[Patches] [ python-Patches-506436 ] GETCONST/GETNAME/GETNAMEV speedup
noreply@sourceforge.net
noreply@sourceforge.net
Mon, 22 Jul 2002 20:34:06 -0700
Patches item #506436, was opened at 2002-01-21 08:39
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=506436&group_id=5470
Category: Core (C code)
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: Skip Montanaro (montanaro)
Assigned to: Tim Peters (tim_one)
Summary: GETCONST/GETNAME/GETNAMEV speedup
Initial Comment:
The attached patch redefines the GETCONST, GETNAME &
GETNAMEV
macros to do the following:
* access the code object's consts
and names through
local variables instead of the long chain from
f
* use access macros to index the tuples and get
the C string
names
The code appears correct, and I've had no trouble
with
it. It only provides the most trivial of
improvement on pystone
(around 1% when I see
anything), but it's all those little things
that
add up, right?
Skip
----------------------------------------------------------------------
>Comment By: Neal Norwitz (nnorwitz)
Date: 2002-07-22 23:34
Message:
Logged In: YES
user_id=33168
Skip, I modified this code some, but your technique is still
valid. I got rid of one of the indirections already. The
patch can easily be updated. Seems like the patch shouldn't
hurt. Tim?
----------------------------------------------------------------------
Comment By: Skip Montanaro (montanaro)
Date: 2002-07-09 19:45
Message:
Logged In: YES
user_id=44345
Looking for a vote up or down on this one...
----------------------------------------------------------------------
Comment By: Skip Montanaro (montanaro)
Date: 2002-01-21 08:47
Message:
Logged In: YES
user_id=44345
Whoops... Make the "observed" speedup 0.1%...
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=506436&group_id=5470