Zsnes Priority
Moderator: ZSNES Mods
Zsnes Priority
I've been keeping up with the betas up to the current release. But since 1.40 was released, It seemed like there was a performance hit. I thought it might change in 1.41, it didn't. It still hasn't in 1.42.
I use XP pro. A nifty feature of pro, is when you hit ctrl-alt-del and brings up the task manager, you can pick and choose the CPU priority of whatever program you wish. So I got to looking one day, I saw that Zsnes was set on the lowest priority by default. When I moved it to "normal", the lag dissapeared, which is what I expected. I don't know much about programing, but is there a setting within Zsnes that tells the OS what priority the program should have? It's a simple task for me to fix this, but regular XP users don't have a choice.
I use XP pro. A nifty feature of pro, is when you hit ctrl-alt-del and brings up the task manager, you can pick and choose the CPU priority of whatever program you wish. So I got to looking one day, I saw that Zsnes was set on the lowest priority by default. When I moved it to "normal", the lag dissapeared, which is what I expected. I don't know much about programing, but is there a setting within Zsnes that tells the OS what priority the program should have? It's a simple task for me to fix this, but regular XP users don't have a choice.
Ok, I did more testing. Even when I set Zsnes 1.42's priority to normal, or above normal.... it FORCES itself back down to Low. What's that all about? I discovered this after playing for a few minutes. Everything would be smooth and after I saved or loaded from a savestate, it would return to low priority. I tested it quite a few times. Same results. I think this is a serious bug. Someone on a newer system wouldn't even be phased, but people on a 1ghz, or less, could. 0.o
-
- I know where you live.
- Posts: 148
- Joined: Thu Aug 19, 2004 4:51 am
800 Mhz P3, GeForce 4 Ti4200, WinXP Pro, 256MB RAM.
I cannot duplicate your bug report. ZSNES starts at Normal priority and stays there. Putting it down to Low makes it stay at Low.
I cannot duplicate your bug report. ZSNES starts at Normal priority and stays there. Putting it down to Low makes it stay at Low.
FireKnight:I'm pretty sure a 1KG 24k gold brick costs less than that.
phonymike: well the same amount of raw metals used in a car costs a fraction of the price of a new car idiot. I'm gonna take away your posting privileges and replace them with my balls on your chin.
I smell spray paint.
phonymike: well the same amount of raw metals used in a car costs a fraction of the price of a new car idiot. I'm gonna take away your posting privileges and replace them with my balls on your chin.
I smell spray paint.
-
- ZSNES Shake Shake Prinny
- Posts: 5632
- Joined: Wed Jul 28, 2004 4:15 pm
- Location: PAL50, dood !
If you have other cpu-eating processes, ZSNES might be pushed down as it's not very cpu intensive when running a rom, unless you're using hq4x.
皆黙って俺について来い!!
Pantheon: Gideon Zhi | CaitSith2 | Nach | kode54
Code: Select all
<jmr> bsnes has the most accurate wiki page but it takes forever to load (or something)
-
- ZSNES Developer
- Posts: 6747
- Joined: Tue Dec 28, 2004 6:47 am
To reproduce the "bug", just load up ZSNES (just the GUI, it doesn't matter if a ROM is loaded)... the priority set is Low. When a ROM is loaded (and you are not in the GUI), this changes to Normal.
This is what I think the original poster is somewhat confused about (although, I'm not sure the low priority is intended when only the GUI is loaded).
I don't know what OS the poster is using, this is reproducable in Win2k in any case.
I'm not sure what this "lag" is... if it's GUI lag, this might explain it, but if the emulation is laggy, that would be a different story.
This is what I think the original poster is somewhat confused about (although, I'm not sure the low priority is intended when only the GUI is loaded).
I don't know what OS the poster is using, this is reproducable in Win2k in any case.
I'm not sure what this "lag" is... if it's GUI lag, this might explain it, but if the emulation is laggy, that would be a different story.
-
- Locksmith of Hyrule
- Posts: 3634
- Joined: Sun Aug 08, 2004 7:49 am
- Location: 255.255.255.255
- Contact:
Deathlike2 wrote:I don't know what OS the poster is using, this is reproducable in Win2k in any case.
Kriegan wrote:I use XP pro.
<Nach> so why don't the two of you get your own room and leave us alone with this stupidity of yours?
NSRT here.
NSRT here.
-
- ZSNES Developer
- Posts: 6747
- Joined: Tue Dec 28, 2004 6:47 am
I wouldn't say that with such certainty. The NT kernel makes numerous adjustments, rearrangements, and the like without your consent. It also tends to have insufficient tweaking options (the few that are available are set/disabled in the registry).
If the kernel pages (swaps) without your consent [which it does constantly], delegates which processes get your CPU time, and decides which application deserves the most physical memory (and which get hardly any), it's not very difficult to believe it could change process priorities dynamically as well.
I could be wrong; perhaps ZSNES does explicitly set its priority level now. If so, perhaps that was implemented to reduce CPU usage (remember the 95-100% CPU usage 'bug' with the GUI's infinite loop?).
If the kernel pages (swaps) without your consent [which it does constantly], delegates which processes get your CPU time, and decides which application deserves the most physical memory (and which get hardly any), it's not very difficult to believe it could change process priorities dynamically as well.
I could be wrong; perhaps ZSNES does explicitly set its priority level now. If so, perhaps that was implemented to reduce CPU usage (remember the 95-100% CPU usage 'bug' with the GUI's infinite loop?).
-
- ZSNES Developer
- Posts: 6747
- Joined: Tue Dec 28, 2004 6:47 am
It does work in a sense... it changes the priority when you are running the ROM (normal, high if set in ZSNES's options and low when it is in the GUI)perhaps ZSNES does explicitly set its priority level now.
That bug is still there (I believe it is, because it does show 100% CPU usage when the ZSNES GUI is on)... I only find it strange (unless the devs say otherwise) that the GUI is running at a low priority...If so, perhaps that was implemented to reduce CPU usage (remember the 95-100% CPU usage 'bug' with the GUI's infinite loop?).
-
- ZSNES Developer
- Posts: 6747
- Joined: Tue Dec 28, 2004 6:47 am
Well, this hasn't changed though... at least in the Windows version.Well old versions of ZSNES used to set priority to low while in the GUI and then back to normal when in a game but this code was changed long ago so I don't see what could be changing the priority on ZSNES to low. This one is a mystery to me.