Skip to content

Commit

Permalink
benchmarks: modularize
Browse files Browse the repository at this point in the history
  • Loading branch information
MilesCranmer committed Aug 2, 2024
1 parent 37c89d7 commit 5295cc7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 2 additions & 0 deletions benchmark/benchmarks.jl
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,6 @@ SUITE["basic"]["@py"]["pydict"]["pydel"] = @benchmarkable test_atpy(Val(true))


include("gcbench.jl")
using .GCBench: append_lots

SUITE["gc"]["append_and_full_gc"] = @benchmarkable GC.gc(true) setup=(append_lots())
6 changes: 5 additions & 1 deletion benchmark/gcbench.jl
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
using PythonCall, Test
module GCBench

using PythonCall

function append_lots(iters=100 * 1024, size=1596)
v = pylist()
Expand All @@ -7,3 +9,5 @@ function append_lots(iters=100 * 1024, size=1596)
end
return v
end

end

0 comments on commit 5295cc7

Please sign in to comment.