www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/05/16/09:18:16

Message-ID: <373EBC8B.A6271397@enter.net>
Date: Sun, 16 May 1999 08:39:39 -0400
From: Sean <sproctor AT enter DOT net>
X-Mailer: Mozilla 4.51 [en] (Win98; U)
X-Accept-Language: en
MIME-Version: 1.0
Newsgroups: comp.os.msdos.djgpp
Subject: Re: uclock trouble
References: <Pine DOT SUN DOT 3 DOT 91 DOT 990516135445 DOT 26252Y-100000 AT is>
NNTP-Posting-Host: 207.16.153.95
X-Original-NNTP-Posting-Host: 207.16.153.95
X-Trace: 16 May 1999 08:39:09 -0400, 207.16.153.95
Organization: Enter.Net
Lines: 30
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Eli Zaretskii wrote:
> First, please post a short test program that exhibits this behavior.

I had something like:

int t = (int)uclock();
while(t < 0x2000)
{
  printf("%i", t);
  t = (int)uclock();
}

It wasn't anything really, just trying to figure out why other things I
was doing were messing up.  Like why when I time one thing before
another, the first one's always shorter.  And if something is short
enough the time is negative.  Well, I know why now.

> And second, describe the operating system you are running (DOS?
> Windows? which version?).  `uclock' is known to have problems on some
> versions of Windows, but you don't tell enough to decide whether this
> is your problem.

I'm running Windows 98.  The problem is uclock() counts up from 0, after
the first call, to around 0x1200.  I couldn't tell because I don't see
every number it counts, then jumps down to -64000 or so, then counts up
normally from there as far as I can tell.  If you consider a timer
counting up negative numbers normal, then reaches 0 and keeps counting
up like it's supposed to.  I'm running a Pentium-166, if that helps.

Sean

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019