summaryrefslogtreecommitdiffstats
path: root/Python/sigcheck.c
diff options
context:
space:
mode:
authorRaymond Hettinger <python@rcn.com>2003-01-19 05:08:13 (GMT)
committerRaymond Hettinger <python@rcn.com>2003-01-19 05:08:13 (GMT)
commit4bad9ba2827a3cac04b2cffaf0825224b7dc3c55 (patch)
treebf8052fb2aa2b1d0fe03f13694e83c0894beedab /Python/sigcheck.c
parent513a1cd103ba2b67ad88dc58a185fc7b514078bd (diff)
downloadcpython-4bad9ba2827a3cac04b2cffaf0825224b7dc3c55.zip
cpython-4bad9ba2827a3cac04b2cffaf0825224b7dc3c55.tar.gz
cpython-4bad9ba2827a3cac04b2cffaf0825224b7dc3c55.tar.bz2
SF patch #670367: Micro-optimizations for ceval.c
Make the code slightly shorter, faster, and easier to read. * Eliminate unused DUP_TOPX code for x==1. compile.c always generates DUP_TOP instead. * Since only two cases remain for DUP_TOPX, replace the switch-case with if-elseif. * The in-lined integer compare does a CheckExact on both arguments. Since the second is a little more likely to fail, test it first. * The switch-case for IS/IS_NOT and IN/NOT_IN can separate the regular and inverted cases with no additional work. For all four paths, saves a test and jump.
Diffstat (limited to 'Python/sigcheck.c')
0 files changed, 0 insertions, 0 deletions