Re: [PATCHES] Reorganization of spinlock defines - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [PATCHES] Reorganization of spinlock defines
Date
Msg-id 10919.1063377220@sss.pgh.pa.us
Whole thread Raw
In response to Re: [PATCHES] Reorganization of spinlock defines  ("Marc G. Fournier" <scrappy@postgresql.org>)
Responses Re: [PATCHES] Reorganization of spinlock defines
List pgsql-hackers
"Marc G. Fournier" <scrappy@postgresql.org> writes:
> 'K, now, I know we acquire all our shared_buffers on startup now ... do we
> do the same with semaphores?

Yes.

> If we do acquire at the start, would it not be trivial to add a message to
> the startup messages, based on #_of_semaphores != max_connections, that
> tells ppl that spinlocks aren't being used?

The code already knows whether it's compiled to use spinlocks or not, it
hardly needs to test that way ;-).  I thought you were asking how to
double-check a system that's live today.

I prefer Bruce's idea of a configure-time warning, myself.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: massive quotes?
Next
From: Larry Rosenman
Date:
Subject: Re: __cpu__ defines