I'm building an application for an STM32G0 and noticed that quite a bit of double precision libs such as _strtod_l, __aeabi_dsub, __aeabi_dadd, etc are shown in the linker file. As far as I know, there is no double math being done but obviously something is requiring it.
In an effort to reduce code size, I'm trying to understand why these are linked and see if I can eliminate them to free up valuable flash. The application is quite large so just removing bits of code is not a light effort and I've tried running objdump -D on all .o files, but I don't see any references in this output. Is there a better way?
From map file analysis:
Disassemble and cross-reference so you understand what is using them.
printf/scanf likely to be primary culprits unless you use "lite" versions. Watch also for lazy usage of floats in the HAL, say computing UART bauds, or unpacking clock / pll trees.
I suspect that you are already using the advanced debugging tools, but in any case, I found this video list, I don't know if it helps in your case:
Sorry, I edited my response just a bit too late. I have tried running objdump -D on all my object files and don't see any references (only __aeabi_f* show up). Am I doing the disassembly wrong or missing something?
I'm using things a bit more exotic than objdump, but if you have a list of entry points, and the code is linear, you should be able to establish if anything calls them.
There's perhaps some common code among the functions.
Worst case block fill the memory with 0xCDCDCDCD and see what traps out of the HardFault Handler, and back-trace.