Skip to contentSkip to conversation

openpgm: Blacklist Blackfin ADI 2014R1 toolchain

PATCH New Romain Naour 2 participants 6 messages Mar 7, 2015 – Mar 13, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 openpgm: Blacklist Blackfin ADI 2014R1 toolchain

Openpgm requires compiler intrinsics not available with Blackfin ADI toolchains.

Fixes:
http://autobuild.buildroot.net/results/394/394cf96cc0ab9029e5baa84b19e2b4d7a553f077/

---
 package/openpgm/Config.in | 1 +
 1 file changed, 1 insertion(+)
package/openpgm/Config.in +1 -0
index 3a26212..8d03c84 100644
@@ -1,6 +1,7 @@
 config BR2_PACKAGE_OPENPGM
 	bool "openpgm"
 	# The following toolchains lack required compiler intrinsics
+	depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2014R1
 	depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2013R1
 	depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2012R2
 	depends on BR2_TOOLCHAIN_HAS_THREADS
Signature · 1 line
1.9.3
#1 lore raw

PATCH 1/1 openpgm: Blacklist Blackfin ADI 2014R1 toolchain

Dear Romain Naour,

Quoted 15 lines · Romain Naour

Openpgm requires compiler intrinsics not available with Blackfin ADI toolchains.

Fixes:
http://autobuild.buildroot.net/results/394/394cf96cc0ab9029e5baa84b19e2b4d7a553f077/

---
 package/openpgm/Config.in | 1 +
 1 file changed, 1 insertion(+)
package/openpgm/Config.in +0 -0
index 3a26212..8d03c84 100644

package/openpgm/Config.in line 7

Quoted 7 lines
package/openpgm/Config.in +1 -0
@@ -1,6 +1,7 @@
 config BR2_PACKAGE_OPENPGM
 	bool "openpgm"
 	# The following toolchains lack required compiler intrinsics
+	depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2014R1
 	depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2013R1
 	depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2012R2
 	depends on BR2_TOOLCHAIN_HAS_THREADS

When you add a new dependency to a symbol, you need to propagate this dependency to the other symbols select that one. In this specific case, zeromq PGM support was selecting openpgm, so you need to replicate this dependency. I've applied after fixing that.

Also, at some point, we will need to really on the ARCH_HAS_ATOMICS stuff for this.

Best regards,

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#2 lore raw

PATCH 1/1 openpgm: Blacklist Blackfin ADI 2014R1 toolchain

Hi Thomas,

Le 08/03/2015 08:53, Thomas Petazzoni a ?crit :

Quoted 22 lines

Dear Romain Naour,

Quoted 19 lines · Romain Naour

Openpgm requires compiler intrinsics not available with Blackfin ADI toolchains.

Fixes:
http://autobuild.buildroot.net/results/394/394cf96cc0ab9029e5baa84b19e2b4d7a553f077/

---
 package/openpgm/Config.in | 1 +
 1 file changed, 1 insertion(+)
package/openpgm/Config.in +1 -0
index 3a26212..8d03c84 100644
@@ -1,6 +1,7 @@
 config BR2_PACKAGE_OPENPGM
 	bool "openpgm"
 	# The following toolchains lack required compiler intrinsics
+	depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2014R1
Quoted 8 lines

package/openpgm/Config.in line 7

Quoted 3 lines
package/openpgm/Config.in +0 -0
 	depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2013R1
 	depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2012R2
 	depends on BR2_TOOLCHAIN_HAS_THREADS

When you add a new dependency to a symbol, you need to propagate this dependency to the other symbols select that one. In this specific case, zeromq PGM support was selecting openpgm, so you need to replicate this dependency. I've applied after fixing that.

Ah yes, thanks.
I completely forgot to check that :/

Quoted 3 lines

Also, at some point, we will need to really on the ARCH_HAS_ATOMICS stuff for this.

really -> rely

You mean BR2_ARCH_HAS_ATOMICS ?
But it's set by default for bfin configs.

If I understand correctly, you want to move those "denpends on" to Config.in.bfin:

config BR2_ARCH_HAS_ATOMICS
# The following toolchains lack required compiler intrinsics depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2014R1 depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2013R1 depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2012R2 default y

I can cook a patch to do that.

Best regards,
Romain

Quoted 5 lines

Best regards,

Thomas

#3 lore raw

PATCH 1/1 openpgm: Blacklist Blackfin ADI 2014R1 toolchain

Dear Romain Naour,

Quoted 3 lines · Romain Naour
Quoted 2 lines

Also, at some point, we will need to really on the ARCH_HAS_ATOMICS stuff for this.

really -> rely

Right. But it's not a commit log, so do we care about typos ? :-)

Quoted 2 lines

You mean BR2_ARCH_HAS_ATOMICS ?
But it's set by default for bfin configs.

Yes. Back when we introduced BR2_ARCH_HAS_ATOMICS, but wondered whether it should be BR2_ARCH_HAS_ATOMICS or BR2_TOOLCHAIN_HAS_ATOMICS, i.e whether we would have the case of an architecture that does support atomic intrinsics, but has certain toolchain versions for this architecture that do not.

I don't remember if we carefully check whether Blackfin has atomic intrinsics or not.

Quoted 6 lines

config BR2_ARCH_HAS_ATOMICS
# The following toolchains lack required compiler intrinsics depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2014R1 depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2013R1 depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2012R2 default y

Nope. We first need to find out whether the Blackfin architecture has what's needed to provide atomic intrinsics. Depending on that, we'll now if it's a toolchain limitation or not.

Best regards,

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#4 lore raw

PATCH 1/1 openpgm: Blacklist Blackfin ADI 2014R1 toolchain

Hello Thomas,

Le 08/03/2015 18:30, Thomas Petazzoni a ?crit :

Quoted 9 lines

Dear Romain Naour,

Quoted 3 lines · Romain Naour
Quoted 2 lines

Also, at some point, we will need to really on the ARCH_HAS_ATOMICS stuff for this.

really -> rely

Right. But it's not a commit log, so do we care about typos ? :-)

:)

Quoted 9 lines
Quoted 3 lines

You mean BR2_ARCH_HAS_ATOMICS ?
But it's set by default for bfin configs.

Yes. Back when we introduced BR2_ARCH_HAS_ATOMICS, but wondered whether it should be BR2_ARCH_HAS_ATOMICS or BR2_TOOLCHAIN_HAS_ATOMICS, i.e whether we would have the case of an architecture that does support atomic intrinsics, but has certain toolchain versions for this architecture that do not.

I remember to have read something about that on the ml.

Yann said in the commit log:
"The fact that atomic operations are available is not really a specificity of the toolchain, but rather of the architecture."

Quoted 3 lines

I don't remember if we carefully check whether Blackfin has atomic intrinsics or not.

I don't know, the commit enabling BR2_ARCH_HAS_ATOMICS on bfin said nothing about that. Yann do you remember ?

Quoted 11 lines
Quoted 7 lines

config BR2_ARCH_HAS_ATOMICS
# The following toolchains lack required compiler intrinsics depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2014R1 depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2013R1 depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2012R2 default y

Nope. We first need to find out whether the Blackfin architecture has what's needed to provide atomic intrinsics. Depending on that, we'll now if it's a toolchain limitation or not.

I'm not sure but blackfin seems to have some (one?) atomic instruction(s):

http://www.analog.com/media/en/dsp-documentation/processor-manuals/ADSP-BF539_HRM_rev03.pdf
"The processor provides a single atomic operation: TESTSET"

http://blackfin.uclinux.org/doku.php?id=toolchain:application_binary_interface
"The Blackfin does not have an atomic 64 bit load/store instruction"

Best regards,
Romain

Quoted 5 lines

Best regards,

Thomas

#5 lore raw

PATCH 1/1 openpgm: Blacklist Blackfin ADI 2014R1 toolchain

Dear Romain Naour,

Quoted 3 lines · Romain Naour

Yann said in the commit log:
"The fact that atomic operations are available is not really a specificity of the toolchain, but rather of the architecture."

That is correct, but you could imagine, on an architecture that does have atomic operations, a compiler version that does not implement the corresponding compiler intrinsics.

Back then, we decided to not support such situations, because it was making the handling of this atomic operation support too complicated.

Quoted 11 lines
Quoted 10 lines
Quoted 6 lines

config BR2_ARCH_HAS_ATOMICS
# The following toolchains lack required compiler intrinsics depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2014R1 depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2013R1 depends on !BR2_TOOLCHAIN_EXTERNAL_BLACKFIN_UCLINUX_2012R2 default y

Nope. We first need to find out whether the Blackfin architecture has what's needed to provide atomic intrinsics. Depending on that, we'll now if it's a toolchain limitation or not.

Quoted 7 lines

I'm not sure but blackfin seems to have some (one?) atomic instruction(s):

http://www.analog.com/media/en/dsp-documentation/processor-manuals/ADSP-BF539_HRM_rev03.pdf
"The processor provides a single atomic operation: TESTSET"

http://blackfin.uclinux.org/doku.php?id=toolchain:application_binary_interface
"The Blackfin does not have an atomic 64 bit load/store instruction"

What we need to check is if more recent versions of gcc on Blackfin do have the atomic intrinsics available. If not, when we can simply decide to set BR2_ARCH_HAS_ATOMICS to false on Blackfin. If however some more recent gcc versions for Blackfin do have those instructions, then we will have to handle a toolchain-level criteria to decide whether atomic operations are available or not.

Best regards,

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com