Commit Graph

11 Commits

Author SHA1 Message Date
Georg Brandl e323e0e91a Fix error handling in PyCode_Optimize, by Alexander Schremmer at EuroPython sprint. 2009-06-29 14:44:49 +00:00
Benjamin Peterson aafa18aa05 teach the peepholer about SETUP_WITH 2009-05-26 12:49:59 +00:00
Jeffrey Yasskin 68d6852006 Backport r69961 to trunk, replacing JUMP_IF_{TRUE,FALSE} with
POP_JUMP_IF_{TRUE,FALSE} and JUMP_IF_{TRUE,FALSE}_OR_POP. This avoids executing
a POP_TOP on each conditional and sometimes allows the peephole optimizer to
skip a JUMP_ABSOLUTE entirely. It speeds up list comprehensions significantly.
2009-02-28 19:03:21 +00:00
Gregory P. Smith dd96db63f6 This reverts r63675 based on the discussion in this thread:
http://mail.python.org/pipermail/python-dev/2008-June/079988.html

Python 2.6 should stick with PyString_* in its codebase.  The PyBytes_* names
in the spirit of 3.0 are available via a #define only.  See the email thread.
2008-06-09 04:58:54 +00:00
Christian Heimes 593daf545b Renamed PyString to PyBytes 2008-05-26 12:51:38 +00:00
Neal Norwitz 4677fbf7de Try to fix a bunch of compiler warnings on Win64. 2008-03-25 04:18:18 +00:00
Neal Norwitz 0031ff3f1c Fix indentation 2008-02-25 01:45:37 +00:00
Neal Norwitz 080b598990 Use macro version of GET_SIZE to avoid Coverity warning (#150) about a possible error. 2007-06-09 04:48:22 +00:00
Raymond Hettinger 20e1199fbe Fix embarrassing typo and fix constantification of None 2007-03-02 19:20:46 +00:00
Neal Norwitz cbeb687c68 Update the peephole optimizer to remove more dead code (jumps after returns)
and inline jumps to returns.
2006-10-14 21:33:38 +00:00
Jeremy Hylton 644dddcc3f Move peephole optimizer to separate file. 2006-08-21 16:19:37 +00:00