[PATCH] MIPS: Optimize atomic memory operations for TARGET_OCTEON.
Richard Sandiford
rdsandiford@googlemail.com
Thu Oct 1 05:40:00 GMT 2009
David Daney <ddaney@caviumnetworks.com> writes:
> Richard Sandiford wrote:
>> Richard Sandiford <rdsandiford@googlemail.com> writes:
>>> David Daney <ddaney@caviumnetworks.com> writes:
>>>> * gcc/config/mips/mips.c (mips_process_sync_loop) Emit syncw
>>>> instructions for TARGET_OCTEON.
>>> OK.
>>>
>>> Thanks for the great comment btw.
>>
>> Hmm, actually, I might have been too quick off the mark.
>> __sync*_compare_and_swap are documented as being full barriers even
>> in the case where no SC occurs, so I think you also need to check
>> "required_oldval == 0".
>>
>
> OK, what do you think of this version then?
>
> Tested on mips64-unknown-linux-gnu --with-float=soft --with-arch=octeon
> all default languages and
> RUNTESTFLAGS="--target_board=unix/\{,-mabi=64\}" with no regressions.
>
> OK to commit?
Yeah, looks good, thanks.
Richard
More information about the Gcc-patches
mailing list