Index: benchmark/readyQ/rq_bench.hpp
===================================================================
--- benchmark/readyQ/rq_bench.hpp	(revision 7c9ac4af78fda11cf4e9558899fd4764524f22f5)
+++ benchmark/readyQ/rq_bench.hpp	(revision f9b2e7388420b253282b546bc3300f089e8d2b89)
@@ -1,3 +1,6 @@
 #include <cassert>
+#include <climits>
+#include <cstdint>
+#include <cstdio>
 
 #include <time.h>										// timespec
@@ -5,8 +8,4 @@
 
 enum { TIMEGRAN = 1000000000LL };					// nanosecond granularity, except for timeval
-
-
-#include <libfibre/fibre.h>
-
 
 
@@ -57,7 +56,8 @@
 uint64_t from_fseconds(double sec) { return sec * TIMEGRAN; }
 
+template<typename Sleeper>
 void wait(const uint64_t & start, bool is_tty) {
 	for(;;) {
-		Fibre::usleep(100000);
+		Sleeper::usleep(100000);
 		uint64_t end = getTimeNsec();
 		uint64_t delta = end - start;
@@ -75,49 +75,9 @@
 }
 
-class __attribute__((aligned(128))) bench_sem {
-	Fibre * volatile ptr = nullptr;
-public:
-	inline bool wait() {
-		static Fibre * const ready  = reinterpret_cast<Fibre * const>(1ull);
-		for(;;) {
-			Fibre * expected = this->ptr;
-			if(expected == ready) {
-				if(__atomic_compare_exchange_n(&this->ptr, &expected, nullptr, false, __ATOMIC_SEQ_CST, __ATOMIC_SEQ_CST)) {
-					return false;
-				}
-			}
-			else {
-				/* paranoid */ assert( expected == nullptr );
-				if(__atomic_compare_exchange_n(&this->ptr, &expected, fibre_self(), false, __ATOMIC_SEQ_CST, __ATOMIC_SEQ_CST)) {
-					fibre_park();
-					return true;
-				}
-			}
-
-		}
-	}
-
-	inline bool post() {
-		static Fibre * const ready  = reinterpret_cast<Fibre * const>(1ull);
-		for(;;) {
-			Fibre * expected = this->ptr;
-			if(expected == ready) return false;
-			if(expected == nullptr) {
-				if(__atomic_compare_exchange_n(&this->ptr, &expected, ready, false, __ATOMIC_SEQ_CST, __ATOMIC_SEQ_CST)) {
-					return false;
-				}
-			}
-			else {
-				if(__atomic_compare_exchange_n(&this->ptr, &expected, nullptr, false, __ATOMIC_SEQ_CST, __ATOMIC_SEQ_CST)) {
-					fibre_unpark( expected );
-					return true;
-				}
-			}
-		}
-	}
-};
-
 // ==========================================================================================
+#include <cstdlib>
 #include <cstring>
+
+#include <algorithm>
 
 //-----------------------------------------------------------------------------
