]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Use chain_next on eh_landing_pad_d for GTY (PR middle-end/110510)
authorAndrew Pinski <apinski@marvell.com>
Sat, 1 Jul 2023 17:52:48 +0000 (10:52 -0700)
committerAndrew Pinski <apinski@marvell.com>
Mon, 3 Jul 2023 21:45:33 +0000 (14:45 -0700)
The backtrace in the bug report suggest there is a running out of
stack during GC collection, because of a long chain of eh_landing_pad_d.
This might fix that by adding chain_next onto eh_landing_pad_d's GTY marker.

OK? Bootstrapped and tested on x86_64-linux-gnu with no regressions.

gcc/ChangeLog:

PR middle-end/110510
* except.h (struct eh_landing_pad_d): Add chain_next GTY.

gcc/except.h

index 378a9e4cb77b8ab9ea60b39f03cfff415aeb2244..173b0f026db1702104d7906d62d251472bf20fa7 100644 (file)
@@ -66,7 +66,7 @@ enum eh_region_type
 /* A landing pad for a given exception region.  Any transfer of control
    from the EH runtime to the function happens at a landing pad.  */
 
-struct GTY(()) eh_landing_pad_d
+struct GTY((chain_next("%h.next_lp"))) eh_landing_pad_d
 {
   /* The linked list of all landing pads associated with the region.  */
   struct eh_landing_pad_d *next_lp;