Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Query Performance Timer Problem

Author
Message
Sasuke
20
Years of Service
User Offline
Joined: 2nd Dec 2005
Location: Milton Keynes UK
Posted: 16th May 2010 13:41
Hi guys, I've noticed an issue with Query Performance method of timers on Windows XP and Vista. So far Win 7 doesn't seem to be an issue. Basically the Query Performance Counter loops in a 2-4 second interval, it can also count up and count backwards really quickly then loop again and again. If you check on Google you won't find anything about it so I'm thinking this is a DBP specific issue, an issue reading the DLL maybe. I know you can have problems with the counter jumping with multi-core processors but this ones odd to me.

Anyway, because this problem exists, how could you check for it so I could switch to a different timer method. A 2-4 second test to see if it loops is a bit much, unless it's done in the background. So any ideas on how to detect this problem?

A dream is a fantasy, if you achieve that fantasy it was never a dream to begin with.
KISTech
18
Years of Service
User Offline
Joined: 8th Feb 2008
Location: Aloha, Oregon
Posted: 16th May 2010 19:32
Does this issue effect IanM's HITIMER() function?

IanM
Retired Moderator
23
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 16th May 2010 20:18
No it doesn't, and I'd guess that the problem Sasuke is having is because he's reading the results into an integer or dword variable - he should be reading it into a double integer instead.

Sasuke
20
Years of Service
User Offline
Joined: 2nd Dec 2005
Location: Milton Keynes UK
Posted: 17th May 2010 13:15
Yes it does. If you can remember, I posted a thread called 'Query Performance Counter Returning Odd Value', I even posted code using double integers. You said I should use HITIMER() and funnily enough that looped as well. When I upgraded to Win 7 the issue went away, but when I tested something on my brothers PC using XP sp3 it looped and that was using HITIMER(). Ever it's a really rare bug, it would totally mess up a game.

A dream is a fantasy, if you achieve that fantasy it was never a dream to begin with.

Login to post a reply

Server time is: 2026-07-25 15:30:17
Your offset time is: 2026-07-25 15:30:17