Keep CE Xcom 1or2 from using too much CPU


  • Please log in to reply
3 replies to this topic

#1 localhosed

localhosed

    Bio-Drones : saying Fus Ro Dah since '95

  • Members
  • PipPipPip
  • 71 posts
  • Gender:Male

Posted 08 July 2012 - 06:16 PM

Collector's edition xcom 1 and 2 seem to use half cpu time on both of my cores, which keeps my system hot for hours on end. This is from a program that can probably run on a 486/66 mhz (~0.066 ghz) . The best program I have found so far to limit cpu and have the game run well is
Battle Encoder Shirase : http://mion.faireal.net/BES/

..In combination with UFOExtender or TFTDExtender to limit framerate (see INI file) can help throttle speed of certain animations too, like tile animations in tactical (arrow above selected unit's head is one gauge to use , or sonar computer animation in the Triton) and menu animations in geoscape. Framerate modding change to the Extender(s) was done by Seb76 some time ago.

Here are the instructions and settings I use  :
Set Extender framerates, If you use split exectuables (from Xcomutil or BB's combomod) it can be more helpful, since tactical can use lower framerate than geoscape, since it seems to benefit from it more.
Click watch and point BES to your executable and then run the game, or run the game first and click target and find it there. The tray icon will turn red if BES is limiting the speed of the program. Then click the big 'control' button once the program is being limited.
Settings depend on the speed of your system so you will probably need adjusting but this could give you something to start with :

Speed 90% (less)
Sleep/awake : 18 milliseconds or less . 16ms equates to about 60 'fps' . But this setting controls frequency of wrangling the targeted program by BES, not FPS of it. This setting is mostly important to keep audio from stuttering on my PC. Smooths animations also.
That's on a ~3ghz desktop. So if you use a laptop or more mobile device you won't need as much slowing but also will get much finer control.

And there, for me the game uses about 8 to 18% CPU on both cores (setting affinity to one core might help even more, now that I think of it) instead of 50% on each core (also 50% total). That's a ton of unnecessary processing.

Edit: After more testing, it seems like Fullscreen mode with TFTDExtender needs more frequent updates to run as smoothly as windowed mode. Now I'm using 10ms updates with a similar amount of slowdown.

But wait, there's more!
That's right, you can get even finer control of cpu usage by setting your executable to use only one core with the 'imagecfg' utility. : http://www.robpol86....ex.php/ImageCFG

I use "imagecfg -u [your xcom CE executable]" at the command line. Now BES works better and the program only runs on one core. There are more options with imagecfg also.

Also remember that there are in-game speed settings in tactical (? button ) that can help after these other adjustments too.

May your plasma and sonic bursty blobs fly slow enough to be noticed.

#2 Bomb Bloke

Bomb Bloke

    The Smily Admin

  • Admin
  • PipPipPipPipPip
  • 4,625 posts
  • Gender:Male
  • Location:Tasmania (AU)

Posted 09 July 2012 - 07:46 AM

I must confess I'm a little confused as to how they could make use of two cores to start with. Hyperthreading or something?  :eh:
BB's X-Com Projects Page - X-Com Games At GamersGate
You're just jealous 'cause the voices only talk to me :P
We love Tammy! :)

#3 silencer_pl

silencer_pl

    Captain

  • Members
  • PipPipPipPipPip
  • 4,405 posts
  • Gender:Male
  • Location:Poland

Posted 09 July 2012 - 08:05 AM

Hyperthreading is limited to only few CPUs. Old Pentium 4s and the newest i7's and higher so I doubt that would be the case.
Posted ImagePosted ImagePosted Image

#4 localhosed

localhosed

    Bio-Drones : saying Fus Ro Dah since '95

  • Members
  • PipPipPip
  • 71 posts
  • Gender:Male

Posted 09 July 2012 - 08:39 AM

If i remember correctly, the program isn't really using multiple cores as normally expected. It's some side effect of the move from the only single core aware windows versions and the multi core aware versions. Something like that.
I would have liked if windows somehow detected old single core native programs and ran them that way, but it doesnt work that way,  Older programs seem to make use of both cores but I think they really just run the same data simultaneously on both cores, redundantly.

I could be wrong about the last part. I don't know the specifics, whether it involves certain runtime libraries also, or works very differently on some processors, I haven't seen a difference with these particular programs since I bought my first multi core athlon 64 a long time ago.

Now i'm using a core 2 duo so I don't think newer hardware solved these less common game problems...the core-I series is newer but somehow I doubt there is any difference. It's funny that you mention core I's having hyperthreading, I don't think my core 2 duo has hyperthreading. I don't know much about it, somehow i doubt it would help, but would be interested to know if anyone using hyperthreading notices any different behavior with CE xcom.
Old efficient xcom making a 3.0ghz processor sweat? Boggled my mind.

Edit : but by just observing the game running full hyper-blast and running with BES restricting it very much, I can tell that CE xcom is using cpu cycles while apparently doing nothing noticeable. In tactical for me, wih framerate 15, and no BES, it looks similar, but faster,  to BES at 90% ( This gives CE around 10% CPU time, and BES is working normally, but CE is doing so much of nearly-nothing it is sometimes hard to notice). "YMMV" ...
I havent looked into it (not that I could) but I imagine that seb76's framerate limiter somehow just throttles some framebuffery-ish vsync-ey direct3d/directx mechanism and doesn't change the normal speed of any non fullscreen-copy-type graphic related function, animation timing, that sort of thing, all controlled by CPU. It certainly helps though somehow, maybe with voodoo magic and the help of greek gods.
A thousand bio-drones bumping into wireless keyboards with visual studio for a thousand years will eventually solve all program bugs.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users