llvm-project/llvm/lib/Transforms/InstCombine
Sanjay Patel e359eaaf70 [InstCombine] change bitwise logic type to eliminate bitcasts
In PR27925:
https://llvm.org/bugs/show_bug.cgi?id=27925

...we proposed adding this fold to eliminate a bitcast. In D20774, there was 
some concern about changing the type of a bitwise op as well as creating 
bitcasts that might not be free for a target. However, if we're strictly 
eliminating an instruction (by limiting this to one-use ops), then we should 
be able to do this in InstCombine.

But we're cautiously restricting the transform for now to vector types to
avoid possible backend problems. A transform to make sure the logic op is
legal for the target should be added to reverse this transform and improve
codegen.

Differential Revision: https://reviews.llvm.org/D26641

llvm-svn: 287707
2016-11-22 22:05:48 +00:00
..
CMakeLists.txt [CMake] NFC. Updating CMake dependency specifications 2016-11-17 04:36:50 +00:00
InstCombineAddSub.cpp [InstCombine] use m_APInt to allow sub with constant folds for splat vectors 2016-10-14 16:31:54 +00:00
InstCombineAndOrXor.cpp [InstCombine] add helper function for folding {and,or,xor} (cast X), C ; NFCI 2016-09-12 00:16:23 +00:00
InstCombineCalls.cpp [InstCombine][AVX-512] Teach InstCombineCalls how to handle the intrinsics for variable shift with 16-bit elements. 2016-11-18 06:04:33 +00:00
InstCombineCasts.cpp [InstCombine] change bitwise logic type to eliminate bitcasts 2016-11-22 22:05:48 +00:00
InstCombineCompares.cpp [InstCombine] Fold nuw left-shifts in `ugt`/`ule` comparisons. 2016-11-01 19:19:29 +00:00
InstCombineInternal.h [InstCombine] handle simple vector integer constants in IsFreeToInvert 2016-10-27 17:30:50 +00:00
InstCombineLoadStoreAlloca.cpp Analysis: Move llvm::getConstantRangeFromMetadata to IR library. 2016-10-21 19:59:26 +00:00
InstCombineMulDivRem.cpp fix formatting; NFC 2016-11-21 21:48:36 +00:00
InstCombinePHI.cpp Use the range variant of find/find_if instead of unpacking begin/end 2016-08-12 03:55:06 +00:00
InstCombineSelect.cpp [InstCombine] canonicalize min/max constant to select's false value 2016-11-21 22:04:14 +00:00
InstCombineShifts.cpp [InstCombine] Folding of shifts by the sum of positive values 2016-11-01 15:40:30 +00:00
InstCombineSimplifyDemanded.cpp [X86] Remove the scalar intrinsics for fadd/fsub/fdiv/fmul 2016-11-16 05:24:10 +00:00
InstCombineVectorOps.cpp [InstCombine] avoid infinite loop from shuffle-extract-insert sequence (PR30923) 2016-11-10 00:15:14 +00:00
InstructionCombining.cpp Fix spelling mistakes in Transforms comments. NFC. 2016-11-20 13:19:49 +00:00
LLVMBuild.txt Update libdeps since TLI was moved from Target to Analysis in r226078. 2015-01-15 05:21:00 +00:00