X-Git-Url: https://git.lttng.org/?p=urcu.git;a=blobdiff_plain;f=tests%2Ftest_urcu_bp.c;h=857913f83413e89722ce17f9b00182dc1254bea1;hp=ba80ae60f5129bd172960007b2f019e0ce9c1b7a;hb=a0b7f7ea3fc3339a1c42caffd53ce9f056e5b901;hpb=de10a5858ea0638c9059bb3315794ccb1401f404 diff --git a/tests/test_urcu_bp.c b/tests/test_urcu_bp.c index ba80ae6..857913f 100644 --- a/tests/test_urcu_bp.c +++ b/tests/test_urcu_bp.c @@ -239,11 +239,11 @@ void *thr_reader(void *_count) debug_yield_read(); if (local_ptr) assert(local_ptr->a == 8); - if (unlikely(rduration)) + if (caa_unlikely(rduration)) loop_sleep(rduration); rcu_read_unlock(); nr_reads++; - if (unlikely(!test_duration_read())) + if (caa_unlikely(!test_duration_read())) break; } @@ -276,7 +276,7 @@ void *thr_writer(void *_count) new = test_array_alloc(); new->a = 8; old = rcu_xchg_pointer(&test_rcu_pointer, new); - if (unlikely(wduration)) + if (caa_unlikely(wduration)) loop_sleep(wduration); synchronize_rcu(); if (old) @@ -284,9 +284,9 @@ void *thr_writer(void *_count) test_array_free(old); rcu_copy_mutex_unlock(); nr_writes++; - if (unlikely(!test_duration_write())) + if (caa_unlikely(!test_duration_write())) break; - if (unlikely(wdelay)) + if (caa_unlikely(wdelay)) loop_sleep(wdelay); }