| 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" // NOLINT | 5 #include "vm/globals.h" // NOLINT |
| 6 #if defined(TARGET_ARCH_ARM) | 6 #if defined(TARGET_ARCH_ARM) |
| 7 | 7 |
| 8 #include "vm/assembler.h" | 8 #include "vm/assembler.h" |
| 9 #include "vm/cpu.h" | 9 #include "vm/cpu.h" |
| 10 #include "vm/longjump.h" | 10 #include "vm/longjump.h" |
| (...skipping 1949 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1960 ASSERT(RawObject::kClassIdTagPos == 16); | 1960 ASSERT(RawObject::kClassIdTagPos == 16); |
| 1961 ASSERT(RawObject::kClassIdTagSize == 16); | 1961 ASSERT(RawObject::kClassIdTagSize == 16); |
| 1962 const intptr_t class_id_offset = Object::tags_offset() + | 1962 const intptr_t class_id_offset = Object::tags_offset() + |
| 1963 RawObject::kClassIdTagPos / kBitsPerByte; | 1963 RawObject::kClassIdTagPos / kBitsPerByte; |
| 1964 ldrh(result, FieldAddress(object, class_id_offset), cond); | 1964 ldrh(result, FieldAddress(object, class_id_offset), cond); |
| 1965 } | 1965 } |
| 1966 | 1966 |
| 1967 | 1967 |
| 1968 void Assembler::LoadClassById(Register result, Register class_id) { | 1968 void Assembler::LoadClassById(Register result, Register class_id) { |
| 1969 ASSERT(result != class_id); | 1969 ASSERT(result != class_id); |
| 1970 LoadImmediate(result, Isolate::Current()->class_table()->TableAddress()); | 1970 LoadIsolate(result); |
| 1971 LoadFromOffset(kWord, result, result, 0); | 1971 const intptr_t offset = |
| 1972 Isolate::class_table_offset() + ClassTable::table_offset(); |
| 1973 LoadFromOffset(kWord, result, result, offset); |
| 1972 ldr(result, Address(result, class_id, LSL, 2)); | 1974 ldr(result, Address(result, class_id, LSL, 2)); |
| 1973 } | 1975 } |
| 1974 | 1976 |
| 1975 | 1977 |
| 1976 void Assembler::LoadClass(Register result, Register object, Register scratch) { | 1978 void Assembler::LoadClass(Register result, Register object, Register scratch) { |
| 1977 ASSERT(scratch != result); | 1979 ASSERT(scratch != result); |
| 1978 LoadClassId(scratch, object); | 1980 LoadClassId(scratch, object); |
| 1979 LoadClassById(result, scratch); | 1981 LoadClassById(result, scratch); |
| 1980 } | 1982 } |
| 1981 | 1983 |
| (...skipping 1646 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3628 | 3630 |
| 3629 | 3631 |
| 3630 const char* Assembler::FpuRegisterName(FpuRegister reg) { | 3632 const char* Assembler::FpuRegisterName(FpuRegister reg) { |
| 3631 ASSERT((0 <= reg) && (reg < kNumberOfFpuRegisters)); | 3633 ASSERT((0 <= reg) && (reg < kNumberOfFpuRegisters)); |
| 3632 return fpu_reg_names[reg]; | 3634 return fpu_reg_names[reg]; |
| 3633 } | 3635 } |
| 3634 | 3636 |
| 3635 } // namespace dart | 3637 } // namespace dart |
| 3636 | 3638 |
| 3637 #endif // defined TARGET_ARCH_ARM | 3639 #endif // defined TARGET_ARCH_ARM |
| OLD | NEW |