I have an application that is working well, but I am experiencing strange discrepancies when creating a binary (.hex) in release mode.
binary sizes under different circumstances:
Debug Mode, load onto Flash w/KDS: ~52kB (console reported binary size)
Debug Mode, generated .hex file: ~52kB
Release Mode, load onto Flash w/KDS: ~52kB (console reported binary size)
Release Mode, generated .hex file: ~35kB
If I attempt to flash the release mode .hex file with a production utility (Segger J-Flash), the code does not work. The debug version generated .hex file works fine flashing with Segger tool. Based on the code size difference, it seems to be that something was removed or optimized away.
If it makes any difference, I'm using the Kinetis SDK.