Config: an alias pattern with several '*' matches its DLLs #2310
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl!2310
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/2310/head"
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?
@gefydev on GitHub · 2026-11-25 13:32 UTC · original
gefydev:config-glob-several-stars→main· +35 −4 · 1 files · 1 commits · merged 2026-11-25 16:15 UTCAn alias in
xcl.tomlwhose DLL pattern has more than one*, such asapi-ms-win-*-l1-1-*.dll, never matched a DLL:glob_matchsplit the pattern at the first*and compared everything after it as plain text, so the second*had to appear in the DLL's name. The alias was ignored with no message. Patterns with one*or none, which are all that XCL's own table uses, answer as before.What is in it
crates/xcl/src/util.rs:glob_matchreads*as any run of characters, anywhere and as often as the pattern has it: the start is matched at the start, the parts between the stars in order, the last part at the end.globbing_with_several_stars: a two-star API-set pattern that matches and one that does not,a*b*cagainst names that do and do not match, the non-overlap of the two ends (ab*baagainstaba), a lone*and**.Tested
assertion failed: glob_match("api-ms-win-*-l1-1-*.dll", "api-ms-win-core-file-l1-1-0.dll")) and passes with it; the existingglobbingtest passes in both.cargo build --workspace, thencargo test --workspace --no-fail-fast -- --test-threads=4onf8ce21d: 1251 passed, 0 failed, 46 ignored. 26 SKIPPED, none of them on a path this change touches: 20 wave64 cases ("no wave64" on this GPU), 3 per-lane f16 cases the per-lane form refuses, 1 "no heap windows", 2 for the D3D12 debug layer not being installed.Regression run
scripts/smoke.ps1 -Game <title folder> -Seconds 60, release builds, the same machine and title for both, one after the other. An earlier run of this branch had come out at 499 frames and 15 294 MB of peak commit, against 910 frames and 11 693 MB for main in its first run; the next two runs of each were within a few percent of each other (main 888 and 911 frames, this branch 902 and 928), so I take the first one as that machine's run-to-run spread (#2225) and show the last pair.main:
PR:
Not tested
Registry::routein a title's run: the unit test callsglob_match, the function the route uses.AI use
@oni-swr on GitHub · 2026-11-25 13:45 UTC · original
CPU-only review of #2310 at head
f8ce21de8f599635d9c811edbd4d6f59c8c84fc5, onorigin/mainafc5ee86ae3a9521c9f15d96505cd73fe72f2191(the PR is based on1a0bbe3; it merges into currentmainwithout conflicts).Tested
origin/main(all three merge cleanly together) and rancargo test -p xcl --lib --no-run: compiles; the 2 warnings are in code these PRs do not touch.cargo test -p xcl --lib util:: -- --test-threads=1: 6 passed, 0 failed, 0 ignored (includes the newglobbing_with_several_starsand the oldglobbing)Review
glob_match: prefix is stripped, middle parts are taken in order at their first occurrence, the last part is checked as the tail of what is left, so the parts cannot overlap (ab*bavsaba,a*avsa). Edge cases"",*,**and no-star behave as the test says. The new test would have failed on the oldsplit_onceversion (e.g.a*b*cvsaXbYbZc). No issues found. Matching is still case-sensitive as before.Overlap
glob_match(searched open PRs).Not tested
scripts/smoke.ps1/ any title run. This is not a replacement for the GPU suite or the smoke run the PR template asks for.AI use
stable-x86_64-pc-windows-msvc, debug build, CPU only. I read the full diff; nothing was changed or pushed.@gefydev on GitHub · 2026-11-25 13:48 UTC · original
@oni-swr thank you for the review of #2310 at
f8ce21donorigin/mainafc5ee8:util::6 passed, 0 failed, a clean merge with #2311 and #2312, and no issues inglob_match. The full suite (1251 passed, 0 failed, 46 ignored) and the smoke pair are in the description; no GPU suite was part of your run, as you say.AI use: Claude Code (Claude Sonnet 5.5) wrote this comment for @gefydev.
@nnonno91 on GitHub · 2026-11-25 14:33 UTC · original
I checked a two-star alias through TOML parsing and
Registry::routeonf8ce21de8f599635d9c811edbd4d6f59c8c84fc5.Tested
cargo test --locked -p xcl --lib globbing -- --nocapture --test-threads=1gave 2 passed, 0 failed.hle::tests::local_two_star_alias_from_tomlfixture parsed"api-ms-win-*-l1-1-*.dll" = "@stub"in[aliases], built the registry and checked its routes. Three matching names selected the configured route, including two empty wildcard spans. Three near misses kept their default routes. The API-set file DLL also had a different route in the default registry, so the check exercised precedence.cargo test --locked -p xcl --lib hle::tests::local_two_star_alias_from_toml -- --exact --nocapture --test-threads=1gave 1 passed, 0 failed. Both runs had 0 ignores and no skips. The temporary fixture was removed.Not tested
A running title importing through this alias, the parent and the full workspace suite.
AI use
OpenAI Codex (GPT-6.2 Sol) wrote the temporary fixture, ran the tests and prepared this report.
@gefydev on GitHub · 2026-11-25 14:47 UTC · original
@nnonno91 thank you for the report on #2310 at
f8ce21d(Ryzen 7 9800X3D, Windows 11 build 26200.9974, Rust 1.100.0, CPU only). It covers what the description lists as not tested, a two-star alias through the TOML andRegistry::route:globbing2 passed, 0 failed, and your temporary fixture with"api-ms-win-*-l1-1-*.dll" = "@stub"selected the configured route for three matching names (two with empty wildcard spans), kept the default route for three near misses, and the default registry gave the API-set file DLL a different route, so precedence was exercised. The fixture was removed and no title ran, as you say.AI use: Claude Code (Claude Sonnet 5.5) wrote this comment for @gefydev.
@DavidM1911 on GitHub · 2026-11-25 17:41 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!