Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(181)

Side by Side Diff: src/x64/lithium-gap-resolver-x64.cc

Issue 1408983002: [x64] Make use of vxorpd when AVX is enabled. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/x64/lithium-codegen-x64.cc ('k') | src/x64/macro-assembler-x64.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #if V8_TARGET_ARCH_X64 5 #if V8_TARGET_ARCH_X64
6 6
7 #include "src/x64/lithium-codegen-x64.h" 7 #include "src/x64/lithium-codegen-x64.h"
8 #include "src/x64/lithium-gap-resolver-x64.h" 8 #include "src/x64/lithium-gap-resolver-x64.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 __ Set(dst, static_cast<uint32_t>(constant)); 182 __ Set(dst, static_cast<uint32_t>(constant));
183 } 183 }
184 } else { 184 } else {
185 __ Move(dst, cgen_->ToHandle(constant_source)); 185 __ Move(dst, cgen_->ToHandle(constant_source));
186 } 186 }
187 } else if (destination->IsDoubleRegister()) { 187 } else if (destination->IsDoubleRegister()) {
188 double v = cgen_->ToDouble(constant_source); 188 double v = cgen_->ToDouble(constant_source);
189 uint64_t int_val = bit_cast<uint64_t, double>(v); 189 uint64_t int_val = bit_cast<uint64_t, double>(v);
190 XMMRegister dst = cgen_->ToDoubleRegister(destination); 190 XMMRegister dst = cgen_->ToDoubleRegister(destination);
191 if (int_val == 0) { 191 if (int_val == 0) {
192 __ xorps(dst, dst); 192 __ Xorpd(dst, dst);
193 } else { 193 } else {
194 __ Set(kScratchRegister, int_val); 194 __ Set(kScratchRegister, int_val);
195 __ Movq(dst, kScratchRegister); 195 __ Movq(dst, kScratchRegister);
196 } 196 }
197 } else { 197 } else {
198 DCHECK(destination->IsStackSlot()); 198 DCHECK(destination->IsStackSlot());
199 Operand dst = cgen_->ToOperand(destination); 199 Operand dst = cgen_->ToOperand(destination);
200 if (cgen_->IsSmiConstant(constant_source)) { 200 if (cgen_->IsSmiConstant(constant_source)) {
201 __ Move(dst, cgen_->ToSmi(constant_source)); 201 __ Move(dst, cgen_->ToSmi(constant_source));
202 } else if (cgen_->IsInteger32Constant(constant_source)) { 202 } else if (cgen_->IsInteger32Constant(constant_source)) {
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
309 } 309 }
310 } 310 }
311 } 311 }
312 312
313 #undef __ 313 #undef __
314 314
315 } // namespace internal 315 } // namespace internal
316 } // namespace v8 316 } // namespace v8
317 317
318 #endif // V8_TARGET_ARCH_X64 318 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/x64/lithium-codegen-x64.cc ('k') | src/x64/macro-assembler-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698