[Bug target/35836] Wrong instruction generated for comparison with zero on PPC 64 bit
oder at eleks dot lviv dot ua
gcc-bugzilla@gcc.gnu.org
Wed May 21 16:28:00 GMT 2008
------- 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
More information about the Gcc-bugs
mailing list