From 09f162ca6a10446d6377b957f3a58ac92ce38306 Mon Sep 17 00:00:00 2001 From: Devang Patel Date: Tue, 1 May 2007 21:15:47 +0000 Subject: Do not use typeinfo to identify pass in pass manager. llvm-svn: 36632 --- llvm/lib/CodeGen/PHIElimination.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'llvm/lib/CodeGen/PHIElimination.cpp') diff --git a/llvm/lib/CodeGen/PHIElimination.cpp b/llvm/lib/CodeGen/PHIElimination.cpp index 0b77fe26696..f26819d9e29 100644 --- a/llvm/lib/CodeGen/PHIElimination.cpp +++ b/llvm/lib/CodeGen/PHIElimination.cpp @@ -33,6 +33,9 @@ STATISTIC(NumAtomic, "Number of atomic phis lowered"); namespace { struct VISIBILITY_HIDDEN PNE : public MachineFunctionPass { + static const int ID; // Pass identifcation, replacement for typeid + PNE() : MachineFunctionPass((intptr_t)&ID) {} + bool runOnMachineFunction(MachineFunction &Fn) { analyzePHINodes(Fn); @@ -73,6 +76,7 @@ namespace { VRegPHIUse VRegPHIUseCount; }; + const int PNE::ID = 0; RegisterPass X("phi-node-elimination", "Eliminate PHI nodes for register allocation"); } -- cgit v1.2.3