Skip to contentSkip to conversation

Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

PATCH In review David Nyström 6 participants 22 messages Jan 10, 2014 – Feb 27, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

The reverted commit seems to introduce some problems for the toolchain tarball for powerpc.
I see this both in master and on dora.

1. Looks like the relocation scripts fails for environments:

~/tests/poky [master]

$ cat /opt/oel/2014-01-01/environment-setup-ppce500v2-oel-linux | grep "#"
export SDKTARGETSYSROOT=##SDKTARGETSYSROOT##

~/tests/poky [master]

$ cat /opt/oel/2014-01-01/environment-setup-ppce500v2-oel-linux-gnuspe | grep "#"

2. nativeSDK gnuspe compiler does not allow -mabi=spe ABIEXTENSION is zeroed both for linux-gnuspe and linux

3. Compiler can't create executables.
I think this is due to libgcc_s.so from the SDK target sysroot is in mabi=spe.

4. -mspe is included in CC var for both linux and gnuspe.
cat /opt/oel/2014-01-01/environment-setup-ppce500v2-oel-linux | grep mabi export CC="powerpc-oel-linux-gcc -m32 -mcpu=8548 -mabi=spe -mspe .... export CXX="powerpc-oel-linux-g++ -m32 -mcpu=8548 -mabi=spe -mspe .... export CPP="powerpc-oel-linux-gcc -E -m32 -mcpu=8548 -mabi=spe -mspe ....

With the commit reverted, I can successfully build target code with the canadian compiler from the SDK tarball. Only the gnuspe environment file is generated.

This reverts commit 11d9127ac57514394f8297f9fdfc7b31e163fcb8.

---
 meta/classes/cross-canadian.bbclass                | 31 ----------------------
 .../binutils/binutils-cross-canadian.inc           |  2 --
 meta/recipes-devtools/gcc/gcc-cross-canadian.inc   |  5 +---
 meta/recipes-devtools/gdb/gdb-cross-canadian.inc   |  1 -
 4 files changed, 1 insertion(+), 38 deletions(-)
meta/classes/cross-canadian.bbclass +0 -31
index c974212..7181c60 100644
@@ -15,30 +15,12 @@ STAGING_BINDIR_TOOLCHAIN = "${STAGING_DIR_NATIVE}${bindir_native}/${SDK_ARCH}${S
 # Update BASE_PACKAGE_ARCH and PACKAGE_ARCHS
 #
 PACKAGE_ARCH = "${SDK_ARCH}-${SDKPKGSUFFIX}"
-CANADIANEXTRAOS = ""
 python () {
     archs = d.getVar('PACKAGE_ARCHS', True).split()
     sdkarchs = []
     for arch in archs:
         sdkarchs.append(arch + '-${SDKPKGSUFFIX}')
     d.setVar('PACKAGE_ARCHS', " ".join(sdkarchs))
-
-    # PowerPC can build "linux" and "linux-gnuspe"
-    tarch = d.getVar("TARGET_ARCH", True)
-    if tarch == "powerpc":
-        tos = d.getVar("TARGET_OS", True)
-        if (tos != "linux" and tos != "linux-gnuspe"):
-            bb.fatal("Building cross-candian powerpc for an unknown TARGET_SYS (%s), please update cross-canadian.bbclass" % d.getVar("TARGET_SYS", True))
-        # Have to expand DEPENDS before we change the extensions
-        d.setVar("DEPENDS", d.getVar("DEPENDS", True))
-        d.setVar("STAGING_BINDIR_TOOLCHAIN", d.getVar("STAGING_BINDIR_TOOLCHAIN", True))
-        for prefix in ["AR", "AS", "DLLTOOL", "CC", "CXX", "GCC", "LD", "LIPO", "NM", "OBJDUMP", "RANLIB", "STRIP", "WINDRES"]:
-            n = prefix + "_FOR_TARGET"
-            d.setVar(n, d.getVar(n, True))
-
-        d.setVar("LIBCEXTENSION", "")
-        d.setVar("ABIEXTENSION", "")
-        d.setVar("CANADIANEXTRAOS", "linux-gnuspe")
 }
 MULTIMACH_TARGET_SYS = "${PACKAGE_ARCH}${HOST_VENDOR}-${HOST_OS}"
 
@@ -118,16 +100,3 @@ TARGET_ARCH[vardepsexclude] = "TUNE_ARCH"
 # points to the wrong place so force it
 SHLIBSDIRS = "${PKGDATA_DIR}/nativesdk-shlibs"
 SHLIBSWORKDIR = "${PKGDATA_DIR}/nativesdk-shlibs"
-
-cross_canadian_bindirlinks () {
-	for i in ${CANADIANEXTRAOS}
-	do
-		d=${D}${bindir}/../${TARGET_ARCH}${TARGET_VENDOR}-$i
-		install -d $d
-		for j in `ls ${D}${bindir}`
-		do
-			p=${TARGET_ARCH}${TARGET_VENDOR}-$i-`echo $j | sed -e s,${TARGET_PREFIX},,`
-			ln -s ../${TARGET_SYS}/$j $d/$p
-		done
-       done
-}
meta/recipes-devtools/binutils/binutils-cross-canadian.inc +0 -2
index 81349c0..2da9017 100644
@@ -22,8 +22,6 @@ do_install () {
 	rm -f ${D}${libdir}/libiberty*
 	rm -f ${D}${libdir}/libopcodes*
 	rm -f ${D}${includedir}/*.h
-	
-	cross_canadian_bindirlinks
 }
 
 BBCLASSEXTEND = ""
meta/recipes-devtools/gcc/gcc-cross-canadian.inc +1 -4
index 900f1e5..64bb6ba 100644
@@ -29,7 +29,6 @@ export AS_FOR_TARGET = "${TARGET_PREFIX}as"
 export DLLTOOL_FOR_TARGET = "${TARGET_PREFIX}dlltool"
 export CC_FOR_TARGET = "${TARGET_PREFIX}gcc"
 export CXX_FOR_TARGET = "${TARGET_PREFIX}g++"
-export GCC_FOR_TARGET = "${TARGET_PREFIX}gcc"
 export LD_FOR_TARGET = "${TARGET_PREFIX}ld"
 export LIPO_FOR_TARGET = "${TARGET_PREFIX}lipo"
 export NM_FOR_TARGET = "${TARGET_PREFIX}nm"
@@ -70,7 +69,7 @@ EXCLUDE_FROM_SHLIBS = "1"
 PACKAGES = "${PN} ${PN}-doc"
 
 FILES_${PN} = "\
-    ${exec_prefix}/bin/* \
+    ${bindir}/* \
     ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/* \
     ${gcclibdir}/${TARGET_SYS}/${BINV}/*.o \
     ${gcclibdir}/${TARGET_SYS}/${BINV}/specs \
@@ -138,8 +137,6 @@ do_install () {
 	done
 
 	chown -R root:root ${D}
-	
-	cross_canadian_bindirlinks
 }
 
 ELFUTILS = "nativesdk-elfutils"
meta/recipes-devtools/gdb/gdb-cross-canadian.inc +0 -1
index 653f52b..3cb347b 100644
@@ -31,6 +31,5 @@ EOF
 # right bits installed by binutils.
 do_install_append() {
 	rm -rf ${D}${exec_prefix}/lib
-	cross_canadian_bindirlinks
 }
 
Signature · 1 line
1.8.3.2
#1 lore raw
Quoted 19 lines · David Nyström

The reverted commit seems to introduce some problems for the toolchain tarball for powerpc.
I see this both in master and on dora.

1. Looks like the relocation scripts fails for environments:

~/tests/poky [master]

$ cat /opt/oel/2014-01-01/environment-setup-ppce500v2-oel-linux | grep "#"
export SDKTARGETSYSROOT=##SDKTARGETSYSROOT##

~/tests/poky [master]

$ cat /opt/oel/2014-01-01/environment-setup-ppce500v2-oel-linux-gnuspe | grep "#"

2. nativeSDK gnuspe compiler does not allow -mabi=spe ABIEXTENSION is zeroed both for linux-gnuspe and linux

3. Compiler can't create executables.
I think this is due to libgcc_s.so from the SDK target sysroot is in mabi=spe.

Quoted 8 lines

4. -mspe is included in CC var for both linux and gnuspe.
cat /opt/oel/2014-01-01/environment-setup-ppce500v2-oel-linux | grep mabi export CC="powerpc-oel-linux-gcc -m32 -mcpu=8548 -mabi=spe -mspe .... export CXX="powerpc-oel-linux-g++ -m32 -mcpu=8548 -mabi=spe -mspe .... export CPP="powerpc-oel-linux-gcc -E -m32 -mcpu=8548 -mabi=spe -mspe ....

With the commit reverted, I can successfully build target code with the canadian compiler from the SDK tarball. Only the gnuspe environment file is generated.

Ok, so how do you propose we fix the issues the patch was added to address?

Cheers,

Richard

#2 lore raw
Quoted 29 lines · Richard Purdie
Quoted 19 lines · David Nyström

The reverted commit seems to introduce some problems for the toolchain tarball for powerpc.
I see this both in master and on dora.

1. Looks like the relocation scripts fails for environments:

~/tests/poky [master]

$ cat /opt/oel/2014-01-01/environment-setup-ppce500v2-oel-linux | grep "#"
export SDKTARGETSYSROOT=##SDKTARGETSYSROOT##

~/tests/poky [master]

$ cat /opt/oel/2014-01-01/environment-setup-ppce500v2-oel-linux-gnuspe | grep "#"

2. nativeSDK gnuspe compiler does not allow -mabi=spe ABIEXTENSION is zeroed both for linux-gnuspe and linux

3. Compiler can't create executables.
I think this is due to libgcc_s.so from the SDK target sysroot is in mabi=spe.

Quoted 8 lines

4. -mspe is included in CC var for both linux and gnuspe.
cat /opt/oel/2014-01-01/environment-setup-ppce500v2-oel-linux | grep mabi export CC="powerpc-oel-linux-gcc -m32 -mcpu=8548 -mabi=spe -mspe .... export CXX="powerpc-oel-linux-g++ -m32 -mcpu=8548 -mabi=spe -mspe .... export CPP="powerpc-oel-linux-gcc -E -m32 -mcpu=8548 -mabi=spe -mspe ....

With the commit reverted, I can successfully build target code with the canadian compiler from the SDK tarball. Only the gnuspe environment file is generated.

Quoted 7 lines

Ok, so how do you propose we fix the issues the patch was added to address?

Cheers,

Richard

Just to clarify bug 5354:
If I understand the bug correctly, this would arise when first building the nativesdk tarball on a MACHINE with ABI linux, and then building the nativesdk for another MACHINE(with the same the same TUNE) after altering ABIEXTENSION to linux-gnuspe ?

If I understand bug 5354 correctly, perhaps the tmp/sdk/tarball.here can be ABI specific ? i.e. a generic rule that all nativesdk builds are invalidated if the ABI changes. I guess that would mean:
cross-canadian.bbclass: TARGET_ARCH[vardeps] += "ABIEXTENSION"
+ Adding ABIEXTENSION to the nativesdk tarball name.

PPC '=mabi=spe' seems to be one-way compatible, I could not get the non-SPE configured compiler to work with the SPE sysroot.
Another possible solution would be to always configure the compiler to SPE, and use compile time flags in the environment file to do the selects. + symlinks for the compiler paths.
However, even if we fix it this way for powerpc, we will still have this issue with thumb f.ex.

It would be good if the Freescale folks could chime in here.

Br,
David

#3 lore raw
Quoted 8 lines · David Nyström

Just to clarify bug 5354:
If I understand the bug correctly, this would arise when first building the nativesdk tarball on a MACHINE with ABI linux,
and then building the nativesdk for another MACHINE(with the same the same TUNE) after altering ABIEXTENSION to linux-gnuspe ?

If I understand bug 5354 correctly, perhaps the tmp/sdk/tarball.here can be ABI specific ?

The idea behind the changes to cross-canadian were to have just a single gcc/binutils which generated all of the appropriate targets for a given architecture.

I understood this to be possible but it looks like we may need to tweak things a bit.

Quoted 11 lines

i.e. a generic rule that all nativesdk builds are invalidated if the ABI changes. I guess that would mean:
cross-canadian.bbclass: TARGET_ARCH[vardeps] += "ABIEXTENSION"
+ Adding ABIEXTENSION to the nativesdk tarball name.

PPC '=mabi=spe' seems to be one-way compatible, I could not get the non-SPE configured compiler
to work with the SPE sysroot.
Another possible solution would be to always configure the compiler to SPE, and use compile time flags in the
environment file to do the selects. + symlinks for the compiler paths.

Can we configure the compiler to include SPE support without changing the paths/OS string?

Quoted 2 lines

However, even if we fix it this way for powerpc, we will still have this issue with thumb f.ex.

Keep in mind the target sysroot still varies for each different target. The thing we're trying to keep in common is the gcc/bintuils and only have one copy for each target architecture. Is that possible in this case if we somehow enable SPE support in gcc-cross-canadian?

Cheers,

Richard

#4 lore raw
Quoted 29 lines · Richard Purdie
Quoted 8 lines · David Nyström

Just to clarify bug 5354:
If I understand the bug correctly, this would arise when first building the nativesdk tarball on a MACHINE with ABI linux,
and then building the nativesdk for another MACHINE(with the same the same TUNE) after altering ABIEXTENSION to linux-gnuspe ?

If I understand bug 5354 correctly, perhaps the tmp/sdk/tarball.here can be ABI specific ?

The idea behind the changes to cross-canadian were to have just a single gcc/binutils which generated all of the appropriate targets for a given architecture.

I understood this to be possible but it looks like we may need to tweak things a bit.

Quoted 11 lines

i.e. a generic rule that all nativesdk builds are invalidated if the ABI changes. I guess that would mean:
cross-canadian.bbclass: TARGET_ARCH[vardeps] += "ABIEXTENSION"
+ Adding ABIEXTENSION to the nativesdk tarball name.

PPC '=mabi=spe' seems to be one-way compatible, I could not get the non-SPE configured compiler
to work with the SPE sysroot.
Another possible solution would be to always configure the compiler to SPE, and use compile time flags in the
environment file to do the selects. + symlinks for the compiler paths.

Quoted 2 lines

Can we configure the compiler to include SPE support without changing the paths/OS string?

Possibly, but I don't know enough about SPE to be sure. Perhaps Zhenhua can add a few cents here.

Short summary of problem:
All SPE enabled MACHINES, (e500 and e500v2) have broken nativesdk compilers in dora and master.

Any suggestions on above statements ?

Quoted 8 lines
Quoted 3 lines

However, even if we fix it this way for powerpc, we will still have this issue with thumb f.ex.

Keep in mind the target sysroot still varies for each different target. The thing we're trying to keep in common is the gcc/bintuils and only have one copy for each target architecture. Is that possible in this case if we somehow enable SPE support in gcc-cross-canadian?

Yes, target sysroot varies. The nativesdk sysroot containing the compiler is the same as long as TUNE_ARCH and SDKMACHINE is the same. Two ARMv8 targets built in sequence on the same host, where one is Thumb2 and the other is EABI ?, they will share nativesdk compiler no ?

The -native compiler runs from the -native sysroot, which has an ABI postfix, so no problem there I assume.

Quoted 5 lines

Cheers,

Richard

#5 lore raw

Hi,

e500v1/v2 uses SPE to handle floating point operations using general purpose regs.
So using the non-SPE compiler with SPE libraries won't work. However the soft-fp libraries are compatible with the e500 ABI (with a considerable performance penalty).

From what I can see, eglibc is built with SPE. So GCC should be built also for SPE (target powerpc-poky-linux-gnuspe).

Kind regards,
Alex

Quoted 81 lines

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of David Nyström
Sent: Tuesday, January 14, 2014 3:24 PM
To: Luo Zhenhua-B19537
Cc: [email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

Quoted 3 lines · Richard Purdie
Quoted 2 lines · David Nyström

Just to clarify bug 5354:
If I understand the bug correctly, this would arise when first

building

Quoted 8 lines
Quoted 6 lines

the nativesdk tarball on a MACHINE with ABI linux,
and then building the nativesdk for another MACHINE(with the same the same TUNE) after altering ABIEXTENSION to linux-gnuspe ?

If I understand bug 5354 correctly, perhaps the tmp/sdk/tarball.here can be ABI specific ?

The idea behind the changes to cross-canadian were to have just a

single

Quoted 18 lines

gcc/binutils which generated all of the appropriate targets for a given architecture.

I understood this to be possible but it looks like we may need to tweak things a bit.

Quoted 11 lines

i.e. a generic rule that all nativesdk builds are invalidated if the ABI changes. I guess that would mean:
cross-canadian.bbclass: TARGET_ARCH[vardeps] += "ABIEXTENSION"
+ Adding ABIEXTENSION to the nativesdk tarball name.

PPC '=mabi=spe' seems to be one-way compatible, I could not get the non-SPE configured compiler
to work with the SPE sysroot.
Another possible solution would be to always configure the compiler to SPE, and use compile time flags in the
environment file to do the selects. + symlinks for the compiler paths.

Quoted 2 lines

Can we configure the compiler to include SPE support without changing the paths/OS string?

Possibly, but I don't know enough about SPE to be sure. Perhaps Zhenhua can add a few cents here.

Short summary of problem:
All SPE enabled MACHINES, (e500 and e500v2) have broken nativesdk compilers in dora and master.

Any suggestions on above statements ?

Quoted 8 lines
Quoted 3 lines

However, even if we fix it this way for powerpc, we will still have this issue with thumb f.ex.

Keep in mind the target sysroot still varies for each different target. The thing we're trying to keep in common is the gcc/bintuils and only have one copy for each target architecture. Is that possible in this case if we somehow enable SPE support in gcc-cross-canadian?

Yes, target sysroot varies. The nativesdk sysroot containing the compiler is the same as long as TUNE_ARCH and SDKMACHINE is the same. Two ARMv8 targets built in sequence on the same host, where one is Thumb2 and the other is EABI ?, they will share nativesdk compiler no ?

The -native compiler runs from the -native sysroot, which has an ABI postfix, so no problem there I assume.

Quoted 5 lines

Cheers,

Richard

_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#6 lore raw
Quoted 8 lines · On Fri, 2014-01-17 at 14:43 +0000, [email protected] wrote:

e500v1/v2 uses SPE to handle floating point operations using general purpose regs.
So using the non-SPE compiler with SPE libraries won't work. However the soft-fp libraries are compatible with the e500 ABI (with a considerable performance penalty).

From what I can see, eglibc is built with SPE. So GCC should be built also for SPE (target powerpc-poky-linux-gnuspe).

The key question is this:

Can one gcc binary generate code for both non-SPE and SPE targets, assuming its pointed at an appropriate sysroot containing appropriate libraries?

If we can have one such binary, how do we configure it? If we can't, we need to redo the way gcc-cross-canadian is working on powerpc.

The change there was to have one gcc for each different target architecture rather than each "tune" since that was horribly inefficient.

Cheers,

Richard

#7 lore raw

Hi,

Yes, the gcc configured for SPE (--target=powerpc-fsl_networking-linux-gnuspe) can generate both SPE and non-SPE code provided that software floating point is used.

There are a couple of parameters (-mabi=no-spe -mno-spe) that will turn off SPE vector instructions generation. If the code contains floating point arithmethic -msoft-float needs to be used as well. This means that the GCC multilib setup has to be configured to include soft float and build coresponding version of libgcc and target fragments. But why would we want to generate code without SPE for e500v1/v2? Soft-float comes with a major performance penalty.

Maybe I didn't understand correctly what kind of toolchain you want to be built in the end. Do you want to have a single GCC that builds all powerpc targets (e500v2, e5500, e6500 etc) and a separate sysroot for each target?
This may be problematic since, for example, the compiler that can generate SPE (for e500v2) can't generate altivec instructions (for e6500).

Kind regards,
Alex

Quoted 39 lines

-----Original Message-----
From: Richard Purdie [mailto:[email protected]]
Sent: Saturday, January 18, 2014 1:20 PM
To: Sardan Alexandru Cezar-B41700
Cc: David Nyström; Luo Zhenhua-B19537; openembedded- [email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

Quoted 8 lines · On Fri, 2014-01-17 at 14:43 +0000, [email protected] wrote:

e500v1/v2 uses SPE to handle floating point operations using general purpose regs.
So using the non-SPE compiler with SPE libraries won't work. However the soft-fp libraries are compatible with the e500 ABI (with a considerable performance penalty).

From what I can see, eglibc is built with SPE. So GCC should be built also for SPE (target powerpc-poky-linux-gnuspe).

The key question is this:

Can one gcc binary generate code for both non-SPE and SPE targets, assuming its pointed at an appropriate sysroot containing appropriate libraries?

If we can have one such binary, how do we configure it? If we can't, we need to redo the way gcc-cross-canadian is working on powerpc.

The change there was to have one gcc for each different target architecture rather than each "tune" since that was horribly inefficient.

Cheers,

Richard

#8 lore raw
Quoted 12 lines · On Tue, 2014-01-21 at 17:39 +0000, [email protected] wrote:

Yes, the gcc configured for SPE (--target=powerpc-fsl_networking-linux-gnuspe) can generate both SPE and non-SPE code provided that software floating point is used.

There are a couple of parameters (-mabi=no-spe -mno-spe) that will turn off SPE vector instructions generation. If the code contains floating point arithmethic -msoft-float needs to be used as well. This means that the GCC multilib setup has to be configured to include soft float and build coresponding version of libgcc and target fragments. But why would we want to generate code without SPE for e500v1/v2? Soft-float comes with a major performance penalty.

Quoted 4 lines

Maybe I didn't understand correctly what kind of toolchain you want to be built in the end. Do you want to have a single GCC that builds all powerpc targets (e500v2, e5500, e6500 etc) and a separate sysroot for each target?

Yes, this is exactly what is wanted. This is how the SDK is intended to operate. The alternative and what we had before was a separate compiler for each target which is rather wasteful.

Quoted 2 lines

This may be problematic since, for example, the compiler that can generate SPE (for e500v2) can't generate altivec instructions (for e6500).

Is there no way to configure gcc so it can generate for the different targets assuming you pass in the right runtime target options?

Cheers,

Richard

#9 lore raw

Hi,

See my comment inline.

Alex

Quoted 35 lines

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Richard Purdie
Sent: Tuesday, January 21, 2014 7:43 PM
To: Sardan Alexandru Cezar-B41700
Cc: Udma Catalin-Dan-B32721; [email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

Quoted 1 line · On Tue, 2014-01-21 at 17:39 +0000, [email protected] wrote:

Yes, the gcc configured for SPE (--target=powerpc-fsl_networking-linux-

gnuspe)

Quoted 6 lines

can generate both SPE and non-SPE code provided that software floating point is used.

There are a couple of parameters (-mabi=no-spe -mno-spe) that will turn off SPE vector instructions generation. If the code contains floating point arithmethic -msoft-float needs to be used as well. This means

that

Quoted 8 lines

the GCC multilib setup has to be configured to include soft float and build coresponding version of libgcc and target fragments. But why would we want to generate code without SPE for e500v1/v2? Soft-float comes with a major performance penalty.

Maybe I didn't understand correctly what kind of toolchain you want to be built in the end. Do you want to have a single GCC that builds all powerpc targets (e500v2, e5500, e6500 etc) and a separate sysroot for

each

Quoted 1 line

target?

Yes, this is exactly what is wanted. This is how the SDK is intended to operate. The alternative and what we had before was a separate compiler for each target which is rather wasteful.

Quoted 6 lines
Quoted 1 line

This may be problematic since, for example, the compiler that can

generate

Quoted 1 line

SPE (for e500v2) can't generate altivec instructions (for e6500).

Is there no way to configure gcc so it can generate for the different targets assuming you pass in the right runtime target options?

[Alex Sardan] No. The more generic target powerpc-none-linux will not generate SPE code and the powerpc-none-linux-gnuspe target that generates SPE will not be able to generate Altivec.
Maybe an exception can be added for e500v1/v2 targets so that a separate compiler can be generated for them? All the other targets will work fine with powerpc-none-linux using different runtime command line options.

Quoted 10 lines

Cheers,

Richard

_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#10 lore raw
Quoted 17 lines · On Thu, 2014-01-23 at 18:22 +0000, [email protected] wrote:
Quoted 10 lines
Quoted 3 lines

Maybe I didn't understand correctly what kind of toolchain you want to be built in the end. Do you want to have a single GCC that builds all powerpc targets (e500v2, e5500, e6500 etc) and a separate sysroot for

each

Quoted 1 line

target?

Yes, this is exactly what is wanted. This is how the SDK is intended to operate. The alternative and what we had before was a separate compiler for each target which is rather wasteful.

Quoted 6 lines
Quoted 1 line

This may be problematic since, for example, the compiler that can

generate

Quoted 1 line

SPE (for e500v2) can't generate altivec instructions (for e6500).

Is there no way to configure gcc so it can generate for the different targets assuming you pass in the right runtime target options?

Quoted 6 lines

[Alex Sardan] No. The more generic target powerpc-none-linux will not generate SPE code and the powerpc-none-linux-gnuspe target that generates SPE will not be able to generate Altivec.
Maybe an exception can be added for e500v1/v2 targets so that a separate compiler can be generated for them? All the other targets will work fine with powerpc-none-linux using different runtime command line options.

An exception can probably be added (its all just software after all) but the setup we have right now just allows for one compiler so some work will be needed to make this work properly.

Cheers,

Richard

#11 lore raw
In reply to [email protected]
Quoted 3 lines · On Thu, 2014-01-23 at 18:22 +0000, [email protected] wrote:

[Alex Sardan] No. The more generic target powerpc-none-linux will not generate SPE code and the powerpc-none-linux-gnuspe target that generates SPE will not be able to generate Altivec.

Why not? As far as I can tell from the gcc configury, the target string only affects the defaults (i.e. powerpc-*-linux gets -mno-spe -mno-altivec, powerpc-*-linuxaltivec gets -maltivec -mno-spec, and powerpc-*-linuxspe gets -mno-altivec -mspe). There doesn't seem to be any real impact beyond this that would make the compiler binary fundamentally incapable of generating either type of instruction if you pass the appropriate options on the command line.

p.

#12 lore raw

Hi,

See my comment inline.

Regards,
Alex

Quoted 24 lines

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Phil Blundell
Sent: Friday, January 24, 2014 10:56 PM
To: Sardan Alexandru Cezar-B41700
Cc: Udma Catalin-Dan-B32721; [email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

Quoted 2 lines · On Thu, 2014-01-23 at 18:22 +0000, [email protected] wrote:

[Alex Sardan] No. The more generic target powerpc-none-linux will not generate SPE code and the powerpc-none-linux-gnuspe target that

generates

Quoted 1 line

SPE will not be able to generate Altivec.

Why not? As far as I can tell from the gcc configury, the target string only affects the defaults (i.e. powerpc-*-linux gets -mno-spe -mno-altivec, powerpc-*-linuxaltivec gets -maltivec -mno-spec, and powerpc-*-linuxspe gets -mno-altivec -mspe). There doesn't seem to be any real impact beyond this that would make the compiler binary fundamentally incapable of generating either type of instruction if you pass the appropriate options on the command line.

Quoted 1 line

p.

[Alex Sardan] Trying to generate altivec instructions with the spe compiler will yield the following error:

b41700@fsr-ub1264-102: [sandbox]$ powerpc-fsl_networking-linux-gnuspe-gcc -mcpu=e6500 -mabi=no-spe -mno-spe -mabi=altivec -maltivec -S -c double.c double.c:1:0: error: AltiVec and E500 instructions cannot coexist

Also trying to generate e500v2 code with powerpc-linux target:

b41700@fsr-ub1264-102: [sandbox]$ powerpc-poky-linux-gcc -mcpu=8548 -mabi=spe -mspe -mfloat-gprs=double -S -c double.c double.c:1:0: error: not configured for SPE ABI
double foo()
^
double.c:1:0: error: not configured for SPE instruction set

Quoted 7 lines

_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#13 lore raw
In reply to Phil Blundell
Quoted 5 lines · Phil Blundell
Quoted 3 lines · On Thu, 2014-01-23 at 18:22 +0000, [email protected] wrote:

[Alex Sardan] No. The more generic target powerpc-none-linux will not generate SPE code and the powerpc-none-linux-gnuspe target that generates SPE will not be able to generate Altivec.

Quoted 7 lines

Why not? As far as I can tell from the gcc configury, the target string only affects the defaults (i.e. powerpc-*-linux gets -mno-spe -mno-altivec, powerpc-*-linuxaltivec gets -maltivec -mno-spec, and powerpc-*-linuxspe gets -mno-altivec -mspe). There doesn't seem to be any real impact beyond this that would make the compiler binary fundamentally incapable of generating either type of instruction if you pass the appropriate options on the command line.

I had a closer look at this. The config.gcc case statements for powerpc only appear to let you include rs6000/linuxaltivec.h or rs6000/linuxspe.h, there doesn't appear to be a target you can pass in to get both.

Looking at the code in those files, I don't see any reason why you can't actually include support for both however. As such, I just hacked a build with:

tm_file="${tm_file} rs6000/linuxaltivec.h" tm_file="${tm_file} rs6000/linuxspe.h rs6000/e500.h"

and it certainly seems to build ok and compile things (this was just for qemuppc). I didn't try building altivec or spe specific things but looking at the code, I can't see any reason it wouldn't work at least in theory.

I'd suggest the easiest way to resolve this may be to patch gcc to include support for all the modes.

Cheers,

Richard

#14 lore raw

Hi Richard,

I've tested your patch for both altivec and spe and it works fine.

Regards,
Alex

Quoted 51 lines

-----Original Message-----
From: Richard Purdie [mailto:[email protected]]
Sent: Wednesday, January 29, 2014 1:39 PM
To: Phil Blundell
Cc: Sardan Alexandru Cezar-B41700; Udma Catalin-Dan-B32721; openembedded- [email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

Quoted 1 line · Phil Blundell

On Thu, 2014-01-23 at 18:22 +0000, [email protected]

Quoted 2 lines · wrote:
Quoted 2 lines

[Alex Sardan] No. The more generic target powerpc-none-linux will not generate SPE code and the powerpc-none-linux-gnuspe target that

generates

Quoted 3 lines
Quoted 1 line

SPE will not be able to generate Altivec.

Why not? As far as I can tell from the gcc configury, the target

string

Quoted 6 lines

only affects the defaults (i.e. powerpc-*-linux gets -mno-spe -mno-altivec, powerpc-*-linuxaltivec gets -maltivec -mno-spec, and powerpc-*-linuxspe gets -mno-altivec -mspe). There doesn't seem to be any real impact beyond this that would make the compiler binary fundamentally incapable of generating either type of instruction if you pass the appropriate options on the command line.

I had a closer look at this. The config.gcc case statements for powerpc only appear to let you include rs6000/linuxaltivec.h or rs6000/linuxspe.h, there doesn't appear to be a target you can pass in to get both.

Looking at the code in those files, I don't see any reason why you can't actually include support for both however. As such, I just hacked a build with:

tm_file="${tm_file} rs6000/linuxaltivec.h" tm_file="${tm_file} rs6000/linuxspe.h rs6000/e500.h"

and it certainly seems to build ok and compile things (this was just for qemuppc). I didn't try building altivec or spe specific things but looking at the code, I can't see any reason it wouldn't work at least in theory.

I'd suggest the easiest way to resolve this may be to patch gcc to include support for all the modes.

Cheers,

Richard

#15 lore raw
Quoted 3 lines · On Fri, 2014-01-31 at 17:53 +0000, [email protected] wrote:

Hi Richard,

I've tested your patch for both altivec and spe and it works fine.

Would you be able to put together a proper patch with the explanation and so on so we can get it merged and resolve this issue?

Cheers,

Richard

Quoted 56 lines

Regards,
Alex

Quoted 51 lines

-----Original Message-----
From: Richard Purdie [mailto:[email protected]]
Sent: Wednesday, January 29, 2014 1:39 PM
To: Phil Blundell
Cc: Sardan Alexandru Cezar-B41700; Udma Catalin-Dan-B32721; openembedded- [email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

Quoted 1 line · Phil Blundell

On Thu, 2014-01-23 at 18:22 +0000, [email protected]

Quoted 2 lines · wrote:
Quoted 2 lines

[Alex Sardan] No. The more generic target powerpc-none-linux will not generate SPE code and the powerpc-none-linux-gnuspe target that

generates

Quoted 3 lines
Quoted 1 line

SPE will not be able to generate Altivec.

Why not? As far as I can tell from the gcc configury, the target

string

Quoted 6 lines

only affects the defaults (i.e. powerpc-*-linux gets -mno-spe -mno-altivec, powerpc-*-linuxaltivec gets -maltivec -mno-spec, and powerpc-*-linuxspe gets -mno-altivec -mspe). There doesn't seem to be any real impact beyond this that would make the compiler binary fundamentally incapable of generating either type of instruction if you pass the appropriate options on the command line.

I had a closer look at this. The config.gcc case statements for powerpc only appear to let you include rs6000/linuxaltivec.h or rs6000/linuxspe.h, there doesn't appear to be a target you can pass in to get both.

Looking at the code in those files, I don't see any reason why you can't actually include support for both however. As such, I just hacked a build with:

tm_file="${tm_file} rs6000/linuxaltivec.h" tm_file="${tm_file} rs6000/linuxspe.h rs6000/e500.h"

and it certainly seems to build ok and compile things (this was just for qemuppc). I didn't try building altivec or spe specific things but looking at the code, I can't see any reason it wouldn't work at least in theory.

I'd suggest the easiest way to resolve this may be to patch gcc to include support for all the modes.

Cheers,

Richard

#16 lore raw

Hi,

Sure, I'll do this and also some more extensive testing on the boards.

Thanks,
Alex

Quoted 89 lines

-----Original Message-----
From: Richard Purdie [mailto:[email protected]]
Sent: Friday, January 31, 2014 8:07 PM
To: Sardan Alexandru Cezar-B41700
Cc: Phil Blundell; Udma Catalin-Dan-B32721; openembedded- [email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

Quoted 3 lines · On Fri, 2014-01-31 at 17:53 +0000, [email protected] wrote:

Hi Richard,

I've tested your patch for both altivec and spe and it works fine.

Would you be able to put together a proper patch with the explanation and so on so we can get it merged and resolve this issue?

Cheers,

Richard

Quoted 8 lines

Regards,
Alex

Quoted 5 lines

-----Original Message-----
From: Richard Purdie [mailto:[email protected]]
Sent: Wednesday, January 29, 2014 1:39 PM
To: Phil Blundell
Cc: Sardan Alexandru Cezar-B41700; Udma Catalin-Dan-B32721;

openembedded-

Quoted 8 lines
Quoted 8 lines

[email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

Quoted 1 line · Phil Blundell

On Thu, 2014-01-23 at 18:22 +0000, [email protected]

Quoted 1 line · wrote:
Quoted 1 line

[Alex Sardan] No. The more generic target powerpc-none-linux will

not

Quoted 9 lines
Quoted 9 lines
Quoted 1 line
Quoted 1 line

generate SPE code and the powerpc-none-linux-gnuspe target that

generates

Quoted 3 lines
Quoted 1 line

SPE will not be able to generate Altivec.

Why not? As far as I can tell from the gcc configury, the target

string

Quoted 3 lines

only affects the defaults (i.e. powerpc-*-linux gets -mno-spe -mno-altivec, powerpc-*-linuxaltivec gets -maltivec -mno-spec, and powerpc-*-linuxspe gets -mno-altivec -mspe). There doesn't seem to

be

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

any real impact beyond this that would make the compiler binary fundamentally incapable of generating either type of instruction if

you

Quoted 3 lines
Quoted 3 lines
Quoted 1 line

pass the appropriate options on the command line.

I had a closer look at this. The config.gcc case statements for

powerpc

Quoted 2 lines
Quoted 2 lines

only appear to let you include rs6000/linuxaltivec.h or rs6000/linuxspe.h, there doesn't appear to be a target you can pass

in

Quoted 3 lines
Quoted 3 lines

to get both.

Looking at the code in those files, I don't see any reason why you

can't

Quoted 7 lines
Quoted 7 lines

actually include support for both however. As such, I just hacked a build with:

tm_file="${tm_file} rs6000/linuxaltivec.h" tm_file="${tm_file} rs6000/linuxspe.h rs6000/e500.h"

and it certainly seems to build ok and compile things (this was just

for

Quoted 2 lines
Quoted 2 lines

qemuppc). I didn't try building altivec or spe specific things but looking at the code, I can't see any reason it wouldn't work at least

in

Quoted 12 lines
Quoted 10 lines

theory.

I'd suggest the easiest way to resolve this may be to patch gcc to include support for all the modes.

Cheers,

Richard

#17 lore raw
Quoted 8 lines · On 2014-01-31 19:17, [email protected] wrote:

Hi,

Sure, I'll do this and also some more extensive testing on the boards.

Thanks,
Alex

Hi Alex,

Whats the status on this ?

Br,
David

#18 lore raw

Hi David,

Sorry for the late reply.
I'm not familiar with the procedure for submitting a patch to Poky. Could you walk me through the process?

Meanwhile I've attached the patch to this e-mail. It's been tested on e500v2, e5500 and e6500.

Kind regards,
Alex

Quoted 22 lines

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of David Nyström
Sent: Tuesday, February 11, 2014 12:08 PM
To: Sardan Alexandru Cezar-B41700; Richard Purdie
Cc: Udma Catalin-Dan-B32721; [email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

Quoted 8 lines · On 2014-01-31 19:17, [email protected] wrote:

Hi,

Sure, I'll do this and also some more extensive testing on the boards.

Thanks,
Alex

Hi Alex,

Quoted 9 lines

Whats the status on this ?

Br,
David
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

From 7c7eee56ae69dc28c9c4897ee13c3ee9d7a7f4e1 Mon Sep 17 00:00:00 2001
From: Alexandru-Cezar Sardan <[email protected]>
Date: Thu, 20 Feb 2014 15:59:03 +0200
Subject: [PATCH] Enable SPE & AltiVec generation on powepc*linux target.

Also this patch adds symlinks to libgcc such that a GCC configured by passing the target parameter without LIBCEXTENSION and ABIEXTENSION specifiers to find the correct startup files from a libgcc configured with these variables.

---
 meta/recipes-devtools/gcc/gcc-4.8.inc              |    1 +
 ...AltiVec-generation-on-powepc-linux-target.patch |   40 ++++++++++++++++++++
 meta/recipes-devtools/gcc/libgcc.inc               |   25 +++++++++++-
 3 files changed, 65 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-devtools/gcc/gcc-4.8/0049-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch
meta/recipes-devtools/gcc/gcc-4.8.inc +1 -0
index fdd0c12..f5e583d 100644
@@ -69,6 +69,7 @@ SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	   file://0046-libatomic-deptracking.patch \
 	   file://0047-repomembug.patch \
 	   file://0048-PR58854_fix_arm_apcs_epilogue.patch \
+	   file://0049-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch \ 
 	  "
 SRC_URI[md5sum] = "a3d7d63b9cb6b6ea049469a0c4a43c9d"
 SRC_URI[sha256sum] = "09dc2276c73424bbbfda1dbddc62bbbf900c9f185acf7f3e1d773ce2d7e3cdc8"
meta/recipes-devtools/gcc/gcc-4.8/0049-Enable-SPE-AltiVec-generation-on-powepc-linux-target.patch new file +40 -0
new file mode 100644
index 0000000..76fbb7a
@@ -0,0 +1,40 @@
+From 9e0e19eac2562f73858602fe26e2044eb8b20c47 Mon Sep 17 00:00:00 2001
+From: Alexandru-Cezar Sardan <[email protected]>
+Date: Wed, 5 Feb 2014 16:52:31 +0200
+Subject: [PATCH] Enable SPE & AltiVec generation on powepc*linux target
+
+When is configured with --target=powerpc-linux, the resulting GCC will 
+not be able to generate code for SPE targets (e500v1/v2).
+GCC configured with --target=powerpc-linuxspe will not be able to
+generate AltiVec instructions (for e6500).
+This patch modifies the configured file such that SPE or AltiVec code
+can be generated when gcc is configured with --target=powerpc-linux.
+The ABI and speciffic instructions can be selected through the
+"-mabi=spe or -mabi=altivec" and the "-mspe or -maltivec" parameters.
+
+Signed-off-by: Alexandru-Cezar Sardan <[email protected]>
+---
+ gcc/config.gcc |    7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/gcc/config.gcc b/gcc/config.gcc
+index cb7a94e..d392c2b 100644
+--- a/gcc/config.gcc
++++ b/gcc/config.gcc
+@@ -2068,7 +2068,12 @@ powerpc-*-rtems*)
+ 	tmake_file="rs6000/t-fprules rs6000/t-rtems t-rtems rs6000/t-ppccomm"
+ 	;;
+ powerpc*-*-linux*)
+-	tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h rs6000/sysv4.h"
++	case ${target} in
++	    powerpc*-*-linux*spe* | powerpc*-*-linux*altivec*)
++		tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h rs6000/sysv4.h" ;;
++	    *)
++		tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h rs6000/sysv4.h rs6000/linuxaltivec.h rs6000/linuxspe.h rs6000/e500.h" ;;
++	esac
+ 	extra_options="${extra_options} rs6000/sysv4.opt"
+ 	tmake_file="rs6000/t-fprules rs6000/t-ppcos ${tmake_file} rs6000/t-ppccomm"
+ 	case ${target} in
+-- 
+1.7.9.5
+
meta/recipes-devtools/gcc/libgcc.inc +23 -1
index fe98238..8f400b1 100644
@@ -17,7 +17,8 @@ FILES_${PN}-dev = " \
   ${libdir}/${TARGET_SYS}/${BINV}/32 \
   ${libdir}/${TARGET_SYS}/${BINV}/x32 \
   ${libdir}/${TARGET_SYS}/${BINV}/n32 \
-  ${libdir}/${TARGET_SYS}/${BINV}/libgcc*"
+  ${libdir}/${TARGET_SYS}/${BINV}/libgcc* \
+  ${@base_conditional('TARGET_SYS_NO_EXTENSION', '${TARGET_SYS}', '', '${libdir}/${TARGET_SYS_NO_EXTENSION}', d)}"
 FILES_libgcov-dev = " \
   ${libdir}/${TARGET_SYS}/${BINV}/libgcov.a \
   "
@@ -141,3 +142,24 @@ python do_multilib_install() {
             os.unlink(dest)
         os.symlink(src, dest)
 }
+
+addtask extra_symlinks after do_multilib_install before do_package do_populate_sysroot
+python do_extra_symlinks() {
+    targetsysnoext = d.getVar('TARGET_SYS_NO_EXTENSION', True)
+
+    if targetsysnoext != d.getVar('TARGET_SYS', True):
+        dest = d.getVar('D', True) + d.getVar('libdir', True) + '/' + targetsysnoext
+        src = d.getVar('TARGET_SYS', True)
+        if not os.path.lexists(dest):
+            os.symlink(src, dest)
+}
+
+python () {
+    targetsysnoext = d.getVar('TARGET_SYS', True)
+
+    for suffix in [d.getVar('ABIEXTENSION', True), d.getVar('LIBCEXTENSION', True)]:
+        if suffix and targetsysnoext.endswith(suffix):
+            targetsysnoext = targetsysnoext[:-len(suffix)]
+
+    d.setVar('TARGET_SYS_NO_EXTENSION', targetsysnoext)
+}
Signature · 1 line
1.7.9.5
#19 lore raw
Quoted 11 lines · On 2014-02-26 19:29, [email protected] wrote:

Hi David,

Sorry for the late reply.
I'm not familiar with the procedure for submitting a patch to Poky. Could you walk me through the process?

Meanwhile I've attached the patch to this e-mail. It's been tested on e500v2, e5500 and e6500.

Kind regards,
Alex

Hi,

You patch looks fine to me. A couple of comments though:

You should use git send-mail to send it to oe-core, and your patch on GCC needs an upstream status. i.e. Plans of how and if this will be upstreamed to GCC.

Details:
https://wiki.yoctoproject.org/wiki/Contribution_Guidelines

Was able to build a working SDK compiler for p1025twr.

When this has brewed in the Autobuilder for a while, it should be backported to dora as well.

Br,
David

Quoted 38 lines
Quoted 23 lines

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of David Nyström
Sent: Tuesday, February 11, 2014 12:08 PM
To: Sardan Alexandru Cezar-B41700; Richard Purdie
Cc: Udma Catalin-Dan-B32721; [email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

Quoted 8 lines · On 2014-01-31 19:17, [email protected] wrote:

Hi,

Sure, I'll do this and also some more extensive testing on the boards.

Thanks,
Alex

Hi Alex,

Quoted 9 lines

Whats the status on this ?

Br,
David
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#20 lore raw

Hi,

I've made the modifications and sent the patch with git send-mail to the oe-core list.

Regards,
Alex

From: David Nyström [mailto:[email protected]]
Sent: Thursday, February 27, 2014 12:37 AM
To: Sardan Alexandru Cezar-B41700; David Nyström; Richard Purdie
Cc: Udma Catalin-Dan-B32721; [email protected]
Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc linux verses linux-gnuspe"

On 2014-02-26 19:29, [email protected]<mailto:[email protected]> wrote:

Hi David,

Sorry for the late reply.

I'm not familiar with the procedure for submitting a patch to Poky.

Could you walk me through the process?

Meanwhile I've attached the patch to this e-mail. It's been tested

on e500v2, e5500 and e6500.

Kind regards,

Alex

Hi,

You patch looks fine to me. A couple of comments though:

You should use git send-mail to send it to oe-core, and your patch on GCC needs an upstream status. i.e. Plans of how and if this will be upstreamed to GCC.

Details:
https://wiki.yoctoproject.org/wiki/Contribution_Guidelines

Was able to build a working SDK compiler for p1025twr.

When this has brewed in the Autobuilder for a while, it should be backported to dora as well.

Br,
David

-----Original Message-----

From: [email protected]<mailto:[email protected]>

[mailto:[email protected]] On Behalf Of

David Nyström

Sent: Tuesday, February 11, 2014 12:08 PM

To: Sardan Alexandru Cezar-B41700; Richard Purdie

Cc Udma Catalin-Dan-B32721; [email protected]<mailto:[email protected]>

Subject: Re: [OE-core] [PATCH] Revert "cross-canadian: Handle powerpc

linux verses linux-gnuspe"

On 2014-01-31 19:17, [email protected]<mailto:[email protected]> wrote:

Hi,

Sure, I'll do this and also some more extensive testing

on the boards.

Thanks,

Alex

Hi Alex,

Whats the status on this ?

Br,

David

_______________________________________________

Openembedded-core mailing list

[email protected]<mailto:[email protected]>

http://lists.openembedded.org/mailman/listinfo/openembedded-core

_______________________________________________

Openembedded-core mailing list

[email protected]<mailto:[email protected]>

http://lists.openembedded.org/mailman/listinfo/openembedded-core

#21 lore raw
In reply to Richard Purdie
Quoted 10 lines · Richard Purdie
Quoted 8 lines · On Fri, 2014-01-17 at 14:43 +0000, [email protected] wrote:

e500v1/v2 uses SPE to handle floating point operations using general purpose regs.
So using the non-SPE compiler with SPE libraries won't work. However the soft-fp libraries are compatible with the e500 ABI (with a considerable performance penalty).

From what I can see, eglibc is built with SPE. So GCC should be built also for SPE (target powerpc-poky-linux-gnuspe).

Quoted 9 lines

The key question is this:

Can one gcc binary generate code for both non-SPE and SPE targets, assuming its pointed at an appropriate sysroot containing appropriate libraries?

If we can have one such binary, how do we configure it? If we can't, we need to redo the way gcc-cross-canadian is working on powerpc.

I think gcc can generate the code all you would need is option, real problem is gcc runtime which will need different set of libraries and init files.

Quoted 4 lines

The change there was to have one gcc for each different target architecture rather than each "tune" since that was horribly inefficient.

We dont need specific to tune but spe is ABI identifier that should be treated differently then defaul tunes IMO

Quoted 10 lines

Cheers,

Richard

_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

Signature · 1 line
-Khem