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_MIPS. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_MIPS. |
6 #if defined(TARGET_ARCH_MIPS) | 6 #if defined(TARGET_ARCH_MIPS) |
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 1711 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1722 : instruction_(instruction), cls_(cls) { } | 1722 : instruction_(instruction), cls_(cls) { } |
1723 | 1723 |
1724 virtual void EmitNativeCode(FlowGraphCompiler* compiler) { | 1724 virtual void EmitNativeCode(FlowGraphCompiler* compiler) { |
1725 __ Comment("StoreInstanceFieldSlowPath"); | 1725 __ Comment("StoreInstanceFieldSlowPath"); |
1726 __ Bind(entry_label()); | 1726 __ Bind(entry_label()); |
1727 const Code& stub = | 1727 const Code& stub = |
1728 Code::Handle(StubCode::GetAllocationStubForClass(cls_)); | 1728 Code::Handle(StubCode::GetAllocationStubForClass(cls_)); |
1729 const ExternalLabel label(stub.EntryPoint()); | 1729 const ExternalLabel label(stub.EntryPoint()); |
1730 | 1730 |
1731 LocationSummary* locs = instruction_->locs(); | 1731 LocationSummary* locs = instruction_->locs(); |
1732 locs->live_registers()->Remove(locs->out(0)); | 1732 locs->live_registers()->Remove(locs->temp(0)); |
1733 | 1733 |
1734 compiler->SaveLiveRegisters(locs); | 1734 compiler->SaveLiveRegisters(locs); |
1735 compiler->GenerateCall(Scanner::kNoSourcePos, // No token position. | 1735 compiler->GenerateCall(Scanner::kNoSourcePos, // No token position. |
1736 &label, | 1736 &label, |
1737 RawPcDescriptors::kOther, | 1737 RawPcDescriptors::kOther, |
1738 locs); | 1738 locs); |
1739 __ mov(locs->temp(0).reg(), V0); | 1739 __ mov(locs->temp(0).reg(), V0); |
1740 compiler->RestoreLiveRegisters(locs); | 1740 compiler->RestoreLiveRegisters(locs); |
1741 | 1741 |
1742 __ b(exit_label()); | 1742 __ b(exit_label()); |
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2127 | 2127 |
2128 virtual void EmitNativeCode(FlowGraphCompiler* compiler) { | 2128 virtual void EmitNativeCode(FlowGraphCompiler* compiler) { |
2129 __ Comment("BoxDoubleSlowPath"); | 2129 __ Comment("BoxDoubleSlowPath"); |
2130 __ Bind(entry_label()); | 2130 __ Bind(entry_label()); |
2131 const Class& double_class = compiler->double_class(); | 2131 const Class& double_class = compiler->double_class(); |
2132 const Code& stub = | 2132 const Code& stub = |
2133 Code::Handle(StubCode::GetAllocationStubForClass(double_class)); | 2133 Code::Handle(StubCode::GetAllocationStubForClass(double_class)); |
2134 const ExternalLabel label(stub.EntryPoint()); | 2134 const ExternalLabel label(stub.EntryPoint()); |
2135 | 2135 |
2136 LocationSummary* locs = instruction_->locs(); | 2136 LocationSummary* locs = instruction_->locs(); |
2137 locs->live_registers()->Remove(locs->out(0)); | 2137 ASSERT(!locs->live_registers()->Contains(locs->out(0))); |
2138 | 2138 |
2139 compiler->SaveLiveRegisters(locs); | 2139 compiler->SaveLiveRegisters(locs); |
2140 compiler->GenerateCall(Scanner::kNoSourcePos, // No token position. | 2140 compiler->GenerateCall(Scanner::kNoSourcePos, // No token position. |
2141 &label, | 2141 &label, |
2142 RawPcDescriptors::kOther, | 2142 RawPcDescriptors::kOther, |
2143 locs); | 2143 locs); |
2144 if (locs->out(0).reg() != V0) { | 2144 if (locs->out(0).reg() != V0) { |
2145 __ mov(locs->out(0).reg(), V0); | 2145 __ mov(locs->out(0).reg(), V0); |
2146 } | 2146 } |
2147 compiler->RestoreLiveRegisters(locs); | 2147 compiler->RestoreLiveRegisters(locs); |
(...skipping 2549 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4697 compiler->GenerateCall(token_pos(), &label, stub_kind_, locs()); | 4697 compiler->GenerateCall(token_pos(), &label, stub_kind_, locs()); |
4698 #if defined(DEBUG) | 4698 #if defined(DEBUG) |
4699 __ LoadImmediate(S4, kInvalidObjectPointer); | 4699 __ LoadImmediate(S4, kInvalidObjectPointer); |
4700 __ LoadImmediate(S5, kInvalidObjectPointer); | 4700 __ LoadImmediate(S5, kInvalidObjectPointer); |
4701 #endif | 4701 #endif |
4702 } | 4702 } |
4703 | 4703 |
4704 } // namespace dart | 4704 } // namespace dart |
4705 | 4705 |
4706 #endif // defined TARGET_ARCH_MIPS | 4706 #endif // defined TARGET_ARCH_MIPS |
OLD | NEW |