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

Issue 2433273002: [wasm] Avoid double-serializing the wire bytes (Closed)

Created:
4 years, 2 months ago by Mircea Trofin
Modified:
4 years, 1 month ago
CC:
v8-reviews_googlegroups.com
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

[wasm] Avoid double-serializing the wire bytes Since the public API for deserialization is now just DeserializeOrCompile, we can trickle down the wire bytes to the deserialization logic, and avoid the need for duplicating the wire bytes when serializing. BUG=chromium:657316 Committed: https://crrev.com/91a5a219d46d592b49f6e963d308b2bbdc9b5b60 Cr-Commit-Position: refs/heads/master@{#40516}

Patch Set 1 #

Total comments: 4

Patch Set 2 : feedback #

Patch Set 3 : formatting #

Total comments: 2

Patch Set 4 : externalize/internalize buffer #

Total comments: 2

Patch Set 5 : fixes #

Patch Set 6 : fixes #

Patch Set 7 : removed unrelated changes #

Unified diffs Side-by-side diffs Delta from patch set Stats (+59 lines, -36 lines) Patch
M include/v8.h View 1 2 3 1 chunk +2 lines, -1 line 0 comments Download
M src/api.cc View 1 2 3 4 5 6 2 chunks +7 lines, -19 lines 0 comments Download
M src/heap/heap.h View 1 2 3 4 5 1 chunk +4 lines, -0 lines 0 comments Download
M src/runtime/runtime.h View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M src/runtime/runtime-test.cc View 1 2 3 4 1 chunk +18 lines, -2 lines 0 comments Download
M src/snapshot/code-serializer.h View 1 chunk +2 lines, -2 lines 0 comments Download
M src/snapshot/code-serializer.cc View 1 2 3 chunks +15 lines, -3 lines 0 comments Download
M test/mjsunit/wasm/compiled-module-serialization.js View 4 chunks +10 lines, -8 lines 0 comments Download

Messages

Total messages: 57 (40 generated)
Mircea Trofin
4 years, 2 months ago (2016-10-20 05:51:36 UTC) #5
Yang
https://chromiumcodereview.appspot.com/2433273002/diff/1/src/runtime/runtime-test.cc File src/runtime/runtime-test.cc (right): https://chromiumcodereview.appspot.com/2433273002/diff/1/src/runtime/runtime-test.cc#newcode770 src/runtime/runtime-test.cc:770: {reinterpret_cast<uint8_t*>(wire_bytes->backing_store()), I think it helps with readability if you ...
4 years, 2 months ago (2016-10-20 06:46:17 UTC) #9
Mircea Trofin
https://chromiumcodereview.appspot.com/2433273002/diff/1/src/runtime/runtime-test.cc File src/runtime/runtime-test.cc (right): https://chromiumcodereview.appspot.com/2433273002/diff/1/src/runtime/runtime-test.cc#newcode770 src/runtime/runtime-test.cc:770: {reinterpret_cast<uint8_t*>(wire_bytes->backing_store()), On 2016/10/20 06:46:17, Yang wrote: > I think ...
4 years, 2 months ago (2016-10-20 07:22:30 UTC) #13
titzer
https://chromiumcodereview.appspot.com/2433273002/diff/60001/src/runtime/runtime-test.cc File src/runtime/runtime-test.cc (right): https://chromiumcodereview.appspot.com/2433273002/diff/60001/src/runtime/runtime-test.cc#newcode771 src/runtime/runtime-test.cc:771: reinterpret_cast<uint8_t*>(wire_bytes->backing_store()), This raw pointer is unsafe unless the buffer ...
4 years, 2 months ago (2016-10-20 08:32:08 UTC) #18
Mircea Trofin
Michael, could you please check my use of the ArrayBuffer Register/Unregister APIs (see runtime-test.cc)? Is ...
4 years, 2 months ago (2016-10-20 16:06:42 UTC) #22
Michael Lippautz
The usage is (almost) correct and you will not create a copy for the unregister/register ...
4 years, 2 months ago (2016-10-20 16:20:31 UTC) #25
titzer
On 2016/10/20 16:20:31, Michael Lippautz wrote: > The usage is (almost) correct and you will ...
4 years, 2 months ago (2016-10-20 16:25:16 UTC) #26
Mircea Trofin
On 2016/10/20 16:25:16, titzer wrote: > On 2016/10/20 16:20:31, Michael Lippautz wrote: > > The ...
4 years, 2 months ago (2016-10-20 16:32:52 UTC) #29
Mircea Trofin
https://chromiumcodereview.appspot.com/2433273002/diff/80001/src/runtime/runtime-test.cc File src/runtime/runtime-test.cc (right): https://chromiumcodereview.appspot.com/2433273002/diff/80001/src/runtime/runtime-test.cc#newcode780 src/runtime/runtime-test.cc:780: wire_bytes->set_is_external(false); On 2016/10/20 16:20:31, Michael Lippautz wrote: > Please ...
4 years, 2 months ago (2016-10-20 16:33:42 UTC) #30
Mircea Trofin
PTAL. I need additional signoff from snaphshot folks, hence adding respective owners. Thanks!
4 years, 2 months ago (2016-10-20 18:10:42 UTC) #34
Michael Lippautz
heap/ lgtm although the methods on heap will likely never internalize/externalize for you but merely ...
4 years, 2 months ago (2016-10-20 19:20:46 UTC) #35
Yang
On 2016/10/20 19:20:46, Michael Lippautz wrote: > heap/ lgtm > > although the methods on ...
4 years, 2 months ago (2016-10-21 05:21:43 UTC) #36
Mircea Trofin
ptal - removed unrelated changes (thanks, Ben, for noticing!)
4 years, 2 months ago (2016-10-21 18:20:08 UTC) #47
titzer
On 2016/10/21 18:20:08, Mircea Trofin wrote: > ptal - removed unrelated changes (thanks, Ben, for ...
4 years, 2 months ago (2016-10-22 14:43:04 UTC) #50
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2433273002/180001
4 years, 2 months ago (2016-10-22 15:12:09 UTC) #53
commit-bot: I haz the power
Committed patchset #7 (id:180001)
4 years, 2 months ago (2016-10-22 15:14:50 UTC) #55
commit-bot: I haz the power
4 years, 1 month ago (2016-11-17 22:10:22 UTC) #57
Message was sent while issue was closed.
Patchset 7 (id:??) landed as
https://crrev.com/91a5a219d46d592b49f6e963d308b2bbdc9b5b60
Cr-Commit-Position: refs/heads/master@{#40516}

Powered by Google App Engine
This is Rietveld 408576698