*/
#include <folly/ThreadCachedArena.h>
-#include <folly/Memory.h>
+#include <algorithm>
+#include <iterator>
#include <map>
#include <mutex>
-#include <thread>
-#include <iterator>
-#include <algorithm>
#include <random>
+#include <thread>
#include <unordered_map>
#include <glog/logging.h>
-#include <folly/Range.h>
#include <folly/Benchmark.h>
+#include <folly/Memory.h>
+#include <folly/Range.h>
#include <folly/portability/GTest.h>
using namespace folly;
other.areas_.clear();
}
-} // namespace
+} // namespace
TEST(ThreadCachedArena, BlockSize) {
- static const size_t alignment = alignof(std::max_align_t);
+ static const size_t alignment = folly::max_align_v;
static const size_t requestedBlockSize = 64;
ThreadCachedArena arena(requestedBlockSize);
BENCHMARK_DRAW_LINE()
-} // namespace
-
+} // namespace
// Benchmark Iters Total t t/iter iter/sec
// ----------------------------------------------------------------------------