diff options
author | Bernd Schmidt <bernds@codesourcery.com> | 2010-09-27 15:52:40 +0000 |
---|---|---|
committer | Bernd Schmidt <bernds@codesourcery.com> | 2010-09-27 15:52:40 +0000 |
commit | 43bb514a1cc9641dfdb0f3ac20de48e2c17c0135 (patch) | |
tree | 6653486e8201395216f4f5b90d6aa6b0426d54c4 /gas/config | |
parent | d9aee5d7f73be87d56ac14e0179afbd0dd59cb75 (diff) | |
download | fsf-binutils-gdb-43bb514a1cc9641dfdb0f3ac20de48e2c17c0135.zip fsf-binutils-gdb-43bb514a1cc9641dfdb0f3ac20de48e2c17c0135.tar.gz fsf-binutils-gdb-43bb514a1cc9641dfdb0f3ac20de48e2c17c0135.tar.bz2 |
gas/
* config/tc-tic6x.c (tic6x_fix_adjustable): New function.
* config/tc-tic6x.h (tic6x_fix_adjustable): Declare.
(tc_fix_adjustable): New macro.
gas/testsuite/
* gas/tic6x/got-reloc.s: New test.
* gas/tic6x/got-reloc.d: New test.
Diffstat (limited to 'gas/config')
-rw-r--r-- | gas/config/tc-tic6x.c | 19 | ||||
-rw-r--r-- | gas/config/tc-tic6x.h | 3 |
2 files changed, 22 insertions, 0 deletions
diff --git a/gas/config/tc-tic6x.c b/gas/config/tc-tic6x.c index ea750ba..f1c28d0 100644 --- a/gas/config/tc-tic6x.c +++ b/gas/config/tc-tic6x.c @@ -1591,6 +1591,25 @@ tic6x_init_fix_data (fixS *fixP) fixP->tc_fix_data.fix_adda = FALSE; } +/* Return true if the fix can be handled by GAS, false if it must + be passed through to the linker. */ + +bfd_boolean +tic6x_fix_adjustable (fixS *fixP) +{ + switch (fixP->fx_r_type) + { + /* Adjust_reloc_syms doesn't know about the GOT. */ + case BFD_RELOC_C6000_SBR_GOT_U15_W: + case BFD_RELOC_C6000_SBR_GOT_H16_W: + case BFD_RELOC_C6000_SBR_GOT_L16_W: + return 0; + + default: + return 1; + } +} + /* Given the fine-grained form of an operand, return the coarse (bit-mask) form. */ diff --git a/gas/config/tc-tic6x.h b/gas/config/tc-tic6x.h index d4a3795..a324c02 100644 --- a/gas/config/tc-tic6x.h +++ b/gas/config/tc-tic6x.h @@ -147,6 +147,9 @@ extern void tic6x_start_line_hook (void); extern void tic6x_cons_fix_new (fragS *frag, int where, int size, expressionS *exp); +#define tc_fix_adjustable(FIX) tic6x_fix_adjustable (FIX) +extern bfd_boolean tic6x_fix_adjustable (struct fix *); + #define tc_frob_label(sym) tic6x_frob_label (sym) extern void tic6x_frob_label (symbolS *sym); |