[clang] [llvm] [win][x64] Add support for Windows x64 unwind v3 (PR #200249)
Mészáros Gergely via cfe-commits
cfe-commits at lists.llvm.org
Mon Jun 1 07:23:03 PDT 2026
================
@@ -0,0 +1,165 @@
+; RUN: llc -mtriple=x86_64-unknown-windows-msvc -o - %s | FileCheck %s
+
+; Test that the V3 pass correctly handles funclets. Each funclet gets its own
+; UNWIND_INFO, so V3 capacity limits (≤31 prolog ops, ≤7 epilogs) apply per
+; funclet, not summed across the entire function.
+;
+; This function has 15 cleanup funclets, each with its own prolog/epilog.
+; Each funclet generates ~2 prolog ops (push rbp + stack alloc), plus the
+; main function has ~3 (push rbp + stack alloc + set frame). The total across
+; all funclets (~33) exceeds the 31-op V3 limit, but each individual funclet
+; is well within limits. The V3 pass must not report_fatal_error for this case.
----------------
Maetveis wrote:
```suggestion
; all funclets (~33) exceeds the 31-op V3 limit, but each individual funclet
; is well within limits. The V3 pass should handle this without errors.
```
NIT: It's better not to be overly specific about the kind of error the pass whould not produce.
https://github.com/llvm/llvm-project/pull/200249
More information about the cfe-commits
mailing list