#pragma once
-#include <type_traits>
#include <assert.h>
#include <errno.h>
#include <stdint.h>
+
+#include <type_traits>
+
#include <boost/noncopyable.hpp>
#include <folly/AtomicStruct.h>
#include <folly/Portability.h>
-#include <folly/detail/CacheLocality.h>
+#include <folly/concurrency/CacheLocality.h>
#include <folly/portability/SysMman.h>
#include <folly/portability/Unistd.h>
namespace detail {
template <typename Pool>
struct IndexedMemPoolRecycler;
-}
+} // namespace detail
template <
typename T,
}
AtomicStruct<TaggedPtr,Atom>& localHead() {
- auto stripe = detail::AccessSpreader<Atom>::current(NumLocalLists);
+ auto stripe = AccessSpreader<Atom>::current(NumLocalLists);
return local_[stripe].head;
}
void markAllocated(Slot& slot) {
slot.localNext.store(uint32_t(-1), std::memory_order_release);
}
+
+ public:
+ static constexpr std::size_t kSlotSize = sizeof(Slot);
};
namespace detail {
}
};
-}
+} // namespace detail
} // namespace folly