getnanotime man page on DragonFly

Man page or keyword search:  
man Server   44335 pages
apropos Keyword Search (all sections)
Output format
DragonFly logo
[printable version]

MICROTIME(9)		 BSD Kernel Developer's Manual		  MICROTIME(9)

NAME
     microtime, getmicrotime, nanotime, getnanotime — get the current time

SYNOPSIS
     #include <sys/time.h>

     void
     microtime(struct timeval *tv);

     void
     getmicrotime(struct timeval *tv);

     void
     nanotime(struct timespec *ts);

     void
     getnanotime(struct timespec *tsp);

DESCRIPTION
     The microtime() and getmicrotime() functions stores the system time as a
     struct timeval at the address specified by tv.  The nanotime() and
     getnanotime() functions perform the same utility, but record the time as
     a struct timespec instead.

     Microtime() and nanotime() always query the timecounter to return the
     current time as precisely as possible.  Whereas getmicrotime() and
     getnanotime() functions are abstractions which can alternately return a
     less precise, but faster to obtain, time.	This behaviour can be toggled
     via the kern.timecounter.method sysctl variable:

     0	  sacrifice precision in favor of faster code execution

     1	  return the more precise time (the same as calling microtime() or
	  nanotime()).

     The intent of the getmicrotime() and getnanotime() functions is to
     enforce the user's preference for timer accuracy versus execution time.

DIAGNOSTICS
     Buggy hardware can cause "calcru negative..." when kern.time‐
     counter.method is set to 0.

SEE ALSO
     getmicrouptime(9), getnanouptime(9), microuptime(9), nanouptime(9),
     tvtohz(9)

HISTORY
     The microtime and nanotime functions first appeared in FreeBSD 3.0 but
     existed in other incarnations since 4.4BSD

AUTHORS
     This manual page was written by Kelly Yancey ⟨kbyanc@posi.net⟩.

BSD				January 3, 2000				   BSD
[top]

List of man pages available for DragonFly

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net