Fix a potential illegal memory access in the Z80 assembler.
[deliverable/binutils-gdb.git] / gas / config / tc-sparc.h
index f24460cefd63d687f774cc4d78ff3c82fa953a9f..09a23b4213509aee7435f7a8f706d51eb094ef66 100644 (file)
@@ -1,5 +1,5 @@
 /* tc-sparc.h - Macros and type defines for the sparc.
-   Copyright (C) 1989-2017 Free Software Foundation, Inc.
+   Copyright (C) 1989-2020 Free Software Foundation, Inc.
 
    This file is part of GAS, the GNU Assembler.
 
@@ -30,6 +30,9 @@ struct frag;
 
 #define TARGET_ARCH bfd_arch_sparc
 
+extern unsigned long sparc_mach (void);
+#define TARGET_MACH sparc_mach ()
+
 #ifdef TE_FreeBSD
 #define ELF_TARGET_FORMAT      "elf32-sparc"
 #define ELF64_TARGET_FORMAT    "elf64-sparc-freebsd"
@@ -79,29 +82,6 @@ extern void sparc_handle_align (struct frag *);
 
 #define DIFF_EXPR_OK    /* foo-. gets turned into PC relative relocs */
 
-/* I know that "call 0" fails in sparc-coff if this doesn't return 1.  I
-   don't know about other relocation types, or other formats, yet.  */
-#ifdef OBJ_COFF
-#define TC_FORCE_RELOCATION_ABS(FIX)           \
-  ((FIX)->fx_r_type == BFD_RELOC_32_PCREL_S2   \
-   || TC_FORCE_RELOCATION (FIX))
-
-#define RELOC_REQUIRES_SYMBOL
-#endif
-
-#ifdef OBJ_AOUT
-/* This expression evaluates to true if the relocation is for a local
-   object for which we still want to do the relocation at runtime.
-   False if we are willing to perform this relocation while building
-   the .o file.  */
-
-#define TC_FORCE_RELOCATION_LOCAL(FIX)         \
-  (GENERIC_FORCE_RELOCATION_LOCAL (FIX)                \
-   || (sparc_pic_code                          \
-       && S_IS_EXTERNAL ((FIX)->fx_addsy)))
-#endif
-
-#ifdef OBJ_ELF
 /* Don't turn certain relocs into relocations against sections.  This
    is required for the dynamic linker to operate properly.  When
    generating PIC, we need to keep any non PC relative reloc.  The PIC
@@ -139,21 +119,6 @@ extern void sparc_adjust_symtab (void);
      || (FIX)->fx_r_type == BFD_RELOC_32               \
      || (FIX)->fx_r_type == BFD_RELOC_16               \
      || (FIX)->fx_r_type == BFD_RELOC_8))
-#endif
-
-#ifdef OBJ_AOUT
-/* When generating PIC code, we must not adjust any reloc which will
-   turn into a reloc against the global offset table, nor any reloc
-   which we will need if a symbol is overridden.  */
-#define tc_fix_adjustable(FIX)                                         \
-  (! sparc_pic_code                                                    \
-   || ((FIX)->fx_pcrel                                                 \
-       && ((FIX)->fx_addsy == NULL                                     \
-          || (! S_IS_EXTERNAL ((FIX)->fx_addsy)                        \
-              && ! S_IS_WEAK ((FIX)->fx_addsy))))                      \
-   || (FIX)->fx_r_type == BFD_RELOC_16                                 \
-   || (FIX)->fx_r_type == BFD_RELOC_32)
-#endif
 
 #define elf_tc_final_processing sparc_elf_final_processing
 extern void sparc_elf_final_processing (void);
@@ -163,15 +128,11 @@ extern void sparc_elf_final_processing (void);
 extern void sparc_md_end (void);
 #define md_end() sparc_md_end ()
 
-#endif
-
 #define TC_PARSE_CONS_RETURN_TYPE const char *
 #define TC_PARSE_CONS_RETURN_NONE NULL
 
-#ifdef OBJ_ELF
 #define TC_PARSE_CONS_EXPRESSION(EXP, NBYTES) sparc_cons (EXP, NBYTES)
 extern const char *sparc_cons (expressionS *, int);
-#endif
 
 #define TC_CONS_FIX_NEW cons_fix_new_sparc
 extern void cons_fix_new_sparc
@@ -217,4 +178,4 @@ extern int sparc_cie_data_alignment;
    this, BFD_RELOC_32_PCREL will be emitted directly instead.  */
 #define CFI_DIFF_EXPR_OK 0
 
-/* end of tc-sparc.h */
+#endif
This page took 0.027378 seconds and 4 git commands to generate.