- as_bad (_("at 0x%lx, displacement to undefined symbol %s overflows 12-bit field"),
- (unsigned long) fragP->fr_address,
- S_GET_NAME (fragP->fr_symbol));
-
-#if 0
- /* This code works, but generates poor code and the compiler
- should never produce a sequence that requires it to be used. */
-
- /* A jump wont fit in 12 bits, make code which looks like
- bra foo
- mov.w @(0, PC), r14
- .long disp
- foo: bra @r14
- */
- int t = buffer[0] & 0x10;
-
- buffer[highbyte ] = 0xa0; /* branch over move and disp */
- buffer[lowbyte ] = 3;
- buffer[highbyte + 2] = 0xd0 | JREG; /* Build mov insn */
- buffer[lowbyte + 2] = 0x00;
-
- buffer[highbyte + 4] = 0; /* space for 32 bit jump disp */
- buffer[lowbyte + 4] = 0;
- buffer[highbyte + 6] = 0;
- buffer[lowbyte + 6] = 0;
-
- buffer[highbyte + 8] = 0x40 | JREG; /* Build jmp @JREG */
- buffer[lowbyte + 8] = t ? 0xb : 0x2b;
-
- buffer[highbyte + 10] = 0x20; /* build nop */
- buffer[lowbyte + 10] = 0x0b;
-
- /* Make reloc for the long disp. */
- fix_new (fragP,
- fragP->fr_fix + 4,
- 4,
- fragP->fr_symbol,
- fragP->fr_offset,
- 0,
- BFD_RELOC_32);
- fragP->fr_fix += UNCOND32_LENGTH;
+ as_bad_where (fragP->fr_file, fragP->fr_line,
+ _("displacement to undefined symbol %s overflows 12-bit field"),
+ S_GET_NAME (fragP->fr_symbol));
+ /* Stabilize this frag, so we don't trip an assert. */
+ fragP->fr_fix += fragP->fr_var;