Need to use "isnan" and "isinf" in ARM compiler

Hi,

I'm using the ARM v6 compiler (AC6) in a Keil Studio project, and am having trouble with 'isnan' and 'isinf' calls.  They return false regardless of the value of the single-precision float being passed.  Is there a way to make this work?  Also, how can I pass compiler options using the csolution.yml file format?  Can I pass an argument such as -fno-finite-math-only?  I don't see any examples in documention of what syntax to use.

Also, I'm using 'balanced' as the optimization type.  Is there any documentation to see what that means?  Does it enable 'fast-math'?

Parents
  • ChatGPT to the rescue.  I just learned I can add the options here in my .csolution.yml file:

    # List of miscellaneous tool-specific controls
    misc:
    - for-compiler: AC6 # GDB requires DWARF 5, remove when using uVision Debugger
    C-CPP:
    - -gdwarf-5
    - -fno-finite-math-only
    ASM:
    - -gdwarf-5

    -fno-finite-math-only OR -fno-fast-math fixed the issue for me.

Reply
  • ChatGPT to the rescue.  I just learned I can add the options here in my .csolution.yml file:

    # List of miscellaneous tool-specific controls
    misc:
    - for-compiler: AC6 # GDB requires DWARF 5, remove when using uVision Debugger
    C-CPP:
    - -gdwarf-5
    - -fno-finite-math-only
    ASM:
    - -gdwarf-5

    -fno-finite-math-only OR -fno-fast-math fixed the issue for me.

Children
No data