| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #if V8_TARGET_ARCH_X64 | 7 #if V8_TARGET_ARCH_X64 |
| 8 | 8 |
| 9 #include "src/x64/lithium-codegen-x64.h" | 9 #include "src/x64/lithium-codegen-x64.h" |
| 10 #include "src/x64/lithium-gap-resolver-x64.h" | 10 #include "src/x64/lithium-gap-resolver-x64.h" |
| (...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 181 if (cgen_->IsDehoistedKeyConstant(constant_source)) { | 181 if (cgen_->IsDehoistedKeyConstant(constant_source)) { |
| 182 __ Set(dst, constant); | 182 __ Set(dst, constant); |
| 183 } else { | 183 } else { |
| 184 __ Set(dst, static_cast<uint32_t>(constant)); | 184 __ Set(dst, static_cast<uint32_t>(constant)); |
| 185 } | 185 } |
| 186 } else { | 186 } else { |
| 187 __ Move(dst, cgen_->ToHandle(constant_source)); | 187 __ Move(dst, cgen_->ToHandle(constant_source)); |
| 188 } | 188 } |
| 189 } else if (destination->IsDoubleRegister()) { | 189 } else if (destination->IsDoubleRegister()) { |
| 190 double v = cgen_->ToDouble(constant_source); | 190 double v = cgen_->ToDouble(constant_source); |
| 191 uint64_t int_val = BitCast<uint64_t, double>(v); | 191 uint64_t int_val = bit_cast<uint64_t, double>(v); |
| 192 XMMRegister dst = cgen_->ToDoubleRegister(destination); | 192 XMMRegister dst = cgen_->ToDoubleRegister(destination); |
| 193 if (int_val == 0) { | 193 if (int_val == 0) { |
| 194 __ xorps(dst, dst); | 194 __ xorps(dst, dst); |
| 195 } else { | 195 } else { |
| 196 __ Set(kScratchRegister, int_val); | 196 __ Set(kScratchRegister, int_val); |
| 197 __ movq(dst, kScratchRegister); | 197 __ movq(dst, kScratchRegister); |
| 198 } | 198 } |
| 199 } else { | 199 } else { |
| 200 DCHECK(destination->IsStackSlot()); | 200 DCHECK(destination->IsStackSlot()); |
| 201 Operand dst = cgen_->ToOperand(destination); | 201 Operand dst = cgen_->ToOperand(destination); |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 310 moves_[i].set_source(source); | 310 moves_[i].set_source(source); |
| 311 } | 311 } |
| 312 } | 312 } |
| 313 } | 313 } |
| 314 | 314 |
| 315 #undef __ | 315 #undef __ |
| 316 | 316 |
| 317 } } // namespace v8::internal | 317 } } // namespace v8::internal |
| 318 | 318 |
| 319 #endif // V8_TARGET_ARCH_X64 | 319 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |