Add experimental BCPack BC1 decoding and clarify pipeline activity #230

Closed
Yeetbot159 wants to merge 3 commits from upstream-pr/233 into main
Yeetbot159 commented 2026-11-23 21:37:31 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Yeetbot159 on 2026-11-23T21:37:31Z.


Summary

  • Add an opt-in experimental BCPack BC1 decoder to DirectStorage, using the MIT-licensed bcpack-rs dependency pinned to a revision. Supports direct BC1 and zlib-then-BC1 requests to virtual or physical-page destinations.
  • Reject malformed streams, unknown lane 1 symbols, and unfitted endpoint entries without writing the destination. Document that fitted tables may still be inaccurate; BC2–BC7 and hardware swizzling remain unsupported. The separately published bcpack-decoder requires learned tables that are not distributed and does not reconstruct BC5–BC7 blocks.
  • Exclude dormant lazy pipelines from the window's compilation activity indicator.

This does not establish that the affected game renders or runs fully. Enable BC1 with XCL_DSTORAGE_BCPACK_BC1=1.

Validation

  • Synthetic DirectStorage queue tests cover direct and zlib-wrapped BC1, physical pages, malformed inputs, opt-in, unsupported formats, and unfitted table entries; a focused test checks rejection of unknown lane 1 symbols.
  • ./scripts/test.ps1 (before the lane 1 check)
  • cargo test -p xcl hle::dstorage::tests --lib
  • cargo build --release --workspace
  • Attempted a real-game run with BC1 enabled; stopped after roughly 13 seconds when private memory exceeded the 10 GiB safety limit. No BCPack request appeared in the captured log, so this did not validate the decoder against real textures or demonstrate gameplay.
<!-- greyfinch-sync:ivall/xcl:issue:6569339549 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/233). Originally posted by [Yeetbot159](https://github.com/Yeetbot159) on 2026-11-23T21:37:31Z. --- ## Summary - Add an opt-in experimental BCPack BC1 decoder to DirectStorage, using the MIT-licensed `bcpack-rs` dependency pinned to a revision. Supports direct BC1 and zlib-then-BC1 requests to virtual or physical-page destinations. - Reject malformed streams, unknown lane 1 symbols, and unfitted endpoint entries without writing the destination. Document that fitted tables may still be inaccurate; BC2–BC7 and hardware swizzling remain unsupported. The separately published `bcpack-decoder` requires learned tables that are not distributed and does not reconstruct BC5–BC7 blocks. - Exclude dormant lazy pipelines from the window's compilation activity indicator. This does **not** establish that the affected game renders or runs fully. Enable BC1 with `XCL_DSTORAGE_BCPACK_BC1=1`. ## Validation - Synthetic DirectStorage queue tests cover direct and zlib-wrapped BC1, physical pages, malformed inputs, opt-in, unsupported formats, and unfitted table entries; a focused test checks rejection of unknown lane 1 symbols. - `./scripts/test.ps1` (before the lane 1 check) - `cargo test -p xcl hle::dstorage::tests --lib` - `cargo build --release --workspace` - Attempted a real-game run with BC1 enabled; stopped after roughly 13 seconds when private memory exceeded the 10 GiB safety limit. No BCPack request appeared in the captured log, so this did not validate the decoder against real textures or demonstrate gameplay.
upstream-sync closed this pull request 2026-11-24 11:04:38 +00:00
ivall commented 2026-11-24 11:05:52 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by ivall on 2026-11-24T10:39:34Z.


#905 is merged (67a3735): DirectStorage now unpacks BCPack BC1, BC3, BC4, BC5, BC6H and BC7 with the format's exact tables, so this PR is superseded. Thanks for the early BC1 work.

<!-- greyfinch-sync:ivall/xcl:comment:7129074206 --> Imported from [ivall/xcl](https://github.com/ivall/xcl/pull/233#issuecomment-7129074206). Originally posted by [ivall](https://github.com/ivall) on 2026-11-24T10:39:34Z. --- #905 is merged (67a3735): DirectStorage now unpacks BCPack BC1, BC3, BC4, BC5, BC6H and BC7 with the format's exact tables, so this PR is superseded. Thanks for the early BC1 work.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
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.

Reference
xcl-dev/xcl!230
No description provided.