Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(196)

Unified Diff: src/execution.cc

Issue 1230303005: Signal a blocked futex if the isolate is interrupted; don't busy-wait (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: merge master Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/futex-emulation.h » ('j') | src/futex-emulation.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/execution.cc
diff --git a/src/execution.cc b/src/execution.cc
index d2dd41a12c6598ca170d80da314267382780e86e..b21bd8f82f81bb1811dba1526dfde0b2a47030d7 100644
--- a/src/execution.cc
+++ b/src/execution.cc
@@ -413,6 +413,11 @@ void StackGuard::RequestInterrupt(InterruptFlag flag) {
// Not intercepted. Set as active interrupt flag.
thread_local_.interrupt_flags_ |= flag;
set_interrupt_limits(access);
+
+ // If this isolate is waiting in a futex, notify it to wake up.
+ if (isolate_->futex_wait_list_node()->waiting()) {
Jarin 2015/08/19 05:26:05 Could we perhaps pull the waiting() check into Not
binji 2015/08/19 17:36:23 My thought here was to do a quick check to avoid t
+ isolate_->futex_wait_list_node()->NotifyWake();
+ }
}
« no previous file with comments | « no previous file | src/futex-emulation.h » ('j') | src/futex-emulation.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698