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

Unified Diff: src/v8.h

Issue 1069883002: WIP SharedArrayBuffer implementation (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 8 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
« src/objects.h ('K') | « src/types.cc ('k') | src/v8.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/v8.h
diff --git a/src/v8.h b/src/v8.h
index 211f3c6141a79650fa798ef9351e1276a24486c8..d60c77390a2ad13cadfb08b18b9430e29c38db23 100644
--- a/src/v8.h
+++ b/src/v8.h
@@ -78,6 +78,16 @@ class V8 : public AllStatic {
array_buffer_allocator_ = allocator;
}
+ static v8::SharedArrayBuffer::Allocator* SharedArrayBufferAllocator() {
+ return shared_array_buffer_allocator_;
+ }
+
+ static void SetSharedArrayBufferAllocator(
+ v8::SharedArrayBuffer::Allocator* allocator) {
+ CHECK_NULL(shared_array_buffer_allocator_);
+ shared_array_buffer_allocator_ = allocator;
+ }
+
static void InitializePlatform(v8::Platform* platform);
static void ShutdownPlatform();
static v8::Platform* GetCurrentPlatform();
@@ -91,6 +101,8 @@ class V8 : public AllStatic {
// Allocator for external array buffers.
static v8::ArrayBuffer::Allocator* array_buffer_allocator_;
+ // Allocator for external shared array buffers.
+ static v8::SharedArrayBuffer::Allocator* shared_array_buffer_allocator_;
// v8::Platform to use.
static v8::Platform* platform_;
};
« src/objects.h ('K') | « src/types.cc ('k') | src/v8.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698