[stringtemplate-interest] Stringtemplate performances : some figures
Benjamin Niemann
pink at odahoda.de
Sun Mar 1 12:32:35 PST 2009
Hello Mathieu,
On Sun, Mar 1, 2009 at 9:16 PM, Mathieu Clabaut
<mathieu.clabaut at gmail.com> wrote:
> I was in the process on doing a prototype in python to validate the use of
> template engine for some export task inside the Rodin Platform
> (http://wiki.event-b.org).
> I was quite disappointed stringtemplate performances in python: The export
> of a (quite big) model took 49,7 seconds.
> So I tried Mako which is reputed to be quite fast (albeit 3 times slower
> than tenjin : http://www.kuwata-lab.com/tenjin/), and I get the same result
> (Same overhead outside of template generation, and very similar template) in
> 8,7s.
>
> This led to two questions:
> - Do you know of some ways to improve strigtemplate performances ?
The Python version of ST is a very close port of the Java version.
This makes it much easier for me to keep the implementation correct
(as in 'like the reference implementation') - at the price of often
suboptimal, un-pythonic solutions.
I haven't spent time on optimizing it yet, I did not even ran it
through the profiler, so I can't say if there are big and/or easy
opportunities for improvements.
-Ben
> - Are java stringtemplate performances better, or quite the same than those
> of python (I didn't find any benchmark with Stringtemplate on the net) ?
More information about the stringtemplate-interest
mailing list