Floating point emulation library and multitasking

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • Floating point emulation library and multitasking

    My question is related to the embOS and IAR C/C++ for ARM compiler and their handling of the floating-point arithmetic emulation on a CPU without floating point coprocessor.

    My application uses Cortex-M3 (NXP LPC1788 ) so I have no VFP. I use Embedded Artists eval board for now.

    Should I be concerned with multitasking affecting somehow the floating point emulation library?
    Are there any global variables used by the f-p library and if so, where are they stored?

    I have a previous experience using floating-point emulator library under uCOS by Micrium with Borland and Paradigm C/C++ compilers based on the project using an older clone of 80186 microcontroller and we had to solve a problem with floating point library being not os-aware and
    putting some global variables at the end of the main code stack. FP library was initialized once at the program start, before the os was started. Then, after the multitasking was running and the task wanted to use floating point library, the code was not able to access previously stored f-p library variables because the stack was switched from main code task to the private task stack…


    Will we have to deal with similar issues with embOS and IAR compilers for ARM?

    I checked the documents available in IAR Workbench but could not find any info related to floating point library reentrancy...

    Thanks!
  • Hello,

    I just tested it with an embOS project and IAR and IAR doesn't use global variables for the software floating point emulation, so they are reentrant.
    You can use embOS with IAR and software floating point emulation without any problems.

    Best regards,
    Til
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.