diff options
author | Matteo Martincigh <matteo.martincigh@arm.com> | 2019-08-08 13:46:32 +0100 |
---|---|---|
committer | Matteo Martincigh <matteo.martincigh@arm.com> | 2019-08-12 15:43:42 +0100 |
commit | 4e73b429ddfebef9beb64872d3e54a14bceccb29 (patch) | |
tree | 4df1460ac6fa836af5202ece84184bab136fb94d /src/backends/dynamic/reference/CMakeLists.txt | |
parent | 1fa19197a5673c57058efe19d94db223a93bc206 (diff) | |
download | armnn-4e73b429ddfebef9beb64872d3e54a14bceccb29.tar.gz |
IVGCVSW-3546 Create a reference dynamic backend to use for testing and as
an example in the docs
* Wrapped the reference backend into a dynamic backend
* Moved the static registration code to a separate file, so that
it is possible to create the reference dynamic backend that does not
register statically into armnn
* Added unit test
Change-Id: I1074d21b020820f9ac8c7178388be773b447555a
Signed-off-by: Matteo Martincigh <matteo.martincigh@arm.com>
Diffstat (limited to 'src/backends/dynamic/reference/CMakeLists.txt')
-rw-r--r-- | src/backends/dynamic/reference/CMakeLists.txt | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/backends/dynamic/reference/CMakeLists.txt b/src/backends/dynamic/reference/CMakeLists.txt new file mode 100644 index 0000000000..e9a94af2fc --- /dev/null +++ b/src/backends/dynamic/reference/CMakeLists.txt @@ -0,0 +1,28 @@ +# +# Copyright © 2017 Arm Ltd. All rights reserved. +# SPDX-License-Identifier: MIT +# + +# File needed to wrap the existing backend into a dynamic one +list(APPEND armnnRefDynamicBackend_sources + RefDynamicBackend.cpp + RefDynamicBackend.hpp +) + +# Set the backend source path +set(RefBackendPath ${PROJECT_SOURCE_DIR}/src/backends/reference) + +# Source files of the backend, taken directly from the source tree +file(GLOB RefBackendBaseFiles ${RefBackendPath}/*.cpp) +set(RefBackendFiles ${RefBackendBaseFiles}) + +# Remove the file that contains the static backend registration +list(REMOVE_ITEM RefBackendFiles ${RefBackendPath}/RefRegistryInitializer.cpp) + +# Create the shared object +add_library(Arm_CpuRef_backend MODULE ${armnnRefDynamicBackend_sources} ${RefBackendFiles}) +target_include_directories(Arm_CpuRef_backend PRIVATE ${PROJECT_SOURCE_DIR}/src/armnn) +target_include_directories(Arm_CpuRef_backend PRIVATE ${PROJECT_SOURCE_DIR}/src/armnnUtils) +target_include_directories(Arm_CpuRef_backend PRIVATE ${PROJECT_SOURCE_DIR}/src/backends) +set_target_properties(Arm_CpuRef_backend PROPERTIES PREFIX "") +target_link_libraries(Arm_CpuRef_backend armnn) |