diff options
author | Nick Clifton <nickc@redhat.com> | 2006-05-05 17:46:47 +0000 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2006-05-05 17:46:47 +0000 |
commit | 731608473ad5f49c490c51ced17213db5ffddcef (patch) | |
tree | 49981af58839525c8df270f308acc8c648117e9e /gas/config/tc-avr.h | |
parent | 605a56cbd3e45de9304a5bdd2f877fa0d15627c1 (diff) | |
download | gdb-731608473ad5f49c490c51ced17213db5ffddcef.zip gdb-731608473ad5f49c490c51ced17213db5ffddcef.tar.gz gdb-731608473ad5f49c490c51ced17213db5ffddcef.tar.bz2 |
* gas/config/tc-avr.h (TC_VALIDATE_FIX): Define. Disable fixups for PMEM
related expressions.
* bfd/elf32-avr.c (elf32_avr_relax_delete_bytes): Iterate over all of the
bfd's sections for the reloc-addend adjustments.
Diffstat (limited to 'gas/config/tc-avr.h')
-rw-r--r-- | gas/config/tc-avr.h | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/gas/config/tc-avr.h b/gas/config/tc-avr.h index df12045..61e76e6 100644 --- a/gas/config/tc-avr.h +++ b/gas/config/tc-avr.h @@ -1,5 +1,5 @@ /* This file is tc-avr.h - Copyright 1999, 2000, 2001, 2002, 2005 Free Software Foundation, Inc. + Copyright 1999, 2000, 2001, 2002, 2005, 2006 Free Software Foundation, Inc. Contributed by Denis Chertykov <denisc@overta.ru> @@ -109,7 +109,7 @@ extern long md_pcrel_from_section (struct fix *, segT); would print `12 34 56 78'. The default value is 4. */ #define LISTING_WORD_SIZE 2 -/* AVR port uses `$' as a logical line separator */ +/* AVR port uses `$' as a logical line separator. */ #define LEX_DOLLAR 0 /* An `.lcomm' directive with no explicit alignment parameter will @@ -120,3 +120,20 @@ extern long md_pcrel_from_section (struct fix *, segT); also affected by this macro. The default definition will set P2VAR to the truncated power of two of sizes up to eight bytes. */ #define TC_IMPLICIT_LCOMM_ALIGNMENT(SIZE, P2VAR) (P2VAR) = 0 + +/* We don't want gas to fixup the following program memory related relocations. + We will need them in case that we want to do linker relaxation. + We could in principle keep these fixups in gas when not relaxing. + However, there is no serious performance penilty when making the linker + make the fixup work. */ +#define TC_VALIDATE_FIX(FIXP,SEG,SKIP) \ + if ( FIXP->fx_r_type == BFD_RELOC_AVR_7_PCREL \ + || FIXP->fx_r_type == BFD_RELOC_AVR_13_PCREL \ + || FIXP->fx_r_type == BFD_RELOC_AVR_LO8_LDI_PM \ + || FIXP->fx_r_type == BFD_RELOC_AVR_HI8_LDI_PM \ + || FIXP->fx_r_type == BFD_RELOC_AVR_HH8_LDI_PM \ + || FIXP->fx_r_type == BFD_RELOC_AVR_16_PM) \ + { \ + goto SKIP; \ + } + |