Skip to content

Commit 55e81fa

Browse files
Improve doxygen
1 parent e71a2ba commit 55e81fa

File tree

2 files changed

+22
-2
lines changed

2 files changed

+22
-2
lines changed

Documentation/Doxygen/dsp.dxy.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2430,7 +2430,7 @@ INCLUDE_FILE_PATTERNS =
24302430
# recursively expanded use the := operator instead of the = operator.
24312431
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES.
24322432

2433-
PREDEFINED = DOXYGEN HAS_VECTOR HAS_PREDICATED_LOOP ARM_MATH_NEON=1 ARM_FLOAT16_SUPPORTED=1 __STATIC_FORCEINLINE= __ALIGNED(x)=
2433+
PREDEFINED = DOXYGEN ARM_DSP_ATTRIBUTE= ARM_DSP_TABLE_ATTRIBUTE= HAS_VECTOR HAS_PREDICATED_LOOP ARM_MATH_NEON=1 ARM_FLOAT16_SUPPORTED=1 __STATIC_FORCEINLINE= __ALIGNED(x)=
24342434

24352435
# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then this
24362436
# tag can be used to specify a list of macro names that should be expanded. The

Documentation/Doxygen/src/mainpage.md

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ The library ships with a number of examples which demonstrate how to use the lib
5454

5555
## Toolchain Support {#toolchain}
5656

57-
The library is now tested on Fast Models building with cmake. Core M0, M4, M7, M33, M55, A32 are tested.
57+
The library is now tested on Fast Models building with cmake. Core M0, M4, M7, M33, M55 are tested.
5858

5959
## Access to CMSIS-DSP {#pack}
6060

@@ -120,6 +120,26 @@ Each library project has different preprocessor macros.
120120
- `ARM_MATH_AUTOVECTORIZE`:
121121
- With Helium or Neon, disable the use of vectorized code with C intrinsics and use pure C instead. The vectorization is then done by the compiler.
122122

123+
- `ARM_DSP_ATTRIBUTE`: Can be set to define CMSIS-DSP function as weak functions. This can either be set on the command line when building or in a new `arm_dsp_config.h` header (see below)
124+
125+
- `ARM_DSP_TABLE_ATTRIBUTE`: Can be set to define in which section constant tables must be mapped. This can either be set on the command line when building or in a new `arm_dsp_config.h` header (see below). Another way to set those sections is by modifying the linker scripts since the constant tables are defined only in a restricted set of source files.
126+
127+
- `ARM_DSP_CUSTOM_CONFIG` When set, the file `arm_dsp_config.h` is included by the `arm_math_types.h` headers. You can use this file to define any of the above compilation symbols.
128+
129+
## Code size
130+
131+
Constant tables can use a lot of read only memory. The linker can remove the unused functions and constant tables.
132+
133+
For this you need to use the right initialization functions in the library and the right options for the linker (they are compiler dependent).
134+
135+
For all transforms functions (CFFT, RFFT ...) instead of using a generic initialization function that works for all lengths (like `arm_cff_init_f32`), use a dedicated initialization function for a specific size (like `arm_cfft_init_1024_f32`).
136+
137+
By using the right initialization function, you're telling the linker what is really used.
138+
139+
If you use a generic function, the linker cannot deduce the used lengths and thus will keep all the constant tables required for each length.
140+
141+
Then you need to use the right options for the compiler so that the unused tables and functions are removed. It is compiler dependent but generally the options are named like `-ffunction-sections`, `-fdata-sections`, `--gc-sections` ...
142+
123143
## License {#license}
124144

125145
The CMSIS-DSP is provided free of charge under the [Apache 2.0 License](https://raw.githubusercontent.com/ARM-software/CMSIS-DSP/main/LICENSE).

0 commit comments

Comments
 (0)