[issue1040026] os.times() is bogus
Alexander Belopolsky
report at bugs.python.org
Sun Feb 24 20:07:34 CET 2008
Alexander Belopolsky added the comment:
> You complained in msg62869 about the original patch that calling
sysconf
> on every call leads to an unacceptable slowdown. Your one-line patch
> calls sysconf five times on each call when HZ is not defined.
That's why I said that was a matter of personal preference. I use 3
different systems: i386 linux, x86_64 linux and Mac OS X and the last is
not mission critical. On i386 linux HZ is already defined as sysconf
call, on x86_64 HZ is defined as 100 and it happens to be the correct
value. On MacOS X, HZ is not defined, and os.times exhibits the bug.
One-line patch will make MacOS X behave the same as i386 Linux, which is
fine for me, but I will oppose any changes that affect x86_64 linux
performance.
Does anyone know of a platform where HZ is defined to a wrong value? WE
may want to undef or redefine HZ on such platforms.
_____________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1040026>
_____________________________________
More information about the Python-bugs-list
mailing list