[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Debian powerpc binary compatibility?

* Sergei Poselenov | 2010-09-17 13:48:19 [+0400]:

>Could you please answer some questions, regarding the use of the 
>Debian powerpc distro for embedded PowerPC system?
>- What exact target CPU it is built for? I see here
>  http://www.debian.org/ports/powerpc/inst/install the list of
>  supported machines, but how can I understand will the Debian binaries
>  work on my board with the specific CPU?
>  Is it possible, knowing only the specific CPU type (440, 603, 8540,
>  8560, etc) to say will it run Debian PowerPC Distro or not?
- 603 are fine.
- I have no clue whether 440 has a FPU or not. If it don't you need
  either to enable enable floating emulation in kernel or a softfloat
- 8540 and 8560 are e500v1 core based cpus. They use the SPE unit for
  single precision floating point operation. This is not compatible with
  the "classic" floating unit in other powerpc like the 603. You may use
  the kernel emulation to work around the problem but they remain a few
  opcodes which trigger an invalid opcode.

>  (I understand that there should be a kernel supporting the specific
>  board; I'm rather interested in the instructions set used by GCC to
>  build the binary images for Debian powerpc distro. In short - what
>  "-mcpu=" GCC option is used for build?)

generic so you can run it on any powerpc. Floating point could be a
problem which can solved by kernel emulation which will make FPU
intesive operation slow. On 85xx lwsync will be another problem.

>- We are considering to rebuild the Debian distribution, to
>  tune the packages for the specific CPU type (enable hardware FP
>  support, etc).
>  I now the Debian powerpc distro is built natively. Are there any
>  details of the build process available, so we could use it in our
>  build system?

For powerpcspe [0] we use powerpc-linux-gnuspe as gcc tripplet which
enables the correct CPU and floating point for us. There is no more
magic behind it.
If you want to rebuild the complete Debian with -mcpu=603 then the
easiest thing would be to put a wrapper around gcc which passes the
correct CFLAGS _or_ make sure that the default cpu is 603. 

[0] http://wiki.debian.org/PowerPCSPEPort

>Thanks for any help.


Reply to: