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

Side by Side Diff: src/compiler/x64/code-generator-x64.cc

Issue 1411743003: [x64] Emit vcvtss2sd & vcvtsd2ss 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 | « no previous file | src/x64/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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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/compiler/code-generator.h" 5 #include "src/compiler/code-generator.h"
6 6
7 #include "src/compiler/code-generator-impl.h" 7 #include "src/compiler/code-generator-impl.h"
8 #include "src/compiler/gap-resolver.h" 8 #include "src/compiler/gap-resolver.h"
9 #include "src/compiler/node-matchers.h" 9 #include "src/compiler/node-matchers.h"
10 #include "src/compiler/osr.h" 10 #include "src/compiler/osr.h"
(...skipping 808 matching lines...) Expand 10 before | Expand all | Expand 10 after
819 case kSSEFloat32Sqrt: 819 case kSSEFloat32Sqrt:
820 ASSEMBLE_SSE_UNOP(sqrtss); 820 ASSEMBLE_SSE_UNOP(sqrtss);
821 break; 821 break;
822 case kSSEFloat32Max: 822 case kSSEFloat32Max:
823 ASSEMBLE_SSE_BINOP(maxss); 823 ASSEMBLE_SSE_BINOP(maxss);
824 break; 824 break;
825 case kSSEFloat32Min: 825 case kSSEFloat32Min:
826 ASSEMBLE_SSE_BINOP(minss); 826 ASSEMBLE_SSE_BINOP(minss);
827 break; 827 break;
828 case kSSEFloat32ToFloat64: 828 case kSSEFloat32ToFloat64:
829 ASSEMBLE_SSE_UNOP(cvtss2sd); 829 ASSEMBLE_SSE_UNOP(Cvtss2sd);
830 break; 830 break;
831 case kSSEFloat64Cmp: 831 case kSSEFloat64Cmp:
832 ASSEMBLE_SSE_BINOP(ucomisd); 832 ASSEMBLE_SSE_BINOP(ucomisd);
833 break; 833 break;
834 case kSSEFloat64Add: 834 case kSSEFloat64Add:
835 ASSEMBLE_SSE_BINOP(addsd); 835 ASSEMBLE_SSE_BINOP(addsd);
836 break; 836 break;
837 case kSSEFloat64Sub: 837 case kSSEFloat64Sub:
838 ASSEMBLE_SSE_BINOP(subsd); 838 ASSEMBLE_SSE_BINOP(subsd);
839 break; 839 break;
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
902 ASSEMBLE_SSE_UNOP(sqrtsd); 902 ASSEMBLE_SSE_UNOP(sqrtsd);
903 break; 903 break;
904 case kSSEFloat64Round: { 904 case kSSEFloat64Round: {
905 CpuFeatureScope sse_scope(masm(), SSE4_1); 905 CpuFeatureScope sse_scope(masm(), SSE4_1);
906 RoundingMode const mode = 906 RoundingMode const mode =
907 static_cast<RoundingMode>(MiscField::decode(instr->opcode())); 907 static_cast<RoundingMode>(MiscField::decode(instr->opcode()));
908 __ roundsd(i.OutputDoubleRegister(), i.InputDoubleRegister(0), mode); 908 __ roundsd(i.OutputDoubleRegister(), i.InputDoubleRegister(0), mode);
909 break; 909 break;
910 } 910 }
911 case kSSEFloat64ToFloat32: 911 case kSSEFloat64ToFloat32:
912 ASSEMBLE_SSE_UNOP(cvtsd2ss); 912 ASSEMBLE_SSE_UNOP(Cvtsd2ss);
913 break; 913 break;
914 case kSSEFloat64ToInt32: 914 case kSSEFloat64ToInt32:
915 if (instr->InputAt(0)->IsDoubleRegister()) { 915 if (instr->InputAt(0)->IsDoubleRegister()) {
916 __ Cvttsd2si(i.OutputRegister(), i.InputDoubleRegister(0)); 916 __ Cvttsd2si(i.OutputRegister(), i.InputDoubleRegister(0));
917 } else { 917 } else {
918 __ Cvttsd2si(i.OutputRegister(), i.InputOperand(0)); 918 __ Cvttsd2si(i.OutputRegister(), i.InputOperand(0));
919 } 919 }
920 break; 920 break;
921 case kSSEFloat64ToUint32: { 921 case kSSEFloat64ToUint32: {
922 if (instr->InputAt(0)->IsDoubleRegister()) { 922 if (instr->InputAt(0)->IsDoubleRegister()) {
(...skipping 903 matching lines...) Expand 10 before | Expand all | Expand 10 after
1826 int padding_size = last_lazy_deopt_pc_ + space_needed - current_pc; 1826 int padding_size = last_lazy_deopt_pc_ + space_needed - current_pc;
1827 __ Nop(padding_size); 1827 __ Nop(padding_size);
1828 } 1828 }
1829 } 1829 }
1830 1830
1831 #undef __ 1831 #undef __
1832 1832
1833 } // namespace compiler 1833 } // namespace compiler
1834 } // namespace internal 1834 } // namespace internal
1835 } // namespace v8 1835 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/x64/assembler-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698