>As documented somewhere... perf-tuning probably... uslock is an order of
>magnitude faster than sysvsem on multiprocessor irix boxes. It is an
>order of magnitude slower than sysvsem on single cpu irix boxes. Also,
>fcntl (or flock, forget which it used in 1.2) is an order of magnitude
>slower than sysvsem on multiprocessor boxes... and about half as fast as
>sysvsem on single cpu boxes.
I have got good results on SGI boxes (multi and single) with using the
MIPS ABI mutex functions, these basically resolve to an atomic test and
set operation and require the user level to decide what to do if
congested (one could do sginap(0) to yield there). For example:
abilock_t mutex;
while (acquire_lock(&sharedMem->mutex)) {
/* congestion case */
Yield();
}
/* do the shared memory manipulation */
release_lock(&sharedMem->mutex);
And opposed to what is documented in the man page, these functions
happen to live in libc and do not require any thread enablement or such
ilk to be used.
Jens-Uwe Mager
HELIOS Software GmbH
Steinriede 3
30827 Garbsen
Germany
Phone: +49 5131 709320
FAX: +49 5131 709325
Internet: jum@helios.de
|