diff --git a/engine/MUNGA/APP.cpp b/engine/MUNGA/APP.cpp index eee79bf..c42825e 100644 --- a/engine/MUNGA/APP.cpp +++ b/engine/MUNGA/APP.cpp @@ -1369,6 +1369,18 @@ void case CreatingMission: case LoadingMission: case WaitingForLaunch: + // LOAD-PHASE MARKER (2026-07-22): each CheckLoad pass that finds the + // event queue still busy delays the ready transition by its 1s + // re-post -- count them so the teal->green minute is attributable. + if (!eventQueue->IsPriorityEmpty(MinEventPriority)) + { + static int s_busy_passes = 0; + ++s_busy_passes; + if ((s_busy_passes % 5) == 1) + DEBUG_STREAM << "[loadphase] CheckLoad: event queue still busy" + << " (pass " << s_busy_passes << ") t=" << GetTickCount() + << std::endl << std::flush; + } if (eventQueue->IsPriorityEmpty(MinEventPriority)) { Host *console_host; diff --git a/engine/MUNGA_L4/L4VIDEO.cpp b/engine/MUNGA_L4/L4VIDEO.cpp index 4aaac9f..0ce0f71 100644 --- a/engine/MUNGA_L4/L4VIDEO.cpp +++ b/engine/MUNGA_L4/L4VIDEO.cpp @@ -9607,6 +9607,23 @@ void DPLRenderer::SetViewAngle(Degree new_angle) void DPLRenderer::LoadMissionImplementation(Mission *mission) { + // LOAD-PHASE MARKER (2026-07-22): the teal->green minute is almost all + // unattributed (models are ~0.2s of ~58s measured) -- stamp the + // renderer-side load so the next run names its share. + struct BTPhaseTimer + { + unsigned long t0; + BTPhaseTimer() : t0(GetTickCount()) + { + DEBUG_STREAM << "[loadphase] renderer LoadMission BEGIN t=" << t0 + << std::endl << std::flush; + } + ~BTPhaseTimer() + { + DEBUG_STREAM << "[loadphase] renderer LoadMission END +" + << (GetTickCount() - t0) << "ms" << std::endl << std::flush; + } + } _phase; Check(this); Tell("DPLVideoRenderer::StartImplementation has been called\n"); DPLReadEnvironment(mission);