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

Side by Side Diff: src/full-codegen/full-codegen.cc

Issue 2913783002: [builtins] Begin removing CodeFactory accessors (Closed)
Patch Set: V8_EXPORT_PRIVATE Created 3 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/crankshaft/x87/lithium-codegen-x87.cc ('k') | src/interpreter/interpreter-generator.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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/full-codegen/full-codegen.h" 5 #include "src/full-codegen/full-codegen.h"
6 6
7 #include "src/ast/ast-numbering.h" 7 #include "src/ast/ast-numbering.h"
8 #include "src/ast/ast.h" 8 #include "src/ast/ast.h"
9 #include "src/ast/prettyprinter.h" 9 #include "src/ast/prettyprinter.h"
10 #include "src/ast/scopes.h" 10 #include "src/ast/scopes.h"
(...skipping 596 matching lines...) Expand 10 before | Expand all | Expand 10 after
607 607
608 // Reload the context register after the call as i.e. TurboFan code stubs 608 // Reload the context register after the call as i.e. TurboFan code stubs
609 // won't preserve the context register. 609 // won't preserve the context register.
610 LoadFromFrameField(StandardFrameConstants::kContextOffset, 610 LoadFromFrameField(StandardFrameConstants::kContextOffset,
611 context_register()); 611 context_register());
612 context()->Plug(result_register()); 612 context()->Plug(result_register());
613 } 613 }
614 614
615 615
616 void FullCodeGenerator::EmitToString(CallRuntime* expr) { 616 void FullCodeGenerator::EmitToString(CallRuntime* expr) {
617 EmitIntrinsicAsStubCall(expr, CodeFactory::ToString(isolate())); 617 EmitIntrinsicAsStubCall(
618 expr, Builtins::CallableFor(isolate(), Builtins::kToString));
618 } 619 }
619 620
620 621
621 void FullCodeGenerator::EmitToLength(CallRuntime* expr) { 622 void FullCodeGenerator::EmitToLength(CallRuntime* expr) {
622 EmitIntrinsicAsStubCall(expr, CodeFactory::ToLength(isolate())); 623 EmitIntrinsicAsStubCall(expr, CodeFactory::ToLength(isolate()));
623 } 624 }
624 625
625 void FullCodeGenerator::EmitToInteger(CallRuntime* expr) { 626 void FullCodeGenerator::EmitToInteger(CallRuntime* expr) {
626 EmitIntrinsicAsStubCall(expr, CodeFactory::ToInteger(isolate())); 627 EmitIntrinsicAsStubCall(expr, CodeFactory::ToInteger(isolate()));
627 } 628 }
628 629
629 void FullCodeGenerator::EmitToNumber(CallRuntime* expr) { 630 void FullCodeGenerator::EmitToNumber(CallRuntime* expr) {
630 EmitIntrinsicAsStubCall(expr, CodeFactory::ToNumber(isolate())); 631 EmitIntrinsicAsStubCall(expr, CodeFactory::ToNumber(isolate()));
631 } 632 }
632 633
633 634
634 void FullCodeGenerator::EmitToObject(CallRuntime* expr) { 635 void FullCodeGenerator::EmitToObject(CallRuntime* expr) {
635 EmitIntrinsicAsStubCall(expr, CodeFactory::ToObject(isolate())); 636 EmitIntrinsicAsStubCall(
637 expr, Builtins::CallableFor(isolate(), Builtins::kToObject));
636 } 638 }
637 639
638 640
639 void FullCodeGenerator::EmitHasProperty() { 641 void FullCodeGenerator::EmitHasProperty() {
640 Callable callable = CodeFactory::HasProperty(isolate()); 642 Callable callable = CodeFactory::HasProperty(isolate());
641 PopOperand(callable.descriptor().GetRegisterParameter(1)); 643 PopOperand(callable.descriptor().GetRegisterParameter(1));
642 PopOperand(callable.descriptor().GetRegisterParameter(0)); 644 PopOperand(callable.descriptor().GetRegisterParameter(0));
643 __ Call(callable.code(), RelocInfo::CODE_TARGET); 645 __ Call(callable.code(), RelocInfo::CODE_TARGET);
644 RestoreContext(); 646 RestoreContext();
645 } 647 }
(...skipping 967 matching lines...) Expand 10 before | Expand all | Expand 10 after
1613 1615
1614 const FeedbackVectorSpec* FullCodeGenerator::feedback_vector_spec() const { 1616 const FeedbackVectorSpec* FullCodeGenerator::feedback_vector_spec() const {
1615 return literal()->feedback_vector_spec(); 1617 return literal()->feedback_vector_spec();
1616 } 1618 }
1617 1619
1618 #undef __ 1620 #undef __
1619 1621
1620 1622
1621 } // namespace internal 1623 } // namespace internal
1622 } // namespace v8 1624 } // namespace v8
OLDNEW
« no previous file with comments | « src/crankshaft/x87/lithium-codegen-x87.cc ('k') | src/interpreter/interpreter-generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698