[Python-Dev] Optimization of Python ASTs: How should we deal with constant values?

Frank Wierzbicki fwierzbicki at gmail.com
Sun May 18 20:49:09 CEST 2008


On Fri, May 2, 2008 at 10:21 AM, Thomas Lee <tom at vector-seven.com> wrote:
> Any Jython folk care to weigh in on this? If there are no major objections I
> think I'm going to forge ahead with an independant Const() node.
I suspect that having a marker for non-int non-str constants could
also be used for some optimization of Jython bytecode emissions as
well, though of course it would depend on the details.  If the path
from raw AST to optimized AST isn't too crazy Jython can just grow the
same logic.  We have really good AST comparison tests these days, so I
bet it won't be a huge problem for us when the time comes.

-Frank


More information about the Python-Dev mailing list