| Index: runtime/vm/intermediate_language.cc
|
| diff --git a/runtime/vm/intermediate_language.cc b/runtime/vm/intermediate_language.cc
|
| index 87e5407ce22e6968396bfe23f4293e389e4d84c9..8f48cbe94e77ee0ba41b9850597ecbbe73a3498d 100644
|
| --- a/runtime/vm/intermediate_language.cc
|
| +++ b/runtime/vm/intermediate_language.cc
|
| @@ -937,6 +937,16 @@ void JoinEntryInstr::InsertPhi(PhiInstr* phi) {
|
| phis_->Add(phi);
|
| }
|
|
|
| +void JoinEntryInstr::RemovePhi(PhiInstr* phi) {
|
| + ASSERT(phis_ != NULL);
|
| + for (intptr_t index = 0; index < phis_->length(); ++index) {
|
| + if (phi == (*phis_)[index]) {
|
| + (*phis_)[index] = phis_->Last();
|
| + phis_->RemoveLast();
|
| + return;
|
| + }
|
| + }
|
| +}
|
|
|
| void JoinEntryInstr::RemoveDeadPhis(Definition* replacement) {
|
| if (phis_ == NULL) return;
|
|
|