From: 오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 Date: Thu, 8 Aug 2019 09:51:29 +0000 (+0900) Subject: Revise acl cl backend cmake (#6391) X-Git-Tag: submit/tizen/20190809.050447~14 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f3103e9fd1eaf1aa23f1933461f0e36562404505;p=platform%2Fcore%2Fml%2Fnnfw.git Revise acl cl backend cmake (#6391) - Set strict build option: nnfw_common - Remove needless link - Update header include for acl common Signed-off-by: Hyeongseok Oh --- diff --git a/runtimes/neurun/backend/acl_cl/CMakeLists.txt b/runtimes/neurun/backend/acl_cl/CMakeLists.txt index 2dd7959..46d90b8 100644 --- a/runtimes/neurun/backend/acl_cl/CMakeLists.txt +++ b/runtimes/neurun/backend/acl_cl/CMakeLists.txt @@ -11,14 +11,10 @@ file(GLOB_RECURSE SOURCES "*.cc") add_library(${LIB_NEURUN_BACKEND_ACL_CL} SHARED ${SOURCES}) target_include_directories(${LIB_NEURUN_BACKEND_ACL_CL} PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}) -target_include_directories(${LIB_NEURUN_BACKEND_ACL_CL} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/..) - -target_link_libraries(${LIB_NEURUN_BACKEND_ACL_CL} arm_compute) -target_link_libraries(${LIB_NEURUN_BACKEND_ACL_CL} arm_compute_ex) -target_link_libraries(${LIB_NEURUN_BACKEND_ACL_CL} neurun-core) -target_link_libraries(${LIB_NEURUN_BACKEND_ACL_CL} ${LIB_NEURUN_BACKEND_ACL_COMMON}) - -target_compile_options(${LIB_NEURUN_BACKEND_ACL_CL} PRIVATE -Wall -Wextra -Werror) +target_link_libraries(${LIB_NEURUN_BACKEND_ACL_CL} PRIVATE neurun-core) +target_link_libraries(${LIB_NEURUN_BACKEND_ACL_CL} PRIVATE ${LIB_NEURUN_BACKEND_ACL_COMMON}) +target_link_libraries(${LIB_NEURUN_BACKEND_ACL_CL} PRIVATE nnfw_common) set_target_properties(${LIB_NEURUN_BACKEND_ACL_CL} PROPERTIES OUTPUT_NAME backend_acl_cl) + install(TARGETS ${LIB_NEURUN_BACKEND_ACL_CL} DESTINATION lib) diff --git a/runtimes/neurun/backend/acl_cl/KernelGenerator.cc b/runtimes/neurun/backend/acl_cl/KernelGenerator.cc index 0eed6a2..41d0ef8 100644 --- a/runtimes/neurun/backend/acl_cl/KernelGenerator.cc +++ b/runtimes/neurun/backend/acl_cl/KernelGenerator.cc @@ -21,6 +21,10 @@ #include #include +#include +#include +#include + #include "kernel/ConcatLayer.h" #include "model/Index.h" #include "model/DataType.h" @@ -30,9 +34,6 @@ #include "util/logging.h" #include "util/Utils.h" #include "util/Padding.h" -#include "acl_common/AclFunction.h" -#include "acl_common/Convert.h" -#include "acl_common/Swizzle.h" using ::neurun::compiler::IExecutionBuilder; diff --git a/runtimes/neurun/backend/acl_cl/MemoryManager.h b/runtimes/neurun/backend/acl_cl/MemoryManager.h index 540c1db..65338c2 100644 --- a/runtimes/neurun/backend/acl_cl/MemoryManager.h +++ b/runtimes/neurun/backend/acl_cl/MemoryManager.h @@ -23,8 +23,8 @@ #include #include -#include "acl_common/AclMemoryManager.h" -#include "acl_common/AclLinearMemoryManager.h" +#include +#include #include "operand/CLTensor.h" #include "operand/CLSubTensor.h" diff --git a/runtimes/neurun/backend/acl_cl/ShapeFixer.cc b/runtimes/neurun/backend/acl_cl/ShapeFixer.cc index 5fb2b21..e6744cc 100644 --- a/runtimes/neurun/backend/acl_cl/ShapeFixer.cc +++ b/runtimes/neurun/backend/acl_cl/ShapeFixer.cc @@ -21,6 +21,10 @@ #include #include +#include +#include +#include + #include "kernel/ConcatLayer.h" #include "model/Index.h" #include "model/DataType.h" @@ -30,9 +34,6 @@ #include "util/logging.h" #include "util/Utils.h" #include "util/Padding.h" -#include "acl_common/AclFunction.h" -#include "acl_common/Convert.h" -#include "acl_common/Swizzle.h" using ::neurun::compiler::IExecutionBuilder; diff --git a/runtimes/neurun/backend/acl_cl/TensorBuilder.h b/runtimes/neurun/backend/acl_cl/TensorBuilder.h index 160b39a..8ce69a6 100644 --- a/runtimes/neurun/backend/acl_cl/TensorBuilder.h +++ b/runtimes/neurun/backend/acl_cl/TensorBuilder.h @@ -17,7 +17,8 @@ #ifndef __NEURUN_BACKEND_ACL_CL_TENSOR_BUILDER_H__ #define __NEURUN_BACKEND_ACL_CL_TENSOR_BUILDER_H__ -#include "acl_common/TemplTensorBuilder.h" +#include + #include "operand/CLTensor.h" #include "operand/CLSubTensor.h" #include "operand/Object.h" diff --git a/runtimes/neurun/backend/acl_cl/kernel/ConcatLayer.cc b/runtimes/neurun/backend/acl_cl/kernel/ConcatLayer.cc index 04388ce..bbe97c5 100644 --- a/runtimes/neurun/backend/acl_cl/kernel/ConcatLayer.cc +++ b/runtimes/neurun/backend/acl_cl/kernel/ConcatLayer.cc @@ -18,8 +18,9 @@ #include +#include + #include "util/feature/nchw/View.h" -#include "acl_common/Swizzle.h" #include "util/logging.h" namespace diff --git a/runtimes/neurun/backend/acl_cl/operand/CLTensor.cc b/runtimes/neurun/backend/acl_cl/operand/CLTensor.cc index 64bc4a1..4c78d31 100644 --- a/runtimes/neurun/backend/acl_cl/operand/CLTensor.cc +++ b/runtimes/neurun/backend/acl_cl/operand/CLTensor.cc @@ -14,12 +14,13 @@ * limitations under the License. */ +#include "CLTensor.h" + #include #include #include -#include "CLTensor.h" -#include "acl_common/Convert.h" +#include namespace neurun { diff --git a/runtimes/neurun/backend/acl_cl/operand/ICLTensor.h b/runtimes/neurun/backend/acl_cl/operand/ICLTensor.h index 3c29bba..022cec6 100644 --- a/runtimes/neurun/backend/acl_cl/operand/ICLTensor.h +++ b/runtimes/neurun/backend/acl_cl/operand/ICLTensor.h @@ -18,7 +18,8 @@ #define __NEURUN_BACKEND_ACL_CL_OPERAND_I_CL_TENSOR_H__ #include -#include + +#include namespace neurun {