Hi! On Fri, Jan 21, 2022 at 11:31:34AM -0600, Bill Schmidt wrote: > It was recently discovered that Clang supports a couple of variants of > vec_sldw that > GCC does not. After some discussion, we decided that these variants are > reasonable, > and GCC will also support them. This patch adds that support.
As we discussed, this is reasonable only because we already allow non-integer inputs (and outputs) for all(?) other permute class instructions. > I updated an existing test and discovered it wasn't actually checking for > generation > of the xxsldwi instruction, so I added that check as well. It can always generate vsldoi instead, which is a strict superset (if all registers used are VRs). They will not likely be here, because these are such simple functions, but that is a bit fragile. > * gcc.target/powerpc/builtins-4.c: Add two test variants. Adjust > assembler counts. Is there any justification for the new counts? ... Ah, it didn't count the sld's at all before. Okay. > @@ -161,6 +175,6 @@ test_sll_vuill_vuill_vuc (vector unsigned long long int x, > /* { dg-final { scan-assembler-times "xvnabssp" 1 } } */ > /* { dg-final { scan-assembler-times "xvnabsdp" 1 } } */ > /* { dg-final { scan-assembler-times "vslo" 4 } } */ > -/* { dg-final { scan-assembler-times "xxlor" 30 } } */ > +/* { dg-final { scan-assembler-times "xxlor" 32 } } */ This will need modification for the phase of the moon. It also does not even test only xxlor insn (also xxlorc insns, for example). > +/* { dg-final { scan-assembler-times "xxsldwi" 10 } } */ Okay if you make this \mxxsldwi\M or even \m(?:xxsldwi|vsldoi)\M Thanks! Segher