A render pass instance's first fetch between draws records after its load operations
On RADV on the RX 550 (Polaris, neither ordered fetch form of its own; job m3-max-14807) the first fetch of a render pass instance read a load-cleared RGBA32Uint attachment as 0: the lane's three exf_fetch_count draws stored (k + 1) * 13 for c * 27 + (k + 1) * 13, and fetched_attachments_clear_as_the_load_action_does counted 7, 200, 13, 255 beside the tag for 10, 206, 22, 267. Each read after a barrier between draws was right. Vulkan orders the load operations before every access of the instance through the attachment, but this driver did not make the clear visible to the input attachment read; the barrier between draws, inside the subpass's own dependency, does. So an instance begins with InterlockedStorage::BEGUN, the fetch-after-writes kind alone set: the first draw that reads input attachments ordered between draws alone records the barrier too. No draw of another device reaches that kind, so nothing else changes. The lane test now counts one more barrier in each pass (4, 3, 1) and states what a first read of 0 leaves. API.md, the runtime's framebuffer_fetch and InterlockedStorage docs and WorkCounts::fetch_draw_barriers say the load operations are among the writes a fetch records after. To be verified on the RX 550.
This commit is contained in:
1 parent
f1045dd9e5
commit
aba3c0969c
5 files changed
+49
-32
No files matched your search
+4
-4
@@ -845,8 +845,8 @@ Where Metal's rules differ from Vulkan's, the pipeline gives Metal's answer:
|
||||
as an input attachment without rasterization-order access
|
||||
(`GraphicsState::rasterization_order_attachment_access` false), and the consumer records a
|
||||
barrier of the subpass's dependency on itself, by region, before each draw that reads input
|
||||
attachments after an earlier draw of the subpass wrote a color, and before each draw that writes
|
||||
a color after an earlier one read them: a fetch reads what every earlier draw stored, Metal's
|
||||
attachments after an earlier draw of the subpass, or its load operations, wrote a color, and
|
||||
before each draw that writes a color after an earlier one read them: a fetch reads what every earlier draw stored, Metal's
|
||||
answer, but the overlapping fragments of one draw are not ordered, which the fragment stage
|
||||
records (`PrecisionNote::UnorderedFetchWithinDraw`; the runtime does all of this itself). A
|
||||
raster order group on such a color input, or on a color output of an attachment the function
|
||||
@@ -3664,8 +3664,8 @@ bound.
|
||||
`fragmentShaderPixelInterlock` (Honeykrisp on Apple's M2 Pro; RADV on the RX 550). It reads the
|
||||
attachment as an input attachment, and the runtime records a barrier of the draws' subpass's
|
||||
dependency on itself, by region, before each draw that reads input attachments after an earlier
|
||||
draw of its render pass instance wrote a color, and before each draw that writes a color after
|
||||
an earlier one read them (`WorkCounts::fetch_draw_barriers`): a fetch reads what every earlier
|
||||
draw of its render pass instance, or its load operations, wrote a color, and before each draw
|
||||
that writes a color after an earlier one read them (`WorkCounts::fetch_draw_barriers`): a fetch reads what every earlier
|
||||
draw stored at its pixel, Metal's answer. Vulkan orders nothing between the overlapping
|
||||
fragments of one draw there, where Metal orders them in primitive order: a fragment that covers
|
||||
a pixel an earlier fragment of its own draw covered may read the texel from before that
|
||||
|
||||
Reference in new issue
Block a user