aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMåns Nilsson <mans.nilsson@arm.com>2022-04-11 14:00:04 +0200
committerAnnie Tallund <annie.tallund@arm.com>2022-07-19 08:53:37 +0200
commit84c478872d449ef18e93089e95e541e5a7586f04 (patch)
tree47bda34da0558b038e77c31243bf9bc7d7cce4a5
parent2ebaac7a007cbfae7fff818e4d6c4c33562eea0e (diff)
downloadethos-u-core-software-84c478872d449ef18e93089e95e541e5a7586f04.tar.gz
Provide CMSIS-Device header as needed for TFLM
Change-Id: Ie78bdf3330765131ab5aee248ef42f175a652218
-rw-r--r--tflite_micro.cmake9
1 files changed, 9 insertions, 0 deletions
diff --git a/tflite_micro.cmake b/tflite_micro.cmake
index a93bf33..d0e0c9d 100644
--- a/tflite_micro.cmake
+++ b/tflite_micro.cmake
@@ -161,6 +161,15 @@ tensorflow_target_sources_glob(tflu GLOB TRUE
target_include_directories(tflu PRIVATE
${TFLU_PATH}/cortex_m_generic)
+# For DWT/PMU counters
+target_link_libraries(tflu PRIVATE cmsis_device)
+target_compile_definitions(tflu PRIVATE ${ARM_CPU})
+
+if("${ARM_CPU}" STREQUAL "ARMCM55")
+ target_compile_definitions(tflu PRIVATE
+ ARM_MODEL_USE_PMU_COUNTERS)
+endif()
+
#############################################################################
# Tensorflow micro lite
#############################################################################