You are not logged in.

#1 2008-02-09 17:24:56

Bestiapeluda
Member
From: Buenos Aires, Argentina
Registered: 2007-10-16
Posts: 181

Making a game to run exclusively in a specific core of my cpu

I play wow using wine, and i wonder if it is possible to make wine and wow
to run exclusively on a core, while the rest run on the other.

Offline

#2 2008-02-09 17:44:32

buttons
Member
From: NJ, USA
Registered: 2007-08-04
Posts: 620

Re: Making a game to run exclusively in a specific core of my cpu

Well, I can answer the first part of your question...

pacman -S schedtool

env WINEDEBUG=-all schedtool -a 1 -e wine "foo.exe"

Obviously the important bit here is the "schedtool -a 1 -e" part, which says "execute the following on core 1."  Note that, in your case, the two cores are named 0 and 1, respectively.

As for the other part of your question, "the rest" isn't exactly descriptive, though I'm not sure it matters.  It's up to the SMP scheduler in the kernel to decide which core a given process runs on, and while I'd like to think it's smart enough to move other computationally-intensive processes to the unused core, you don't have any control over this, anyway.

In general, though, this scheduler is pretty smart, and you should let it do what it thinks is correct, unless your program will absolutely not work on multiple cores.


Cthulhu For President!

Offline

#3 2008-02-09 19:37:41

Bestiapeluda
Member
From: Buenos Aires, Argentina
Registered: 2007-10-16
Posts: 181

Re: Making a game to run exclusively in a specific core of my cpu

thanks buttons

Offline

Board footer

Powered by FluxBB