OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/x64/assembler-x64.h" | 5 #include "src/x64/assembler-x64.h" |
6 | 6 |
7 #include <cstring> | 7 #include <cstring> |
8 | 8 |
9 #if V8_TARGET_ARCH_X64 | 9 #if V8_TARGET_ARCH_X64 |
10 | 10 |
(...skipping 1466 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1477 if (!RelocInfo::IsNone(rmode)) { | 1477 if (!RelocInfo::IsNone(rmode)) { |
1478 RecordRelocInfo(rmode, value); | 1478 RecordRelocInfo(rmode, value); |
1479 } | 1479 } |
1480 emitq(value); | 1480 emitq(value); |
1481 } | 1481 } |
1482 | 1482 |
1483 void Assembler::movq(Register dst, uint64_t value, RelocInfo::Mode rmode) { | 1483 void Assembler::movq(Register dst, uint64_t value, RelocInfo::Mode rmode) { |
1484 movq(dst, static_cast<int64_t>(value), rmode); | 1484 movq(dst, static_cast<int64_t>(value), rmode); |
1485 } | 1485 } |
1486 | 1486 |
| 1487 |
1487 // Loads the ip-relative location of the src label into the target location | 1488 // Loads the ip-relative location of the src label into the target location |
1488 // (as a 32-bit offset sign extended to 64-bit). | 1489 // (as a 32-bit offset sign extended to 64-bit). |
1489 void Assembler::movl(const Operand& dst, Label* src) { | 1490 void Assembler::movl(const Operand& dst, Label* src) { |
1490 EnsureSpace ensure_space(this); | 1491 EnsureSpace ensure_space(this); |
1491 emit_optional_rex_32(dst); | 1492 emit_optional_rex_32(dst); |
1492 emit(0xC7); | 1493 emit(0xC7); |
1493 emit_operand(0, dst); | 1494 emit_operand(0, dst); |
1494 if (src->is_bound()) { | 1495 if (src->is_bound()) { |
1495 int offset = src->pos() - pc_offset() - sizeof(int32_t); | 1496 int offset = src->pos() - pc_offset() - sizeof(int32_t); |
1496 DCHECK(offset <= 0); | 1497 DCHECK(offset <= 0); |
(...skipping 2697 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4194 | 4195 |
4195 bool RelocInfo::IsInConstantPool() { | 4196 bool RelocInfo::IsInConstantPool() { |
4196 return false; | 4197 return false; |
4197 } | 4198 } |
4198 | 4199 |
4199 | 4200 |
4200 } // namespace internal | 4201 } // namespace internal |
4201 } // namespace v8 | 4202 } // namespace v8 |
4202 | 4203 |
4203 #endif // V8_TARGET_ARCH_X64 | 4204 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |