URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Subversion Repositories openrisc
[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.target/] [arm/] [sync-1.c] - Rev 714
Go to most recent revision | Compare with Previous | Blame | View Log
/* { dg-do run { target sync_int_long } } */ /* { dg-options "-O2" } */ volatile int mem; int bar (int x, int y) { if (x) __sync_fetch_and_add(&mem, y); return 0; } extern void abort (void); int main (int argc, char *argv[]) { mem = 0; bar (0, 1); bar (1, 1); if (mem != 1) abort (); return 0; }
Go to most recent revision | Compare with Previous | Blame | View Log