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
DCHECK when closing BrowserWindow from microtask #20013
Comments
Looks like the failing DCHECK is that we're trying to run a microtask queue that's already running. The constructor's DCHECK in this code is what's failing: class SetIsRunningMicrotasks {
public:
explicit SetIsRunningMicrotasks(bool* flag) : flag_(flag) {
DCHECK(!*flag_);
*flag_ = true;
}
~SetIsRunningMicrotasks() {
DCHECK(*flag_);
*flag_ = false;
}
private:
bool* flag_;
}; The first call to pump the microtask queue appears to come from https://github.com/electron/electron/blob/master/shell/browser/microtasks_runner.cc#L17 https://github.com/v8/v8/blob/master/src/execution/microtask-queue.cc#L117
This sets the stage for the second call that occurs while the previous tasks are still running. Backtrace here matches Jeremy's:
|
I've opened nodejs/node#29434 to address this ☝️ |
Closed by nodejs/node#29434. |
vscode was seeing slow startup times when upgrading to E8 compared to E7, turns out this change was source of the slowdown microsoft/vscode#97638 (comment). I am yet to make a minimal repro, any thoughts in debugging further is appreciated. |
Release builds don't crash on this because it's a DCHECK.
Fiddle: https://gist.github.com/316a0d5e34603dc3a352e8289f0065de
Stack trace:
The text was updated successfully, but these errors were encountered: