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

Unified Diff: test/cctest/wasm/wasm-run-utils.h

Issue 2594993002: [wasm] Rename wasm::LocalType to wasm::ValueType and kAst* to kWasm* (Closed)
Patch Set: Fix inspector tests Created 4 years 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 | « test/cctest/wasm/test-run-wasm-simd-lowering.cc ('k') | test/common/wasm/test-signatures.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/wasm/wasm-run-utils.h
diff --git a/test/cctest/wasm/wasm-run-utils.h b/test/cctest/wasm/wasm-run-utils.h
index a61c8b306133ab8cbb094a01ae833d109e8d8bea..8c489c9cc4291e781d0d8aa12ec9bfce1c94f3cd 100644
--- a/test/cctest/wasm/wasm-run-utils.h
+++ b/test/cctest/wasm/wasm-run-utils.h
@@ -121,7 +121,7 @@ class TestingModule : public ModuleEnv {
template <typename T>
T* AddGlobal(
- LocalType type = WasmOpcodes::LocalTypeFor(MachineTypeForC<T>())) {
+ ValueType type = WasmOpcodes::ValueTypeFor(MachineTypeForC<T>())) {
const WasmGlobal* global = AddGlobal(type);
return reinterpret_cast<T*>(instance->globals_start + global->offset);
}
@@ -297,7 +297,7 @@ class TestingModule : public ModuleEnv {
WasmInterpreter* interpreter_;
Handle<WasmInstanceObject> instance_object_;
- const WasmGlobal* AddGlobal(LocalType type) {
+ const WasmGlobal* AddGlobal(ValueType type) {
byte size = WasmOpcodes::MemSize(WasmOpcodes::MachineTypeFor(type));
global_offset = (global_offset + size - 1) & ~(size - 1); // align
module_.globals.push_back(
@@ -524,7 +524,7 @@ class WasmFunctionCompiler : private GraphAndBuilders {
testing_module_->SetFunctionCode(function_index(), code);
}
- byte AllocateLocal(LocalType type) {
+ byte AllocateLocal(ValueType type) {
uint32_t index = local_decls.AddLocals(1, type);
byte result = static_cast<byte>(index);
DCHECK_EQ(index, result);
@@ -636,7 +636,7 @@ class WasmRunnerBase : public HandleAndZoneScope {
return *functions_.back();
}
- byte AllocateLocal(LocalType type) {
+ byte AllocateLocal(ValueType type) {
return functions_[0]->AllocateLocal(type);
}
@@ -663,16 +663,16 @@ class WasmRunnerBase : public HandleAndZoneScope {
int param_count = param_types.length();
// Allocate storage array in zone.
- LocalType* sig_types =
- zone_.NewArray<LocalType>(return_count + param_count);
+ ValueType* sig_types =
+ zone_.NewArray<ValueType>(return_count + param_count);
// Convert machine types to local types, and check that there are no
// MachineType::None()'s in the parameters.
int idx = 0;
- if (return_count) sig_types[idx++] = WasmOpcodes::LocalTypeFor(return_type);
+ if (return_count) sig_types[idx++] = WasmOpcodes::ValueTypeFor(return_type);
for (MachineType param : param_types) {
CHECK_NE(MachineType::None(), param);
- sig_types[idx++] = WasmOpcodes::LocalTypeFor(param);
+ sig_types[idx++] = WasmOpcodes::ValueTypeFor(param);
}
return new (&zone_) FunctionSig(return_count, param_count, sig_types);
}
« no previous file with comments | « test/cctest/wasm/test-run-wasm-simd-lowering.cc ('k') | test/common/wasm/test-signatures.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698