[PATCH] D95235: [InstCombine] narrow abs with sign-extended input
Sanjay Patel via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 22 10:35:37 PST 2021
spatel added a comment.
In D95235#2515765 <https://reviews.llvm.org/D95235#2515765>, @RKSimon wrote:
> Cheers - please can you add the PR48816 test case
>
> define i8 @transform_abs_epi8(i8 %0) {
> %2 = sext i8 %0 to i32
> %3 = tail call i32 @llvm.abs.i32(i32 %2, i1 true)
> %4 = trunc i32 %3 to i8
> ret i8 %4
> }
> declare i32 @llvm.abs.i32(i32, i1 immarg)
>
> (and vector equivalent)
Sure - will add tests with trunc on pre-commit of tests and this patch.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D95235/new/
https://reviews.llvm.org/D95235
More information about the llvm-commits
mailing list