[ros-dev] [ros-diffs] [fireball] 34232: Yuri Sidorov <jura at cp-lab.com> - Prevent boolean flags from being optimized away by compiler (due to PSEH usage) by making them volatile. See issue #3408 for more details.

KJK::Hyperion hackbunny at reactos.com
Wed Jul 2 15:08:20 CEST 2008


Timo Kreuzer ha scritto:
> What about wrapping the _SEH_TRY part in a local inline function? In my 
> tests this successfully prevented the variables from being optimized 
> away. At least under normal optimisation settings.

I find this a terrible, terrible idea. An unreliable side effect of an 
unspecified behavior of a non-ANSI C feature. It will break unoptimized 
builds as soon as we add support for DEP, too, because local functions 
require an executable stack. I am at a loss of words to convey how bad 
of an idea this seems to me


More information about the Ros-dev mailing list