Re: responsive threading

Andras Balogh <[email protected]> Sun, 31 Jul 2005 13:13:01 -0600
Newsgroups gmane.games.devel.general
Message-ID <[email protected]>
Hmm, but when I don't call into that library, then the CPU usage for my 
rendering thread is below 10%! I would think that if I have a busy loop, 
then the CPU would be at 100%, no?

Anyway, I've tried disabling vsync, and surprisingly, there's not much 
difference (except from the tearing). I have no idea why, because now 
the CPU is really at 100% all the time... Although I have to admit that 
it's a bit hard to see the improvement/worsening, because this is not 
something I can measure, so it's totally subjective, and with the 
tearing on screen it's even harder to tell what's going on.

Just to repeat, these spikes are not too bad, only happens like every 
couple seconds, and only maybe for an eight of a second. I guess if my 
app would run at 10fps constant, you'd never even notice.

Hmm, now I've put in some extra sleeps, just for kicks, and it does feel 
a tiny bit more smooth. But again, it's very subjective :)

BTW: I don't think I've ever seen any app handling this amount of data 
without any hiccups (if you happen to know of one, then please let me 
know!), so I'm pretty pleased with the results already. Of course, if 
it's possible to do better, then I'd love to make it better! :P

As for the unknown variables, and black boxes, I'm afraid there'll 
always be some. The driver and Windows itself are just two examples. And 
as we will develop more and more complex applications, we will have to 
integrate more and more off the shelf solutions into our product. I 
think this is something we just have to learn to deal with. Hmm, this 
reminds me of a library I've seen recently, which, when encounters an 
error, just calls exit(-1)!! ==:-O

cheers,


Andras


Brian Hook wrote:
> On Sun, 31 Jul 2005 19:49:46 -0000, Alen Ladavac wrote:
> 
>>Are you sure that waiting for vsync gives out time? 
> 
> 
> That's what I'm thinking as well -- Andras, maybe disable vsync and 
> see how it performs first.  The problem right now is that you haven't 
> really eliminated enough variables for people to work with.  Disabling 
> vsync is one, and unfortunately the black box nature of the library 
> you're using is another.
> 
> Brian


-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
Gamedevlists-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gamedevlists-general
Archives:
http://sourceforge.net/mailarchive/forum.php?forum_id=557