v8/test/cctest/asmjs
jpp 060d984c94 [wasm][asm2wasm] Fixes a bug in 8-bit heap view accesses.
The bug was caused when validating expressions

X >> 0

for indexing into 8-bit heap views. If X was not an intish, the 'normal'
validation path would fail. That, however, left the type of X registered
in the AsmTyper::node_types_ member.

Later, in the 'lenient' code path for 8-bit views, the entire X >> 0
expression would be validated, which would cause X to be validated
again, at which point AsmTyper::SetTypeOf() would DCHECK because the
supplied node already had a type associated with it.

The fix was to simply FAIL() when X is not an intish. This is safe
because if X is not an intish, then

Validate(>>, !intish, FixNum)

will also fail.

BUG= https://bugs.chromium.org/p/chromium/issues/detail?id=628803
BUG= https://bugs.chromium.org/p/v8/issues/detail?id=4203
TEST= cctest/asmjs/test-asm-typer.cc
LOG= N

Review-Url: https://codereview.chromium.org/2181723002
Cr-Commit-Position: refs/heads/master@{#38053}
2016-07-26 14:05:05 +00:00
..
OWNERS V8. ASM-2-WASM. Validator V2. 2016-07-12 23:12:08 +00:00
test-asm-typer.cc [wasm][asm2wasm] Fixes a bug in 8-bit heap view accesses. 2016-07-26 14:05:05 +00:00