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

Issue 2416543002: [wasm] Fix bounds check for zero initial memory. (Closed)

Created:
4 years, 2 months ago by gdeepti
Modified:
4 years, 2 months ago
CC:
v8-reviews_googlegroups.com, v8-mips-ports_googlegroups.com, v8-x87-ports_googlegroups.com, v8-ppc-ports_googlegroups.com
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

[wasm] Fix bounds check for zero initial memory. Currently when memory size references are updated with zero initial memory during GrowMemory/Relocation of Instance objects, the bounds check does not take into account the size of memtype. R=titzer@chromium.org, bradnelson@chromium.org Committed: https://crrev.com/70416a2b360c0d993cffb48284b143d484d1e290 Committed: https://crrev.com/3d6f7743528ba5fd5524376a23711fb87df3d5fc Cr-Original-Commit-Position: refs/heads/master@{#40326} Cr-Commit-Position: refs/heads/master@{#40329}

Patch Set 1 #

Total comments: 8

Patch Set 2 : Remove additional reloc modes, refactor #

Patch Set 3 : Cleanup #

Patch Set 4 : Fix formatting #

Patch Set 5 : Fix test #

Patch Set 6 : Add aTODO #

Total comments: 4

Patch Set 7 : Brad's review #

Patch Set 8 : Rebase #

Total comments: 4

Patch Set 9 : Review comments #

Total comments: 4

Patch Set 10 : Review #

Patch Set 11 : Cleanup #

Patch Set 12 : Fix bot failure #

Unified diffs Side-by-side diffs Delta from patch set Stats (+131 lines, -60 lines) Patch
M src/assembler.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +2 lines, -3 lines 0 comments Download
M src/compiler/wasm-compiler.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +7 lines, -10 lines 0 comments Download
M src/wasm/wasm-module.h View 1 2 3 4 5 6 1 chunk +0 lines, -5 lines 0 comments Download
M src/wasm/wasm-module.cc View 1 2 3 4 5 6 3 chunks +5 lines, -39 lines 0 comments Download
M test/mjsunit/wasm/grow-memory.js View 1 2 3 4 5 6 2 chunks +86 lines, -3 lines 0 comments Download
M test/mjsunit/wasm/import-memory.js View 1 chunk +31 lines, -0 lines 0 comments Download

Messages

Total messages: 68 (48 generated)
gdeepti
4 years, 2 months ago (2016-10-12 07:55:12 UTC) #3
gdeepti
4 years, 2 months ago (2016-10-12 07:55:15 UTC) #4
bradn
lgtm w/ suggestions https://codereview.chromium.org/2416543002/diff/1/src/assembler.cc File src/assembler.cc (right): https://codereview.chromium.org/2416543002/diff/1/src/assembler.cc#newcode371 src/assembler.cc:371: DCHECK(rmode_ == RelocInfo::WASM_MEMORY_BYTE_SIZE_REFERENCE); Handle explicit and ...
4 years, 2 months ago (2016-10-12 18:50:45 UTC) #8
gdeepti
PTAL. Changed implementation to use one additional RelocInfo mode instead of one for each memtype. ...
4 years, 2 months ago (2016-10-13 08:43:00 UTC) #17
bradn
https://codereview.chromium.org/2416543002/diff/100001/src/compiler/wasm-compiler.cc File src/compiler/wasm-compiler.cc (right): https://codereview.chromium.org/2416543002/diff/100001/src/compiler/wasm-compiler.cc#newcode2852 src/compiler/wasm-compiler.cc:2852: uint32_t size = module_->instance->mem_size; Shouldn't this be from min_mem_pages ...
4 years, 2 months ago (2016-10-13 22:43:41 UTC) #22
bradn
lgtm https://codereview.chromium.org/2416543002/diff/140001/src/compiler/wasm-compiler.cc File src/compiler/wasm-compiler.cc (right): https://codereview.chromium.org/2416543002/diff/140001/src/compiler/wasm-compiler.cc#newcode2864 src/compiler/wasm-compiler.cc:2864: if (size == 0 || offset >= size ...
4 years, 2 months ago (2016-10-14 01:17:07 UTC) #29
gdeepti
https://codereview.chromium.org/2416543002/diff/100001/src/compiler/wasm-compiler.cc File src/compiler/wasm-compiler.cc (right): https://codereview.chromium.org/2416543002/diff/100001/src/compiler/wasm-compiler.cc#newcode2852 src/compiler/wasm-compiler.cc:2852: uint32_t size = module_->instance->mem_size; On 2016/10/13 22:43:41, bradn wrote: ...
4 years, 2 months ago (2016-10-14 01:28:44 UTC) #32
bradn
https://codereview.chromium.org/2416543002/diff/160001/src/compiler/wasm-compiler.cc File src/compiler/wasm-compiler.cc (right): https://codereview.chromium.org/2416543002/diff/160001/src/compiler/wasm-compiler.cc#newcode2863 src/compiler/wasm-compiler.cc:2863: size_t effective_size; Move down to the initialization. https://codereview.chromium.org/2416543002/diff/160001/src/compiler/wasm-compiler.cc#newcode2880 src/compiler/wasm-compiler.cc:2880: ...
4 years, 2 months ago (2016-10-14 01:42:38 UTC) #33
gdeepti
https://codereview.chromium.org/2416543002/diff/160001/src/compiler/wasm-compiler.cc File src/compiler/wasm-compiler.cc (right): https://codereview.chromium.org/2416543002/diff/160001/src/compiler/wasm-compiler.cc#newcode2863 src/compiler/wasm-compiler.cc:2863: size_t effective_size; On 2016/10/14 01:42:38, bradn wrote: > Move ...
4 years, 2 months ago (2016-10-14 01:57:11 UTC) #34
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/2416543002/200001
4 years, 2 months ago (2016-10-14 02:27:52 UTC) #45
commit-bot: I haz the power
No L-G-T-M from a valid reviewer yet. CQ run can only be started by full ...
4 years, 2 months ago (2016-10-14 02:27:55 UTC) #47
gdeepti
4 years, 2 months ago (2016-10-14 16:58:32 UTC) #49
Mircea Trofin
lgtm
4 years, 2 months ago (2016-10-14 20:54:06 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/2416543002/200001
4 years, 2 months ago (2016-10-14 20:58:48 UTC) #52
commit-bot: I haz the power
Committed patchset #11 (id:200001)
4 years, 2 months ago (2016-10-14 21:01:30 UTC) #53
commit-bot: I haz the power
Patchset 11 (id:??) landed as https://crrev.com/70416a2b360c0d993cffb48284b143d484d1e290 Cr-Commit-Position: refs/heads/master@{#40326}
4 years, 2 months ago (2016-10-14 21:02:04 UTC) #55
gdeepti
A revert of this CL (patchset #11 id:200001) has been created in https://codereview.chromium.org/2416393002/ by gdeepti@chromium.org. ...
4 years, 2 months ago (2016-10-14 22:32:24 UTC) #56
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/2416543002/220001
4 years, 2 months ago (2016-10-14 23:51:23 UTC) #64
commit-bot: I haz the power
Committed patchset #12 (id:220001)
4 years, 2 months ago (2016-10-14 23:54:48 UTC) #66
commit-bot: I haz the power
4 years, 2 months ago (2016-10-14 23:54:59 UTC) #68
Message was sent while issue was closed.
Patchset 12 (id:??) landed as
https://crrev.com/3d6f7743528ba5fd5524376a23711fb87df3d5fc
Cr-Commit-Position: refs/heads/master@{#40329}

Powered by Google App Engine
This is Rietveld 408576698