1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 10:42:39 +01:00
llvm-mirror/lib/Transforms/Scalar
Craig Topper 34eef4175e [DivRemPairs] Add an initial case for hoisting to a common predecessor.
This patch adds support for hoisting the division and maybe the
remainder for control flow graphs like this.

```
PredBB
  |  \
  |  Rem
  |  /
 Div
```

If we have DivRem we'll hoist both to PredBB. If not we'll just
hoist Div and expand Rem using the Div.

This improves our codegen for something like this

```
__uint128_t udivmodti4(__uint128_t dividend, __uint128_t divisor, __uint128_t *remainder) {
    if (remainder != 0)
        *remainder = dividend % divisor;
    return dividend / divisor;
}
```

Reviewed By: spatel, lebedev.ri

Differential Revision: https://reviews.llvm.org/D87555
2021-07-11 10:03:07 -07:00
..
ADCE.cpp
AlignmentFromAssumptions.cpp Recommit [ScalarEvolution] Make getMinusSCEV() fail for unrelated pointers. 2021-07-06 12:16:05 -07:00
AnnotationRemarks.cpp
BDCE.cpp
CallSiteSplitting.cpp
CMakeLists.txt [NewPM] Remove SpeculateAroundPHIs pass 2021-06-15 20:35:55 +03:00
ConstantHoisting.cpp
ConstraintElimination.cpp
CorrelatedValuePropagation.cpp
DCE.cpp
DeadStoreElimination.cpp Revert "Transform memset + malloc --> calloc (PR25892)" 2021-07-09 16:26:48 +03:00
DivRemPairs.cpp [DivRemPairs] Add an initial case for hoisting to a common predecessor. 2021-07-11 10:03:07 -07:00
EarlyCSE.cpp
FlattenCFGPass.cpp
Float2Int.cpp
GuardWidening.cpp
GVN.cpp
GVNHoist.cpp
GVNSink.cpp
InductiveRangeCheckElimination.cpp
IndVarSimplify.cpp
InferAddressSpaces.cpp [OpaquePtr][InferAddrSpace] Use PointerType::getWithSamePointeeType() 2021-07-09 10:29:08 -07:00
InstSimplifyPass.cpp
IVUsersPrinter.cpp
JumpThreading.cpp [CSSPGO] Undoing the concept of dangling pseudo probe 2021-06-18 15:14:11 -07:00
LICM.cpp
LoopAccessAnalysisPrinter.cpp
LoopBoundSplit.cpp
LoopDataPrefetch.cpp
LoopDeletion.cpp [LoopDeletion] Handle switch in proving that loop exits on first iteration 2021-07-09 18:03:34 +07:00
LoopDistribute.cpp
LoopFlatten.cpp
LoopFuse.cpp
LoopIdiomRecognize.cpp [Intrinsics] Make MemCpyInlineInst a MemCpyInst 2021-07-02 10:25:24 -07:00
LoopInstSimplify.cpp
LoopInterchange.cpp
LoopLoadElimination.cpp
LoopPassManager.cpp
LoopPredication.cpp
LoopRerollPass.cpp Recommit [ScalarEvolution] Make getMinusSCEV() fail for unrelated pointers. 2021-07-06 12:16:05 -07:00
LoopRotation.cpp
LoopSimplifyCFG.cpp
LoopSink.cpp
LoopStrengthReduce.cpp [ScalarEvolution] Strictly enforce pointer/int type rules. 2021-07-09 17:29:26 -07:00
LoopUnrollAndJamPass.cpp
LoopUnrollPass.cpp [LoopUnroll] Don't modify TripCount/TripMultiple in computeUnrollCount() (NFCI) 2021-06-21 21:34:17 +02:00
LoopUnswitch.cpp
LoopVersioningLICM.cpp
LowerAtomic.cpp
LowerConstantIntrinsics.cpp
LowerExpectIntrinsic.cpp
LowerGuardIntrinsic.cpp
LowerMatrixIntrinsics.cpp [Matrix] Fix crash during fusion if the same load is re-used. 2021-07-02 14:00:17 +01:00
LowerWidenableCondition.cpp
MakeGuardsExplicit.cpp
MemCpyOptimizer.cpp [Intrinsics] Make MemCpyInlineInst a MemCpyInst 2021-07-02 10:25:24 -07:00
MergedLoadStoreMotion.cpp
MergeICmps.cpp PR51018: Remove explicit conversions from SmallString to StringRef to future-proof against C++23 2021-07-08 13:37:57 -07:00
NaryReassociate.cpp
NewGVN.cpp
PartiallyInlineLibCalls.cpp [PartiallyInlineLibCalls] Disable sqrt expansion for strictfp. 2021-06-17 14:15:12 -07:00
PlaceSafepoints.cpp
Reassociate.cpp
Reg2Mem.cpp
RewriteStatepointsForGC.cpp
Scalar.cpp
ScalarizeMaskedMemIntrin.cpp [ScalarizeMaskedMemIntrin][SelectionDAGBuilder] Use the element type to calculate alignment for gather/scatter when alignment operand is 0. 2021-07-01 19:08:47 -07:00
Scalarizer.cpp Update @llvm.powi to handle different int sizes for the exponent 2021-06-17 09:38:28 +02:00
SCCP.cpp
SeparateConstOffsetFromGEP.cpp
SimpleLoopUnswitch.cpp [NewPM] Consistently use 'simplifycfg' rather than 'simplify-cfg' 2021-07-09 09:47:03 +02:00
SimplifyCFGPass.cpp [SimplifyCFG] Tail-merging all blocks with resume terminator 2021-06-24 21:25:06 +03:00
Sink.cpp
SpeculativeExecution.cpp
SROA.cpp
StraightLineStrengthReduce.cpp
StructurizeCFG.cpp
TailRecursionElimination.cpp
WarnMissedTransforms.cpp