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

Issue 2484623002: [wasm] Indirect calls without function table cause validation errors. (Closed)

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

Description

[wasm] Indirect calls without function table cause validation errors. The spec defines that indirect calls in WebAssembly code should cause a validation error if no function table exists. The CL contains the following changes: 1) Throw a validation error for indirect calls if the function table not exist. 2) Do not create TF nodes to throw a runtime error for indirect calls if the function table does not exist. 3) Fix existing unit tests by creating a dummy function table. 4) Add new a new test which tests that indirect calls without function table cause a validation error. R=rossberg@chromium.org CC=titzer@chromium.org TEST=unittests/AstDecoderTest.IndirectCallsWithoutTableCrash Committed: https://crrev.com/4db05d405b564a832476ffbe8e157bab7b608ae0 Cr-Commit-Position: refs/heads/master@{#40852}

Patch Set 1 #

Total comments: 2

Patch Set 2 : Put the validation into the Validate function #

Patch Set 3 : Fix another test #

Patch Set 4 : Add include #

Patch Set 5 : try to export symbols #

Unified diffs Side-by-side diffs Delta from patch set Stats (+32 lines, -32 lines) Patch
M src/compiler/wasm-compiler.cc View 1 chunk +1 line, -9 lines 0 comments Download
M src/wasm/ast-decoder.cc View 1 1 chunk +5 lines, -0 lines 0 comments Download
M src/wasm/signature-map.h View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M test/cctest/wasm/test-run-wasm.cc View 1 1 chunk +0 lines, -22 lines 0 comments Download
M test/mjsunit/wasm/trap-location.js View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M test/unittests/wasm/ast-decoder-unittest.cc View 1 2 3 6 chunks +24 lines, -0 lines 0 comments Download

Messages

Total messages: 35 (21 generated)
ahaas
4 years, 1 month ago (2016-11-07 09:15:27 UTC) #1
titzer
https://codereview.chromium.org/2484623002/diff/1/src/wasm/ast-decoder.cc File src/wasm/ast-decoder.cc (right): https://codereview.chromium.org/2484623002/diff/1/src/wasm/ast-decoder.cc#newcode1141 src/wasm/ast-decoder.cc:1141: if (Validate(pc_, operand) && module_->IsValidTable(table_index)) { Why not just ...
4 years, 1 month ago (2016-11-07 09:24:12 UTC) #5
ahaas
https://codereview.chromium.org/2484623002/diff/1/src/wasm/ast-decoder.cc File src/wasm/ast-decoder.cc (right): https://codereview.chromium.org/2484623002/diff/1/src/wasm/ast-decoder.cc#newcode1141 src/wasm/ast-decoder.cc:1141: if (Validate(pc_, operand) && module_->IsValidTable(table_index)) { On 2016/11/07 at ...
4 years, 1 month ago (2016-11-07 09:35:56 UTC) #10
titzer
On 2016/11/07 09:35:56, ahaas wrote: > https://codereview.chromium.org/2484623002/diff/1/src/wasm/ast-decoder.cc > File src/wasm/ast-decoder.cc (right): > > https://codereview.chromium.org/2484623002/diff/1/src/wasm/ast-decoder.cc#newcode1141 > ...
4 years, 1 month ago (2016-11-07 09:42:01 UTC) #11
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/2484623002/40001
4 years, 1 month ago (2016-11-07 12:34:42 UTC) #20
commit-bot: I haz the power
Committed patchset #3 (id:40001)
4 years, 1 month ago (2016-11-07 12:36:45 UTC) #21
Michael Achenbach
A revert of this CL (patchset #3 id:40001) has been created in https://codereview.chromium.org/2479283002/ by machenbach@chromium.org. ...
4 years, 1 month ago (2016-11-07 17:56:37 UTC) #22
Michael Achenbach
Reopened this to test failing trybot for reland.
4 years, 1 month ago (2016-11-07 18:03:52 UTC) #25
ahaas
On 2016/11/07 at 18:03:52, machenbach wrote: > Reopened this to test failing trybot for reland. ...
4 years, 1 month ago (2016-11-09 08:01:30 UTC) #26
titzer
On 2016/11/09 08:01:30, ahaas wrote: > On 2016/11/07 at 18:03:52, machenbach wrote: > > Reopened ...
4 years, 1 month ago (2016-11-09 08:09:58 UTC) #27
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/2484623002/80001
4 years, 1 month ago (2016-11-09 08:10:28 UTC) #29
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 1 month ago (2016-11-09 08:37:15 UTC) #31
commit-bot: I haz the power
Patchset 5 (id:??) landed as https://crrev.com/3de5204737d95c6d09fd2685b5d4e45641f5aa5e Cr-Commit-Position: refs/heads/master@{#40802}
4 years, 1 month ago (2016-11-17 22:24:39 UTC) #33
commit-bot: I haz the power
4 years, 1 month ago (2016-11-17 22:27:03 UTC) #35
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/4db05d405b564a832476ffbe8e157bab7b608ae0
Cr-Commit-Position: refs/heads/master@{#40852}

Powered by Google App Engine
This is Rietveld 408576698