dma: use ccomp_timer component for testing performance metric

ccomp_timer now becomes a standalone component, located in the component registry.
we can use that in the test app by component manager.
This commit is contained in:
morris
2023-04-28 17:18:06 +08:00
parent 74d87aef0c
commit da3b3cf4a4
3 changed files with 5 additions and 3 deletions

View File

@@ -1,7 +1,5 @@
# This is the project CMakeLists.txt file for the test subproject
cmake_minimum_required(VERSION 3.16)
set(EXTRA_COMPONENT_DIRS "$ENV{IDF_PATH}/tools/unit-test-app/components")
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
project(dma_test)

View File

@@ -0,0 +1,2 @@
dependencies:
ccomp_timer: "^1.0.0"

View File

@@ -14,12 +14,14 @@
#include "freertos/task.h"
#include "freertos/semphr.h"
#include "unity.h"
#include "test_utils.h"
#include "ccomp_timer.h"
#include "esp_async_memcpy.h"
#include "soc/soc_caps.h"
#include "hal/dma_types.h"
#define IDF_LOG_PERFORMANCE(item, value_fmt, value, ...) \
printf("[Performance][%s]: " value_fmt "\n", item, value, ##__VA_ARGS__)
#define ALIGN_UP(addr, align) (((addr) + (align)-1) & ~((align)-1))
#define ALIGN_DOWN(size, align) ((size) & ~((align) - 1))