Maximizing PCem performance

Support and general discussion.
Post Reply
ecksemmess
Posts: 183
Joined: Wed 18 Mar, 2015 5:27 am

Maximizing PCem performance

Post by ecksemmess »

I'm trying to wrap my head around which factors are most significant in determining the performance ceiling for PCem on any given host system. I'm fully aware that it's almost 100% about the CPU, and that single-thread performance is the crucial bottleneck there. However, I'm a bit unclear on how the effects of the host CPU's overall single-thread benchmark compare to the effects of other factors such as its clock speed. I realize these things are all correlated to some degree, but not always. For example, if we can take PassMark as a reliable source (I hope?), you can see from looking through their single-thread charts that some CPUs have a higher overall single-thread benchmark even though they have somewhat lower clock speeds. I would tend to assume that the overall single-thread benchmark wins out in such cases - i.e., PCem will have a higher performance ceiling on a 4.5GHz Ryzen than a 5.0GHz i7, if that particular Ryzen has a substantially higher single-thread PassMark score than that particular i7. But is this a faulty conclusion I'm jumping to? It occurs to me that I may be putting too much faith in that one specific benchmark. If that's the case, maybe I should be weighting raw clock speed (or Intel-vs.-AMD, or any number of other factors) more heavily, relative to the single-thread benchmark scores. Does anyone have a clear sense of how much each of these (and other) CPU properties matter relative to each other? If I'm under any misconceptions, I want to clear them up before they lead me down any expensive or time-consuming blind alleys.
User avatar
leilei
Posts: 1039
Joined: Fri 25 Apr, 2014 4:47 pm

Re: Maximizing PCem performance

Post by leilei »

When V17 came out with the official tuned build, I made myself a spreadsheet table of all the CPUs I can benchmark for 100% execution with a Voodoo Banshee using the second (visible) half of MDK2's benchmark and standing in place on Q3DM17. This was enough for my general use cases. (My fastest 100%'s on both games were K6 200, PPro166, PMMX200 and MII 433. They average ~28fps).


Turning down the adapter refresh rate to 60 and turning on vsync should also gain some execution back. V3's defaults with the new PnP monitor stuff can lead into excesses of 85fps+
User avatar
CryptidWorks
Posts: 141
Joined: Fri 26 Apr, 2019 7:11 am

Re: Maximizing PCem performance

Post by CryptidWorks »

It's about experimenting and tuning to figure what CPU you go into most things without noticeable slowdown with.

For me that's so far turned out to be a Pentium MMX 200Mhz on my 3600X that hits 4.1Ghz PBO all core. 233Mhz if I'm not planning on running anything that uses Quicktime that particular session and want to push my luck a little bit.
donkeyulli
Posts: 9
Joined: Sat 19 Jul, 2014 2:11 pm

Re: Maximizing PCem performance

Post by donkeyulli »

Hallo :)

I have found out that you could gain a little more performance out of pcem, if you choose opengl 3.0 renderer and set shader_refresh_rate = 1.000000.

Also I have found out, that the PII 266 Mhz cpu runs smoother on my Computer than the PII 233 MHz emulated CPU. Still not at 100%, but better ...

I hope these tips helps someone :)

Best Regards and thanks for this great emulator to sarah Walker.
menobug
Posts: 16
Joined: Mon 02 Mar, 2015 11:28 pm

Re: Maximizing PCem performance

Post by menobug »

Can someone explain this?

I bought a new gaming PC. I looked out for a CPU with good single thread performance for PCem.

https://www.cpubenchmark.net/singleThread.html

Now I have CPU AMD Ryzen 7 5800X, 48GB RAM, SSD harddrive, RTX 3070. Actually a very good machine.
My highest system I can run emulation speed 100% is PII 333 MHz Voodoo3 3000 which gives 100% emulation speed all the time.

But now the tricky part:
With this machine I can run almost any games including Need for Speed 3 (which looks GREAT) with highest settings 100% emulation speed. Runs so smooth... great.

But for example Microsoft Motocross Madness (with resolution 1280x1024 resolution, this game looks like garbage) only runs 80-90% emulation speed.
I have to go down to a PII-266 to have 100% emulation speed.

So how does a game that looks very good and has nice graphics run at 100% and another game that looks very bad runs at 80%. (Even though my CPU seems to be able to handle the PII-333MHZ)... Is this bad programming by the game developers from the past?


P.S.: @donkeyulli what does shader_refresh_rate = 1.000000. do ?
User avatar
unreal9010
Posts: 160
Joined: Sat 14 Nov, 2020 8:20 pm

Re: Maximizing PCem performance

Post by unreal9010 »

Nice for letting us know about the Ryzen 5800X performance.
Try lowering the resolution to 800x600 and see if there's any difference. Use hardware acceleration if possible.
Some games (regardless of their system requirements) are more problematic than others under PCem. I can run several 1999 games at 100% even on my Core i7 6700 when emulating PII 300, however, when playing the 1995 game The Riddle of Master Lu speed drops down to 80-85% even on Pentium ll 233.
menobug
Posts: 16
Joined: Mon 02 Mar, 2015 11:28 pm

Re: Maximizing PCem performance

Post by menobug »

Thx for the tipp!

Motocross Madness only hit 80% emulation speed with 1280x1024 but now 100% with 1024x768 (like my desktop resolution).
But Midtown Madness also only runs 90-95% with 1024x768, I have to go down to PII-300MHZ for full 100% emulation...

I noticed this same behaviour several times.... My machine seems to run 100% on Windows and quite good looking games and then on others (older, bad looking games) it drops but runs smooth with lower CPUs settings...

I think we have to try out for each game individually which emulated CPU gives the best results :-)
User avatar
unreal9010
Posts: 160
Joined: Sat 14 Nov, 2020 8:20 pm

Re: Maximizing PCem performance

Post by unreal9010 »

Check the number of rendering threads used in Voodoo 3 settings. If there are 4, set them to 2. This might help solve some of the performance issues you're having.
User avatar
unreal9010
Posts: 160
Joined: Sat 14 Nov, 2020 8:20 pm

Re: Maximizing PCem performance

Post by unreal9010 »

If you're willing to test your emulated CPU limits with PCem, try running the following: The Riddle of Master Lu, Stonekeep (demo versions should be enough for testing purposes) and Broken Sword: The Shadow of the Templars installer (game itself should run at 100% on your configuration). For some reason they really hog PCem regardless of which PCem video renderer/settings or BIOS settings I use and the only way for me to get them running at constant 100% is to revert back to P166 MMX.
There are also few titles (namely Daggerfall, Alone in the Dark 3 and Krypton Egg 32) that will hog PCem even when emulating P120, however, on my end they were running at 100% under emulated PII 300 with internal CPU cache being turned off in the emulated machine's BIOS. Immediately after playing these I had to turn the internal CPU cache back on otherwise at least 95% of other games and applications would stutter or run incredibly slow.
A. Naim
Posts: 139
Joined: Thu 09 Jul, 2015 5:06 pm

Re: Maximizing PCem performance

Post by A. Naim »

unreal9010 wrote: Fri 05 Feb, 2021 7:23 am Check the number of rendering threads used in Voodoo 3 settings. If there are 4, set them to 2. This might help solve some of the performance issues you're having.
Specifically, you need at least 5 cores to run the main CPU + Voodoo 3 with 4 rendering threads. Leaving aside the issue of not having one core per thread, which means that at least one core is going to have to do two things at once (and do so much slower);

So, for a six-core (and up) Ryzen CPU prior to the Zen 3/Ryzen 5000 architecture, that means you're going to cross CCX boundaries. Since I have a Ryzen 2700X, that means that using 4 Voodoo rendering threads is slower than using 2 Voodoo rendering threads. If you have a Ryzen 5000-series six core or up, then a single Voodoo 3 with 4 rendering threads will run just fine. 2 SLI Voodoo 3's with 4 rendering threads each (8 total) are going to run on 9 threads, and thus hit CCX boundaries again. I have no test data here, but I would guess that it would probably also slow down.

For an Intel CPU, you just need to worry about having enough cores - and, of course, clocks and IPC. And that's pretty much why, if you're building a PC for the sole purpose of running PCem, Intel is currently the better choice.
User avatar
SarahWalker
Site Admin
Posts: 2054
Joined: Thu 24 Apr, 2014 4:18 pm

Re: Maximizing PCem performance

Post by SarahWalker »

A. Naim wrote: Sat 06 Feb, 2021 12:55 am Specifically, you need at least 5 cores to run the main CPU + Voodoo 3 with 4 rendering threads.
6 - Voodoo cards have a FIFO/setup thread in addition to the rendering threads.
tk421
Posts: 156
Joined: Sat 18 Jun, 2016 6:57 am

Re: Maximizing PCem performance

Post by tk421 »

A. Naim wrote: Sat 06 Feb, 2021 12:55 am
unreal9010 wrote: Fri 05 Feb, 2021 7:23 am Check the number of rendering threads used in Voodoo 3 settings. If there are 4, set them to 2. This might help solve some of the performance issues you're having.
Specifically, you need at least 5 cores to run the main CPU + Voodoo 3 with 4 rendering threads. Leaving aside the issue of not having one core per thread, which means that at least one core is going to have to do two things at once (and do so much slower);

So, for a six-core (and up) Ryzen CPU prior to the Zen 3/Ryzen 5000 architecture, that means you're going to cross CCX boundaries. Since I have a Ryzen 2700X, that means that using 4 Voodoo rendering threads is slower than using 2 Voodoo rendering threads. If you have a Ryzen 5000-series six core or up, then a single Voodoo 3 with 4 rendering threads will run just fine. 2 SLI Voodoo 3's with 4 rendering threads each (8 total) are going to run on 9 threads, and thus hit CCX boundaries again. I have no test data here, but I would guess that it would probably also slow down.

For an Intel CPU, you just need to worry about having enough cores - and, of course, clocks and IPC. And that's pretty much why, if you're building a PC for the sole purpose of running PCem, Intel is currently the better choice.
May I ask if the Voodoo 3 has SLI mode like the Voodoo 2? To my knowledge the V3 has no SLI mode but I could be wrong.

In my experience, a single V3 with 4 render threads provides good solid performance to the point SLI mode would not be needed. Even with the Voodoo 2 emulated machines I have tested, a single V2 provides excellent performance to the point that the V2's SLI mode was not necessary to obtain good performance.

When it comes to maximizing PCem performance, I have found it helps to remember that your CPU is running the whole load for PCem. I try to place maximum focus on the CPU I want to emulate, assigning only as much RAM as the emulated machine needs. I use the Sound Blaster 16 for Win95/98. I keep my virtual hard disks small and as much as possible I only use one per emulated machine. Most of my PCem win98 VMs only use 64mb of RAM and have 2gb hard drives. I have some VMs with just 32mb of RAM, and they run perfectly fine. I let the emulated CPU get most of the CPU load on my PC.

Before v17 of PCem, I used the Pentium MMX for most of my win98 tasks. With v17, much of those tasks are now being done using the Pentium 2 and the V3.
User avatar
leilei
Posts: 1039
Joined: Fri 25 Apr, 2014 4:47 pm

Re: Maximizing PCem performance

Post by leilei »

Banshee and Voodoo3 can't SLI.


SLI would come back for the Voodoo5 later on in the form of having more VSA-100s doing the work on a single card.
A. Naim
Posts: 139
Joined: Thu 09 Jul, 2015 5:06 pm

Re: Maximizing PCem performance

Post by A. Naim »

SarahWalker wrote: Sat 06 Feb, 2021 8:33 am
A. Naim wrote: Sat 06 Feb, 2021 12:55 am Specifically, you need at least 5 cores to run the main CPU + Voodoo 3 with 4 rendering threads.
6 - Voodoo cards have a FIFO/setup thread in addition to the rendering threads.
Thanks, good to know.

And thanks tk421 and leilei; I wasn't aware that the Voodoo 3 doesn't have SLI, and just sort-of assumed from the Voodoo 2.
menobug
Posts: 16
Joined: Mon 02 Mar, 2015 11:28 pm

Re: Maximizing PCem performance

Post by menobug »

Can someone tell me where I can check/select the number of rendering threads in my voodoo3-settings? I have the voodoo3-tray-icon in my Win98 tray area... but where to go from there. (is it even worth it lowering the rendering threads from 4 to 2 with my Ryzen 7 5800X ?)
User avatar
SarahWalker
Site Admin
Posts: 2054
Joined: Thu 24 Apr, 2014 4:18 pm

Re: Maximizing PCem performance

Post by SarahWalker »

In the PCem configuration, in the video pane where you selected Voodoo 3, there is a configure icon next to the graphics card selector.
Post Reply