linux-mips
[Top] [All Lists]

Re: Confused assembler

To: pf@net.alphadv.de
Subject: Re: Confused assembler
From: Thiemo Seufer <ica2_ts@csv.ica.uni-stuttgart.de>
Date: Fri, 31 Dec 2004 17:30:09 +0100
Cc: linux-mips@linux-mips.org
In-reply-to: <Pine.LNX.4.58.0412310201350.455@Indigo2.Peter>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <20041225172449.1063A1F123@trashy.coderock.org> <20041227124435.GC26100@linux-mips.org> <Pine.LNX.4.58.0412310201350.455@Indigo2.Peter>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.5.6+20040907i
Peter Fuerst wrote:
> 
> 
> Hello !
> 
> 
> When building 2.6.10, the assembler (2.13.2.1) gets confused by a "b target2"
> (compiler generated) immediately following a "beqzl target1" (inline assembly
> macro), and reorders these instructions (with wrong address calculation too)
> to an infinite loop.
[snip]
> Was this behaviour already observed elsewhere ?  Is it fixed in some newer
> assembler version ?

Fixed in current binutils CVS, IIRC both 2.15 branch and trunk. The
older binutils tarball at linux-mips.org was also fixed.

> Or should i just be content with it and work around
> with appropriate "nop"s in the concerned inline-assembly macros ? ... ?

You should upgrade to something newer than 2.13. :-)

> as -EB -G 0 -mips4 -O2 -g0 -64 -mcpu=r8000 -v -64 -non_shared -64 
> -march=r8000 -mips4 --trap -o kernel/.tmp_fork.o

Note that those arguments are partially contradicting each other.

-mips4 -64 -mcpu=r8000 -64 -64 -march=r8000 -mips4

is (with 2.15 gas) better expressed as

-mabi=64 -march=mips4

or, more suitable for r10000, with

-mabi=64 -march=r10000


Thiemo

<Prev in Thread] Current Thread [Next in Thread>