Are the commands that are overloading the first core multithreaded? You may want to plugin a threaded I/O, as some of the lines of code are quite old, and would not have any idea that multithreaded CPU's would ever exist.
A good drop in library would be http://code.google.com/p/google-perftools/ - it also support OS-X for those Mac modders. -------- Owner Nigredo Studios http://www.nigredostudios.com --- On Mon, 13/9/10, Marek Sieradzki <marek.sierad...@gmail.com> wrote: From: Marek Sieradzki <marek.sierad...@gmail.com> Subject: Re: [hlcoders] Fwd: Source 2007 engine and inconsistent dual/quad core usage To: "Discussion of Half-Life Programming" <hlcoders@list.valvesoftware.com> Received: Monday, 13 September, 2010, 8:59 PM On Mon, Sep 13, 2010 at 12:02 PM, <c277...@bofthew.com> wrote: > Does anyone know why Source 2007 mods usually don't use both (or all) cpu > cores as default? > Every time I start a Source 2007 mod, it uses 10% of core1 and 99-100% of > core2. For quads it goes so that core1 is 100% and rest are around 10%. > > Manually setting the affinity of cores in task manager, after alt-tabbing > from the mod, first to 1 core and then back to 2 cores will even out the > usage percentages so that both cores use about 30-80% depending on mod. Same > works for quad cores as well. > > I've seen and heard from my friends that this is quite common but I could not > find anymore info on this matter and I was wondering why this happens and is > there a way to fix this for good? Some have suggested using host_thread_mode > 2 but that only works for some and to others it just brings more trouble. > > Source 2006 mods seem distribute the usage to both cores evenly without any > hassle. Do you mean 100%, 100% or 50%, 50%? Because every OS can juggle your process from 1 core to another all the time. Also, do you mean client or the server? Even though there's sv_parallel_sendpackets and similar commands in my mod networking dominates CPU time and isn't really parallellized (when it fills 1 core fully server starts be too slow to reply at 33 Hz). I don't know if that's expected behavior. _______________________________________________ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders _______________________________________________ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders