Re: 8.0 beta 1 on linux-mipsel R5900

From: Neil Conway <neilc(at)samurai(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Zeugswetter Andreas SB SD <ZeugswetterA(at)spardat(dot)at>, Greg Stark <gsstark(at)mit(dot)edu>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: 8.0 beta 1 on linux-mipsel R5900
Date: 2004-08-24 14:58:56
Message-ID: 412B57B0.1090109@samurai.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
> But yes, a yield primitive would be nice, and so would knowing the
> number of CPUs.

I'm planning on submitting a patch shortly that determines the number of
CPUs in the machine and adjusts the spinlock behavior accordingly (there
are various APIs for getting the # of CPUs, like sysctl() on many Unixen
and GetSystemInfo() on Win32).

Speaking of improving spinlock behavior, there's a Solaris API that I
think might be worth using: schedctl_start() asks the scheduler to not
pre-empt the current process, and schedctl_stop() cancels the request.
The idea the first extremely short periods of time that we're holding a
spinlock, we don't want to get preempted, since if the process was
allowed to run for just a little bit longer it would probably give up
the spinlock. The docs are here:

http://docs.sun.com/db/doc/816-3324/6m9k4vdu1?a=view

-Neil

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2004-08-24 16:08:40 Re: 8.0 beta 1 on linux-mipsel R5900
Previous Message Tom Lane 2004-08-24 14:58:54 Re: PITR: XLog File compression on Archive