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

Unified Diff: test/cctest/wasm/test-run-wasm.cc

Issue 1775123003: [wasm] Encode immediates to Load and Store as varint. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/wasm/wasm-opcodes.h ('k') | test/cctest/wasm/test-run-wasm-module.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/wasm/test-run-wasm.cc
diff --git a/test/cctest/wasm/test-run-wasm.cc b/test/cctest/wasm/test-run-wasm.cc
index ec5042f9835857792dcf1ccc20c1cd1ee4002807..cda5ce3b6af3a8aeae8b2b2c2e5dfc7de5992278 100644
--- a/test/cctest/wasm/test-run-wasm.cc
+++ b/test/cctest/wasm/test-run-wasm.cc
@@ -1777,9 +1777,9 @@ TEST(Run_Wasm_CheckMachIntsZero) {
WasmRunner<uint32_t> r(&module, MachineType::Int32());
BUILD(r, kExprBlock, 2, kExprLoop, 1, kExprIf, kExprGetLocal, 0, kExprBr, 0,
- kExprIfElse, kExprI32LoadMem, 0, kExprGetLocal, 0, kExprBr, 2,
- kExprI8Const, 255, kExprSetLocal, 0, kExprI32Sub, kExprGetLocal, 0,
- kExprI8Const, 4, kExprI8Const, 0);
+ kExprIfElse, kExprI32LoadMem, ZERO_ALIGNMENT, ZERO_OFFSET,
+ kExprGetLocal, 0, kExprBr, 2, kExprI8Const, 255, kExprSetLocal, 0,
+ kExprI32Sub, kExprGetLocal, 0, kExprI8Const, 4, kExprI8Const, 0);
module.BlankMemory();
CHECK_EQ(0, r.Call((kNumElems - 1) * 4));
@@ -2558,7 +2558,7 @@ static void Run_WasmMixedCall_N(int start) {
std::vector<byte> code;
ADD_CODE(code,
static_cast<byte>(WasmOpcodes::LoadStoreOpcodeOf(result, true)),
- WasmOpcodes::LoadStoreAccessOf(false));
+ ZERO_ALIGNMENT, ZERO_OFFSET);
ADD_CODE(code, WASM_ZERO);
ADD_CODE(code, kExprCallFunction, static_cast<byte>(index));
@@ -2782,8 +2782,12 @@ TEST(Run_Wasm_LoadStoreI64_sx) {
byte* memory = module.AddMemoryElems<byte>(16);
WasmRunner<int64_t> r(&module);
- byte code[] = {kExprI64StoreMem, 0, kExprI8Const, 8,
- loads[m], 0, kExprI8Const, 0};
+ byte code[] = {kExprI64StoreMem, ZERO_ALIGNMENT,
+ ZERO_OFFSET, // --
+ kExprI8Const, 8, // --
+ loads[m], ZERO_ALIGNMENT,
+ ZERO_OFFSET, // --
+ kExprI8Const, 0}; // --
r.Build(code, code + arraysize(code));
« no previous file with comments | « src/wasm/wasm-opcodes.h ('k') | test/cctest/wasm/test-run-wasm-module.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698