llvm-project/llvm/lib/Transforms/InstCombine
Nikita Popov c3ca6876ed [InstCombine] Don't simplify calls without uses
When simplifying a call without uses, replaceInstUsesWith() is
going to do nothing, but we'll skip all following folds. We can
only run into this problem with calls that both simplify and are
not trivially dead if unused, which currently seems to happen only
with calls to undef, as the test diff shows. When extending
SimplifyCall() to handle "returned" attributes, this becomes a much
bigger problem, so I'm fixing this first.

Differential Revision: https://reviews.llvm.org/D75814
2020-03-09 18:47:46 +01:00
..
CMakeLists.txt [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
InstCombineAddSub.cpp [InstComine] Forego of one-use check in `(X - (X & Y)) --> (X & ~Y)` if Y is a constant 2020-03-06 21:39:07 +03:00
InstCombineAndOrXor.cpp [InstCombin] Avoid nested Create calls, to guarantee order. 2020-02-18 09:44:11 +01:00
InstCombineAtomicRMW.cpp [InstCombine] Use replaceOperand() in more places 2020-02-11 17:38:23 +01:00
InstCombineCalls.cpp [InstCombine] Don't simplify calls without uses 2020-03-09 18:47:46 +01:00
InstCombineCasts.cpp [InstCombine] Use IRBuilder to create bitcast 2020-03-04 18:28:38 +01:00
InstCombineCompares.cpp [APFloat] Make use of new overloaded comparison operators. NFC. 2020-03-06 16:42:53 +00:00
InstCombineInternal.h [InstCombine] DCE instructions earlier 2020-02-27 18:45:59 +01:00
InstCombineLoadStoreAlloca.cpp [InstCombine] Fix infinite loop in min/max load/store bitcast combine (PR44835) 2020-02-08 16:55:22 +01:00
InstCombineMulDivRem.cpp Remove BinaryOperator::CreateFNeg 2020-02-27 09:06:03 -08:00
InstCombinePHI.cpp [WinEH] Fix inttoptr+phi optimization in presence of catchswitch 2020-03-01 07:49:28 -08:00
InstCombineSelect.cpp Remove BinaryOperator::CreateFNeg 2020-02-27 09:06:03 -08:00
InstCombineShifts.cpp [InstCombine] Don't explicitly invoke const folding in shift combine 2020-03-04 18:33:00 +01:00
InstCombineSimplifyDemanded.cpp [InstCombine] Fix known bits handling in SimplifyDemandedUseBits 2020-03-07 18:16:41 +01:00
InstCombineTables.td InstCombine/AMDGPU: Add dimension-aware image intrinsics to SimplifyDemanded 2018-06-21 13:37:31 +00:00
InstCombineVectorOps.cpp [InstCombine] Use replaceOperand() in more places 2020-02-11 17:38:23 +01:00
InstructionCombining.cpp [ConstantFolding] Always return something from ConstantFoldConstant 2020-03-04 18:24:47 +01:00
LLVMBuild.txt Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00