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

Unified Diff: runtime/vm/intermediate_language.cc

Issue 806973002: Cleanup access to Instruction's fields (especially deopt_id_). (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years 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
« runtime/vm/intermediate_language.h ('K') | « runtime/vm/intermediate_language.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/intermediate_language.cc
===================================================================
--- runtime/vm/intermediate_language.cc (revision 42367)
+++ runtime/vm/intermediate_language.cc (working copy)
@@ -756,7 +756,7 @@
void Instruction::InheritDeoptTarget(Isolate* isolate, Instruction* other) {
ASSERT(other->env() != NULL);
- deopt_id_ = other->deopt_id_;
+ CopyDeoptIdFrom(*other);
other->env()->DeepCopyTo(isolate, this);
env()->set_deopt_id(deopt_id_);
}
@@ -765,7 +765,7 @@
void BranchInstr::InheritDeoptTarget(Isolate* isolate, Instruction* other) {
ASSERT(env() == NULL);
Instruction::InheritDeoptTarget(isolate, other);
- comparison()->SetDeoptId(GetDeoptId());
+ comparison()->SetDeoptId(*this);
}
@@ -819,7 +819,7 @@
// Take other's environment from this definition.
ASSERT(other->env() == NULL);
other->SetEnvironment(env());
- env_ = NULL;
+ ClearEnv();
// Replace all uses of this definition with other.
ReplaceUsesWith(other);
// Reuse this instruction's SSA name for other.
@@ -953,7 +953,7 @@
ASSERT(instr->previous() == this);
GotoInstr* goto_join = new GotoInstr(AsJoinEntry());
- goto_join->deopt_id_ = parent->deopt_id_;
+ goto_join->CopyDeoptIdFrom(*parent);
graph_entry->normal_entry()->LinkTo(goto_join);
return true;
}
« runtime/vm/intermediate_language.h ('K') | « runtime/vm/intermediate_language.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698