Automatic, portable optimization of global access
Michael Hudson
mwh at python.net
Mon Apr 19 06:48:13 EDT 2004
python at rcn.com (Raymond Hettinger) writes:
> FWIW, I've posted a brief, but powerful recipe for a bytecode
> optimization that saves known globals as constants:
>
> http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/277940
You seem to have reimplemented:
http://bytecodehacks.sourceforge.net/bch-docs/bch/module-bytecodehacks.closure.html
:-)
Indeed the first "bytecodehack" was very similar to this.
Cheers,
mwh
--
ZAPHOD: Listen three eyes, don't try to outwierd me, I get stranger
things than you free with my breakfast cereal.
-- The Hitch-Hikers Guide to the Galaxy, Episode 7
More information about the Python-list
mailing list