From 28ad2e2dc94bf73896eda64f0084c1395219673a Mon Sep 17 00:00:00 2001 From: Michael Eager Date: Wed, 31 Oct 2012 15:27:37 +0000 Subject: 2012-10-31 David Holsgrove * config/tc-microblaze.c: Check for weak symbols before emitting relocation. 2012-10-31 David Holsgrove * gas/microblaze: New. * gas/microblaze/reloc_sym.exp: Add test case. * gas/microblaze/reloc_strongsym.s: Likewise. * gas/microblaze/reloc_weaksym.s: Likewise. * gas/microblaze/reloc_sym.d: Likewise. --- gas/config/tc-microblaze.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'gas/config/tc-microblaze.c') diff --git a/gas/config/tc-microblaze.c b/gas/config/tc-microblaze.c index 3ab854f..86ac90b 100644 --- a/gas/config/tc-microblaze.c +++ b/gas/config/tc-microblaze.c @@ -2065,7 +2065,8 @@ md_estimate_size_before_relax (fragS * fragP, as_bad (_("Absolute PC-relative value in relaxation code. Assembler error.....")); abort (); } - else if ((S_GET_SEGMENT (fragP->fr_symbol) == segment_type)) + else if (S_GET_SEGMENT (fragP->fr_symbol) == segment_type && + !S_IS_WEAK (fragP->fr_symbol)) { fragP->fr_subtype = DEFINED_PC_OFFSET; /* Don't know now whether we need an imm instruction. */ -- cgit v1.1