From: | Josh Berkus <josh(at)agliodbs(dot)com> |
---|---|
To: | "Jeffrey W(dot) Baker" <jwbaker(at)acm(dot)org> |
Cc: | Luke Lonergan <llonergan(at)greenplum(dot)com>, Ron Peacetree <rjpeace(at)earthlink(dot)net>, pgsql-hackers(at)postgresql(dot)org, pgsql-performance(at)postgresql(dot)org |
Subject: | Re: [PERFORM] A Better External Sort? |
Date: | 2005-09-29 18:03:27 |
Message-ID: | 200509291103.27344.josh@agliodbs.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-performance |
Jeff,
> Josh, do you happen to know how many passes are needed in the multiphase
> merge on your 60GB table?
No, any idea how to test that?
> I think the largest speedup will be to dump the multiphase merge and
> merge all tapes in one pass, no matter how large M. Currently M is
> capped at 6, so a sort of 60GB with 1GB sort memory needs 13 passes over
> the tape. It could be done in a single pass heap merge with N*log(M)
> comparisons, and, more importantly, far less input and output.
Yes, but the evidence suggests that we're actually not using the whole 1GB
of RAM ... maybe using only 32MB of it which would mean over 200 passes
(I'm not sure of the exact match). Just fixing our algorithm so that it
used all of the work_mem permitted might improve things tremendously.
> I would also recommend using an external processes to asynchronously
> feed the tuples into the heap during the merge.
>
> What's the timeframe for 8.2?
Too far out to tell yet. Probably 9mo to 1 year, that's been our history.
--
--Josh
Josh Berkus
Aglio Database Solutions
San Francisco
From | Date | Subject | |
---|---|---|---|
Next Message | Jeffrey W. Baker | 2005-09-29 18:15:41 | Re: [PERFORM] A Better External Sort? |
Previous Message | Jeffrey W. Baker | 2005-09-29 17:44:23 | Re: [PERFORM] A Better External Sort? |
From | Date | Subject | |
---|---|---|---|
Next Message | Jeffrey W. Baker | 2005-09-29 18:15:41 | Re: [PERFORM] A Better External Sort? |
Previous Message | Jeffrey W. Baker | 2005-09-29 17:44:23 | Re: [PERFORM] A Better External Sort? |