Thanks for reviewing the patch. Committed as r15-2740.
在 2024/7/31 17:10, Kewen.Lin 写道: > Hi Haochen, > > on 2024/7/25 11:34, HAO CHEN GUI wrote: >> Hi, >> This patch add const_vector into any_operand predicate. From my >> understanding, any_operand should include all kinds of operands. >> The const_vector should be included. As emit_move_insn doesn't check >> the predicate, the const_vector is actually supported by vector mode >> move expand. So it should be added into any_operand in case other gen >> function (for instance, maybe_gen_insn) checks the predicate. >> >> Bootstrapped and tested on x86 and powerpc64-linux BE and LE with no >> regressions. Is it OK for trunk?> >> Thanks >> Gui Haochen >> >> ChangeLog >> rs6000: Add const_vector into any_operand predicate >> >> gcc/ >> * config/rs6000/predicates.md (any_operand): Add const_vector. >> >> patch.diff >> diff --git a/gcc/config/rs6000/predicates.md >> b/gcc/config/rs6000/predicates.md >> index d23ce9a77a3..12600368c43 100644 >> --- a/gcc/config/rs6000/predicates.md >> +++ b/gcc/config/rs6000/predicates.md >> @@ -19,7 +19,7 @@ >> >> ;; Return 1 for anything except PARALLEL. >> (define_predicate "any_operand" >> - (match_code >> "const_int,const_double,const_wide_int,const,symbol_ref,label_ref,subreg,reg,mem")) >> + (match_code >> "const_int,const_double,const_wide_int,const,symbol_ref,label_ref,subreg,reg,mem,const_vector")) > > CC Mike since he added mov<VEC_M:mode> and movmisalign<VEC_N:mode>. > >>From the name, its associated comments and what it currently consists of, > this seemed to be an oversight and looks reasonable to fix. Maybe it's > read better to put "const_vector" after "const_wide_int", OK for trunk > with this tweaked, but please give others two days or so to chime in, > thanks! > > BR, > Kewen >