Index: src/ia32/macro-assembler-ia32.cc |
diff --git a/src/ia32/macro-assembler-ia32.cc b/src/ia32/macro-assembler-ia32.cc |
index 1bd31b32ecd27e21ebf0b53a0a67b9ffe143d18a..81438c3046e3b6e6f094ba988cde615bcf36d6a2 100644 |
--- a/src/ia32/macro-assembler-ia32.cc |
+++ b/src/ia32/macro-assembler-ia32.cc |
@@ -2377,11 +2377,11 @@ void MacroAssembler::Move(XMMRegister dst, uint32_t src) { |
void MacroAssembler::Move(XMMRegister dst, uint64_t src) { |
- uint32_t lower = static_cast<uint32_t>(src); |
- uint32_t upper = static_cast<uint32_t>(src >> 32); |
- if (upper == 0) { |
- Move(dst, lower); |
+ if (src == 0) { |
+ pxor(dst, dst); |
} else { |
+ uint32_t lower = static_cast<uint32_t>(src); |
+ uint32_t upper = static_cast<uint32_t>(src >> 32); |
unsigned cnt = base::bits::CountPopulation64(src); |
unsigned nlz = base::bits::CountLeadingZeros64(src); |
unsigned ntz = base::bits::CountTrailingZeros64(src); |