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

Issue 1136553006: Implement SharedArrayBuffer (Closed)

Created:
5 years, 7 months ago by binji
Modified:
5 years, 7 months ago
CC:
Paweł Hajdan Jr., v8-dev
Base URL:
https://chromium.googlesource.com/v8/v8.git@master
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

Implement SharedArrayBuffer. This adds a new external type (v8::SharedArrayBuffer) that uses a JSArrayBuffer under the hood. It can be distinguished from an ArrayBuffer by the newly-added is_shared() bit. Currently there is no difference in functionality between a SharedArrayBuffer and an ArrayBuffer. However, a future CL will add the Atomics API, which is only available on an SharedArrayBuffer. All non-atomic accesses are identical to ArrayBuffer accesses. LOG=N BUG= Committed: https://crrev.com/aff8ebb0ebe165dceb03b567fe54633cf3f0a1f7 Cr-Commit-Position: refs/heads/master@{#28594}

Patch Set 1 #

Patch Set 2 : revert some unnecessary changes #

Patch Set 3 : use flag instead of instance type #

Patch Set 4 : . #

Patch Set 5 : fix dumb typo #

Total comments: 5

Patch Set 6 : remove shared allocator #

Patch Set 7 : switch SharedFlag to enum class #

Patch Set 8 : fix embedder index #

Patch Set 9 : merge master #

Unified diffs Side-by-side diffs Delta from patch set Stats (+550 lines, -256 lines) Patch
M BUILD.gn View 1 2 1 chunk +2 lines, -1 line 0 comments Download
M include/v8.h View 1 2 3 4 5 6 7 8 5 chunks +116 lines, -2 lines 0 comments Download
M src/api.h View 3 chunks +5 lines, -0 lines 0 comments Download
M src/api.cc View 1 2 3 4 5 6 7 8 8 chunks +83 lines, -6 lines 0 comments Download
M src/arraybuffer.js View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M src/bootstrapper.cc View 1 2 3 4 5 6 7 3 chunks +17 lines, -0 lines 0 comments Download
M src/contexts.h View 1 2 3 4 5 6 7 2 chunks +2 lines, -0 lines 0 comments Download
M src/factory.h View 1 2 3 4 5 6 1 chunk +2 lines, -1 line 0 comments Download
M src/factory.cc View 1 2 3 4 5 6 7 2 chunks +6 lines, -3 lines 0 comments Download
M src/flag-definitions.h View 1 2 3 4 5 6 7 1 chunk +2 lines, -1 line 0 comments Download
A src/harmony-sharedarraybuffer.js View 1 2 3 4 5 6 1 chunk +56 lines, -0 lines 0 comments Download
M src/macros.py View 1 2 3 4 5 6 2 chunks +5 lines, -0 lines 0 comments Download
M src/objects.h View 1 2 3 4 5 6 7 3 chunks +8 lines, -0 lines 0 comments Download
M src/objects-inl.h View 1 2 3 4 5 6 7 1 chunk +8 lines, -0 lines 0 comments Download
M src/runtime/runtime.h View 1 2 3 4 5 6 2 chunks +7 lines, -6 lines 0 comments Download
M src/runtime/runtime-typedarray.cc View 1 2 3 4 5 6 8 chunks +16 lines, -8 lines 0 comments Download
M src/typedarray.js View 1 2 2 chunks +2 lines, -1 line 0 comments Download
M test/cctest/test-api.cc View 1 2 3 4 5 6 7 8 1 chunk +130 lines, -0 lines 0 comments Download
A + test/mjsunit/harmony/sharedarraybuffer.js View 1 2 18 chunks +80 lines, -225 lines 0 comments Download
M tools/gyp/v8.gyp View 1 2 1 chunk +2 lines, -1 line 0 comments Download

Messages

Total messages: 29 (8 generated)
binji
FYI: here is an example CL where the TypedArray hierarchy is not split.
5 years, 7 months ago (2015-05-14 19:00:02 UTC) #1
binji
PTAL, changed this to use a flag on JSArrayBuffer instead of introducing a new InstanceType.
5 years, 7 months ago (2015-05-21 14:05:21 UTC) #3
jochen (gone - plz use gerrit)
https://codereview.chromium.org/1136553006/diff/80001/include/v8.h File include/v8.h (right): https://codereview.chromium.org/1136553006/diff/80001/include/v8.h#newcode5171 include/v8.h:5171: ArrayBuffer::Allocator* shared_array_buffer_allocator; why do we need a separate allocator? ...
5 years, 7 months ago (2015-05-22 08:37:47 UTC) #4
binji
https://codereview.chromium.org/1136553006/diff/80001/include/v8.h File include/v8.h (right): https://codereview.chromium.org/1136553006/diff/80001/include/v8.h#newcode5171 include/v8.h:5171: ArrayBuffer::Allocator* shared_array_buffer_allocator; On 2015/05/22 at 08:37:47, jochen wrote: > ...
5 years, 7 months ago (2015-05-22 09:27:34 UTC) #5
Jarin
https://codereview.chromium.org/1136553006/diff/80001/src/objects.h File src/objects.h (right): https://codereview.chromium.org/1136553006/diff/80001/src/objects.h#newcode177 src/objects.h:177: enum SharedFlag { NOT_SHARED, SHARED }; On 2015/05/22 09:27:34, ...
5 years, 7 months ago (2015-05-22 09:37:35 UTC) #7
jochen (gone - plz use gerrit)
On 2015/05/22 at 09:37:35, jarin wrote: > https://codereview.chromium.org/1136553006/diff/80001/src/objects.h > File src/objects.h (right): > > https://codereview.chromium.org/1136553006/diff/80001/src/objects.h#newcode177 ...
5 years, 7 months ago (2015-05-22 09:41:16 UTC) #8
binji
On 2015/05/22 at 09:41:16, jochen wrote: > On 2015/05/22 at 09:37:35, jarin wrote: > > ...
5 years, 7 months ago (2015-05-22 10:12:01 UTC) #9
jochen (gone - plz use gerrit)
lgtm please also wait for jarin@
5 years, 7 months ago (2015-05-22 11:13:10 UTC) #10
Jarin
On 2015/05/22 11:13:10, jochen wrote: > lgtm > > please also wait for jarin@ lgtm. ...
5 years, 7 months ago (2015-05-22 11:45:19 UTC) #11
binji
On 2015/05/22 at 11:45:19, jarin wrote: > On 2015/05/22 11:13:10, jochen wrote: > > lgtm ...
5 years, 7 months ago (2015-05-22 11:52:33 UTC) #12
binji
On 2015/05/22 at 11:52:33, binji wrote: > On 2015/05/22 at 11:45:19, jarin wrote: > > ...
5 years, 7 months ago (2015-05-22 11:59:18 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1136553006/120001
5 years, 7 months ago (2015-05-22 12:00:02 UTC) #15
commit-bot: I haz the power
Committed patchset #7 (id:120001)
5 years, 7 months ago (2015-05-22 12:07:09 UTC) #16
commit-bot: I haz the power
Patchset 7 (id:??) landed as https://crrev.com/57170bff7baf341c666252a7f6a49e9c08d51263 Cr-Commit-Position: refs/heads/master@{#28588}
5 years, 7 months ago (2015-05-22 12:07:28 UTC) #17
Yang
A revert of this CL (patchset #7 id:120001) has been created in https://codereview.chromium.org/1149203003/ by yangguo@chromium.org. ...
5 years, 7 months ago (2015-05-22 12:17:34 UTC) #18
binji
On 2015/05/22 at 12:17:34, yangguo wrote: > A revert of this CL (patchset #7 id:120001) ...
5 years, 7 months ago (2015-05-22 12:43:59 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1136553006/140001
5 years, 7 months ago (2015-05-22 12:45:54 UTC) #22
commit-bot: I haz the power
Try jobs failed on following builders: v8_linux64_avx2_rel on tryserver.v8 (JOB_FAILED, http://build.chromium.org/p/tryserver.v8/builders/v8_linux64_avx2_rel/builds/672)
5 years, 7 months ago (2015-05-22 12:51:08 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1136553006/160001
5 years, 7 months ago (2015-05-22 13:01:03 UTC) #27
commit-bot: I haz the power
Committed patchset #9 (id:160001)
5 years, 7 months ago (2015-05-22 13:43:47 UTC) #28
commit-bot: I haz the power
5 years, 7 months ago (2015-05-22 13:44:00 UTC) #29
Message was sent while issue was closed.
Patchset 9 (id:??) landed as
https://crrev.com/aff8ebb0ebe165dceb03b567fe54633cf3f0a1f7
Cr-Commit-Position: refs/heads/master@{#28594}

Powered by Google App Engine
This is Rietveld 408576698