AnsweredAssumed Answered

How to disable optimization for protecting an unused function

Question asked by Jason Cui on Apr 4, 2016
Latest reply on Apr 4, 2016 by ZhangJennie

I created a function, and didn't call it in my project, the compiler treated it as unused dead code and removed it by the linker. I hope the optimization doesn't work only for this function, how can I do? The CodeWarrior I used is ver5.9, and the MCU is MC9S12G128.


Any help would be much appreciate!