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

Unified Diff: gin/isolate_holder.cc

Issue 2660423003: Atomics.wait throws when called on the main thread. (Closed)
Patch Set: Created 3 years, 11 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 | gin/public/isolate_holder.h » ('j') | gin/public/isolate_holder.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gin/isolate_holder.cc
diff --git a/gin/isolate_holder.cc b/gin/isolate_holder.cc
index e38190c4285dd49997452b6336b61c0518fcc9f4..7d9ce02f22c700559fc4e082380b20090bb37d27 100644
--- a/gin/isolate_holder.cc
+++ b/gin/isolate_holder.cc
@@ -33,7 +33,8 @@ IsolateHolder::IsolateHolder(
IsolateHolder::IsolateHolder(
scoped_refptr<base::SingleThreadTaskRunner> task_runner,
- AccessMode access_mode)
+ AccessMode access_mode,
+ AllowAtomicsWaitMode atomics_wait_mode)
: access_mode_(access_mode) {
v8::ArrayBuffer::Allocator* allocator = g_array_buffer_allocator;
CHECK(allocator) << "You need to invoke gin::IsolateHolder::Initialize first";
@@ -43,6 +44,7 @@ IsolateHolder::IsolateHolder(
params.constraints.ConfigureDefaults(base::SysInfo::AmountOfPhysicalMemory(),
base::SysInfo::AmountOfVirtualMemory());
params.array_buffer_allocator = allocator;
+ params.allow_atomics_wait = atomics_wait_mode == kAllowAtomicsWait;
isolate_ = v8::Isolate::New(params);
isolate_data_.reset(
new PerIsolateData(isolate_, allocator, access_mode, task_runner));
« no previous file with comments | « no previous file | gin/public/isolate_holder.h » ('j') | gin/public/isolate_holder.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698