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

Side by Side Diff: src/compiler/simplified-lowering.cc

Issue 2050853003: [stubs] StringToNumberStub --> StringToNumber builtin. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 6 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 | « src/code-stubs.h ('k') | src/ia32/builtins-ia32.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/simplified-lowering.h" 5 #include "src/compiler/simplified-lowering.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "src/address-map.h" 9 #include "src/address-map.h"
10 #include "src/base/bits.h" 10 #include "src/base/bits.h"
(...skipping 1498 matching lines...) Expand 10 before | Expand all | Expand 10 after
1509 return; 1509 return;
1510 } 1510 }
1511 case IrOpcode::kStringFromCharCode: { 1511 case IrOpcode::kStringFromCharCode: {
1512 VisitUnop(node, UseInfo::TruncatingWord32(), 1512 VisitUnop(node, UseInfo::TruncatingWord32(),
1513 MachineRepresentation::kTagged); 1513 MachineRepresentation::kTagged);
1514 return; 1514 return;
1515 } 1515 }
1516 case IrOpcode::kStringToNumber: { 1516 case IrOpcode::kStringToNumber: {
1517 VisitUnop(node, UseInfo::AnyTagged(), MachineRepresentation::kTagged); 1517 VisitUnop(node, UseInfo::AnyTagged(), MachineRepresentation::kTagged);
1518 if (lower()) { 1518 if (lower()) {
1519 // StringToNumber(x) => Call(StringToNumberStub, x, no-context) 1519 // StringToNumber(x) => Call(StringToNumber, x, no-context)
1520 Operator::Properties properties = Operator::kNoThrow; 1520 Operator::Properties properties = Operator::kNoThrow;
1521 Callable callable = CodeFactory::StringToNumber(jsgraph_->isolate()); 1521 Callable callable = CodeFactory::StringToNumber(jsgraph_->isolate());
1522 CallDescriptor::Flags flags = CallDescriptor::kNoFlags; 1522 CallDescriptor::Flags flags = CallDescriptor::kNoFlags;
1523 CallDescriptor* desc = Linkage::GetStubCallDescriptor( 1523 CallDescriptor* desc = Linkage::GetStubCallDescriptor(
1524 jsgraph_->isolate(), jsgraph_->zone(), callable.descriptor(), 0, 1524 jsgraph_->isolate(), jsgraph_->zone(), callable.descriptor(), 0,
1525 flags, properties); 1525 flags, properties);
1526 node->InsertInput(jsgraph_->zone(), 0, 1526 node->InsertInput(jsgraph_->zone(), 0,
1527 jsgraph_->HeapConstant(callable.code())); 1527 jsgraph_->HeapConstant(callable.code()));
1528 node->AppendInput(jsgraph_->zone(), jsgraph_->NoContextConstant()); 1528 node->AppendInput(jsgraph_->zone(), jsgraph_->NoContextConstant());
1529 node->AppendInput(jsgraph_->zone(), jsgraph_->graph()->start()); 1529 node->AppendInput(jsgraph_->zone(), jsgraph_->graph()->start());
(...skipping 1289 matching lines...) Expand 10 before | Expand all | Expand 10 after
2819 isolate(), graph()->zone(), callable.descriptor(), 0, flags, 2819 isolate(), graph()->zone(), callable.descriptor(), 0, flags,
2820 Operator::kNoProperties); 2820 Operator::kNoProperties);
2821 to_number_operator_.set(common()->Call(desc)); 2821 to_number_operator_.set(common()->Call(desc));
2822 } 2822 }
2823 return to_number_operator_.get(); 2823 return to_number_operator_.get();
2824 } 2824 }
2825 2825
2826 } // namespace compiler 2826 } // namespace compiler
2827 } // namespace internal 2827 } // namespace internal
2828 } // namespace v8 2828 } // namespace v8
OLDNEW
« no previous file with comments | « src/code-stubs.h ('k') | src/ia32/builtins-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698