* gettimeofday - millisecond accuracy
@ 2008-12-19 4:01 fred
0 siblings, 0 replies; only message in thread
From: fred @ 2008-12-19 4:01 UTC (permalink / raw)
To: cygwin
with my test of gettimeofday in cygwin it appears to be counting in
milliseconds
rather than microseconds.
so I had a look at where it is coded, /winsup/cygwin/times.cc
...
gettimeofday (struct timeval *tv, void *tzvp)
{
struct timezone *tz = (struct timezone *) tzvp;
static bool tzflag;
LONGLONG now = gtod.usecs ();
...
I notice there is
hires_ms NO_COPY gtod;
however lower down there is appears to be a hires_us
class coded.
So I am wondering what the story is behind this ?
I will look at testing some changes here and testing, just need to do a
successful build from source
of as is first.....
I am looking for microsecond resolution, and see that hires_us is using
QueryPerformanceFrequency/QueryPerformanceCounter,
so thats looking good I think?
I have code that does bitbanging to the parallel port, it works
perfectly under linux, and would like
to see it work in cygwin also.
Thanks
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2008-12-19 4:01 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-12-19 4:01 gettimeofday - millisecond accuracy fred
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).