Robert Haas <robertmhaas@gmail.com> writes:
> On Tue, Jul 26, 2011 at 9:57 PM, Robert Haas <robertmhaas@gmail.com> wrote:
>> 1. Add a new flag to each procState called something like "timeToPayAttention".
>> 2. Each call to SIGetDataEntries() iterates over all the ProcStates
>> whose index is < lastBackend and sets stateP->timeToPayAttention =
>> TRUE for each.
>> 3. At the beginning of SIGetDataEntries(), we do an unlocked if
>> (!stateP->timeToPayAttention) return 0.
>> 4. Immediately following that if statement and before acquiring any
>> locks, we set stateP->timeToPayAttention = FALSE.
> There turned out to be a little bit of further subtlety to this, but
> it seems to work. Patch attached.
And?
It didn't sound to me like this could possibly be a performance win,
but I await some numbers ...
regards, tom lane