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

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

Issue 938443002: [es6] implement spread calls (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: rebase + clang-format Created 5 years, 8 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 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 #ifndef V8_FULL_CODEGEN_H_ 5 #ifndef V8_FULL_CODEGEN_H_
6 #define V8_FULL_CODEGEN_H_ 6 #define V8_FULL_CODEGEN_H_
7 7
8 #include "src/v8.h" 8 #include "src/v8.h"
9 9
10 #include "src/allocation.h" 10 #include "src/allocation.h"
(...skipping 540 matching lines...) Expand 10 before | Expand all | Expand 10 after
551 F(DebugBreakInOptimizedCode) \ 551 F(DebugBreakInOptimizedCode) \
552 F(ClassOf) \ 552 F(ClassOf) \
553 F(StringCharCodeAt) \ 553 F(StringCharCodeAt) \
554 F(StringAdd) \ 554 F(StringAdd) \
555 F(SubString) \ 555 F(SubString) \
556 F(StringCompare) \ 556 F(StringCompare) \
557 F(RegExpExec) \ 557 F(RegExpExec) \
558 F(RegExpConstructResult) \ 558 F(RegExpConstructResult) \
559 F(GetFromCache) \ 559 F(GetFromCache) \
560 F(NumberToString) \ 560 F(NumberToString) \
561 F(DebugIsActive) 561 F(DebugIsActive) \
562 F(CallSuperWithSpread)
562 563
563 #define GENERATOR_DECLARATION(Name) void Emit##Name(CallRuntime* call); 564 #define GENERATOR_DECLARATION(Name) void Emit##Name(CallRuntime* call);
564 FOR_EACH_FULL_CODE_INTRINSIC(GENERATOR_DECLARATION) 565 FOR_EACH_FULL_CODE_INTRINSIC(GENERATOR_DECLARATION)
565 #undef GENERATOR_DECLARATION 566 #undef GENERATOR_DECLARATION
566 567
567 // Platform-specific code for resuming generators. 568 // Platform-specific code for resuming generators.
568 void EmitGeneratorResume(Expression *generator, 569 void EmitGeneratorResume(Expression *generator,
569 Expression *value, 570 Expression *value,
570 JSGeneratorObject::ResumeMode resume_mode); 571 JSGeneratorObject::ResumeMode resume_mode);
571 572
(...skipping 10 matching lines...) Expand all
582 583
583 void EmitAccessor(Expression* expression); 584 void EmitAccessor(Expression* expression);
584 585
585 // Expects the arguments and the function already pushed. 586 // Expects the arguments and the function already pushed.
586 void EmitResolvePossiblyDirectEval(int arg_count); 587 void EmitResolvePossiblyDirectEval(int arg_count);
587 588
588 // Platform-specific support for allocating a new closure based on 589 // Platform-specific support for allocating a new closure based on
589 // the given function info. 590 // the given function info.
590 void EmitNewClosure(Handle<SharedFunctionInfo> info, bool pretenure); 591 void EmitNewClosure(Handle<SharedFunctionInfo> info, bool pretenure);
591 592
593 // Re-usable portions of CallRuntime
594 void EmitLoadJSRuntimeFunction(CallRuntime* expr);
595 void EmitCallJSRuntimeFunction(CallRuntime* expr);
596
592 // Platform-specific support for compiling assignments. 597 // Platform-specific support for compiling assignments.
593 598
594 // Left-hand side can only be a property, a global or a (parameter or local) 599 // Left-hand side can only be a property, a global or a (parameter or local)
595 // slot. 600 // slot.
596 enum LhsKind { 601 enum LhsKind {
597 VARIABLE, 602 VARIABLE,
598 NAMED_PROPERTY, 603 NAMED_PROPERTY,
599 KEYED_PROPERTY, 604 KEYED_PROPERTY,
600 NAMED_SUPER_PROPERTY, 605 NAMED_SUPER_PROPERTY,
601 KEYED_SUPER_PROPERTY 606 KEYED_SUPER_PROPERTY
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
679 static bool NeedsHomeObject(Expression* expr) { 684 static bool NeedsHomeObject(Expression* expr) {
680 return FunctionLiteral::NeedsHomeObject(expr); 685 return FunctionLiteral::NeedsHomeObject(expr);
681 } 686 }
682 687
683 // Adds the [[HomeObject]] to |initializer| if it is a FunctionLiteral. 688 // Adds the [[HomeObject]] to |initializer| if it is a FunctionLiteral.
684 // The value of the initializer is expected to be at the top of the stack. 689 // The value of the initializer is expected to be at the top of the stack.
685 // |offset| is the offset in the stack where the home object can be found. 690 // |offset| is the offset in the stack where the home object can be found.
686 void EmitSetHomeObjectIfNeeded(Expression* initializer, int offset); 691 void EmitSetHomeObjectIfNeeded(Expression* initializer, int offset);
687 692
688 void EmitLoadSuperConstructor(); 693 void EmitLoadSuperConstructor();
694 void EmitInitializeThisAfterSuper(SuperReference* super_ref);
689 695
690 void CallIC(Handle<Code> code, 696 void CallIC(Handle<Code> code,
691 TypeFeedbackId id = TypeFeedbackId::None()); 697 TypeFeedbackId id = TypeFeedbackId::None());
692 698
693 void CallLoadIC(ContextualMode mode, 699 void CallLoadIC(ContextualMode mode,
694 TypeFeedbackId id = TypeFeedbackId::None()); 700 TypeFeedbackId id = TypeFeedbackId::None());
695 void CallGlobalLoadIC(Handle<String> name); 701 void CallGlobalLoadIC(Handle<String> name);
696 void CallStoreIC(TypeFeedbackId id = TypeFeedbackId::None()); 702 void CallStoreIC(TypeFeedbackId id = TypeFeedbackId::None());
697 703
698 void SetFunctionPosition(FunctionLiteral* fun); 704 void SetFunctionPosition(FunctionLiteral* fun);
(...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after
1092 1098
1093 Address start_; 1099 Address start_;
1094 Address instruction_start_; 1100 Address instruction_start_;
1095 uint32_t length_; 1101 uint32_t length_;
1096 }; 1102 };
1097 1103
1098 1104
1099 } } // namespace v8::internal 1105 } } // namespace v8::internal
1100 1106
1101 #endif // V8_FULL_CODEGEN_H_ 1107 #endif // V8_FULL_CODEGEN_H_
OLDNEW
« no previous file with comments | « src/flag-definitions.h ('k') | src/full-codegen.cc » ('j') | test/js-perf-test/JSTests.json » ('J')

Powered by Google App Engine
This is Rietveld 408576698