support for dual processors...


(MuffinMan) #1

i’m trying to compile with my dual amd system using -threads 2 but it seems that q3map2 doesn’t really use both cpu’s it uses exactly 50% processing power, about 10-20% on one cpu and the rest on the other, so it doesn’t really take advantage of the dual system. is it supposed to be able to use it or is -threads the wrong command or something? it even doesn’t generate 2 threads but only one so i guess it’s quite hard anyway for q3map2 to distribute the work…

oh i just recognized that it works but only on the lighting phase, there it generates the second thread as well - this is ok for me as bsp doesn’t take too long…


(BoltyBoy) #2

Can you specify to only use one thread then? So I mean if you want to run applications on one processor while the other does the compile work, would this work? Or is there the problem that the compile will suck up the memory so rendering the computer useless anyway?


(MuffinMan) #3

i can specify a cpu for a certain program/thread so i can for example say that cpu1 should compile while the other is used for normal work, but even when i use both (which i am doing at the moment) i still can even use radiant (but no fluent working), and normal usage is no problem, just a little bit slower when reading the hard disk is involved for example.
there is no problem with ram as it seems that q3map2 doesn’t use all my ram currently with both cpu’s compiling it uses about 200 mb, peak usage was at 404 mb, having 1 gig so that doesn’t bother me…

built this system 2 days ago and it’s my first dual system, still learning what can be done with it but really like it already!


(LodeRunner) #4

You don’t have to specify a -threads argument. On my system, it always detects the SMP and automatically sets 2 threads. (2x Athlon 2000+MP/1gb DDR). Leastwise, I’m pretty sure that q3map2 autodetects SMP ability. If I"m wrong, you can be sure someone will say it right quick.


(MuffinMan) #5

well it doesn’t at my comp and i am quite pleased about that as i can now compile and map at the same time…


(ydnar) #6

Vis and light code is threaded. The BSP phase is a series of gating operations, none of which take that long individually–and all of which are less-than-ideal candidates for parallelization.

The thread imbalance in lighting code is probably due to the way the thread code doles out work. The computation time for each work unit varies widely, because lightmaps & surface sizes vary, as well as the number of lights and occluders affecting each. The latter isn’t known until computation time, so the thread code can’t be affected by it.

y


(SteelRat) #7

An anecdotal note on this since I played with it today:

I tesed compiling on a HP Proliant DL760 server with 8 Intel Xeon HT enabled processors (Hyper Threading).
I set the thread value to 16 and started a compile, both the vis and the light process really utilises the processing power, see the screenshot.
The regular stuff, as Ydnar has mentioned above, only uses 1 cpu.

/SteelRat
www.srcgaming.com


(Hewster) #8

thats interesting, and how many of us are now drooling at the thought of
compiling on such a machine !! lol

Just think light compile time was 2 hours… with this beast 20 min’s :slight_smile:
( the above is a guestimate so no picky comments lol )

Hewster


(michi.be) #9

when i compile on my 3ghz HT cpu with threads=2 its at 100% too.
Its even at 100% then i set threads=1


(LodeRunner) #10

Some people have reported that HT slows down the compile, others that it goes slightly faster. Can anyone produce some definitive results on this?

As far as SMP affecting light compile times…I have a project that was taking about 8 hours to compile on my old PIII800 (oc’d to 964)…on my new box, the Dual Athlon 2000+ MP (1666 MHz), it takes about 40 minutes, and with the newest Q3Map2, about 20. :stuck_out_tongue: Thanks for the performance boosts in newer version Ydnar!


(SteelRat) #11

If I find some time next week I can do some benchmarking, it would be interesting to see.


(rgoer) #12

http://www.quake3world.com/ubb/Forum6/HTML/026693-4.html#136