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 2280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2291 } | 2291 } |
2292 } | 2292 } |
2293 Isolate* isolate = compiler->isolate(); | 2293 Isolate* isolate = compiler->isolate(); |
2294 const Code& stub = Code::Handle( | 2294 const Code& stub = Code::Handle( |
2295 isolate, isolate->stub_code()->GetAllocateArrayStub()); | 2295 isolate, isolate->stub_code()->GetAllocateArrayStub()); |
2296 const ExternalLabel label(stub.EntryPoint()); | 2296 const ExternalLabel label(stub.EntryPoint()); |
2297 compiler->GenerateCall(token_pos(), | 2297 compiler->GenerateCall(token_pos(), |
2298 &label, | 2298 &label, |
2299 RawPcDescriptors::kOther, | 2299 RawPcDescriptors::kOther, |
2300 locs()); | 2300 locs()); |
| 2301 compiler->AddStubCallTarget(stub); |
2301 ASSERT(locs()->out(0).reg() == kResultReg); | 2302 ASSERT(locs()->out(0).reg() == kResultReg); |
2302 } | 2303 } |
2303 | 2304 |
2304 | 2305 |
2305 LocationSummary* LoadFieldInstr::MakeLocationSummary(Isolate* isolate, | 2306 LocationSummary* LoadFieldInstr::MakeLocationSummary(Isolate* isolate, |
2306 bool opt) const { | 2307 bool opt) const { |
2307 const intptr_t kNumInputs = 1; | 2308 const intptr_t kNumInputs = 1; |
2308 const intptr_t kNumTemps = | 2309 const intptr_t kNumTemps = |
2309 (IsUnboxedLoad() && opt) ? 1 : | 2310 (IsUnboxedLoad() && opt) ? 1 : |
2310 ((IsPotentialUnboxedLoad()) ? 3 : 0); | 2311 ((IsPotentialUnboxedLoad()) ? 3 : 0); |
(...skipping 4688 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6999 void AllocateObjectInstr::EmitNativeCode(FlowGraphCompiler* compiler) { | 7000 void AllocateObjectInstr::EmitNativeCode(FlowGraphCompiler* compiler) { |
7000 Isolate* isolate = compiler->isolate(); | 7001 Isolate* isolate = compiler->isolate(); |
7001 StubCode* stub_code = isolate->stub_code(); | 7002 StubCode* stub_code = isolate->stub_code(); |
7002 const Code& stub = Code::Handle(isolate, | 7003 const Code& stub = Code::Handle(isolate, |
7003 stub_code->GetAllocationStubForClass(cls())); | 7004 stub_code->GetAllocationStubForClass(cls())); |
7004 const ExternalLabel label(stub.EntryPoint()); | 7005 const ExternalLabel label(stub.EntryPoint()); |
7005 compiler->GenerateCall(token_pos(), | 7006 compiler->GenerateCall(token_pos(), |
7006 &label, | 7007 &label, |
7007 RawPcDescriptors::kOther, | 7008 RawPcDescriptors::kOther, |
7008 locs()); | 7009 locs()); |
| 7010 compiler->AddStubCallTarget(stub); |
7009 __ Drop(ArgumentCount()); // Discard arguments. | 7011 __ Drop(ArgumentCount()); // Discard arguments. |
7010 } | 7012 } |
7011 | 7013 |
7012 | 7014 |
7013 void DebugStepCheckInstr::EmitNativeCode(FlowGraphCompiler* compiler) { | 7015 void DebugStepCheckInstr::EmitNativeCode(FlowGraphCompiler* compiler) { |
7014 ASSERT(!compiler->is_optimizing()); | 7016 ASSERT(!compiler->is_optimizing()); |
7015 StubCode* stub_code = compiler->isolate()->stub_code(); | 7017 StubCode* stub_code = compiler->isolate()->stub_code(); |
7016 const ExternalLabel label(stub_code->DebugStepCheckEntryPoint()); | 7018 const ExternalLabel label(stub_code->DebugStepCheckEntryPoint()); |
7017 compiler->GenerateCall(token_pos(), &label, stub_kind_, locs()); | 7019 compiler->GenerateCall(token_pos(), &label, stub_kind_, locs()); |
7018 #if defined(DEBUG) | 7020 #if defined(DEBUG) |
7019 __ LoadImmediate(R4, kInvalidObjectPointer); | 7021 __ LoadImmediate(R4, kInvalidObjectPointer); |
7020 __ LoadImmediate(R5, kInvalidObjectPointer); | 7022 __ LoadImmediate(R5, kInvalidObjectPointer); |
7021 #endif | 7023 #endif |
7022 } | 7024 } |
7023 | 7025 |
7024 } // namespace dart | 7026 } // namespace dart |
7025 | 7027 |
7026 #endif // defined TARGET_ARCH_ARM | 7028 #endif // defined TARGET_ARCH_ARM |
OLD | NEW |