Author amaury.forgeotdarc
Recipients amaury.forgeotdarc, gagenellina, georg.brandl, inducer, rhettinger, tim_one
Date 2007-11-27.18:04:16
SpamBayes Score 0.0274527
Marked as misclassified No
Message-id <1196186657.6.0.698765727839.issue1045@psf.upfronthosting.co.za>
In-reply-to
Content
The slowdown is due to the new function _PyObject_LengthHint: on my
Win2K machine, 
the command
  python -m timeit "tuple(1 for _ in xrange(3))"
answers:
  100000 loops, best of 3: 4.14 usec per loop
By adding a line "return rv;" on the second line of
_PyObject_LengthHint, I get:
  100000 loops, best of 3: 2.71 usec per loop

Should we disable this function for some known built-in types?
History
Date User Action Args
2007-11-27 18:04:18amaury.forgeotdarcsetspambayes_score: 0.0274527 -> 0.0274527
recipients: + amaury.forgeotdarc, tim_one, georg.brandl, rhettinger, gagenellina, inducer
2007-11-27 18:04:18amaury.forgeotdarcsetspambayes_score: 0.0274527 -> 0.0274527
messageid: <1196186657.6.0.698765727839.issue1045@psf.upfronthosting.co.za>
2007-11-27 18:04:17amaury.forgeotdarclinkissue1045 messages
2007-11-27 18:04:17amaury.forgeotdarccreate