+
+static void force_mb_single_thread(pthread_t tid)
+{
+ assert(reader_data);
+ sig_done = 0;
+ smp_mb(); /* write sig_done before sending the signals */
+ pthread_kill(tid, SIGURCU);
+ /*
+ * Wait for sighandler (and thus mb()) to execute on every thread.
+ * BUSY-LOOP.
+ */
+ while (LOAD_REMOTE(sig_done) < 1)
+ cpu_relax();
+ smp_mb(); /* read sig_done before ending the barrier */
+}
+