Stop looking up the methods at compile time. For much speed. #47
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
#27
There is 1 key internal change of this, that should be invisible to users, more or less.
Rather than create a
Method
using@which
, to decide if a method should be instrumented or not.we instead query the function + argument against the set of rules.
Which is much faster, expectially in the case where no, or few
@no_debug
rules are set.(as in the benchmark below).
However, there is 1 problem with this.
If you
set_nodebug
on a method, that takes fairly abstract arguments.Then it will actually result in all more specific methods also being blocked.
I don't think that that is actually a serious usability issue.
As
set_nodebug
is mostly used ona function or module level.set_nodebug
from working on amethod
level.A less problematic side effect of this change is that now setting no debug on a Module,
now takes out methods that belong to that module's functions,
even when those methods are defined in other modules.
I do not think this change is a problem, as I think that is the more reasonable behavour to have.
It is about knocking out a whole namepace, not knocking out a particular package.
using the "standard" summer test
for benchmarking debuggers:
(I have a feeling I am not using it the same way as in JuliaDebug/JuliaInterpreter.jl#204 (comment) though)
With this PR:
Current master: