-
Notifications
You must be signed in to change notification settings - Fork 6
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
Implement FinalizerEscape #90
base: master
Are you sure you want to change the base?
Conversation
4b8b6bf
to
0da4802
Compare
Codecov Report
@@ Coverage Diff @@
## master #90 +/- ##
==========================================
- Coverage 80.02% 79.21% -0.82%
==========================================
Files 3 3
Lines 1382 1400 +18
==========================================
+ Hits 1106 1109 +3
- Misses 276 291 +15
Continue to review full report at Codecov.
|
@@ -126,13 +127,15 @@ struct EscapeInfo | |||
Analyzed::Bool | |||
ReturnEscape::Bool | |||
ThrownEscape::LivenessSet | |||
FinalizerEscape::Bool |
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.
So how FinalizerEscape
can be used? If we insert finalize
call for allocations whose FinalizerEscape
is true
, we will end up inserting early finalize
calls for anything escaping (since AllEscape
also has FinalizerEscape=true
.
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.
Should FinalizerEscape=true
not be part of AllEscape
?
My initial thoughts were that if nothing escaped other than the object being finalized, and the object being finalized does not otherwise escape, then we'd insert finalize
at the end of the liveness range.
6011c86
to
d8a19b1
Compare
Co-authored-by: Shuhei Kadowaki <[email protected]>
d8a19b1
to
501960e
Compare
With the intention of eventually using this to add early
finalize
calls to minimize GC overhead of functions with many large-but-temporary heap allocations with finalizers.