2014-10-24 Christophe Lyon <christophe.lyon@linaro.org>
[official-gcc.git] / gcc / testsuite / gcc.target / sparc / pdistn-2.c
blob008496f9ae746edc550f895918e561408298e111
1 /* { dg-do compile } */
2 /* { dg-options "-mcpu=ultrasparc -mvis3 -O1 -fdump-tree-optimized" } */
4 typedef unsigned char vec8 __attribute__((vector_size(8)));
6 #define _(A) (unsigned char)A
8 long foo () {
9 vec8 a = { _(1), _(2), _(3), _(4), _(5), _(6), _(7), _(255) };
10 vec8 b = { _(2), _(4), _(8), _(16), _(32), _(64), _(128), _(8) };
11 return __builtin_vis_pdistn (a, b);
14 /* { dg-final { scan-assembler-not "pdistn\t%" } } */
15 /* { dg-final { scan-tree-dump "return 473" "optimized" } } */
16 /* { dg-final { cleanup-tree-dump "optimized" } } */