WIP: [pr-fix][RAYTRACING] Restore buffer state after DXR postbuild writes #27

Manually merged
TrustNo1 merged 0 commits from umcakatabla/dxr-postbuild-buffer-state into main 2026-12-03 18:36:40 +00:00 AGit
Contributor

Refs #4.

Contributor role (optional)

  • Fluxer ID:

What it changes

The destination buffer of a DXR postbuild answer stays in COPY_DEST after a size or serialization result is written. The title can read that buffer again in the same command list. Return the destination to COMMON after WriteBufferImmediate and CopyBufferRegion so the next access can promote it to the required read state.

How it was tested

  • Tested revision 2519633, based on 4a92569.
  • cargo test --locked -p darner-gpu --lib --features diagnostics hwrt::tests passed (21 tests).
  • cargo clippy --locked -p darner-gpu --all-targets --all-features -- -D warnings passed.
  • The asset policy check through cargo run --locked -p xtask -- policy passed in a dedicated target directory (542 files).
  • A standalone WARP probe reproduced validation message 538 after a two-dword WriteBufferImmediate followed by a copy from the same buffer in the same command list. Restoring COMMON cleared the message and preserved the two values with the debug layer and with GPU-based validation.
  • Coverage gap: gameplay with this standalone commit. The combined local candidate still reproduced device removal in the default TLAS configuration. Runtime results

Checklist

  • This PR contains one change based on main.
  • The diff follows docs/asset-policy.md.
  • I recorded this PR's dependencies below.
    • Depends on: none

Checked for overlap

  • I searched the open pull requests for the same issue and for the files this touches.
  • Related PRs: #23 changes BLAS input and memory placement, and #3 changes F1 ray tracing status. Both touch hwrt.rs.
Refs #4. ## Contributor role (optional) - Fluxer ID: ## What it changes The destination buffer of a DXR postbuild answer stays in COPY_DEST after a size or serialization result is written. The title can read that buffer again in the same command list. Return the destination to COMMON after WriteBufferImmediate and CopyBufferRegion so the next access can promote it to the required read state. ## How it was tested - Tested revision `2519633`, based on `4a92569`. - `cargo test --locked -p darner-gpu --lib --features diagnostics hwrt::tests` passed (21 tests). - `cargo clippy --locked -p darner-gpu --all-targets --all-features -- -D warnings` passed. - The asset policy check through `cargo run --locked -p xtask -- policy` passed in a dedicated target directory (542 files). - A standalone WARP probe reproduced validation message 538 after a two-dword WriteBufferImmediate followed by a copy from the same buffer in the same command list. Restoring COMMON cleared the message and preserved the two values with the debug layer and with GPU-based validation. - Coverage gap: gameplay with this standalone commit. The combined local candidate still reproduced device removal in the default TLAS configuration. [Runtime results](https://git.gtahub.st/TrustNo1/Darner/issues/4#issuecomment-847347) ## Checklist - [x] This PR contains one change based on `main`. - [x] The diff follows `docs/asset-policy.md`. - [x] I recorded this PR's dependencies below. - Depends on: none ## Checked for overlap - [x] I searched the open pull requests for the same issue and for the files this touches. - Related PRs: #23 changes BLAS input and memory placement, and #3 changes F1 ray tracing status. Both touch `hwrt.rs`.
TrustNo1 manually merged commit deabb1a223 into main 2026-12-03 18:36:40 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
TrustNo1/Darner!27
No description provided.