[PATCH] D42032: [LLVM][PASSES][InstCombine] Fix (a + a + ...) / a cases
Roman Lebedev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 17 12:15:42 PST 2018
lebedev.ri added a comment.
Thank you for working on this!
Looks sane to me, but someone who actually knows this should review.
================
Comment at: test/Transforms/InstSimplify/reassociate.ll:166
+; (X << C1) / X -> 1 << C1
+ %shl = shl nsw i32 %x, 2
+ %r = sdiv i32 %shl, %x
----------------
Does this need negative tests, with missing `nsw`?
https://reviews.llvm.org/D42032
More information about the llvm-commits
mailing list