Porting GDC?

Mike Groble michael.groble at mindspring.com
Tue May 1 08:28:40 PDT 2007


I tried building GDC on my PS3.  I got to a certain point and gave
up.

I am running YDL on my PS3.  I downloaded the SDK 2.1 source RPMs
from the Barcelona site (http://www.bsc.es/plantillaH.php?
cat_id=304). I installed GDC 0.23 on top of the ppu-gcc code and
tried to build natively on the PS3.

First is that the cell version modifies floating point macros that
break code in in d-gcc-real.cc.  I don't know exacly what I am
doing.  To get past the errors, I changed lines like:

 REAL_ARITHMETIC(x.rv(), MINUS_EXPR, rv(), r.rv());

to
 REAL_ARITHMETIC(x.rv(), MINUS_EXPR, rv(), r.rv(), max_float_mode
());

Note, there are more macros that changed than just this one, but I
modified all the same way to give them the required machine_mode
parameter they wanted.

The compiler built after that, but then phobos failed compiling.  I
don't remember the exact error, but the error message mentioned
some floating point function like sqrt.

It seems to me that there will need to be some work to get the
floating point capabilities provided by the cell processors to work
correctly with GDC.  My real interest is getting it to run on the
spu-gcc version of the compiler which I think will be harder
still.  I did enough to realize I am a little over my head and the
build doesn't work "straight out of the box". I'd be willing to try
some experiments if people have suggestions.


More information about the D.gnu mailing list