[all-commits] [llvm/llvm-project] 5d811c: llc: Verify MIR outputs by default
Matt Arsenault via All-commits
all-commits at lists.llvm.org
Thu Oct 1 14:18:26 PDT 2026
Branch: refs/heads/users/arsenm/llc/verify-mir-output
Home: https://github.com/llvm/llvm-project
Commit: 5d811c1771d59f288f2b974aa01ea821119bed7a
https://github.com/llvm/llvm-project/commit/5d811c1771d59f288f2b974aa01ea821119bed7a
Author: Matt Arsenault <Matthew.Arsenault at amd.com>
Date: 2026-10-01 (Thu, 01 Oct 2026)
Changed paths:
M llvm/include/llvm/CodeGen/TargetPassConfig.h
M llvm/include/llvm/Target/CGPassBuilderOption.h
M llvm/lib/CodeGen/CodeGenTargetMachineImpl.cpp
M llvm/lib/CodeGen/TargetPassConfig.cpp
M llvm/lib/Passes/CodeGenPassBuilder.cpp
M llvm/test/CodeGen/X86/callbr-asm-outputs-indirect-isel-m32.ll
M llvm/test/CodeGen/X86/callbr-asm-outputs-indirect-isel.ll
A llvm/test/tools/llc/disable-mir-output-verify.mir
M llvm/test/tools/llc/new-pm/start-stop.ll
M llvm/tools/llc/lib/NewPMDriver.cpp
M llvm/tools/llc/lib/llcdriver.cpp
Log Message:
-----------
llc: Verify MIR outputs by default
MIR is validated by the machine verifier on read, but by default wasn't
validated on output. This differs from opt, which runs the verifier on
output unless explicitly disabled. -verify-machineinstrs is frequently used as
a much more expensive way of getting the verifier run, since that runs between
every pass.
Run the machine verifier at the end of the pipeline whenever it stops before code
emission. Add -disable-mir-output-verify to suppress this. It is separate from
-disable-verify, which still only controls verification of the IR input. The
extra verifier is skipped when the verifier already runs after every machine
pass, with -verify-machineinstrs in the legacy pass manager or -verify-each in
the new pass manager.
Some tests had to force disabling the verifier in a few tests which already fail
the verifier.
Unlike opt, the driver can't simply verify after the pass manager finishes.
MachineFunctions are freed as soon as they are printed. The verifier therefore
has to be added per function inside the pipeline, including the pipelines built
by addPassesToEmitFile and CodeGenPassBuilder for -stop-before/-stop-after.
Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list