From a45e709e2838be7e84c26ce2aaee80825ad195b0 Mon Sep 17 00:00:00 2001 From: Ryan McClelland Date: Sun, 27 Oct 2024 23:30:08 -0700 Subject: [PATCH] manifest: update cmsis-dsp to v1.16.2 Update cmsis-dsp module to v1.16.2 Signed-off-by: Ryan McClelland (cherry picked from commit f5946a546d077fd9858ad8d7346912a944b41bd7) --- modules/cmsis-dsp/CMakeLists.txt | 4 ++-- tests/lib/cmsis_dsp/fastmath/src/q15.c | 4 ++-- tests/lib/cmsis_dsp/fastmath/src/q31.c | 4 ++-- tests/lib/cmsis_dsp/support/src/f16.c | 10 +++++----- tests/lib/cmsis_dsp/support/src/f32.c | 10 +++++----- west.yml | 2 +- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/modules/cmsis-dsp/CMakeLists.txt b/modules/cmsis-dsp/CMakeLists.txt index b4f2b8edd00d77..e5ebbfcf172da1 100644 --- a/modules/cmsis-dsp/CMakeLists.txt +++ b/modules/cmsis-dsp/CMakeLists.txt @@ -730,7 +730,7 @@ if(CONFIG_CMSIS_DSP) ${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_selection_sort_f32.c ${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_sort_f32.c ${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_sort_init_f32.c - ${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_weighted_sum_f32.c + ${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_weighted_average_f32.c ) if ((NOT ARMAC5) AND (NOT DISABLEFLOAT16)) @@ -740,7 +740,7 @@ if(CONFIG_CMSIS_DSP) zephyr_library_sources(${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_q15_to_f16.c) zephyr_library_sources(${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_float_to_f16.c) zephyr_library_sources(${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_f16_to_float.c) - zephyr_library_sources(${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_weighted_sum_f16.c) + zephyr_library_sources(${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_weighted_average_f16.c) zephyr_library_sources(${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_barycenter_f16.c) zephyr_library_sources(${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_f16_to_f64.c) zephyr_library_sources(${CMSIS_DSP_DIR}/Source/SupportFunctions/arm_f64_to_f16.c) diff --git a/tests/lib/cmsis_dsp/fastmath/src/q15.c b/tests/lib/cmsis_dsp/fastmath/src/q15.c index 428dd7b09a3442..72ee64d2f928eb 100644 --- a/tests/lib/cmsis_dsp/fastmath/src/q15.c +++ b/tests/lib/cmsis_dsp/fastmath/src/q15.c @@ -90,10 +90,10 @@ ZTEST(fastmath_q15, test_arm_sqrt_q15) status = arm_sqrt_q15(in_sqrt[index], &output[index]); /* Validate operation status */ - if (in_sqrt[index] <= 0) { + if (in_sqrt[index] < 0) { zassert_equal(status, ARM_MATH_ARGUMENT_ERROR, "square root did fail with an input value " - "of '0'"); + "of less than '0'"); } else { zassert_equal(status, ARM_MATH_SUCCESS, "square root operation did not succeed"); diff --git a/tests/lib/cmsis_dsp/fastmath/src/q31.c b/tests/lib/cmsis_dsp/fastmath/src/q31.c index 23344b659ad92c..d3731658613b80 100644 --- a/tests/lib/cmsis_dsp/fastmath/src/q31.c +++ b/tests/lib/cmsis_dsp/fastmath/src/q31.c @@ -90,10 +90,10 @@ ZTEST(fastmath_q31, test_arm_sqrt_q31) status = arm_sqrt_q31(in_sqrt[index], &output[index]); /* Validate operation status */ - if (in_sqrt[index] <= 0) { + if (in_sqrt[index] < 0) { zassert_equal(status, ARM_MATH_ARGUMENT_ERROR, "square root did fail with an input value " - "of '0'"); + "of less than '0'"); } else { zassert_equal(status, ARM_MATH_SUCCESS, "square root operation did not succeed"); diff --git a/tests/lib/cmsis_dsp/support/src/f16.c b/tests/lib/cmsis_dsp/support/src/f16.c index 6b5c52317039e0..6845a8c8b41428 100644 --- a/tests/lib/cmsis_dsp/support/src/f16.c +++ b/tests/lib/cmsis_dsp/support/src/f16.c @@ -182,7 +182,7 @@ DEFINE_TEST_VARIANT3(support_f16, arm_float_to_f16, 7, ref_f32, ref_f16, 7); DEFINE_TEST_VARIANT3(support_f16, arm_float_to_f16, 16, ref_f32, ref_f16, 16); DEFINE_TEST_VARIANT3(support_f16, arm_float_to_f16, 23, ref_f32, ref_f16, 23); -static void test_arm_weighted_sum_f16( +static void test_arm_weighted_average_f16( int ref_offset, size_t length) { const float16_t *val = (const float16_t *)in_weighted_sum_val; @@ -195,7 +195,7 @@ static void test_arm_weighted_sum_f16( zassert_not_null(output, ASSERT_MSG_BUFFER_ALLOC_FAILED); /* Run test function */ - output[0] = arm_weighted_sum_f16(val, coeff, length); + output[0] = arm_weighted_average_f16(val, coeff, length); /* Validate output */ zassert_true( @@ -207,8 +207,8 @@ static void test_arm_weighted_sum_f16( free(output); } -DEFINE_TEST_VARIANT2(support_f16, arm_weighted_sum_f16, 7, 0, 7); -DEFINE_TEST_VARIANT2(support_f16, arm_weighted_sum_f16, 16, 1, 16); -DEFINE_TEST_VARIANT2(support_f16, arm_weighted_sum_f16, 23, 2, 23); +DEFINE_TEST_VARIANT2(support_f16, arm_weighted_average_f16, 7, 0, 7); +DEFINE_TEST_VARIANT2(support_f16, arm_weighted_average_f16, 16, 1, 16); +DEFINE_TEST_VARIANT2(support_f16, arm_weighted_average_f16, 23, 2, 23); ZTEST_SUITE(support_f16, NULL, NULL, NULL, NULL, NULL); diff --git a/tests/lib/cmsis_dsp/support/src/f32.c b/tests/lib/cmsis_dsp/support/src/f32.c index 70dc73a6b005d8..dc80c045b1e01a 100644 --- a/tests/lib/cmsis_dsp/support/src/f32.c +++ b/tests/lib/cmsis_dsp/support/src/f32.c @@ -145,7 +145,7 @@ DEFINE_TEST_VARIANT3(support_f32, arm_float_to_q7, 15, in_f32, ref_q7, 15); DEFINE_TEST_VARIANT3(support_f32, arm_float_to_q7, 32, in_f32, ref_q7, 32); DEFINE_TEST_VARIANT3(support_f32, arm_float_to_q7, 33, in_f32, ref_q7, 33); -static void test_arm_weighted_sum_f32( +static void test_arm_weighted_average_f32( int ref_offset, size_t length) { const float32_t *val = (const float32_t *)in_weighted_sum_val; @@ -158,7 +158,7 @@ static void test_arm_weighted_sum_f32( zassert_not_null(output, ASSERT_MSG_BUFFER_ALLOC_FAILED); /* Run test function */ - output[0] = arm_weighted_sum_f32(val, coeff, length); + output[0] = arm_weighted_average_f32(val, coeff, length); /* Validate output */ zassert_true( @@ -170,9 +170,9 @@ static void test_arm_weighted_sum_f32( free(output); } -DEFINE_TEST_VARIANT2(support_f32, arm_weighted_sum_f32, 3, 0, 3); -DEFINE_TEST_VARIANT2(support_f32, arm_weighted_sum_f32, 8, 1, 8); -DEFINE_TEST_VARIANT2(support_f32, arm_weighted_sum_f32, 11, 2, 11); +DEFINE_TEST_VARIANT2(support_f32, arm_weighted_average_f32, 3, 0, 3); +DEFINE_TEST_VARIANT2(support_f32, arm_weighted_average_f32, 8, 1, 8); +DEFINE_TEST_VARIANT2(support_f32, arm_weighted_average_f32, 11, 2, 11); static void test_arm_sort_out( const uint32_t *input1, const uint32_t *ref, size_t length, diff --git a/west.yml b/west.yml index 87657ebf6df364..1bfd211711faac 100644 --- a/west.yml +++ b/west.yml @@ -121,7 +121,7 @@ manifest: groups: - hal - name: cmsis-dsp - revision: 6489e771e9c405f1763b52d64a3f17a1ec488ace + revision: d80a49b2bb186317dc1db4ac88da49c0ab77e6e7 path: modules/lib/cmsis-dsp - name: cmsis-nn revision: ea987c1ca661be723de83bd159aed815d6cbd430