https://gcc.gnu.org/g:1755c3815690bddfe0450b692c58ae98daec1b9c
commit r17-4664-g1755c3815690bddfe0450b692c58ae98daec1b9c Author: Andrea Pinski <[email protected]> Date: Thu Sep 24 21:23:24 2026 -0700 except: Use chain_next on eh_region_d for GTY [PR127602] With many local variables with cleanups needed, we get a huge chain of eh_region_d; and in some cases inside the GC, the stack can overflow. This fixes the issue by using chain_next on eh_region_d. In a similar way r14-2270-gd0a333612bfb7f was done for eh_landing_pad_d. Pushed as obvious after bootstrap/test on x86_64-linux-gnu. PR middle-end/127602 gcc/ChangeLog: * except.h (struct eh_region_d): Add chain_next GTY. Signed-off-by: Andrea Pinski <[email protected]> Diff: --- gcc/except.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/except.h b/gcc/except.h index e0cb9431166c..1988d9f4ad79 100644 --- a/gcc/except.h +++ b/gcc/except.h @@ -115,7 +115,7 @@ struct GTY(()) eh_catch_d /* Describes one exception region. */ -struct GTY(()) eh_region_d +struct GTY((chain_next("%h.next_peer"))) eh_region_d { /* The immediately surrounding region. */ struct eh_region_d *outer;
