-
Notifications
You must be signed in to change notification settings - Fork 37
Fixes #432 ... #504
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
Fixes #432 ... #504
Conversation
... by moving `invokelatest` up the call stack.
Why does this work? And how much of a performance impact does it have? |
I first tried smaller changes to repair the problem, but then some tests failed. I don't have tools available to diagnose the crash in Julia.
Doesn't CI tell us that? |
Codecov Report
@@ Coverage Diff @@
## master #504 +/- ##
==========================================
- Coverage 87.31% 87.28% -0.04%
==========================================
Files 12 12
Lines 2468 2470 +2
==========================================
+ Hits 2155 2156 +1
- Misses 313 314 +1
Continue to review full report at Codecov.
|
Ouch. Any hints how to repair this for Julia 1? |
Wait for #499 to be merged and rebase :) |
src/interpret.jl
Outdated
fmod = parentmodule(f)::Module | ||
if fmod === JuliaInterpreter.CompiledCalls || fmod === Core.Compiler | ||
return Some{Any}(Base.invokelatest(f, fargs[2:end]...)) | ||
else | ||
return Some{Any}(f(fargs[2:end]...)) | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we want to keep this code around (like with commented out), and leave some comment that says ideally we want to figure out the root problem here and remove the added invokelatest
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
I worry this isn't the right fix...it's just kind of a bandaid, and one that will likely hurt performance.
No, CI is often quite bad for checking performance, because the CI servers are always running multiple tasks and you get spurious failures when server-latency gets confounded for a performance regression. You kind of need a dedicated machine. You can run benchmarks locally in https://github.com/JuliaDebug/JuliaInterpreter.jl/tree/master/benchmark, although as a caution our benchmarks may not be completely thorough. |
Same, which is why I'd like to understand why this works. |
For main:
For branch:
|
Unfortunately this works on 1.7.0 and does not on 1.6.4.
tested on 1.8.0-DEV.
At least I now understand that there seems to be some kind of world age confusion. Interesting question I've been pondering is how to explicitly track world age. |
Let's get this in even though we are not sure exactly what is going on. It fixes a problem and doesn't complicate the code much. Thanks @goerch! |
... by moving
invokelatest
up the call stack.