1 /* { dg-do compile { target { powerpc*-*-* } } } */
2 /* { dg-skip-if "do not override -mcpu" { powerpc*-*-* } { "-mcpu=*" } { "-mcpu=power7" } } */
3 /* powerpc_vsx_ok represents power7 */
4 /* { dg-require-effective-target powerpc_vsx_ok } */
5 /* { dg-skip-if "" { powerpc_p8vector_ok } } */
6 /* { dg-skip-if "" { powerpc*-*-aix* } } */
7 /* { dg-options "-mcpu=power7" } */
9 /* This test should succeed on both 32- and 64-bit configurations. */
12 /* Though the command line specifies power7 target, this function is
13 to support power8, which will fail because this platform does not
15 __attribute__((target("cpu=power8")))
17 char_fetch_add_relaxed (char *ptr
, int value
)
18 { /* { dg-warning "lacks power8 support" } */
19 return __atomic_fetch_add (ptr
, value
, __ATOMIC_RELAXED
);