@@ -111,9 +111,9 @@ function _run(b::Benchmark, p::Parameters; verbose=false, pad="", kwargs...)
111
111
return_val = trial_contents. __return_val
112
112
iters = 2
113
113
while (Base. time () - start_time) < params. seconds && iters ≤ params. samples
114
- params. gcsample && gcscrub ()
115
- push! (trial, b. samplefunc (b. quote_vals, params)[ 1 : ( end - 1 )] . .. )
116
- iters += 1
114
+ params. gcsample && gcscrub ()
115
+ push! (trial, b. samplefunc (b. quote_vals, params))
116
+ iters += 1
117
117
end
118
118
return trial, return_val
119
119
end
@@ -563,23 +563,23 @@ function generate_benchmark_definition(
563
563
__evals))
564
564
if $ (experimental_enable_linux_perf)
565
565
# Based on https://github.com/JuliaPerf/LinuxPerf.jl/blob/a7fee0ff261a5b5ce7a903af7b38d1b5c27dd931/src/LinuxPerf.jl#L1043-L1061
566
- __linux_perf_groups = LinuxPerf. set_default_spaces (
566
+ __linux_perf_groups = BenchmarkTools . LinuxPerf. set_default_spaces (
567
567
$ (linux_perf_opts. events),
568
568
$ (linux_perf_opts. spaces),
569
569
)
570
- __linux_perf_bench = LinuxPerf. make_bench_threaded (
570
+ __linux_perf_bench = BenchmarkTools . LinuxPerf. make_bench_threaded (
571
571
__linux_perf_groups;
572
572
threads = $ (linux_perf_opts. threads),
573
573
)
574
- LinuxPerf. enable! (__linux_perf_bench)
574
+ BenchmarkTools . LinuxPerf. enable! (__linux_perf_bench)
575
575
# We'll just run it one time.
576
576
__return_val_2 = $ (invocation)
577
- LinuxPerf. disable! (__linux_perf_bench)
577
+ BenchmarkTools . LinuxPerf. disable! (__linux_perf_bench)
578
578
# trick the compiler not to eliminate the code
579
579
if rand () < 0
580
580
__linux_perf_stats = __return_val_2
581
581
else
582
- __linux_perf_stats = LinuxPerf. Stats (__linux_perf_bench)
582
+ __linux_perf_stats = BenchmarkTools . LinuxPerf. Stats (__linux_perf_bench)
583
583
end
584
584
end
585
585
return (;
0 commit comments