From a8e92f1d0e6b4f70719cfa91164b27338b29662b Mon Sep 17 00:00:00 2001 From: Yedidya Feldblum Date: Wed, 17 May 2023 08:57:37 -0700 Subject: [PATCH] use std::unordered_map in fiber-manager global maps Summary: The global maps are used only in the slow-path, so simplicity is better. The simplicity also allows simpler access to the list of extant fiber-managers in the debugger, with needing the gdb scripts only to support `std::unordered_map` and not also `folly::F14NodeMap`. Reviewed By: jaesoo-fb Differential Revision: D45919505 fbshipit-source-id: fa354b60344809ff2a2e234945b3f19873b76ac4 --- third-party/folly/src/folly/fibers/FiberManagerMap-inl.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/third-party/folly/src/folly/fibers/FiberManagerMap-inl.h b/third-party/folly/src/folly/fibers/FiberManagerMap-inl.h index d2d7ec57f10d0a..644e4470328bd3 100644 --- a/third-party/folly/src/folly/fibers/FiberManagerMap-inl.h +++ b/third-party/folly/src/folly/fibers/FiberManagerMap-inl.h @@ -17,6 +17,7 @@ #pragma once #include +#include #include #include @@ -99,7 +100,7 @@ class GlobalCache { } std::mutex mutex_; - folly::F14NodeMap, std::unique_ptr> map_; + std::unordered_map, std::unique_ptr> map_; }; constexpr size_t kEraseListMaxSize = 64;