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 | 4be0bd79a472f01c2310507df3150ecf3b57c88f (patch) | |
tree | abbfd7e638c4b318cbcb8410a168ce9a9e91de68 /llvm/lib/CodeGen/LiveDebugVariables.h | |
parent | ce2bd8d05f40f8269c975e28b1e743d75708ea98 (diff) | |
download | bcm5719-llvm-4be0bd79a472f01c2310507df3150ecf3b57c88f.tar.gz bcm5719-llvm-4be0bd79a472f01c2310507df3150ecf3b57c88f.zip |
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.
llvm-svn: 120636
Diffstat (limited to 'llvm/lib/CodeGen/LiveDebugVariables.h')
-rw-r--r-- | llvm/lib/CodeGen/LiveDebugVariables.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/LiveDebugVariables.h b/llvm/lib/CodeGen/LiveDebugVariables.h index eba4fbede27..2e4b05267dd 100644 --- a/llvm/lib/CodeGen/LiveDebugVariables.h +++ b/llvm/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; }; |