0xc000001d Illegal instruction (CLWB) crash on AMD Ryzen 7 #210
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Marvisak--VIctory#210
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
@FulhR on GitHub · 2026-11-24 01:27 UTC · original
Bug report
Description
VIctory crashes during initial system initialization due to an illegal CPU instruction (
CLWB).The host CPU supports AVX2 but does not support the
CLWBinstruction.Error details
Steps to reproduce
victory.exe run --execute.0xc000001d.Expected behavior
VIctory should detect whether the host CPU supports
CLWBbefore executing it and provide a compatible fallback when the instruction is unavailable.Actual behavior
An unsupported
CLWBinstruction is executed, causing an illegal instruction exception (0xc000001d) and terminating the process.Additional information
git grep -i clwbdoes not find a direct reference to this instruction.Possible solution
Could a CPU feature check or a fallback implementation be added for systems that support AVX2 but do not support
CLWB?Is this an expected hardware limitation, or could it be addressed in VIctory?
@DaviTostes on GitHub · 2026-11-24 01:32 UTC · original
Current
mainhandles this instruction, so the first thing to check is the build.crates/victory-loader/src/crash.rsemulatesclwb m8(66 [rex] 0f ae /6) in the illegal-instruction handler:clwb_lenskips a single write-back hint, andclwb_loopcompletes a whole write-back loop in one exception. That came in with #45, merged as7d33c46.97c78d1), rebuild from currentmain(d2a4baeas of now) and theclwb [r9]at+0x4ecc84ashould no longer fault.main, the useful datum is the crash log's refused-instruction bytes plus the exact CPU model. The handler matches by encoding, so a segment prefix or a REX variant it does not expect is what would explain it. #198 (open) adds those bytes to the crash report, which makes this diagnosable without a debugger.Related: #7, #106 and #108 are the same class (CLWB/CLZERO/
rdpru); #34 (open) extends the handler toclzeroloops andrdpru.No game data used.
@Marvisak on GitHub · 2026-11-25 01:44 UTC · original · edited 2026-11-25 01:52 UTC
Automated triage for the maintainers.
+0x4ecc84ais the sameclwbwrite-back loop reported in #102, #103 and #108. The cause is tracked in #102 (oldest report of this crash); #106 reports the relatedclzerocase.mainhandles this:crates/victory-loader/src/crash.rs,emulate_amd_only, catches the illegal-instruction exception and usesclwb_loop(whole write-back loop in one exception) orclwb_len(skip oneclwb). The66 41 0f ae 31(clwb [r9]) encoding is covered. This arrived with #45 (merge7d33c46, 2026-11-24 00:30 UTC), shortly before this report; on #108 a reporter confirmed the title gets past this point after updating.main, rebuild and retry. If it still crashes, please post the VIctory commit (git rev-parse HEAD), the exact CPU model, GPU and driver version, Windows version, and thecrashes.logentry. Since #198 the log includes the bytes of the refused instruction, which shows which encoding was not recognised.Generated by Claude Code