Fri Feb 21 14:34:31 1997 Martin M. Hunt <hunt@pizza.cygnus.com>

* config/tc-d10v.c (md_pcrel_from_section): Return 0 if
        relocation is in different section. Fixes PR11574.
This commit is contained in:
Martin Hunt
1997-02-21 22:36:21 +00:00
parent 80e3b2aa53
commit 09d9ef26c9
2 changed files with 18 additions and 12 deletions

View File

@ -1,3 +1,8 @@
Fri Feb 21 14:34:31 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
* config/tc-d10v.c (md_pcrel_from_section): Return 0 if
relocation is in different section. Fixes PR11574.
Fri Feb 21 10:08:25 1997 Jim Wilson <wilson@cygnus.com>
* tc-mips.c (mips_ip): If configured for an embedded ELF system,

View File

@ -1,6 +1,6 @@
/* tc-d10v.c -- Assembler code for the Mitsubishi D10V
Copyright (C) 1996 Free Software Foundation.
Copyright (C) 1996, 1997 Free Software Foundation.
This file is part of GAS, the GNU Assembler.
@ -1253,7 +1253,8 @@ md_pcrel_from_section (fixp, sec)
fixS *fixp;
segT sec;
{
if (fixp->fx_addsy != (symbolS *)NULL && !S_IS_DEFINED (fixp->fx_addsy))
if (fixp->fx_addsy != (symbolS *)NULL && (!S_IS_DEFINED (fixp->fx_addsy) ||
(S_GET_SEGMENT (fixp->fx_addsy) != sec)))
return 0;
return fixp->fx_frag->fr_address + fixp->fx_where;
}