------- Comment #11 from oder at eleks dot lviv dot ua 2008-05-21 16:27 ------- (In reply to comment #10) > OSAtomicIncrement32Barrier will return a 32bit signed extended value to a > 64bit > so using a 64bit compare is fine and ok according to the ABI.
Yes, but it returns value in 64-bit register with lower 32 bit being correct and higher 32 bit being nonzero (the garbage) and using 64bit comparison for equality with zero yields incorrect result. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35836