aboutsummaryrefslogtreecommitdiff
path: root/binutils/objdump.c
diff options
context:
space:
mode:
authorMickael Guene <mickael.guene@st.com>2016-01-20 12:53:50 +0000
committerNick Clifton <nickc@redhat.com>2016-01-20 12:53:50 +0000
commit91f68a68f992e3f6c3da26c616b5257230bd1eec (patch)
tree9e549da0d8aaacafb6231069425241f003357a14 /binutils/objdump.c
parentbe56871ee8f65c51b9eee611532ed036a71a72e0 (diff)
downloadgdb-91f68a68f992e3f6c3da26c616b5257230bd1eec.zip
gdb-91f68a68f992e3f6c3da26c616b5257230bd1eec.tar.gz
gdb-91f68a68f992e3f6c3da26c616b5257230bd1eec.tar.bz2
Add support for an ARM specific 'y' section attribute flag to mark the section as NOREAD.
bfd/ChangeLog: * elf32-arm.c ((elf32_arm_special_sections): Remove catch of noread section using '.text.noread' pattern. gas/ChangeLog: * config/obj-elf.c (obj_elf_change_section) : Allow arm section with SHF_ARM_NOREAD section flag. * config/tc-arm.h (md_elf_section_letter) : Implement this hook to handle letter 'y'. (arm_elf_section_letter) : Declare it. * config/tc-arm.c (arm_elf_section_letter): Handle letter 'y' to set SHF_ARM_NOREAD section flag. * doc/c-arm.texi (ARM section attribute 'y'): Document it. gas/testsuite/ChangeLog: * gas/arm/section-execute-only.s: New test case. * gas/arm/section-execute-only.d: Expected output. ld/testsuite/ChangeLog: * ld-arm/thumb1-noread-not-present-mixing-two-section.s: Add 'y' attribute usage. * ld-arm/thumb1-noread-present-one-section.s: Likewise. * ld-arm/thumb1-noread-present-two-section.s: Likewise. * ld-arm/thumb1-input-section-flag-match.s: Likewise. binutils/ChangeLog: * readelf.c (get_elf_section_flags): Display y letter for section with SHF_ARM_NOREAD section flag in readelf section output. (process_section_headers): Add y letter in readelf section output key mapping for ARM architecture.
Diffstat (limited to 'binutils/objdump.c')
-rw-r--r--binutils/objdump.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/binutils/objdump.c b/binutils/objdump.c
index fa991a9..3c94a76 100644
--- a/binutils/objdump.c
+++ b/binutils/objdump.c
@@ -488,9 +488,23 @@ dump_section_header (bfd *abfd, asection *section,
}
PF (SEC_SMALL_DATA, "SMALL_DATA");
if (bfd_get_flavour (abfd) == bfd_target_coff_flavour)
- PF (SEC_COFF_SHARED, "SHARED");
+ {
+ PF (SEC_COFF_SHARED, "SHARED");
+ PF (SEC_COFF_NOREAD, "NOREAD");
+ }
+ else if (bfd_get_flavour (abfd) == bfd_target_elf_flavour)
+ {
+ /* Note - sections can have both the READONLY and NOREAD attributes
+ set. In this case the NOREAD takes precedence, but we report both
+ since the user may need to know that both bits are set. */
+ PF (SEC_ELF_NOREAD, "NOREAD");
+ }
PF (SEC_THREAD_LOCAL, "THREAD_LOCAL");
PF (SEC_GROUP, "GROUP");
+ if (bfd_get_arch (abfd) == bfd_arch_mep)
+ {
+ PF (SEC_MEP_VLIW, "VLIW");
+ }
if ((section->flags & SEC_LINK_ONCE) != 0)
{