llvm-project/llvm/tools/llvm-reduce
Arthur Eubanks 9660563950 [llvm-reduce] Add reduction passes to reduce operands to undef/1/0
Having non-undef constants in a final llvm-reduce output is nicer than
having undefs.

This splits the existing reduce-operands pass into three, one which does
the same as the current pass of reducing to undef, and two more to
reduce to the constant 1 and the constant 0. Do not reduce to undef if
the operand is a ConstantData, and do not reduce 0s to 1s.

Reducing GEP operands very frequently causes invalid IR (since types may
not match up if we index differently into a struct), so don't touch GEPs.

Reviewed By: Meinersbur

Differential Revision: https://reviews.llvm.org/D111765
2021-10-19 15:25:21 -07:00
..
deltas [llvm-reduce] Add reduction passes to reduce operands to undef/1/0 2021-10-19 15:25:21 -07:00
CMakeLists.txt [llvm-reduce] Introduce operands-to-args pass. 2021-10-13 09:54:03 -05:00
DeltaManager.cpp [llvm-reduce] Add reduction passes to reduce operands to undef/1/0 2021-10-19 15:25:21 -07:00
DeltaManager.h [llvm-reduce] Add flag to only run specific passes 2021-04-30 11:51:01 -07:00
TestRunner.cpp [NFC][llvm-reduce] Cleanup types 2021-10-10 18:07:28 -07:00
TestRunner.h [NFC][llvm-reduce] Cleanup types 2021-10-10 18:07:28 -07:00
llvm-reduce.cpp [NFC][llvm-reduce] Cleanup types 2021-10-10 18:07:28 -07:00