Reverted commit D3270439
[folly.git] / folly / test / DeterministicSchedule.cpp
index f7668fc587e5bd68d9270683f3b2e0c8007bafc8..fe59cc02145c47357fb68158a16914119a9cb634 100644 (file)
  */
 
 #include <folly/test/DeterministicSchedule.h>
-
-#include <assert.h>
-
 #include <algorithm>
 #include <list>
 #include <mutex>
 #include <random>
-#include <unordered_map>
 #include <utility>
+#include <unordered_map>
+#include <assert.h>
 
-#include <folly/Random.h>
+DECLARE_ACCESS_SPREADER_TYPE(folly::test::DeterministicAtomic)
 
 namespace folly {
 namespace test {
@@ -141,7 +139,7 @@ int DeterministicSchedule::getRandNumber(int n) {
   if (tls_sched) {
     return tls_sched->scheduler_(n);
   }
-  return Random::rand32() % n;
+  return std::rand() % n;
 }
 
 int DeterministicSchedule::getcpu(unsigned* cpu,