LTO and Redlib?

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by Muis on Thu Feb 26 05:14:34 MST 2015
My code does not depend on semi-hosting, and the release version is always compiled as Redlib (None).

Now last week I tried to debug a HardFault which occurs in my code only with LTO (Link Time Optimization) enabled (-oS). I couldn't find the reason. Today I accidently enabled 'Redlib (Nohost) for my release-build. And now LTO-compiled binaries don't give a HardFault anymore?

What can be the cause of this miraclous behaviour of None Vs NoHost?