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

Issue 2483053005: [wasm] Check data segments for zero-sized memory. (Closed)

Created:
4 years, 1 month ago by ahaas
Modified:
4 years, 1 month ago
Reviewers:
titzer, rossberg
CC:
v8-reviews_googlegroups.com
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

[wasm] Check data segments for zero-sized memory. According to the spec data segments are allowed even if the memory size is zero. However, if one of the data segments has a length greater than 0, then module instantiation should fail. I also changed the exception type in LoadDataSegments to TypeError, because that's the exception type for all exceptions which can happen during instantiation. R=titzer@chromium.org, rossberg@chromium.org TEST=cctest/test-run-wasm-module/EmptyMemoryEmptyDataSegment, cctest/test-run-wasm-module/EmptyMemoryNonEmptyDataSegment Committed: https://crrev.com/e3c7324a2e0bf7317fd12302a02ed4bddc856a8c Cr-Commit-Position: refs/heads/master@{#40922}

Patch Set 1 #

Total comments: 2

Patch Set 2 : Comments addressed #

Patch Set 3 : Rebase #

Patch Set 4 : remove redundant '(' ')' #

Patch Set 5 : Use a different formatter string #

Unified diffs Side-by-side diffs Delta from patch set Stats (+115 lines, -7 lines) Patch
M src/wasm/wasm-module.cc View 1 2 3 4 3 chunks +12 lines, -7 lines 0 comments Download
M test/cctest/wasm/test-run-wasm-module.cc View 1 1 chunk +103 lines, -0 lines 0 comments Download

Messages

Total messages: 30 (23 generated)
ahaas
4 years, 1 month ago (2016-11-09 17:06:39 UTC) #1
titzer
https://codereview.chromium.org/2483053005/diff/1/src/wasm/wasm-module.cc File src/wasm/wasm-module.cc (right): https://codereview.chromium.org/2483053005/diff/1/src/wasm/wasm-module.cc#newcode1152 src/wasm/wasm-module.cc:1152: } else if (!CheckDataSegmentsAreEmpty()) { Why not just call ...
4 years, 1 month ago (2016-11-09 17:20:31 UTC) #4
ahaas
https://codereview.chromium.org/2483053005/diff/1/src/wasm/wasm-module.cc File src/wasm/wasm-module.cc (right): https://codereview.chromium.org/2483053005/diff/1/src/wasm/wasm-module.cc#newcode1152 src/wasm/wasm-module.cc:1152: } else if (!CheckDataSegmentsAreEmpty()) { On 2016/11/09 at 17:20:31, ...
4 years, 1 month ago (2016-11-10 10:26:25 UTC) #9
titzer
On 2016/11/10 10:26:25, ahaas wrote: > https://codereview.chromium.org/2483053005/diff/1/src/wasm/wasm-module.cc > File src/wasm/wasm-module.cc (right): > > https://codereview.chromium.org/2483053005/diff/1/src/wasm/wasm-module.cc#newcode1152 > ...
4 years, 1 month ago (2016-11-10 10:31:53 UTC) #10
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/2483053005/80001
4 years, 1 month ago (2016-11-11 12:40:01 UTC) #27
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 1 month ago (2016-11-11 13:03:02 UTC) #28
commit-bot: I haz the power
4 years, 1 month ago (2016-11-17 22:30:36 UTC) #30
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/e3c7324a2e0bf7317fd12302a02ed4bddc856a8c
Cr-Commit-Position: refs/heads/master@{#40922}

Powered by Google App Engine
This is Rietveld 408576698