You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "js8544 (via GitHub)" <gi...@apache.org> on 2023/02/02 15:25:35 UTC

[GitHub] [arrow] js8544 opened a new pull request, #34008: GH-34007: [C++] Add an array_span_mutable interface to ExecResult

js8544 opened a new pull request, #34008:
URL: https://github.com/apache/arrow/pull/34008

   <!--
   Thanks for opening a pull request!
   If this is your first pull request you can find detailed information on how 
   to contribute here:
     * [New Contributor's Guide](https://arrow.apache.org/docs/dev/developers/guide/step_by_step/pr_lifecycle.html#reviews-and-merge-of-the-pull-request)
     * [Contributing Overview](https://arrow.apache.org/docs/dev/developers/overview.html)
   
   
   If this is not a [minor PR](https://github.com/apache/arrow/blob/master/CONTRIBUTING.md#Minor-Fixes). Could you open an issue for this pull request on GitHub? https://github.com/apache/arrow/issues/new/choose
   
   Opening GitHub issues ahead of time contributes to the [Openness](http://theapacheway.com/open/#:~:text=Openness%20allows%20new%20users%20the,must%20happen%20in%20the%20open.) of the Apache Arrow project.
   
   Then could you also rename the pull request title in the following format?
   
       GH-${GITHUB_ISSUE_ID}: [${COMPONENT}] ${SUMMARY}
   
   or
   
       MINOR: [${COMPONENT}] ${SUMMARY}
   
   In the case of PARQUET issues on JIRA the title also supports:
   
       PARQUET-${JIRA_ISSUE_ID}: [${COMPONENT}] ${SUMMARY}
   
   -->
   
   ### Rationale for this change
   
   Like for Buffer, we separate two interface for getting the underlying `array_span` for `ExecResult`, one const and one mutable. This avoids the awkward `const_cast` we currently use.
   
   <!--
    Why are you proposing this change? If this is already explained clearly in the issue then this section is not needed.
    Explaining clearly why changes are proposed helps reviewers understand your changes and offer better suggestions for fixes.  
   -->
   
   ### What changes are included in this PR?
   
   <!--
   There is no need to duplicate the description in the issue here but it is sometimes worth providing a summary of the individual changes in this PR.
   -->
   
   Add the new mutable interface and update current calls to this method.
   
   ### Are these changes tested?
   
   <!--
   We typically require tests for all PRs in order to:
   1. Prevent the code from being accidentally broken by subsequent changes
   2. Serve as another way to document the expected behavior of the code
   
   If tests are not included in your PR, please explain why (for example, are they covered by existing tests)?
   -->
   
   Tested with existing tests.
   
   ### Are there any user-facing changes?
   
   <!--
   If there are user-facing changes then we may require documentation to be updated before approving the PR.
   -->
   
   <!--
   If there are any breaking changes to public APIs, please uncomment the line below and explain which changes are breaking.
   -->
   <!-- **This PR includes breaking changes to public APIs.** -->
   
   <!--
   Please uncomment the line below (and provide explanation) if the changes fix either (a) a security vulnerability, (b) a bug that caused incorrect or invalid data to be produced, or (c) a bug that causes a crash (even when the API contract is upheld). We use this to highlight fixes to issues that may affect users without their knowledge. For this reason, fixing bugs that cause errors don't count, since those are usually obvious.
   -->
   <!-- **This PR contains a "Critical Fix".** -->
   No.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [arrow] ursabot commented on pull request #34008: GH-34007: [C++] Add an array_span_mutable interface to ExecResult

Posted by "ursabot (via GitHub)" <gi...@apache.org>.
ursabot commented on PR #34008:
URL: https://github.com/apache/arrow/pull/34008#issuecomment-1416668181

   ['Python', 'R'] benchmarks have high level of regressions.
   [ursa-i9-9960x](https://conbench.ursa.dev/compare/runs/402a171775bc48218e7a5fc8ac9b179e...a005f0c9e2804f30a6996888dd0e5008/)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [arrow] github-actions[bot] commented on pull request #34008: GH-34007: [C++] Add an array_span_mutable interface to ExecResult

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #34008:
URL: https://github.com/apache/arrow/pull/34008#issuecomment-1413922569

   * Closes: #34007


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [arrow] westonpace merged pull request #34008: GH-34007: [C++] Add an array_span_mutable interface to ExecResult

Posted by "westonpace (via GitHub)" <gi...@apache.org>.
westonpace merged PR #34008:
URL: https://github.com/apache/arrow/pull/34008


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [arrow] github-actions[bot] commented on pull request #34008: GH-34007: [C++] Add an array_span_mutable interface to ExecResult

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #34008:
URL: https://github.com/apache/arrow/pull/34008#issuecomment-1413922628

   :warning: GitHub issue #34007 **has been automatically assigned in GitHub** to PR creator.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [arrow] js8544 commented on pull request #34008: GH-34007: [C++] Add an array_span_mutable interface to ExecResult

Posted by "js8544 (via GitHub)" <gi...@apache.org>.
js8544 commented on PR #34008:
URL: https://github.com/apache/arrow/pull/34008#issuecomment-1414735193

   > I would generally discourage rewriting something to auto just because you can.
   Makes sense to me. I've reverted the changes to `auto`.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [arrow] ursabot commented on pull request #34008: GH-34007: [C++] Add an array_span_mutable interface to ExecResult

Posted by "ursabot (via GitHub)" <gi...@apache.org>.
ursabot commented on PR #34008:
URL: https://github.com/apache/arrow/pull/34008#issuecomment-1416668109

   Benchmark runs are scheduled for baseline = 78a8da42d1fc364e84286afc88a25fa5b819d092 and contender = 3be5e11687ea874b7293d17227943bd8244e8789. 3be5e11687ea874b7293d17227943bd8244e8789 is a master commit associated with this PR. Results will be available as each benchmark for each run completes.
   Conbench compare runs links:
   [Finished :arrow_down:0.0% :arrow_up:0.0%] [ec2-t3-xlarge-us-east-2](https://conbench.ursa.dev/compare/runs/869a32da5c76409eaff01a86ec73b71a...778ab7898d9144e5991aa2db2e664089/)
   [Failed :arrow_down:0.55% :arrow_up:0.0%] [test-mac-arm](https://conbench.ursa.dev/compare/runs/b62f47606ff846658987ab2cdb3c97e1...741f7d90310b476ba0b3ef835b1bd8ba/)
   [Finished :arrow_down:1.79% :arrow_up:0.0%] [ursa-i9-9960x](https://conbench.ursa.dev/compare/runs/402a171775bc48218e7a5fc8ac9b179e...a005f0c9e2804f30a6996888dd0e5008/)
   [Finished :arrow_down:0.41% :arrow_up:0.06%] [ursa-thinkcentre-m75q](https://conbench.ursa.dev/compare/runs/279a2a32768940968540237e86c1f92e...dd4dbf57262a4b1a959916516d547b54/)
   Buildkite builds:
   [Finished] [`3be5e116` ec2-t3-xlarge-us-east-2](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ec2-t3-xlarge-us-east-2/builds/2320)
   [Failed] [`3be5e116` test-mac-arm](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-test-mac-arm/builds/2347)
   [Finished] [`3be5e116` ursa-i9-9960x](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ursa-i9-9960x/builds/2319)
   [Finished] [`3be5e116` ursa-thinkcentre-m75q](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ursa-thinkcentre-m75q/builds/2338)
   [Finished] [`78a8da42` ec2-t3-xlarge-us-east-2](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ec2-t3-xlarge-us-east-2/builds/2319)
   [Finished] [`78a8da42` test-mac-arm](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-test-mac-arm/builds/2346)
   [Finished] [`78a8da42` ursa-i9-9960x](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ursa-i9-9960x/builds/2317)
   [Finished] [`78a8da42` ursa-thinkcentre-m75q](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ursa-thinkcentre-m75q/builds/2337)
   Supported benchmarks:
   ec2-t3-xlarge-us-east-2: Supported benchmark langs: Python, R. Runs only benchmarks with cloud = True
   test-mac-arm: Supported benchmark langs: C++, Python, R
   ursa-i9-9960x: Supported benchmark langs: Python, R, JavaScript
   ursa-thinkcentre-m75q: Supported benchmark langs: C++, Java
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [arrow] westonpace commented on pull request #34008: GH-34007: [C++] Add an array_span_mutable interface to ExecResult

Posted by "westonpace (via GitHub)" <gi...@apache.org>.
westonpace commented on PR #34008:
URL: https://github.com/apache/arrow/pull/34008#issuecomment-1414522524

   +1 on the idea of `array_span_mutable`.
   
   I'm -0.5 on rewriting everything to auto.  Arrow follows the [google C++ style guide](https://google.github.io/styleguide/cppguide.html#Type_deduction) which states:
   
   > The fundamental rule is: use type deduction only to make the code clearer or safer, and do not use it merely to avoid the inconvenience of writing an explicit type. When judging whether the code is clearer, keep in mind that your readers are not necessarily on your team, or familiar with your project, so types that you and your reviewer experience as unnecessary clutter will very often provide useful information to others. For example, you can assume that the return type of make_unique<Foo>() is obvious, but the return type of MyWidgetFactory() probably isn't.
   
   Though that leaves plenty of room for interpretation.  We also have not applied the rule consistently and large chunks of the code base use auto extensively.
   
   However, I would generally discourage rewriting something to auto just because you can.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org