[PATCH] D65529: [PowerPC] Use xxleqv to set all one vector IMM(-1).
Jinsong Ji via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 15 06:51:21 PDT 2019
jsji marked an inline comment as done.
jsji added inline comments.
================
Comment at: llvm/lib/Target/PowerPC/PPCInstrInfo.td:390
+def immAnyExt8NonAllOne : ImmLeaf<i32, [{ return (isInt<8>(Imm) && (Imm != -1))
+ || (isUInt<8>(Imm) && (Imm != 0xFF)); }]>;
def immSExt5NonZero : ImmLeaf<i32, [{ return Imm && isInt<5>(Imm); }]>;
----------------
wuzish wrote:
> steven.zhang wrote:
> > line too long. immAnyExt8NonAllOnes or immNonAllOnesAnyExt8?
> I think no need to modify this to exclude all ones. So long as its position which is blow all ones Pat, it would not be selected before all ones. Can have a try.
No, ISEL select the pattern according to `complexity` , not the `position` of where the pattern defined.
And yes, I did try before modifying this pattern, if we don't exclude all ones here, this pattern will be selected first, as it is complexity is far larger than others.
eg: 477 vs. 407.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D65529/new/
https://reviews.llvm.org/D65529
More information about the llvm-commits
mailing list