streaming: latch fast-travel early admission until the arrival set settles (L170, still opt-in)

Switches verified inactive before first settlement; moving gains hold (near 43.7 -> 55.5%, far holes 1.8 -> 0%, p99
7.21 -> 6.48 ms, worst 12.32 -> 12.27 ms). Arrival median +1.28% (4/7 pairs slower) though the switches did no work
then; defaults remain off (WaitForAllCriticalTiles=1, ApplyBudget=0). Source/: VoxelWorld.cpp, VoxelWorld.h.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016dhxM43dnWvUu2B5Ph1iG1
This commit is contained in:
Fr0zkaandClaude Opus 5.5 committed 2026-11-02 17:28:52 +01:00
1 parent 786ecc4cdf
commit 24803ab771
4 files changed
+559 -5

No files matched your search

+12 -5
View File
@@ -9984,6 +9984,7 @@ void AVoxelWorld::ProcessPendingChunks(uint64 TickStartCycles)
}
}
}
bInitialArrivalSetSettled = bInitialArrivalSetSettled || bInitialDesiredSetReady;
const bool bStartupApplyOverridden = GVoxelForgeStreamingStartupApplyBoost <= 0
|| GVoxelForgeStep1MaxMeshApplies > 0;
if (bStartupApplyBoostStarted && !bStartupApplyBoostEnded
@@ -10035,7 +10036,8 @@ void AVoxelWorld::ProcessPendingChunks(uint64 TickStartCycles)
float ApplyBudgetMilliseconds = bUseStartupApplyBoost
? StreamingStartupApplyBudgetMilliseconds
: (Settings ? FMath::Max(Settings->MaxMeshApplyMilliseconds, 0.0f) : 2.0f);
const bool bFastTravelApplyBudgetActive = bStreamingPlayerMoving && bSpeedAwareFastMode
const bool bFastTravelApplyBudgetActive = bInitialArrivalSetSettled
&& bStreamingPlayerMoving && bSpeedAwareFastMode
&& GVoxelForgeStreamingFastTravelApplyBudgetMilliseconds > 0.0f;
if (bFastTravelApplyBudgetActive)
{
@@ -13562,7 +13564,7 @@ void AVoxelWorld::UpdateChunksAroundPosition(const FVector& CenterPosition, APaw
const int32 ConfiguredReadyQueueDepth = FMath::Clamp(
GVoxelForgeStreamingReadyQueueDepth, 0, FMath::Min(64, FMath::Max(1, MaxTasks) * 4));
const bool bFastTravelAdmission = GVoxelForgeStreamingSchedulerPolicy == 3
&& bSpeedAwareFastMode;
&& bInitialArrivalSetSettled && bSpeedAwareFastMode;
const int32 ReadyQueueDepth = bFastTravelAdmission
? FMath::Max(ConfiguredReadyQueueDepth, 24) : ConfiguredReadyQueueDepth;
const int32 TotalAdmissionCap = MaxTasks + ReadyQueueDepth;
@@ -13695,7 +13697,8 @@ void AVoxelWorld::UpdateChunksAroundPosition(const FVector& CenterPosition, APaw
? AuthoredNearTaskReserve
: ((bPawnMoving || !bWalkableRingReadyForReserve) ? QueueAwareNearTaskReserve : 0);
const int32 NearTaskReserve = EffectiveNearTaskReserve;
const bool bPolicy3FastTravel = SchedulerPolicy == 3 && bSpeedAwareFastMode;
const bool bPolicy3FastTravel = SchedulerPolicy == 3
&& bInitialArrivalSetSettled && bSpeedAwareFastMode;
// Fast travel keeps three quarters of the bounded ready queue for near detail and
// leaves the final quarter open for horizon coverage. The walkable ring is submitted first.
const int32 FastTravelNearCap = MaxTasks + (ReadyQueueDepth * 3) / 4;
@@ -14999,6 +15002,8 @@ void AVoxelWorld::UpdateChunksAroundPosition(const FVector& CenterPosition, APaw
TEXT("\"frame\":%llu,\"center\":[%d,%d,%d],\"desired_rebuilt\":%d,"
"\"submission_loop_ran\":%d,\"all_chunks_loaded\":%d,"
"\"walkable_ready\":%d,\"moving\":%d,"
"\"initial_arrival_set_settled\":%d,\"fast_travel_mode\":%d,"
"\"wait_for_all_critical_tiles\":%d,"
"\"core_region_compile_pending\":%d,\"core_ready\":%d,\"coarse_first\":%d,"
"\"dynamic_near_reserve\":%d,\"legacy_pending_result_cap\":%d,"
"\"core_region_concurrent_admission\":%d,"
@@ -15038,6 +15043,8 @@ void AVoxelWorld::UpdateChunksAroundPosition(const FVector& CenterPosition, APaw
static_cast<unsigned long long>(GFrameCounter), CenterChunk.X, CenterChunk.Y, CenterChunk.Z,
bDesiredRebuiltThisUpdate ? 1 : 0, bSubmissionLoopRan ? 1 : 0, bAllChunksLoaded ? 1 : 0,
bWalkableRingReadyForReserve ? 1 : 0, bPawnMoving ? 1 : 0,
bInitialArrivalSetSettled ? 1 : 0, bPolicy3FastTravel ? 1 : 0,
GVoxelForgeStreamingFastTravelWaitForAllCriticalTiles,
bCoreRegionCompilePending ? 1 : 0, IsVoxelForgeCoreReady() ? 1 : 0,
GVoxelForgeStreamingCoarseFirst, GVoxelForgeStreamingDynamicNearReserve,
GVoxelForgeStreamingLegacyPendingResultCap,
@@ -15118,7 +15125,7 @@ void AVoxelWorld::LoadTile(const FVoxelTileKey& Tile, EVoxelTileWorkPriority Wor
const int32 ConfiguredReadyQueueDepth = FMath::Clamp(
GVoxelForgeStreamingReadyQueueDepth, 0, FMath::Min(64, FMath::Max(1, MaxTasks) * 4));
const bool bFastTravelAdmission = GVoxelForgeStreamingSchedulerPolicy == 3
&& bSpeedAwareFastMode;
&& bInitialArrivalSetSettled && bSpeedAwareFastMode;
const int32 ReadyQueueDepth = bFastTravelAdmission
? FMath::Max(ConfiguredReadyQueueDepth, 24) : ConfiguredReadyQueueDepth;
const int32 TotalAdmissionCap = MaxTasks + ReadyQueueDepth;
@@ -15520,7 +15527,7 @@ void AVoxelWorld::LoadCoreTile(const FVoxelTileKey& Tile, EVoxelTileWorkPriority
const int32 ConfiguredReadyQueueDepth = FMath::Clamp(
GVoxelForgeStreamingReadyQueueDepth, 0, FMath::Min(64, FMath::Max(1, MaxTasks) * 4));
const bool bFastTravelAdmission = GVoxelForgeStreamingSchedulerPolicy == 3
&& bSpeedAwareFastMode;
&& bInitialArrivalSetSettled && bSpeedAwareFastMode;
const int32 ReadyQueueDepth = bFastTravelAdmission
? FMath::Max(ConfiguredReadyQueueDepth, 24) : ConfiguredReadyQueueDepth;
const int32 TotalAdmissionCap = MaxTasks + ReadyQueueDepth;