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" // NOLINT | 5 #include "vm/globals.h" // NOLINT |
6 #if defined(TARGET_ARCH_ARM64) | 6 #if defined(TARGET_ARCH_ARM64) |
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 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
214 | 214 |
215 void Assembler::Stop(const char* message) { | 215 void Assembler::Stop(const char* message) { |
216 if (FLAG_print_stop_message) { | 216 if (FLAG_print_stop_message) { |
217 UNIMPLEMENTED(); | 217 UNIMPLEMENTED(); |
218 } | 218 } |
219 Label stop; | 219 Label stop; |
220 b(&stop); | 220 b(&stop); |
221 Emit(Utils::Low32Bits(reinterpret_cast<int64_t>(message))); | 221 Emit(Utils::Low32Bits(reinterpret_cast<int64_t>(message))); |
222 Emit(Utils::High32Bits(reinterpret_cast<int64_t>(message))); | 222 Emit(Utils::High32Bits(reinterpret_cast<int64_t>(message))); |
223 Bind(&stop); | 223 Bind(&stop); |
224 hlt(Instr::kStopMessageCode); | 224 brk(Instr::kStopMessageCode); |
225 } | 225 } |
226 | 226 |
227 | 227 |
228 static int CountLeadingZeros(uint64_t value, int width) { | 228 static int CountLeadingZeros(uint64_t value, int width) { |
229 ASSERT((width == 32) || (width == 64)); | 229 ASSERT((width == 32) || (width == 64)); |
230 if (value == 0) { | 230 if (value == 0) { |
231 return width; | 231 return width; |
232 } | 232 } |
233 int count = 0; | 233 int count = 0; |
234 do { | 234 do { |
(...skipping 1251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1486 add(base, array, Operand(index, LSL, shift)); | 1486 add(base, array, Operand(index, LSL, shift)); |
1487 } | 1487 } |
1488 const OperandSize size = Address::OperandSizeFor(cid); | 1488 const OperandSize size = Address::OperandSizeFor(cid); |
1489 ASSERT(Address::CanHoldOffset(offset, Address::Offset, size)); | 1489 ASSERT(Address::CanHoldOffset(offset, Address::Offset, size)); |
1490 return Address(base, offset, Address::Offset, size); | 1490 return Address(base, offset, Address::Offset, size); |
1491 } | 1491 } |
1492 | 1492 |
1493 } // namespace dart | 1493 } // namespace dart |
1494 | 1494 |
1495 #endif // defined TARGET_ARCH_ARM64 | 1495 #endif // defined TARGET_ARCH_ARM64 |
OLD | NEW |