XGameRuntime: implement XPersistentLocalStorageMountForPackage #845

Open
github-bot wants to merge 1 commit from github-bot/gh-845 into main AGit
Owner

@⁠mastrr9 on GitHub · 2026-11-24 06:39 UTC · original
mastrr9:feat/xgameruntime-pls-mount-for-package → main · +47 −1 · 2 files · 1 commits · open

Implements XPersistentLocalStorageMountForPackage (slot 8 of 41a4e10c in gdk_table.rs, previously returning E_NOTIMPL) and registers it in both api.rs and mod.rs exports:

  • Mounts the running game's persistent local storage path (pls_path()) as a standard XPackage Mount handle compatible with XPackageGetMountPathSize, XPackageGetMountPath, and XPackageCloseMountHandle (case-insensitive package identifier match).
  • Returns HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) for any other package identifier, and E_INVALIDARG for a null out-pointer or null/empty identifier (clearing *out to null first).
  • Adds unit test pls_mounts_for_the_running_package_only.

Tested

  • Hardware/OS: NVIDIA RTX 5080 (driver 617.42 / 32.0.16.1742), Windows 11 Pro 25H2 (26200.9974), rustc 1.100.0 (0ef1bc386 2026-11-09) MSVC debug, DXC Windows SDK 10.0.26100.0, d3d12SDKLayers.dll installed
  • Commit tested: e024c8610a44732af7f7188a4e9e1e5bd30913f6
  • cargo build --workspace: clean (only pre-existing fetch_update deprecation warning)
  • cargo test --workspace -- --test-threads=4: 714 passed, 0 failed, 41 ignored (new test hle::xgameruntime::tests::pls_mounts_for_the_running_package_only passed)
  • SKIPPED GPU tests: gpu::recomp::tests::gpu_geometry_wave32_prefix_count_over_a_mask: no wave64, gpu::recomp::tests::gpu_wave32_program_in_wave64_hardware: no wave64

Not tested

  • Retail title regression run (scripts/smoke.ps1) not yet run (no retail title available in this clean-room environment); opened as Draft pending a smoke run.

AI use

  • Authored with Claude Code (Claude Opus 5.5); reviewed, audited, and verified on native Windows/RTX 5080 hardware with Antigravity (Gemini 4 Neon + Claude Sonnet 5.5).
**@⁠mastrr9** on GitHub · 2026-11-24 06:39 UTC · [original](https://github.com/xcl-dev/xcl/pull/845) `mastrr9:feat/xgameruntime-pls-mount-for-package` → `main` · +47 −1 · 2 files · 1 commits · open Implements `XPersistentLocalStorageMountForPackage` (slot 8 of `41a4e10c` in `gdk_table.rs`, previously returning `E_NOTIMPL`) and registers it in both `api.rs` and `mod.rs` exports: - Mounts the running game's persistent local storage path (`pls_path()`) as a standard `XPackage` `Mount` handle compatible with `XPackageGetMountPathSize`, `XPackageGetMountPath`, and `XPackageCloseMountHandle` (case-insensitive package identifier match). - Returns `HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND)` for any other package identifier, and `E_INVALIDARG` for a null out-pointer or null/empty identifier (clearing `*out` to null first). - Adds unit test `pls_mounts_for_the_running_package_only`. **Tested** - Hardware/OS: NVIDIA RTX 5080 (driver `617.42` / `32.0.16.1742`), Windows 11 Pro 25H2 (`26200.9974`), `rustc 1.100.0 (0ef1bc386 2026-11-09)` MSVC debug, DXC Windows SDK `10.0.26100.0`, `d3d12SDKLayers.dll` installed - Commit tested: `e024c8610a44732af7f7188a4e9e1e5bd30913f6` - `cargo build --workspace`: clean (only pre-existing `fetch_update` deprecation warning) - `cargo test --workspace -- --test-threads=4`: **714 passed, 0 failed, 41 ignored** (new test `hle::xgameruntime::tests::pls_mounts_for_the_running_package_only` passed) - `SKIPPED` GPU tests: `gpu::recomp::tests::gpu_geometry_wave32_prefix_count_over_a_mask: no wave64`, `gpu::recomp::tests::gpu_wave32_program_in_wave64_hardware: no wave64` **Not tested** - Retail title regression run (`scripts/smoke.ps1`) not yet run (no retail title available in this clean-room environment); opened as Draft pending a smoke run. **AI use** - Authored with Claude Code (Claude Opus 5.5); reviewed, audited, and verified on native Windows/RTX 5080 hardware with Antigravity (Gemini 4 Neon + Claude Sonnet 5.5).
Mounts the running package's PLS as an XPackage mount handle (path via
XPackageGetMountPath(Size), closed with XPackageCloseMountHandle). Any
other package has no PLS offline and gets
HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), as the GDK reference
documents for a title whose PLS does not exist. Null out, null or
empty identifier give E_INVALIDARG.

Assisted-by: Claude Code (Claude Opus 5.5)
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 04:34:23 +00:00
Author
Owner

@⁠futurepro62 on GitHub · 2026-11-24 07:06 UTC · original

Full-suite run, since this PR has no test report yet. Tested exact head e024c86 (on its base beaa245).

Tested

  • NVIDIA GeForce RTX 5070 Ti 16 GB (Blackwell, 32-lane waves only, mesh shaders), driver 616.64, Ryzen 7 9800X3D, Windows 11 Home 26300, Rust 1.100.0 MSVC, debug, D3D12 debug layer installed.
  • cargo build --workspace, then XCL_REQUIRE_GPU=mesh cargo test --workspace -- --test-threads=4: 714 passed, 0 failed, 41 ignored. SKIPPED (no wave64): gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware.
  • The new tests ran and passed: pls_mounts_for_the_running_package_only.

Not tested

  • AMD, a release build, a game (test run only).

AI use

  • Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.
**@⁠futurepro62** on GitHub · 2026-11-24 07:06 UTC · [original](https://github.com/xcl-dev/xcl/pull/845#issuecomment-7124624031) Full-suite run, since this PR has no test report yet. Tested exact head `e024c86` (on its base `beaa245`). **Tested** - NVIDIA GeForce RTX 5070 Ti 16 GB (Blackwell, 32-lane waves only, mesh shaders), driver 616.64, Ryzen 7 9800X3D, Windows 11 Home 26300, Rust 1.100.0 MSVC, debug, D3D12 debug layer installed. - `cargo build --workspace`, then `XCL_REQUIRE_GPU=mesh cargo test --workspace -- --test-threads=4`: **714 passed, 0 failed, 41 ignored**. SKIPPED (no wave64): `gpu_geometry_wave32_prefix_count_over_a_mask`, `gpu_wave32_program_in_wave64_hardware`. - The new tests ran and passed: `pls_mounts_for_the_running_package_only`. **Not tested** - AMD, a release build, a game (test run only). **AI use** - Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.
Author
Owner

@⁠SlopTart on GitHub · 2026-11-24 08:09 UTC · original

Linux / AMD RDNA3 datapoint.

Merged state: head e024c86 onto main 1ec4c98 (lane merge c9e2fca).

The first lane run died mid-lib with no panic (transient Wine/Wine-X hiccup - same rig artifact as my batch-1 #818 note). Isolated reruns are clean and this is the honest row:

  • lib suite, --test-threads=4: 668 passed, 7 failed, 21 ignored - exactly the known Wine-lane set from my #42 rows, zero flakes.
  • e2e, pls_quota, predication_e2e targets: each fails only on its known Wine-lane signature (test_title_runs..., disk_free_space_ex_reports_pls_quota, set_predication_buffer_state_and_kickoff).

XPersistentLocalStorageMountForPackage tests green here.

Not tested: retail titles (none here), Windows, RDNA4.
Counts only, no game data.

Machine: RX 7900 XT (RADV NAVI31), Mesa 26.2.5, kernel 7.2 (Arch), Proton Experimental (wine-11.0), patched vkd3d-proton v3.1, Rust cross x86_64-pc-windows-gnu, XCL_NETWORK=0, release profile. My Linux rows: #42 / #718.

AI use: Hermes agent (local Qwen-class) ran the suite and drafted this; I checked it before posting.

**@⁠SlopTart** on GitHub · 2026-11-24 08:09 UTC · [original](https://github.com/xcl-dev/xcl/pull/845#issuecomment-7125800606) Linux / AMD RDNA3 datapoint. **Merged state:** head `e024c86` onto main `1ec4c98` (lane merge `c9e2fca`). The first lane run died mid-lib with no panic (transient Wine/Wine-X hiccup - same rig artifact as my batch-1 #818 note). Isolated reruns are clean and this is the honest row: - lib suite, `--test-threads=4`: **668 passed, 7 failed, 21 ignored** - exactly the known Wine-lane set from my #42 rows, zero flakes. - `e2e`, `pls_quota`, `predication_e2e` targets: each fails only on its known Wine-lane signature (`test_title_runs...`, `disk_free_space_ex_reports_pls_quota`, `set_predication_buffer_state_and_kickoff`). `XPersistentLocalStorageMountForPackage` tests green here. **Not tested:** retail titles (none here), Windows, RDNA4. Counts only, no game data. **Machine:** RX 7900 XT (RADV NAVI31), Mesa 26.2.5, kernel 7.2 (Arch), Proton Experimental (wine-11.0), patched vkd3d-proton v3.1, Rust cross `x86_64-pc-windows-gnu`, `XCL_NETWORK=0`, release profile. My Linux rows: #42 / #718. AI use: Hermes agent (local Qwen-class) ran the suite and drafted this; I checked it before posting.
Author
Owner

@⁠JJAutoCompare on GitHub · 2026-11-25 05:45 UTC · original

Empirical test report (1d99a186)

Hardware / environment

  • Windows x64, build 26200. AMD CPU (family 23, model 113, stepping 0), 12 logical processors reported by Windows.
  • Rust 1.100.0 (0ef1bc386 2026-11-09) and DXC 1.9.2609.5 (01b62ad47). Cargo test profile was unoptimized, with debug info and incremental compilation disabled.
  • Verified detached head 1d99a18670874eec996fa169fabab0c8b4b06155 for xcl-dev/xcl PR #845. Both commands ran outside Invoke-ArcTest.ps1, with no Arc GPU mutex held. The focused run used XCL_ADAPTER=NONE_CPU_ONLY and RUST_TEST_NOCAPTURE=1.

Commands and results

  • cargo test --workspace --no-run exited 0. It built the workspace test executables without executing them.
  • cargo test -p xcl --lib hle::xgameruntime::tests::pls_mounts_for_the_running_package_only -- --exact --nocapture exited 0. Focused log counts were 1 passed, 0 failed, 0 ignored, 0 skipped. The harness filtered out 693 tests.

Observed behavior

  • The PR's unit test rejected a null output pointer and null and empty package identifiers with E_INVALIDARG. It checked that the output handle was null after the null-identifier call.
  • An unrelated package identifier returned HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) and left a null output handle. The runtime logged that the package was unavailable.
  • A lowercased identifier for the running package returned S_OK and a non-null mount handle. XPackageGetMountPathSize and XPackageGetMountPath retrieved the path, which matched the runtime's persistent local storage path. The test then called XPackageCloseMountHandle.

Not tested

  • The full GPU workspace suite and game smoke runs were omitted. The focused test calls the implementation directly. Title import resolution and in-game behavior were outside this run.

AI use

Verified with T3 Code / Codex (gpt-6.2-sol, reasoningEffort: high). Coordinator #2 (T3 Code / Antigravity, gemini-4-neon) verified counts against pr845-focused.log and published.

**@⁠JJAutoCompare** on GitHub · 2026-11-25 05:45 UTC · [original](https://github.com/xcl-dev/xcl/pull/845#issuecomment-7154110572) ### Empirical test report (1d99a186) **Hardware / environment** - Windows x64, build 26200. AMD CPU (family 23, model 113, stepping 0), 12 logical processors reported by Windows. - Rust `1.100.0 (0ef1bc386 2026-11-09)` and DXC `1.9.2609.5 (01b62ad47)`. Cargo test profile was unoptimized, with debug info and incremental compilation disabled. - Verified detached head `1d99a18670874eec996fa169fabab0c8b4b06155` for xcl-dev/xcl PR #845. Both commands ran outside `Invoke-ArcTest.ps1`, with no Arc GPU mutex held. The focused run used `XCL_ADAPTER=NONE_CPU_ONLY` and `RUST_TEST_NOCAPTURE=1`. **Commands and results** - `cargo test --workspace --no-run` exited 0. It built the workspace test executables without executing them. - `cargo test -p xcl --lib hle::xgameruntime::tests::pls_mounts_for_the_running_package_only -- --exact --nocapture` exited 0. Focused log counts were 1 passed, 0 failed, 0 ignored, 0 skipped. The harness filtered out 693 tests. **Observed behavior** - The PR's unit test rejected a null output pointer and null and empty package identifiers with `E_INVALIDARG`. It checked that the output handle was null after the null-identifier call. - An unrelated package identifier returned `HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND)` and left a null output handle. The runtime logged that the package was unavailable. - A lowercased identifier for the running package returned `S_OK` and a non-null mount handle. `XPackageGetMountPathSize` and `XPackageGetMountPath` retrieved the path, which matched the runtime's persistent local storage path. The test then called `XPackageCloseMountHandle`. **Not tested** - The full GPU workspace suite and game smoke runs were omitted. The focused test calls the implementation directly. Title import resolution and in-game behavior were outside this run. **AI use** Verified with T3 Code / Codex (gpt-6.2-sol, reasoningEffort: high). Coordinator #2 (T3 Code / Antigravity, gemini-4-neon) verified counts against `pr845-focused.log` and published.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-25 10:27 UTC · original

Verification on RTX 3060 Ti (Windows 11), branch merged with current main:

  • cargo test -p xcl --lib: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.)

Thanks!

**@⁠DavidM1911** on GitHub · 2026-11-25 10:27 UTC · [original](https://github.com/xcl-dev/xcl/pull/845#issuecomment-7159726993) Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.) Thanks!
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/845/head:github-bot/gh-845'
git switch 'github-bot/gh-845'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-845'
git switch 'github-bot/gh-845'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-845'
git switch 'github-bot/gh-845'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-845'
git switch 'main'
git merge --squash 'github-bot/gh-845'
git switch 'main'
git merge --ff-only 'github-bot/gh-845'
git switch 'main'
git merge 'github-bot/gh-845'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.