aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--applications/message_handler_openamp/inference_runner.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/applications/message_handler_openamp/inference_runner.cpp b/applications/message_handler_openamp/inference_runner.cpp
index c290773..b462b44 100644
--- a/applications/message_handler_openamp/inference_runner.cpp
+++ b/applications/message_handler_openamp/inference_runner.cpp
@@ -191,8 +191,8 @@ void ethosu_inference_end(ethosu_driver *drv, void *userArg) {
// Get cycle counter
if (response.pmu_cycle_counter_enable) {
- uint64_t cycleCount = ETHOSU_PMU_Get_CCNTR(drv);
- response.pmu_cycle_counter_count = cycleCount;
+ uint64_t cycleCount = ETHOSU_PMU_Get_CCNTR(drv);
+ response.pmu_cycle_counter_count += cycleCount;
ethosu_profiler_add_to_pmu_cycles(&context->profiler_context, cycleCount);
}
@@ -202,8 +202,8 @@ void ethosu_inference_end(ethosu_driver *drv, void *userArg) {
// Get event counters
int i;
for (i = 0; i < numEvents; i++) {
- uint32_t eventValue = ETHOSU_PMU_Get_EVCNTR(drv, i);
- response.pmu_event_count[i] = eventValue;
+ uint32_t eventValue = ETHOSU_PMU_Get_EVCNTR(drv, i);
+ response.pmu_event_count[i] += eventValue;
ethosu_profiler_add_to_pmu_event(&context->profiler_context, i, eventValue);
}