[Bug other/46770] Replace .ctors/.dtors with .init_array/.fini_array on targets supporting them

ccoutant at google dot com gcc-bugzilla@gcc.gnu.org
Tue Apr 17 18:54:00 GMT 2012


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46770

--- Comment #81 from ccoutant at google dot com 2012-04-17 18:52:11 UTC ---
>> As Paul noted, this is a moot point in practice for .ctors, since GCC emits
>> only a single .ctors entry per TU, but it could be significant for assembly
>> code or for TUs with .init_array sections.
>
> That is my concern. .init_array section in the same TU can may have
> more than one entry due to:
>
> 1. Assembly code.
> 2. constructor attribute in C source.
> 3. .init_array section attribute in C source.
>
> We need to spell out exactly what --reverse-init-array should do.

Didn't I just do that?

-cary



More information about the Gcc-bugs mailing list