[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.
Timo Kreuzer
timo.kreuzer at web.de
Wed Jul 2 13:39:29 CEST 2008
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.
_SEH_TRY
{
void inline tryblock()
{
...
}
tryblock();
}
...
KJK::Hyperion schrieb:
> Alex Ionescu ha scritto:
>
>> If something is happening to these flags, PSEH should be fixed -- not
>> making every flag in the source base a volatile.
>>
>
> PSEH is based setjmp/longjmp, some local variables WILL be reset when an
> exception is caught and they MUST be marked as "volatile". I documented
> this a long time ago
> _______________________________________________
> Ros-dev mailing list
> Ros-dev at reactos.org
> http://www.reactos.org/mailman/listinfo/ros-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.reactos.org/pipermail/ros-dev/attachments/20080702/50959f23/attachment.html
More information about the Ros-dev
mailing list