As claimed by @vladislavbelov on several occasions (e.g. https://wildfiregames.com/forum/topic/29654-request-sacrificial-knife/?tab=comments#comment-405553), having many different actors affects performance. A way to reduce the effect, but still allow many variants is to optionally disable the randomness. This should limit the number of different variants if disabled, but keeps the old performance if enabled.
Details
- Reviewers
vladislavbelov Freagarach - Trac Tickets
- #5831
Check that it actually improves performance
Check no OOS occurs
Comment on D3034
Think of better descriptions
Diff Detail
- Repository
- rP 0 A.D. Public Repository
- Branch
- /ps/trunk
- Lint
Lint OK - Unit
No Unit Test Coverage - Build Status
Buildable 13385 Build 26901: Vulcan Build Jenkins Build 26900: Vulcan Build (macOS) Jenkins Build 26899: Vulcan Build (Windows) Jenkins Build 26898: arc lint + arc unit
Event Timeline
Successful build - Chance fights ever on the side of the prudent.
builderr-release-macos.txt /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: ../../../binaries/system/libgraphics.a(precompiled.o) has no symbols
Link to build: https://jenkins.wildfiregames.com/job/macos-differential/1648/display/redirect
binaries/data/config/default.cfg | ||
---|---|---|
84 | I guess you mean variants instead of graphics items? | |
85 | graphics.entityvariety? | |
binaries/data/mods/public/gui/options/options.json | ||
202 | slight and boost are kind of opposite ;) | |
source/graphics/ObjectBase.cpp | ||
568–569 | This sentence is a continuation of Choose a random number in the interval [0..totalFreq) so with the full-stop there this needs to be changed as well. | |
569 | I'm not sure what this all does, but can't you skip the whole searching for a match? |
source/graphics/ObjectBase.cpp | ||
---|---|---|
569 | We sometimes want to force a unit to take a certain form (choose some animation say), I think... |
Successful build - Chance fights ever on the side of the prudent.
builderr-release-macos.txt /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: ../../../binaries/system/libgraphics.a(precompiled.o) has no symbols
Link to build: https://jenkins.wildfiregames.com/job/macos-differential/1656/display/redirect
binaries/data/config/default.cfg | ||
---|---|---|
84 | What is meant with remaining here? | |
binaries/data/mods/public/gui/options/options.json | ||
202 | small and boost are still. I suggest using improvement over boost. Then either slight or small as you wish, | |
source/graphics/ObjectBase.cpp | ||
571 | If randNum is 0 due to entityVariety == false, this will become negative immidiately, I think? (Assuming (*grp)[i].m_Frequency) is a positive integer.) Causing us to break at after the first loop with match == 0? |
binaries/data/mods/public/gui/options/options.json | ||
---|---|---|
202 | Maybe Works best in a new match.? The "game" word (in context of match) in options seems a bit misleading to me. | |
source/graphics/ObjectBase.cpp | ||
568 | entityVariety might be not initialized afaik. | |
569 | Are sure that you need to ask options for each group and each model? |
binaries/data/mods/public/gui/options/options.json | ||
---|---|---|
202 | by the changes it now requires to restart a match, this doesn't have to be done like this, by adding some function setting the parameter on the fly |
Successful build - Chance fights ever on the side of the prudent.
builderr-release-macos.txt /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: ../../../binaries/system/libsimulation2.a(precompiled.o) has no symbols /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: ../../../binaries/system/libengine.a(precompiled.o) has no symbols /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: ../../../binaries/system/libgraphics.a(precompiled.o) has no symbols /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: ../../../binaries/system/libatlas.a(precompiled.o) has no symbols
Link to build: https://jenkins.wildfiregames.com/job/macos-differential/1675/display/redirect
source/graphics/ObjectBase.cpp | ||
---|---|---|
554 | Can't you break here? |
Successful build - Chance fights ever on the side of the prudent.
builderr-release-macos.txt /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: ../../../binaries/system/libsimulation2.a(precompiled.o) has no symbols /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: ../../../binaries/system/libgraphics.a(precompiled.o) has no symbols /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: ../../../binaries/system/libatlas.a(precompiled.o) has no symbols
Link to build: https://jenkins.wildfiregames.com/job/macos-differential/1682/display/redirect
Yes, I see a 10% improvement on combat demo (huge) (FPS increase, ms/frame and ms/turn decrease).
I think this should be put next to renderactors, and possibly have that as the lowest setting?