[llvm] [LICM] Drop nsw/nuw flags on affected instructions in hoistMulAddAssociation. (PR #85486)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 18 07:05:23 PDT 2024
================
@@ -2735,6 +2737,12 @@ static bool hoistMulAddAssociation(Instruction &I, Loop &L,
if (Changes.empty())
return false;
+ // Drop the poison flags for any adds we looked through.
+ if (I.getType()->isIntOrIntVectorTy()) {
+ for (auto *Add : Adds)
+ Add->dropPoisonGeneratingFlags();
----------------
nikic wrote:
I think the flag drop on the adds does not have test coverage?
https://github.com/llvm/llvm-project/pull/85486
More information about the llvm-commits
mailing list