Re: 8.0 beta 1 on linux-mipsel R5900 - Mailing list pgsql-hackers

From Neil Conway
Subject Re: 8.0 beta 1 on linux-mipsel R5900
Date
Msg-id 412B57B0.1090109@samurai.com
Whole thread Raw
In response to Re: 8.0 beta 1 on linux-mipsel R5900  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: 8.0 beta 1 on linux-mipsel R5900  (Tom Lane <tgl@sss.pgh.pa.us>)
List 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



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: PITR: XLog File compression on Archive
Next
From: Gaetano Mendola
Date:
Subject: Re: debuging postgres