This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] MIPS: Optimize atomic memory operations for TARGET_OCTEON.


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]