-
Notifications
You must be signed in to change notification settings - Fork 30k
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
src: use unrefed async for GC tracking #16758
Conversation
IMHO the Alternative resolution: auto observers = env->performance_state()->observers;
if (observers == nullptr || arraysize(observers) = 0) return; |
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.
😍 🎉 ❤️
wait... they won't. So this becomes a little delicate. |
Niiiiice. |
PerformanceObservers are passive. They won't keep anything open. |
On
|
Make the 'setImmediate' in that test a 'setInterval' I think. |
test/parallel/test-performance-gc.js
Outdated
@@ -48,4 +48,6 @@ const kinds = [ | |||
})); | |||
obs.observe({ entryTypes: ['gc'] }); | |||
global.gc(); | |||
// Keep the event loop alive to witness the GC happen. | |||
setImmediate(() => {}); |
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.
hmmm, some how this is not enough for a gc hook..
EDIT: let's go with #16758 (comment) ?
All Windows fail (if it was just VS2015 I'd plotz) |
During the initial investigation I think this only reproduced on vs2015/vcbt2015 builds? Or we might just missed other 2017 builds at that time. Curious what's differed about those builds... |
╯°□°)╯︵ ┻━┻
As much as I hate to say it … isn’t that just masking a problem instead of taking the time to understand what’s going on? 😞 At least this seems to be failing consistently, yay for that. |
I think the issue was computer related more then compiler related. But we do have a different flake that happens only on VS2017 - #15558 |
Okay, picking up work on this again… |
Do not let an internal handle keep the event loop alive. Fixes: nodejs#16210
Looks like using 2 nested Jenkins is hanging, otherwise I’d start CI, this should be ready… |
@refack Sorry, didn’t see that! 😄 But probably a good idea to make sure nothing’s flaky :) |
Okay, CI seems good - feel free to land this,otherwise I'll do that tomorrow |
Do not let an internal handle keep the event loop alive. PR-URL: #16758 Fixes: https://github.com/node/issues/16210 Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
This effectively reverts 5c475a7 and 75095d7. PR-URL: #16758 Fixes: https://github.com/node/issues/16210 Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Do not let an internal handle keep the event loop alive. PR-URL: #16758 Fixes: https://github.com/node/issues/16210 Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
This effectively reverts 5c475a7 and 75095d7. PR-URL: #16758 Fixes: https://github.com/node/issues/16210 Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
I've backported this to v8.x Please lmk if you think it should bake longer |
Do not let an internal handle keep the event loop alive. PR-URL: #16758 Fixes: https://github.com/node/issues/16210 Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
This effectively reverts 5c475a7 and 75095d7. PR-URL: #16758 Fixes: https://github.com/node/issues/16210 Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Do not let an internal handle keep the event loop alive.
I think this patch is okay since GC isn’t deterministic anyway.
Fixes: #16210
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passesAffected core subsystem(s)
src
@Trott @refack @jasnell