From ee083f13c6d6619d4ebff5d1ba4df76827201280 Mon Sep 17 00:00:00 2001 From: Louis Dionne Date: Fri, 12 Sep 2025 08:55:14 -0400 Subject: [PATCH] [libc++] Fix broke unique and unique_copy benchmarks These benchmarks have an assumption that the container size is divisible by 4 because of how we populate their content, which wasn't satisfied. --- libcxx/test/benchmarks/algorithms/modifying/unique.bench.cpp | 4 ++-- .../benchmarks/algorithms/modifying/unique_copy.bench.cpp | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/libcxx/test/benchmarks/algorithms/modifying/unique.bench.cpp b/libcxx/test/benchmarks/algorithms/modifying/unique.bench.cpp index c0aee942eef64..e3ac50187ef4b 100644 --- a/libcxx/test/benchmarks/algorithms/modifying/unique.bench.cpp +++ b/libcxx/test/benchmarks/algorithms/modifying/unique.bench.cpp @@ -76,7 +76,7 @@ int main(int argc, char** argv) { } }) ->Arg(32) - ->Arg(50) // non power-of-two + ->Arg(52) // non power-of-two ->Arg(1024) ->Arg(8192); }; @@ -143,7 +143,7 @@ int main(int argc, char** argv) { } }) ->Arg(32) - ->Arg(50) // non power-of-two + ->Arg(52) // non power-of-two ->Arg(1024) ->Arg(8192); }; diff --git a/libcxx/test/benchmarks/algorithms/modifying/unique_copy.bench.cpp b/libcxx/test/benchmarks/algorithms/modifying/unique_copy.bench.cpp index 45b52dd23b695..1885b53e51413 100644 --- a/libcxx/test/benchmarks/algorithms/modifying/unique_copy.bench.cpp +++ b/libcxx/test/benchmarks/algorithms/modifying/unique_copy.bench.cpp @@ -61,6 +61,7 @@ int main(int argc, char** argv) { } }) ->Arg(32) + ->Arg(52) // non power-of-two ->Arg(1024) ->Arg(8192); }; @@ -115,7 +116,7 @@ int main(int argc, char** argv) { } }) ->Arg(32) - ->Arg(50) // non power-of-two + ->Arg(52) // non power-of-two ->Arg(1024) ->Arg(8192); };