Messages in this thread | | | Date | Fri, 12 Nov 2004 07:04:14 +0100 | From | Willy Tarreau <> | Subject | Re: CONFIG_X86_PM_TIMER is slow |
| |
Hi,
On Thu, Nov 11, 2004 at 09:52:27PM -0800, dean gaudet wrote: > when using CONFIG_X86_PM_TIMER i'm finding that gettimeofday() calls take > 2.8us on a p-m 1.4GHz box... which is an order of magnitude slower than > TSC-based solutions. > > on one workload i'm seeing a 7% perf improvement by booting "acpi=off" to > force it to use tsc instead of the PM timer... (the workload calls > gettimeofday too frequently, but i can't change that).
I did not test, this might be interesting. In fact, what would be very good would be sort of a new select/poll/epoll syscalls with an additional argument, which would point to a structure that the syscall would fill in return with the time of day. This would greatly reduce the number of calls to gettimeofday() in some programs, and make use of the time that was used by the syscall itself.
For example, if I could call it like this, it would be really cool :
ret = select_absdate(&in, &out, &excp, &date_timeout, &return_date);
with <date_timeout> the date at which to timeout (instead of the number of microseconds) and <return_date> the current date upon return.
Cheers, Willy
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |