[PATCH] A bit-tracking DCE Pass

hfinkel at anl.gov hfinkel at anl.gov
Tue Feb 10 18:15:34 PST 2015


Updated to reflect Sanjoy's suggestions. We can now remove the dependence on a dead function return value even if we can't remove the function itself. I've added a test case for that.

Also, I chatted earlier with James, who suggested looking at how this relates to the implementation of InstCombiner::SimplifyDemandedUseBits. I did not see any obvious way of refactoring the logic there so that it could be reused here, but looking at the implementation did point out that I needed a few more lines of code to correctly handle nsw/nuw/exact flags on the shift operators. That's now been added too.


http://reviews.llvm.org/D7531

Files:
  include/llvm-c/Transforms/Scalar.h
  include/llvm/InitializePasses.h
  include/llvm/LinkAllPasses.h
  include/llvm/Transforms/Scalar.h
  lib/Transforms/IPO/PassManagerBuilder.cpp
  lib/Transforms/Scalar/BDCE.cpp
  lib/Transforms/Scalar/CMakeLists.txt
  lib/Transforms/Scalar/Scalar.cpp
  test/Transforms/BDCE/basic.ll

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D7531.19725.patch
Type: text/x-patch
Size: 23642 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150211/00532396/attachment.bin>


More information about the llvm-commits mailing list