llvm-project/llvm/lib/Transforms
Sanjay Patel 2e87333bfe [InstCombine] convert mul by negative-pow2 to negate and shift
This is an unusual canonicalization because we create an extra instruction,
but it's likely better for analysis and codegen (similar reasoning as D133399).

InstCombine::Negator may create this kind of multiply from negate and shift,
but this should not conflict because of the narrow negation.

I don't know how to create a fully general proof for this kind of transform in
Alive2, but here's an example with bitwidths similar to one of the regression
tests:
https://alive2.llvm.org/ce/z/J3jTjR

Differential Revision: https://reviews.llvm.org/D133667
2022-10-02 12:22:25 -04:00
..
AggressiveInstCombine [AggressiveInstCombine] Combine consecutive loads which are being merged to form a wider load. 2022-09-28 17:32:47 +01:00
CFGuard [NFC] Fix warning 2022-08-23 20:50:37 -05:00
Coroutines [IR] Add Instruction::getInsertionPointAfterDef() 2022-08-31 10:50:10 +02:00
Hello
IPO Reapply [FunctionAttrs] Infer precise FMRB 2022-09-29 14:02:15 +02:00
InstCombine [InstCombine] convert mul by negative-pow2 to negate and shift 2022-10-02 12:22:25 -04:00
Instrumentation [MemProf] Update metadata during inlining 2022-09-30 16:46:17 -07:00
ObjCARC [llvm] Migrate PAEval to new pass manager 2022-10-01 16:41:58 -07:00
Scalar [ConstraintElimination] Update Changed status in ssub simplification. 2022-10-02 14:25:51 +01:00
Utils [LAA] Change to function analysis for new PM. 2022-10-01 15:44:27 +01:00
Vectorize [LAA] Change to function analysis for new PM. 2022-10-01 15:44:27 +01:00
CMakeLists.txt