GNU Toolchain 4.1.1 and GDB for the Cell BE's PPU/SPU

The Cell BE's PPU (Power Processor Unit) uses the same instruction set as the PowerPC 970 processor. The toolchain includes a GCC compiler for PPU to cross-compile on x86 and as a replacement for the native GCC compiler on ppc platforms. The GCC compiler for the PPU is preferred and the make files are configured to use it when building the Libraries and Samples. This release also includes a Fortran compiler for PPU as a replacement for the native Fortran compiler on ppc platforms. The GCC compiler also contains a separate SPE cross-compiler that supports the standards defined in the SPU C/C++ Language Extensions V2.6, SPU Application Binary Interface Specification V1.7, and Synergistic Processor Unit (SPU) Instruction Set Architecture V1.2 documents. The associated assembler and linker additionally support the SPU Assembly Language Specification V1.5. The toolchain is based on a port of GCC, GDB and the GNU binutils to the Cell Broadband Engine Architecture (CBEA) provided by Sony Computer Entertainment Inc.

The cross-compiling GNU Toolchain is installed into the /opt/cell/ directory while the ppc toolchain will be installed into /usr.


Binary Packages


 
PowerPC
x86 cross-compiler
 
PPU
SPU
PPU
SPU
GNU Binutils
ppc
ppc
i686
i686
GNU GCC Compiler
ppc
ppc
i686
i686
GNU GCC C++ Compiler
ppc
ppc
i686
i686
GNU GNAT
ppc
N/A
i686
N/A
GNU Fortran Compiler
ppc
ppc
i686
i686
GNU GDB
ppc
ppc
i686
i686
GNU newlib C library
N/A
ppc
N/A
i686
GNU GCC debuginfo
ppc
ppc
i686
i686
GNU GDB debuginfo
ppc
ppc
i686
i686

GCC 4.3 (prototype code)

In SDK 3.1, GCC 4.3 is also shipped as part of the toolchain as prototype code.

 
PowerPC
x86 cross-compiler
 
PPU
SPU
PPU
SPU
GNU GCC Compiler
ppc
ppc
i686
i686
GNU GCC C++ Compiler
ppc
ppc
i686
i686
GNU GCC debuginfo
ppc
ppc
i686
i686
GNU Fortran Compiler
ppc
ppc
i686
i686

GNU Toolchain on a Fedora 9 x86 machine

To install the GNU Toolchain in a Fedora 9 x86 machine in order to cross-compile applications, you need to install the two following rpms:

File Description
ppu-sysroot-f9-2.noarch.rpm Basic libraries and headers for cross-compiling to Cell Broadband Engine's PPU.
ppu-sysroot64-f9-2.noarch.rpm Basic libraries and headers for cross-compiling to Cell Broadband Engine's PPU (64-bit).

GNU Toolchain on a RHEL 5.2 x86 machine

To install the GNU Toolchain on a RHEL 5.2 x86 machine to cross-compile applications, you need to create and install ppu-sysroot rpms for RHEL.

To build that rpms for GNU Toolchain installation on RHEL you need to do the following:

  1. Download ppu-sysroot.spec file and copy it to /usr/redhat/SPECS.
  2. Copy following RPMS from you RHEL5 U2 distribution to /usr/redhat/SOURCES:
    • glibc-2.5-24.ppc.rpm
    • glibc-2.5-24.ppc64.rpm
    • glibc-devel-2.5-24.ppc.rpm
    • glibc-devel-2.5-24.ppc64.rpm
    • glibc-headers-2.5-24.ppc.rpm
    • kernel-headers--2.6.18-92.el5.ppc.rpm
    • gmp-4.1.4-10.el5.ppc.rpm
    • gmp-4.1.4-10.el5.ppc64.rpm
    • gmp-devel-4.1.4-10.el5.ppc.rpm
    • gmp-devel-4.1.4-10.el5.ppc64.rpm
  3. To build the ppu-sysroot files type: rpmbuild -ba ppu-sysroot.spec --target noarch

This would generate ppu-sysroot-rhel5-6.noarch.rpm and ppu-sysroot64-rhel5-6.noarch.rpm that must be installed in your RHEL5 U2 x86 box.

GNU Toolchain on a RHEL 5.3 x86 machine

To install the GNU Toolchain on a RHEL5.3 x86 machine to cross-compile applications, you need to create and install ppu-sysroot rpms for RHEL.

Before you can build that rpms for GNU Toolchain installation on RHEL you need to do download the ppu-sysroot.spec file for RHEL5.3 from http://www.bsc.es/projects/deepcomputing/linuxoncell/cellsimulator/sdk3.1/sources/toolchain/rhel5.3-ppu-sysroot/

The next steps are described in the README available for SDK 3.1 on RHEL5.3 which is available at the Cell Broadband Engine Architecture forum at http://www.ibm.com/developerworks/forums/forum.jspa?forumID=739&cat=46




GNU Toolchain Source distribution and build files

To rebuild the GNU toolchain, We provide the source rpms that can be easily installed but also the source tarballs and the set of patches that were used to build the binary distribution.


Source RPM packages

 

File Description
ppu-gcc-4.1.1-166.src.rpm GNU GCC source package for the Cell BE's PPU.
spu-gcc-4.1.1-166.src.rpm GNU GCC source package for the Cell BE's SPU.
ppu-binutils-2.18.50-21.src.rpm GNU Binutils source package for the Cell BE's PPU.
spu-binutils-2.18.50-21.src.rpm GNU Binutils source package for the Cell BE's SPU.
ppu-gdb-6.8.50-13.src.rpm GNU GDB source package for the Cell BE's PPU.
spu-gdb-6.8.50-13.src.rpm GNU GDB source package for the Cell BE's SPU.
ppu-sysroot-f7-2.src.rpm PPU sysroot toolchain source package.
spu-newlib-1.16.0-17.src.rpm GNU newlib source package for the Cell BE's SPU.

Source RPM packages for GCC 4.3 (prototype code)

 

File Description
ppu-gcc43-4.3.2-2.src.rpm GNU GCC 4.3 source package for the Cell BE's PPU.
spu-gcc43-4.3.2-2.src.rpm GNU GCC 4.3 source package for the Cell BE's SPU.