Skip to content

cmake: function-visibility.txt, which callers must see which callees' bodies - #398

Merged
TheRedDaemon merged 7 commits into
sourcehold:mainfrom
kotijekriv:reimpl/function-visibility-manifest
Nov 21, 2026
Merged

TheRedDaemon merged 7 commits into
sourcehold:mainfrom
kotijekriv:reimpl/function-visibility-manifest

Conversation

@kotijekriv

@kotijekriv kotijekriv commented Nov 12, 2026 •

Copy link
Copy Markdown
Contributor

Update (2026-11-21), after #399: #399 brought this manifest onto main (02fab42) as it stood at 20176fe, so everything described below is on main already. main is now merged into this branch (3e959f2), and against main this PR adds only one edge: UpdateTrebuchet → GameSynchronyState::isAIPlayer (its update note is below; UpdateTrebuchet is in #453).

Adds cmake/function-visibility.txt, the list gynt asked for on Discord: for each caller, the functions whose bodies it has to see when it is compiled.

OpenSHC::Map::Units::UpdateCamel
    OpenSHC::Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState
    OpenSHC::Map::Units::UnitsState::hasUnitReachedDestination

means UpdateCamel has to be compiled in a unit that also holds those two bodies. Whether a callee needs something itself is its own entry. Names are fully qualified the way the definitions are written. Entries are sorted by the caller's address, and each entry's callees by theirs. There are 85 entries with 125 edges, and in every one of them the callee is at a lower address than its caller. Nothing else changes: the file is not read by the build yet.

Update after #290: #290 rewrote UpdateBadBuildingGibbet and UpdateBadBuildingStretchingRack so that they reach 100% without /GL. On main ea63a49d9 both measure 1.0000 with and without updateBuildingSignpostCounter's body, so their two edges are gone (87 entries and 127 edges before). Their "must not see" rows for addBuildingToTargetableBuildings still hold on the new code and are re-measured below: 1.0000 alone, 0.8539 (Gibbet) and 0.7407 (StretchingRack) with it.

Update (2026-11-21), for #378: #378 puts UnitsState/selectionContainsOnlyArabAssassins.cpp on the /GL list. BuildingsState::canUnitReachBuildingPerimeter (on main at 100%) calls that function and must not see its body: the pair is in the "Must not see" table below (0.7731 alone, 0.5738 with it). Nothing had to be added to the list for it. Its entry is already here, with getBuildingHeightForBuildingID, the one callee it must see. With #399's option on, that puts it into a wrapper of three files built without /GL. Real builds, reccmp, raw:

build canUnitReachBuildingPerimeter
main 3458fea34, /GL 100.0
main + #378 e81059741, /GL 60.1
main + #378 without that one /GL line 100.0
main + #378 + #399, wrapper option on 100.0

Two limits. The list isn't read by the default build, so there only the /GL list decides. And an entry without callee lines changes nothing, because the generator groups only files that an entry joins.

Update (2026-11-21), for UpdateTrebuchet: one edge more, UpdateTrebuchet → GameSynchronyState::isAIPlayer. Without it UpdateTrebuchet measures 0.9132 with its other two callees; with it 0.9818. The original calls it at 0x0056A05B and 0x0056A124 and does not re-read the unit slot behind either call.

One edge is gone: UpdateMerchant → activateTraderState. It was measured on a 93.8% draft, the weaker kind of evidence named under "Known gaps". UpdateMerchant has since landed on main at 100% (#409), and that version must not see the body. On main 3458fea34 it reads 100.0 under /GL (activateTraderState.cpp isn't on the /GL list), 90.0 in a wrapper build with the old line and 100.0 without it. It was the only one of 150 functions (the /GL list plus every file this list names) whose raw number differed between /GL and the wrappers.

How each edge was measured

Every edge comes from tools/compiler-internals/tu_merge.py, not from reading the code. For a caller and one or more callees, it compiles the caller as committed and with the callees' bodies pasted into its file (bundled MSVC 2005, /FA, no /GL). Each result is diffed against the original with quick_diff.py --name CALLER. Every function and struct resolver was switched on.

  • A callee is listed when pasting it in raises the caller's score.
  • A callee that makes the caller worse is the opposite case: the original's caller did not know that body, so the two were in different files. These "must not see" pairs are listed below. They matter as much as the edges, because today's /GL list lets every listed file see every other.
  • Callers with several callees were also measured with all of them pasted in at once, then with each one left out in turn. A callee whose removal lowers the score is needed together with the others (10 callees hurt alone but are needed in the full set). One whose removal raises it must not be seen. That was repeated without the harmful ones until none hurt, up to four rounds. 55 callers went through it.

Trees measured:

tree what it adds
main 677469cd2 every caller in cmake/compiler-flags-gl.txt
reimpl/units-B-development (our Map::Units branch, contains main) 28 more files: Map::Units Update functions and their callees
reimpl/units-A-development (our other Map::Units branch) 7 more files: UpdateMerchant, UpdateMerchantHorse and their callees

The list was then checked against main 3458fea34: every name from main resolves there. 22 names are not on main yet. 21 are Map::Units Update functions (UpdateMerchant landed with #409): they were measured on our local branches reimpl/units-B-development and reimpl/units-A-development (UpdateCamel is also on the local reimpl/units-B-round2-100), and gynt's reimpl/map-units-updatefunctions has drafts of all of them. The 22nd is UnitsState::changeDestinationByAmount from #378. A generator would skip them until they land. If you'd rather keep only what is on main, they are easy to take out.

Highlights

  • UpdateDairyFarmer must NOT see getResourceCountThatCanBeDeposited, while addResourceToGranary must. Dairy with its other callees measures 1.0000, and 0.9865 once getResourceCountThatCanBeDeposited is added. addResourceToGranary measures 0.8750 alone and 1.0000 with it. Under /GL both are on the list, so Dairy can't avoid it, which is why it is at 93.9 today.
  • UpdateLady reaches 1.0000 with changeDestinationByAmount, checkIfCitizenUnitIsAliveBasedOnState, hasUnitReachedDestination and makeUnitStopWalkingByClearingPathProgressState. It must not see findNextBuildingForPlayerAndOneOfThreeTypes or findNextBuildingIDForOwnerAndType: with them, it drops to 0.8222.
  • playSFXAtLocation is "must not see" for 13 Map::Units callers. Camel drops from 1.0000 to 0.8706 with it, for example.
  • addBuildingToTargetableBuildings is "must not see" for 16 building Update functions, as the earlier /GL batch already found.
  • The /GL workshop functions (UpdateArmorersWorkshop and friends) need updateVisuallyActiveState. That matches gl-conundrum.md.

Measured gains left out of the file

Twelve callees raised their caller's score but cannot be same-file edges, so they are not in the file:

caller callee why it is left out
UpdateFletchersWorkshop, UpdateBlacksmithsWorkshop, UpdatePoleturnersWorkshop, UpdateArmorersWorkshop, UpdateBakery, UpdateIronMine playSFXAtLocation (0x449DC0) the callee is at a higher address than all six callers (0x412D50-0x41CC70); inside an optimised unit every callee sits at a lower address than its caller (gl-conundrum.md, 3b)
UpdateStables (0x4174E0) AICState::addBuildingToTargetableBuildings (0x4CDA50) the callee is at a higher address than its caller
UpdateMaceman, UpdateTrebuchet, UpdateSlave playSFXAtLocation would put playSFXAtLocation into the Map::Units file, which 13 callers there must not see
UpdateSlave BuildingsState::prepareCampgroundCoords would put it into the Map::Units file, which 5 callers there must not see
UpdateTrebuchet GameSynchronyState::isAIPlayer UpdateCatapult must not see it

So the building Update functions gain from seeing playSFXAtLocation's body, although by the address layout it cannot have been in their file. I haven't found the reason yet.

Some kept edges span huge distances: UpdateInnkeeper (0x540EC0) → getBuildingResourceAmountByUid (0x409330), and UpdatePikeman/UpdateMaceman → ViewportRenderState::xyAreValid at 0x401000. They contradict no other measurement, so they stay. Innkeeper's is confirmed by a build (below). A third, UpdateMerchant → activateTraderState, was removed (update of 2026-11-21).

Known gaps

  • UpdateSlave was not split: its merged unit takes about ten minutes per compile. Its single-callee rows say it must not see changeDestinationByAmount or xyAreValid, which other units need. Those are the only two contradictions left when the file's edges are grouped into units.
  • Edges of unfinished functions are weaker evidence: a body that does not match yet may not leave the same registers alone. The status % of both sides is in the tables below.
  • A callee that is not reimplemented yet cannot be measured, so the list grows as more functions land.
  • Side finding: cmake/compiler-flags-gl.txt on main has six lines for four files that don't exist: takeScreenshot.cpp, determineBuildingPlacementRotation.cpp, and executeDefaultCastleAIV.cpp and findAppropriateGridLocationForBuilding.cpp (twice each).

The static idea

Declaring the Update functions static changes nothing. A static function can't go into MACRO_FUNCTION_RESOLVER as it stands (MSVC 2005 error C2970: an internal-linkage function as a template argument). So the test swapped the resolver's argument for 0 and kept the function alive with an external function pointer, the way a dispatch table would.

function alone alone, static with its /GL callees the same, static
UpdateDairyFarmer (its 12 callees on today's /GL list; the file lists 6) 0.4966 0.4966 0.9865 0.9865
UpdateDairyFarmer (the same 12 without getResourceCountThatCanBeDeposited) 0.4966 0.4966 1.0000 1.0000
UpdateAppleFarmer 0.4879 0.4879 0.9167 0.9167
UpdateHopsFarmer 0.5950 0.5950 0.9971 0.9971
UpdateCamel 0.7941 0.7941 1.0000 1.0000
UpdateSiegeTent 1.0000 1.0000 - -
UpdateHorseArcher_DoShooting 0.9882 0.9882 - -

Does a wrapper build reproduce /GL?

Yes, so far. #399 builds on this PR and adds the generator gynt suggested: cmake/function-visibility-units.py and an option, -DOPENSHC_FUNCTION_VISIBILITY_UNITS=ON, off by default. It groups each caller with its callees (one group per connected set, since a function is defined once), writes one wrapper .cpp per group that #includes the members, and builds the wrappers instead of the members, without /GL.

Built with the file as first posted (87 entries, before the updates above) on our Map::Units development branch, which contains main and its /GL list: 24 wrappers holding 124 files, no build failures, and it links. Against the /GL build of the same code, 2,247 of 2,254 functions are identical, 7 are better and none is worse. All 2,107 functions at 100% stay at 100%.

better than under /GL /GL wrappers
UpdateDairyFarmer 93.9 100
UpdateSlave 81.8 88.8
UpdateMerchantHorse 51.5 72.5
UpdateMerchant 70.1 76.7
UpdateAppleFarmer 85.1 87.7
Constructor_Menu 98.4 100
handleMenuItems 97.9 100

This PR is only the list; the build doesn't read it.

The measurements

Single-callee rows: the caller alone, then with that one callee pasted in before it ("callee first") and after it ("callee after"). Scores are quick_diff ratios; % is each function's status.

Must not see (69 pairs)
caller caller % callee callee % alone callee first callee after tree
Audio::SFX::SFXState::playUnitSpeech 100.0 Audio::SFX::SFXState::playUnitSpeechEffect 100.0 0.9785 0.9713 0.9713 main
Map::Buildings::BuildingsState::canUnitReachBuildingPerimeter 100.0 Map::Units::UnitsState::selectionContainsOnlyArabAssassins 100.0 0.7731 0.5738 0.5738 main
Map::Buildings::BuildingsState::lightUpBuilding 100.0 Map::Buildings::BuildingsState::getBuildingFlammabilityFactor 100.0 - - - main, with the other callees
Map::Buildings::BuildingsState::lightUpBuilding 100.0 Map::Entities::EntityState::getFireEntityIDAtTile 100.0 0.9231 0.68 0.68 main
Map::Buildings::UpdateApothecary 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 1.0 0.7929 0.7929 main
Map::Buildings::UpdateArmorersWorkshop 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 0.3967 0.3204 0.3204 main
Map::Buildings::UpdateBadBuildingBurningStake 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 1.0 0.7891 0.7891 main
Map::Buildings::UpdateBadBuildingGallows 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 0.9076 0.6949 0.6949 main
Map::Buildings::UpdateBadBuildingGibbet 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 1.0 0.8539 0.8539 main ea63a49d9
Map::Buildings::UpdateBadBuildingStretchingRack 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 1.0 0.7407 0.7407 main ea63a49d9
Map::Buildings::UpdateBakery 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 0.3498 0.2667 0.2667 main
Map::Buildings::UpdateBlacksmithsWorkshop 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 0.3593 0.3167 0.3167 main
Map::Buildings::UpdateFireBallistaBuilding 100.0 AI::AICState::generateSiegeCreationInformation 100.0 0.9893 0.6266 0.6266 main
Map::Buildings::UpdateFireBallistaBuilding 100.0 Map::Buildings::BuildingsState::destroyBuilding 100.0 0.9936 0.9893 0.9936 main
Map::Buildings::UpdateFireBallistaBuilding 100.0 Map::Units::TribesState::addUnitToNewTribe 100.0 0.9936 0.9893 0.9936 main
Map::Buildings::UpdateFireBallistaBuilding 100.0 Synchrony::GameSynchronyState::getLordTypeForPlayer 100.0 0.9936 0.8043 0.8043 main
Map::Buildings::UpdateFletchersWorkshop 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 0.4282 0.411 0.411 main
Map::Buildings::UpdateGoodBuildingDancingBear 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 1.0 0.6849 0.6849 main
Map::Buildings::UpdateGoodBuildingMaypole 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 0.973 0.9524 0.9524 main
Map::Buildings::UpdateHopsFarm 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 1.0 0.8504 0.8504 main
Map::Buildings::UpdateInn 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 0.4213 0.3959 0.3959 main
Map::Buildings::UpdateIronMine 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 0.4407 0.3759 0.3759 main
Map::Buildings::UpdatePoleturnersWorkshop 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 0.4 0.3906 0.3906 main
Map::Buildings::UpdateWheatFarm 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 1.0 0.8504 0.8504 main
Map::Units::UpdateAppleFarmer 85.1 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.4879 0.446 0.446 dev
Map::Units::UpdateAppleFarmer 85.1 Game::GameStateStructures::setLastEncounteredTroopUnit 100.0 - - - dev, with the other callees
Map::Units::UpdateAppleFarmer 85.1 Map::Buildings::BuildingsState::getResourceCountThatCanBeDeposited 100.0 0.4879 0.4768 0.4768 dev
Map::Units::UpdateArabianSwordsman 82.9 Audio::SFX::SFXState::playSFXAtLocation 100.0 - - - dev, with the other callees
Map::Units::UpdateArabianSwordsman 82.9 Map::Buildings::BuildingsState::prepareCampgroundCoords 100.0 - - - dev, with the other callees
Map::Units::UpdateArabianSwordsman 82.9 Map::Units::UnitsState::playHurtSFXForUnit 100.0 - - - dev, with the other callees
Map::Units::UpdateArabianSwordsman 82.9 Random::RNG::nextRandomNumber1 100.0 - - - dev, with the other callees
Map::Units::UpdateAssassin 82.5 Audio::SFX::SFXState::playSFXAtLocation 100.0 - - - dev, with the other callees
Map::Units::UpdateAssassin 82.5 Map::Buildings::BuildingsState::prepareCampgroundCoords 100.0 0.516 0.4819 0.4819 dev
Map::Units::UpdateAssassin 82.5 Map::Units::UnitsState::playHurtSFXForUnit 100.0 - - - dev, with the other callees
Map::Units::UpdateBallista 85.9 Audio::SFX::SFXState::playSFXAtLocation 100.0 - - - dev, with the other callees
Map::Units::UpdateCamel 100.0 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.7941 0.7162 0.7162 dev
Map::Units::UpdateCatapult 76.6 AI::AICState::yieldCowThrow 100.0 - - - dev, with the other callees
Map::Units::UpdateCatapult 76.6 Audio::SFX::SFXState::playSFXAtLocation 100.0 - - - dev, with the other callees
Map::Units::UpdateCatapult 76.6 Synchrony::GameSynchronyState::isAIPlayer 100.0 - - - dev, with the other callees
Map::Units::UpdateDairyFarmer 93.9 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.4966 0.4716 0.4716 dev
Map::Units::UpdateDairyFarmer 93.9 Game::GameStateStructures::setLastEncounteredTroopUnit 100.0 - - - dev, with the other callees
Map::Units::UpdateDairyFarmer 93.9 Map::Buildings::BuildingsState::getResourceCountThatCanBeDeposited 100.0 0.4966 0.4357 0.4357 dev
Map::Units::UpdateFireBallista 83.3 Audio::SFX::SFXState::playSFXAtLocation 100.0 - - - dev, with the other callees
Map::Units::UpdateHopsFarmer 99.7 Game::GameStateStructures::setLastEncounteredTroopUnit 100.0 - - - dev, with the other callees
Map::Units::UpdateHopsFarmer 99.7 Map::Buildings::BuildingsState::canBuildingStoreTheAmount 100.0 0.595 0.5902 0.5902 dev
Map::Units::UpdateHorseArcher 85.1 Audio::SFX::SFXState::playSFXAtLocation 100.0 - - - dev, with the other callees
Map::Units::UpdateHorseArcher 85.1 Map::Buildings::BuildingsState::prepareCampgroundCoords 100.0 0.4818 0.4775 0.4775 dev
Map::Units::UpdateHorseArcher 85.1 Map::Units::UpdateHorseArcher_DoShooting 100.0 - - - dev, with the other callees
Map::Units::UpdateKnight 84.6 Audio::SFX::SFXState::playSFXAtLocation 100.0 - - - dev, with the other callees
Map::Units::UpdateKnight 84.6 Map::Buildings::BuildingsState::prepareCampgroundCoords 100.0 - - - dev, with the other callees
Map::Units::UpdateKnight 84.6 Map::Units::UnitsState::playHurtSFXForUnit 100.0 - - - dev, with the other callees
Map::Units::UpdateLady 100.0 Map::Buildings::BuildingsState::findNextBuildingForPlayerAndOneOfThreeTypes 100.0 0.7341 0.5084 0.5084 dev
Map::Units::UpdateLady 100.0 Map::Buildings::BuildingsState::findNextBuildingIDForOwnerAndType 100.0 0.7341 0.7043 0.7043 dev
Map::Units::UpdateMaceman 77.7 Map::Units::UnitsState::playHurtSFXForUnit 100.0 - - - dev, with the other callees
Map::Units::UpdateMangonel 72.1 Audio::SFX::SFXState::playSFXAtLocation 100.0 - - - dev, with the other callees
Map::Units::UpdateMerchantHorse 64.9 Game::GameStateStructures::resetTraderState 100.0 - - - A, with the other callees
Map::Units::UpdatePikeman 69.9 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.4014 0.3396 0.3396 dev
Map::Units::UpdatePikeman 69.9 Map::Units::UnitsState::playHurtSFXForUnit 100.0 - - - dev, with the other callees
Map::Units::UpdateQuarryMason 100.0 Game::GameStateStructures::setLastEncounteredTroopUnit 100.0 - - - main, with the other callees
Map::Units::UpdateSlave 81.8 Map::Buildings::BuildingsState::getBuildingFlammabilityFactor 100.0 0.5248 0.4007 0.4007 dev
Map::Units::UpdateSlave 81.8 Map::Units::UnitsState::changeDestinationByAmount 100.0 0.5248 0.5239 0.5239 dev
Map::Units::UpdateSlave 81.8 Rendering::ViewportRenderState::xyAreValid 100.0 0.5248 0.5099 0.5099 dev
Map::Units::UpdateSwordsman 81.0 Audio::SFX::SFXState::playSFXAtLocation 100.0 - - - dev, with the other callees
Map::Units::UpdateSwordsman 81.0 Map::Buildings::BuildingsState::prepareCampgroundCoords 100.0 0.4451 0.4375 0.4375 dev
Map::Units::UpdateSwordsman 81.0 Map::Units::UnitsState::playHurtSFXForUnit 100.0 - - - dev, with the other callees
Map::Units::UpdateSwordsman 81.0 Random::RNG::nextRandomNumber1 100.0 - - - dev, with the other callees
Map::Units::UpdateTrebuchet 76.8 AI::AICState::yieldCowThrow 100.0 - - - dev, with the other callees
Synchrony::GameSynchronyState::receiveAllTransmittedCommands 100.0 IO::LowLevelMemory::moveLowerThreeBytesIntoParam2 100.0 0.963 0.7943 0.7943 main
UI::MenuItems::ChooseRandomNumberOfEnemies::MenuItemRenderFunction_ChooseRandomNumberOfEnemies_Main 100.0 Audio::SFX::SFXState::scheduleSFXVariation 100.0 0.6301 0.5333 0.5333 main
Hurt alone, needed together with the caller's other callees (10 pairs)
caller caller % callee callee % alone callee first callee after tree
Map::Units::UpdateBallista 85.9 Map::Units::UnitsState::deselectUnit 100.0 0.5516 0.4818 0.4818 dev
Map::Units::UpdateBurningMan 100.0 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.7373 0.627 0.627 main
Map::Units::UpdateDairyFarmer 93.9 Map::Units::CheckUnitProductionPaused 100.0 0.4966 0.4951 0.4951 dev
Map::Units::UpdateDairyFarmer 93.9 Map::Units::SetStateToFreetimeWalking 100.0 0.4966 0.4412 0.4412 dev
Map::Units::UpdateDairyFarmer 93.9 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.4966 0.4602 0.4602 dev
Map::Units::UpdateJuggler 83.5 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.7433 0.7059 0.7059 dev
Map::Units::UpdateLady 100.0 Map::Units::UnitsState::changeDestinationByAmount 100.0 0.7341 0.6974 0.6974 dev
Map::Units::UpdateMaceman 77.7 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.426 0.4101 0.4101 dev
Map::Units::UpdateTrebuchet 76.8 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.6067 0.5933 0.5933 dev
Map::Units::UpdateTrebuchet 76.8 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.6067 0.5961 0.5961 dev
Gained, one callee at a time (143 pairs, including the 12 left out above)
caller caller % callee callee % alone callee first callee after tree
Game::GameStateStructures::clearEnemyRelatedStructures 100.0 Game::GameStateStructures::setVariousGameStateToInitialValues 100.0 0.9811 0.9858 0.9858 main
Game::GameStateStructures::getSalesPrice 100.0 Game::GameStateStructures::getSellResourceAmount 100.0 0.6842 1.0 1.0 main
IO::DecoderState::decodeData 100.0 IO::LowLevelMemory::copyData 100.0 0.9913 1.0 1.0 main
IO::DecoderState::encodeData 100.0 IO::LowLevelMemory::copyData 100.0 0.9756 1.0 1.0 main
IO::ResourceManager::readFirstPartOfCurrentResourceIntoMemory 100.0 IO::LowLevelMemory::putFileNameAndAppendFileExtension 100.0 0.98 1.0 1.0 main
IO::ResourceManager::readNextPartOfCurrentResourceIntoMemory 100.0 IO::LowLevelMemory::putFileNameAndAppendFileExtension 100.0 0.9821 1.0 1.0 main
IO::ResourceManager::swapMapDataWithNextMap 100.0 IO::LowLevelMemory::copyData 100.0 0.9867 1.0 1.0 main
Input::MouseState::updateRightDragCameraControl 100.0 Map::Navigation::DirectionAlgorithmState::getMouseVectorLengthBasedOnDirection 100.0 0.3636 0.994 0.994 main
Map::Buildings::BuildingsState::addResourceToArmory 100.0 Map::Buildings::BuildingsState::getArmoryIDIfSpaceLeft 100.0 0.642 1.0 1.0 main
Map::Buildings::BuildingsState::addResourceToGranary 100.0 Map::Buildings::BuildingsState::getResourceCountThatCanBeDeposited 100.0 0.875 1.0 1.0 main
Map::Buildings::BuildingsState::addResourceToStockpile 100.0 Map::Buildings::BuildingsState::extendResourceCountdownForPlayerBuildingsOfType 100.0 0.9929 1.0 1.0 main
Map::Buildings::BuildingsState::buildingIsAccessible 100.0 Map::Buildings::BuildingsState::getBuildingHeightForBuildingID 100.0 0.6079 1.0 1.0 main
Map::Buildings::BuildingsState::canUnitReachBuildingPerimeter 100.0 Map::Buildings::BuildingsState::getBuildingHeightForBuildingID 100.0 0.7731 1.0 1.0 main
Map::Buildings::BuildingsState::destroyBuildingAndLinkedDuplicates 100.0 Map::Buildings::BuildingsState::destroySignpostData 100.0 0.6875 0.9375 0.9375 main
Map::Buildings::BuildingsState::findAccessibleAreaNearBuildingLocation 100.0 Map::Buildings::BuildingsState::setupBuildingEntrancesOffset 100.0 0.6914 1.0 1.0 main
Map::Buildings::BuildingsState::findParticularBuilding 100.0 Map::Buildings::BuildingsState::setupBuildingEntrancesOffset 100.0 0.5766 1.0 1.0 main
Map::Buildings::BuildingsState::getBuildingCost 100.0 Map::Buildings::BuildingsState::convertCommandBuildingTypeToBuildingType 100.0 0.5276 1.0 1.0 main
Map::Buildings::BuildingsState::getResourceSpace 100.0 Map::Buildings::BuildingsState::getBuildingStorageTypeForResourceType 100.0 0.7674 0.9586 0.9586 main
Map::Buildings::BuildingsState::getResourceSpace 100.0 Map::Buildings::BuildingsState::getResourceCountThatCanBeDeposited 100.0 0.7674 0.8655 0.8655 main
Map::Buildings::BuildingsState::getSpriteID2 100.0 Map::Buildings::BuildingsState::convertCommandBuildingTypeToBuildingType 100.0 0.4167 1.0 1.0 main
Map::Buildings::BuildingsState::getStorageBuildingForResourceTypeAndAmount 100.0 Map::Buildings::BuildingsState::getBuildingStorageTypeForResourceType 100.0 0.5882 1.0 1.0 main
Map::Buildings::BuildingsState::hasBuildingAsNeighbour 100.0 Map::Buildings::BuildingsState::setupBuildingEntrancesOffset 100.0 0.672 1.0 1.0 main
Map::Buildings::BuildingsState::lightUpBuilding 100.0 Map::Buildings::BuildingsState::getBuildingFlammabilityFactor 100.0 0.9231 0.9512 0.9512 main
Map::Buildings::BuildingsState::processResourceLoss 100.0 Map::Buildings::BuildingsState::getBuildingStorageTypeForResourceType 100.0 0.744 1.0 1.0 main
Map::Buildings::BuildingsState::updateNeededEmployeeCount 100.0 Map::Buildings::BuildingsState::hasWorker 100.0 0.5965 1.0 1.0 main
Map::Buildings::UpdateArmorersWorkshop 100.0 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.3967 0.5873 0.5873 main
Map::Buildings::UpdateArmorersWorkshop 100.0 Map::Buildings::BuildingsState::updateVisuallyActiveState 100.0 0.3967 0.9945 0.9945 main
Map::Buildings::UpdateBadBuildingDungeon 100.0 Map::Buildings::BuildingsState::updateBuildingSignpostCounter 100.0 0.9643 1.0 1.0 main
Map::Buildings::UpdateBadBuildingGallows 100.0 Map::Buildings::BuildingsState::updateBuildingSignpostCounter 100.0 0.9076 0.9661 0.9661 main
Map::Buildings::UpdateBakery 100.0 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.3498 0.5725 0.5725 main
Map::Buildings::UpdateBakery 100.0 Map::Buildings::BuildingsState::updateVisuallyActiveState 100.0 0.3498 0.9961 0.9961 main
Map::Buildings::UpdateBlacksmithsWorkshop 100.0 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.3593 0.8202 0.8202 main
Map::Buildings::UpdateBlacksmithsWorkshop 100.0 Map::Buildings::BuildingsState::updateVisuallyActiveState 100.0 0.3593 0.9979 0.9979 main
Map::Buildings::UpdateFletchersWorkshop 100.0 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.4282 0.7748 0.7748 main
Map::Buildings::UpdateFletchersWorkshop 100.0 Map::Buildings::BuildingsState::updateVisuallyActiveState 100.0 0.4282 0.9954 0.9954 main
Map::Buildings::UpdateInn 100.0 Map::Buildings::BuildingsState::updateVisuallyActiveState 100.0 0.4213 1.0 1.0 main
Map::Buildings::UpdateIronMine 100.0 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.4407 0.7415 0.7415 main
Map::Buildings::UpdateIronMine 100.0 Map::Buildings::BuildingsState::getBuildingResourceAmountByUid 100.0 0.4407 1.0 1.0 main
Map::Buildings::UpdatePoleturnersWorkshop 100.0 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.4 0.7864 0.7864 main
Map::Buildings::UpdatePoleturnersWorkshop 100.0 Map::Buildings::BuildingsState::updateVisuallyActiveState 100.0 0.4 0.9966 0.9966 main
Map::Buildings::UpdateStables 100.0 AI::AICState::addBuildingToTargetableBuildings 100.0 0.6642 0.6894 0.6894 main
Map::Buildings::UpdateStables 100.0 Map::Buildings::BuildingsState::validateBuildingTetheredUnits 100.0 0.6642 1.0 1.0 main
Map::TileMapState::updateMoatCountdownTimers 100.0 Map::TileMapState::recountTotalOwnedMoats 100.0 0.5128 1.0 1.0 main
Map::Units::UpdateAppleFarmer 85.1 Game::GameStateStructures::setLastEncounteredTroopUnit 100.0 0.4879 0.5023 0.5023 dev
Map::Units::UpdateAppleFarmer 85.1 Map::Units::ComputeGoodsProduced 100.0 0.4879 0.5145 0.5145 dev
Map::Units::UpdateAppleFarmer 85.1 Map::Units::IncrementAndOptionalUpdateAVValueRelated 100.0 0.4879 0.6971 0.6971 dev
Map::Units::UpdateAppleFarmer 85.1 Map::Units::SetStateToFreetimeWalking 100.0 0.4879 0.5796 0.5796 dev
Map::Units::UpdateAppleFarmer 85.1 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.4879 0.5372 0.5372 dev
Map::Units::UpdateAppleFarmer 85.1 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.4879 0.5034 0.5034 dev
Map::Units::UpdateArabianSwordsman 82.9 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.4309 0.4607 0.4607 dev
Map::Units::UpdateArabianSwordsman 82.9 Map::Buildings::BuildingsState::prepareCampgroundCoords 100.0 0.4309 0.5079 0.5079 dev
Map::Units::UpdateArabianSwordsman 82.9 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.4309 0.8786 0.8786 dev
Map::Units::UpdateArabianSwordsman 82.9 Random::RNG::nextRandomNumber1 100.0 0.4309 0.7192 0.7192 dev
Map::Units::UpdateAssassin 82.5 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.516 0.7625 0.7625 dev
Map::Units::UpdateAssassin 82.5 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.516 0.869 0.869 dev
Map::Units::UpdateBallista 85.9 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.5516 0.6081 0.6081 dev
Map::Units::UpdateBallista 85.9 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.5516 0.8848 0.8848 dev
Map::Units::UpdateBurningMan 100.0 Map::Units::UnitsState::hasTunnelerNotFinishedDigging 100.0 0.7373 0.7668 0.7668 main
Map::Units::UpdateCamel 100.0 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.7941 0.9835 0.9835 dev
Map::Units::UpdateCamel 100.0 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.7941 0.8099 0.8099 dev
Map::Units::UpdateCatapult 76.6 Map::Units::UnitsState::deselectUnit 100.0 0.503 0.5564 0.5564 dev
Map::Units::UpdateCatapult 76.6 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.503 0.8071 0.8071 dev
Map::Units::UpdateDairyFarmer 93.9 Game::GameStateStructures::setLastEncounteredTroopUnit 100.0 0.4966 0.5152 0.5152 dev
Map::Units::UpdateDairyFarmer 93.9 Map::Units::ComputeGoodsProduced 100.0 0.4966 0.5585 0.5585 dev
Map::Units::UpdateDairyFarmer 93.9 Map::Units::IncrementAndOptionalUpdateAVValueRelated 100.0 0.4966 0.6973 0.6973 dev
Map::Units::UpdateDairyFarmer 93.9 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.4966 0.5449 0.5449 dev
Map::Units::UpdateDrunkard 100.0 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.6162 0.9316 0.9316 main
Map::Units::UpdateDrunkard 100.0 Map::Units::UnitsState::hasTunnelerNotFinishedDigging 100.0 0.6162 0.6345 0.6345 main
Map::Units::UpdateFireBallista 83.3 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.639 0.7179 0.7179 dev
Map::Units::UpdateFireBallista 83.3 Map::Units::UnitsState::deselectUnit 100.0 0.639 0.6729 0.6729 dev
Map::Units::UpdateFireBallista 83.3 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.639 0.7985 0.7985 dev
Map::Units::UpdateFireEater 100.0 Map::Units::UnitsState::changeDestinationByAmount 100.0 0.5336 0.5436 0.5436 dev
Map::Units::UpdateFireEater 100.0 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.5336 0.9365 0.9365 dev
Map::Units::UpdateFireEater 100.0 Map::Units::UnitsState::hasTunnelerNotFinishedDigging 100.0 0.5336 0.7762 0.7762 dev
Map::Units::UpdateFireEater 100.0 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.5336 0.7118 0.7118 dev
Map::Units::UpdateHopsFarmer 99.7 Game::GameStateStructures::setLastEncounteredTroopUnit 100.0 0.595 0.6359 0.6359 dev
Map::Units::UpdateHopsFarmer 99.7 Map::Units::ComputeGoodsProduced 100.0 0.595 0.6268 0.6268 dev
Map::Units::UpdateHopsFarmer 99.7 Map::Units::IncrementAndOptionalUpdateAVValueRelated 100.0 0.595 0.7676 0.7676 dev
Map::Units::UpdateHopsFarmer 99.7 Map::Units::SetStateToFreetimeWalking 100.0 0.595 0.668 0.668 dev
Map::Units::UpdateHopsFarmer 99.7 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.595 0.6437 0.6437 dev
Map::Units::UpdateHopsFarmer 99.7 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.595 0.6187 0.6187 dev
Map::Units::UpdateHorseArcher 85.1 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.4818 0.7478 0.7478 dev
Map::Units::UpdateHorseArcher 85.1 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.4818 0.8953 0.8953 dev
Map::Units::UpdateInnkeeper 100.0 Map::Buildings::BuildingsState::getBuildingResourceAmountByUid 100.0 0.55 0.5703 0.5703 main
Map::Units::UpdateInnkeeper 100.0 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.55 0.6314 0.6314 main
Map::Units::UpdateInnkeeper 100.0 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.55 0.9119 0.9119 main
Map::Units::UpdateJuggler 83.5 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.7433 0.905 0.905 dev
Map::Units::UpdateJuggler 83.5 Map::Units::UnitsState::hasTunnelerNotFinishedDigging 100.0 0.7433 0.75 0.75 dev
Map::Units::UpdateKnight 84.6 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.497 0.7583 0.7583 dev
Map::Units::UpdateKnight 84.6 Map::Buildings::BuildingsState::prepareCampgroundCoords 100.0 0.497 0.5024 0.5024 dev
Map::Units::UpdateKnight 84.6 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.497 0.8985 0.8985 dev
Map::Units::UpdateLady 100.0 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.7341 0.82 0.82 dev
Map::Units::UpdateLady 100.0 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.7341 0.778 0.778 dev
Map::Units::UpdateLady 100.0 Map::Units::UnitsState::makeUnitStopWalkingByClearingPathProgressState 100.0 0.7341 0.7452 0.7452 dev
Map::Units::UpdateMaceman 77.7 Map::Units::UnitsState::changeDestinationByAmount 100.0 0.426 0.4268 0.4268 dev
Map::Units::UpdateMaceman 77.7 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.426 0.7454 0.7454 dev
Map::Units::UpdateMaceman 77.7 Rendering::ViewportRenderState::xyAreValid 100.0 0.426 0.4447 0.4447 dev
Map::Units::UpdateMangonel 72.1 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.6073 0.6767 0.6767 dev
Map::Units::UpdateMangonel 72.1 Map::Units::UnitsState::deselectUnit 100.0 0.6073 0.6313 0.6313 dev
Map::Units::UpdateMangonel 72.1 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.6073 0.7815 0.7815 dev
Map::Units::UpdateMerchant 93.8 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.8285 0.9478 0.9478 A
Map::Units::UpdateMerchant 93.8 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.8285 0.8482 0.8482 A
Map::Units::UpdateMerchantHorse 64.9 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.6751 0.7146 0.7146 A
Map::Units::UpdateMerchantHorse 64.9 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.6751 0.7484 0.7484 A
Map::Units::UpdateMiner 100.0 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.7124 0.9211 0.9211 main
Map::Units::UpdatePikeman 69.9 Map::Buildings::BuildingsState::prepareCampgroundCoords 100.0 0.4014 0.4242 0.4242 dev
Map::Units::UpdatePikeman 69.9 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.4014 0.7233 0.7233 dev
Map::Units::UpdatePikeman 69.9 Rendering::ViewportRenderState::xyAreValid 100.0 0.4014 0.4446 0.4446 dev
Map::Units::UpdateQuarryMason 100.0 Game::GameStateStructures::setLastEncounteredTroopUnit 100.0 0.8078 0.8098 0.8098 main
Map::Units::UpdateQuarryMason 100.0 Map::Units::UnitsState::checkIfCitizenUnitIsAliveBasedOnState 100.0 0.8078 1.0 1.0 main
Map::Units::UpdateSlave 81.8 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.5248 0.5497 0.5497 dev
Map::Units::UpdateSlave 81.8 Map::Buildings::BuildingsState::prepareCampgroundCoords 100.0 0.5248 0.5894 0.5894 dev
Map::Units::UpdateSlave 81.8 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.5248 0.8675 0.8675 dev
Map::Units::UpdateSwordsman 81.0 Audio::SFX::SFXState::playSFXAtLocation 100.0 0.4451 0.6088 0.6088 dev
Map::Units::UpdateSwordsman 81.0 Map::Units::UnitsState::hasUnitReachedDestination 100.0 0.4451 0.8604 0.8604 dev
Map::Units::UpdateSwordsman 81.0 Random::RNG::nextRandomNumber1 100.0 0.4451 0.7194 0.7194 dev
Map::Units::UpdateTrebuchet 76.8 AI::AICState::yieldCowThrow 100.0 0.6067 0.6555 0.6555 dev
Map::Units::UpdateTrebuchet 76.8 Map::Units::UnitsState::deselectUnit 100.0 0.6067 0.6649 0.6649 dev
Map::Units::UpdateTrebuchet 76.8 Synchrony::GameSynchronyState::isAIPlayer 100.0 0.6067 0.718 0.718 dev
Synchrony::GameSynchronyState::processSyncPacket 100.0 Synchrony::GameSynchronyState::translateMultiplayerIDsIntoPlayerIDs 100.0 0.2667 1.0 1.0 main
Synchrony::GameSynchronyState::receiveAllTransmittedCommands 100.0 Synchrony::GameSynchronyState::translateMultiplayerIDsIntoPlayerIDs 100.0 0.963 0.9657 0.9657 main
UI::HoveredState::Constructor_HoveredState 100.0 UI::HoveredState::clearHoveredState 100.0 0.4 1.0 1.0 main
UI::MenuItems::BuildMenu::MenuItemActionHandler_BuildMenu_UnitActionButtons 100.0 UI::Helpers::SetTribesPatrolButtonPressed 100.0 0.8645 0.9032 0.9032 main
UI::MenuItems::BuildingAndStatusMenu::MenuItemActionHandler_BuildingAndStatusMenu_BarrackUnitPortraits 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.9036 1.0 1.0 main
UI::MenuItems::BuildingAndStatusMenu::MenuItemRenderFunction_BuildingAndStatusMenu_BarracksWeaponAvailability 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.3699 1.0 1.0 main
UI::MenuItems::BuildingAndStatusMenu::MenuItemRenderFunction_BuildingAndStatusMenu_DrawbridgeOpenClose 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.6575 1.0 1.0 main
UI::MenuItems::BuildingAndStatusMenu::MenuItemRenderFunction_BuildingAndStatusMenu_EngineerAndMonkPortraits 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.6015 1.0 1.0 main
UI::MenuItems::BuildingAndStatusMenu::MenuItemRenderFunction_BuildingAndStatusMenu_GatehouseOpenClose 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.6575 1.0 1.0 main
UI::MenuItems::BuildingAndStatusMenu::MenuItemRenderFunction_BuildingAndStatusMenu_GeneralButtonRender 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.5098 1.0 1.0 main
UI::MenuItems::BuildingAndStatusMenu::MenuItemRenderFunction_BuildingAndStatusMenu_MercenaryPostPortraits 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.9029 1.0 1.0 main
UI::MenuItems::BuildingAndStatusMenu::MenuItemRenderFunction_BuildingAndStatusMenu_SelectBuySellGoods 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.5634 1.0 1.0 main
UI::MenuItems::BuildingAndStatusMenu::MenuItemRenderFunction_BuildingAndStatusMenu_TunnelerPortrait 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.6015 1.0 1.0 main
UI::MenuItems::BuildingAndStatusMenu::MenuItemRenderFunction_BuildingAndStatusMenu_WorkshopWeaponSelection 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.6565 1.0 1.0 main
UI::MenuItems::ChooseRandomNumberOfEnemies::MenuItemRenderFunction_ChooseRandomNumberOfEnemies_Main 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.6301 1.0 1.0 main
UI::MenuItems::General::MenuItemRenderFunction_General_RenderCurrentButtonWithPossibleAlphaTexOnScreenMenuSurface 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.7455 1.0 1.0 main
UI::MenuItems::MapEditorLandscaping::MenuItemRenderFunction_MapEditorLandscaping_GeneralButtons 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.7024 0.9596 0.9596 main
UI::Rendering::RenderButtonImageWithBlending 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.6602 1.0 1.0 main
UI::Rendering::RenderCurrentButtonOnScreenMenu 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.5098 1.0 1.0 main
UI::Rendering::RenderCurrentButtonToScreenMenuWithBlendingUnk 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.2034 1.0 1.0 main
UI::Rendering::RenderCurrentNotActiveButtonWithPossibleAlphaTexOnCurrentSurfaceUnk 100.0 UI::Rendering::ButtonGmData::getPictureNumberInGm 100.0 0.5806 1.0 1.0 main
UI::Rendering::TextureRenderCore::renderGmWithPreparedAlphaMask 100.0 UI::Rendering::InitBlendFilterArraysUnk 100.0 0.8258 0.8303 0.8303 main
UI::Rendering::TextureRenderCore::renderInterfaceOrBuildingOccupationArea 100.0 UI::Rendering::InitBlendFilterArraysUnk 100.0 0.827 0.8447 0.8447 main
UI::Rendering::TextureRenderCore::transformTilesetToRGB565 100.0 UI::Rendering::TextureRenderCore::transformTileObjectToRGB565 100.0 0.4167 1.0 1.0 main

The leave-one-out rounds of the 55 callers and the 259 pairs with no effect don't fit here; I can post them as a comment.

🤖 Generated with Claude Code

… bodies

One entry per caller, with the callees whose bodies it must see when it is
compiled, fully qualified as the definitions are written:

    OpenSHC::funcA
        OpenSHC::funcB

87 entries, 127 edges, sorted by the caller's address. Every edge is a
tu_merge.py measurement: pasting the callee into the caller's unit raises the
caller's quick_diff ratio, and for callers with several callees a leave-one-out
over the full set decided which are needed together. In all 127 the callee is
at a lower address than its caller.

Twelve measured gains are left out because they cannot be same-file edges:
in seven the callee is at a higher address than its caller, and the other
five would put a callee into a unit with callers that measure worse when they
see it.

23 names are not on main yet. 22 are Map::Units Update callers: they were
measured on our local branches reimpl/units-B-development and
reimpl/units-A-development (UpdateCamel is also on the local
reimpl/units-B-round2-100), and gynt's reimpl/map-units-updatefunctions has
drafts of all 22. The 23rd is UnitsState::changeDestinationByAmount from sourcehold#378.
A generator skips names it cannot find. The measurements are in the PR
description.

Co-authored-by: Gynt <gynt@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
kotijekriv and others added 2 commits November 14, 2026 00:14
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…tCounter's body

sourcehold#290 rewrote UpdateBadBuildingGibbet and UpdateBadBuildingStretchingRack so that they reach 100% without /GL. On
main (ea63a49), tu_merge.py gives both 1.0000 in all three layouts: the caller alone, the callee's body pasted
before it, and pasted after it (45 of 45 and 41 of 41 instructions). Seeing updateBuildingSignpostCounter no longer
helps either of them, so their two entries go. The callee keeps its other two callers, UpdateBadBuildingGallows and
UpdateBadBuildingDungeon.

The manifest now has 85 entries and 125 edges. On main's sources the wrapper generator from sourcehold#399 makes 24 units
holding 91 source files (93 before), with no internal-name clashes and the same 23 names not on main yet.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kotijekriv

Copy link
Copy Markdown
Contributor Author

Updated after #290: I merged main in (a731ab3), then dropped two entries (6ba3369). UpdateBadBuildingGibbet and UpdateBadBuildingStretchingRack now reach 100% with or without updateBuildingSignpostCounter's body, so those two edges are gone, and the list has 85 entries and 125 edges. Their "must not see addBuildingToTargetableBuildings" rows still hold on the new code: with that body they drop to 0.8539 and 0.7407. #399 builds its wrappers from this list, so it only needed the new head (61ef05f). The description has the updated numbers.

kotijekriv and others added 2 commits November 21, 2026 00:44
The entry for UpdateMerchant listed GameStateStructures::activateTraderState. That edge was measured on a 93.8%
draft of UpdateMerchant. The function has since landed on main at 100% (sourcehold#409), and it reaches that under /GL
without the body: activateTraderState.cpp is not on the /GL list. With the body in its unit the caller keeps the
unit slot in esi across the call, where the original reads it again, so the original's caller did not know it.

Measured on main 3458fea with sourcehold#399's wrapper build (-DOPENSHC_FUNCTION_VISIBILITY_UNITS=ON), reccmp, raw:
UpdateMerchant reads 100.0 under /GL, 90.0 with the wrappers before this change and 100.0 after it. It was the only
one of the 150 functions in that build (main's /GL list plus every file the manifest names) whose raw number
differed between /GL and the wrappers, and none differs now.

The manifest now has 85 entries and 124 edges. On main's sources the generator makes 24 units holding 92 source
files (93 before).

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
UpdateTrebuchet (0x00569410) calls GameSynchronyState::isAIPlayer twice, at 0x0056A05B and 0x0056A124. Behind each
call the original pushes ebx, the unit slot it read from 0xEE0FC8, without reading the slot again (0x0056A068,
0x0056A12D); behind the next call, to 0x00465F20, it reads it again (0x0056A06F, 0x0056A134). So the original's
caller knew that isAIPlayer writes no memory, which it can know only from the body.

Measured with tu_merge.py on main 3458fea (in a clone with two UI commits on top, nothing under Map or Synchrony)
plus worker C's UpdateTrebuchet.cpp (6757ed1, at 100% under /GL), every struct and function resolver on,
quick_diff ratio of the caller:

    caller alone                                          0.5440
    isAIPlayer, hasUnitReachedDestination, deselectUnit   0.9818
    hasUnitReachedDestination, deselectUnit               0.9132
    isAIPlayer alone                                      0.5587

(callees first and caller first read the same in each row). Leaving isAIPlayer out lowers the score, so it is needed
together with the other two. isAIPlayer (0x004010B0) is at a lower address than its caller, and it goes first in the
entry, whose callees are sorted by address.

The manifest now has 85 entries and 125 edges. On main's sources the generator from sourcehold#399 makes the same 24 units
holding 92 source files, file for file, since UpdateTrebuchet is not on main. With that UpdateTrebuchet.cpp in the
build, isAIPlayer.cpp joins its unit (24 units holding 95 source files, 94 without the line); no other file in that
unit calls isAIPlayer.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@TheRedDaemon

TheRedDaemon commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Hi @kotijekriv , I merged your other branch. Is this one still relevant?

The manifest itself is on main since sourcehold#399 (02fab42); this branch keeps
one more edge, UpdateTrebuchet -> GameSynchronyState::isAIPlayer.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kotijekriv

Copy link
Copy Markdown
Contributor Author

Thanks for merging #399. This one is down to a single line now: I merged main into it, so against main it only adds the edge UpdateTrebuchet → GameSynchronyState::isAIPlayer to cmake/function-visibility.txt. UpdateTrebuchet comes in #453 and needs that body visible (0.9132 without it, 0.9818 with it in our narrow measurement).

If you'd rather not keep a PR open for one line, I can move it into #453 and close this one. Either way works for us.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants