85bfab144c008b4562c35555e6adf31335ec8c59
1 /* testsuite/gcc.target/arm/pr48183.c */
2 /* { dg-do compile } */
3 /* { dg-skip-if "-mslow-flash-data and -mword-relocations incompatible" { *-*-* } { "-mslow-flash-data" } } */
4 /* { dg-skip-if "-mpure-code and -mword-relocations incompatible" { *-*-* } { "-mpure-code" } } */
5 /* { dg-options "-O2 -mword-relocations -march=armv7-a -marm" } */
6 /* { dg-final { scan-assembler-not "\[\\t \]+movw" } } */
18 int atomic_add_return_relaxed(int *p1
) {
19 __builtin_prefetch(p1
);
22 void atomic_long_inc_return_relaxed(int *p1
) {
24 atomic_add_return_relaxed(v
);
26 void ww_acquire_init(struct ww_class
*p1
) {
27 atomic_long_inc_return_relaxed(&p1
->stamp
);
30 int *get_random_order();
31 void stress_inorder_work() {
34 int *i
= &g
->locks
, *j
= get_random_order();
39 for (n
= 0; n
< h
; n
++)
40 ww_mutex_lock(i
[j
[n
]]);