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

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

Issue 850073002: [turbofan] Allow 0.0 as immediate for floating-point comparison on arm/arm64. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 11 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/compiler/arm/instruction-selector-arm.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/arm/macro-assembler-arm.h" 7 #include "src/arm/macro-assembler-arm.h"
8 #include "src/compiler/code-generator-impl.h" 8 #include "src/compiler/code-generator-impl.h"
9 #include "src/compiler/gap-resolver.h" 9 #include "src/compiler/gap-resolver.h"
10 #include "src/compiler/node-matchers.h" 10 #include "src/compiler/node-matchers.h"
(...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after
487 break; 487 break;
488 case kArmTst: 488 case kArmTst:
489 __ tst(i.InputRegister(0), i.InputOperand2(1)); 489 __ tst(i.InputRegister(0), i.InputOperand2(1));
490 DCHECK_EQ(SetCC, i.OutputSBit()); 490 DCHECK_EQ(SetCC, i.OutputSBit());
491 break; 491 break;
492 case kArmTeq: 492 case kArmTeq:
493 __ teq(i.InputRegister(0), i.InputOperand2(1)); 493 __ teq(i.InputRegister(0), i.InputOperand2(1));
494 DCHECK_EQ(SetCC, i.OutputSBit()); 494 DCHECK_EQ(SetCC, i.OutputSBit());
495 break; 495 break;
496 case kArmVcmpF64: 496 case kArmVcmpF64:
497 __ VFPCompareAndSetFlags(i.InputFloat64Register(0), 497 if (instr->InputAt(1)->IsDoubleRegister()) {
498 i.InputFloat64Register(1)); 498 __ VFPCompareAndSetFlags(i.InputFloat64Register(0),
499 i.InputFloat64Register(1));
500 } else {
501 DCHECK(instr->InputAt(1)->IsImmediate());
502 // 0.0 is the only immediate supported by vcmp instructions.
503 DCHECK(i.InputDouble(1) == 0.0);
504 __ VFPCompareAndSetFlags(i.InputFloat64Register(0), i.InputDouble(1));
505 }
499 DCHECK_EQ(SetCC, i.OutputSBit()); 506 DCHECK_EQ(SetCC, i.OutputSBit());
500 break; 507 break;
501 case kArmVaddF64: 508 case kArmVaddF64:
502 __ vadd(i.OutputFloat64Register(), i.InputFloat64Register(0), 509 __ vadd(i.OutputFloat64Register(), i.InputFloat64Register(0),
503 i.InputFloat64Register(1)); 510 i.InputFloat64Register(1));
504 DCHECK_EQ(LeaveCC, i.OutputSBit()); 511 DCHECK_EQ(LeaveCC, i.OutputSBit());
505 break; 512 break;
506 case kArmVsubF64: 513 case kArmVsubF64:
507 __ vsub(i.OutputFloat64Register(), i.InputFloat64Register(0), 514 __ vsub(i.OutputFloat64Register(), i.InputFloat64Register(0),
508 i.InputFloat64Register(1)); 515 i.InputFloat64Register(1));
(...skipping 520 matching lines...) Expand 10 before | Expand all | Expand 10 after
1029 } 1036 }
1030 } 1037 }
1031 MarkLazyDeoptSite(); 1038 MarkLazyDeoptSite();
1032 } 1039 }
1033 1040
1034 #undef __ 1041 #undef __
1035 1042
1036 } // namespace compiler 1043 } // namespace compiler
1037 } // namespace internal 1044 } // namespace internal
1038 } // namespace v8 1045 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/compiler/arm/instruction-selector-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698