Hi there,
I am using Cortex-M4 with FPU support (single precision only) for a project. I am looking for an option to confirm that in the entire project we are only using hardware floating point unit for floating point computation. So far have looked into disassembly code to confirm we are using hardware FPU. However, going through every function that performs floating point computation would be tedious.
Hence, I started looking for a better approach and couldn't determine a simple one.
Toolchain Info
Things tried so far
Above options didn't conclusively prove to me that we are only using hardware FPU. Any suggestions would be off great help. Thank you.
I doubt there is a single easy solution for this. It would depend on your code.
One option could be to search for library calls. For example compiling a simple C function to add two floats, compiled to the following with -mfpu=softvfp
test 0x00000000: b580 .. PUSH {r7,lr} 0x00000002: f7fffffe .... BL __aeabi_fadd 0x00000006: bd80 .. POP {r7,pc}
Thank you Ronan.
We have developed custom libraries that perform floating point math and have been cautious to use single precision. However, its not guaranteed and hence the need to figure out a solution to determine this.