[PATCH] D109035: [TableGen][SelectionDAG] Use ComplexPattern type for non-leaf nodes
Jessica Clarke via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 1 11:06:54 PDT 2021
jrtc27 added a comment.
In D109035#2977420 <https://reviews.llvm.org/D109035#2977420>, @kparzysz wrote:
> This fails to build because `SVDup0` is a complex pattern defined with type `i64`, but it's used in places that require vectors:
>
> def SVEDup0 : ComplexPattern<i64, 0, "SelectDupZero", []>;
> def SVEDup0Undef : ComplexPattern<i64, 0, "SelectDupZeroOrUndef", []>;
>
> and
>
> multiclass SVE_SETCC_Pat_With_Zero<CondCode cc, CondCode invcc, ValueType predvt,
> ValueType intvt, Instruction cmp> {
> def : Pat<(predvt (AArch64setcc_z predvt:$Op1, intvt:$Op2, (SVEDup0), cc)),
> (cmp $Op1, $Op2)>;
> def : Pat<(predvt (AArch64setcc_z predvt:$Op1, (SVEDup0), intvt:$Op2, invcc)),
> (cmp $Op1, $Op2)>;
> }
>
> Looks good to me otherwise.
Yes, this turned up a bunch of cases where the types were wrong (as you would expect, though fewer than I feared); you'll need all 3 parent revisions listed under Stack for it to both build (the first AArch64 revision) and not crash in various CodeGen tests (the AMDGPU revision and other AArch64 one).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D109035/new/
https://reviews.llvm.org/D109035
More information about the llvm-commits
mailing list