[Bug tree-optimization/31862] Loop IM and other optimizations harmful for -fopenmp

Andrew Pinski pinskia@gmail.com
Tue May 8 14:59:00 GMT 2007


On 8 May 2007 14:44:16 -0000, dnovillo at acm dot org
<gcc-bugzilla@gcc.gnu.org> wrote:
> The original code did not have a race condition.  The compiler
> transformations introduced a race-condition.  This *is*  a compiler
> bug.

Actually the original code has a race condition, if another thread is
reading from var and then acting on that and writting back.  This is
why threading programming is considered hard.



More information about the Gcc-bugs mailing list