Skip to content

Commit d021f2e

Browse files
Remove debugging macros in reinit! due to overhead
This ends up having a lot of overhead found in SciML/OrdinaryDiffEq.jl#2757. They are triggered because the `reinit!` code recursively `reinit!`s the internals of the cache, and `LinearCache` doesn't have a `reinit!`, so it's a no-op. This is correct, but it turns out the debugging macro is just really expensive so it makes it slow even though it's not doing anything 😅 . I commented it out so we know where to put SciMLVerbosity.jl instructions for the near future @jClugstor
1 parent 37926ed commit d021f2e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/NonlinearSolveBase/src/abstract_types.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ function reinit! end
1010
function reinit_self! end
1111

1212
function reinit!(x::Any; kwargs...)
13-
@debug "`InternalAPI.reinit!` is not implemented for $(typeof(x))."
13+
#@debug "`InternalAPI.reinit!` is not implemented for $(typeof(x))."
1414
return
1515
end
1616
function reinit_self!(x::Any; kwargs...)
17-
@debug "`InternalAPI.reinit_self!` is not implemented for $(typeof(x))."
17+
#@debug "`InternalAPI.reinit_self!` is not implemented for $(typeof(x))."
1818
return
1919
end
2020

0 commit comments

Comments
 (0)