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

Unified Diff: runtime/vm/intermediate_language.h

Issue 678763004: Make CTX allocatable by the register allocator. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 2 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: runtime/vm/intermediate_language.h
===================================================================
--- runtime/vm/intermediate_language.h (revision 41279)
+++ runtime/vm/intermediate_language.h (working copy)
@@ -726,7 +726,7 @@
locs_ = MakeLocationSummary(isolate, optimizing);
}
- static LocationSummary* MakeCallSummary();
+ static LocationSummary* MakeCallSummary(Isolate* isolate);
virtual void EmitNativeCode(FlowGraphCompiler* compiler) {
UNIMPLEMENTED();
@@ -1318,7 +1318,7 @@
ZoneGrowableArray<PhiInstr*>* phis() const { return phis_; }
- void InsertPhi(intptr_t var_index, intptr_t var_count);
+ void InsertPhi(intptr_t var_index, intptr_t var_count, bool always_live);
void RemoveDeadPhis(Definition* replacement);
void InsertPhi(PhiInstr* phi);
@@ -2583,19 +2583,28 @@
};
-class ClosureCallInstr : public TemplateDefinition<1> {
+class ClosureCallInstr : public TemplateDefinition<2> {
public:
+ enum {
+ kFunctionPos = 0,
+ kContextPos = 1
+ };
+
ClosureCallInstr(Value* function,
+ Value* context,
ClosureCallNode* node,
ZoneGrowableArray<PushArgumentInstr*>* arguments)
- : TemplateDefinition<1>(Isolate::Current()->GetNextDeoptId()),
+ : TemplateDefinition<2>(Isolate::Current()->GetNextDeoptId()),
ast_node_(*node),
arguments_(arguments) {
- SetInputAt(0, function);
+ SetInputAt(kFunctionPos, function);
+ SetInputAt(kContextPos, context);
}
DECLARE_INSTRUCTION(ClosureCall)
+ Value* context() const { return InputAt(kContextPos); }
+
const Array& argument_names() const { return ast_node_.arguments()->names(); }
virtual intptr_t token_pos() const { return ast_node_.token_pos(); }

Powered by Google App Engine
This is Rietveld 408576698