OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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_ARM64. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_ARM64. |
6 #if defined(TARGET_ARCH_ARM64) | 6 #if defined(TARGET_ARCH_ARM64) |
7 | 7 |
8 #include "vm/intermediate_language.h" | 8 #include "vm/intermediate_language.h" |
9 | 9 |
10 #include "vm/dart_entry.h" | 10 #include "vm/dart_entry.h" |
(...skipping 1967 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1978 ASSERT(locs()->in(kElementTypePos).reg() == R1); | 1978 ASSERT(locs()->in(kElementTypePos).reg() == R1); |
1979 ASSERT(locs()->in(kLengthPos).reg() == R2); | 1979 ASSERT(locs()->in(kLengthPos).reg() == R2); |
1980 Isolate* isolate = compiler->isolate(); | 1980 Isolate* isolate = compiler->isolate(); |
1981 const Code& stub = Code::Handle( | 1981 const Code& stub = Code::Handle( |
1982 isolate, isolate->stub_code()->GetAllocateArrayStub()); | 1982 isolate, isolate->stub_code()->GetAllocateArrayStub()); |
1983 const ExternalLabel label(stub.EntryPoint()); | 1983 const ExternalLabel label(stub.EntryPoint()); |
1984 compiler->GenerateCall(token_pos(), | 1984 compiler->GenerateCall(token_pos(), |
1985 &label, | 1985 &label, |
1986 RawPcDescriptors::kOther, | 1986 RawPcDescriptors::kOther, |
1987 locs()); | 1987 locs()); |
| 1988 compiler->AddStubCallTarget(stub); |
1988 ASSERT(locs()->out(0).reg() == R0); | 1989 ASSERT(locs()->out(0).reg() == R0); |
1989 } | 1990 } |
1990 | 1991 |
1991 | 1992 |
1992 LocationSummary* LoadFieldInstr::MakeLocationSummary(Isolate* isolate, | 1993 LocationSummary* LoadFieldInstr::MakeLocationSummary(Isolate* isolate, |
1993 bool opt) const { | 1994 bool opt) const { |
1994 const intptr_t kNumInputs = 1; | 1995 const intptr_t kNumInputs = 1; |
1995 const intptr_t kNumTemps = | 1996 const intptr_t kNumTemps = |
1996 (IsUnboxedLoad() && opt) ? 1 : | 1997 (IsUnboxedLoad() && opt) ? 1 : |
1997 ((IsPotentialUnboxedLoad()) ? 1 : 0); | 1998 ((IsPotentialUnboxedLoad()) ? 1 : 0); |
(...skipping 3477 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5475 void AllocateObjectInstr::EmitNativeCode(FlowGraphCompiler* compiler) { | 5476 void AllocateObjectInstr::EmitNativeCode(FlowGraphCompiler* compiler) { |
5476 Isolate* isolate = compiler->isolate(); | 5477 Isolate* isolate = compiler->isolate(); |
5477 StubCode* stub_code = isolate->stub_code(); | 5478 StubCode* stub_code = isolate->stub_code(); |
5478 const Code& stub = Code::Handle(isolate, | 5479 const Code& stub = Code::Handle(isolate, |
5479 stub_code->GetAllocationStubForClass(cls())); | 5480 stub_code->GetAllocationStubForClass(cls())); |
5480 const ExternalLabel label(stub.EntryPoint()); | 5481 const ExternalLabel label(stub.EntryPoint()); |
5481 compiler->GenerateCall(token_pos(), | 5482 compiler->GenerateCall(token_pos(), |
5482 &label, | 5483 &label, |
5483 RawPcDescriptors::kOther, | 5484 RawPcDescriptors::kOther, |
5484 locs()); | 5485 locs()); |
| 5486 compiler->AddStubCallTarget(stub); |
5485 __ Drop(ArgumentCount()); // Discard arguments. | 5487 __ Drop(ArgumentCount()); // Discard arguments. |
5486 } | 5488 } |
5487 | 5489 |
5488 | 5490 |
5489 void DebugStepCheckInstr::EmitNativeCode(FlowGraphCompiler* compiler) { | 5491 void DebugStepCheckInstr::EmitNativeCode(FlowGraphCompiler* compiler) { |
5490 ASSERT(!compiler->is_optimizing()); | 5492 ASSERT(!compiler->is_optimizing()); |
5491 StubCode* stub_code = compiler->isolate()->stub_code(); | 5493 StubCode* stub_code = compiler->isolate()->stub_code(); |
5492 const ExternalLabel label(stub_code->DebugStepCheckEntryPoint()); | 5494 const ExternalLabel label(stub_code->DebugStepCheckEntryPoint()); |
5493 compiler->GenerateCall(token_pos(), &label, stub_kind_, locs()); | 5495 compiler->GenerateCall(token_pos(), &label, stub_kind_, locs()); |
5494 #if defined(DEBUG) | 5496 #if defined(DEBUG) |
5495 __ LoadImmediate(R4, kInvalidObjectPointer, kNoPP); | 5497 __ LoadImmediate(R4, kInvalidObjectPointer, kNoPP); |
5496 __ LoadImmediate(R5, kInvalidObjectPointer, kNoPP); | 5498 __ LoadImmediate(R5, kInvalidObjectPointer, kNoPP); |
5497 #endif | 5499 #endif |
5498 } | 5500 } |
5499 | 5501 |
5500 } // namespace dart | 5502 } // namespace dart |
5501 | 5503 |
5502 #endif // defined TARGET_ARCH_ARM64 | 5504 #endif // defined TARGET_ARCH_ARM64 |
OLD | NEW |