Red Hat Bugzilla – Bug 109841
Need faster gettimeofday() implementation
Last modified: 2007-11-30 17:06:59 EST
When we (BEA) compare JRockit performance numbers (using SpecJBB2000)
between Windows and RHAS21, JRockit on RHAS21 is about 10% behind (a
bit less on ia32 than on ia64). The main reasons for this are the
implementations of memset() and gettimeofday().
AFAIU, an improved memset() implementation has already gone into RHEL3
(or will be going in RSN). Improvements to gettimeofday() however
isn't scheduled until RHEL4, with the introduction of 2.6 kernels.
We would very much like to see the 2.6 gettimeofday() backported in
the RHEL3 time frame.
1) have you actually measured how "slow" gettimeofday() is ?
2) due to the variety in PC hardware the vsyscall "fast"
gettimeofday() isn't really feasible anymore.
Quoting an internal memo:
> Q1: getimeofday() (system time in mills) is consuming almost 5%
> of extra Kernel CPU cycles.
> On Win64 as well as Linux32, same call is executed in user
> mode and consumes less
> than 0.5 % of CPU cycles. What is the status of fast
> gettimeofday() on Linux64 from Red Hat?
> Fast gettimeofday() has been implemented on linux-ia64.
> But the implementation is based on linux-2.6.
> It'll be a while before RH ships it.
> The current RH distributions are linux-2.4 based.
Sorry about the platform confusion.
fwiw linux on x86 does not execute the gettimeofday() call in userspace!
This is a very old bug, and I'm sure whatever GTOD() there is in RHEL3 today is
staying, so closing this as WONTFIX.