l i n u x - u s e r s - g r o u p - o f - d a v i s
L U G O D
 
Next Meeting:
August 5: Social gathering
Next Installfest:
TBD
Latest News:
Jul. 4: July, August and September: Security, Photography and Programming for Kids
Page last updated:
2004 Jun 24 02:59

The following is an archive of a post made to our 'vox-tech mailing list' by one of its subscribers.

Report this post as spam:

(Enter your email address)
Re: [vox-tech] Easiest way to calculate date in 100 ns increments?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [vox-tech] Easiest way to calculate date in 100 ns increments?



Quoting Mark K. Kim (lugod@cbreak.org):

> Having said that, `date` is a nice tool for converting from human readable
> format to hour/minute/sec/nanosec if you're scripting, and the source is
> freely available if you're using C!

Most likely, the results wouldn't be meaningful since the querent is
looking for 100 ns resolution.  I believe that date uses gettimeofday,
which is at best accurate to about two microseconds.  It'd be a
challenge to converge in 100 ns accuracy with a suitable algorithm --
under rather rare conditions, I would think.  I used to know how to do
this, but that would have been in structured Fortran.  ;->  [1]

If you need 100 ns resolution, therefore, it's better to use something
like Robert G. Brown's nanotimer utility, which reads and uses
information from the on-board cycle counter accessible on pretty much
all modern CPUs.  See:

http://www.beowulf.org/pipermail/beowulf/2004-January/009028.html

[1] No, that language is not dead; it just smells that way.  Quit
sniggering, sonny, or I'll whack you with my cane.

-- 
Cheers,        "A raccoon tangled with a 23,000 volt line, today.  The results
Rick Moen       blacked out 1400 homes and, of course, one raccoon."
rick@linuxmafia.com                                  -- Steel City News
_______________________________________________
vox-tech mailing list
vox-tech@lists.lugod.org
http://lists.lugod.org/mailman/listinfo/vox-tech



LinkedIn
LUGOD Group on LinkedIn
Sign up for LUGOD event announcements
Your email address:
facebook
LUGOD Group on Facebook
'Like' LUGOD on Facebook:

Hosting provided by:
Sunset Systems
Sunset Systems offers preconfigured Linux systems, remote system administration and custom software development.

LUGOD: Linux Users' Group of Davis
PO Box 2082, Davis, CA 95617
Contact Us

LUGOD is a 501(c)7 non-profit organization
based in Davis, California
and serving the Sacramento area.
"Linux" is a trademark of Linus Torvalds.

Sponsored in part by:
EDGE Tech Corp.
For donating some give-aways for our meetings.