OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [trunk/] [gnu-src/] [binutils-2.20.1/] [gas/] [config/] [tc-or32.c] - Diff between revs 241 and 413

Show entire file | Details | Blame | View Log

Rev 241 Rev 413
Line 1... Line 1...
/* Assembly backend for the OpenRISC 1000.
/* Assembly backend for the OpenRISC 1000.
   Copyright (C) 2002, 2003, 2005, 2007, 2009
   Copyright (C) 2002, 2003, 2005, 2007, 2009
 
   Copyright (C) 2010 Embecosm Limited
   Free Software Foundation, Inc.
   Free Software Foundation, Inc.
   Contributed by Damjan Lampret <lampret@opencores.org>.
   Contributed by Damjan Lampret <lampret@opencores.org>.
   Modified bu Johan Rydberg, <johan.rydberg@netinsight.se>.
   Modified bu Johan Rydberg, <johan.rydberg@netinsight.se>.
               Gyorgy Jeney <nog@sdf.lonestar.org>
               Gyorgy Jeney <nog@sdf.lonestar.org>
   Based upon a29k port.
   Based upon a29k port.
Line 963... Line 964...
/* Exactly what point is a PC-relative offset relative TO?
/* Exactly what point is a PC-relative offset relative TO?
   On the 29000, they're relative to the address of the instruction,
   On the 29000, they're relative to the address of the instruction,
   which we have set up as the address of the fixup too.  */
   which we have set up as the address of the fixup too.  */
 
 
long
long
md_pcrel_from (fixS *fixP)
md_pcrel_from_section (fixS *fixP, segT sec)
{
{
 
#ifndef USE_REL
 
  if (TC_FORCE_RELOCATION (fixP)
 
      || (fixP->fx_addsy != (symbolS *) NULL
 
          && S_GET_SEGMENT (fixP->fx_addsy) != sec))
 
    {
 
      /* If we can't adjust this relocation, or if it references a
 
         local symbol in a different section (which
 
         TC_FORCE_RELOCATION can't check), let the linker figure it
 
         out.  */
 
      return 0;
 
    }
 
#endif
 
 
  return fixP->fx_where + fixP->fx_frag->fr_address;
  return fixP->fx_where + fixP->fx_frag->fr_address;
}
}
 
 
/* Generate a reloc for a fixup.  */
/* Generate a reloc for a fixup.  */
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.