From 43b4c25efc59aa9651305948196a7b00ae8fdfa1 Mon Sep 17 00:00:00 2001 From: Michael Meissner Date: Mon, 29 Nov 1999 00:46:16 +0000 Subject: Add support for !literal and !lituse_base --- gas/config/tc-alpha.h | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) (limited to 'gas/config/tc-alpha.h') diff --git a/gas/config/tc-alpha.h b/gas/config/tc-alpha.h index a350513f3a7..632b04ebc3c 100644 --- a/gas/config/tc-alpha.h +++ b/gas/config/tc-alpha.h @@ -102,3 +102,47 @@ extern void alpha_frob_file_before_adjust PARAMS ((void)); { ".sdata", SHT_PROGBITS, SHF_ALLOC + SHF_WRITE + SHF_ALPHA_GPREL }, \ { ".sbss", SHT_NOBITS, SHF_ALLOC + SHF_WRITE + SHF_ALPHA_GPREL }, #endif + +/* Whether to add support for explict !relocation_op!sequence_number. At the + moment, only do this for ELF, though ECOFF could use it as well. */ + +#ifdef OBJ_ELF +#define RELOC_OP_P +#endif + +#ifdef RELOC_OP_P +/* Before the relocations are written, reorder them, so that user supplied + !lituse relocations follow the appropriate !literal relocations. Also + convert the gas-internal relocations to the appropriate linker relocations. + */ +#define tc_adjust_symtab() alpha_adjust_symtab () +extern void alpha_adjust_symtab PARAMS ((void)); + +/* New fields for supporting explicit relocations (such as !literal to mark + where a pointer is loaded from the global table, and !lituse_base to track + all of the normal uses of that pointer). */ + +#define TC_FIX_TYPE struct alpha_fix_tag + +struct alpha_fix_tag +{ + struct fix *next_lituse; /* next !lituse */ + struct alpha_literal_tag *info; /* other members with same sequence */ +}; + +/* Initialize the TC_FIX_TYPE field. */ +#define TC_INIT_FIX_DATA(fixP) \ +do { \ + fixP->tc_fix_data.next_lituse = (struct fix *)0; \ + fixP->tc_fix_data.info = (struct alpha_literal_tag *)0; \ +} while (0) + +/* Work with DEBUG5 to print fields in tc_fix_type. */ +#define TC_FIX_DATA_PRINT(stream,fixP) \ +do { \ + if (fixP->tc_fix_data.info) \ + fprintf (stderr, "\tinfo = 0x%lx, next_lituse = 0x%lx\n", \ + (long)fixP->tc_fix_data.info, \ + (long)fixP->tc_fix_data.next_lituse); \ +} while (0) +#endif -- cgit v1.2.1