aboutsummaryrefslogtreecommitdiff
path: root/binutils
diff options
context:
space:
mode:
authorChristos Zoulas <christos@zoulas.com>2019-06-11 16:43:25 +0100
committerNick Clifton <nickc@redhat.com>2019-06-11 16:43:25 +0100
commit2057d69dccf36206be3bec5d48ff165621e9a06c (patch)
treec7af61bfa548acb9190cfba2c14e22637da75488 /binutils
parent08f10e02be1bb218d6edcde87b9f59dd11b40a78 (diff)
downloadgdb-2057d69dccf36206be3bec5d48ff165621e9a06c.zip
gdb-2057d69dccf36206be3bec5d48ff165621e9a06c.tar.gz
gdb-2057d69dccf36206be3bec5d48ff165621e9a06c.tar.bz2
Add support for reporting Alpha and Vax symbol visibility in readelf.
PR 24662 * readelf.c (get_alpha_symbol_other): New function. (get_symbol_other): Use for Alpha symbols. (is_32bit_pcrel_reloc): Add R_VAX_PCREL32.
Diffstat (limited to 'binutils')
-rw-r--r--binutils/ChangeLog7
-rw-r--r--binutils/readelf.c18
2 files changed, 25 insertions, 0 deletions
diff --git a/binutils/ChangeLog b/binutils/ChangeLog
index cf11c8d..2b6d402 100644
--- a/binutils/ChangeLog
+++ b/binutils/ChangeLog
@@ -1,5 +1,12 @@
2019-06-11 Christos Zoulas <christos@zoulas.com>
+ PR 24662
+ * readelf.c (get_alpha_symbol_other): New function.
+ (get_symbol_other): Use for Alpha symbols.
+ (is_32bit_pcrel_reloc): Add R_VAX_PCREL32.
+
+2019-06-11 Christos Zoulas <christos@zoulas.com>
+
PR 24661
* readelf.c (decode_arm_unwind): Ensure that the local variable
'addr' is always initialised.
diff --git a/binutils/readelf.c b/binutils/readelf.c
index 6246de6..8933ccb 100644
--- a/binutils/readelf.c
+++ b/binutils/readelf.c
@@ -11135,6 +11135,19 @@ get_symbol_visibility (unsigned int visibility)
}
static const char *
+get_alpha_symbol_other (unsigned int other)
+{
+ switch (other)
+ {
+ case STO_ALPHA_NOPV: return "NOPV";
+ case STO_ALPHA_STD_GPLOAD: return "STD GPLOAD";
+ default:
+ error (_("Unrecognized alpah specific other value: %u"), other);
+ return _("<unknown>");
+ }
+}
+
+static const char *
get_solaris_symbol_visibility (unsigned int visibility)
{
switch (visibility)
@@ -11273,6 +11286,9 @@ get_symbol_other (Filedata * filedata, unsigned int other)
switch (filedata->file_header.e_machine)
{
+ case EM_ALPHA:
+ result = get_alpha_symbol_other (other);
+ break;
case EM_AARCH64:
result = get_aarch64_symbol_other (other);
break;
@@ -12722,6 +12738,8 @@ is_32bit_pcrel_reloc (Filedata * filedata, unsigned int reloc_type)
case EM_L1OM:
case EM_K1OM:
return reloc_type == 2; /* R_X86_64_PC32. */
+ case EM_VAX:
+ return reloc_type == 4; /* R_VAX_PCREL32. */
case EM_XTENSA_OLD:
case EM_XTENSA:
return reloc_type == 14; /* R_XTENSA_32_PCREL. */