Bug #443

md2, CPU Affinity & FPS (multithread-bug)

Added by zerro_crash about 15 years ago. Updated almost 10 years ago.

Target version:
Start date:
% Done:



Hi )
I have GeForce 7900GS, Athlon X2 4200+ & WinXP x64 Pro, DX9c feb;

There is a problem when using OpenGL renderer (DX somewhy is not working (says sth like '.. creation error'.. dosen't matter).

So as i understand:

You must have computer with several CPUs or dual-core CPU. Launch game (using OpenGL), and enable md2-models (load them, etc). And... i had only 19 fps, even less (about 10(!)) when i had killed thouse 2 first guys in doom2 and other zombies had entered room... it's on 7900GS with specially disabled textures, dyn. light, particles.. everything except models....

So after few minutes i've disided to do:
1. launch snowberry
2. launch doom2
3. during window with log: suspend doomsday.exe process (to have some time..)
4. Task Manager->doomsday process->Set Affinity->SELECT ONLY ONE CPU CORE->ok
5. resume doomsday process

after all this i have had 60 fps with all graph on MAX

so... somewhere there is MT-bug... maybe you can select only one CPU while loading and run all game on it..

Labels: Graphics


#2 Updated by danij about 15 years ago

Logged In: YES
Originator: NO

Yes, we've been aware of this issue for some now. Unfortunately, I've not had time to spend on investigating it yet. Rather than attempt to forcefully set the affinity on load I would prefer to solve the cause if possible.

I now have the requisite hardware to debug with and once 1.9.0-beta6 is released I plan to attempt to find the cause.

#3 Updated by skyjake about 15 years ago

(originally posted by anonymous user)

Logged In: YES
Originator: NO

I don't know the DD sourcecode, but does it use RTDSC to time stuff?
Be aware that AMD Dual Core CPUs cause many problems in games that don't use QueryHighPerformanceCounter() from Windows but rather RTDSC commands, because the Time Stamp Counters are not synchronized between cores.
That for, AMD developed the "AMD Dual Core Optimizer" software, which synchronizes them programmatically. You can download it from their site.
Intel Dual Core processors doesn't suffer from this problem.

#4 Updated by yagisan about 15 years ago

Logged In: YES
Originator: NO

I'm not convinced this is our bug. I rewrote the threading code to use SDL threads, and the only threads other then the main one are for network send/receive - honest - then engine is basically single threaded - that means it can't have thread synchronisation problems. There are TWO things all these reports have in common. Windows and Nvidia drivers. (If someone wants to send me the cash to build a dual core system, I'll gladly test on Linux). I'm looking at the Nvidia driver as the culprit here - perhaps they changed something recently that doesn't like the way we access the video card ?

#5 Updated by wizard76 over 14 years ago

Logged In: YES
Originator: NO

i read in the doomsday hq forums about turning off threaded optimizations on nvidia hardware....worked for me anyhoo

Also available in: Atom PDF