HLE: trace the XUserAddAsync completion and the create thread's next calls #10
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Lesloo--longroad!10
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-10"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@Headache3318 on GitHub · 2026-12-04 10:54 UTC · original
Headache3318:xuser-gameinput-trace→main· +74 −3 · 2 files · 1 commits · openFollows the request from issue #4 (2026-12-03T17:23Z):
Logging only — no behaviour change.
What it logs
XUserAddAsynccompletion (modules/xuser.rs): when the add provider's async block completes, one INFO line with the result it completed with (0x0) and the user handle the result branch hands back, as a number:The
GameInputCreatethread (modules/gameinput.rs): the create line now names its calling thread (thread=ThreadId(n)), and every later call that same thread makes into this module logs one INFO line — slot name, thread, timestamp — for a budget of 40 lines:The honest scope: there is no call-time choke point to follow that thread across every layer boundary — every import binds straight to its implementation or the host at load time (
HleResolver::resolve), and the only central call path is the loader'sunimplemented_importstub, which sees just the unresolved imports. So this traces calls into the gameinput module from that thread; other threads' calls never spend the budget. Silence after the create then means the thread left this module — which is exactly the fork that matters for the "the thread stops there" question, and a laterunimplemented import calledline (already logged by the loader) names the boundary it did reach.Reading the output
One binary runs on both sides, so read the same lines on each (console or
LONGROAD_LOG_FILE, INFO is the default):register_devicelines for the gamepad callback (the+0.4 msregistration), then whatever the thread keeps calling, until the budget ends.gameinput call after the createline from that thread at all (it left this module right after the create — that's run 8's suspected stop). Cross-reference theXUserAddAsynccompletion line's timestamp to place the stop in the boot timeline.Build evidence
cargo check -p longroad-hle(native Linux): fails onmaintoo —longroad-gpu/longroad-loaderneed the Windows SDK (cargo xwin build ... --target x86_64-pc-windows-msvcis the documented route). Verified against a cleanmaincheckout (git stash), so this PR neither fixes nor breaks it.rustup target list --installed→x86_64-pc-windows-msvcpresent.cargo check -p longroad-hle --target x86_64-pc-windows-msvc→ fails only for a missinglib.exe(no MSVC tools on PATH here).cargo xwin check -p longroad-hle --target x86_64-pc-windows-msvc→Checking longroad-hle v0.1.0 ... Finished dev profile ... exit 0(repo-pinned toolchain, rustc 1.98.1; SDK fetched by cargo-xwin).cargo fmt -- --check: none of the added lines show a diff (the crate's pre-existing rustfmt drift on this toolchain is untouched).AI-assisted (Hermes Agent).
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.