From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Brent Verner <brent(at)rcfile(dot)org> |
Cc: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Some interesting results from tweaking spinlocks |
Date: | 2002-01-05 19:01:04 |
Message-ID: | 12679.1010257264@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Brent Verner <brent(at)rcfile(dot)org> writes:
> I suspect using usleep() instead of select() might
> relieve the serialization.
A number of people have suggested that reducing the sleep interval would
improve matters. I tried that just now, again on RedHat's 4-way box,
and was mildly astonished to find that it makes things worse. The graph
below shows pgbench results for both the current code (10 millisec delay
using select()) and a 10-microsec delay using usleep(), with several
different SPINS_PER_DELAY values. Test conditions are otherwise the
same as in my last message (in particular, LWLock patch version 2).
At any given SPINS_PER_DELAY, the 10msec sleep beats the 10usec sleep
handily. I wonder if this indicates a problem with Linux'
implementation of usleep?
regards, tom lane
Attachment | Content-Type | Size |
---|---|---|
image/gif | 8.4 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Sean Chittenden | 2002-01-05 19:11:10 | Re: pgcryto strangeness... |
Previous Message | Hannu Krosing | 2002-01-05 18:13:16 | Re: Some interesting results from tweaking spinlocks |