linux-mips
[Top] [All Lists]

Re: MIPS_ATOMIC_SET again (Re: newest kernel

To: Florian Lohoff <flo@rfc822.org>
Subject: Re: MIPS_ATOMIC_SET again (Re: newest kernel
From: Jun Sun <jsun@mvista.com>
Date: Wed, 23 May 2001 14:06:07 -0700
Cc: Joe deBlaquiere <jadb@redhat.com>, "Maciej W. Rozycki" <macro@ds2.pg.gda.pl>, ralf@oss.sgi.com, Pete Popov <ppopov@mvista.com>, George Gensure <werkt@csh.rit.edu>, linux-mips@oss.sgi.com
References: <Pine.GSO.3.96.1010523152429.5196A-100000@delta.ds2.pg.gda.pl> <3B0BF7F8.3050306@redhat.com> <3B0C0475.B9ACE682@mvista.com> <20010523205412.A10981@paradigm.rfc822.org>
Sender: owner-linux-mips@oss.sgi.com
Florian Lohoff wrote:

> My favourit would be to let the glibc on runtime decide whether
> to use sysmips or ll/sc in the atomic test_and_set stuff. This would
> lead to an common atom op in the userspace which is fast on ll/sc
> cpus and gives much lesser performance penaltys in the sysmips case
> than emulating ll/sc.
> 

Do you have an idea how this run-time detection might be implemented?  I am
very curious.  

For example, how will you figure out the existence of ll/sc instruction?  Is
that a test which is a part of every process startup procedure?  Or do you
introduce a new syscall?

Jun

<Prev in Thread] Current Thread [Next in Thread>