GPU terrain: integrate hybrid meshing and mod compatibility - #4
Conversation
|
Validation finding — host readback synchronization gap (blocking correctness issue before RX/RADV runtime testing):
The Vulkan spec explicitly says waiting for / polling a signaled fence is an execution dependency only and does not by itself guarantee device memory accesses are visible to the host. HOST_COHERENT removes the need for Suggested narrow fix in the same helper command buffer, after all copies into VkBufferMemoryBarrier.Buffer barrier = VkBufferMemoryBarrier.calloc(1, stack);
barrier.get(0).sType$Default()
.srcAccessMask(VK_ACCESS_TRANSFER_WRITE_BIT)
.dstAccessMask(VK_ACCESS_HOST_READ_BIT)
.srcQueueFamilyIndex(VK_QUEUE_FAMILY_IGNORED)
.dstQueueFamilyIndex(VK_QUEUE_FAMILY_IGNORED)
.buffer(readbackBuffer).offset(0L).size(totalReadbackBytes);
vkCmdPipelineBarrier(commandBuffer.getHandle(),
VK_PIPELINE_STAGE_TRANSFER_BIT,
VK_PIPELINE_STAGE_HOST_BIT,
0, null, barrier, null);For validation/capture mode, cover the full readback range containing both the result/descriptors and copied vertex payload. This should fix both the synchronous oracle and Spec references:
I have not changed PR #4 from the validation lane; production thread should own the fix. |
|
Additional corroboration: VulkanMod already uses the exact required dependency in |
|
Validation status at current head |
|
Validation escalation: this is not isolated to the draft PR. The current I rechecked the current Vulkan spec: fence wait / successful Gate consequence: do not request the RX/RADV functional test yet. First land the narrow readback barrier after all copies, covering the full readback range in validation mode; then rerun the terrain lifecycle/Vulkan startup smokes. CI xCollateral#606 otherwise remains healthy through the terrain-related gates and fails only at the separately owned Immersive Portals smoke. |
|
Validation finding on the new hybrid planner (
Current Suggested bounded fix, without redesigning the shader/ABI: during worker-side hybrid planning, for each candidate face compare the GPU predicate ( This is separate from the already-reported |
|
Additional hybrid integration constraint (fail-closed, not a corruption bug): It clears When this planner is wired into production, pair the filtered payload with a hybrid-aware qualification/staged-preflight result that counts only GPU-owned faces and explicitly permits CPU-owned visible states. Do not reuse the existing all-or-nothing This one safely fails closed today because the hybrid planner is not yet production-wired; it is an integration guardrail for the next slice. |
|
Hybrid activation guardrail on the new APPEND draw-plan work ( Once hybrid CPU tessellation actually omits GPU-owned cubes and the CPU command contains exceptions only, the same missing/stale-residency path would draw only those exceptions and leave the GPU-owned portion absent until recovery. In other words, APPEND cannot simultaneously mean Please treat this as an activation gate, not a defect in the currently unwired groundwork: before production enables APPEND with CPU omission, make the transition atomic or preserve a complete previous CPU fallback until exact GPU residency publishes. Tests should distinguish This is independent of the still-open transfer->host readback barrier and per-face Block.shouldRenderFace equivalence findings. |
Primary Forge 1.20.1 development/integration branch for the current Phase 7 GPU-terrain work.
This branch now consolidates the previously separate GPU-terrain, compatibility, and still-relevant validation work.
Production terrain changes include:
Compatibility changes now integrated here include:
Validation consolidation:
All accelerated terrain behavior remains experimental/default-off and must retain CPU fallback for unsupported Forge content, fluids, block entities, translucent/tripwire paths, stale generations, overflow, and failed GPU work.
Do not merge into forge-1.20.1 until the current combined CI suite is green and the repository gates have been rechecked against live state.