aboutsummaryrefslogtreecommitdiff
path: root/gas/config/tc-arm.c
diff options
context:
space:
mode:
authorZack Weinberg <zackw@panix.com>2005-06-07 18:03:17 +0000
committerZack Weinberg <zackw@panix.com>2005-06-07 18:03:17 +0000
commit05ab1f3b1c6eb9377b0ea51ded17c95e59fb25dc (patch)
tree15109d018d9b773139da87140ab79c4f7733e240 /gas/config/tc-arm.c
parent55cf6793d851ffd0f14d851eb6d75cac2fe400ff (diff)
downloadgdb-05ab1f3b1c6eb9377b0ea51ded17c95e59fb25dc.zip
gdb-05ab1f3b1c6eb9377b0ea51ded17c95e59fb25dc.tar.gz
gdb-05ab1f3b1c6eb9377b0ea51ded17c95e59fb25dc.tar.bz2
Revert accidental commit
Diffstat (limited to 'gas/config/tc-arm.c')
-rw-r--r--gas/config/tc-arm.c24
1 files changed, 13 insertions, 11 deletions
diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
index 5e7fb74..a3cc432 100644
--- a/gas/config/tc-arm.c
+++ b/gas/config/tc-arm.c
@@ -1414,11 +1414,9 @@ find_real_start (symbolS * symbolP)
if (name == NULL)
abort ();
- /* The compiler may generate BL instructions to local labels because
- it needs to perform a branch to a far away location. These labels
- do not have a corresponding ".real_start_of" label. To accomodate
- hand-written assembly, we don't insist on a leading ".L", just a
- leading dot. */
+ /* Names that start with '.' are local labels, not function entry points.
+ The compiler may generate BL instructions to these labels because it
+ needs to perform a branch to a far away location. */
if (name[0] == '.')
return symbolP;
@@ -10515,8 +10513,7 @@ md_apply_fix (fixS * fixP,
#define SEXT24(x) ((((x) & 0xffffff) ^ (~ 0x7fffff)) + 0x800000)
#ifdef OBJ_ELF
- if (!fixP->fx_done)
- value = fixP->fx_offset;
+ value = fixP->fx_offset;
#endif
/* We are going to store value (shifted right by two) in the
@@ -10586,8 +10583,7 @@ md_apply_fix (fixS * fixP,
newval = md_chars_to_number (buf, INSN_SIZE);
#ifdef OBJ_ELF
- if (!fixP->fx_done)
- value = fixP->fx_offset;
+ value = fixP->fx_offset;
#endif
hbit = (value >> 1) & 1;
value = (value >> 2) & 0x00ffffff;
@@ -10746,8 +10742,7 @@ md_apply_fix (fixS * fixP,
if (diff & 0x400000)
diff |= ~0x3fffff;
#ifdef OBJ_ELF
- if (!fixP->fx_done)
- value = fixP->fx_offset;
+ value = fixP->fx_offset;
#endif
value += diff;
@@ -11358,6 +11353,13 @@ arm_force_relocation (struct fix * fixp)
if (fixp->fx_r_type == BFD_RELOC_RVA)
return 1;
#endif
+#ifdef OBJ_ELF
+ if (fixp->fx_r_type == BFD_RELOC_ARM_PCREL_BRANCH
+ || fixp->fx_r_type == BFD_RELOC_ARM_PCREL_BLX
+ || fixp->fx_r_type == BFD_RELOC_THUMB_PCREL_BLX
+ || fixp->fx_r_type == BFD_RELOC_THUMB_PCREL_BRANCH23)
+ return 1;
+#endif
/* Resolve these relocations even if the symbol is extern or weak. */
if (fixp->fx_r_type == BFD_RELOC_ARM_IMMEDIATE