populate_sdk_base: use xz -T instead of pixz
PATCH 1/1 populate_sdk_base: use xz -T instead of pixz
xz has native support for threaded compression now and SDK creation was the only part of oe-core which is using pixz instead of xz.
Not only does this remove pixz-native from the SDK dependencies, but in my limited testing xz -T0 is slightly faster and produces smaller archives than pixz for the same input.
--- meta/classes/populate_sdk_base.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
meta/classes/populate_sdk_base.bbclass +2 -2
@@ -46,7 +46,7 @@ TOOLCHAIN_TARGET_TASK_ATTEMPTONLY ?= "" TOOLCHAIN_OUTPUTNAME ?= "${SDK_NAME}-toolchain-${SDK_VERSION}" SDK_RDEPENDS = "${TOOLCHAIN_TARGET_TASK} ${TOOLCHAIN_HOST_TASK}" -SDK_DEPENDS = "virtual/fakeroot-native pixz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross" +SDK_DEPENDS = "virtual/fakeroot-native xz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross" SDK_DEPENDS_append_libc-glibc = " nativesdk-glibc-locale" # We want the MULTIARCH_TARGET_SYS to point to the TUNE_PKGARCH, not PACKAGE_ARCH as it
@@ -225,7 +225,7 @@ fakeroot tar_sdk() { # Package it up mkdir -p ${SDKDEPLOYDIR} cd ${SDK_OUTPUT}/${SDKPATH} - tar ${SDKTAROPTS} -cf - . | pixz > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz + tar ${SDKTAROPTS} -cf - . | xz -T 0 > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz } fakeroot create_shar() {
Signature · 1 line
2.11.0
Quoted 7 lines · Ross Burton
xz has native support for threaded compression now and SDK creation was the only part of oe-core which is using pixz instead of xz.
Not only does this remove pixz-native from the SDK dependencies, but in my limited testing xz -T0 is slightly faster and produces smaller archives than pixz for the same input.
this is using nativesdk-xz ?
Quoted 35 lines
Signed-off-by Ross Burton <[email protected]>--- meta/classes/populate_sdk_base.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)meta/classes/populate_sdk_base.bbclass +2
-3@@ -46,7 +46,7 @@ TOOLCHAIN_TARGET_TASK_ATTEMPTONLY ?= "" TOOLCHAIN_OUTPUTNAME ?= "${SDK_NAME}-toolchain-${SDK_VERSION}" SDK_RDEPENDS = "${TOOLCHAIN_TARGET_TASK} ${TOOLCHAIN_HOST_TASK}" -SDK_DEPENDS = "virtual/fakeroot-native pixz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross" +SDK_DEPENDS = "virtual/fakeroot-native xz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross" SDK_DEPENDS_append_libc-glibc = " nativesdk-glibc-locale" # We want the MULTIARCH_TARGET_SYS to point to the TUNE_PKGARCH, not PACKAGE_ARCH as it@@ -225,7 +225,7 @@ fakeroot tar_sdk() { # Package it up mkdir -p ${SDKDEPLOYDIR} cd ${SDK_OUTPUT}/${SDKPATH} - tar ${SDKTAROPTS} -cf - . | pixz > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz + tar ${SDKTAROPTS} -cf - . | xz -T 0 > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz } fakeroot create_shar() { --2.11.0
--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core
No, it's SDK generation, so xz-native (see SDK_DEPENDS in the first hunk).
Ross
Quoted 46 lines · Khem Raj
Quoted 7 lines · Ross Burton
xz has native support for threaded compression now and SDK creation was the only part of oe-core which is using pixz instead of xz.
Not only does this remove pixz-native from the SDK dependencies, but in my limited testing xz -T0 is slightly faster and produces smaller archives than pixz for the same input.
this is using nativesdk-xz ?
Quoted 35 lines
Signed-off-by Ross Burton <[email protected]>--- meta/classes/populate_sdk_base.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)meta/classes/populate_sdk_base.bbclass +2
-3@@ -46,7 +46,7 @@ TOOLCHAIN_TARGET_TASK_ATTEMPTONLY ?= "" TOOLCHAIN_OUTPUTNAME ?= "${SDK_NAME}-toolchain-${SDK_VERSION}" SDK_RDEPENDS = "${TOOLCHAIN_TARGET_TASK} ${TOOLCHAIN_HOST_TASK}" -SDK_DEPENDS = "virtual/fakeroot-native pixz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross" +SDK_DEPENDS = "virtual/fakeroot-native xz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross" SDK_DEPENDS_append_libc-glibc = " nativesdk-glibc-locale" # We want the MULTIARCH_TARGET_SYS to point to the TUNE_PKGARCH, not PACKAGE_ARCH as it@@ -225,7 +225,7 @@ fakeroot tar_sdk() { # Package it up mkdir -p ${SDKDEPLOYDIR} cd ${SDK_OUTPUT}/${SDKPATH} - tar ${SDKTAROPTS} -cf - . | pixz > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz + tar ${SDKTAROPTS} -cf - . | xz -T 0 > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz } fakeroot create_shar() { --2.11.0
--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core
Quoted 2 lines · Ross
No, it's SDK generation, so xz-native (see
SDK_DEPENDSin the first hunk).
OK then we need to make sure that all supported distros will have the threaded xz version
Quoted 49 lines
Ross
Quoted 46 lines · Khem Raj
Quoted 7 lines · Ross Burton
xz has native support for threaded compression now and SDK creation was the only part of oe-core which is using pixz instead of xz.
Not only does this remove pixz-native from the SDK dependencies, but in my limited testing xz -T0 is slightly faster and produces smaller archives than pixz for the same input.
this is using nativesdk-xz ?
Quoted 35 lines
Signed-off-by Ross Burton <[email protected]>--- meta/classes/populate_sdk_base.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)meta/classes/populate_sdk_base.bbclass +2
-3@@ -46,7 +46,7 @@ TOOLCHAIN_TARGET_TASK_ATTEMPTONLY ?= "" TOOLCHAIN_OUTPUTNAME ?= "${SDK_NAME}-toolchain-${SDK_VERSION}" SDK_RDEPENDS = "${TOOLCHAIN_TARGET_TASK} ${TOOLCHAIN_HOST_TASK}" -SDK_DEPENDS = "virtual/fakeroot-native pixz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross" +SDK_DEPENDS = "virtual/fakeroot-native xz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross" SDK_DEPENDS_append_libc-glibc = " nativesdk-glibc-locale" # We want the MULTIARCH_TARGET_SYS to point to the TUNE_PKGARCH, not PACKAGE_ARCH as it@@ -225,7 +225,7 @@ fakeroot tar_sdk() { # Package it up mkdir -p ${SDKDEPLOYDIR} cd ${SDK_OUTPUT}/${SDKPATH} - tar ${SDKTAROPTS} -cf - . | pixz > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz + tar ${SDKTAROPTS} -cf - . | xz -T 0 > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz } fakeroot create_shar() { --2.11.0
--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core
xz-native isn't in ASSUME_PROVIDED, we built it.
Ross
Quoted 56 lines · Khem Raj
Quoted 2 lines · Ross
No, it's SDK generation, so xz-native (see
SDK_DEPENDSin the first hunk).OK then we need to make sure that all supported distros will have the threaded xz version
Quoted 49 lines
Ross
Quoted 46 lines · Khem Raj
Quoted 7 lines · Ross Burton
xz has native support for threaded compression now and SDK creation was the only part of oe-core which is using pixz instead of xz.
Not only does this remove pixz-native from the SDK dependencies, but in my limited testing xz -T0 is slightly faster and produces smaller archives than pixz for the same input.
this is using nativesdk-xz ?
Quoted 35 lines
Signed-off-by Ross Burton <[email protected]>--- meta/classes/populate_sdk_base.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)meta/classes/populate_sdk_base.bbclass +2
-3@@ -46,7 +46,7 @@ TOOLCHAIN_TARGET_TASK_ATTEMPTONLY ?= "" TOOLCHAIN_OUTPUTNAME ?= "${SDK_NAME}-toolchain-${SDK_VERSION}" SDK_RDEPENDS = "${TOOLCHAIN_TARGET_TASK} ${TOOLCHAIN_HOST_TASK}" -SDK_DEPENDS = "virtual/fakeroot-native pixz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross" +SDK_DEPENDS = "virtual/fakeroot-native xz-native cross-localedef-native ${MLPREFIX}qemuwrapper-cross" SDK_DEPENDS_append_libc-glibc = " nativesdk-glibc-locale" # We want the MULTIARCH_TARGET_SYS to point to the TUNE_PKGARCH, not PACKAGE_ARCH as it@@ -225,7 +225,7 @@ fakeroot tar_sdk() { # Package it up mkdir -p ${SDKDEPLOYDIR} cd ${SDK_OUTPUT}/${SDKPATH} - tar ${SDKTAROPTS} -cf - . | pixz > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz + tar ${SDKTAROPTS} -cf - . | xz -T 0 > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz } fakeroot create_shar() { --2.11.0
--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core
Quoted 12 lines · Ross Burton
xz has native support for threaded compression now and SDK creation was the only part of oe-core which is using pixz instead of xz.
Not only does this remove pixz-native from the SDK dependencies, but in my limited testing xz -T0 is slightly faster and produces smaller archives than pixz for the same input.
Signed-off-by Ross Burton <[email protected]>---
# We want the
MULTIARCH_TARGET_SYSto point to theTUNE_PKGARCH, notPACKAGE_ARCHas it
meta/classes/populate_sdk_base.bbclass fakeroot tar_sdk() { · line 228
Quoted 5 lines
meta/classes/populate_sdk_base.bbclass +1
-1@@ -225,7 +225,7 @@ fakeroot tar_sdk() { # Package it up mkdir -p ${SDKDEPLOYDIR} cd ${SDK_OUTPUT}/${SDKPATH} - tar ${SDKTAROPTS} -cf - . | pixz > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz + tar ${SDKTAROPTS} -cf - . | xz -T 0 > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz
Since -T 0 will use all available CPUs (ie any attempts the user may have made to limit parallelism via BB_NUMBER_THREADS or PARALLEL_MAKE will be ignored), perhaps it's worth adding something like "--memlimit=70%" to try to give some protection for environments with lots of CPUs but not so much DRAM?
Quoted 11 lines · Andre McCurdy
Quoted 10 lines · Ross Burton
xz has native support for threaded compression now and SDK creation was the only part of oe-core which is using pixz instead of xz.
Not only does this remove pixz-native from the SDK dependencies, but in my limited testing xz -T0 is slightly faster and produces smaller archives than pixz for the same input.
Signed-off-by Ross Burton <[email protected]>---
Quoted 13 lines
meta/classes/populate_sdk_base.bbclass fakeroot tar_sdk() { · line 228
Quoted 7 lines
# We want the
MULTIARCH_TARGET_SYSto point to theTUNE_PKGARCH, notPACKAGE_ARCHas itmeta/classes/populate_sdk_base.bbclass +1
-1@@ -225,7 +225,7 @@ fakeroot tar_sdk() { # Package it up mkdir -p ${SDKDEPLOYDIR} cd ${SDK_OUTPUT}/${SDKPATH} - tar ${SDKTAROPTS} -cf - . | pixz > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz + tar ${SDKTAROPTS} -cf - . | xz -T 0 > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xzSince -T 0 will use all available CPUs (ie any attempts the user may have made to limit parallelism via
BB_NUMBER_THREADSorPARALLEL_MAKEwill be ignored), perhaps it's worth adding something like "--memlimit=70%" to try to give some protection for environments with lots of CPUs but not so much DRAM?
There's a few places where -T0 is passed already: tar.xz image creation and opkg creation, so I guess we need to centralise this somewhere too.
Ross
Quoted 26 lines · Ross
Quoted 11 lines · Andre McCurdy
Quoted 10 lines · Ross Burton
xz has native support for threaded compression now and SDK creation was the only part of oe-core which is using pixz instead of xz.
Not only does this remove pixz-native from the SDK dependencies, but in my limited testing xz -T0 is slightly faster and produces smaller archives than pixz for the same input.
Signed-off-by Ross Burton <[email protected]>---
Quoted 13 lines
meta/classes/populate_sdk_base.bbclass fakeroot tar_sdk() { · line 228
Quoted 7 lines
# We want the
MULTIARCH_TARGET_SYSto point to theTUNE_PKGARCH, notPACKAGE_ARCHas itmeta/classes/populate_sdk_base.bbclass +1
-1@@ -225,7 +225,7 @@ fakeroot tar_sdk() { # Package it up mkdir -p ${SDKDEPLOYDIR} cd ${SDK_OUTPUT}/${SDKPATH} - tar ${SDKTAROPTS} -cf - . | pixz > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz + tar ${SDKTAROPTS} -cf - . | xz -T 0 > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xzSince -T 0 will use all available CPUs (ie any attempts the user may have made to limit parallelism via
BB_NUMBER_THREADSorPARALLEL_MAKEwill be ignored), perhaps it's worth adding something like "--memlimit=70%" to try to give some protection for environments with lots of CPUs but not so much DRAM?
Quoted 4 lines
There's a few places where -T0 is passed already: tar.xz image creation and opkg creation, so I guess we need to centralise this somewhere too.
May be use XZ_OPT env bariable and param to -T could use the bitbake calculated number of CPUs
Quoted 6 lines
Ross
--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core
Quoted 27 lines · Khem Raj
Quoted 26 lines · Ross
Quoted 24 lines · Andre McCurdy
Quoted 12 lines · Ross Burton
xz has native support for threaded compression now and SDK creation was the only part of oe-core which is using pixz instead of xz.
Not only does this remove pixz-native from the SDK dependencies, but in my limited testing xz -T0 is slightly faster and produces smaller archives than pixz for the same input.
Signed-off-by Ross Burton <[email protected]>---
# We want the
MULTIARCH_TARGET_SYSto point to theTUNE_PKGARCH, notPACKAGE_ARCHas itmeta/classes/populate_sdk_base.bbclass fakeroot tar_sdk() { · line 228
Quoted 5 lines
meta/classes/populate_sdk_base.bbclass +1
-1@@ -225,7 +225,7 @@ fakeroot tar_sdk() { # Package it up mkdir -p ${SDKDEPLOYDIR} cd ${SDK_OUTPUT}/${SDKPATH} - tar ${SDKTAROPTS} -cf - . | pixz > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xz + tar ${SDKTAROPTS} -cf - . | xz -T 0 > ${SDKDEPLOYDIR}/${TOOLCHAIN_OUTPUTNAME}.tar.xzSince -T 0 will use all available CPUs (ie any attempts the user may have made to limit parallelism via
BB_NUMBER_THREADSorPARALLEL_MAKEwill be ignored), perhaps it's worth adding something like "--memlimit=70%" to try to give some protection for environments with lots of CPUs but not so much DRAM?
Quoted 7 lines
Quoted 4 lines
There's a few places where -T0 is passed already: tar.xz image creation and opkg creation, so I guess we need to centralise this somewhere too.
May be use
XZ_OPTenv bariable and param to -T could use the bitbake calculated number of CPUs
-T0 is use as many threads as there are cores, which is the same as the bitbake function. Re-using BB_NUMBER_THREADS might work.
Ross