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

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

Issue 1507703002: [turbofan] Change TruncateFloat64ToUint64 to TryTruncateFloatToUint64. (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/arm64/instruction-selector-arm64.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 1034 matching lines...) Expand 10 before | Expand all | Expand 10 after
1045 __ Ccmp(i.OutputRegister(0), -1, VFlag, vc); 1045 __ Ccmp(i.OutputRegister(0), -1, VFlag, vc);
1046 __ Fccmp(i.InputDoubleRegister(0), i.InputDoubleRegister(0), VFlag, vc); 1046 __ Fccmp(i.InputDoubleRegister(0), i.InputDoubleRegister(0), VFlag, vc);
1047 __ Cset(i.OutputRegister(1), vc); 1047 __ Cset(i.OutputRegister(1), vc);
1048 } 1048 }
1049 break; 1049 break;
1050 case kArm64Float32ToUint64: 1050 case kArm64Float32ToUint64:
1051 __ Fcvtzu(i.OutputRegister64(), i.InputFloat32Register(0)); 1051 __ Fcvtzu(i.OutputRegister64(), i.InputFloat32Register(0));
1052 break; 1052 break;
1053 case kArm64Float64ToUint64: 1053 case kArm64Float64ToUint64:
1054 __ Fcvtzu(i.OutputRegister64(), i.InputDoubleRegister(0)); 1054 __ Fcvtzu(i.OutputRegister64(), i.InputDoubleRegister(0));
1055 if (i.OutputCount() > 1) {
1056 Label done;
1057 __ Fcmp(i.InputDoubleRegister(0), 0.0);
1058 __ Cset(i.OutputRegister(1), ge);
martyn.capewell 2015/12/07 16:10:34 You should be able to use conditional compare agai
ahaas 2015/12/07 17:03:03 Done
1059 __ B(lt, &done);
1060 __ Cmp(i.OutputRegister(0), -1);
1061 __ Cset(i.OutputRegister(1), ne);
1062 __ Bind(&done);
1063 }
1055 break; 1064 break;
1056 case kArm64Int32ToFloat64: 1065 case kArm64Int32ToFloat64:
1057 __ Scvtf(i.OutputDoubleRegister(), i.InputRegister32(0)); 1066 __ Scvtf(i.OutputDoubleRegister(), i.InputRegister32(0));
1058 break; 1067 break;
1059 case kArm64Int64ToFloat32: 1068 case kArm64Int64ToFloat32:
1060 __ Scvtf(i.OutputDoubleRegister().S(), i.InputRegister64(0)); 1069 __ Scvtf(i.OutputDoubleRegister().S(), i.InputRegister64(0));
1061 break; 1070 break;
1062 case kArm64Int64ToFloat64: 1071 case kArm64Int64ToFloat64:
1063 __ Scvtf(i.OutputDoubleRegister(), i.InputRegister64(0)); 1072 __ Scvtf(i.OutputDoubleRegister(), i.InputRegister64(0));
1064 break; 1073 break;
(...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after
1601 padding_size -= kInstructionSize; 1610 padding_size -= kInstructionSize;
1602 } 1611 }
1603 } 1612 }
1604 } 1613 }
1605 1614
1606 #undef __ 1615 #undef __
1607 1616
1608 } // namespace compiler 1617 } // namespace compiler
1609 } // namespace internal 1618 } // namespace internal
1610 } // namespace v8 1619 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/compiler/arm64/instruction-selector-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698