1 /* { dg-do compile { target { powerpc*-*-* } } } */ 2 /* { dg-require-effective-target powerpc_p9vector_ok } */ 3 /* { dg-options "-mdejagnu-cpu=power9" } */ 4 5 #include <stddef.h> 6 #include <altivec.h> 7 8 unsigned char fetch_data(unsigned int offset,vector unsigned char * datap)9fetch_data (unsigned int offset, vector unsigned char *datap) 10 { 11 vector unsigned char data = *datap; 12 13 return vec_xlx (offset, data); 14 } 15 16 /* { dg-final { scan-assembler "vextublx" } } */ 17