#include <vecintrin.h>
volatile vector signed char vsc;
volatile vector signed short vss;
volatile vector signed int vsi;
volatile vector signed long long vsl;
volatile vector unsigned char vuc;
volatile vector unsigned short vus;
volatile vector unsigned int vui;
volatile vector unsigned long long vul;
volatile vector bool char vbc;
volatile vector bool short vbs;
volatile vector bool int vbi;
volatile vector bool long long vbl;
volatile vector float vf;
volatile vector double vd;
volatile signed char sc;
volatile signed short ss;
volatile signed int si;
volatile signed long long sl;
volatile unsigned char uc;
volatile unsigned short us;
volatile unsigned int ui;
volatile unsigned long long ul;
volatile float f;
volatile double d;
const void * volatile cptr;
const signed char * volatile cptrsc;
const signed short * volatile cptrss;
const signed int * volatile cptrsi;
const signed long long * volatile cptrsl;
const unsigned char * volatile cptruc;
const unsigned short * volatile cptrus;
const unsigned int * volatile cptrui;
const unsigned long long * volatile cptrul;
const float * volatile cptrf;
const double * volatile cptrd;
void * volatile ptr;
signed char * volatile ptrsc;
signed short * volatile ptrss;
signed int * volatile ptrsi;
signed long long * volatile ptrsl;
unsigned char * volatile ptruc;
unsigned short * volatile ptrus;
unsigned int * volatile ptrui;
unsigned long long * volatile ptrul;
float * volatile ptrf;
double * volatile ptrd;
volatile unsigned int len;
volatile int idx;
int cc;
void test_core(void) {
vf = vec_gather_element(vf, vui, cptrf, idx); vf = vec_gather_element(vf, vui, cptrf, -1); vf = vec_gather_element(vf, vui, cptrf, 4); vd = vec_gather_element(vd, vul, cptrd, idx); vd = vec_gather_element(vd, vul, cptrd, -1); vd = vec_gather_element(vd, vul, cptrd, 2);
vec_scatter_element(vf, vui, ptrf, idx); vec_scatter_element(vf, vui, ptrf, -1); vec_scatter_element(vf, vui, ptrf, 4); vec_scatter_element(vd, vul, ptrd, idx); vec_scatter_element(vd, vul, ptrd, -1); vec_scatter_element(vd, vul, ptrd, 2);
vf = vec_splat(vf, idx); vf = vec_splat(vf, -1); vf = vec_splat(vf, 4); vd = vec_splat(vd, idx); vd = vec_splat(vd, -1); vd = vec_splat(vd, 2); }
void test_integer(void) {
vf = vec_sld(vf, vf, idx); vd = vec_sld(vd, vd, idx);
vuc = vec_msum_u128(vul, vul, vuc, idx); vuc = vec_msum_u128(vul, vul, vuc, -1); vuc = vec_msum_u128(vul, vul, vuc, 16); }
void test_float(void) {
vbi = vec_fp_test_data_class(vf, idx, &cc); vbi = vec_fp_test_data_class(vf, -1, &cc); vbi = vec_fp_test_data_class(vf, 4096, &cc); vbl = vec_fp_test_data_class(vd, idx, &cc); vbl = vec_fp_test_data_class(vd, -1, &cc); vbl = vec_fp_test_data_class(vd, 4096, &cc); }