diff options
author | Hsiangkai Wang <hsiangkai@gmail.com> | 2018-08-06 03:59:47 +0000 |
---|---|---|
committer | Hsiangkai Wang <hsiangkai@gmail.com> | 2018-08-06 03:59:47 +0000 |
commit | ef72e481ea11f5e1954bf3af41e2dc78f15836e3 (patch) | |
tree | cc5ede53ac602f31501a839caf17c0e4a8927b71 /llvm/lib/Transforms/InstCombine | |
parent | 4a73aa112b1ec2ac771c6d749a6843f2b38e5c64 (diff) | |
download | bcm5719-llvm-ef72e481ea11f5e1954bf3af41e2dc78f15836e3.tar.gz bcm5719-llvm-ef72e481ea11f5e1954bf3af41e2dc78f15836e3.zip |
[DebugInfo] Refactor DbgInfoIntrinsic class hierarchy.
In the past, DbgInfoIntrinsic has a strong assumption that these
intrinsics all have variables and expressions attached to them.
However, it is too strong to derive the class for other debug entities.
Now, it has problems for debug labels.
In order to make DbgInfoIntrinsic as a base class for 'debug info', I
create a class for 'variable debug info', DbgVariableIntrinsic.
DbgDeclareInst, DbgAddrIntrinsic, and DbgValueInst will be derived from it.
Differential Revision: https://reviews.llvm.org/D50220
llvm-svn: 338984
Diffstat (limited to 'llvm/lib/Transforms/InstCombine')
-rw-r--r-- | llvm/lib/Transforms/InstCombine/InstructionCombining.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp b/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp index cff0d544729..b87d5593f58 100644 --- a/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp +++ b/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp @@ -2144,7 +2144,7 @@ Instruction *InstCombiner::visitAllocSite(Instruction &MI) { // If we are removing an alloca with a dbg.declare, insert dbg.value calls // before each store. - TinyPtrVector<DbgInfoIntrinsic *> DIIs; + TinyPtrVector<DbgVariableIntrinsic *> DIIs; std::unique_ptr<DIBuilder> DIB; if (isa<AllocaInst>(MI)) { DIIs = FindDbgAddrUses(&MI); @@ -2934,7 +2934,7 @@ static bool TryToSinkInstruction(Instruction *I, BasicBlock *DestBlock) { // Also sink all related debug uses from the source basic block. Otherwise we // get debug use before the def. - SmallVector<DbgInfoIntrinsic *, 1> DbgUsers; + SmallVector<DbgVariableIntrinsic *, 1> DbgUsers; findDbgUsers(DbgUsers, I); for (auto *DII : DbgUsers) { if (DII->getParent() == SrcBlock) { |