diff --git a/llvm/include/llvm/CodeGen/LiveVariables.h b/llvm/include/llvm/CodeGen/LiveVariables.h index 90aeb8ceda559..9ed4c7bdf7b17 100644 --- a/llvm/include/llvm/CodeGen/LiveVariables.h +++ b/llvm/include/llvm/CodeGen/LiveVariables.h @@ -118,11 +118,6 @@ class LiveVariables : public MachineFunctionPass { /// IndexedMap VirtRegInfo; - /// PHIJoins - list of virtual registers that are PHI joins. These registers - /// may have multiple definitions, and they require special handling when - /// building live intervals. - SparseBitVector<> PHIJoins; - private: // Intermediate data structures MachineFunction *MF = nullptr; @@ -302,12 +297,6 @@ class LiveVariables : public MachineFunctionPass { MachineBasicBlock *DomBB, MachineBasicBlock *SuccBB, std::vector> &LiveInSets); - - /// isPHIJoin - Return true if Reg is a phi join register. - bool isPHIJoin(Register Reg) { return PHIJoins.test(Reg.id()); } - - /// setPHIJoin - Mark Reg as a phi join register. - void setPHIJoin(Register Reg) { PHIJoins.set(Reg.id()); } }; } // End llvm namespace diff --git a/llvm/lib/CodeGen/LiveVariables.cpp b/llvm/lib/CodeGen/LiveVariables.cpp index 077276b64aa22..6b983b6320c71 100644 --- a/llvm/lib/CodeGen/LiveVariables.cpp +++ b/llvm/lib/CodeGen/LiveVariables.cpp @@ -601,7 +601,6 @@ bool LiveVariables::runOnMachineFunction(MachineFunction &mf) { PhysRegDef.assign(NumRegs, nullptr); PhysRegUse.assign(NumRegs, nullptr); PHIVarInfo.resize(MF->getNumBlockIDs()); - PHIJoins.clear(); // FIXME: LiveIntervals will be updated to remove its dependence on // LiveVariables to improve compilation time and eliminate bizarre pass diff --git a/llvm/lib/CodeGen/PHIElimination.cpp b/llvm/lib/CodeGen/PHIElimination.cpp index dbb9a9ffdf60b..10d8378ce58d1 100644 --- a/llvm/lib/CodeGen/PHIElimination.cpp +++ b/llvm/lib/CodeGen/PHIElimination.cpp @@ -330,9 +330,6 @@ void PHIElimination::LowerPHINode(MachineBasicBlock &MBB, if (IncomingReg) { LiveVariables::VarInfo &VI = LV->getVarInfo(IncomingReg); - // Increment use count of the newly created virtual register. - LV->setPHIJoin(IncomingReg); - MachineInstr *OldKill = nullptr; bool IsPHICopyAfterOldKill = false;