HLE: return NOT_SUPPORTED early for null out in QueryApiImpl without marking area missing #1199

Open
geiyiliyabumo wants to merge 1 commit from upstream-pr/1199 into main
geiyiliyabumo commented 2026-11-24 16:24:12 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by geiyiliyabumo on 2026-11-24T16:24:12Z.


Summary

Closes #1029

Full verification details and change notes are documented in #1029 (commit 8466edd, based on main ffe310e).

 crates/victory-hle/src/modules/xgameruntime.rs | 265 ++++++++++++++++++++++++-
 1 file changed, 260 insertions(+), 5 deletions(-)

Verification (Windows 11 x64 MSVC)

  • rustfmt --edition 2024 --check on edited files: PASS
  • cargo xtask policy: PASS (zero game files/data)
  • cargo clippy --all-targets --locked -- -D warnings (default + --features diagnostics where applicable): PASS
  • Targeted & crate unit/GPU tests: PASS

AI-assisted; synthetic tests only, no game files.

<!-- greyfinch-sync:Marvisak/VIctory:issue:6586436695 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1199). Originally posted by [geiyiliyabumo](https://github.com/geiyiliyabumo) on 2026-11-24T16:24:12Z. --- ### Summary Closes #1029 Full verification details and change notes are documented in #1029 (commit `8466edd`, based on `main` `ffe310e`). ```text crates/victory-hle/src/modules/xgameruntime.rs | 265 ++++++++++++++++++++++++- 1 file changed, 260 insertions(+), 5 deletions(-) ``` ### Verification (Windows 11 x64 MSVC) - `rustfmt --edition 2024 --check` on edited files: **PASS** - `cargo xtask policy`: **PASS** (zero game files/data) - `cargo clippy --all-targets --locked -- -D warnings` (default + `--features diagnostics` where applicable): **PASS** - Targeted & crate unit/GPU tests: **PASS** *AI-assisted; synthetic tests only, no game files.*
DenRakEiw commented 2026-11-24 17:03:48 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by DenRakEiw on 2026-11-24T16:27:16Z.

Review: APPROVED


Tested head 8466edd (fast-forward on main ffe310e) on Windows 11 x64 (Rust 1.98.1 MSVC):

  • cargo test -p victory-hle: 107 passed, 0 failed (plus no_dll_planting: 1 passed)
  • cargo clippy -p victory-hle --all-targets: 0 warnings
  • cargo xtask policy: ok

Clean null-out validation in QueryApiImpl and expanded xgameruntime test coverage. Approving.

AI-assisted (Gemini 4 Neon).

<!-- greyfinch-sync:Marvisak/VIctory:review:6043235785 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1199#pullrequestreview-6043235785). Originally posted by [DenRakEiw](https://github.com/DenRakEiw) on 2026-11-24T16:27:16Z. **Review:** APPROVED --- Tested head `8466edd` (fast-forward on `main` `ffe310e`) on Windows 11 x64 (Rust 1.98.1 MSVC): - `cargo test -p victory-hle`: **107 passed, 0 failed** (plus `no_dll_planting`: 1 passed) - `cargo clippy -p victory-hle --all-targets`: **0 warnings** - `cargo xtask policy`: ok Clean null-`out` validation in `QueryApiImpl` and expanded `xgameruntime` test coverage. Approving. AI-assisted (Gemini 4 Neon).
Zipettte commented 2026-11-24 18:06:09 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by Zipettte on 2026-11-24T18:00:16Z.


Tested on AMD Radeon RX 7700 XT (RDNA3, gfx1101), driver 32.0.32029.2010, Windows 11, Rust 1.98.1 MSVC at 8466edd: cargo test -p victory-hle passes, 108 passed / 0 failed. Workspace baseline on main (ffe310e) is green on the same machine (342 passed).

Tested with AI assistance (Claude).

<!-- greyfinch-sync:Marvisak/VIctory:comment:7140016638 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1199#issuecomment-7140016638). Originally posted by [Zipettte](https://github.com/Zipettte) on 2026-11-24T18:00:16Z. --- Tested on AMD Radeon RX 7700 XT (RDNA3, gfx1101), driver 32.0.32029.2010, Windows 11, Rust 1.98.1 MSVC at 8466edd: `cargo test -p victory-hle` passes, 108 passed / 0 failed. Workspace baseline on main (ffe310e) is green on the same machine (342 passed). _Tested with AI assistance (Claude)._
upstream-sync changed title from [PR #1199] HLE: reject null out in QueryApiImpl before lookup and add xgameruntime unit tests to [PR #1199] HLE: return NOT_SUPPORTED early for null out in QueryApiImpl without marking area missing 2026-11-25 02:03:33 +00:00
Marvisak commented 2026-11-25 02:05:53 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by Marvisak on 2026-11-25T01:19:47Z.


Automated triage for the maintainers.

Needs work (small). Thanks for the update. The change now does what we suggested. In QueryApiImpl (crates/victory-hle/src/modules/xgameruntime.rs), a null out returns NOT_SUPPORTED before the lookup, so an implemented pair is no longer logged or remembered as "runtime API area not implemented". The new test fails on main and passes here.

However, this head also deletes an existing, unrelated test from main: title_stub_loads_the_runtime_dynamically. It checks that the runtime's exports resolve through LoadLibraryExA/GetProcAddress, and that host DLLs still load from the host. That looks like a leftover from trimming the earlier tests. Please restore it and keep your new test next to it. The PR body also still points to #1029 and shows the old diffstat. A one-line description of the change would do. With the test restored, this would be a merge candidate.

CI: passing.


Generated by Claude Code

<!-- greyfinch-sync:Marvisak/VIctory:comment:7149435908 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1199#issuecomment-7149435908). Originally posted by [Marvisak](https://github.com/Marvisak) on 2026-11-25T01:19:47Z. --- <!-- victory-triage v1 head=6ebc0af9a1a65af3e1e17fe9da1a9b35ece4cb9c verdict=needs-work at=2026-11-25T02:20:29Z --> Automated triage for the maintainers. **Needs work (small).** Thanks for the update. The change now does what we suggested. In `QueryApiImpl` (`crates/victory-hle/src/modules/xgameruntime.rs`), a null `out` returns `NOT_SUPPORTED` before the lookup, so an implemented pair is no longer logged or remembered as "runtime API area not implemented". The new test fails on main and passes here. However, this head also deletes an existing, unrelated test from main: `title_stub_loads_the_runtime_dynamically`. It checks that the runtime's exports resolve through `LoadLibraryExA`/`GetProcAddress`, and that host DLLs still load from the host. That looks like a leftover from trimming the earlier tests. Please restore it and keep your new test next to it. The PR body also still points to #1029 and shows the old diffstat. A one-line description of the change would do. With the test restored, this would be a merge candidate. CI: passing. --- _Generated by [Claude Code](https://claude.ai/code)_
geiyiliyabumo commented 2026-11-25 02:06:18 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by geiyiliyabumo on 2026-11-25T01:45:45Z.


Updated per triage feedback: kept \NOT_SUPPORTED\ as the return value for a null \out\ in \QueryApiImpl, returning early before logging or recording the API area as unimplemented, and trimmed the tests down to a single focused regression test covering the return value and missing-area cache. Rebased onto \main; \cargo test -p victory-hle --locked\ (145 passed, 0 failed), \cargo clippy -p victory-hle --all-targets --locked -- -D warnings, and \cargo xtask policy\ all pass.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7149926021 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/1199#issuecomment-7149926021). Originally posted by [geiyiliyabumo](https://github.com/geiyiliyabumo) on 2026-11-25T01:45:45Z. --- Updated per triage feedback: kept \NOT_SUPPORTED\ as the return value for a null \out\ in \QueryApiImpl\, returning early before logging or recording the API area as unimplemented, and trimmed the tests down to a single focused regression test covering the return value and missing-area cache. Rebased onto \main\; \cargo test -p victory-hle --locked\ (145 passed, 0 failed), \cargo clippy -p victory-hle --all-targets --locked -- -D warnings\, and \cargo xtask policy\ all pass.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/1199:upstream-pr/1199'
git switch 'upstream-pr/1199'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/1199'
git switch 'upstream-pr/1199'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/1199'
git switch 'upstream-pr/1199'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/1199'
git switch 'main'
git merge --squash 'upstream-pr/1199'
git switch 'main'
git merge --ff-only 'upstream-pr/1199'
git switch 'main'
git merge 'upstream-pr/1199'
git push origin 'main'
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
Marvisak/VIctory!1199
No description provided.