This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: mipsel problem


>>Any chance one of the errors was
>>arch/mips/kernel/time.c:278: error: unknown register name `accum' in `asm'

No the stuff in 2.4.18 invloved the compiler.h file and some of the funky stuff the kernel was doing in sysycall.c (I think) 

It was where a small assembly header was placed on top of a C fucntion.  the inline asm was called, would drop through into the C function.  In 3.4.1, they have added optimization that (my understanding) first compiles asm code then goes and does the C code in a file.  What was happening was the inline assembly stuff was being put at the top of the compiled file.  It was not being left where it was, at the top of the C function it was written for.  So when linux would call this inline assembly, it would drop through to a completely different function than what was "expected".  Believe me this was a bugger to find... :-)

Any content within this email is provided "AS IS" for informational purposes only. No contract will be formed between the parties by virtue of this email.
<**************************>
Marc Karasek
System Lead Technical Engineer
iVivity Inc.
PH: 678-990-1550 x238
Fax: 678-990-1551
<**************************>



-----Original Message-----
From: Daniel Kegel [mailto:dank@kegel.com]
Sent: Friday, May 20, 2005 12:28 PM
To: Marc Karasek
Cc: Crossgcc (E-mail)
Subject: Re: mipsel problem


Marc Karasek wrote:
> I have gotten gcc 3.4.1 & glibc 2.3.2 & linux 2.4.18 / 2.6 to cross for mipsel.
> 
> The problem we are seeing is in the dynamic linking.  Static linking to glibc works fine, dynamic crashes with a null pointer. 
> Has anyone else seen this problem?

I haven't seen this exact problem, but I did
bring up a toolchain on sh4, and I had similar
problems.  I ended up debugging them in two ways:
1) by running the glibc and gcc regression tests
(see crosstest-howto), and
2) by starting with a working target environment
from some other source (e.g. montavista), and creating a
chroot jail containing my new environment.  I
then inserted print statements (well, write syscalls) into glibc etc.
until I tracked down the problem.

I poked around a bit, and found some posts that might be related:
http://sources.redhat.com/bugzilla/show_bug.cgi?id=660

> FYI: I am going to put together a patch for the 2.4.18 kernel for it to work with 3.4.1.  There were some minor changes to a few files. 

Any chance one of the errors was
arch/mips/kernel/time.c:278: error: unknown register name `accum' in `asm'
That's what stops linux-2.6.8; see
http://kegel.com/crosstool/current/buildlogs/mipsel-gcc-3.4.3-glibc-2.3.2.log.txt ?

Thanks!
- Dan

------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]