PDA

View Full Version : CPU load


Anton
March 27th, 2015, 03:46 PM
Hello all,

WinSPWW2 exerts 50% of my CPU power, which is 100% of a core, during any activity in the game including the mere pressing 'R' for rally. Is this intended and expected behaviour and does anybody else observe it on their machines?

Mobhack
March 27th, 2015, 04:48 PM
The original DOS game took 100% of the CPU, all the time, as did the original Windows conversion.

The windows rewrite will give some CPU time to other processes, when idle, but not all. It only does this as a courtesy to other Windows programmes that may be active. However if minimised, then it takes almost no CPU time, as with any other windows programme.

As its a game, it assumes that you are playing it as the primary purpose of running the computer at that time if it is on the screen. When its doing something, it grabs the CPU, and when its "idle" it will still grab it for screen updates several times a second.

Thus the game is not "idle" simply because the end user is not poking keys currently. It will be continuously pumping out screen updates, especially if the game map is visible.

Games are designed differently from office apps. They hog the CPU, unlike word processors etc - But I designed this one to let the office apps get a look in by giving it an OnIdle event;)!

If you really need that CPU time to do something else than play the game - then either shut the game down or minimise it to the task bar.

cheers
Andy

DRG
March 27th, 2015, 05:17 PM
Game CPU load has never been an issue for me even when I was running it with a Pentium III on my old Dell. Even then I could have both games running, Paint Shop Pro running, SHPEdit running, EditPlus running and one or both MOBHacks idling . I don't even think twice about having winSPWW2 and winSPMBT running at the same time

Anton
March 31st, 2015, 05:18 PM
The original DOS game took 100% of the CPU, all the time, as did the original Windows conversion.

MS-DOS is a single-process OS, so any program may be said to possess the CPU, although it may exert only a tiny portion of its calculating power spending most time awaiting user input. Is it in this sense that the DOS version took 100% of the CPU, or did it load the CPU with real calculations to its full capacity?

As its a game, it assumes that you are playing it as the primary purpose of running the computer at that time if it is on the screen.

That I understand. I am a purist in this regard, for I will not have any distractions while playing. Switching away to check e-mail or social networks spoils one's experience and is actually an offense to the game's author. I enjoy winSPWW2 and will never do that.

When its doing something, it grabs the CPU, and when its "idle" it will still grab it for screen updates several times a second.

WinSPWW2 does not strain the CPU much in this "idle" state.

Games are designed differently from office apps. They hog the CPU, unlike word processors etc - But I designed this one to let the office apps get a look in by giving it an OnIdle event;)!

If a game is a first-person shooter with an unlimited FPS it will surely put the hardware to its limits, but I shouldn't expect it of winSPWW2 with its scanty low-FPS (and fixed-FPS) animation. I would know what calculations are taking nearly 100% of CPU time during the processing of so innocent an event as the rally command? Would it not be some dummy load arising from the lack of a delay in the main loop? I will always add a tiny delay to such loops lest they clog the CPU in the absence of actual work:


while true do begin
ProcessEventsIfAny();
Delay(timeUntilNextUpdate);
end;

and perhaps you might do the same in case nobody has subscribed to the OnIdle event...

If you really need that CPU time to do something else than play the game - then either shut the game down or minimise it to the task bar.

I'm worried about the increased wearing of my computer under so high a load in a situation where this load is totally unnecessary and is only a side-effect of the game's architecture. It is not the bare digits in the Task Manager but the actual high power consumption manifested in the whining of the fan.