From: | David Rowley <david(dot)rowley(at)2ndquadrant(dot)com> |
---|---|
To: | Peter Geoghegan <pg(at)heroku(dot)com> |
Cc: | Andres Freund <andres(at)anarazel(dot)de>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Memory prefetching while sequentially fetching from SortTuple array, tuplestore |
Date: | 2015-09-03 04:43:02 |
Message-ID: | CAKJS1f8aMfbVTrcx5Uj-3fPueA+Mff-BMqrV75R_=eCpvcPqvQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 3 September 2015 at 07:24, Peter Geoghegan <pg(at)heroku(dot)com> wrote:
> On Wed, Sep 2, 2015 at 7:12 AM, Andres Freund <andres(at)anarazel(dot)de> wrote:
> > What worries me about adding explicit prefetching is that it's *highly*
> > platform and even micro-architecture dependent. Why is looking three
> > elements ahead the right value?
>
> Because that was the fastest value following testing on my laptop. You
> are absolutely right to point out that this isn't a good reason to go
> with the patch -- I share your concern. All I can say in defense of
> that is that other major system software does the same, without any
> regard for the underlying microarchitecture AFAICT. So, yes,
> certainly, more testing is required across a reasonable cross-section
> of platforms to justify the patch.
>
FWIW someone else found 3 to be good on the platform they tested on:
http://www.naftaliharris.com/blog/2x-speedup-with-one-line-of-code/
Peter, would you be able to share the test case which you saw the speedup
on. So far I've been unable to see much of an improvement.
Regards
David Rowley
--
David Rowley http://www.2ndQuadrant.com/
<http://www.2ndquadrant.com/>
PostgreSQL Development, 24x7 Support, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Geoghegan | 2015-09-03 04:50:54 | Re: Memory prefetching while sequentially fetching from SortTuple array, tuplestore |
Previous Message | David Rowley | 2015-09-03 04:28:40 | Re: WIP: Make timestamptz_out less slow. |