Raymond Hettinger <raymond.hettin...@gmail.com> added the comment:

+0 It looks like there is a small net win.  Conceptually, constant folding is 
better done upstream where more semantic information is available (rather than 
downstream when the meaning has to be deduced from the opcodes).  The only 
drawback is that if unfolded tuples ever leak out of the AST step or get 
created by the peephole optimization step, then they won't get fixed-up 
downstream (as functionality gets moved out of peephole.c, it creates more 
obligations on the AST code generation step to always produce the best possible 
code because the finally neatening-up step no longer occurs).

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue33318>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to