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

Side by Side Diff: src/compiler/wasm-compiler.cc

Issue 1717993002: [wasm] Fix bug in CallImport. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 10 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 unified diff | Download patch
« no previous file with comments | « no previous file | test/mjsunit/wasm/import-table.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/compiler/wasm-compiler.h" 5 #include "src/compiler/wasm-compiler.h"
6 6
7 #include "src/isolate-inl.h" 7 #include "src/isolate-inl.h"
8 8
9 #include "src/base/platform/platform.h" 9 #include "src/base/platform/platform.h"
10 10
(...skipping 1491 matching lines...) Expand 10 before | Expand all | Expand 10 after
1502 wasm::FunctionSig* sig = module_->GetFunctionSignature(index); 1502 wasm::FunctionSig* sig = module_->GetFunctionSignature(index);
1503 1503
1504 return BuildWasmCall(sig, args); 1504 return BuildWasmCall(sig, args);
1505 } 1505 }
1506 1506
1507 Node* WasmGraphBuilder::CallImport(uint32_t index, Node** args) { 1507 Node* WasmGraphBuilder::CallImport(uint32_t index, Node** args) {
1508 DCHECK_NULL(args[0]); 1508 DCHECK_NULL(args[0]);
1509 1509
1510 // Add code object as constant. 1510 // Add code object as constant.
1511 args[0] = Constant(module_->GetImportCode(index)); 1511 args[0] = Constant(module_->GetImportCode(index));
1512 wasm::FunctionSig* sig = module_->GetFunctionSignature(index); 1512 wasm::FunctionSig* sig = module_->GetImportSignature(index);
1513 1513
1514 return BuildWasmCall(sig, args); 1514 return BuildWasmCall(sig, args);
1515 } 1515 }
1516 1516
1517 Node* WasmGraphBuilder::CallIndirect(uint32_t index, Node** args) { 1517 Node* WasmGraphBuilder::CallIndirect(uint32_t index, Node** args) {
1518 DCHECK_NOT_NULL(args[0]); 1518 DCHECK_NOT_NULL(args[0]);
1519 DCHECK(module_ && module_->instance); 1519 DCHECK(module_ && module_->instance);
1520 1520
1521 MachineOperatorBuilder* machine = jsgraph()->machine(); 1521 MachineOperatorBuilder* machine = jsgraph()->machine();
1522 1522
(...skipping 684 matching lines...) Expand 10 before | Expand all | Expand 10 after
2207 module_env->module->GetName(function.name_offset)); 2207 module_env->module->GetName(function.name_offset));
2208 } 2208 }
2209 2209
2210 return code; 2210 return code;
2211 } 2211 }
2212 2212
2213 2213
2214 } // namespace compiler 2214 } // namespace compiler
2215 } // namespace internal 2215 } // namespace internal
2216 } // namespace v8 2216 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | test/mjsunit/wasm/import-table.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698