Skip to content

MINOR: [C++] Replace std::random_shuffle with std::shuffle - #13948

Merged
pitrou merged 1 commit into
apache:masterfrom
amoeba:cpp_fix
Aug 23, 2022
Merged

pitrou merged 1 commit into
apache:masterfrom
amoeba:cpp_fix

Conversation

@amoeba

@amoeba amoeba commented Aug 23, 2022

Copy link
Copy Markdown
Member

std::random_shuffle was deprecated in C++14 and removed altogether in C++17 in favor of std::shuffle. The codebase only uses these shuffling functions in tests and benchmarks and std::shuffle is used in all instances except this one.

@github-actions

Copy link
Copy Markdown

Thanks for opening a pull request!

If this is not a minor PR. Could you open an issue for this pull request on JIRA? https://issues.apache.org/jira/browse/ARROW

Opening JIRAs ahead of time contributes to the Openness of the Apache Arrow project.

Then could you also rename pull request title in the following format?

ARROW-${JIRA_ID}: [${COMPONENT}] ${SUMMARY}

or

MINOR: [${COMPONENT}] ${SUMMARY}

See also:

@amoeba amoeba changed the title [MINOR]: [C++] Replace std::random_shuffle with std::shuffle MINOR: [C++] Replace std::random_shuffle with std::shuffle Aug 23, 2022

@pitrou pitrou left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you @amoeba. Will wait for CI.

@pitrou
pitrou merged commit cc75993 into apache:master Aug 23, 2022
@ursabot

ursabot commented Aug 23, 2022

Copy link
Copy Markdown

Benchmark runs are scheduled for baseline = 8b89147 and contender = cc75993. cc75993 is a master commit associated with this PR. Results will be available as each benchmark for each run completes.
Conbench compare runs links:
[Finished ⬇️0.0% ⬆️0.0%] ec2-t3-xlarge-us-east-2
[Failed ⬇️0.48% ⬆️0.0%] test-mac-arm
[Failed ⬇️0.82% ⬆️0.0%] ursa-i9-9960x
[Finished ⬇️0.64% ⬆️0.43%] ursa-thinkcentre-m75q
Buildkite builds:
[Finished] cc759936 ec2-t3-xlarge-us-east-2
[Failed] cc759936 test-mac-arm
[Failed] cc759936 ursa-i9-9960x
[Finished] cc759936 ursa-thinkcentre-m75q
[Finished] 8b891471 ec2-t3-xlarge-us-east-2
[Finished] 8b891471 test-mac-arm
[Failed] 8b891471 ursa-i9-9960x
[Finished] 8b891471 ursa-thinkcentre-m75q
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

@ursabot

ursabot commented Aug 23, 2022

Copy link
Copy Markdown

['Python', 'R'] benchmarks have high level of regressions.
test-mac-arm
ursa-i9-9960x

zagto pushed a commit to zagto/arrow that referenced this pull request Oct 7, 2022
)

`std::random_shuffle` was deprecated in C++14 and removed altogether in C++17 in favor of `std::shuffle`. The codebase only uses these shuffling functions in tests and benchmarks and `std::shuffle` is used in all instances except this one.

Authored-by: Bryce Mecum <[email protected]>
Signed-off-by: Antoine Pitrou <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants