Skip to content

Commit bf61250

Browse files
committed
Use rng::copy instead of ranges::copy -- that way the results align better with std:: in the tabular output
1 parent d34de3e commit bf61250

File tree

4 files changed

+21
-21
lines changed

4 files changed

+21
-21
lines changed

libcxx/test/benchmarks/algorithms/modifying/copy.bench.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ int main(int argc, char** argv) {
4545
bm.operator()<std::vector<int>>("std::copy(vector<int>)", std_copy);
4646
bm.operator()<std::deque<int>>("std::copy(deque<int>)", std_copy);
4747
bm.operator()<std::list<int>>("std::copy(list<int>)", std_copy);
48-
bm.operator()<std::vector<int>>("ranges::copy(vector<int>)", std::ranges::copy);
49-
bm.operator()<std::deque<int>>("ranges::copy(deque<int>)", std::ranges::copy);
50-
bm.operator()<std::list<int>>("ranges::copy(list<int>)", std::ranges::copy);
48+
bm.operator()<std::vector<int>>("rng::copy(vector<int>)", std::ranges::copy);
49+
bm.operator()<std::deque<int>>("rng::copy(deque<int>)", std::ranges::copy);
50+
bm.operator()<std::list<int>>("rng::copy(list<int>)", std::ranges::copy);
5151
}
5252

5353
// {std,ranges}::copy(vector<bool>)
@@ -71,8 +71,8 @@ int main(int argc, char** argv) {
7171
bm.operator()<true>("std::copy(vector<bool>) (aligned)", std_copy);
7272
bm.operator()<false>("std::copy(vector<bool>) (unaligned)", std_copy);
7373
#if TEST_STD_VER >= 23 // vector<bool>::iterator is not an output_iterator before C++23
74-
bm.operator()<true>("ranges::copy(vector<bool>) (aligned)", std::ranges::copy);
75-
bm.operator()<false>("ranges::copy(vector<bool>) (unaligned)", std::ranges::copy);
74+
bm.operator()<true>("rng::copy(vector<bool>) (aligned)", std::ranges::copy);
75+
bm.operator()<false>("rng::copy(vector<bool>) (unaligned)", std::ranges::copy);
7676
#endif
7777
}
7878

libcxx/test/benchmarks/algorithms/modifying/copy_backward.bench.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ int main(int argc, char** argv) {
4545
bm.operator()<std::vector<int>>("std::copy_backward(vector<int>)", std_copy_backward);
4646
bm.operator()<std::deque<int>>("std::copy_backward(deque<int>)", std_copy_backward);
4747
bm.operator()<std::list<int>>("std::copy_backward(list<int>)", std_copy_backward);
48-
bm.operator()<std::vector<int>>("ranges::copy_backward(vector<int>)", std::ranges::copy_backward);
49-
bm.operator()<std::deque<int>>("ranges::copy_backward(deque<int>)", std::ranges::copy_backward);
50-
bm.operator()<std::list<int>>("ranges::copy_backward(list<int>)", std::ranges::copy_backward);
48+
bm.operator()<std::vector<int>>("rng::copy_backward(vector<int>)", std::ranges::copy_backward);
49+
bm.operator()<std::deque<int>>("rng::copy_backward(deque<int>)", std::ranges::copy_backward);
50+
bm.operator()<std::list<int>>("rng::copy_backward(list<int>)", std::ranges::copy_backward);
5151
}
5252

5353
// {std,ranges}::copy_n(vector<bool>)
@@ -72,8 +72,8 @@ int main(int argc, char** argv) {
7272
bm.operator()<true>("std::copy_backward(vector<bool>) (aligned)", std_copy_backward);
7373
bm.operator()<false>("std::copy_backward(vector<bool>) (unaligned)", std_copy_backward);
7474
#if TEST_STD_VER >= 23 // vector<bool>::iterator is not an output_iterator before C++23
75-
bm.operator()<true>("ranges::copy_backward(vector<bool>) (aligned)", std::ranges::copy_backward);
76-
bm.operator()<false>("ranges::copy_backward(vector<bool>) (unaligned)", std::ranges::copy_backward);
75+
bm.operator()<true>("rng::copy_backward(vector<bool>) (aligned)", std::ranges::copy_backward);
76+
bm.operator()<false>("rng::copy_backward(vector<bool>) (unaligned)", std::ranges::copy_backward);
7777
#endif
7878
}
7979

libcxx/test/benchmarks/algorithms/modifying/copy_if.bench.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,9 @@ int main(int argc, char** argv) {
5353
bm.operator()<std::deque<int>>("std::copy_if(deque<int>) (every other)", std_copy_if);
5454
bm.operator()<std::list<int>>("std::copy_if(list<int>) (every other)", std_copy_if);
5555

56-
bm.operator()<std::vector<int>>("ranges::copy_if(vector<int>) (every other)", std::ranges::copy_if);
57-
bm.operator()<std::deque<int>>("ranges::copy_if(deque<int>) (every other)", std::ranges::copy_if);
58-
bm.operator()<std::list<int>>("ranges::copy_if(list<int>) (every other)", std::ranges::copy_if);
56+
bm.operator()<std::vector<int>>("rng::copy_if(vector<int>) (every other)", std::ranges::copy_if);
57+
bm.operator()<std::deque<int>>("rng::copy_if(deque<int>) (every other)", std::ranges::copy_if);
58+
bm.operator()<std::list<int>>("rng::copy_if(list<int>) (every other)", std::ranges::copy_if);
5959
}
6060

6161
// Benchmark {std,ranges}::copy_if where we copy the full range.
@@ -86,9 +86,9 @@ int main(int argc, char** argv) {
8686
bm.operator()<std::deque<int>>("std::copy_if(deque<int>) (entire range)", std_copy_if);
8787
bm.operator()<std::list<int>>("std::copy_if(list<int>) (entire range)", std_copy_if);
8888

89-
bm.operator()<std::vector<int>>("ranges::copy_if(vector<int>) (entire range)", std::ranges::copy_if);
90-
bm.operator()<std::deque<int>>("ranges::copy_if(deque<int>) (entire range)", std::ranges::copy_if);
91-
bm.operator()<std::list<int>>("ranges::copy_if(list<int>) (entire range)", std::ranges::copy_if);
89+
bm.operator()<std::vector<int>>("rng::copy_if(vector<int>) (entire range)", std::ranges::copy_if);
90+
bm.operator()<std::deque<int>>("rng::copy_if(deque<int>) (entire range)", std::ranges::copy_if);
91+
bm.operator()<std::list<int>>("rng::copy_if(list<int>) (entire range)", std::ranges::copy_if);
9292
}
9393

9494
benchmark::Initialize(&argc, argv);

libcxx/test/benchmarks/algorithms/modifying/copy_n.bench.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ int main(int argc, char** argv) {
4545
bm.operator()<std::vector<int>>("std::copy_n(vector<int>)", std_copy_n);
4646
bm.operator()<std::deque<int>>("std::copy_n(deque<int>)", std_copy_n);
4747
bm.operator()<std::list<int>>("std::copy_n(list<int>)", std_copy_n);
48-
bm.operator()<std::vector<int>>("ranges::copy_n(vector<int>)", std::ranges::copy_n);
49-
bm.operator()<std::deque<int>>("ranges::copy_n(deque<int>)", std::ranges::copy_n);
50-
bm.operator()<std::list<int>>("ranges::copy_n(list<int>)", std::ranges::copy_n);
48+
bm.operator()<std::vector<int>>("rng::copy_n(vector<int>)", std::ranges::copy_n);
49+
bm.operator()<std::deque<int>>("rng::copy_n(deque<int>)", std::ranges::copy_n);
50+
bm.operator()<std::list<int>>("rng::copy_n(list<int>)", std::ranges::copy_n);
5151
}
5252

5353
// {std,ranges}::copy_n(vector<bool>)
@@ -70,8 +70,8 @@ int main(int argc, char** argv) {
7070
bm.operator()<true>("std::copy_n(vector<bool>) (aligned)", std_copy_n);
7171
bm.operator()<false>("std::copy_n(vector<bool>) (unaligned)", std_copy_n);
7272
#if TEST_STD_VER >= 23 // vector<bool>::iterator is not an output_iterator before C++23
73-
bm.operator()<true>("ranges::copy_n(vector<bool>) (aligned)", std::ranges::copy_n);
74-
bm.operator()<false>("ranges::copy_n(vector<bool>) (unaligned)", std::ranges::copy_n);
73+
bm.operator()<true>("rng::copy_n(vector<bool>) (aligned)", std::ranges::copy_n);
74+
bm.operator()<false>("rng::copy_n(vector<bool>) (unaligned)", std::ranges::copy_n);
7575
#endif
7676
}
7777

0 commit comments

Comments
 (0)