[HACKERS] Re: frees in psort - Mailing list pgsql-hackers

From Bruce Momjian
Subject [HACKERS] Re: frees in psort
Date
Msg-id 96093b8fc4f9159e7321bac87c8800a2
Whole thread Raw
List pgsql-hackers
>
> Bruce Momjian <maillist@candle.pha.pa.us> writes:
> > Now that I believe the Mariposa code is good
>
> well...
>
> >     best way to perform sort in memory (leftist sort vs. qsort)
>
> replacement/selection (e.g., the leftist tree thingy) is the usual
> technique for run generation.  it can greatly reduce the number of
> passes required to sort.  the main downside is complexity.  there's
> still ongoing research on how to do r/s memory management
> efficiently.  there are also memory system effects: qsort is
> more cache-friendly than r/s if implemented right.
>
> i'd just worry about the first-order effects for now.  the extra
> disk copies (temp relations) are bad - fix that.  the other stuff
> is probably noise.

This is very helpful.  Thanks.

I will concentrate on intergrating the Mariposa code ( to eliminate the
temp tables) and prevent the seven tape files from being generated for
small sorts.


>
> some useful online papers:
>
> http://www.research.microsoft.com/research/barc/Gray/AlphaSort.doc
> ftp://ftp.cs.pdx.edu/pub/faculty/graefe/papers/sort.ps
> --
>   Paul M. Aoki         | University of California at Berkeley
>   aoki@CS.Berkeley.EDU | Dept. of EECS, Computer Science Division #1776
>                        | Berkeley, CA 94720-1776
>


- --
Bruce Momjian
maillist@candle.pha.pa.us

------------------------------

End of hackers-digest V1 #399
*****************************

pgsql-hackers by date:

Previous
From: "Leo Shuster"
Date:
Subject: Re[6]: [HACKERS] \dt and disk access
Next
From: "Thomas G. Lockhart"
Date:
Subject: Re: [HACKERS] problems with sunos4 port, endian?