1. 10 Sep, 2010 3 commits
  2. 04 Sep, 2010 1 commit
  3. 17 Aug, 2010 1 commit
  4. 13 Aug, 2010 1 commit
  5. 20 Jul, 2010 2 commits
  6. 10 Jul, 2010 1 commit
  7. 25 Jun, 2010 1 commit
  8. 23 Jun, 2010 1 commit
  9. 30 May, 2010 1 commit
  10. 09 May, 2010 1 commit
  11. 03 May, 2010 2 commits
  12. 01 Apr, 2010 1 commit
  13. 21 Mar, 2010 5 commits
  14. 12 Mar, 2010 1 commit
  15. 07 Mar, 2010 1 commit
  16. 11 Feb, 2010 1 commit
  17. 10 Nov, 2009 1 commit
  18. 31 Oct, 2009 1 commit
  19. 03 Oct, 2009 1 commit
  20. 21 Jul, 2009 2 commits
    • Alexandre Vassalotti's avatar
      Merged revisions 73750 via svnmerge from · bfc3099f
      Alexandre Vassalotti authored
      svn+ssh://pythondev@svn.python.org/python/trunk
      
      ........
        r73750 | benjamin.peterson | 2009-07-01 19:45:19 -0400 (Wed, 01 Jul 2009) | 1 line
      
        small optimization: avoid popping the current block until we have to
      ........
      bfc3099f
    • Alexandre Vassalotti's avatar
      Merged revisions 72487-72488,72879 via svnmerge from · 7b82b40a
      Alexandre Vassalotti authored
      svn+ssh://pythondev@svn.python.org/python/trunk
      
      ........
        r72487 | jeffrey.yasskin | 2009-05-08 17:51:06 -0400 (Fri, 08 May 2009) | 7 lines
      
        PyCode_NewEmpty:
        Most uses of PyCode_New found by http://www.google.com/codesearch?q=PyCode_New
        are trying to build an empty code object, usually to put it in a dummy frame
        object. This patch adds a PyCode_NewEmpty wrapper which lets the user specify
        just the filename, function name, and first line number, instead of also
        requiring lots of code internals.
      ........
        r72488 | jeffrey.yasskin | 2009-05-08 18:23:21 -0400 (Fri, 08 May 2009) | 13 lines
      
        Issue 5954, PyFrame_GetLineNumber:
        Most uses of PyCode_Addr2Line
        (http://www.google.com/codesearch?q=PyCode_Addr2Line) are just trying to get
        the line number of a specified frame, but there's no way to do that directly.
        Forcing people to go through the code object makes them know more about the
        guts of the interpreter than they should need.
      
        The remaining uses of PyCode_Addr2Line seem to be getting the line from a
        traceback (for example,
        http://www.google.com/codesearch/p?hl=en#u_9_nDrchrw/pygame-1.7.1release/src/base.c&q=PyCode_Addr2Line),
        which is replaced by the tb_lineno field.  So we may be able to deprecate
        PyCode_Addr2Line entirely for external use.
      ........
        r72879 | jeffrey.yasskin | 2009-05-23 19:23:01 -0400 (Sat, 23 May 2009) | 14 lines
      
        Issue #6042:
        lnotab-based tracing is very complicated and isn't documented very well.  There
        were at least 3 comment blocks purporting to document co_lnotab, and none did a
        very good job. This patch unifies them into Objects/lnotab_notes.txt which
        tries to completely capture the current state of affairs.
      
        I also discovered that we've attached 2 layers of patches to the basic tracing
        scheme. The first layer avoids jumping to instructions that don't start a line,
        to avoid problems in if statements and while loops.  The second layer
        discovered that jumps backward do need to trace at instructions that don't
        start a line, so it added extra lnotab entries for 'while' and 'for' loops, and
        added a special case for backward jumps within the same line. I replaced these
        patches by just treating forward and backward jumps differently.
      ........
      7b82b40a
  21. 28 Jun, 2009 6 commits
  22. 30 May, 2009 1 commit
  23. 26 Feb, 2009 1 commit
    • Benjamin Peterson's avatar
      Merged revisions 69811,69947 via svnmerge from · efb06b0d
      Benjamin Peterson authored
      svn+ssh://pythondev@svn.python.org/python/trunk
      
      ........
        r69811 | collin.winter | 2009-02-20 13:30:41 -0600 (Fri, 20 Feb 2009) | 2 lines
      
        Issue 5176: special-case string formatting in BINARY_MODULO implementation. This shows a modest (1-3%) speed-up in templating systems, for example.
      ........
        r69947 | jeffrey.yasskin | 2009-02-24 16:48:34 -0600 (Tue, 24 Feb 2009) | 3 lines
      
        Tools/scripts/analyze_dxp.py, a module with some helper functions to
        analyze the output of sys.getdxp().
      ........
      efb06b0d
  24. 25 Feb, 2009 1 commit
    • Jeffrey Yasskin's avatar
      http://bugs.python.org/issue4715 · 9de7ec78
      Jeffrey Yasskin authored
      This patch by Antoine Pitrou optimizes the bytecode for conditional branches by
      merging the following "POP_TOP" instruction into the conditional jump.  For
      example, the list comprehension "[x for x in l if not x]" produced the
      following bytecode:
      
        1           0 BUILD_LIST               0
                    3 LOAD_FAST                0 (.0)
              >>    6 FOR_ITER                23 (to 32)
                    9 STORE_FAST               1 (x)
                   12 LOAD_FAST                1 (x)
                   15 JUMP_IF_TRUE            10 (to 28)
                   18 POP_TOP
                   19 LOAD_FAST                1 (x)
                   22 LIST_APPEND              2
                   25 JUMP_ABSOLUTE            6
              >>   28 POP_TOP
                   29 JUMP_ABSOLUTE            6
              >>   32 RETURN_VALUE
      
      but after the patch it produces the following bytecode:
      
        1           0 BUILD_LIST               0
                    3 LOAD_FAST                0 (.0)
              >>    6 FOR_ITER                18 (to 27)
                    9 STORE_FAST               1 (x)
                   12 LOAD_FAST                1 (x)
                   15 POP_JUMP_IF_TRUE         6
                   18 LOAD_FAST                1 (x)
                   21 LIST_APPEND              2
                   24 JUMP_ABSOLUTE            6
              >>   27 RETURN_VALUE
      
      Notice that not only the code is shorter, but the conditional jump
      (POP_JUMP_IF_TRUE) jumps right to the start of the loop instead of going through
      the JUMP_ABSOLUTE at the end. "continue" statements are helped
      similarly.
      
      Furthermore, the old jump opcodes (JUMP_IF_FALSE, JUMP_IF_TRUE) have been
      replaced by two new opcodes:
      - JUMP_IF_TRUE_OR_POP, which jumps if true and pops otherwise
      - JUMP_IF_FALSE_OR_POP, which jumps if false and pops otherwise
      9de7ec78
  25. 25 Jan, 2009 1 commit
  26. 17 Jan, 2009 1 commit