X-Git-Url: https://git.liburcu.org/?p=urcu.git;a=blobdiff_plain;f=urcu.c;h=be6d4bdfc55b32d624011280c972d6f2772f2853;hp=2339bc63c872c6a4826d7a52e8d064d85130c0df;hb=3a71751ee010b48e1a1fa7081617ec6f82d5c0ba;hpb=b7b6a8f52c051dca78161908670e3f51b9b33080 diff --git a/urcu.c b/urcu.c index 2339bc6..be6d4bd 100644 --- a/urcu.c +++ b/urcu.c @@ -41,6 +41,18 @@ /* Do not #define _LGPL_SOURCE to ensure we can emit the wrapper symbols */ #include "urcu.h" +/* + * If a reader is really non-cooperative and refuses to commit its + * rcu_active_readers count to memory (there is no barrier in the reader + * per-se), kick it after a few loops waiting for it. + */ +#define KICK_READER_LOOPS 10000 + +/* + * Active attempts to check for reader Q.S. before calling futex(). + */ +#define RCU_QS_ACTIVE_ATTEMPTS 100 + #ifdef RCU_MEMBARRIER static int init_done; int has_sys_membarrier;