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

Unified Diff: src/crankshaft/hydrogen-instructions.h

Issue 1609893003: [es6] Tail calls support. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebasing Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/crankshaft/hydrogen.cc ('k') | src/crankshaft/ia32/lithium-codegen-ia32.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/crankshaft/hydrogen-instructions.h
diff --git a/src/crankshaft/hydrogen-instructions.h b/src/crankshaft/hydrogen-instructions.h
index 18af113e9923057fbbd0ac662eaba442b55b2594..53e8b0f645006afddd10bcadb9b17679eb676742 100644
--- a/src/crankshaft/hydrogen-instructions.h
+++ b/src/crankshaft/hydrogen-instructions.h
@@ -2395,13 +2395,19 @@ class HInvokeFunction final : public HBinaryCall {
class HCallFunction final : public HBinaryCall {
public:
- DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P3(HCallFunction, HValue*, int,
- ConvertReceiverMode);
+ DECLARE_INSTRUCTION_WITH_CONTEXT_FACTORY_P4(HCallFunction, HValue*, int,
+ ConvertReceiverMode,
+ TailCallMode);
HValue* context() const { return first(); }
HValue* function() const { return second(); }
- ConvertReceiverMode convert_mode() const { return convert_mode_; }
+ ConvertReceiverMode convert_mode() const {
+ return ConvertReceiverModeField::decode(bit_field_);
+ }
+ TailCallMode tail_call_mode() const {
+ return TailCallModeField::decode(bit_field_);
+ }
FeedbackVectorSlot slot() const { return slot_; }
Handle<TypeFeedbackVector> feedback_vector() const {
return feedback_vector_;
@@ -2421,12 +2427,19 @@ class HCallFunction final : public HBinaryCall {
private:
HCallFunction(HValue* context, HValue* function, int argument_count,
- ConvertReceiverMode convert_mode)
+ ConvertReceiverMode convert_mode, TailCallMode tail_call_mode)
: HBinaryCall(context, function, argument_count),
- convert_mode_(convert_mode) {}
+ bit_field_(ConvertReceiverModeField::encode(convert_mode) |
+ TailCallModeField::encode(tail_call_mode)) {}
Handle<TypeFeedbackVector> feedback_vector_;
FeedbackVectorSlot slot_;
- ConvertReceiverMode convert_mode_;
+
+ class ConvertReceiverModeField : public BitField<ConvertReceiverMode, 0, 2> {
+ };
+ class TailCallModeField
+ : public BitField<TailCallMode, ConvertReceiverModeField::kNext, 1> {};
+
+ uint32_t bit_field_;
};
« no previous file with comments | « src/crankshaft/hydrogen.cc ('k') | src/crankshaft/ia32/lithium-codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698