diff options
author | Frits van Bommel <fvbommel@gmail.com> | 2011-03-27 23:32:31 +0000 |
---|---|---|
committer | Frits van Bommel <fvbommel@gmail.com> | 2011-03-27 23:32:31 +0000 |
commit | f56762a96dbd602f1205ff9e6d1b700d5b4a6c8a (patch) | |
tree | ad5147f8cc009002ea75104151d8d3322ac30522 /lib/Transforms | |
parent | ef1f5ccca7efaa18209523b31019d356d302f635 (diff) |
Add some debug output when -instcombine uses RAUW. This can make debug output for those cases much clearer since without this it only showed that the original instruction was removed, not what it was replaced with.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@128399 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms')
-rw-r--r-- | lib/Transforms/InstCombine/InstCombine.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/Transforms/InstCombine/InstCombine.h b/lib/Transforms/InstCombine/InstCombine.h index 0da962a5f4..d5de53aa92 100644 --- a/lib/Transforms/InstCombine/InstCombine.h +++ b/lib/Transforms/InstCombine/InstCombine.h @@ -246,7 +246,10 @@ public: // segment of unreachable code, so just clobber the instruction. if (&I == V) V = UndefValue::get(I.getType()); - + + DEBUG(errs() << "IC: Replacing " << I << "\n" + " with " << *V << '\n'); + I.replaceAllUsesWith(V); return &I; } |