Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Linux Kernel timers subsystems: Precision vs. Resolution

I'm trying to measure the execution time of portions of Linux Kernel code and found that there are two different subsystems for timers. hrtimers stands for high resolution timer while hpet means high precision event timer.

How does resolution differs from precision?

http://www.mjmwired.net/kernel/Documentation/timers/

like image 495
Peter Senna Avatar asked Feb 10 '12 22:02

Peter Senna


1 Answers

HPET refers to a specific piece of x86 PC platform hardware (which Linux does have a driver for). HPET is described in eg this wikipedia artitcle: http://en.wikipedia.org/wiki/High_Precision_Event_Timer

hrtimers are a Linux subsystem that give a general framework for the software abstraction of "high resolution timers". hrtimers are the interface that most generic Linux kernel code should use, while HPET is a hardware feature that the low-level, platform-specific time-keeping code uses.

like image 86
Roland Avatar answered Sep 23 '22 22:09

Roland