This is the mail archive of the kawa@sources.redhat.com mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: performance


Dominique Boucher wrote:

I had a search algorithm implemented in continuation-passing style with the
--full-tailcalls option enabled. Of course, general tail calls are not
really efficient in Kawa compared to plain Java method calls.

An idea for more efficient tail-calls: Compile each procedure to two methods: One takes the aruments and stashes them in the CallContext; the other extracts the arguments from the CalllContext and evaluates the procedure body. This is basically what we currently do, but the new idea is that both methods can be custom-compiled. In that case the main overhead is saving and restoring the parameters from the CallContext (and that can be avoided in non-tail-calls) plus possibly some slight "driver" overhead.
--
--Per Bothner
per@bothner.com http://per.bothner.com/



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]