This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
Running with gdb, it looks like the problem comes from the ppc_closure.S file of the libffi/src/powerpc directory, at line 32 :
stfd %f1, 48(%r1)
I don't understand anything to powerpc assembly, but after a google search, "stfd" means "store floating-point double". But the PPC405 doesn't have any FPU, so I guess that's why it throws an "illegal instruction".
I've compiled again my cross toolchain with the "--with-float=soft" option, hoping that it would emulate FPU instruction, but this unfortunately doesn't help... I'm nevertheless not sure that this option is the right one...
Any thoughts ? Is there a bug in libffi in that it doesn't support powerpc CPU without FPU ?
On 5/8/07, Andrew Haley <aph-gcc@littlepinkcloud.com> wrote:Patrick Olinet writes:
> Hi there,
>
> I'm running an embedded platform based on a powerpc 405EP CPU and a
> gcc 4.1.0 cross-toolchain. My initial problem was that gcj compiled
> binaries crash at runtime when interpreting java bytecode ("Illegal
> instruction" message).
>
> After many investigations, it looks like the problem comes from the
> libffi library : I've run the libffi testsuite on my embedded paltform
> and many of the tests show the same "Illegal instruction" message. For
> instance, the "cls_uint" test crashes at the following line (from the
> cls_uint.c file) :
>
> res = (*((cls_ret_uint)pcl))(2147483647);
>
> My knowledge about the powerpc architectures is very limited, but I've
> seen mailing lists threads talking about "EABI" that I don't quite
> understand but my intuition is that it could be related. For instance,
> could it be that my cross toolchain is not compiled with the right
> EABI (does this question make sense??) ?
>
> Any ideas or thoughts about this problem ?
Run it in gdb. When gdb stops with SIGILL, do
x/i $pc
Andrew.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |