[llvm] [Reassociate] Preserve `nuw` and `nsw` on `mul` chains (PR #97040)

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Fri Jun 28 06:56:14 PDT 2024


================
@@ -725,7 +735,9 @@ void ReassociatePass::RewriteExprTree(BinaryOperator *I,
           // Note that it doesn't hold for mul if one of the operands is zero.
           // TODO: We can preserve NUW flag if we prove that all mul operands
           // are non-zero.
----------------
nikic wrote:

TODO resolved.

https://github.com/llvm/llvm-project/pull/97040


More information about the llvm-commits mailing list