aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorHans-Peter Nilsson <hp@bitrange.com>2014-06-18 00:11:01 +0200
committerHans-Peter Nilsson <hp@bitrange.com>2014-06-18 00:11:01 +0200
commita968e61d8eddf228173019b0265ac6cf6a52cccf (patch)
tree9a69b011aa50ab205c15a83c5903448183cc501a /gas
parent3bca49eec22679298a36f7fb2059169c61b7cbfa (diff)
downloadgdb-a968e61d8eddf228173019b0265ac6cf6a52cccf.zip
gdb-a968e61d8eddf228173019b0265ac6cf6a52cccf.tar.gz
gdb-a968e61d8eddf228173019b0265ac6cf6a52cccf.tar.bz2
GAS: Fix MMIX err-fb-2.s regression caused by recent generic GAS changes.
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog7
-rw-r--r--gas/config/tc-mmix.c11
2 files changed, 18 insertions, 0 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index d75b57f..eaf5c03 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,10 @@
+2014-06-17 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * config/tc-mmix.c (loc_assert_s): New member frag.
+ (s_loc): Set it.
+ (mmix_md_end): If an error is reported for a LOC expression, patch
+ up the related frag.
+
2014-06-17 Chris Metcalf <cmetcalf@tilera.com>
PR gas/16908
diff --git a/gas/config/tc-mmix.c b/gas/config/tc-mmix.c
index ab0fd00..7740ee2 100644
--- a/gas/config/tc-mmix.c
+++ b/gas/config/tc-mmix.c
@@ -112,6 +112,7 @@ static struct loc_assert_s
{
segT old_seg;
symbolS *loc_sym;
+ fragS *frag;
struct loc_assert_s *next;
} *loc_asserts = NULL;
@@ -3560,6 +3561,15 @@ mmix_md_end (void)
as_bad_where (fnam, line,
_("LOC to section unknown or indeterminable "
"at first pass"));
+
+ /* Patch up the generic location data to avoid cascading
+ error messages from later passes. (See original in
+ write.c:relax_segment.) */
+ fragP = loc_assert->frag;
+ fragP->fr_type = rs_align;
+ fragP->fr_subtype = 0;
+ fragP->fr_offset = 0;
+ fragP->fr_fix = 0;
}
}
@@ -4084,6 +4094,7 @@ s_loc (int ignore ATTRIBUTE_UNUSED)
loc_asserts->next = next;
loc_asserts->old_seg = now_seg;
loc_asserts->loc_sym = esym;
+ loc_asserts->frag = frag_now;
}
p = frag_var (rs_org, 1, 1, (relax_substateT) 0, sym, off, (char *) 0);