This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

.init_array/.fini_array


I have a question about the .init_array and .fini_array ELF sections.
In gas/config/obj-elf.c these are defined as standard SHT_PROGBITS
sections instead of special SHT_INIT_ARRAY or SHT_FINI_ARRAY sections.
The file contains the comment:

  /* FIXME: The current gcc, as of 2002-03-03, will emit

        .section .init_array,"aw",@progbits

     for __attribute__ ((section (".init_array"))). "@progbits" marks
     the incorrect section type. For now, we make them with
     SHT_PROGBITS. BFD will fix the section type. Gcc should be changed
     to emit

        .section .init_array

I was wondering if there has been any change in this status?  On HP-UX
IA64 I am using the HP linker and it handles these sections so I would
like them to have their correct definitions.

Rather then use

	.section .init_array

in GCC I am currently putting out:

	.section	.init_array,	"aw",	"init_array"

for this section based on CTORS_SECTION_ASM_OP in config/ia64/hpux.h and
I need the correct definition of .init_array/.fini_array/.preinit_array
for this to work.

Steve Ellcey
sje@cup.hp.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]