English Amiga Board

English Amiga Board (http://eab.abime.net/index.php)
-   Coders. C/C++ (http://eab.abime.net/forumdisplay.php?f=118)
-   -   GCC 3.4.0 and soft-float (http://eab.abime.net/showthread.php?t=101844)

TomSoniq 20 April 2020 15:19

GCC 3.4.0 and soft-float
Hi all,

I'm using gcc 3.4.0 as part of the good old amidevcpp package to cross-compile 68k code under MS Windows.

I've been trying to build non-FPU code but so far without success. :(

Here's my very small test program:

int main(void) {
    float a,b,c;
    return 0;

When I compile this using

m68k-amigaos-gcc -noixemul -msoft-float -o FloatTest FloatTest.c
then I instantly get the infamous #8000000B software failure on a non-FPU-system. Even adding -m68000 doesn't help.

Am I doing something wrong? Does this build of GCC support compiling code for FPU emulation at all?

Here's its version info:

Reading specs from /usr/bin/../lib/gcc/m68k-amigaos/3.4.0/specs
Configured with: ../gcc-3.4.0/configure --prefix=/usr/local/amiga --target=m68k-amigaos --enable-languages=c,c++,objc --enable-haifa --enable-sjlj-exceptions --disable-shared --disable-libstdcxx-pch
Thread model: single
gcc version 3.4.0

Any help appreciated. :)

jotd 20 April 2020 16:23

can't you switch to Bebbo's gcc 6 ? it's supported and works good. And I'm pretty sure that it supports floating point AND amidevcpp as well. Plus it's cygwin-free and cygin is crap so all for the best.


jeff b00toNic 20 April 2020 17:09

Well, I was able to compile your code on GCC 3.4.0 emulated in WinUAE
without guru, so it could be that very build.

As jotd already suggested Bebbo's gcc is very good!

TomSoniq 21 April 2020 18:57

Wow thanks! This looks very promising. I gave it a quick try. At the moment I get MuForce hits whenever I fopen() a file and then fseek() in it or rewind() it. I still need to figure out why. Whether it's a bug in the supplied link libraries or something I'm doing wrong.
I also need to find out why my test, when clearly compiled for mathieeesingbas.library, still crashes on my non-FPU WinUAE setup.

TomSoniq 22 April 2020 10:36

Ah, great, someone else noticed the lseek() bug as well, reported it, and it got fixed immediately!
Phantastic. Now switching the AmigaAMP3 68k build to gcc 6.5 :)

All times are GMT +2. The time now is 04:08.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, vBulletin Solutions Inc.

Page generated in 0.04296 seconds with 11 queries