Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 18 Jan 2007 20:15:53 +0100
From:      Olivier Houchard <mlfbsd@ci0.org>
To:        Hans Petter Selasky <hselasky@c2i.net>
Cc:        Bernd Walter <ticso@cicely12.cicely.de>, freebsd-arm@freebsd.org, ticso@cicely.de
Subject:   Re: Strange assembler warning
Message-ID:  <20070118191553.GA42638@ci0.org>
In-Reply-To: <200701081144.57054.hselasky@c2i.net>
References:  <20070107210212.GP58585@cicely12.cicely.de> <20070107233704.GA34036@ci0.org> <200701081144.57054.hselasky@c2i.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Jan 08, 2007 at 11:44:55AM +0100, Hans Petter Selasky wrote:
> On Monday 08 January 2007 00:37, Olivier Houchard wrote:
> > On Sun, Jan 07, 2007 at 10:02:13PM +0100, Bernd Walter wrote:
> > > I was trying to build Hans Petter's USB stack:
> > > cc -c -O2 -pipe -fno-strict-aliasing -mcpu=arm9 -std=c99  -Wall
> > > -Wredundant-decls -Wnested-externs -Wstrict-prototypes 
> > > -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual  -Wundef
> > > -fformat-extensions -nostdinc -I-  -I. -I../../.. -I../../../contrib/altq
> > > -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common
> > > -finline-limit=8000 --param inline-unit-growth=100 --param
> > > large-function-growth=1000 -mcpu=arm9 -ffreestanding -Werror 
> > > ../../../dev/usb/ohci.c ../../../dev/usb/ohci.c:120:1: "PHYSADDR"
> > > redefined
> > > In file included from <command line>:5:
> > > ./opt_global.h:3:1: this is the location of the previous definition
> > > {standard input}: Assembler messages:
> > > {standard input}:6052: Warning: source register same as write-back base
> > > *** Error code 1
> > >
> > > Stop in /usr/src/sys/arm/compile/FBOX.
> > > 98.000u 3.000s 2:01.33 83.8%    37057+84655k 1+12io 2pf+0w
> > > Exit 1
> > > [86]arm9#
> > >
> > > Ok - the PHYADDR is a name collision with the kernel load address.
> > > After removing the clash it compiles.
> > > But the assembler warning remains.
> >
> > Hi Bernd,
> >
> > Could you put the assembler file, as provided my cc -S, and ohci.c
> > somewhere online ? This typically happens with gcc allocating the wrong
> > registers with inline asm, so we need to figure out which code is at fault,
> > and try to fix it or work around the problem.
> >
> > Thanks !
> >
> > Olivier
> 
> Hi Bernd,
> 
> Could you send me a diff when you are finished, and I will look over the 
> changes and integrate your work in my SVN and p4 tree.
> 
> Oliver: Did you find the reason for the Assembler warning ?
> 
> --HPS

Erm it seems I totally forgot to answer your mails, sorry Bernd that was not
against you, just me being the usual idiot I am.
By reading the code, I'm afraid it looks like a gcc bug, this code doesn't
seem to be related with inline asm. You may try your luck tweaking the code
to get gcc to generate something else. I'm afraid I have no great idea.

Cheers,

Olivier



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070118191553.GA42638>