Open GoogleCodeExporter opened 9 years ago
Original comment by collinw
on 26 Sep 2009 at 12:05
Original comment by collinw
on 6 Jan 2010 at 11:43
Attached is a preliminary patch that implements inlining for len() on strings
and
lists. The bad thing is that, in my tests, it shows a roughly 2% slowdown, and
I can't
figure out why.
Original comment by intelliy...@gmail.com
on 22 Feb 2010 at 6:34
Attachments:
FWIW, uploaded to rietveld for easier viewing:
http://codereview.appspot.com/218053
Original comment by thomaswout@gmail.com
on 22 Feb 2010 at 6:51
Actual code review: http://codereview.appspot.com/218056/show
Original comment by collinwi...@google.com
on 22 Feb 2010 at 8:36
r1102 added a manually-specialized version of len() for certain types.
### django ###
Min: 0.815731 -> 0.803618: 1.0151x faster
Avg: 0.818294 -> 0.806813: 1.0142x faster
Significant (t=11.238954)
Stddev: 0.00715 -> 0.00729: 1.0191x larger
Timeline: http://tinyurl.com/yl4v2n3
Results from an ultra-synthetic nanobenchmark to demonstrate maximum benefit:
### len ###
Min: 0.001329 -> 0.000866: 1.5347x faster
Avg: 0.001375 -> 0.000894: 1.5391x faster
Significant (t=183.295677)
Stddev: 0.00004 -> 0.00002: 1.5365x smaller
Timeline: http://tinyurl.com/yf3yee5
The more sophisticated Clang-based top-down inliner jyasskin is developing will
need to meet or
exceed this level of performance.
Original comment by collinw
on 23 Feb 2010 at 8:29
Original issue reported on code.google.com by
collinw
on 25 Jul 2009 at 9:53