Monday, April 16, 2012

[REQ-SC2] how to keep the simspeed constant?

Hello. :)
I read in a post (pertaining to FA) that it is possible to keep the simspeed at a constant rate, no matter what the sim thinks your cpu can handle.
As i stated, i know that pertains to FA, but my question is; can this be done to SC2 also?
If so, how?
Thanks.
Also, lets say there were no gamespeed options available, how would i be able to increase gamespeed through lua and without meddling in game.prefs?
Thanks again.|||damusolja|||Why wouldn't the hack on the executable not work on 360? I can access the xex file and uncompile it in IDA. I can also edit and recompile and resign the xex file to either DEV or retail.
But seeing as how i don't know were to look in the engine, i wont try this method, unless i know were and what to edit.
What about this Conexecute method? how would i go about doing this method.
Thanks.|||There is no executable hack for SC2.
Even if there were, it would depend heavily on very particular behavior from the executable, e.g. specific memory offsets that can change radically with a re-compile, between versions, etc. Even if such a thing existed for the PC version, it would never work on the 360 executable without significant changes, nevermind that it would also be a native Win32 app and wouldn't run at all on the 360.|||Sim speeds adjusted for a reason to keep the game stable even if you could force a constant speed more than likely the game would crash from a lack of memory.|||liveordie|||So the simrate does not affect the ram, thats good to know. What does it affect then?

I can deal with a bit of stuttering, i've played the 360 version with +4 gamespeed.Its actually not noticeable. how i did this was through lua/ui/lobby/lobbyoptions.lua. I simply changed the default for gamespeed from 1 to 2. 3 would set it to adjustable in game, but because the keys for this action are not mapped for 360, i cant use this feature.
i'm running a 500 unit cap, and i notice that the game runs smoother than it did with normal gamespeed long term wise. Yes the initial start was stuttering sometimes, but when the unit cap increased and battles were going on it would smooth to normal.
Is there a way to get the sim to at least 7?
Thanks.|||If you're running the game at a higher simspeed than the hardware can handle, since SCom2 was never designed to "skip forwards" in time, I imagine that, in practical terms, the simspeed will slow down anyways as the CPU struggles to process the simulation fast enough.
ie. It will claim to be running at +4 or whatever, but it will run slowly and jerkily, rather than slowing down gracefully and smoothly if you allow the built-in simspeed adjuster to do its job.
It's also possible that the simulation/gameplay processes will eat into the CPU needed by rendering, sound or networking, so possibly the framerate, sound output, or network code might slow/stutter or stop altogether. (although in a multithreaded application on a multicore CPU maybe that wont happen - depends what processes are run on which cores.)|||360 cpu specs:
-90 nm process, 65 nm process upgrade in 2007 (codenamed "Falcon"), 45 nm process since Xbox 360 S model.
-165 million transistors.
-Three symmetrical cores, each two way SMT-capable and clocked at 3.2 GHz.
-SIMD: VMX128 with 2× (128×128 bit) register files for each core.
-1 MB L2 cache (lockable by the GPU) running at half-speed (1.6 GHz) with a 256-bit bus.
-51.2 gigabytes per second of L2 memory bandwidth (256 bit × 1600 MHz)
-21.6 GB/s front-side bus
Dot product performance: 9.6 billion per second.
-96.0 (4× 32VMX + 1× FPU × 3 cores × 3.2 GHz) GFLOPS theoretical peak performance (single-precision).
-57.6 (2× 64VMX + 1× FPU × 3 cores × 3.2 GHz) GFLOPS theoretical peak performance (double-precision).
-Restricted to in-order code execution
eFuse 768 bits.
-ROM (and 64 kbytes SRAM) storing Microsoft's Secure Bootloader, and encryption hypervisor.
-Big endian architecture.
360 GPU specs:
-500 MHz 10 MiB daughter embedded DRAM (@256GB/s) framebuffer on 90 nm process[citation needed].
-NEC designed eDRAM die includes additional logic (192 parallel pixel processors) for color, alpha compositing, Z/stencil buffering, and anti-aliasing called “Intelligent Memory”, giving developers 4-sample anti-aliasing at very little performance cost.
-105 million transistors .
-8 Render Output units.
-Maximum pixel fillrate: 16 gigasamples per second fillrate using 4X multisample anti aliasing (MSAA), or 32 gigasamples using Z-only operation; 4 gigapixels per second without MSAA (8 ROPs × 500 MHz).
-Maximum Z sample rate: 8 gigasamples per second (2 Z samples × 8 ROPs × 500 MHz), 32 gigasamples per second using 4X anti aliasing (2 Z samples × 8 ROPs × 4X AA × 500 MHz).
-Maximum anti-aliasing sample rate: 16 gigasamples per second (4 AA samples × 8 ROPs × 500 MHz).
-500 MHz parent GPU on 90 nm , 65 nm or 45nm TSMC process of total 232 million transistors.
-48 floating-point vector processors for shader execution, divided in three dynamically scheduled SIMD groups of 16 processors each.
-Unified shading architecture (each pipeline is capable of running either pixel or vertex shaders).
-10 FP ops per vector processor per cycle (5 fused multiply-add).
-Maximum vertex count: 6 billion vertices per second ( (48 shader vector processors × 2 ops per cycle × 500 MHz) / 8 vector ops per vertex) for simple transformed and lit polygons.
-Maximum polygon count: 500 million triangles per second.
-Maximum shader operations: 96 Billion shader operations per second (48 ALUs × 4 shader (2 vector4 and 2 scalar) operations per cycle(4 shader operations per ALU per cycle) × 500Mhz).
-240GLOPS.
-MEMEXPORT shader function.
-16 texture filtering units (TF) and 16 texture addressing unit (TA)
-16 filtered samples per clock.
-Maximum texel fillrate: 8 gigatexel per second (16 textures × 500 MHz)
-16 unfiltered texture samples per clock.
-Maximum Dot product operations: 24 billion per second.
-Support for a superset of DirectX 9.0c API DirectX Xbox 360, and Shader Model 3.0+.

I'm quite sure the cpu and gpu can handle the simrate, i wont mention ram seeing as how simrate has no affect on it. the game pushes faster when the battles happen but then slows down as if there is a speed limiter. maybe its set to turn the simrate down if it detects large battles as to not run your cpu to hot to prevent crashing the game.
Yes i believe heat plays a role in the performance as well. the cooler the cpu and gpu are the smoother the game.

Any how, is there a way to do this ConExecute method? If so, were and witch file do i need?|||The game runs like crap on a 775 quad core clocked at 3.2ghz, playing a few games with 1 friend with a i7 then going to my other friend that use to have a quad core he would be 6-7 lower than my systems sim, meaning he was around -4 after about 30 minutes into a game i told him this he didn't believe me until he upgrade a month ago to a i7 keeping his old video card now when we all play we are never 1 bellow or high than each other making a stable and smooth game play. what im saying is the end room for old hardware that's used in the xbox 360 cant be push much more than it already is.|||liveordie|||damusolja|||DeadMG|||Mithy|||Fair enough. I'm sure there are compiler optimizations in effect, but how they affect SC2's sim efficiency can't be extremely significant, because the game slows down on the 360 similarly to how it slows down on an equivalent desktop CPU, whereas plenty of other games run much more efficiently on the 360's relatively old hardware than they do on all but the newest PCs (ignoring some obvious differences in memory usage, texture resolution, etc).
Of course, it's difficult to determine what an 'equivalent' is when they're using different CPU architectures and instruction sets, and have different system architectures (as you mentioned, shared memory, shared GPU/CPU dies on newer incarnations, etc).|||DeadMG|||The game speed is hard-set, not the sim speed. The sim speed is always variable (downward), in any moho engine game on any platform. If it wasn't, it would stutter and skip badly whenever it ran into CPU limits, as DeadMG described.|||Mithy|||That may be true LoD, but then again, maybe the sim limiter is set to slow down during large battles as i said. look at it like having a fast car that you know can go 200 mph, hell it says it on the dash, but its speed limiter or governor cap only allows it to go 120 mph.
about me stating my issues with the game to LoD, I might have spoken to soon when i said that. I apologize for any confusions, but really there were problems with my jtag having issues in general, not because of this game. those issue have been solved, and the game only slows down under load as mentioned.
If the sim rate is a variable that can be adjusted then how can this be achieved? Also, if game speed is hardcoded then why is it that i can raise it to +4? or is this simply not true?
I'll post a vid, that way you guys can see what i'm talking about.
Thanks.|||There is no limiter for sim speed that's what i was saying before the game will slow down to a speed your system can handle then speed back up when the load finished, You may be able to change the game speed but it will only apply till your system hits that same point were it slows down then game speed wont mater ether way, There is a command "wld_RunWithTheWind If true, run beats as fast as we can" on pc that pushes the game speed to the max also doesn't adjust the sim speed i've tried this before and it stutters and lags really bad.|||Yes, that is correct LoD. The game runs at 0 witch is normal game speed, and when the load increases slows down, then it speeds back to normal when there isnt so much going on.

There is a limit to how low the sim can go though right? I mean, if this variable can be found, and seeing as how this is not hardcoded, can i it change from what ever the lower limit is to lets say -1 or 0? That way when it does slow down, it wont go below -1 or 0, depending on the number i set it at.

Also, how did you go about doing this "wld_RunWithTheWind If true, run beats as fast as we can" code? If you still got the 360 files LoD, do u mind implementing this? for testing purposes.
Thanks.
Also vid coming soon.|||On pc the lowest the sim will read is -10 but it can go lower i think doesn't matter what you set the game speed to the game will still slow to what it can handle on that system me and my friends always play on +4 game speed, when 2000 unit battle happens the sim speed will lower to around 0 to -4 then when all the units have died the game speed will speed back up to +2 because the AI builds a huge base that's were we lose 2 sim speed but ether way the game will run at the same speed if your using +10 game speed the sim will still adjust to what it would if you were using 0 game speed, wld_RunWithTheWind is a console command i think there is way to make commands run at start up.|||Here's the vid:

http://www.youtube.com/watch?v=ib6w8phR8GQ
Note that this is the 0.5 scale mod LoD provided me. It's not perfect but its a clear understanding of what level the sim drops to. I don't know exactly how low it is in the vid, but its pretty low.
I will also upload another vid but with a normal scale and huge battle going on.
Thanks.|||That's normal, and is what happens when there isn't enough available CPU power to process the sim at full speed. The moho engine is not multithreaded at all-- the sim must run on one core only, and the sim usually represents about 90-95% of the game's CPU load.
The fact that it still otherwise runs smoothly (and that presumably, the sound isn't choppy and stuttering) means that rendering and audio and other user-layer processes are already being handled by other threads on other cores, and there's nothing more you can do to make it run faster - it's running into a hard limit on available single-core processing power.|||Okay, but how many threads does supcom 2 use? i really feel that the game could be optimised more. 3 core's,each with 2 threads for a total of 6 threads should easily run this game if optimised correctly.
Also that was +4 gamespeed, but because the scale mod is not perfect there are some bug's prably caused by the LOD cuttoffs i think. Xbox has sound issues, just not as noticeable as the pc's.
I will upload a vid of normal scale with normal game speed, then one with +4 gamespeed.
Thanks for the reply's you guy's. very informative.

No comments:

Post a Comment