diff options
author | Alan Modra <amodra@gmail.com> | 2001-01-16 13:52:16 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2001-01-16 13:52:16 +0000 |
commit | 64afeba3893573416b124daeca5987131df1b73e (patch) | |
tree | e59ae1fca3538a7b1ce9c0a9d423080eb3370cf6 /gas/config | |
parent | 1d3d5051d1ed664e87708905372b2465024bc6c5 (diff) | |
download | binutils-gdb-64afeba3893573416b124daeca5987131df1b73e.tar.gz |
Support hand-crafted .PARISC.unwind entries
Diffstat (limited to 'gas/config')
-rw-r--r-- | gas/config/tc-hppa.c | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/gas/config/tc-hppa.c b/gas/config/tc-hppa.c index ac258ce307b..f87b57a12df 100644 --- a/gas/config/tc-hppa.c +++ b/gas/config/tc-hppa.c @@ -4047,14 +4047,6 @@ tc_gen_reloc (section, fixp) code = *codes[0]; - reloc->sym_ptr_ptr = (asymbol **) xmalloc (sizeof (asymbol *)); - *reloc->sym_ptr_ptr = symbol_get_bfdsym (fixp->fx_addsy); - reloc->howto = bfd_reloc_type_lookup (stdoutput, - (bfd_reloc_code_real_type) code); - reloc->address = fixp->fx_frag->fr_address + fixp->fx_where; - - assert (reloc->howto && (unsigned int) code == reloc->howto->type); - /* Now, do any processing that is dependent on the relocation type. */ switch (code) { @@ -4088,10 +4080,24 @@ tc_gen_reloc (section, fixp) break; #endif + case R_PARISC_DIR32: + /* Facilitate hand-crafted unwind info. */ + if (strcmp (section->name, UNWIND_SECTION_NAME) == 0) + code = R_PARISC_SEGREL32; + /* Fall thru */ + default: reloc->addend = fixp->fx_offset; break; } + + reloc->sym_ptr_ptr = (asymbol **) xmalloc (sizeof (asymbol *)); + *reloc->sym_ptr_ptr = symbol_get_bfdsym (fixp->fx_addsy); + reloc->howto = bfd_reloc_type_lookup (stdoutput, + (bfd_reloc_code_real_type) code); + reloc->address = fixp->fx_frag->fr_address + fixp->fx_where; + + assert (reloc->howto && (unsigned int) code == reloc->howto->type); break; } #else /* OBJ_SOM */ |