+2018-08-30 H.J. Lu <hongjiu.lu@intel.com>
+
+ * readelf.c (process_section_headers): Treat SHT_FINI_ARRAY and
+ SHT_PREINIT_ARRAY as relocatable sections.
+
2018-08-30 Chenghua Xu <paul.hua.gm@gmail.com>
* MAINTAINERS: Add myself as a MIPS port maintainer.
&& filedata->section_headers[section->sh_info].sh_type != SHT_NOBITS
&& filedata->section_headers[section->sh_info].sh_type != SHT_NOTE
&& filedata->section_headers[section->sh_info].sh_type != SHT_INIT_ARRAY
+ && filedata->section_headers[section->sh_info].sh_type != SHT_FINI_ARRAY
+ && filedata->section_headers[section->sh_info].sh_type != SHT_PREINIT_ARRAY
/* FIXME: Are other section types valid ? */
&& filedata->section_headers[section->sh_info].sh_type < SHT_LOOS))
{
+2018-08-30 H.J. Lu <hongjiu.lu@intel.com>
+
+ * testsuite/gas/elf/elf.exp: Run section14.
+ * testsuite/gas/elf/section14.d: New file.
+ * testsuite/gas/elf/section14.s: Likewise.
+
2018-08-29 Daniel Cederman <cederman@gaisler.com>
* testsuite/gas/sparc/leon.d: New test.
run_dump_test "section12a"
run_dump_test "section12b"
run_dump_test "section13"
+ run_dump_test "section14"
run_dump_test "dwarf2-1"
run_dump_test "dwarf2-2"
run_dump_test "dwarf2-3"
--- /dev/null
+#name: array sections
+#as: --no-pad-sections
+#readelf: -S --wide
+
+There are [0-9]+ section headers, starting at offset 0x[0-9a-f]+:
+
+Section Headers:
+ +\[Nr\] Name +Type +Addr(ess|) +Off +Size +ES +Flg +Lk +Inf +Al
+ +\[ 0\] +NULL +0+ +0+ +0+ +0+ +0 +0 +0
+#pass
--- /dev/null
+ .section .init_array
+ .align 4
+ .type init_array, %object
+ .size init_array, 4
+init_array:
+ .dc.a foo
+ .section .preinit_array
+ .align 4
+ .type preinit_array, %object
+ .size preinit_array, 4
+preinit_array:
+ .dc.a foo
+ .section .fini_array
+ .align 4
+ .type fini_array, %object
+ .size fini_array, 4
+fini_array:
+ .dc.a foo