Re: strict aliasing

From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: "Robert Haas" <robertmhaas(at)gmail(dot)com>
Cc: "Andres Freund" <andres(at)anarazel(dot)de>, "Florian Weimer" <fweimer(at)bfk(dot)de>, "Ants Aasma" <ants(dot)aasma(at)eesti(dot)ee>, "Thomas Munro" <munro(at)ip9(dot)org>, "Florian Pflug" <fgp(at)phlo(dot)org>, <pgsql-hackers(at)postgresql(dot)org>,"Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: strict aliasing
Date: 2011-11-16 16:44:39
Message-ID: 4EC39417020000250004304A@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov> wrote:

>> This suggests that in the long term, it might be worth [...]

> The other possibility is that the OS is smart enough about moving
> things around to get good locality that sticking locality hints on
> top doesn't really make any difference. Certainly, I would expect
> any OS to be smart enough to allocate backend-local memory on the
> same processor where the task is running, and to avoid moving
> processes between cells more than necessary.

Right. I'm not sure that it will make any more sense to do this
than to do raw access to a disk partition. I don't think it's a
given that we can do a better job of this than the OS does.

> Regarding results instability [...] My working theory is that this
> is the result of spinlock contention.

> So my theory is that now the performance goes down more or less
> "permanently", unless or until there's some momentary break in the
> action that lets the queue of people waiting for that spinlock
> drain out. This is just a wild-ass guess, and I might be totally
> wrong...

Well, I suspect that you're basing that guess on enough evidence
that it's more likely to be right than the wild-assed guesses I've
been throwing out there. :-) I can't say it's inconsistent with
anything I've seen.

-Kevin

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2011-11-16 17:00:21 Re: FlexLocks
Previous Message Kevin Grittner 2011-11-16 16:17:42 Re: FlexLocks