This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: nop in load-delay-slot (on MIPS o32 PIC code)
- From: cgd at broadcom dot com
- To: anemo at mba dot ocn dot ne dot jp
- Cc: binutils at sources dot redhat dot com
- Date: 20 Apr 2004 08:26:00 -0700
- Subject: Re: nop in load-delay-slot (on MIPS o32 PIC code)
- References: <20040420.203314.102583229.nemoto@toshiba-tops.co.jp><mailpost.1082460801.27630@news-sj1-1>
At Tue, 20 Apr 2004 11:33:21 +0000 (UTC), "Atsushi Nemoto" wrote:
> In MIPS PIC code, mips-linux-as produces a nop for load-delay-slot in
> many case even if -march=mips2 was specified.
> [ ... ]
> I think this nop can be omitted on "!gpr_interlocks" condition. Is
> this nop required by MIPS ABI(o32) ? The march=mips2 option should
> not override this behavior ?
You are correct. This is an issue, but probably not worth fixing IMO.
I've got patches against an old version of binutils that did this for
lots of the cases that we cared about. But, it was fairly invasive,
and, if i recall correctly, involved touching variant frags in some
cases. There aren't enough test cases for these code paths, either,
which means that if one did this 'right' then it should also include a
bunch of new test cases (which we didn't do, for our own use here).
IMO The right solution is to use a newer compiler (3.4 8-) that
generates explicit relocs and .set noreorder code, so when the
explicit relocs code came along I dropped the patch from my source
tree.
I can probably find the patch for you w/o too much trouble. But it's
nowhere near suitable for inclusion into binutils as-is.
chris