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

Side by Side Diff: src/crankshaft/arm64/lithium-arm64.cc

Issue 1744163002: [stubs] Introduce a proper ToBooleanStub. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix mips Created 4 years, 9 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
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/crankshaft/arm64/lithium-arm64.h" 5 #include "src/crankshaft/arm64/lithium-arm64.h"
6 6
7 #include <sstream> 7 #include <sstream>
8 8
9 #include "src/crankshaft/arm64/lithium-codegen-arm64.h" 9 #include "src/crankshaft/arm64/lithium-codegen-arm64.h"
10 #include "src/crankshaft/hydrogen-osr.h" 10 #include "src/crankshaft/hydrogen-osr.h"
(...skipping 954 matching lines...) Expand 10 before | Expand all | Expand 10 after
965 type.IsHeapNumber()) { 965 type.IsHeapNumber()) {
966 // These types have simple checks that cannot deoptimize. 966 // These types have simple checks that cannot deoptimize.
967 return new(zone()) LBranch(UseRegister(value), NULL, NULL); 967 return new(zone()) LBranch(UseRegister(value), NULL, NULL);
968 } 968 }
969 969
970 if (type.IsString()) { 970 if (type.IsString()) {
971 // This type cannot deoptimize, but needs a scratch register. 971 // This type cannot deoptimize, but needs a scratch register.
972 return new(zone()) LBranch(UseRegister(value), TempRegister(), NULL); 972 return new(zone()) LBranch(UseRegister(value), TempRegister(), NULL);
973 } 973 }
974 974
975 ToBooleanStub::Types expected = instr->expected_input_types(); 975 ToBooleanICStub::Types expected = instr->expected_input_types();
976 bool needs_temps = expected.NeedsMap() || expected.IsEmpty(); 976 bool needs_temps = expected.NeedsMap() || expected.IsEmpty();
977 LOperand* temp1 = needs_temps ? TempRegister() : NULL; 977 LOperand* temp1 = needs_temps ? TempRegister() : NULL;
978 LOperand* temp2 = needs_temps ? TempRegister() : NULL; 978 LOperand* temp2 = needs_temps ? TempRegister() : NULL;
979 979
980 if (expected.IsGeneric() || expected.IsEmpty()) { 980 if (expected.IsGeneric() || expected.IsEmpty()) {
981 // The generic case cannot deoptimize because it already supports every 981 // The generic case cannot deoptimize because it already supports every
982 // possible input type. 982 // possible input type.
983 DCHECK(needs_temps); 983 DCHECK(needs_temps);
984 return new(zone()) LBranch(UseRegister(value), temp1, temp2); 984 return new(zone()) LBranch(UseRegister(value), temp1, temp2);
985 } else { 985 } else {
(...skipping 1657 matching lines...) Expand 10 before | Expand all | Expand 10 after
2643 2643
2644 2644
2645 LInstruction* LChunkBuilder::DoStoreFrameContext(HStoreFrameContext* instr) { 2645 LInstruction* LChunkBuilder::DoStoreFrameContext(HStoreFrameContext* instr) {
2646 LOperand* context = UseRegisterAtStart(instr->context()); 2646 LOperand* context = UseRegisterAtStart(instr->context());
2647 return new(zone()) LStoreFrameContext(context); 2647 return new(zone()) LStoreFrameContext(context);
2648 } 2648 }
2649 2649
2650 2650
2651 } // namespace internal 2651 } // namespace internal
2652 } // namespace v8 2652 } // namespace v8
OLDNEW
« no previous file with comments | « src/crankshaft/arm/lithium-codegen-arm.cc ('k') | src/crankshaft/arm64/lithium-codegen-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698