diff options
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2010-12-02 00:37:37 +0000 |
---|---|---|
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2010-12-02 00:37:37 +0000 |
commit | 0613516b16466a92c68d60734801221506c85e86 (patch) | |
tree | 5b29564569f13d977b7c2aa4c58914af83259737 /lib/CodeGen/LiveDebugVariables.h | |
parent | dff84b03258514463ede477af38f1246b95b0cd0 (diff) | |
download | llvm-0613516b16466a92c68d60734801221506c85e86.tar.gz llvm-0613516b16466a92c68d60734801221506c85e86.tar.bz2 llvm-0613516b16466a92c68d60734801221506c85e86.tar.xz |
Implement the first half of LiveDebugVariables.
Scan the MachineFunction for DBG_VALUE instructions, and replace them with a
data structure similar to LiveIntervals. The live range of a DBG_VALUE is
determined by propagating it down the dominator tree until a new DBG_VALUE is
found. When a DBG_VALUE lives in a register, its live range is confined to the
live range of the register's value.
LiveDebugVariables runs before coalescing, so DBG_VALUEs are not artificially
extended when registers are joined.
The missing half will recreate DBG_VALUE instructions from the intervals when
register allocation is complete.
The pass is disabled by default. It can be enabled with the temporary command
line option -live-debug-variables.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120636 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/LiveDebugVariables.h')
-rw-r--r-- | lib/CodeGen/LiveDebugVariables.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/LiveDebugVariables.h b/lib/CodeGen/LiveDebugVariables.h index eba4fbede2..2e4b05267d 100644 --- a/lib/CodeGen/LiveDebugVariables.h +++ b/lib/CodeGen/LiveDebugVariables.h @@ -31,6 +31,7 @@ public: static char ID; // Pass identification, replacement for typeid LiveDebugVariables(); + ~LiveDebugVariables(); /// renameRegister - Move any user variables in OldReg to NewReg:SubIdx. /// @param OldReg Old virtual register that is going away. @@ -45,9 +46,8 @@ public: private: - /// runOnMachineFunction - Analyze and remove DBG_VALUE instructions. virtual bool runOnMachineFunction(MachineFunction &); - + virtual void releaseMemory(); virtual void getAnalysisUsage(AnalysisUsage &) const; }; |