Re: What is the most fast sorting algorithm?
- From: Logan Shaw <lshaw-usenet@xxxxxxxxxxxxx>
- Date: Wed, 14 Jun 2006 00:15:42 GMT
Rob Thorpe wrote:
In any situation where you care about calling some function for
comparison you would inline the compare function straight into the sort
code. Maybe by keeping it as an external function but instructing the
language to inline it.
This can be done in many languages, but unfortunately not easily in C.
A bit off topic, but this is one of the things that, to me, has great
potential with languages like Java and C# where the machine code is
generated at runtime: in theory, the virtual machine could notice
that some function is being called inside a tight loop and then
dynamically inline it. The cost to do this wouldn't be zero, but
the benefits would be good: you'd get most of the performance of
manually inlining it but none of the code ugliness.
I don't know if any current JVMs or other virtual machines do anything
like this kind of aggressive optimization, but maybe in a few years...
- Logan
.
- Follow-Ups:
- Re: What is the most fast sorting algorithm?
- From: Rob Thorpe
- Re: What is the most fast sorting algorithm?
- References:
- What is the most fast sorting algorithm?
- From: Jack
- Re: What is the most fast sorting algorithm?
- From: Nelu
- Re: What is the most fast sorting algorithm?
- From: Peteris Krumins
- Re: What is the most fast sorting algorithm?
- From: Dann Corbit
- Re: What is the most fast sorting algorithm?
- From: Googmeister
- Re: What is the most fast sorting algorithm?
- From: Dann Corbit
- Re: What is the most fast sorting algorithm?
- From: Googmeister
- Re: What is the most fast sorting algorithm?
- From: Dann Corbit
- Re: What is the most fast sorting algorithm?
- From: Googmeister
- Re: What is the most fast sorting algorithm?
- From: Dann Corbit
- Re: What is the most fast sorting algorithm?
- From: CBFalconer
- Re: What is the most fast sorting algorithm?
- From: Rob Thorpe
- What is the most fast sorting algorithm?
- Prev by Date: Re: Probability related question and arrays
- Next by Date: Re: finding nearest place
- Previous by thread: Re: What is the most fast sorting algorithm?
- Next by thread: Re: What is the most fast sorting algorithm?
- Index(es):
Relevant Pages
|