From dcd459440fae6e60e49a08f9c3c816c1f82c9a0e Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Fri, 7 May 2021 12:48:35 +0300 Subject: [PATCH] Moved ie_thread_affinity.hpp to private API --- .../threading/ie_thread_affinity.hpp | 22 +++++++++---------- .../src/mkldnn_plugin/mkldnn_exec_network.cpp | 1 - 2 files changed, 11 insertions(+), 12 deletions(-) rename inference-engine/src/{plugin_api => inference_engine}/threading/ie_thread_affinity.hpp (77%) diff --git a/inference-engine/src/plugin_api/threading/ie_thread_affinity.hpp b/inference-engine/src/inference_engine/threading/ie_thread_affinity.hpp similarity index 77% rename from inference-engine/src/plugin_api/threading/ie_thread_affinity.hpp rename to inference-engine/src/inference_engine/threading/ie_thread_affinity.hpp index 3375de6a5994a7..e4c80e2bd3c738 100644 --- a/inference-engine/src/plugin_api/threading/ie_thread_affinity.hpp +++ b/inference-engine/src/inference_engine/threading/ie_thread_affinity.hpp @@ -24,18 +24,18 @@ using cpu_set_t = void; * * @param mask The mask */ -INFERENCE_ENGINE_API_CPP(void) ReleaseProcessMask(cpu_set_t* mask); +void ReleaseProcessMask(cpu_set_t* mask); /** * @brief Deleter for process mask * @ingroup ie_dev_api_threading */ struct ReleaseProcessMaskDeleter { - /** - * @brief A callable operator to release object - * - * @param mask The mask to release - */ + /** + * @brief A callable operator to release object + * + * @param mask The mask to release + */ void operator()(cpu_set_t* mask) const { ReleaseProcessMask(mask); } @@ -52,7 +52,7 @@ using CpuSet = std::unique_ptr; * @ingroup ie_dev_api_threading * @return A core affinity mask */ -INFERENCE_ENGINE_API_CPP(std::tuple) GetProcessMask(); +std::tuple GetProcessMask(); /** * @brief Pins current thread to a set of cores determined by the mask @@ -64,18 +64,18 @@ INFERENCE_ENGINE_API_CPP(std::tuple) GetProcessMask(); * @param[in] processMask The process mask * @return `True` in case of success, `false` otherwise */ -INFERENCE_ENGINE_API_CPP(bool) PinThreadToVacantCore(int thrIdx, int hyperThreads, int ncores, const CpuSet& processMask); +bool PinThreadToVacantCore(int thrIdx, int hyperThreads, int ncores, const CpuSet& processMask); /** * @brief Pins thread to a spare core in the round-robin scheme, while respecting the given process mask. - * The function can also handle the hyper-threading (by populating the physical cores first) + * The function can also handle the hyper-threading (by populating the physical cores first) * @ingroup ie_dev_api_threading * * @param[in] ncores The ncores * @param[in] processMask The process mask * @return `True` in case of success, `false` otherwise */ -INFERENCE_ENGINE_API_CPP(bool) PinCurrentThreadByMask(int ncores, const CpuSet& processMask); +bool PinCurrentThreadByMask(int ncores, const CpuSet& processMask); /** * @brief Pins a current thread to a socket. @@ -84,5 +84,5 @@ INFERENCE_ENGINE_API_CPP(bool) PinCurrentThreadByMask(int ncores, const CpuSet& * @param[in] socket The socket id * @return `True` in case of success, `false` otherwise */ -INFERENCE_ENGINE_API_CPP(bool) PinCurrentThreadToSocket(int socket); +bool PinCurrentThreadToSocket(int socket); } // namespace InferenceEngine diff --git a/inference-engine/src/mkldnn_plugin/mkldnn_exec_network.cpp b/inference-engine/src/mkldnn_plugin/mkldnn_exec_network.cpp index ac8b9c32e59958..356abff030b229 100644 --- a/inference-engine/src/mkldnn_plugin/mkldnn_exec_network.cpp +++ b/inference-engine/src/mkldnn_plugin/mkldnn_exec_network.cpp @@ -15,7 +15,6 @@ #include #include -#include #include #include #include