Open RaphaelRoyerRivard opened 4 years ago
Something not logged from the combat commander took 5s
19608: CCBot::drawProfilingInfo | 0.0 OnStep took 5180.201172ms
19608: CCBot::drawProfilingInfo | 0.10 m_gameCommander.onFrame took 5179.375488ms
19608: CCBot::drawProfilingInfo | 0.10.1 handleUnitAssignments took 0.028000ms
19608: CCBot::drawProfilingInfo | 0.10.4 m_combatCommander.onFrame took 5179.342285ms
19608: CCBot::drawProfilingInfo | 0.10.4.0 updateInfluenceMaps took 0.886000ms
19608: CCBot::drawProfilingInfo | 0.10.4.0.1 resetInfluenceMaps took 0.347000ms
19608: CCBot::drawProfilingInfo | 0.10.4.0.2 updateInfluenceMapsWithUnits took 0.532000ms
19608: CCBot::drawProfilingInfo | 0.10.4.0.3 updateInfluenceMapsWithEffects took 0.001000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1 CalcBestFlyingCycloneHelpers took 0.118000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.1 updateUnits took 0.065000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.3 SetSquadTargets took 0.052000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.4 ExecuteMeleeMicro took 0.003000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5 ExecuteRangedMicro Backup took 3.988000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5 ExecuteRangedMicro MainAttack took 11.425000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5 ExecuteRangedMicro Scout took 0.313000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1 HarassLogicForUnit took 15.442000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.0 getTarget took 1.301000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.1 getThreats took 0.734000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.2 ShouldUnitHeal took 0.899000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.4 ShouldAttackTarget took 0.003000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.5 ThreatFighting took 7.699000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.5.1 CalcCloseUnits took 2.630000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.5.2 CalcThreats took 2.304000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.5.3 CalcThreatsPower took 0.421000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.5.4 SimulateCombat took 0.587000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.6 UnitAbilities took 0.008000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding took 3.920000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding 35 took 0.097000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding 49 took 0.171000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding 692 took 3.649000ms
19608: CCBot::drawProfilingInfo | 0.10.4.1.5.1.8 PotentialFields took 0.004000ms
19608: CCBot::drawProfilingInfo | 0.10.4.2 updateSquads took 0.844000ms
19608: CCBot::drawProfilingInfo | 0.10.4.2.1 updateDefenseBuildings took 0.013000ms
19608: CCBot::drawProfilingInfo | 0.10.4.2.2 updateDefenseSquads took 0.277000ms
19608: CCBot::drawProfilingInfo | 0.10.4.2.2.1 detectEnemiesInRegions took 0.169000ms
19608: CCBot::drawProfilingInfo | 0.10.4.2.2.3 clearRegion took 0.055000ms
19608: CCBot::drawProfilingInfo | 0.10.4.2.3 updateHarassSquads took 0.015000ms
19608: CCBot::drawProfilingInfo | 0.10.4.2.3.0 calcEnemies took 0.074000ms
19608: CCBot::drawProfilingInfo | 0.10.4.2.3.1 simulateCombat took 0.298000ms
19608: CCBot::drawProfilingInfo | 0.10.4.3 m_squadData.onFrame took 15.914001ms
19608: CCBot::drawProfilingInfo | 0.10.4.4 checkUnitsState took 0.204000ms
19608: CCBot::drawProfilingInfo | 0.10.4.4.1 resetStates took 0.008000ms
19608: CCBot::drawProfilingInfo | 0.10.4.4.2 updateStates took 0.189000ms
19608: CCBot::drawProfilingInfo | 0.10.4.4.2.1 addState took 0.007000ms
19608: CCBot::drawProfilingInfo | 0.10.4.4.2.2 updateState took 0.014000ms
19608: CCBot::drawProfilingInfo | 0.10.4.4.3 removeStates took 0.002000ms
19608: CCBot::drawProfilingInfo | 0.11 m_repairStations.onFrame took 0.003000ms
19608: CCBot::drawProfilingInfo | 0.12 m_combatAnalyzer.onFrame took 0.231000ms
19608: CCBot::drawProfilingInfo | 0.2 setUnits took 0.290000ms
19608: CCBot::drawProfilingInfo | 0.2.1 identifyEnemyRepairingSCVs took 0.010000ms
19608: CCBot::drawProfilingInfo | 0.2.1 loopAllUnits took 0.099000ms
19608: CCBot::drawProfilingInfo | 0.2.2 identifyEnemySCVBuilders took 0.003000ms
19608: CCBot::drawProfilingInfo | 0.2.2 clearDeadUnits took 0.016000ms
19608: CCBot::drawProfilingInfo | 0.2.3 identifyEnemyWorkersGoingIntoRefinery took 0.003000ms
19608: CCBot::drawProfilingInfo | 0.2.3 clearDuplicateUnits took 0.104000ms
19608: CCBot::drawProfilingInfo | 0.5 m_unitInfo.onFrame took 0.199000ms
19608: CCBot::drawProfilingInfo | 0.6 m_bases.onFrame took 0.033000ms
19608: CCBot::drawProfilingInfo | 0.6.2 resetBaseLocations took 0.002000ms
19608: CCBot::drawProfilingInfo | 0.6.3 updateBaseLocations took 0.019000ms
19608: CCBot::drawProfilingInfo | 0.6.4 updateEnemyBaseLocations took 0.002000ms
19608: CCBot::drawProfilingInfo | 0.6.7 setOccupiedBaseLocations took 0.005000ms
19608: CCBot::drawProfilingInfo | 0.7 m_workers.onFrame took 0.017000ms
19608: CCBot::drawProfilingInfo | 0.7.1 m_workerData.updateAllWorkerData took 0.015000ms
Combat simulation took 1s
24902: CCBot::drawProfilingInfo | 0.0 OnStep took 1023.253052ms
24902: CCBot::drawProfilingInfo | 0.10 m_gameCommander.onFrame took 1022.327026ms
24902: CCBot::drawProfilingInfo | 0.10.1 handleUnitAssignments took 0.036000ms
24902: CCBot::drawProfilingInfo | 0.10.4 m_combatCommander.onFrame took 1022.286072ms
24902: CCBot::drawProfilingInfo | 0.10.4.0 updateInfluenceMaps took 0.171000ms
24902: CCBot::drawProfilingInfo | 0.10.4.0.1 resetInfluenceMaps took 0.141000ms
24902: CCBot::drawProfilingInfo | 0.10.4.0.2 updateInfluenceMapsWithUnits took 0.027000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1 CalcBestFlyingCycloneHelpers took 0.134000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.1 updateUnits took 0.056000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.3 SetSquadTargets took 0.017000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.4 ExecuteMeleeMicro took 0.001000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5 ExecuteRangedMicro Backup took 9.587001ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5 ExecuteRangedMicro Base Defense 117 60 took 0.096000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5 ExecuteRangedMicro MainAttack took 0.379000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5 ExecuteRangedMicro Scout took 0.056000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1 HarassLogicForUnit took 10.023001ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1.0 getTarget took 0.100000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1.1 getThreats took 0.080000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1.2 ShouldUnitHeal took 3.665000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1.4 ShouldAttackTarget took 0.001000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1.5 ThreatFighting took 5.296000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1.6 UnitAbilities took 0.065000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding took 0.185000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding 34 took 0.036000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding 57 took 0.145000ms
24902: CCBot::drawProfilingInfo | 0.10.4.1.5.1.9 DefensivePathfinding took 0.090000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2 updateSquads took 1009.840027ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.1 updateDefenseBuildings took 0.003000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.2 updateDefenseSquads took 0.223000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.2.1 detectEnemiesInRegions took 0.068000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.2.3 clearRegion took 0.018000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.2.3 createSquad took 0.001000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.2.4 calculateRegionInformation took 0.004000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.2.5 calculateRegionsScores took 0.064000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.2.6 affectUnits took 0.005000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.3 updateHarassSquads took 0.005000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.3.0 calcEnemies took 0.017000ms
24902: CCBot::drawProfilingInfo | 0.10.4.2.3.1 simulateCombat took 1009.481018ms
24902: CCBot::drawProfilingInfo | 0.10.4.3 m_squadData.onFrame took 10.241000ms
24902: CCBot::drawProfilingInfo | 0.10.4.4 checkUnitsState took 0.203000ms
24902: CCBot::drawProfilingInfo | 0.10.4.4.1 resetStates took 0.009000ms
24902: CCBot::drawProfilingInfo | 0.10.4.4.2 updateStates took 0.189000ms
24902: CCBot::drawProfilingInfo | 0.10.4.4.2.2 updateState took 0.002000ms
24902: CCBot::drawProfilingInfo | 0.10.4.4.3 removeStates took 0.002000ms
24902: CCBot::drawProfilingInfo | 0.11 m_repairStations.onFrame took 0.006000ms
24902: CCBot::drawProfilingInfo | 0.12 m_combatAnalyzer.onFrame took 0.241000ms
24902: CCBot::drawProfilingInfo | 0.2 setUnits took 0.329000ms
24902: CCBot::drawProfilingInfo | 0.2.1 identifyEnemyRepairingSCVs took 0.004000ms
24902: CCBot::drawProfilingInfo | 0.2.1 loopAllUnits took 0.189000ms
24902: CCBot::drawProfilingInfo | 0.2.2 identifyEnemySCVBuilders took 0.002000ms
24902: CCBot::drawProfilingInfo | 0.2.2 clearDeadUnits took 0.014000ms
24902: CCBot::drawProfilingInfo | 0.2.3 identifyEnemyWorkersGoingIntoRefinery took 0.002000ms
24902: CCBot::drawProfilingInfo | 0.2.3 clearDuplicateUnits took 0.078000ms
24902: CCBot::drawProfilingInfo | 0.5 m_unitInfo.onFrame took 0.269000ms
24902: CCBot::drawProfilingInfo | 0.6 m_bases.onFrame took 0.040000ms
24902: CCBot::drawProfilingInfo | 0.6.2 resetBaseLocations took 0.002000ms
24902: CCBot::drawProfilingInfo | 0.6.3 updateBaseLocations took 0.026000ms
24902: CCBot::drawProfilingInfo | 0.6.4 updateEnemyBaseLocations took 0.001000ms
24902: CCBot::drawProfilingInfo | 0.6.7 setOccupiedBaseLocations took 0.005000ms
24902: CCBot::drawProfilingInfo | 0.7 m_workers.onFrame took 0.021000ms
24902: CCBot::drawProfilingInfo | 0.7.1 m_workerData.updateAllWorkerData took 0.019000ms
0.4 m_map.onFrame took 525.449036ms
15956: drawProfilingInfo | 0.10.4.1.5.1 HarassLogicForUnit took 48.306004ms
15956: drawProfilingInfo | 0.10.4.1.5.1.0 getTarget took 0.638000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.1 getThreats took 0.510000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.2 ShouldUnitHeal took 0.456000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.4 ShouldAttackTarget took 0.003000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.5 ThreatFighting took 0.941000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.5.1 CalcCloseUnits took 0.261000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.5.2 CalcThreats took 0.027000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.6 UnitAbilities took 0.008000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding took 1.880000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding 35 took 0.061000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding 49 took 0.252000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding 57 took 0.086000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.7 OffensivePathFinding 692 took 1.447000ms
15956: drawProfilingInfo | 0.10.4.1.5.1.8 PotentialFields took 0.010000ms
Could also show the number of times the method has been called in the frame.
Nothing show what is slow in ThreatFighting
19585: drawProfilingInfo | 0.10.4.1.5.1.5 ThreatFighting took 48.319004ms for 17 calls
19585: drawProfilingInfo | 0.10.4.1.5.1.5.1 CalcCloseUnits took 1.225000ms for 7 calls
19585: drawProfilingInfo | 0.10.4.1.5.1.5.2 CalcThreats took 0.668000ms for 6 calls
19585: drawProfilingInfo | 0.10.4.1.5.1.5.3 CalcThreatsPower took 0.141000ms for 6 calls
19585: drawProfilingInfo | 0.10.4.1.5.1.5.4 SimulateCombat took 0.142000ms for 5 calls
Same for lowPriorityChecks of workers
19585: drawProfilingInfo | 0.7 m_workers.onFrame took 35.086002ms for 1 calls
19585: drawProfilingInfo | 0.7.1 m_workerData.updateAllWorkerData took 0.084000ms for 1 calls
19585: drawProfilingInfo | 0.7.2 handleMineralWorkers took 0.008000ms for 1 calls
19585: drawProfilingInfo | 0.7.3 handleGasWorkers took 0.072000ms for 1 calls
19585: drawProfilingInfo | 0.7.4 handleIdleWorkers took 0.012000ms for 1 calls
19585: drawProfilingInfo | 0.7.5 repairCombatBuildings took 0.026000ms for 1 calls
19585: drawProfilingInfo | 0.7.6 lowPriorityChecks took 34.563004ms for 1 calls
19585: drawProfilingInfo | 0.7.7 handleRepairWorkers took 0.311000ms for 1 calls
And ExecuteCycloneLogic
19873: drawProfilingInfo | 0.10.4.1.5.1.b ExecuteCycloneLogic took 11.977000ms for 9 calls
Also, order is bad for the combat commander
19921: drawProfilingInfo | 0.10.4 m_combatCommander.onFrame took 48.491001ms for 1 calls
19921: drawProfilingInfo | 0.10.4.1 CalcBestFlyingCycloneHelpers took 0.101000ms for 1 calls
19921: drawProfilingInfo | 0.10.4.1.5 ExecuteRangedMicro MainAttack took 39.932003ms for 1 calls
The order is bad for the production manager
20427: drawProfilingInfo | 0.10 m_gameCommander.onFrame took 112.218002ms for 1 calls
20427: drawProfilingInfo | 0.10.2 m_productionManager.onFrame took 105.463005ms for 1 calls
20427: drawProfilingInfo | 2.0 manageBuildOrderQueue took 105.422005ms for 1 calls
20427: drawProfilingInfo | 2.2 checkQueue took 105.366005ms for 1 calls
20427: drawProfilingInfo | 2.2.2 tryingToBuild took 105.283005ms for 5 calls
20427: drawProfilingInfo | 2.2.3 Build without premovement took 104.208008ms for 4 calls
The lag of Build without premovement
is probably caused by the use of Util::PathFinding::IsPathToGoalSafe
in BuildingManager::addBuildingTask
.
Because we get attacked and we have no safe place to put our buildings, getBuildLocationNear() makes the bot lag.
10583: drawProfilingInfo | 0.0 OnStep took 54.070004ms for 1 calls
10583: drawProfilingInfo | 0.10 m_gameCommander.onFrame took 53.087002ms for 1 calls
10583: drawProfilingInfo | 0.10.1 handleUnitAssignments took 0.015000ms for 1 calls
10583: drawProfilingInfo | 0.10.2 m_productionManager.onFrame took 40.625004ms for 1 calls
10583: drawProfilingInfo | 0.10.2.1 putImportantBuildOrderItemsInQueue took 0.047000ms for 1 calls
10583: drawProfilingInfo | 0.10.2.2 checkQueue took 40.531002ms for 1 calls
10583: drawProfilingInfo | 0.10.2.2.2 tryingToBuild took 40.447002ms for 8 calls
10583: drawProfilingInfo | 0.10.2.2.2.2 Build with premovement took 40.442001ms for 2 calls
10583: drawProfilingInfo | 0.10.2.2.2.2.1 getNextBuildingLocation took 40.422001ms for 2 calls
10587: drawProfilingInfo | 0.8.3.1.3 getBuildLocationNear took 36.288002ms for 1 calls
And probably the code for the wall is a bit slow.
10587: drawProfilingInfo | 0.10.4.2 updateSquads took 9.958000ms for 1 calls
10587: drawProfilingInfo | 0.10.4.2.1 updateDefenseBuildings took 9.526000ms for 1 calls
There is also something else in the building construction that is slow
7051: drawProfilingInfo | 0.10 m_gameCommander.onFrame took 106.451004ms for 1 calls
7051: drawProfilingInfo | 0.10.2 m_productionManager.onFrame took 104.781006ms for 1 calls
7051: drawProfilingInfo | 0.10.2.2 manageBuildOrderQueue took 104.726006ms for 1 calls
7051: drawProfilingInfo | 0.10.2.2.2 checkQueue took 104.683006ms for 1 calls
7051: drawProfilingInfo | 0.10.2.2.2.2 tryingToBuild took 104.668007ms for 2 calls
7051: drawProfilingInfo | 0.10.2.2.2.2.1 Build without premovement took 104.665009ms for 2 calls
7051: drawProfilingInfo | 0.10.2.2.2.2.1.1 canMakeNow took 104.622002ms for 1 calls
And that
11745: drawProfilingInfo | 0.10 m_gameCommander.onFrame took 84.227005ms for 1 calls
11745: drawProfilingInfo | 0.10.2 m_productionManager.onFrame took 73.855003ms for 1 calls
11745: drawProfilingInfo | 0.10.2.2 manageBuildOrderQueue took 73.814003ms for 1 calls
11745: drawProfilingInfo | 0.10.2.2.2 checkQueue took 73.768005ms for 1 calls
11745: drawProfilingInfo | 0.10.2.2.2.2 tryingToBuild took 73.744003ms for 7 calls
11745: drawProfilingInfo | 0.10.2.2.2.2.1 Build without premovement took 73.742004ms for 6 calls
11745: drawProfilingInfo | 0.10.2.2.2.2.1.2 create took 72.726006ms for 1 calls
11745: drawProfilingInfo | getRefineryPosition took 72.664001ms for 1 calls
8928: drawProfilingInfo | 0.10.4.1.5.1.c.1 ExecuteBansheeUncloakLogic took 63.043003ms for 3 calls
There was a 1.5s lag caused by the combat analyzer (happened twice)
and a 2.5s lag caused by DefensivePathFinding
and a 58s lag caused by the build order queue