Re: [LAD] [Jack-Devel] How is the TSC calibration accuracy on dual core 2 computers? (And what about HPET?)

From: Jussi Laako <jussi@email-addr-hidden>
Date: Tue Apr 28 2009 - 23:09:48 EEST

Kjetil S. Matheussen wrote:
>
> I've looked at the HPET code in jack, but am unsure how accurate it is,
> and whether there are any overhead using it?

Resolution on my machine is 1 / 14.318180 MHz. Frequency can vary
typically from 12 to 16 MHz. Access is usually rather fast through MMIO.
Accuracy can vary depending on hardware and environment, same applies
even more for TSC.

> that's the accuracy of usleep(). So it looks promising, but
> I need at least 0.1ms accuracy...

In my opinion, clock_gettime() with CLOCK_MONOTONIC is pretty good if
kernel is using reasonably good clock source. You can check the current
one by "cat
/sys/devices/system/clocksource/clocksource0/current_clocksource". Over
rather long periods, CLOCK_REALTIME with good NTP sync would probably be
a good choice.

Over what time span you would need that 0.1 ms accuracy?

        - Jussi
_______________________________________________
Linux-audio-dev mailing list
Linux-audio-dev@email-addr-hidden
http://lists.linuxaudio.org/mailman/listinfo/linux-audio-dev
Received on Wed Apr 29 00:15:02 2009

This archive was generated by hypermail 2.1.8 : Wed Apr 29 2009 - 00:15:02 EEST