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 #if V8_TARGET_ARCH_X64 | 5 #if V8_TARGET_ARCH_X64 |
6 | 6 |
7 #include "src/base/bits.h" | 7 #include "src/base/bits.h" |
8 #include "src/base/division-by-constant.h" | 8 #include "src/base/division-by-constant.h" |
9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
(...skipping 2859 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2870 CpuFeatureScope scope(this, AVX); | 2870 CpuFeatureScope scope(this, AVX); |
2871 vmovmskpd(dst, src); | 2871 vmovmskpd(dst, src); |
2872 } else { | 2872 } else { |
2873 movmskpd(dst, src); | 2873 movmskpd(dst, src); |
2874 } | 2874 } |
2875 } | 2875 } |
2876 | 2876 |
2877 void MacroAssembler::Xorps(XMMRegister dst, XMMRegister src) { | 2877 void MacroAssembler::Xorps(XMMRegister dst, XMMRegister src) { |
2878 if (CpuFeatures::IsSupported(AVX)) { | 2878 if (CpuFeatures::IsSupported(AVX)) { |
2879 CpuFeatureScope scope(this, AVX); | 2879 CpuFeatureScope scope(this, AVX); |
2880 vxorps(dst, kScratchDoubleReg, src); | 2880 vxorps(dst, dst, src); |
2881 } else { | 2881 } else { |
2882 xorps(dst, src); | 2882 xorps(dst, src); |
2883 } | 2883 } |
2884 } | 2884 } |
2885 | 2885 |
2886 void MacroAssembler::Xorps(XMMRegister dst, const Operand& src) { | 2886 void MacroAssembler::Xorps(XMMRegister dst, const Operand& src) { |
2887 if (CpuFeatures::IsSupported(AVX)) { | 2887 if (CpuFeatures::IsSupported(AVX)) { |
2888 CpuFeatureScope scope(this, AVX); | 2888 CpuFeatureScope scope(this, AVX); |
2889 vxorps(dst, kScratchDoubleReg, src); | 2889 vxorps(dst, dst, src); |
2890 } else { | 2890 } else { |
2891 xorps(dst, src); | 2891 xorps(dst, src); |
2892 } | 2892 } |
2893 } | 2893 } |
2894 | 2894 |
2895 void MacroAssembler::Roundss(XMMRegister dst, XMMRegister src, | 2895 void MacroAssembler::Roundss(XMMRegister dst, XMMRegister src, |
2896 RoundingMode mode) { | 2896 RoundingMode mode) { |
2897 if (CpuFeatures::IsSupported(AVX)) { | 2897 if (CpuFeatures::IsSupported(AVX)) { |
2898 CpuFeatureScope scope(this, AVX); | 2898 CpuFeatureScope scope(this, AVX); |
2899 vroundss(dst, dst, src, mode); | 2899 vroundss(dst, dst, src, mode); |
(...skipping 2876 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5776 movl(rax, dividend); | 5776 movl(rax, dividend); |
5777 shrl(rax, Immediate(31)); | 5777 shrl(rax, Immediate(31)); |
5778 addl(rdx, rax); | 5778 addl(rdx, rax); |
5779 } | 5779 } |
5780 | 5780 |
5781 | 5781 |
5782 } // namespace internal | 5782 } // namespace internal |
5783 } // namespace v8 | 5783 } // namespace v8 |
5784 | 5784 |
5785 #endif // V8_TARGET_ARCH_X64 | 5785 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |