From 0231b21273f809fda5753589b09e7f61c24cdac6 Mon Sep 17 00:00:00 2001 From: James Sedgwick Date: Fri, 20 Oct 2017 13:30:03 -0700 Subject: [PATCH] move executor task queues and thread factories into subdirectories Summary: as title, see moves (Note: this ignores all push blocking failures!) Reviewed By: mzlee Differential Revision: D6112001 fbshipit-source-id: 1eb10b44ae8ee1f90a10e05c29e48c99d824afa5 --- folly/Makefile.am | 14 +++++++------- folly/executors/CPUThreadPoolExecutor.cpp | 2 +- folly/executors/ThreadPoolExecutor.h | 4 ++-- folly/executors/ThreadedExecutor.cpp | 2 +- folly/executors/ThreadedExecutor.h | 2 +- folly/executors/{ => task_queue}/BlockingQueue.h | 0 .../executors/{ => task_queue}/LifoSemMPMCQueue.h | 2 +- .../{ => task_queue}/PriorityLifoSemMPMCQueue.h | 2 +- .../{ => task_queue}/UnboundedBlockingQueue.h | 2 +- .../test/UnboundedBlockingQueueTest.cpp | 2 +- folly/executors/test/ThreadPoolExecutorTest.cpp | 4 ++-- .../{ => thread_factory}/NamedThreadFactory.h | 2 +- .../{ => thread_factory}/PriorityThreadFactory.h | 2 +- .../executors/{ => thread_factory}/ThreadFactory.h | 0 14 files changed, 20 insertions(+), 20 deletions(-) rename folly/executors/{ => task_queue}/BlockingQueue.h (100%) rename folly/executors/{ => task_queue}/LifoSemMPMCQueue.h (96%) rename folly/executors/{ => task_queue}/PriorityLifoSemMPMCQueue.h (98%) rename folly/executors/{ => task_queue}/UnboundedBlockingQueue.h (96%) rename folly/executors/{ => task_queue}/test/UnboundedBlockingQueueTest.cpp (95%) rename folly/executors/{ => thread_factory}/NamedThreadFactory.h (96%) rename folly/executors/{ => thread_factory}/PriorityThreadFactory.h (97%) rename folly/executors/{ => thread_factory}/ThreadFactory.h (100%) diff --git a/folly/Makefile.am b/folly/Makefile.am index 344dc3ae..3fc4644b 100644 --- a/folly/Makefile.am +++ b/folly/Makefile.am @@ -83,7 +83,6 @@ nobase_follyinclude_HEADERS = \ detail/TurnSequencer.h \ detail/UncaughtExceptionCounter.h \ executors/Async.h \ - executors/BlockingQueue.h \ executors/CPUThreadPoolExecutor.h \ executors/Codel.h \ executors/DrivableExecutor.h \ @@ -93,17 +92,18 @@ nobase_follyinclude_HEADERS = \ executors/IOExecutor.h \ executors/IOObjectCache.h \ executors/IOThreadPoolExecutor.h \ - executors/LifoSemMPMCQueue.h \ - executors/NamedThreadFactory.h \ executors/NotificationQueueExecutor.h \ - executors/PriorityLifoSemMPMCQueue.h \ - executors/PriorityThreadFactory.h \ executors/ScheduledExecutor.h \ executors/SerialExecutor.h \ - executors/ThreadFactory.h \ executors/ThreadPoolExecutor.h \ executors/ThreadedExecutor.h \ - executors/UnboundedBlockingQueue.h \ + executors/task_queue/BlockingQueue.h \ + executors/task_queue/LifoSemMPMCQueue.h \ + executors/task_queue/PriorityLifoSemMPMCQueue.h \ + executors/task_queue/UnboundedBlockingQueue.h \ + executors/thread_factory/NamedThreadFactory.h \ + executors/thread_factory/PriorityThreadFactory.h \ + executors/thread_factory/ThreadFactory.h \ functional/ApplyTuple.h \ Demangle.h \ DiscriminatedPtr.h \ diff --git a/folly/executors/CPUThreadPoolExecutor.cpp b/folly/executors/CPUThreadPoolExecutor.cpp index 37fd4441..3c50a299 100644 --- a/folly/executors/CPUThreadPoolExecutor.cpp +++ b/folly/executors/CPUThreadPoolExecutor.cpp @@ -15,7 +15,7 @@ */ #include -#include +#include namespace folly { diff --git a/folly/executors/ThreadPoolExecutor.h b/folly/executors/ThreadPoolExecutor.h index 3de9ec59..09ff14fd 100644 --- a/folly/executors/ThreadPoolExecutor.h +++ b/folly/executors/ThreadPoolExecutor.h @@ -20,8 +20,8 @@ #include #include #include -#include -#include +#include +#include #include #include diff --git a/folly/executors/ThreadedExecutor.cpp b/folly/executors/ThreadedExecutor.cpp index d75e82b6..e19ecf4f 100644 --- a/folly/executors/ThreadedExecutor.cpp +++ b/folly/executors/ThreadedExecutor.cpp @@ -21,7 +21,7 @@ #include #include -#include +#include namespace folly { diff --git a/folly/executors/ThreadedExecutor.h b/folly/executors/ThreadedExecutor.h index 81c5fca8..94178987 100644 --- a/folly/executors/ThreadedExecutor.h +++ b/folly/executors/ThreadedExecutor.h @@ -25,7 +25,7 @@ #include #include -#include +#include namespace folly { diff --git a/folly/executors/BlockingQueue.h b/folly/executors/task_queue/BlockingQueue.h similarity index 100% rename from folly/executors/BlockingQueue.h rename to folly/executors/task_queue/BlockingQueue.h diff --git a/folly/executors/LifoSemMPMCQueue.h b/folly/executors/task_queue/LifoSemMPMCQueue.h similarity index 96% rename from folly/executors/LifoSemMPMCQueue.h rename to folly/executors/task_queue/LifoSemMPMCQueue.h index 3a16da27..68a86061 100644 --- a/folly/executors/LifoSemMPMCQueue.h +++ b/folly/executors/task_queue/LifoSemMPMCQueue.h @@ -18,7 +18,7 @@ #include #include -#include +#include namespace folly { diff --git a/folly/executors/PriorityLifoSemMPMCQueue.h b/folly/executors/task_queue/PriorityLifoSemMPMCQueue.h similarity index 98% rename from folly/executors/PriorityLifoSemMPMCQueue.h rename to folly/executors/task_queue/PriorityLifoSemMPMCQueue.h index 797287c0..3242628d 100644 --- a/folly/executors/PriorityLifoSemMPMCQueue.h +++ b/folly/executors/task_queue/PriorityLifoSemMPMCQueue.h @@ -19,7 +19,7 @@ #include #include #include -#include +#include namespace folly { diff --git a/folly/executors/UnboundedBlockingQueue.h b/folly/executors/task_queue/UnboundedBlockingQueue.h similarity index 96% rename from folly/executors/UnboundedBlockingQueue.h rename to folly/executors/task_queue/UnboundedBlockingQueue.h index 3fb09b3f..2f29fbfb 100644 --- a/folly/executors/UnboundedBlockingQueue.h +++ b/folly/executors/task_queue/UnboundedBlockingQueue.h @@ -18,7 +18,7 @@ #include #include -#include +#include #include namespace folly { diff --git a/folly/executors/test/UnboundedBlockingQueueTest.cpp b/folly/executors/task_queue/test/UnboundedBlockingQueueTest.cpp similarity index 95% rename from folly/executors/test/UnboundedBlockingQueueTest.cpp rename to folly/executors/task_queue/test/UnboundedBlockingQueueTest.cpp index 203c1eb5..06de12ac 100644 --- a/folly/executors/test/UnboundedBlockingQueueTest.cpp +++ b/folly/executors/task_queue/test/UnboundedBlockingQueueTest.cpp @@ -13,8 +13,8 @@ * See the License for the specific language governing permissions and * limitations under the License. */ +#include #include -#include #include #include diff --git a/folly/executors/test/ThreadPoolExecutorTest.cpp b/folly/executors/test/ThreadPoolExecutorTest.cpp index 40b4af15..fd96b9f1 100644 --- a/folly/executors/test/ThreadPoolExecutorTest.cpp +++ b/folly/executors/test/ThreadPoolExecutorTest.cpp @@ -19,9 +19,9 @@ #include #include #include -#include -#include #include +#include +#include #include using namespace folly; diff --git a/folly/executors/NamedThreadFactory.h b/folly/executors/thread_factory/NamedThreadFactory.h similarity index 96% rename from folly/executors/NamedThreadFactory.h rename to folly/executors/thread_factory/NamedThreadFactory.h index 856a5295..2b34be9e 100644 --- a/folly/executors/NamedThreadFactory.h +++ b/folly/executors/thread_factory/NamedThreadFactory.h @@ -23,7 +23,7 @@ #include #include #include -#include +#include namespace folly { diff --git a/folly/executors/PriorityThreadFactory.h b/folly/executors/thread_factory/PriorityThreadFactory.h similarity index 97% rename from folly/executors/PriorityThreadFactory.h rename to folly/executors/thread_factory/PriorityThreadFactory.h index ed46dd35..0c75fefe 100644 --- a/folly/executors/PriorityThreadFactory.h +++ b/folly/executors/thread_factory/PriorityThreadFactory.h @@ -16,7 +16,7 @@ #pragma once -#include +#include #include #include diff --git a/folly/executors/ThreadFactory.h b/folly/executors/thread_factory/ThreadFactory.h similarity index 100% rename from folly/executors/ThreadFactory.h rename to folly/executors/thread_factory/ThreadFactory.h -- 2.34.1