daily update
[deliverable/binutils-gdb.git] / bfd / coff-i860.c
index c02acce861ea08935c22b398e3dec3bd58c77ea0..b862ff7f0c292b0f3c227a5acaa7d7bc40420596 100644 (file)
@@ -1,5 +1,6 @@
 /* BFD back-end for Intel 860 COFF files.
-   Copyright 1990, 91, 92, 93, 94, 95, 97, 1999 Free Software Foundation, Inc.
+   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1999, 2000, 2001, 2002, 2003
+   Free Software Foundation, Inc.
    Created mostly by substituting "860" for "386" in coff-i386.c
    Harry Dolan <dolan@ssd.intel.com>, October 1995
 
@@ -35,6 +36,7 @@ static reloc_howto_type *coff_i860_rtype_to_howto
   PARAMS ((bfd *, asection *, struct internal_reloc *,
           struct coff_link_hash_entry *, struct internal_syment *,
           bfd_vma *));
+static const bfd_target * i3coff_object_p PARAMS ((bfd *));
 
 #define COFF_DEFAULT_SECTION_ALIGNMENT_POWER (2)
 /* The page size is a guess based on ELF.  */
@@ -45,7 +47,7 @@ static reloc_howto_type *coff_i860_rtype_to_howto
    section for a reference to a common symbol is the value itself plus
    any desired offset.  Ian Taylor, Cygnus Support.  */
 
-/* If we are producing relocateable output, we need to do some
+/* If we are producing relocatable output, we need to do some
    adjustments to the object file that are not done by the
    bfd_perform_relocation function.  This function is called by every
    reloc type to make any required adjustments.  */
@@ -85,7 +87,7 @@ coff_i860_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
     {
       /* For some reason bfd_perform_relocation always effectively
         ignores the addend for a COFF target when producing
-        relocateable output.  This seems to be always wrong for 860
+        relocatable output.  This seems to be always wrong for 860
         COFF, so we handle the addend here instead.  */
       diff = reloc_entry->addend;
     }
@@ -112,7 +114,7 @@ coff_i860_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
            {
              short x = bfd_get_16 (abfd, addr);
              DOIT (x);
-             bfd_put_16 (abfd, x, addr);
+             bfd_put_16 (abfd, (bfd_vma) x, addr);
            }
            break;
 
@@ -120,7 +122,7 @@ coff_i860_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
            {
              long x = bfd_get_32 (abfd, addr);
              DOIT (x);
-             bfd_put_32 (abfd, x, addr);
+             bfd_put_32 (abfd, (bfd_vma) x, addr);
            }
            break;
 
@@ -134,7 +136,7 @@ coff_i860_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
 }
 
 #ifndef PCRELOFFSET
-#define PCRELOFFSET false
+#define PCRELOFFSET FALSE
 #endif
 
 static reloc_howto_type howto_table[] =
@@ -149,29 +151,29 @@ static reloc_howto_type howto_table[] =
         0,                     /* rightshift */
         2,                     /* size (0 = byte, 1 = short, 2 = long) */
         32,                    /* bitsize */
-        false,                 /* pc_relative */
+        FALSE,                 /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_bitfield, /* complain_on_overflow */
         coff_i860_reloc,       /* special_function */
         "dir32",               /* name */
-        true,                  /* partial_inplace */
+        TRUE,                  /* partial_inplace */
         0xffffffff,            /* src_mask */
         0xffffffff,            /* dst_mask */
-        true),                /* pcrel_offset */
+        TRUE),                /* pcrel_offset */
   /* {7}, */
   HOWTO (R_IMAGEBASE,            /* type */
         0,                     /* rightshift */
         2,                     /* size (0 = byte, 1 = short, 2 = long) */
         32,                    /* bitsize */
-        false,                 /* pc_relative */
+        FALSE,                 /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_bitfield, /* complain_on_overflow */
         coff_i860_reloc,       /* special_function */
         "rva32",                  /* name */
-        true,                  /* partial_inplace */
+        TRUE,                  /* partial_inplace */
         0xffffffff,            /* src_mask */
         0xffffffff,            /* dst_mask */
-        false),                /* pcrel_offset */
+        FALSE),                /* pcrel_offset */
   EMPTY_HOWTO (010),
   EMPTY_HOWTO (011),
   EMPTY_HOWTO (012),
@@ -183,12 +185,12 @@ static reloc_howto_type howto_table[] =
         0,                     /* rightshift */
         0,                     /* size (0 = byte, 1 = short, 2 = long) */
         8,                     /* bitsize */
-        false,                 /* pc_relative */
+        FALSE,                 /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_bitfield, /* complain_on_overflow */
         coff_i860_reloc,       /* special_function */
         "8",                   /* name */
-        true,                  /* partial_inplace */
+        TRUE,                  /* partial_inplace */
         0x000000ff,            /* src_mask */
         0x000000ff,            /* dst_mask */
         PCRELOFFSET),          /* pcrel_offset */
@@ -196,12 +198,12 @@ static reloc_howto_type howto_table[] =
         0,                     /* rightshift */
         1,                     /* size (0 = byte, 1 = short, 2 = long) */
         16,                    /* bitsize */
-        false,                 /* pc_relative */
+        FALSE,                 /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_bitfield, /* complain_on_overflow */
         coff_i860_reloc,       /* special_function */
         "16",                  /* name */
-        true,                  /* partial_inplace */
+        TRUE,                  /* partial_inplace */
         0x0000ffff,            /* src_mask */
         0x0000ffff,            /* dst_mask */
         PCRELOFFSET),          /* pcrel_offset */
@@ -209,12 +211,12 @@ static reloc_howto_type howto_table[] =
         0,                     /* rightshift */
         2,                     /* size (0 = byte, 1 = short, 2 = long) */
         32,                    /* bitsize */
-        false,                 /* pc_relative */
+        FALSE,                 /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_bitfield, /* complain_on_overflow */
         coff_i860_reloc,       /* special_function */
         "32",                  /* name */
-        true,                  /* partial_inplace */
+        TRUE,                  /* partial_inplace */
         0xffffffff,            /* src_mask */
         0xffffffff,            /* dst_mask */
         PCRELOFFSET),          /* pcrel_offset */
@@ -222,12 +224,12 @@ static reloc_howto_type howto_table[] =
         0,                     /* rightshift */
         0,                     /* size (0 = byte, 1 = short, 2 = long) */
         8,                     /* bitsize */
-        true,                  /* pc_relative */
+        TRUE,                  /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_signed, /* complain_on_overflow */
         coff_i860_reloc,       /* special_function */
         "DISP8",               /* name */
-        true,                  /* partial_inplace */
+        TRUE,                  /* partial_inplace */
         0x000000ff,            /* src_mask */
         0x000000ff,            /* dst_mask */
         PCRELOFFSET),          /* pcrel_offset */
@@ -235,12 +237,12 @@ static reloc_howto_type howto_table[] =
         0,                     /* rightshift */
         1,                     /* size (0 = byte, 1 = short, 2 = long) */
         16,                    /* bitsize */
-        true,                  /* pc_relative */
+        TRUE,                  /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_signed, /* complain_on_overflow */
         coff_i860_reloc,       /* special_function */
         "DISP16",              /* name */
-        true,                  /* partial_inplace */
+        TRUE,                  /* partial_inplace */
         0x0000ffff,            /* src_mask */
         0x0000ffff,            /* dst_mask */
         PCRELOFFSET),          /* pcrel_offset */
@@ -248,12 +250,12 @@ static reloc_howto_type howto_table[] =
         0,                     /* rightshift */
         2,                     /* size (0 = byte, 1 = short, 2 = long) */
         32,                    /* bitsize */
-        true,                  /* pc_relative */
+        TRUE,                  /* pc_relative */
         0,                     /* bitpos */
         complain_overflow_signed, /* complain_on_overflow */
         coff_i860_reloc,       /* special_function */
         "DISP32",              /* name */
-        true,                  /* partial_inplace */
+        TRUE,                  /* partial_inplace */
         0xffffffff,            /* src_mask */
         0xffffffff,            /* dst_mask */
         PCRELOFFSET)           /* pcrel_offset */
@@ -341,12 +343,12 @@ coff_i860_rtype_to_howto (abfd, sec, rel, h, sym, addendp)
         with and without this section bypassed and then do a binary comparison,
         the addresses which are different can be looked up in the map.  The
         case in which this section has been bypassed has addresses which correspond
-        to values I can find in the map */
+        to values I can find in the map */
       *addendp -= sym->n_value;
     }
 
   /* If the output symbol is common (in which case this must be a
-     relocateable link), we need to add in the final size of the
+     relocatable link), we need to add in the final size of the
      common symbol.  */
   if (h != NULL && h->root.type == bfd_link_hash_common)
     *addendp += h->root.u.c.size;
@@ -362,7 +364,7 @@ static const bfd_target *
 i3coff_object_p(a)
      bfd *a;
 {
-  return coff_object_p(a);
+  return coff_object_p (a);
 }
 
 const bfd_target
This page took 0.0341 seconds and 4 git commands to generate.