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

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

Issue 1533503002: [turbofan] Fixed the second return value of TryTruncateFloatXXToUint64. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years 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/compiler/x64/code-generator-x64.cc » ('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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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/arm64/frames-arm64.h" 7 #include "src/arm64/frames-arm64.h"
8 #include "src/arm64/macro-assembler-arm64.h" 8 #include "src/arm64/macro-assembler-arm64.h"
9 #include "src/ast/scopes.h" 9 #include "src/ast/scopes.h"
10 #include "src/compiler/code-generator-impl.h" 10 #include "src/compiler/code-generator-impl.h"
(...skipping 1042 matching lines...) Expand 10 before | Expand all | Expand 10 after
1053 if (i.OutputCount() > 1) { 1053 if (i.OutputCount() > 1) {
1054 __ Cmp(i.OutputRegister(0), 1); 1054 __ Cmp(i.OutputRegister(0), 1);
1055 __ Ccmp(i.OutputRegister(0), -1, VFlag, vc); 1055 __ Ccmp(i.OutputRegister(0), -1, VFlag, vc);
1056 __ Fccmp(i.InputDoubleRegister(0), i.InputDoubleRegister(0), VFlag, vc); 1056 __ Fccmp(i.InputDoubleRegister(0), i.InputDoubleRegister(0), VFlag, vc);
1057 __ Cset(i.OutputRegister(1), vc); 1057 __ Cset(i.OutputRegister(1), vc);
1058 } 1058 }
1059 break; 1059 break;
1060 case kArm64Float32ToUint64: 1060 case kArm64Float32ToUint64:
1061 __ Fcvtzu(i.OutputRegister64(), i.InputFloat32Register(0)); 1061 __ Fcvtzu(i.OutputRegister64(), i.InputFloat32Register(0));
1062 if (i.OutputCount() > 1) { 1062 if (i.OutputCount() > 1) {
1063 __ Fcmp(i.InputFloat32Register(0), 0.0); 1063 __ Fcmp(i.InputFloat32Register(0), -1.0);
jbramley 2015/12/16 12:49:37 Is -1.0 supposed to be inclusive? If not, "ge" nee
ahaas 2015/12/16 16:15:25 done. I added a test for this case too.
1064 __ Ccmp(i.OutputRegister(0), -1, ZFlag, ge); 1064 __ Ccmp(i.OutputRegister(0), -1, ZFlag, ge);
1065 __ Cset(i.OutputRegister(1), ne); 1065 __ Cset(i.OutputRegister(1), ne);
1066 } 1066 }
1067 break; 1067 break;
1068 case kArm64Float64ToUint64: 1068 case kArm64Float64ToUint64:
1069 __ Fcvtzu(i.OutputRegister64(), i.InputDoubleRegister(0)); 1069 __ Fcvtzu(i.OutputRegister64(), i.InputDoubleRegister(0));
1070 if (i.OutputCount() > 1) { 1070 if (i.OutputCount() > 1) {
1071 __ Fcmp(i.InputDoubleRegister(0), 0.0); 1071 __ Fcmp(i.InputDoubleRegister(0), -1.0);
1072 __ Ccmp(i.OutputRegister(0), -1, ZFlag, ge); 1072 __ Ccmp(i.OutputRegister(0), -1, ZFlag, ge);
1073 __ Cset(i.OutputRegister(1), ne); 1073 __ Cset(i.OutputRegister(1), ne);
1074 } 1074 }
1075 break; 1075 break;
1076 case kArm64Int32ToFloat64: 1076 case kArm64Int32ToFloat64:
1077 __ Scvtf(i.OutputDoubleRegister(), i.InputRegister32(0)); 1077 __ Scvtf(i.OutputDoubleRegister(), i.InputRegister32(0));
1078 break; 1078 break;
1079 case kArm64Int64ToFloat32: 1079 case kArm64Int64ToFloat32:
1080 __ Scvtf(i.OutputDoubleRegister().S(), i.InputRegister64(0)); 1080 __ Scvtf(i.OutputDoubleRegister().S(), i.InputRegister64(0));
1081 break; 1081 break;
(...skipping 539 matching lines...) Expand 10 before | Expand all | Expand 10 after
1621 padding_size -= kInstructionSize; 1621 padding_size -= kInstructionSize;
1622 } 1622 }
1623 } 1623 }
1624 } 1624 }
1625 1625
1626 #undef __ 1626 #undef __
1627 1627
1628 } // namespace compiler 1628 } // namespace compiler
1629 } // namespace internal 1629 } // namespace internal
1630 } // namespace v8 1630 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/compiler/x64/code-generator-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698