ARM-software / CMSIS-DSP

CMSIS-DSP embedded compute library for Cortex-M and Cortex-A
https://arm-software.github.io/CMSIS-DSP
Apache License 2.0
454 stars 122 forks source link

Resolve GCC compiler warning in arm_divide_q15() #161

Closed felixvanoost closed 4 months ago

felixvanoost commented 4 months ago

Replaces the hex constants in arm_divide_q15() with their decimal equivalents to prevent GCC from reporting an integer overflow warning (see #159). This occurs because 0x8000 is treated as a positive integer when the 2's complement representation of -32768 was originally intended.