Re: Memory prefetching while sequentially fetching from SortTuple array, tuplestore - Mailing list pgsql-hackers

From Peter Geoghegan
Subject Re: Memory prefetching while sequentially fetching from SortTuple array, tuplestore
Date
Msg-id CAM3SWZRD25RHiLAGxyVdL_PL3wA57PyHzjbCwTWn2-XJLfxu6w@mail.gmail.com
Whole thread Raw
In response to Memory prefetching while sequentially fetching from SortTuple array, tuplestore  (Peter Geoghegan <pg@heroku.com>)
List pgsql-hackers
On Thu, Jul 16, 2015 at 4:01 PM, Peter Geoghegan <pg@heroku.com> wrote:
> Attached patch adds a portable Postgres wrapper on the GCC intrinsic.
> It also adds a client within tuplesort.c -- a common function that
> seems like a good generic choke point. I can get a speed-up of 6% - 9%
> for all of these cases by prefetching a few SortTuples ahead, for the
> "tuple proper". (In-memory sorts only.)

I added a silly bug during last minute clean-up. I attach a V2.

--
Peter Geoghegan

Attachment

pgsql-hackers by date:

Previous
From: Peter Geoghegan
Date:
Subject: Memory prefetching while sequentially fetching from SortTuple array, tuplestore
Next
From: Tom Lane
Date:
Subject: Bugs in our qsort implementation