package/iozone: Build non-threads version if !BR2_PTHREADS_NATIVE
PATCH 1/1 package/iozone: Build non-threads version if !BR2_PTHREADS_NATIVE
iozone uses pthread_setaffinity_np, which is not supported in Linuxthreads.
--- package/iozone/iozone.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
package/iozone/iozone.mk +1 -1
@@ -12,7 +12,7 @@ IOZONE_LICENSE = IOzone license (NO DERIVED WORKS ALLOWED) # http://www.iozone.org/docs/Iozone_License.txt # No threading target is non-AIO as well -ifeq ($(BR2_TOOLCHAIN_HAS_THREADS),) +ifeq ($(BR2_PTHREADS_NATIVE),) IOZONE_TARGET = linux-noth # AIO support not available on uClibc, use the linux (non-aio) target. else ifeq ($(BR2_TOOLCHAIN_USES_UCLIBC),y)
Signature · 1 line
1.7.9.5
PATCH 1/1 package/iozone: Build non-threads version if !BR2_PTHREADS_NATIVE
Dear Mischa Jonker,
package/iozone/iozone.mk IOZONE_LICENSE = IOzone license (NO DERIVED WORKS ALLOWED) · line 18
Quoted 6 lines · Mischa Jonker
# No threading target is non-AIO as well
package/iozone/iozone.mk +1
-1-ifeq ($(BR2_TOOLCHAIN_HAS_THREADS),) +ifeq ($(BR2_PTHREADS_NATIVE),) IOZONE_TARGET = linux-noth # AIO support not available on uClibc, use the linux (non-aio) target. else ifeq ($(BR2_TOOLCHAIN_USES_UCLIBC),y)
BR2_PTHREADS_NATIVE is a Config.in option that only makes sense in the context of the internal toolchain backend. So any usage of it in package/ is going to not be suitable for external toolchain usage. So your change, as is, would disable thread support in IOZone for any external toolchain.
Best regards,
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com
PATCH 1/1 package/iozone: Build non-threads version if !BR2_PTHREADS_NATIVE
Hi Thomas,
Quoted 4 lines
BR2_PTHREADS_NATIVEis a Config.in option that only makes sense in the context of the internal toolchain backend. So any usage of it in package/ is going to not be suitable for external toolchain usage. So your change, as is, would disable thread support in IOZone for any external toolchain.
Should we add a BR2_TOOLCHAIN_HAS_THREADS_NATIVE to toolchain/toolchain-common.in? Or do you have another suggestion?
Mischa
PATCH 1/1 package/iozone: Build non-threads version if !BR2_PTHREADS_NATIVE
Dear Mischa Jonker,
Quoted 6 lines · Mischa Jonker
Quoted 4 lines
BR2_PTHREADS_NATIVEis a Config.in option that only makes sense in the context of the internal toolchain backend. So any usage of it in package/ is going to not be suitable for external toolchain usage. So your change, as is, would disable thread support in IOZone for any external toolchain.Should we add a
BR2_TOOLCHAIN_HAS_THREADS_NATIVEto toolchain/toolchain-common.in? Or do you have another suggestion?
Yes, I believe that's the only solution. In fact, it could also be used instead of the BR2_TOOLCHAIN_LIBC_NEEDS_THREE_STAGE_BUILD that's being added by my proposed patch "[PATCH] toolchain-internal: skip gcc-intermediate when possible".
Best regards,
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com
PATCH 1/1 package/iozone: Build non-threads version if !BR2_PTHREADS_NATIVE
Quoted 8 lines · Thomas
Quoted 2 lines
Should we add a
BR2_TOOLCHAIN_HAS_THREADS_NATIVEto toolchain/toolchain-common.in? Or do you have another suggestion?
Yes, I believe that's the only solution. In fact, it could also be used instead of the
BR2_TOOLCHAIN_LIBC_NEEDS_THREE_STAGE_BUILDthat's being added by my proposed patch "[PATCH] toolchain-internal: skip gcc-intermediate when possible".
Do you think that it's a safe assumption that GLIBC toolchains have NPTL? (just like BR2_TOOLCHAIN_HAS_THREADS is selected already if BR2_TOOLCHAIN_USES_GLIBC).
Mischa