Chromium Code Reviews

Unified Diff: test/cctest/wasm/test-run-wasm-module.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.
Jump to:
View side-by-side diff with in-line comments
Index: test/cctest/wasm/test-run-wasm-module.cc
diff --git a/test/cctest/wasm/test-run-wasm-module.cc b/test/cctest/wasm/test-run-wasm-module.cc
index 79406165a634bcceca78bd4e3aa4e34989da8880..ad183b6b8c64862b53aaaab42bc5cdd01817ae44 100644
--- a/test/cctest/wasm/test-run-wasm-module.cc
+++ b/test/cctest/wasm/test-run-wasm-module.cc
@@ -148,8 +148,7 @@ TEST(Run_WasmModule_CheckMemoryIsZero) {
WASM_LOAD_MEM(MachineType::Int32(), WASM_GET_LOCAL(localIndex)),
WASM_BRV(2, WASM_I8(-1)), WASM_INC_LOCAL_BY(localIndex, 4))),
WASM_I8(11))};
- uint32_t local_indices[] = {7, 18, 24, 27};
- f->EmitCode(code, sizeof(code), local_indices, sizeof(local_indices) / 4);
+ f->EmitCode(code, sizeof(code), nullptr, 0);
WasmModuleWriter* writer = builder->Build(&zone);
TestModule(writer->WriteTo(&zone), 11);
}
@@ -174,8 +173,7 @@ TEST(Run_WasmModule_CallMain_recursive) {
WASM_INC_LOCAL(localIndex)),
WASM_BRV(1, WASM_CALL_FUNCTION0(0))),
WASM_BRV(0, WASM_I8(55))))};
- uint32_t local_indices[] = {3, 11, 21, 24};
- f->EmitCode(code, sizeof(code), local_indices, sizeof(local_indices) / 4);
+ f->EmitCode(code, sizeof(code), nullptr, 0);
WasmModuleWriter* writer = builder->Build(&zone);
TestModule(writer->WriteTo(&zone), 55);
}

Powered by Google App Engine