mirror of
https://github.com/0xFEEDC0DE64/arduino-esp32.git
synced 2025-07-03 22:06:32 +02:00
IDF master d93887f9f (#5336)
* Update toolchain * Update package_esp32_index.template.json * add optional component dependencies after Kconfig options are known (#5404) Until this commit, Kconfig options (e.g. CONFIG_TINYUSB_ENABLED) were used in conditions preceding idf_component_register to determine which components need to be added to `arduino` component requirements. However the Kconfig options aren't known at the early expansion stage, when the component CMakeLists.txt files are expanded the first time and requirements are evaluated. So all the conditions evaluated as if the options were not set. This commit changes the logic to only add these components as dependencies when the Kconfig options are known. Dependencies become "weak", which means that if one of the components isn't included into the build for some reason, it is not added as a dependency. This may happen, for example, if the component is not present in the `components` directory or is excluded by setting `COMPONENTS` variable in the project CMakeLists.txt file. This also ensures that if the component is not present, it will not be added as a dependency, and this will allow the build to proceed. Follow-up to https://github.com/espressif/arduino-esp32/pull/5391. Closes https://github.com/espressif/arduino-esp32/issues/5319. * IDF master d93887f9f * PlatformIO updates for CI (#5387) * Update PlatformIO CI build script - Switch to the latest toolchains 8.4.0 for ESP32, ESP32S2, ESP32C3 - Use PlatformIO from master branch for better robustness * Update package.json for PlatformIO Co-authored-by: Ivan Grokhotkov <ivan@espressif.com> Co-authored-by: Valerii Koval <valeros@users.noreply.github.com>
This commit is contained in:
@ -43,6 +43,7 @@ extern "C"
|
||||
*/
|
||||
esp_err_t dspm_mult_f32_ansi(const float *A, const float *B, float *C, int m, int n, int k);
|
||||
esp_err_t dspm_mult_f32_ae32(const float *A, const float *B, float *C, int m, int n, int k);
|
||||
esp_err_t dspm_mult_f32_aes3(const float *A, const float *B, float *C, int m, int n, int k);
|
||||
/**@}*/
|
||||
|
||||
|
||||
@ -128,6 +129,7 @@ esp_err_t dspm_mult_4x4x4_f32_ae32(const float *A, const float *B, float *C);
|
||||
*/
|
||||
esp_err_t dspm_mult_s16_ansi(const int16_t *A, const int16_t *B, int16_t *C, int m, int n, int k, int shift);
|
||||
esp_err_t dspm_mult_s16_ae32(const int16_t *A, const int16_t *B, int16_t *C, int m, int n, int k, int shift);
|
||||
esp_err_t dspm_mult_s16_aes3(const int16_t *A, const int16_t *B, int16_t *C, int m, int n, int k, int shift);
|
||||
/**@}*/
|
||||
|
||||
#ifdef __cplusplus
|
||||
@ -136,46 +138,54 @@ esp_err_t dspm_mult_s16_ae32(const int16_t *A, const int16_t *B, int16_t *C, int
|
||||
|
||||
#if CONFIG_DSP_OPTIMIZED
|
||||
|
||||
#if (dspm_mult_s16_ae32_enabled == 1)
|
||||
#define dspm_mult_s16 dspm_mult_s16_ae32
|
||||
#else
|
||||
#define dspm_mult_s16 dspm_mult_s16_ansi
|
||||
#endif
|
||||
|
||||
#if (dspm_mult_f32_ae32_enabled == 1)
|
||||
#define dspm_mult_f32 dspm_mult_f32_ae32
|
||||
#else
|
||||
#define dspm_mult_f32 dspm_mult_f32_ansi
|
||||
#endif
|
||||
#if (dspm_mult_s16_aes3_enabled == 1)
|
||||
#define dspm_mult_s16 dspm_mult_s16_aes3
|
||||
#elif (dspm_mult_s16_ae32_enabled == 1)
|
||||
#define dspm_mult_s16 dspm_mult_s16_ae32
|
||||
#else
|
||||
#define dspm_mult_s16 dspm_mult_s16_ansi
|
||||
#endif
|
||||
|
||||
#if (dspm_mult_3x3x1_f32_ae32_enabled == 1)
|
||||
#define dspm_mult_3x3x1_f32 dspm_mult_3x3x1_f32_ae32
|
||||
#else
|
||||
#define dspm_mult_3x3x1_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 3, 3, 1)
|
||||
#endif
|
||||
#if (dspm_mult_3x3x3_f32_ae32_enabled == 1)
|
||||
#define dspm_mult_3x3x3_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 3, 3, 3)
|
||||
#else
|
||||
#define dsps_sub_f32 dsps_sub_f32_ansi
|
||||
#endif
|
||||
#if (dspm_mult_4x4x1_f32_ae32_enabled == 1)
|
||||
#define dspm_mult_4x4x1_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 4, 4, 1)
|
||||
#else
|
||||
#define dsps_sub_f32 dsps_sub_f32_ansi
|
||||
#endif
|
||||
#if (dspm_mult_4x4x4_f32_ae32_enabled == 1)
|
||||
#define dspm_mult_4x4x4_f32 dspm_mult_4x4x4_f32_ae32
|
||||
#else
|
||||
#define dspm_mult_4x4x4_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 4, 4, 4)
|
||||
#endif
|
||||
#if (dspm_mult_f32_aes3_enabled == 1)
|
||||
#define dspm_mult_f32 dspm_mult_f32_aes3
|
||||
#elif (dspm_mult_f32_ae32_enabled == 1)
|
||||
#define dspm_mult_f32 dspm_mult_f32_ae32
|
||||
#else
|
||||
#define dspm_mult_f32 dspm_mult_f32_ansi
|
||||
#endif
|
||||
|
||||
#if (dspm_mult_3x3x1_f32_ae32_enabled == 1)
|
||||
#define dspm_mult_3x3x1_f32 dspm_mult_3x3x1_f32_ae32
|
||||
#else
|
||||
#define dspm_mult_3x3x1_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 3, 3, 1)
|
||||
#endif
|
||||
#if (dspm_mult_3x3x3_f32_ae32_enabled == 1)
|
||||
#define dspm_mult_3x3x3_f32(A,B,C) dspm_mult_3x3x3_f32_ae32(A,B,C)
|
||||
#else
|
||||
#define dspm_mult_3x3x3_f32(A,B,C) dspm_mult_f32_ansi(A,B,B,3,3,3);
|
||||
#endif
|
||||
#if (dspm_mult_4x4x1_f32_ae32_enabled == 1)
|
||||
#define dspm_mult_4x4x1_f32(A,B,C) dspm_mult_4x4x1_f32_ae32(A,B,C)
|
||||
#else
|
||||
#define dspm_mult_4x4x1_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 4, 4, 1)
|
||||
#endif
|
||||
|
||||
#if (dspm_mult_f32_aes3_enabled == 1)
|
||||
#define dspm_mult_4x4x4_f32(A,B,C) dspm_mult_f32_aes3(A,B,C, 4, 4, 4)
|
||||
#elif (dspm_mult_4x4x4_f32_ae32_enabled == 1)
|
||||
#define dspm_mult_4x4x4_f32 dspm_mult_4x4x4_f32_ae32
|
||||
#else
|
||||
#define dspm_mult_4x4x4_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 4, 4, 4)
|
||||
#endif
|
||||
|
||||
#else
|
||||
#define dspm_mult_s16 dspm_mult_s16_ansi
|
||||
#define dspm_mult_f32 dspm_mult_f32_ansi
|
||||
#define dspm_mult_3x3x1_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 3, 3, 1)
|
||||
#define dsps_sub_f32 dsps_sub_f32_ansi
|
||||
#define dsps_sub_f32 dsps_sub_f32_ansi
|
||||
#define dspm_mult_4x4x4_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 4, 4, 4)
|
||||
#define dspm_mult_s16 dspm_mult_s16_ansi
|
||||
#define dspm_mult_f32 dspm_mult_f32_ansi
|
||||
#define dspm_mult_3x3x1_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 3, 3, 1)
|
||||
#define dsps_sub_f32 dsps_sub_f32_ansi
|
||||
#define dsps_add_f32 dsps_add_f32_ansi
|
||||
#define dspm_mult_4x4x4_f32(A,B,C) dspm_mult_f32_ansi(A,B,C, 4, 4, 4)
|
||||
#endif // CONFIG_DSP_OPTIMIZED
|
||||
|
||||
|
||||
|
@ -1,8 +1,9 @@
|
||||
#ifndef _dspm_mult_platform_H_
|
||||
#define _dspm_mult_platform_H_
|
||||
|
||||
#include "sdkconfig.h"
|
||||
|
||||
|
||||
#ifdef __XTENSA__
|
||||
#include <xtensa/config/core-isa.h>
|
||||
#include <xtensa/config/core-matmap.h>
|
||||
|
||||
@ -22,5 +23,11 @@
|
||||
#define dspm_mult_s16_ae32_enabled 1
|
||||
|
||||
#endif
|
||||
#endif // __XTENSA__
|
||||
|
||||
#if CONFIG_IDF_TARGET_ESP32S3
|
||||
#define dspm_mult_f32_aes3_enabled 1
|
||||
#define dspm_mult_s16_aes3_enabled 1
|
||||
#endif
|
||||
|
||||
#endif // _dspm_mult_platform_H_
|
Reference in New Issue
Block a user