precommit test for D152068
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
llvm/test/Transforms/InstCombine/addsub-constant-folding.ll | ||
---|---|---|
135 | For tests with overflowing constants, I'd recommend using i8 as it's easier to see what overflows and what doesn't at a glance. | |
151 | Can also add nuw here to check that the right attribute presence is checked. | |
175 | It would be good to have a test with non-splat vector constants (one with and one without overflow), as this fold supports them. |
llvm/test/Transforms/InstCombine/addsub-constant-folding.ll | ||
---|---|---|
175 | Thank you for a good catch! I could find currently, i.e. C = <i8 1, i8 3>, C2 = <i8 -127, i8 -125>, bool WillNotSOV = willNotOverflowSignedSub(C, C2, I); would be false because computeOverflowForSignedSub can't check correctly, but each vector's maximum and minimum element range?? |
llvm/test/Transforms/InstCombine/addsub-constant-folding.ll | ||
---|---|---|
175 | In that case, just leave a TODO in the test. |
For tests with overflowing constants, I'd recommend using i8 as it's easier to see what overflows and what doesn't at a glance.