Is it possible to switch off optimization of a specific function?
A friend of mine has the problem that the gcc optimization makes some (unknown to me) μ-controller-code not work.
We know which functions it is, but we have no clue of the code itself so the easiest and safest way would probably be to just switch it off for the whole function.
Sadly http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html shows that there is a an optimize function attribute / pragma, but it requires gcc 4.4, which we do not have.
thanks in advance
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…