Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Exclude precompilation from coverage #6

Merged
merged 1 commit into from
Apr 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions ext/BraketSimulatorPythonExt/precompile.jl
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# exclude precompilation from coverage
# COV_EXCL_START
function _precompile_()
ccall(:jl_generating_output, Cint, ()) == 1 || return nothing
Base.precompile(Tuple{typeof(jl_convert_sim_hadamard),Type{Instruction},Py}) # time: 4.069578
Expand Down Expand Up @@ -110,3 +112,4 @@ function _precompile_()
Base.precompile(Tuple{Type{Py},TwoQubitDephasing,Vector{Int64}}) # time: 0.001219169
isdefined(BraketSimulatorPythonExt, Symbol("#201#204")) && Base.precompile(Tuple{getfield(BraketSimulatorPythonExt, Symbol("#201#204")),Vector{Vector{Float64}}}) # time: 0.001131461
end
# COV_EXCL_STOP
3 changes: 3 additions & 0 deletions src/precompile.jl
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# exclude precompilation from coverage
# COV_EXCL_START
function _precompile_()
ccall(:jl_generating_output, Cint, ()) == 1 || return nothing
Base.precompile(Tuple{typeof(apply_observables!),StateVectorSimulator{ComplexF64, Vector{ComplexF64}},Vector{Tuple{HermitianObservable, Vector{Int64}}}}) # time: 2.3760564
Expand Down Expand Up @@ -270,3 +272,4 @@ function _precompile_()
Base.precompile(Tuple{Type{DensityMatrixSimulator},Int64,Int64}) # time: 0.001066707
Base.precompile(Tuple{typeof(evolve!),DensityMatrixSimulator{ComplexF64, Matrix{ComplexF64}},Vector{Instruction{XX}}}) # time: 0.001022039
end
# COV_EXCL_STOP
Loading