[ZPT] Re: ZPT Speed Tutorial Wanted
Arnar Lundesgaard
arnar.lundesgaard@creuna.no
Mon, 16 Sep 2002 13:38:45 +0200
"Chris Withers" <chrisw@nipltd.com> wrote in message
news:3D85BB36.30301@nipltd.com...
> Andy Meier wrote:
> > My final bottleneck seems to be using Page Templates. Even a
simple Page
> > Template costs me 400ms to render. To compare, rendering a fairly
simple
> > DTML document takes 9ms.
>
> This sucks :-( The difference, I'm hoping, is that DTML has been
optimised over
> the years and has a C implementation.
>
> > Is there anything I can do to increase the speed of Page Templates
(can I
> > "pre-compile" the templates)? Should I convert my page template
into a
> > python script or dtml document header and footer?
>
> Hmmm, we really need to find a way to optimise the ZPT process
itself, anyone
> got any ideas?
Just a wild guess that I wanted to try myself but have not found time
for yet.
I read on c.l.p about psyco, that gives some speedups for python.
Perhaps someone could try 'psyco.bind' on the ZPT module. (Dunno if
this is possible even.)
It is supposed to work out of the box with ordinary python code, but
I don't know if the PageTemplates code can be classified as such.
Long shot indeed :-)
Arnar Lundesgaard