diff --git a/common/BUILD b/common/BUILD index 41c292327e5d..c7ac6c962a90 100644 --- a/common/BUILD +++ b/common/BUILD @@ -287,9 +287,9 @@ sh_test( srcs = [":filesystem_benchmark"], args = [ "--benchmark_dry_run", - # Restrict the sizes to 4-digit ones or smaller to keep test times low. + # Restrict the sizes to 2-digit ones or smaller to keep test times low. # The `$$` is repeated for Bazel escaping of `$`. - "--benchmark_filter=^[^/]+(/[0-9]{1,4}(/[0-9]+)?)?/real_time$$", + "--benchmark_filter=^[^/]+(/[0-9]{1,2}(/[0-9]+)?)?/real_time$$", ], ) diff --git a/common/filesystem_benchmark.cpp b/common/filesystem_benchmark.cpp index 185448c419a8..2db8f7f589b5 100644 --- a/common/filesystem_benchmark.cpp +++ b/common/filesystem_benchmark.cpp @@ -444,9 +444,9 @@ auto BM_CreateDirectories(benchmark::State& state) -> void { CARBON_CHECK(existing_depth <= depth); CARBON_CHECK(depth > 0); - // Use a batch size of 10 to get avoid completely swamping the measurements + // Use a batch size of 5 to get avoid completely swamping the measurements // with overhead from creating existing directories and cleaning up. - constexpr int BatchSize = 10; + constexpr int BatchSize = 5; // Pre-build both the paths and the existing paths. Note that we use // relatively short paths here, which if anything makes the benefits of the