OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_ARM. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_ARM. |
6 #if defined(TARGET_ARCH_ARM) | 6 #if defined(TARGET_ARCH_ARM) |
7 | 7 |
8 #include "vm/intermediate_language.h" | 8 #include "vm/intermediate_language.h" |
9 | 9 |
10 #include "vm/cpu.h" | 10 #include "vm/cpu.h" |
(...skipping 2375 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2386 deopt_id(), | 2386 deopt_id(), |
2387 kAllocateArrayRuntimeEntry, | 2387 kAllocateArrayRuntimeEntry, |
2388 2, | 2388 2, |
2389 locs()); | 2389 locs()); |
2390 __ Drop(2); | 2390 __ Drop(2); |
2391 __ Pop(kResultReg); | 2391 __ Pop(kResultReg); |
2392 __ Bind(&done); | 2392 __ Bind(&done); |
2393 return; | 2393 return; |
2394 } | 2394 } |
2395 } | 2395 } |
| 2396 const Code& stub = Code::Handle(compiler->isolate(), |
| 2397 StubCode::AllocateArray_entry()->code()); |
| 2398 compiler->AddStubCallTarget(stub); |
2396 compiler->GenerateCall(token_pos(), | 2399 compiler->GenerateCall(token_pos(), |
2397 *StubCode::AllocateArray_entry(), | 2400 *StubCode::AllocateArray_entry(), |
2398 RawPcDescriptors::kOther, | 2401 RawPcDescriptors::kOther, |
2399 locs()); | 2402 locs()); |
2400 ASSERT(locs()->out(0).reg() == kResultReg); | 2403 ASSERT(locs()->out(0).reg() == kResultReg); |
2401 } | 2404 } |
2402 | 2405 |
2403 | 2406 |
2404 LocationSummary* LoadFieldInstr::MakeLocationSummary(Zone* zone, | 2407 LocationSummary* LoadFieldInstr::MakeLocationSummary(Zone* zone, |
2405 bool opt) const { | 2408 bool opt) const { |
(...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2673 virtual void EmitNativeCode(FlowGraphCompiler* compiler) { | 2676 virtual void EmitNativeCode(FlowGraphCompiler* compiler) { |
2674 __ Comment("AllocateContextSlowPath"); | 2677 __ Comment("AllocateContextSlowPath"); |
2675 __ Bind(entry_label()); | 2678 __ Bind(entry_label()); |
2676 | 2679 |
2677 LocationSummary* locs = instruction_->locs(); | 2680 LocationSummary* locs = instruction_->locs(); |
2678 locs->live_registers()->Remove(locs->out(0)); | 2681 locs->live_registers()->Remove(locs->out(0)); |
2679 | 2682 |
2680 compiler->SaveLiveRegisters(locs); | 2683 compiler->SaveLiveRegisters(locs); |
2681 | 2684 |
2682 __ LoadImmediate(R1, instruction_->num_context_variables()); | 2685 __ LoadImmediate(R1, instruction_->num_context_variables()); |
| 2686 const Code& stub = Code::Handle(compiler->isolate(), |
| 2687 StubCode::AllocateContext_entry()->code()); |
| 2688 compiler->AddStubCallTarget(stub); |
2683 compiler->GenerateCall(instruction_->token_pos(), | 2689 compiler->GenerateCall(instruction_->token_pos(), |
2684 *StubCode::AllocateContext_entry(), | 2690 *StubCode::AllocateContext_entry(), |
2685 RawPcDescriptors::kOther, | 2691 RawPcDescriptors::kOther, |
2686 locs); | 2692 locs); |
2687 ASSERT(instruction_->locs()->out(0).reg() == R0); | 2693 ASSERT(instruction_->locs()->out(0).reg() == R0); |
2688 compiler->RestoreLiveRegisters(instruction_->locs()); | 2694 compiler->RestoreLiveRegisters(instruction_->locs()); |
2689 __ b(exit_label()); | 2695 __ b(exit_label()); |
2690 } | 2696 } |
2691 | 2697 |
2692 private: | 2698 private: |
(...skipping 4155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6848 1, | 6854 1, |
6849 locs()); | 6855 locs()); |
6850 __ Drop(1); | 6856 __ Drop(1); |
6851 __ Pop(result); | 6857 __ Pop(result); |
6852 } | 6858 } |
6853 | 6859 |
6854 | 6860 |
6855 } // namespace dart | 6861 } // namespace dart |
6856 | 6862 |
6857 #endif // defined TARGET_ARCH_ARM | 6863 #endif // defined TARGET_ARCH_ARM |
OLD | NEW |