diff --git a/benchmark/Project.toml b/benchmark/Project.toml index 9005636ab..197191948 100644 --- a/benchmark/Project.toml +++ b/benchmark/Project.toml @@ -1,5 +1,7 @@ [deps] BenchmarkTools = "6e4b80f9-dd63-53aa-95a3-0cdb28fa8baf" +LDPCDecoders = "3c486d74-64b9-4c60-8b1a-13a564e77efb" Nemo = "2edaba10-b0f1-5616-af89-8c11ac63239a" +PyQDecoders = "17f5de1a-9b79-4409-a58d-4d45812840f7" QuantumClifford = "0525e862-1e90-11e9-3e4d-1b39d7109de1" StableRNGs = "860ef19b-820b-49d6-a774-d7a799459cd3" diff --git a/benchmark/benchmarks.jl b/benchmark/benchmarks.jl index 8b31e501f..f1bc97504 100644 --- a/benchmark/benchmarks.jl +++ b/benchmark/benchmarks.jl @@ -139,3 +139,20 @@ SUITE["circuitsim"]["mctrajectories_sumtype"]["q101_r1"] = @benchmarkable mct SUITE["circuitsim"]["mctrajectories_sumtype"]["q1001_r1"] = @benchmarkable mctrajectory!(state, circuit) setup=(state=Register(one(Stabilizer, 1001), [false]); circuit=compactify_circuit(x_diag_circuit(1000))) evals=1 end + + +if V >= v"0.8.20" + +SUITE["ecc"] = BenchmarkGroup(["ecc"]) +SUITE["ecc"]["evaluate_decoder"] = BenchmarkGroup(["evaluate_decoder"]) +for (cs, c) in [("shor",Shor9()), ("toric8",Toric(8,8))] + for (ds, d) in [ + [("table",TableDecoder(c)), ("bp",BeliefPropDecoder(c)), ("pybp",PyBeliefPropDecoder(c))]..., + (isa(c,Toric) ? [("pymatch",PyMatchingDecoder(c))] : [])...] + for (ss, s) in [("comm",CommutationCheckECCSetup(0.01)), ("naivesyn",NaiveSyndromeECCSetup(0.01,0)), ("shorsyn",ShorSyndromeECCSetup(0.01,0))] + SUITE["ecc"]["evaluate_decoder"]["$(cs)_$(ds)_$(ss)"] = @benchmark evaluate_decoder($d, $s, 1000) + end + end +end + +end