Commit Graph

12 Commits

Author SHA1 Message Date
titzer
91802542d5 [wasm] Rename ExprBoolNot to ExprI32Eqz.
R=bradnelson@chromium.org, binji@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1741393002

Cr-Commit-Position: refs/heads/master@{#34350}
2016-02-28 19:02:24 +00:00
titzer
915ae08dd5 [wasm] Add support for import section.
This CL introduces an import section that names functions to be imported
as well as a CallImport bytecode to call imports from this table.

R=binji@chromium.org,bradnelson@chromium.org
LOG=Y
BUG=chromium:575167

Review URL: https://codereview.chromium.org/1709653002

Cr-Commit-Position: refs/heads/master@{#34157}
2016-02-19 14:58:43 +00:00
binji
7a004a02da [wasm] Put the condition last in kExprBrIf.
To bring V8 into line with the proposed design changes in:

 https://github.com/WebAssembly/design/pull/489

(This CL is forked from https://codereview.chromium.org/1634673002/.
That CL doesn't merge cleanly, and I can't update it.)

TBR=titzer@chromium.org
LOG=Y
BUG=chromium:575167

Review URL: https://codereview.chromium.org/1682443002

Cr-Commit-Position: refs/heads/master@{#33828}
2016-02-08 21:19:26 +00:00
titzer
59b922fb4e [wasm] Put the condition last in kExprSelect.
To bring V8 into line with the proposed design changes in:

 https://github.com/WebAssembly/design/pull/489

R=ahaas@chromium.org,bradnelson@chromium.org
LOG=Y
BUG=chromium:575167
BUG=v8:4735

Review URL: https://codereview.chromium.org/1624323003

Cr-Commit-Position: refs/heads/master@{#33776}
2016-02-05 13:34:53 +00:00
titzer
9c006b724e [wasm] Refactor handling of operands to bytecodes.
This cleans up and simplifyies handling the bytes followin an opcode
with little helper structs that will be useful in the interpreter and
already have been in keeping OpcodeArity and OpcodeLength up to date
with the decoder.

R=bradnelson@chromium.org, ahaas@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1664883002

Cr-Commit-Position: refs/heads/master@{#33723}
2016-02-04 10:16:47 +00:00
titzer
007e14ce4b [wasm] Rename local_int32_count to local_i32_count and similar textual replacements.
R=ahaas@chromium.org,jfb@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1661713003

Cr-Commit-Position: refs/heads/master@{#33702}
2016-02-03 11:06:45 +00:00
titzer
716bc803a3 [wasm] Fix misaligned accesses and endianness issues in decoders.
R=ahaas@chromium.org,bradnelson@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1644023002

Cr-Commit-Position: refs/heads/master@{#33595}
2016-01-28 19:24:39 +00:00
titzer
d51398feea [wasm] Fix decoding failures for tableswitch.
R=ahaas@chromium.org, bradnelson@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1642043002

Cr-Commit-Position: refs/heads/master@{#33581}
2016-01-28 12:54:42 +00:00
titzer
1e1f72f3a6 [wasm] Factor out WasmModuleInstance from ModuleEnv.
R=ahaas@chromium.org,bradnelson@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1637923002

Cr-Commit-Position: refs/heads/master@{#33541}
2016-01-27 11:04:40 +00:00
bradnelson
4c22608133 Disable more crashing / failing wasm tests.
Disabling some tests for ppc, mips, arm.

BUG=
R=bbudge@chromium.org

Review URL: https://codereview.chromium.org/1564553002

Cr-Commit-Position: refs/heads/master@{#33131}
2016-01-05 23:33:12 +00:00
bradnelson
879b21a43a Have WasmModule free it's own memory.
Make WasmModule free it's own memory, avoid mixing stack and
heap allocations in tests. This fixes several memory leaks.

Fix several signed compare issues.
Fix several floating point warnings.

Don't setup heap as external, as then the GC can't collect it.

Disable some tests that fail under ASAN.

R=ahaas@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1538543002

Cr-Commit-Position: refs/heads/master@{#32948}
2015-12-17 13:27:34 +00:00
titzer
4c5b3609fd Initial import of v8-native WASM.
As discussed in person, this adds the code from v8-native-prototype into
V8 proper, guarded by GYP flags that do not build the code by default.
Passing wasm=on to 'make' or setting v8_wasm as a GYP flag activates
building of this code.

An additional header file is added to and exported from the compiler
directory, src/compiler/wasm-compiler.h. This exposes a limited interface
with opaque Node and Graph types to the decoder to build TF graphs, as
well as functions to compile WASM graphs.

The mjsunit tests added are blacklisted because they fail without the
WASM object exposed to JS, which is also disabled by the build config
option.

This corresponds closely to 5981e06ebc, with some formatting fixes and moving some files into src/compiler.

R=mstarzinger@chromium.org, bradnelson@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1504713014

Cr-Commit-Position: refs/heads/master@{#32794}
2015-12-11 12:27:05 +00:00