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

Unified Diff: src/compiler/schedule.h

Issue 1114163005: [turbofan] Fix tail call optimization. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: 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 side-by-side diff with in-line comments
Download patch
Index: src/compiler/schedule.h
diff --git a/src/compiler/schedule.h b/src/compiler/schedule.h
index 027a01dd4af03a9d46bdff6f52bed68672f5a1f5..37ce76299ed53858411f38493ee78275c0efeb61 100644
--- a/src/compiler/schedule.h
+++ b/src/compiler/schedule.h
@@ -37,6 +37,7 @@ class BasicBlock final : public ZoneObject {
kBranch, // Branch if true to first successor, otherwise second.
kSwitch, // Table dispatch to one of the successor blocks.
kDeoptimize, // Return a value from this method.
+ kTailCall, // Tail call another method from this method.
kReturn, // Return a value from this method.
kThrow // Throw an exception.
};
@@ -220,6 +221,9 @@ class Schedule final : public ZoneObject {
// BasicBlock building: add a deoptimize at the end of {block}.
void AddDeoptimize(BasicBlock* block, Node* input);
+ // BasicBlock building: add a tailcall at the end of {block}.
+ void AddTailCall(BasicBlock* block, Node* input);
+
// BasicBlock building: add a return at the end of {block}.
void AddReturn(BasicBlock* block, Node* input);

Powered by Google App Engine
This is Rietveld 408576698