| 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 2427 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2438 } | 2438 } |
| 2439 | 2439 |
| 2440 | 2440 |
| 2441 void LoadFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) { | 2441 void LoadFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) { |
| 2442 ASSERT(sizeof(classid_t) == kInt16Size); | 2442 ASSERT(sizeof(classid_t) == kInt16Size); |
| 2443 | 2443 |
| 2444 const Register instance_reg = locs()->in(0).reg(); | 2444 const Register instance_reg = locs()->in(0).reg(); |
| 2445 if (IsUnboxedLoad() && compiler->is_optimizing()) { | 2445 if (IsUnboxedLoad() && compiler->is_optimizing()) { |
| 2446 const DRegister result = EvenDRegisterOf(locs()->out(0).fpu_reg()); | 2446 const DRegister result = EvenDRegisterOf(locs()->out(0).fpu_reg()); |
| 2447 const Register temp = locs()->temp(0).reg(); | 2447 const Register temp = locs()->temp(0).reg(); |
| 2448 __ ldr(temp, FieldAddress(instance_reg, offset_in_bytes())); | 2448 __ LoadFieldFromOffset(kWord, temp, instance_reg, offset_in_bytes()); |
| 2449 const intptr_t cid = field()->UnboxedFieldCid(); | 2449 const intptr_t cid = field()->UnboxedFieldCid(); |
| 2450 switch (cid) { | 2450 switch (cid) { |
| 2451 case kDoubleCid: | 2451 case kDoubleCid: |
| 2452 __ Comment("UnboxedDoubleLoadFieldInstr"); | 2452 __ Comment("UnboxedDoubleLoadFieldInstr"); |
| 2453 __ LoadDFromOffset(result, temp, | 2453 __ LoadDFromOffset(result, temp, |
| 2454 Double::value_offset() - kHeapObjectTag); | 2454 Double::value_offset() - kHeapObjectTag); |
| 2455 break; | 2455 break; |
| 2456 case kFloat32x4Cid: | 2456 case kFloat32x4Cid: |
| 2457 __ Comment("UnboxedFloat32x4LoadFieldInstr"); | 2457 __ Comment("UnboxedFloat32x4LoadFieldInstr"); |
| 2458 __ LoadMultipleDFromOffset(result, 2, temp, | 2458 __ LoadMultipleDFromOffset(result, 2, temp, |
| (...skipping 4401 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6860 1, | 6860 1, |
| 6861 locs()); | 6861 locs()); |
| 6862 __ Drop(1); | 6862 __ Drop(1); |
| 6863 __ Pop(result); | 6863 __ Pop(result); |
| 6864 } | 6864 } |
| 6865 | 6865 |
| 6866 | 6866 |
| 6867 } // namespace dart | 6867 } // namespace dart |
| 6868 | 6868 |
| 6869 #endif // defined TARGET_ARCH_ARM | 6869 #endif // defined TARGET_ARCH_ARM |
| OLD | NEW |