On 10/20/2011 5:08 PM, Antoine Pitrou wrote:
> Have you reported gcc's "outdated optimization" issue to them? Or is it
> already solved in newer gcc versions?

I checked this on gcc 4.6, and it still optimizes memcmp/strcmp into a
"repz cmpsb" instruction on x86. This has been known to be a problem
since at least 2002[1][2]. There are also some alternative
implementations available on their mailing list. It seems the main
objection to removing the optimization was that gcc isn't always
compiling against an optimized libc, so they didn't want to drop the
optimization. Beyond that, I think nobody was willing to put in the
effort to change the optimization itself.

[1] http://gcc.gnu.org/ml/gcc/2002-10/msg01616.html
[2] http://gcc.gnu.org/ml/gcc/2003-04/msg00166.html

-- 
Scott Dial
sc...@scottdial.com
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to