llvm-project/llvm/test/Transforms
Craig Topper 8324003818 [X86][InstCombine] Add basic simplification support for BEXTR/BEXTRI intrinsics.
This patch adds simplification support for the BEXTR/BEXTRI intrinsics to match gcc. This only supports cases that fold to 0 or can be fully constant folded. Theoretically we could support converting to AND if the shift part is unused or to only a shift if the mask doesn't modify any bits after an equivalent shl. gcc doesn't do these transformations either.

I put this in InstCombine, but it could be done in InstSimplify. It would be the first target specific intrinsic in InstSimplify.

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

llvm-svn: 309603
2017-07-31 18:52:13 +00:00
..
ADCE Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
AddDiscriminators [AddDiscriminators] Assign discriminators to MemIntrinsic calls. 2017-04-11 19:07:30 +00:00
AlignmentFromAssumptions
ArgumentPromotion Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
AtomicExpand Add address space mangling to lifetime intrinsics 2017-04-10 20:18:21 +00:00
BDCE Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
BranchFolding
CodeExtractor Clean up a test case 2017-06-27 21:35:49 +00:00
CodeGenPrepare [CGP] use subtract or subtract-of-cmps for result of memcmp expansion 2017-07-31 18:08:24 +00:00
ConstProp [X86] Replace 'REQUIRES: x86' in tests with 'REQUIRES: x86-registered-target' which seems to be the correct way to make them run on an x86 build. 2017-06-04 08:21:58 +00:00
ConstantHoisting [ConstantHoisting] Remove dupliate logic in constant hoisting 2017-07-10 20:45:34 +00:00
ConstantMerge Don't merge global constants with non-dbg metadata. 2017-03-09 00:03:37 +00:00
Coroutines Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
CorrelatedValuePropagation [LVI] Constant-propagate a zero extension of the switch condition value through case edges 2017-07-28 18:35:25 +00:00
CountingFunctionInserter
CrossDSOCFI [cfi] CFI-ICall for ThinLTO. 2017-06-16 00:18:29 +00:00
DCE [InstSimplify] Don't constant fold or DCE calls that are marked nobuiltin 2017-06-09 23:18:11 +00:00
DeadArgElim Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
DeadStoreElimination Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
EarlyCSE [EarlyCSE] Handle calls with no MemorySSA info. 2017-07-14 20:13:21 +00:00
EliminateAvailableExternally
Float2Int
ForcedFunctionAttrs
FunctionAttrs Support arbitrary address space pointers in masked gather/scatter intrinsics. 2017-05-03 12:28:54 +00:00
FunctionImport ThinLTO: Don't import aliases of any kind (even linkonce_odr) 2017-07-27 15:09:06 +00:00
GCOVProfiling
GVN [GVN] Recommit the patch "Add phi-translate support in scalarpre" 2017-07-28 15:47:25 +00:00
GVNHoist Disable GVN Hoist due to still more bugs being found in it. There is 2017-04-27 00:28:03 +00:00
GVNSink Changed a comparison operator for std::stable_sort to implement strict weak ordering. 2017-06-08 17:27:40 +00:00
GlobalDCE [PM] Teach the PGO instrumentation pasess to run GlobalDCE before 2017-05-25 07:15:09 +00:00
GlobalMerge Align definition of DW_OP_plus with DWARF spec [3/3] 2017-06-14 13:14:38 +00:00
GlobalOpt Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
GlobalSplit Fix one-after-the-end type metadata handling in globalsplit. 2017-03-07 22:18:48 +00:00
GuardWidening
IPConstantProp
IRCE [IRCE] Recognize loops with ne/eq latch conditions 2017-07-18 04:53:48 +00:00
IndVarSimplify Re-enable "[IndVars] Canonicalize comparisons between non-negative values and indvars" 2017-07-08 17:17:30 +00:00
InferAddressSpaces [InferAddressSpaces] Fix assertion about null pointer 2017-07-07 02:40:13 +00:00
InferFunctionAttrs Add argmononly attribute to strlen and wcslen, i.e. they only read memory (string) passed to them. 2017-06-18 03:10:26 +00:00
Inline [Inliner] Do not apply any bonus for cold callsites. 2017-07-28 21:47:36 +00:00
InstCombine [X86][InstCombine] Add basic simplification support for BEXTR/BEXTRI intrinsics. 2017-07-31 18:52:13 +00:00
InstMerge
InstNamer Add basic test case for -instnamer 2017-05-08 23:18:46 +00:00
InstSimplify [ConstantFolder] Don't try to fold gep when the idx is a vector. 2017-07-27 22:20:44 +00:00
InterleavedAccess Expanding the test case for vf8 for stride 4 interleaved. 2017-07-30 11:54:57 +00:00
Internalize
JumpThreading [JumpThreading] Stop falsely preserving LazyValueInfo. 2017-07-28 03:10:43 +00:00
LCSSA
LICM Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
LoadStoreVectorizer Skip bitcasts while looking for GEP in LoadStoreVectorizer 2017-04-25 18:00:08 +00:00
LoopDataPrefetch
LoopDeletion [LoopDeletion] Update exits correctly when multiple duplicate edges from an exiting block 2017-06-22 20:20:56 +00:00
LoopDistribute
LoopIdiom Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
LoopInterchange [LoopInterchange] Do not interchange loops with function calls. 2017-07-31 09:00:52 +00:00
LoopLoadElim
LoopPredication
LoopReroll Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
LoopRotate Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
LoopSimplify Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
LoopSimplifyCFG
LoopStrengthReduce Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
LoopUnroll [ARM] Enable partial and runtime unrolling 2017-07-25 08:51:30 +00:00
LoopUnswitch Add "REQUIRES: asserts" for test unswitch-equality-undef.ll. 2017-07-26 01:34:46 +00:00
LoopVectorize [LV] Avoid redundant operations manipulating masks 2017-07-31 13:21:42 +00:00
LoopVersioning [LAA] Correctly return a half-open range in expandBounds 2017-04-05 09:24:26 +00:00
LoopVersioningLICM [LAA] Correctly return a half-open range in expandBounds 2017-04-05 09:24:26 +00:00
LowerAtomic
LowerExpectIntrinsic Fix builin_expect lowering bug 2017-06-07 18:32:24 +00:00
LowerGuardIntrinsic
LowerInvoke
LowerSwitch LowerSwitch: Fix producing invalid IR on unreachable code 2017-04-21 23:54:12 +00:00
LowerTypeTests LowerTypeTests: Drop function type metadata only if we're going to replace it. 2017-07-20 18:02:05 +00:00
Mem2Reg Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
MemCpyOpt Add address space mangling to lifetime intrinsics 2017-04-10 20:18:21 +00:00
MergeFunc Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
MetaRenamer [MetaRenamer] Don't rename library functions. 2017-03-23 23:21:07 +00:00
NameAnonGlobals
NaryReassociate
NewGVN [NewGVN] Check for congruency of memory accesses. 2017-07-11 19:49:12 +00:00
ObjCARC Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
PGOProfile Migrate PGOMemOptSizeOpt to use new OptimizationRemarkEmitter Pass 2017-07-30 00:35:33 +00:00
PartiallyInlineLibCalls
PhaseOrdering Make globalaa-retained.ll test catching more cases. 2017-04-18 13:29:26 +00:00
PlaceSafepoints All libcalls should be considered to be GC-leaf functions. 2017-07-27 16:49:39 +00:00
PreISelIntrinsicLowering
PruneEH
Reassociate [Reassociate] Make sure EraseInst sets MadeChange 2017-06-27 05:32:13 +00:00
Reg2Mem
RewriteStatepointsForGC All libcalls should be considered to be GC-leaf functions. 2017-07-27 16:49:39 +00:00
SCCP [IPSCCP] Guard a user of getInitializer with hasDefinitiveInitializer 2017-07-31 17:47:07 +00:00
SLPVectorizer [SLP]: Add test to resurrect the jumbled load patch. This test has multiple uses 2017-07-31 07:40:54 +00:00
SROA Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
SafeStack Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
SampleProfile Do not inline recursive direct calls in sample loader pass. 2017-06-21 17:57:43 +00:00
Scalarizer Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
SeparateConstOffsetFromGEP AMDGPU: Mark all unspecified CC functions in tests as amdgpu_kernel 2017-03-21 21:39:51 +00:00
SimpleLoopUnswitch [PM/Unswitch] Fix a bug in the domtree update logic for the new unswitch 2017-05-25 06:33:36 +00:00
SimplifyCFG Fix test failure without X86 backend 2017-07-29 15:03:31 +00:00
Sink Enhance synchscope representation 2017-07-11 22:23:00 +00:00
SpeculativeExecution Revert r301950: SpeculativeExecution: Stop using whitelist for costs 2017-05-10 12:30:07 +00:00
StraightLineStrengthReduce AMDGPU: Mark all unspecified CC functions in tests as amdgpu_kernel 2017-03-21 21:39:51 +00:00
StripDeadPrototypes
StripSymbols Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
StructurizeCFG Revert "StructurizeCFG: Directly invert cmp instructions" 2017-04-24 20:25:01 +00:00
TailCallElim [TRE] Add another test for OptRemark. 2017-07-19 21:39:51 +00:00
ThinLTOBitcodeWriter ThinLTO Minimized Bitcode File Size Reduction 2017-07-21 17:25:20 +00:00
Util Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
WholeProgramDevirt Skip CFI for dead functions. 2017-06-02 18:24:23 +00:00