|
|||||||||||
Technical Support Support Resources
Product Information |
C51: Floating-point Reentrancy in ISR?Information in this article applies to:
QUESTIONThe documentation states floating-point operations are fully reentrant. Does that apply to interrupt routines as well? ANSWERFloating point operations the compiler generates code for (+ - * /) are fully reentrant. But only a few functions in math.h are reentrant. Those that are not reentrant must be protected from interrupts. One way this can be accomplished is to put a wrapper that disables and re-enables interrupts around the floating point math calls. For example:
MORE INFORMATION
SEE ALSO
Last Reviewed: Thursday, February 25, 2021 | ||||||||||
|
Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.