EQ2 Forum Archive @ EQ2Wire

EQ2 Forum Archive @ EQ2Wire (https://archive.eq2wire.com//index.php)
-   General Gameplay Discussion (https://archive.eq2wire.com//forumdisplay.php?f=2586)
-   -   Please allow us to set our own CPU affinity when running EQ2(s) (https://archive.eq2wire.com//showthread.php?t=522102)

Wizardlord 09-09-2012 10:57 PM

<p>Hello, it would be very cool if you were able to let us set our own CPU affinity when running multiple EQ2's, it seems that when im running my normal ammount while boxing (4 Clients of eq2) it always seems to go core 24 (2 and 4), it would be nice it eq2 didnt reset my affinity options in tskmgr.exe every 30seconds or so. at the moment im having to use a program i wrote in c++ to lock the afinity down so it doesnt keep changing.</p><p>just some info:</p><p>1 EQ2 with my cpu locker off = 65fps (116 while in my house)*</p><p>1 EQ2 with my cpu locker on = 135fps (209 while in my house)*</p><p>4 EQ2's with cpu locker off = 42fps (68 while in my house)*</p><p>4 EQ2's with cpu locker on = 74fps (101 while in my house)*</p><p>* = these are just avarage numbers i got on a few tests</p><p>so is it possible for you to make EQ2 so it doesnt lock cpu affinity automatticly to the same 2 cores for every client running?</p><p>thanks</p>

Regolas 09-09-2012 11:55 PM

Ponzo, What are your specs of your computer? I'm running a dated machine now (cpu e5700, gpu 4870, 4gb ram), that runs one client fine but struggles with 2 or more. I'm interested to see if I can get better fps on 2 clients. I'm not that computer savvy but I'm going to research what you've done to see if I can improve my boxing performance.

Avianna 09-10-2012 12:33 AM

<p><cite>[email protected] wrote:</cite></p><blockquote><p>Hello, it would be very cool if you were able to let us set our own CPU affinity when running multiple EQ2's, it seems that when im running my normal ammount while boxing (4 Clients of eq2) it always seems to go core 24 (2 and 4), it would be nice it eq2 didnt reset my affinity options in tskmgr.exe every 30seconds or so. <span style="color: #ff0000;">at the moment im having to use a program i wrote in c++ to lock the afinity down so it doesnt keep changing.</span></p><p>just some info:</p><p>1 EQ2 with my cpu locker off = 65fps (116 while in my house)*</p><p><span style="color: #ff0000;">1 EQ2 with my cpu locker on = 135fps (209 while in my house)*</span></p><p>4 EQ2's with cpu locker off = 42fps (68 while in my house)*</p><p>4 EQ2's with cpu locker on = 74fps (101 while in my house)*</p><p>* = these are just avarage numbers i got on a few tests</p><p>so is it possible for you to make EQ2 so it doesnt lock cpu affinity automatticly to the same 2 cores for every client running?</p><p>thanks</p></blockquote><p>Heck, I would love if you could share this cpu locker with the community, my frame rates are horrid on this old laptop usually around 20 or so... any boost to FPS would be greatly appreciated.</p><p>Please and thank you,</p><p>~Avianna</p>

Deago 09-10-2012 12:57 AM

<p>Remember eq2 was engineered for single-core.  At the OS level.....nevermind carry on I am just feeling lazy but in short its 'intended.'   Cache be the word.</p><p>What OS are you using?</p><p>Remember a project during grad school involving beowulf clusters and this topic reminded me of how nifty it would be to run something old like eq2 across a few old pentium 4's  <img src="/eq2/images/smilies/283a16da79f3aa23fe1025c96295f04f.gif" border="0" />  Not exactly ideal..but funny.</p>

kdmorse 09-10-2012 01:25 AM

<p>Random note:</p><p>If you're running Vista or Windows 7, and *not* running the client as admin, it acts extra dumb in this regard.  You will get better behavior running as admin.</p><p>The client is only kinda dumb normally.  It actually notes whether it is the first, second, third instance, etc...  And tries to lock itself to different CPU's to prevent exactly this issue.  (Although it doesn't do a very good job).</p><p>But if the client is not running as admin, it cannot see those other instances.  So it thinks it's the first client, all four clients think they're the first client, and all lock themselves to the same CPU.</p><p>So in the simplest case where you're multi-clienting, and you start the executables manually, make sure you're starting them as admin and it might help.  (It also might not, as I said, it's not very good about getting out of it's own way, but it does try)</p><p>But, an external app to do CPU affinity locking to exactly the cores you want, and keep it there, is always better.</p><p>Also - if you only give the client 1 CPU, turn off multi-processor support in the game.  If MP support is turned on in the game, it tries to use two processors (one at 100%, one at 15-25%). If it thinks it can do that, but you pin both the main game thread, and it's auxiliary threads to just one CPU, it actually hurts itself - you get a better framerate with client MP support disabled in that situation.</p>

Wizardlord 09-10-2012 01:48 AM

<p>Currently im using Windows 7, Intel I3 Quad Core (3.70ghrtz), ATI Radeon 5650 (1gb, DDR3) and 528gb hard drive, I use duel moniter to (1920x1080). it was a univerisity supplied PC, but it does pretty good, and with a few tweaks im able to do quite alot. i also run a few other porgrams for clearing ram and stopping pretty much any process that isnt required to keep windows/pc running smoothly</p><p>PS: yes i could give the program i wrote to give you much better FPS, but it still needs a few fixes to make it run 100% hehe, at the moment, im changing the cpu affinity and a few other settings after eq2 reverts them back. i need to change that to intercept EQ2 trying to revert them which at the moment is creating a tiny bit of lag about every 2-3minutes (only about a drop of 10-12fps for 4 seconds - but i can fix that)</p>

Deago 09-10-2012 02:08 AM

<p><cite>[email protected] wrote:</cite></p><blockquote><p>Currently im using Windows 7, Intel I3 Quad Core (3.70ghrtz), ATI Radeon 5650 (1gb, DDR3) and 528gb hard drive, I use duel moniter to (1920x1080). it was a univerisity supplied PC, but it does pretty good, and with a few tweaks im able to do quite alot. i also run a few other porgrams for clearing ram and stopping pretty much any process that isnt required to keep windows/pc running smoothly</p><p>PS: yes i could give the program i wrote to give you much better FPS, but it still needs a few fixes to make it run 100% hehe, at the moment, im changing the cpu affinity and a few other settings after eq2 reverts them back. i need to change that to intercept EQ2 trying to revert them which at the moment is creating a tiny bit of lag about every 2-3minutes (only about a drop of 10-12fps for 4 seconds - but i can fix that)</p></blockquote><p>i3 quad core?  ....maybe im just tired but I thought quad started with certain models in the i5 line?</p><p>anyway as stated by Ynn... its all about the OS </p>

Wizardlord 09-10-2012 03:02 AM

<p><cite>Deago wrote:</cite></p><blockquote><p><cite>[email protected] wrote:</cite></p><blockquote><p>Currently im using Windows 7, Intel I3 Quad Core (3.70ghrtz), ATI Radeon 5650 (1gb, DDR3) and 528gb hard drive, I use duel moniter to (1920x1080). it was a univerisity supplied PC, but it does pretty good, and with a few tweaks im able to do quite alot. i also run a few other porgrams for clearing ram and stopping pretty much any process that isnt required to keep windows/pc running smoothly</p><p>PS: yes i could give the program i wrote to give you much better FPS, but it still needs a few fixes to make it run 100% hehe, at the moment, im changing the cpu affinity and a few other settings after eq2 reverts them back. i need to change that to intercept EQ2 trying to revert them which at the moment is creating a tiny bit of lag about every 2-3minutes (only about a drop of 10-12fps for 4 seconds - but i can fix that)</p></blockquote><p>i3 quad core?  ....maybe im just tired but I thought quad started with certain models in the i5 line?</p><p>anyway as stated by Ynn... its all about the OS </p></blockquote><p>Yeah I3 does have quad core hehem but yeah i saw Ynn's post, il ahve a look into that later</p>

Deago 09-10-2012 03:41 AM

<p>I see what you did there <img src="/eq2/images/smilies/49869fe8223507d7223db3451e5321aa.gif" border="0" /></p>

Halo of G4 09-10-2012 04:19 AM

<p>One of my favorite past times in EQ2 global chat is to ruin someones parade by informing that their brag rights of duo 690 Nvidia is all for nothing because of how EQ2 was designed around single CPU. Oh how their cookies crumble.</p>

Wingrider01 09-10-2012 08:21 AM

<p><cite>Halo of G4 wrote:</cite></p><blockquote><p>One of my favorite past times in EQ2 global chat is to ruin someones parade by informing that their brag rights of duo 690 Nvidia is all for nothing because of how EQ2 was designed around single CPU. Oh how their cookies crumble.</p></blockquote><p>run a Quad SLI of 690's in a ASUS P8Z77-V, Core I7 3770K 3.5GHZ process. Even in raid the game runs fine with everything on ultra and just shadows (I detest them) and flora (play short races and hate not being able to see over the flora) turned off, but then the multiple 690's where purchased for another reason, they just happen to be installed in the machine I use to multi-box eq2, the game is just oh by the way I play it on this machine also</p>

Gilasil 09-10-2012 01:54 PM

<p>Every time I see threads like this I'd like to know how much performance boost EQ2 gets by setting the affinity at all.  I'd hope it was pretty significant or it makes no sense as threads like this attest.</p><p>I usually avoid setting CPU affinity on client side apps (yes, multithreaded apps) since you don't really know the environment your app will be running in and it's easy to really mess things up.  As this demonstrates.  There would have to be a VERY good reason to do so.  On server side it makes more sense since you typically have a lot more control over how it'll be run.</p>

Ulrichvon 09-10-2012 02:53 PM

<p><cite>Gilasil wrote:</cite></p><blockquote><p>Every time I see threads like this I'd like to know how much performance boost EQ2 gets by setting the affinity at all.  I'd hope it was pretty significant or it makes no sense as threads like this attest.</p><p>I usually avoid setting CPU affinity on client side apps (yes, multithreaded apps) since you don't really know the environment your app will be running in and it's easy to really mess things up.  As this demonstrates.  There would have to be a VERY good reason to do so.  On server side it makes more sense since you typically have a lot more control over how it'll be run.</p></blockquote><p>Very significant.</p><p>Getting EQ2 to run on cores that will 'turbo' their clockrate is really important.  Unfortunately by default the client chooses cores that are almost certain to prevent the feature.</p><p>There have been other recent threads detailing this issue as well.</p>

Wingrider01 09-10-2012 03:24 PM

<p><cite>Ulrichvon wrote:</cite></p><blockquote><p><cite>Gilasil wrote:</cite></p><blockquote><p>Every time I see threads like this I'd like to know how much performance boost EQ2 gets by setting the affinity at all.  I'd hope it was pretty significant or it makes no sense as threads like this attest.</p><p>I usually avoid setting CPU affinity on client side apps (yes, multithreaded apps) since you don't really know the environment your app will be running in and it's easy to really mess things up.  As this demonstrates.  There would have to be a VERY good reason to do so.  On server side it makes more sense since you typically have a lot more control over how it'll be run.</p></blockquote><p>Very significant.</p><p>Getting EQ2 to run on cores that will 'turbo' their clockrate is really important.  Unfortunately by default the client chooses cores that are almost certain to prevent the feature.</p><p>There have been other recent threads detailing this issue as well.</p></blockquote><p>Is Very significant backed by controlled testing or just by the TSMB method? Would love to see the comparision graphs and data points</p>

Ulrichvon 09-10-2012 04:59 PM

<p><cite>Wingrider01 wrote:</cite></p><blockquote><p>Is Very significant backed by controlled testing or just by the TSMB method? Would love to see the comparision graphs and data points</p></blockquote><p>That would depend explicitly on your cpu and the turbocore settings associated with it.</p><p>For my machine, when forced to a 'sane' affinity setting, eq2 benefits from another 500mhz of processing power, which equates to about 13 extra FPS while raiding with my client settings.</p><p>The difference between 7-8 FPS when locked to core 6, and 19-23 FPS when locked to core 2, is huge IMO.</p><p>Now if the turbocore jump on your rig is less, the difference would be less.</p><p>All in all, SOE doesn't need to do anything with this change OTHER than remove their over-riding of OS and USER affinity settings.  Over-riding the system and the user is a bad idea to start with and should have never been done that way in the first place.</p><p>A few of us tried to get SoE to understand that back when this change was made, but they wouldn't listen then either.  Now with these newer 'turbo core' CPU's the issue is a larger concern and affects people other than just multi-boxers.</p>

Wingrider01 09-10-2012 06:14 PM

<p><cite>Ulrichvon wrote:</cite></p><blockquote><p><cite>Wingrider01 wrote:</cite></p><blockquote><p>Is Very significant backed by controlled testing or just by the TSMB method? Would love to see the comparision graphs and data points</p></blockquote><p>That would depend explicitly on your cpu and the turbocore settings associated with it.</p><p>For my machine, when forced to a 'sane' affinity setting, eq2 benefits from another 500mhz of processing power, which equates to about 13 extra FPS while raiding with my client settings.</p><p>The difference between 7-8 FPS when locked to core 6, and 19-23 FPS when locked to core 2, is huge IMO.</p><p>Now if the turbocore jump on your rig is less, the difference would be less.</p><p>All in all, SOE doesn't need to do anything with this change OTHER than remove their over-riding of OS and USER affinity settings.  Over-riding the system and the user is a bad idea to start with and should have never been done that way in the first place.</p><p>A few of us tried to get SoE to understand that back when this change was made, but they wouldn't listen then either.  Now with these newer 'turbo core' CPU's the issue is a larger concern and affects people other than just multi-boxers.</p></blockquote><p>running a Core I7 3770K 3.5GHZ</p><p>still want to see the data points that you was using to justify the statement, will take them from you configuration. No offense but I take no performence comment at face value unless it is proven - my programmers know this already and will not make statements they do not have the data points to back it up withh</p>

Deago 09-11-2012 05:57 PM

<p><cite>Wingrider01 wrote:</cite></p><blockquote><p><cite>Ulrichvon wrote:</cite></p><blockquote><p><cite>Wingrider01 wrote:</cite></p><blockquote><p>Is Very significant backed by controlled testing or just by the TSMB method? Would love to see the comparision graphs and data points</p></blockquote><p>That would depend explicitly on your cpu and the turbocore settings associated with it.</p><p>For my machine, when forced to a 'sane' affinity setting, eq2 benefits from another 500mhz of processing power, which equates to about 13 extra FPS while raiding with my client settings.</p><p>The difference between 7-8 FPS when locked to core 6, and 19-23 FPS when locked to core 2, is huge IMO.</p><p>Now if the turbocore jump on your rig is less, the difference would be less.</p><p>All in all, SOE doesn't need to do anything with this change OTHER than remove their over-riding of OS and USER affinity settings.  Over-riding the system and the user is a bad idea to start with and should have never been done that way in the first place.</p><p>A few of us tried to get SoE to understand that back when this change was made, but they wouldn't listen then either.  Now with these newer 'turbo core' CPU's the issue is a larger concern and affects people other than just multi-boxers.</p></blockquote><p>running a Core I7 3770K 3.5GHZ</p><p>still want to see the data points that you was using to justify the statement, will take them from you configuration. No offense but I take no performence comment at face value unless it is proven - my programmers know this already and will not make statements they do not have the data points to back it up withh</p></blockquote><p>As a software engineer Wing made me lol because I can relate to his feelings on the matter.</p><p>I will say that 90% of the time the OS is smarter with affinity.  So I agree with wing that data would need to be summoned for it to be taken seriously. </p>

Ulrichvon 09-11-2012 06:51 PM

<p><cite>Deago wrote:</cite></p><blockquote><p>I will say that 90% of the time the <strong><em>OS is smarter with affinity</em></strong>.  So I agree with wing that data would need to be summoned for it to be taken seriously. </p></blockquote><p>YES!  It is!</p><p>Do you realize the EQ2 client overrides the OS affinity and sets its own, and thats why the thread is here?</p>

Deago 09-11-2012 06:57 PM

<p>Indeed.  I do ask ....why?  Perhaps a red name might answer because until then I will assume it is known and intended by the developers. </p>

Wingrider01 09-11-2012 08:09 PM

<p><cite>Ulrichvon wrote:</cite></p><blockquote><p><cite>Deago wrote:</cite></p><blockquote><p>I will say that 90% of the time the <strong><em>OS is smarter with affinity</em></strong>.  So I agree with wing that data would need to be summoned for it to be taken seriously. </p></blockquote><p>YES!  It is!</p><p>Do you realize the EQ2 client overrides the OS affinity and sets its own, and thats why the thread is here?</p></blockquote><p>really? got the documentation to back up your statement? Sorry, need concrete proof on a statement before I will accept it. This is the point I am making - it is just a statement unless there is documentation and data points to validate the statement.</p><p>Unlike deago I require my people to prove a statement before I agree with what they say and allow it to be worked on</p>

Deago 09-11-2012 08:57 PM

<p>This is entertaining <img src="/smilies/283a16da79f3aa23fe1025c96295f04f.gif" border="0" alt="SMILEY" /></p>

kdmorse 09-11-2012 09:48 PM

<p><cite>Wingrider01 wrote:</cite></p><blockquote><p><cite>Ulrichvon wrote:</cite></p><blockquote><p>Do you realize the EQ2 client overrides the OS affinity and sets its own, and thats why the thread is here?</p></blockquote><p>really? got the documentation to back up your statement? Sorry, need concrete proof on a statement before I will accept it. This is the point I am making - it is just a statement unless there is documentation and data points to validate the statement.</p><p>Unlike deago I require my people to prove a statement before I agree with what they say and allow it to be worked on</p></blockquote><p>Err, exactly what point are you disbelieving?  If it's the relative performance of various affinity configurations, fair enough.</p><p>But you seem to be disputing the fact that EQ2 hardcodes it's own affinity settings, and that's not even in question here.  It does it.  We can see it do it - we wish it would stop.  It's why this thread exists.  We can watch it override our settings as 'it knows best'.  Devs have confirmed repeatedly that it does it intentionally, and explained the intent. We can trace the api calls to SetProcessAffinityMask and SetThreadAffinityMask coming from the client.  And the end result is unmistakable, it picks a core, and locks the main thread itself there. </p><p>And when we fire four clients up, and they all lock their main thread to the same core, cutting each clients framerate to 1/4th of normal....   We want to slap someone with a fish...</p>

Deago 09-11-2012 09:55 PM

<p>What did the dev's say was the main reasoning for dynamic affinity?  (sounds like a romance novel <img src="/eq2/images/smilies/283a16da79f3aa23fe1025c96295f04f.gif" border="0" /> )</p><p>I just confirmed what was said with the api calls on my laptop here so it is true in that regard.  </p>

Ulrichvon 09-11-2012 10:15 PM

<p><cite>Deago wrote:</cite></p><blockquote><p>What did the dev's say was the main reasoning for dynamic affinity?  (sounds like a romance novel <img src="/eq2/images/smilies/283a16da79f3aa23fe1025c96295f04f.gif" border="0" /> )</p><p>I just confirmed what was said with the api calls on my laptop here so it is true in that regard.  </p></blockquote><p>The intent, was to prevent multiple instances of the client from picking the same core, which is funny, cause as the previous poster pointed out they still are sometimes.  In nearly all cases, allowing the OS to control affinity is the best answer, unfortunately some guy at SoE didn't agree.</p><p>I have a PM from that guy on my banned forum account, I can see if I can locate it.</p>

kdmorse 09-11-2012 11:21 PM

<p><cite>Deago wrote:</cite></p><blockquote><p>What did the dev's say was the main reasoning for dynamic affinity?  (sounds like a romance novel <img src="/eq2/images/smilies/283a16da79f3aa23fe1025c96295f04f.gif" border="0" /> )</p></blockquote><p>I cannot find the thread I'm remembering, where a dev detailed *how* it worked.  How the clients sniffed each other out.  How they counted down from the largest number core.  And that yes, it didn't always work right.  However I don't think that thread ever mentioned *why* they decided to manhandle it.</p><p>I did find 5 other threads over the years, some hilights: (dev name was (Autenil))</p><p><em>The EQ2 <span >client</span> already assigns affinity for the main thread in an attempt to load balance for multiple clients running. If you have 4 cores and 4 clients running, each <span >client</span>'s main thread should get its own <span >core</span>. Affinity is set on a thread level, so you won't see it in the "set affinity..." dialog in the process manager.</em></p><p><em>----</em></p><p><em>EverQuest II does set affinity for its main thread however, to try and maintain cache coherency and avoid timing problems that can result from reading timing values from different CPUs.</em></p><p>----</p><p><em>The game already has code to load-balance multiple clients between the cores (i.e. running four clients on a quad-core machine, each <span >client</span> will get their own <span >core</span>). If you have multicore support enabled, it means that each running <span >client</span> is going to try to use greater than one <span >core</span>. If you have a quad <span >core</span> machine and run two clients, you'd be fine using multicore support. If you have two cores and run two clients with multicore support, it means that the clients are going to both be trying to use greater than one <span >core</span> each and therein lies the issue.The note in the release notes that you're referring to merely means that multicore mode off is the best environment to run when you can only dedicate one </em> <em><span >core</span> to a game <span >client</span>.</em></p><p>-----</p>

kdmorse 09-12-2012 12:08 AM

<p>That reminds me, another workaround I used to use....</p><p>IF your client is allocating processors sequentially per client launched (as it should be, starting with the highest number, working it's way down), and you want a client on a specific logical processor, you can start dummy clients to fill up the cores you don't want, and then kill them when you have a client on the core you do want.</p><p>Assume a quad core ht system, 8 logical processors, numbered 0 -> 7.  You really want a client on #4.</p><p>Start a client, it locks onto #7Start a client, it locks onto #6Start a client, it locks onto #5Start a client, it locks onto #4</p><p>Keep the last one, kill the first three.  The main thread will stay on logical processor #4.</p><p>I used to use that to pin clients where I wanted them.  For about a week.  It got too annoying to do daily....</p>

Deago 09-12-2012 12:41 AM

<p>Scraped project perhaps that was never cleaned up?</p>


All times are GMT. The time now is 06:37 AM.

Powered by vBulletin® Version 3.7.5
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
All threads and posts originally from the EQ2 and Station forums operated by Sony Online Entertainment. Their use is by express written permission.