Thanks for your replays guys, it's really useful to test the game under real situations so we know where the bottlenecks really are. Normally when we are testing performance we just run a map with AI builders, but humans play quite differently compared to AIs.
Yesterday I came up with an idea to optimize flood fills, which are by far the slowest part of the game. It worked very nicely and I also made another optimization to units finding mining tasks. The end result can be seen in how long it takes to simulate your replays. We simulate them with a tool that removes all graphical aspects of the game, it just runs the game logic as fast as possible (no rendering). Simulations were run multiple times and averaged.
We just played this game on r5116. It was a really bad game and sado messed up because of the new build order. Anyway I hope this helps with analyzing.
Simulated 70 minutes of game time in:
r5116: 70 seconds.
r5196: 43 seconds.
Simulated 70 minutes of game time in:
r5116: 132 seconds
r5196: 82 seconds
This shows my optimizations produced a ~60% speed up, which is massive! I'm quite pleased with the result. Hopefully you'll notice a difference in the next RC, and people with older computers will be able to use speed up in multiplayer without causing lag (and singleplayer/replays will be smoother/faster when using speed up).
Note that I'm focusing on game logic not rendering in my optimizations. Rendering isn't a bottleneck unless you have an old/slow GPU, and we can't do much about that anyway. Also, the less time the game spends on game logic the more time it has to pump out frames and give you a higher FPS (since game logic and rendering share one thread).
Cheers,
Lewin.