[FFmpeg-devel] Support for non-AltiVec PowerPC from Freescale
Sat Jan 30 18:54:40 CET 2010
-----BEGIN PGP SIGNED MESSAGE-----
M?ns Rullg?rd wrote:
> Ancoron Luciferis <ancoron at chaoslayer.de> writes:
>> Hi *,
>> just want to add something to the configure script to ease with
>> compiling for non-altivec PPC CPUs like the MPC85xx from Freescale (e500
>> v2 core).
>> Here's the diff for the 'configure' script:
>> --- configure.orig 2010-01-30 02:17:11.303086681 +0100
>> +++ configure 2010-01-30 02:23:07.863083437 +0100
>> @@ -1912,6 +1912,10 @@
>> enable ldbrx
>> + e500v2|E500V2)
>> + cpuflags="-mcpu=8548 -mhard-float -mfloat-gprs=double"
>> + disable altivec
>> + ;;
> Why use a different tag than the -mcpu flag uses? The cases where we
> match different names are mostly to due to variations in tools like
> uname or if gcc uses a name different from what the cpu is commonly
> known as (which may well be the case here). Also, my gcc manual lists
> -mcpu=8540 but not 8548.
I used a different tag because the tag describes the actual CPU core
used in several different CPUs, so it matches e.g. Freescales MPC8533,
MPC8544 and a lot of others, but not e.g. the MPC8535 or MPC8536. Also
there are -mcpu values for the other eXXX cores like "e300" or "e500mc"
I would add another tag "e500" after the "e500v2" to match the rest of
the PowerQUICC III family to the correct gcc options:
> --- configure.orig 2010-01-30 02:17:11.303086681 +0100
> +++ configure 2010-01-30 18:50:29.000000000 +0100
> @@ -1912,6 +1912,14 @@
> enable ldbrx
> + e500v2|E500V2)
> + cpuflags="-mcpu=8548 -mhard-float -mfloat-gprs=double"
> + disable altivec
> + ;;
> + e500|E500)
> + cpuflags="-mcpu=8540 -mhard-float"
> + disable altivec
> + ;;
> elif enabled x86; then
Althought I'm using the e500 branch of gcc 3.4 the changes made there
have been integrated into the main line years ago. It seams that this
value is only valid for powerpc-linux-gnuspe builds of gcc. I don't know
why it isn't listed in the manual.
To see whether an appropriate gcc has been selected for compilation is
covered by the first cc_check calls. So I think this should be fine.
>> I would really appreciate to see that one included. To answer one of the
>> questions: the mentioned MPC85xx CPUs are build into a lot of devices
>> like NAS's (e.g. Synology DiskStation running BusyBox with kernel 2.6)
>> and other network or media related devices.
> I have nothing against the patch as such.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
More information about the ffmpeg-devel