https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116614
H.J. Lu <hjl.tools at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Ever confirmed|0 |1 Status|UNCONFIRMED |WAITING Last reconfirmed| |2024-09-06 --- Comment #3 from H.J. Lu <hjl.tools at gmail dot com> --- This diff --git a/libiberty/simple-object-elf.c b/libiberty/simple-object-elf.c index c09c216656c..5775e18767f 100644 --- a/libiberty/simple-object-elf.c +++ b/libiberty/simple-object-elf.c @@ -1291,11 +1291,6 @@ simple_object_elf_copy_lto_debug_sections (simple_object_read *sobj, else sh_map[i] = new_i++; } - if (new_i - 1 >= SHN_LORESERVE) - { - *err = ENOTSUP; - return "Too many copied sections"; - } eow->shdrs = XNEWVEC (unsigned char, shdr_size * (new_i - 1)); /* Then perform the actual copying. */ works for me.