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_X64. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64. |
6 #if defined(TARGET_ARCH_X64) | 6 #if defined(TARGET_ARCH_X64) |
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 1706 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1717 | 1717 |
1718 | 1718 |
1719 LocationSummary* StoreInstanceFieldInstr::MakeLocationSummary(Isolate* isolate, | 1719 LocationSummary* StoreInstanceFieldInstr::MakeLocationSummary(Isolate* isolate, |
1720 bool opt) const { | 1720 bool opt) const { |
1721 const intptr_t kNumInputs = 2; | 1721 const intptr_t kNumInputs = 2; |
1722 const intptr_t kNumTemps = | 1722 const intptr_t kNumTemps = |
1723 (IsUnboxedStore() && opt) ? 2 : | 1723 (IsUnboxedStore() && opt) ? 2 : |
1724 ((IsPotentialUnboxedStore()) ? 3 : 0); | 1724 ((IsPotentialUnboxedStore()) ? 3 : 0); |
1725 LocationSummary* summary = new(isolate) LocationSummary( | 1725 LocationSummary* summary = new(isolate) LocationSummary( |
1726 isolate, kNumInputs, kNumTemps, | 1726 isolate, kNumInputs, kNumTemps, |
1727 ((IsUnboxedStore() && opt && is_initialization_) || | 1727 ((IsUnboxedStore() && opt && is_potential_unboxed_initialization_) || |
1728 IsPotentialUnboxedStore()) | 1728 IsPotentialUnboxedStore()) |
1729 ? LocationSummary::kCallOnSlowPath | 1729 ? LocationSummary::kCallOnSlowPath |
1730 : LocationSummary::kNoCall); | 1730 : LocationSummary::kNoCall); |
1731 | 1731 |
1732 summary->set_in(0, Location::RequiresRegister()); | 1732 summary->set_in(0, Location::RequiresRegister()); |
1733 if (IsUnboxedStore() && opt) { | 1733 if (IsUnboxedStore() && opt) { |
1734 summary->set_in(1, Location::RequiresFpuRegister()); | 1734 summary->set_in(1, Location::RequiresFpuRegister()); |
1735 summary->set_temp(0, Location::RequiresRegister()); | 1735 summary->set_temp(0, Location::RequiresRegister()); |
1736 summary->set_temp(1, Location::RequiresRegister()); | 1736 summary->set_temp(1, Location::RequiresRegister()); |
1737 } else if (IsPotentialUnboxedStore()) { | 1737 } else if (IsPotentialUnboxedStore()) { |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1776 Label skip_store; | 1776 Label skip_store; |
1777 | 1777 |
1778 Register instance_reg = locs()->in(0).reg(); | 1778 Register instance_reg = locs()->in(0).reg(); |
1779 | 1779 |
1780 if (IsUnboxedStore() && compiler->is_optimizing()) { | 1780 if (IsUnboxedStore() && compiler->is_optimizing()) { |
1781 XmmRegister value = locs()->in(1).fpu_reg(); | 1781 XmmRegister value = locs()->in(1).fpu_reg(); |
1782 Register temp = locs()->temp(0).reg(); | 1782 Register temp = locs()->temp(0).reg(); |
1783 Register temp2 = locs()->temp(1).reg(); | 1783 Register temp2 = locs()->temp(1).reg(); |
1784 const intptr_t cid = field().UnboxedFieldCid(); | 1784 const intptr_t cid = field().UnboxedFieldCid(); |
1785 | 1785 |
1786 if (is_initialization_) { | 1786 if (is_potential_unboxed_initialization_) { |
1787 const Class* cls = NULL; | 1787 const Class* cls = NULL; |
1788 switch (cid) { | 1788 switch (cid) { |
1789 case kDoubleCid: | 1789 case kDoubleCid: |
1790 cls = &compiler->double_class(); | 1790 cls = &compiler->double_class(); |
1791 break; | 1791 break; |
1792 case kFloat32x4Cid: | 1792 case kFloat32x4Cid: |
1793 cls = &compiler->float32x4_class(); | 1793 cls = &compiler->float32x4_class(); |
1794 break; | 1794 break; |
1795 case kFloat64x2Cid: | 1795 case kFloat64x2Cid: |
1796 cls = &compiler->float64x2_class(); | 1796 cls = &compiler->float64x2_class(); |
(...skipping 4605 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6402 __ movq(R10, Immediate(kInvalidObjectPointer)); | 6402 __ movq(R10, Immediate(kInvalidObjectPointer)); |
6403 __ movq(RBX, Immediate(kInvalidObjectPointer)); | 6403 __ movq(RBX, Immediate(kInvalidObjectPointer)); |
6404 #endif | 6404 #endif |
6405 } | 6405 } |
6406 | 6406 |
6407 } // namespace dart | 6407 } // namespace dart |
6408 | 6408 |
6409 #undef __ | 6409 #undef __ |
6410 | 6410 |
6411 #endif // defined TARGET_ARCH_X64 | 6411 #endif // defined TARGET_ARCH_X64 |
OLD | NEW |