Re: postgresql and process titles - Mailing list pgsql-hackers

From Tom Lane
Subject Re: postgresql and process titles
Date
Msg-id 2989.1150314688@sss.pgh.pa.us
Whole thread Raw
In response to Re: postgresql and process titles  (Greg Stark <gsstark@mit.edu>)
Responses Re: postgresql and process titles  ("Jim C. Nasby" <jnasby@pervasive.com>)
List pgsql-hackers
Greg Stark <gsstark@mit.edu> writes:
> Tom Lane <tgl@sss.pgh.pa.us> writes:
>> This sounds good until you think about locking.  It'd be quite
>> impractical to implement anything as fine-grained as EXPLAIN ANALYZE
>> this way, because of the overhead involved in taking and releasing
>> spinlocks.

> I'm not entirely convinced. The only other process that would be looking at
> the information would be the statistics accumulator which would only be waking
> up every 100ms or so. There would be no contention with other backends
> reporting their info.

The numbers I've been looking at lately say that heavy lock traffic is
expensive, particularly on SMP machines, even with zero contention.
Seems the cache coherency protocol costs a lot even when it's not doing
anything...
        regards, tom lane


pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: 64-bit API for large objects
Next
From: "Jim C. Nasby"
Date:
Subject: Re: Alternative variable length structure