-
Notifications
You must be signed in to change notification settings - Fork 11
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
Move backedge analysis here from Revise, add docs, and release 1.0 #30
Conversation
This package seems like a more natural home. It might be useful in contexts outside of Revise. In Revise they are a means to an end, and that's resulted in limited direct testing. Moving them here also encourages fleshing out the API. This adds many new utitilies and `show` methods. Testing is done by checking the selectivity of execution, an easier but thorough way of examining whether its making the correct decisions.
Codecov Report
@@ Coverage Diff @@
## master #30 +/- ##
===========================================
+ Coverage 0.00% 85.67% +85.67%
===========================================
Files 1 4 +3
Lines 375 691 +316
===========================================
+ Hits 0 592 +592
+ Misses 375 99 -276
Continue to review full report at Codecov.
|
I see that a deploy key got added today by you. |
Yeah, I don't know what was going on last night. Once this finishes building there should 🤞 be a preview of the docs at https://juliadebug.github.io/LoweredCodeUtils.jl/previews/PR30/. I think you'll enjoy the "edges" page and especially the selective execution, @KristofferC. For |
I am sure I will. I am bogged down in a project now so I haven't been able to fully enjoy and experiment with all the new method/code analysis stuff you have made so much progress on. I mean to take a careful look at it in hopefully not too long. |
This also fixes some desynchronization problems with the previous version of the "edges" docs.
Also get rid of an anoymous function to make it more precompile-friendly
Now with better precompiles, xref JuliaLang/julia#34516 (comment) |
Revise has had "backedge" analysis code for some time. It uses it to restrict the amount of code it needs to interpret in order to discover signatures. Unfortunately, it's been only partly successful, and the recent timholy/Revise.jl#479 demonstrates that small tweaks can lead to big breakage.
This PR rewrites that entire code base and moves it from Revise to here. The old code relied on whole block-level decisions, whereas the new algorithm is granular to the level of individual statements. That means that it is more capable of stepping over lines that "do work" rather than define methods, even when the two are intermixed deep within an
@eval
(as is the case with AstroBase). I have verified that this, together with a suitably-rewritten Revise to be pushed later, fix (don't close yet) timholy/Revise.jl#479 and seems to make Revise handle a wider variety of tricky code. CC @helgee.This also adds documentation. As you can see, this is a very large PR, though much of its size comes from splitting the original package up into several source files and adding documentation. Nevertheless the new
codeedges
file is sizable and bears almost no resemblance to its parent in Revise.Once merged, I propose we call this the 1.0 release of LoweredCodeUtils.
Unfortunately there seems to be something messed up with my account so I don't have permissions to add the deploy key, we will want to get that figured out.