* tc-pdp11.c: Use VAX float format support for PDP-11 target.
[deliverable/binutils-gdb.git] / gas / config / tc-i960.h
index f60696751f0527695c2abbda9107c0e8bfb23ea6..dfc0a4d727b6a9f279e8cec84551a414e9f031bd 100644 (file)
@@ -1,5 +1,6 @@
 /* tc-i960.h - Basic 80960 instruction formats.
-   Copyright (C) 1989, 90, 91, 92, 93, 94, 95, 96, 97, 1998
+   Copyright 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1997, 1998, 1999,
+   2000
    Free Software Foundation, Inc.
 
    This file is part of GAS, the GNU Assembler.
    You should have received a copy of the GNU General Public License
    along with GAS; see the file COPYING.  If not, write to the Free
    Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-   02111-1307, USA. */
+   02111-1307, USA.  */
 
 #ifndef TC_I960
 #define TC_I960 1
 
+#ifdef OBJ_ELF
+#define TARGET_FORMAT "elf32-i960"
+#define TARGET_ARCH bfd_arch_i960
+#endif
+
 #define TARGET_BYTES_BIG_ENDIAN 0
 
 #define WORKING_DOT_WORD
@@ -57,8 +63,8 @@
 #define OBJ_COFF_SECTION_HEADER_HAS_ALIGNMENT
 #define OBJ_COFF_MAX_AUXENTRIES                        (2)
 #define TC_COUNT_RELOC(FIXP)                   (!(FIXP)->fx_done)
-#define TC_COFF_FIX2RTYPE(FIXP)                        tc_coff_fix2rtype(FIXP)
-#define TC_COFF_SIZEMACHDEP(FRAGP)             tc_coff_sizemachdep(FRAGP)
+#define TC_COFF_FIX2RTYPE(FIXP)                        tc_coff_fix2rtype (FIXP)
+#define TC_COFF_SIZEMACHDEP(FRAGP)             tc_coff_sizemachdep (FRAGP)
 #define TC_COFF_SET_MACHINE(HDRS)              tc_headers_hook (HDRS)
 extern void tc_headers_hook ();
 extern short tc_coff_fix2rtype ();
@@ -96,7 +102,7 @@ extern int tc_coff_sizemachdep ();
 #define        N_CALLNAME      ((char)-1)
 #define        N_BALNAME       ((char)-2)
 
-/* i960 uses a custom relocation record. */
+/* i960 uses a custom relocation record.  */
 
 /* let obj-aout.h know */
 #define CUSTOM_RELOC_FORMAT 1
@@ -125,7 +131,7 @@ struct relocation_info
 #ifdef OBJ_COFF
 
 /* We store the bal information in the sy_tc field.  */
-#define TC_SYMFIELD_TYPE struct symbol *
+#define TC_SYMFIELD_TYPE symbolS *
 
 #define TC_ADJUST_RELOC_COUNT(FIXP,COUNT) \
   { fixS *tcfixp = (FIXP); \
@@ -135,20 +141,39 @@ struct relocation_info
   }
 #endif
 
-extern int i960_validate_fix PARAMS ((struct fix *, segT, struct symbol **));
+extern int i960_validate_fix PARAMS ((struct fix *, segT, symbolS **));
 #define TC_VALIDATE_FIX(FIXP,SEGTYPE,LABEL) \
        if (i960_validate_fix (FIXP, SEGTYPE, &add_symbolP) != 0) goto LABEL
 
+#ifdef OBJ_ELF
+#define TC_RELOC_RTSYM_LOC_FIXUP(FIX)  \
+  ((FIX)->fx_addsy == NULL \
+   || (! S_IS_EXTERNAL ((FIX)->fx_addsy) \
+       && ! S_IS_WEAK ((FIX)->fx_addsy) \
+       && S_IS_DEFINED ((FIX)->fx_addsy) \
+       && ! S_IS_COMMON ((FIX)->fx_addsy)))
+#endif
+
+#ifndef OBJ_ELF
 #define tc_fix_adjustable(FIXP)                ((FIXP)->fx_bsr == 0)
+/* This arranges for gas/write.c to not apply a relocation if
+   tc_fix_adjustable() says it is not adjustable.  */
+#define TC_FIX_ADJUSTABLE(fixP) tc_fix_adjustable (fixP)
+#else
+#define tc_fix_adjustable(FIXP)                                                \
+  ((FIXP)->fx_bsr == 0                                                 \
+   && ! S_IS_EXTERNAL ((FIXP)->fx_addsy)                               \
+   && ! S_IS_WEAK ((FIXP)->fx_addsy))
+#endif
 
 extern void brtab_emit PARAMS ((void));
 #define md_end()       brtab_emit ()
 
 extern void reloc_callj ();
 
-extern void tc_set_bal_of_call PARAMS ((struct symbol *, struct symbol *));
+extern void tc_set_bal_of_call PARAMS ((symbolS *, symbolS *));
 
-extern struct symbol *tc_get_bal_of_call PARAMS ((struct symbol *));
+extern struct symbol *tc_get_bal_of_call PARAMS ((symbolS *));
 
 extern void i960_handle_align ();
 #define HANDLE_ALIGN(FRAG)     i960_handle_align (FRAG)
@@ -167,5 +192,3 @@ extern const struct relax_type md_relax_table[];
 #define TC_INIT_FIX_DATA(F)    ((F)->tc_fix_data.bsr = 0)
 
 #endif
-
-/* end of tc-i960.h */
This page took 0.025303 seconds and 4 git commands to generate.