Converting from jiffies to ticks
cswiger at mac.com
Thu Aug 19 19:31:50 UTC 2010
On Aug 19, 2010, at 12:15 PM, Jesse Smith wrote:
> This raises two questions for me:
> 1. Where can I find the equivalent information on FreeBSD? I assume
> there's a function call. Maybe in the kvm_* family? I need to be able to
> get the number of ticks a given PID is using.
Does process accounting described by acct(2) / acct(5) address your requirements?
> 2. Any idea on what the conversion rate between ticks and jiffies is?
> Are they the same thing, but with different names? Or is it a kilometres
> and miles issue?
It depends on what the system interrupt quanta are set to:
In the case of FreeBSD, the standard interrupt rate and the rate which statistical sampling is done are not the same, and the latter is done at "fuzzy" times to prevent bad processes that as trying to cheat and avoid their time being counted....
More information about the freebsd-ports