Chromium Code Reviews| Index: src/x64/macro-assembler-x64.cc |
| diff --git a/src/x64/macro-assembler-x64.cc b/src/x64/macro-assembler-x64.cc |
| index 81017b39e17fe6499400ddb37e0c495582a0e3d0..424115725b9e10757a37e07975e22a7e00a30a3e 100644 |
| --- a/src/x64/macro-assembler-x64.cc |
| +++ b/src/x64/macro-assembler-x64.cc |
| @@ -1114,6 +1114,18 @@ void MacroAssembler::Set(Register dst, int64_t x) { |
| } |
| } |
| +void MacroAssembler::Set(Register dst, int64_t x, RelocInfo::Mode rmode) { |
| + if (rmode == RelocInfo::WASM_MEMORY_REFERENCE) { |
| + DCHECK(x != 0); |
| + movq(dst, x, rmode); |
| + } else if (is_uint32(x)) { |
| + movl(dst, Immediate(static_cast<int32_t>(x), rmode)); |
|
titzer
2016/03/14 15:23:38
You probably want to DCHECK that there is no reloc
gdeepti1
2016/03/14 20:08:14
Done.
|
| + } else if (is_int32(x)) { |
| + movq(dst, Immediate(static_cast<int32_t>(x), rmode)); |
| + } else { |
| + movq(dst, x, rmode); |
| + } |
| +} |
| void MacroAssembler::Set(const Operand& dst, intptr_t x) { |
| if (kPointerSize == kInt64Size) { |