aboutsummaryrefslogtreecommitdiff
path: root/gas/config/tc-nios2.h
diff options
context:
space:
mode:
Diffstat (limited to 'gas/config/tc-nios2.h')
-rw-r--r--gas/config/tc-nios2.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/gas/config/tc-nios2.h b/gas/config/tc-nios2.h
index 340fd76..27ae351 100644
--- a/gas/config/tc-nios2.h
+++ b/gas/config/tc-nios2.h
@@ -101,6 +101,14 @@ extern flagword nios2_elf_section_flags (flagword, int, int);
#define DIFF_EXPR_OK
+/* Don't allow the generic code to convert fixups involving the
+ subtraction of a label in the current section to pc-relative if we
+ don't have the necessary pc-relative relocation. */
+#define TC_FORCE_RELOCATION_SUB_LOCAL(FIX, SEG) \
+ (!((FIX)->fx_r_type == BFD_RELOC_16 \
+ || (FIX)->fx_r_type == BFD_RELOC_NIOS2_LO16 \
+ || (FIX)->fx_r_type == BFD_RELOC_NIOS2_HIADJ16))
+
/* Nios2 ABI doesn't have 32-bit PCREL relocation, and, as relocations for
CFI information will be in section other than .text, we can't use PC-biased
relocs. */