OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 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 #ifndef WASM_RUN_UTILS_H | 5 #ifndef WASM_RUN_UTILS_H |
6 #define WASM_RUN_UTILS_H | 6 #define WASM_RUN_UTILS_H |
7 | 7 |
8 #include <setjmp.h> | 8 #include <setjmp.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 #include <stdlib.h> | 10 #include <stdlib.h> |
(...skipping 584 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
595 } | 595 } |
596 | 596 |
597 Handle<Code> Compile() { | 597 Handle<Code> Compile() { |
598 CallDescriptor* desc = descriptor(); | 598 CallDescriptor* desc = descriptor(); |
599 if (kPointerSize == 4) { | 599 if (kPointerSize == 4) { |
600 desc = testing_module_->GetI32WasmCallDescriptor(this->zone(), desc); | 600 desc = testing_module_->GetI32WasmCallDescriptor(this->zone(), desc); |
601 } | 601 } |
602 CompilationInfo info(CStrVector("wasm"), this->isolate(), this->zone(), | 602 CompilationInfo info(CStrVector("wasm"), this->isolate(), this->zone(), |
603 Code::ComputeFlags(Code::WASM_FUNCTION)); | 603 Code::ComputeFlags(Code::WASM_FUNCTION)); |
604 std::unique_ptr<CompilationJob> job(Pipeline::NewWasmCompilationJob( | 604 std::unique_ptr<CompilationJob> job(Pipeline::NewWasmCompilationJob( |
605 &info, &jsgraph, desc, &source_position_table_, nullptr)); | 605 &info, &jsgraph, desc, &source_position_table_, nullptr, false)); |
606 if (job->ExecuteJob() != CompilationJob::SUCCEEDED || | 606 if (job->ExecuteJob() != CompilationJob::SUCCEEDED || |
607 job->FinalizeJob() != CompilationJob::SUCCEEDED) | 607 job->FinalizeJob() != CompilationJob::SUCCEEDED) |
608 return Handle<Code>::null(); | 608 return Handle<Code>::null(); |
609 | 609 |
610 Handle<Code> code = info.code(); | 610 Handle<Code> code = info.code(); |
611 | 611 |
612 // Deopt data holds <WeakCell<wasm_instance>, func_index>. | 612 // Deopt data holds <WeakCell<wasm_instance>, func_index>. |
613 DCHECK(code->deoptimization_data() == nullptr || | 613 DCHECK(code->deoptimization_data() == nullptr || |
614 code->deoptimization_data()->length() == 0); | 614 code->deoptimization_data()->length() == 0); |
615 Handle<FixedArray> deopt_data = | 615 Handle<FixedArray> deopt_data = |
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
837 void RunWasm_##name(WasmExecutionMode execution_mode) | 837 void RunWasm_##name(WasmExecutionMode execution_mode) |
838 | 838 |
839 #define WASM_EXEC_COMPILED_TEST(name) \ | 839 #define WASM_EXEC_COMPILED_TEST(name) \ |
840 void RunWasm_##name(WasmExecutionMode execution_mode); \ | 840 void RunWasm_##name(WasmExecutionMode execution_mode); \ |
841 TEST(RunWasmCompiled_##name) { RunWasm_##name(kExecuteCompiled); } \ | 841 TEST(RunWasmCompiled_##name) { RunWasm_##name(kExecuteCompiled); } \ |
842 void RunWasm_##name(WasmExecutionMode execution_mode) | 842 void RunWasm_##name(WasmExecutionMode execution_mode) |
843 | 843 |
844 } // namespace | 844 } // namespace |
845 | 845 |
846 #endif | 846 #endif |
OLD | NEW |