------- Comment #2 from hailijuan at gmail dot com 2009-06-17 10:07 ------- Subject: Re: __sync_fetch_and_add seems not working well for -march=i686
Yes, I have seen the difference. Thanks muchly. I will close it. 2009/6/17 jakub at gcc dot gnu dot org <gcc-bugzi...@gcc.gnu.org>: > > > ------- Comment #1 from jakub at gcc dot gnu dot org 2009-06-17 08:04 ------- > That's undefined behavior, there is no sequence point between the the > evaluation of foo (&n, n) and evaluation of n passed as the next argument. > If foo (&n, n) is evaluated first, you will see 1 2 printed, if n is evaluated > first, you see 1 1. > > > -- > > jakub at gcc dot gnu dot org changed: > > What |Removed |Added > ---------------------------------------------------------------------------- > Status|UNCONFIRMED |RESOLVED > Resolution| |INVALID > > > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40471 > > ------- You are receiving this mail because: ------- > You reported the bug, or are watching the reporter. > -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40471