add travis ci support for aarch64
cover add travis ci support for aarch64
This patch set is to enable native aarch64 build in Travis CI. It leverages Travis CI multi arch support.
As the first step, compilation jobs are added.
Unit test is not added for now due to service limitation. We are planning to run unit test with no-huge in future.
Ruifeng Wang (2):
ci: add travis ci support for aarch64
devtools: add path to additional shared object files
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- devtools/test-null.sh | 2 +- 3 files changed, 49 insertions(+), 6 deletions(-)
Signature · 1 line
2.17.1
PATCH 1/2 ci: add travis ci support for aarch64
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.
--- .ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 48 insertions(+), 5 deletions(-)
.ci/linux-setup.sh +7 -4
@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't run without it sudo python3 -m pip install --upgrade meson -# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# hugepage settings are skipped on aarch64 due to environment limitation +if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi
.travis.yml +41 -1
47 lines not on this page · raw message
Signature · 1 line
2.17.1
PATCH 2/2 devtools: add path to additional shared object files
In reply to Ruifeng Wanglibrte_mempool_ring.so and librte_pmd_null.so are in 'drivers' folder. Add 'drivers' into LD_LIBRARY_PATH so that testpmd can find and make use of these shared libraries.
--- devtools/test-null.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
devtools/test-null.sh +1 -1
@@ -20,7 +20,7 @@ if [ ! -f "$testpmd" ] ; then fi if ldd $testpmd | grep -q librte_ ; then - export LD_LIBRARY_PATH=$build/lib:$LD_LIBRARY_PATH + export LD_LIBRARY_PATH=$build/drivers:$build/lib:$LD_LIBRARY_PATH libs='-d librte_mempool_ring.so -d librte_pmd_null.so' else libs=
Signature · 1 line
2.17.1
Re: [dpdk-dev] [PATCH 2/2] devtools: add path to additional shared object files
Quoted 25 lines · Ruifeng Wang
librte_mempool_ring.so and librte_pmd_null.so are in 'drivers' folder. Add 'drivers' into
LD_LIBRARY_PATHso that testpmd can find and make use of these shared libraries.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>--- devtools/test-null.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)devtools/test-null.sh +1
-2@@ -20,7 +20,7 @@ if [ ! -f "$testpmd" ] ; then fi if ldd $testpmd | grep -q librte_ ; then - export LD_LIBRARY_PATH=$build/lib:$LD_LIBRARY_PATH + export LD_LIBRARY_PATH=$build/drivers:$build/lib:$LD_LIBRARY_PATH libs='-d librte_mempool_ring.so -d librte_pmd_null.so' else libs= --
Quoted 2 lines
2.17.1
I'm surprised to see this.
So far, the CI ran fine without it, so something is different in the environment.
I can see that the RPATH entry disappeared from the testpmd binary. Xenial:
# readelf -d build/app/dpdk-testpmd |grep RPATH 0x000000000000000f (RPATH) Library rpath: [$ORIGIN/../lib:$ORIGIN/../drivers:XXXXXXXXXXXXX]
(not sure what XXXX purpose is, but different topic)
Bionic:
# readelf -d build/app/dpdk-testpmd |grep RPATH
Adding Bruce and Kevin, as I think this is the same issue than:
http://mails.dpdk.org/archives/dev/2019-December/153627.html
Could it be a change in meson?
--
David Marchand
Re: [dpdk-dev] [PATCH 2/2] devtools: add path to additional shared object files
Quoted 33 lines · David Marchand
Quoted 24 lines · Ruifeng Wang
librte_mempool_ring.so and librte_pmd_null.so are in 'drivers' folder. Add 'drivers' into
LD_LIBRARY_PATHso that testpmd can find and make use of these shared libraries.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>--- devtools/test-null.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)devtools/test-null.sh +1
-2@@ -20,7 +20,7 @@ if [ ! -f "$testpmd" ] ; then fi if ldd $testpmd | grep -q librte_ ; then - export LD_LIBRARY_PATH=$build/lib:$LD_LIBRARY_PATH + export LD_LIBRARY_PATH=$build/drivers:$build/lib:$LD_LIBRARY_PATH libs='-d librte_mempool_ring.so -d librte_pmd_null.so' else libs= --Quoted 2 lines
2.17.1
I'm surprised to see this.
So far, the CI ran fine without it, so something is different in the environment.I can see that the RPATH entry disappeared from the testpmd binary. Xenial:
Quoted 8 lines
# readelf -d build/app/dpdk-testpmd |grep RPATH 0x000000000000000f (RPATH) Library rpath: [$ORIGIN/../lib:$ORIGIN/../drivers:XXXXXXXXXXXXX](not sure what XXXX purpose is, but different topic)
Bionic:
# readelf -d build/app/dpdk-testpmd |grep RPATH
It looks like RPATH just changed to be named RUNPATH in Bionic:
# readelf -d build/app/dpdk-testpmd | grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [$ORIGIN/../lib:$ORIGIN/../drivers:XXXXXXXXXXXXX]
Quoted 3 lines
Adding Bruce and Kevin, as I think this is the same issue than:
http://mails.dpdk.org/archives/dev/2019-December/153627.html
Could it be a change in meson?
Yes, looks like the same error to me.
I'm not sure this is solely a meson issue, I often need to pass -d librte_mempool_ring.so when using make builds too. Maybe I'm missing something here?
---
Kevin
Re: [dpdk-dev] [PATCH 2/2] devtools: add path to additional shared object files
Quoted 41 lines · Kevin
Quoted 39 lines · David Marchand
Quoted 24 lines · Ruifeng Wang
librte_mempool_ring.so and librte_pmd_null.so are in 'drivers' folder. Add 'drivers' into
LD_LIBRARY_PATHso that testpmd can find and make use of these shared libraries.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>--- devtools/test-null.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)devtools/test-null.sh +1
-2@@ -20,7 +20,7 @@ if [ ! -f "$testpmd" ] ; then fi if ldd $testpmd | grep -q librte_ ; then - export LD_LIBRARY_PATH=$build/lib:$LD_LIBRARY_PATH + export LD_LIBRARY_PATH=$build/drivers:$build/lib:$LD_LIBRARY_PATH libs='-d librte_mempool_ring.so -d librte_pmd_null.so' else libs= --Quoted 2 lines
2.17.1
I'm surprised to see this.
So far, the CI ran fine without it, so something is different in the environment.I can see that the RPATH entry disappeared from the testpmd binary. Xenial:
# readelf -d build/app/dpdk-testpmd |grep RPATH 0x000000000000000f (RPATH) Library rpath: [$ORIGIN/../lib:$ORIGIN/../drivers:XXXXXXXXXXXXX](not sure what XXXX purpose is, but different topic)
Quoted 8 lines
Quoted 2 lines
Bionic:
# readelf -d build/app/dpdk-testpmd |grep RPATHIt looks like RPATH just changed to be named RUNPATH in Bionic:
# readelf -d build/app/dpdk-testpmd | grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [$ORIGIN/../lib:$ORIGIN/../drivers:XXXXXXXXXXXXX]
Did some experiment with some test program and .so of mine. TL;DR, if I understand correctly, RPATH on the binary applies to all lookups, even in a subsequent .so code.
But RUNPATH only applies to the current ELF, meaning that the dlopen() in my intermediate .so does not get it.
dlopen() is called from librte_eal.so, and RUNPATH on testpmd is not enough.
Details:
[dmarchan@dmarchan plop]$ cat main.c
extern void loader(void);
int main(int argc, char *argv[])
{
loader();
return 0;
}[dmarchan@dmarchan plop]$ cat loader/loader.c
#include <dlfcn.h>
#include <stdio.h>
void loader(void)
{
if (dlopen("lib.so", RTLD_NOW) == NULL)
fprintf(stderr, "%s\n", dlerror());
}[dmarchan@dmarchan plop]$ cat lib/lib.c
#include <stdio.h>
__attribute__((constructor))
static void plop(void)
{
fprintf(stdout, "plop\n");
}# no rpath/runpath [dmarchan@dmarchan plop]$ gcc -o lib/lib.so -Wall -Werror -shared -fPIC lib/lib.c [dmarchan@dmarchan plop]$ gcc -o loader/loader.so -Wall -Werror -shared -fPIC loader/loader.c -ldl [dmarchan@dmarchan plop]$ gcc -o main -Wall -Werror main.c loader/loader.so [dmarchan@dmarchan plop]$ readelf -d main |grep R.*PATH [dmarchan@dmarchan plop]$ ./main lib.so: cannot open shared object file: No such file or directory
# using rpath on final binary [dmarchan@dmarchan plop]$ gcc -o main -Wall -Werror main.c loader/loader.so -Wl,-rpath,loader:lib [dmarchan@dmarchan plop]$ readelf -d main |grep R.*PATH 0x000000000000000f (RPATH) Library rpath: [loader:lib] [dmarchan@dmarchan plop]$ ./main plop
# using runpath on final binary [dmarchan@dmarchan plop]$ gcc -o main -Wall -Werror main.c loader/loader.so -Wl,-enable-new-dtag,-rpath,loader:lib [dmarchan@dmarchan plop]$ readelf -d main |grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [loader:lib] [dmarchan@dmarchan plop]$ ./main lib.so: cannot open shared object file: No such file or directory
# using runpath on loader [dmarchan@dmarchan plop]$ gcc -o loader/loader.so -Wall -Werror -shared -fPIC loader/loader.c -ldl -Wl,-enable-new-dtag,-rpath,lib [dmarchan@dmarchan plop]$ readelf -d loader/loader.so |grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [lib] [dmarchan@dmarchan plop]$ gcc -o main -Wall -Werror main.c loader/loader.so -Wl,-enable-new-dtag,-rpath,loader [dmarchan@dmarchan plop]$ readelf -d main |grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [loader] [dmarchan@dmarchan plop]$ ./main plop
Quoted 9 lines
Quoted 3 lines
Adding Bruce and Kevin, as I think this is the same issue than:
http://mails.dpdk.org/archives/dev/2019-December/153627.html
Could it be a change in meson?Yes, looks like the same error to me.
I'm not sure this is solely a meson issue, I often need to pass -d librte_mempool_ring.so when using make builds too. Maybe I'm missing something here?
In a make build directory, all libraries ends up in the same lib/ directory and the test-null.sh script work with the current LD_LIBRARY_PATH.
Ruifeng patch seems valid to me, but I would love some explanations in the commitlog.
--
David Marchand
Re: [dpdk-dev] [PATCH 2/2] devtools: add path to additional shared object files
Quoted 160 lines
-----Original Message-----
From: David Marchand <[email protected]>
Sent: Wednesday, December 18, 2019 3:32 PM
To: Laatz, Kevin <[email protected]>
Cc: Ruifeng Wang <[email protected]>; Richardson, Bruce <[email protected]>; Aaron Conole <[email protected]>; Michael Santana <[email protected]>; Thomas Monjalon <[email protected]>; Yigit, Ferruh <[email protected]>; Andrew Rybchenko <[email protected]>; dev <[email protected]>; Gavin Hu <[email protected]>; Honnappa Nagarahalli <[email protected]>; nd <[email protected]>
Subject: Re: [dpdk-dev] [PATCH 2/2] devtools: add path to additional shared object filesQuoted 3 lines · Kevin
Quoted 1 line · David Marchand
On Wed, Dec 18, 2019 at 6:39 AM Ruifeng Wang <[email protected]>
Quoted 1 line · wrote:
Quoted 1 line
Quoted 1 line
librte_mempool_ring.so and librte_pmd_null.so are in 'drivers'
folder.
Quoted 38 lines
Quoted 38 lines
Quoted 24 lines
Add 'drivers' into
LD_LIBRARY_PATHso that testpmd can find and make use of these shared libraries.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>--- devtools/test-null.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)devtools/test-null.sh index renamed from devtools/test-null.sh +0
-0
f39af2c06..548de8113100755devtools/test-null.sh +2
-2@@ -20,7 +20,7 @@ if [ ! -f "$testpmd" ] ; then fi if ldd $testpmd | grep -q librte_ ; then - export LD_LIBRARY_PATH=$build/lib:$LD_LIBRARY_PATH + export + LD_LIBRARY_PATH=$build/drivers:$build/lib:$LD_LIBRARY_PATH libs='-d librte_mempool_ring.so -d librte_pmd_null.so' else libs= --Quoted 2 lines
2.17.1
I'm surprised to see this.
So far, the CI ran fine without it, so something is different in the environment.I can see that the RPATH entry disappeared from the testpmd binary. Xenial:
# readelf -d build/app/dpdk-testpmd |grep RPATH 0x000000000000000f (RPATH) Library rpath: [$ORIGIN/../lib:$ORIGIN/../drivers:XXXXXXXXXXXXX](not sure what XXXX purpose is, but different topic)
Quoted 8 lines
Quoted 2 lines
Bionic:
# readelf -d build/app/dpdk-testpmd |grep RPATHIt looks like RPATH just changed to be named RUNPATH in Bionic:
# readelf -d build/app/dpdk-testpmd | grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [$ORIGIN/../lib:$ORIGIN/../drivers:XXXXXXXXXXXXX]Did some experiment with some test program and .so of mine. TL;DR, if I understand correctly, RPATH on the binary applies to all lookups, even in a subsequent .so code.
But RUNPATH only applies to the current ELF, meaning that thedlopen()in my intermediate .so does not get it.
dlopen()is called from librte_eal.so, and RUNPATH on testpmd is not enough.Details:
[dmarchan@dmarchan plop]$ catmain.c
extern void loader(void);int
main(int argc, char *argv[]){ loader(); return 0; }[dmarchan@dmarchan plop]$ cat
loader/loader.c#include <dlfcn.h> #include <stdio.h>void loader(void)
{ if (dlopen("lib.so", RTLD_NOW) == NULL) fprintf(stderr, "%s\n", dlerror()); }[dmarchan@dmarchan plop]$ cat
lib/lib.c
#include <stdio.h>__attribute__((constructor))
static void plop(void){ fprintf(stdout, "plop\n"); }# no rpath/runpath [dmarchan@dmarchan plop]$ gcc -o lib/lib.so -Wall -Werror -shared -fPIC lib/lib.c [dmarchan@dmarchan plop]$ gcc -o loader/loader.so -Wall -Werror -shared -fPIC loader/loader.c -ldl [dmarchan@dmarchan plop]$ gcc -o main - Wall -Werror main.c loader/loader.so [dmarchan@dmarchan plop]$ readelf -d main |grep R.*PATH [dmarchan@dmarchan plop]$ ./main lib.so: cannot open shared object file: No such file or directory# using rpath on final binary [dmarchan@dmarchan plop]$ gcc -o main -Wall -Werror main.c loader/loader.so -Wl,-rpath,loader:lib [dmarchan@dmarchan plop]$ readelf - d main |grep R.*PATH 0x000000000000000f (RPATH) Library rpath: [loader:lib] [dmarchan@dmarchan plop]$ ./main plop# using runpath on final binary [dmarchan@dmarchan plop]$ gcc -o main -Wall -Werror main.c loader/loader.so -Wl,-enable-new-dtag,-rpath,loader:lib [dmarchan@dmarchan plop]$ readelf -d main |grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [loader:lib] [dmarchan@dmarchan plop]$ ./main lib.so: cannot open shared object file: No such file or directory# using runpath on loader [dmarchan@dmarchan plop]$ gcc -o loader/loader.so -Wall -Werror -shared - fPIC loader/loader.c -ldl -Wl,-enable-new-dtag,-rpath,lib [dmarchan@dmarchan plop]$ readelf -d loader/loader.so |grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [lib] [dmarchan@dmarchan plop]$ gcc -o main -Wall -Werror main.c loader/loader.so -Wl,-enable-new-dtag,-rpath,loader [dmarchan@dmarchan plop]$ readelf -d main |grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [loader] [dmarchan@dmarchan plop]$ ./main plopQuoted 9 lines
Quoted 3 lines
Adding Bruce and Kevin, as I think this is the same issue than:
http://mails.dpdk.org/archives/dev/2019-December/153627.html
Could it be a change in meson?Yes, looks like the same error to me.
I'm not sure this is solely a meson issue, I often need to pass -d librte_mempool_ring.so when using make builds too. Maybe I'm missing something here?
In a make build directory, all libraries ends up in the same
lib/directory and thetest-null.shscript work with the currentLD_LIBRARY_PATH.
Quoted 5 lines
Ruifeng patch seems valid to me, but I would love some explanations in the commitlog.
--
David Marchand
Really, if we are running a shared-library build, all sorts of problems are to be expected unless we do an "install" to place the .so files in their correct locations on the filesystem.
For example, on install, the drivers are copied to a drivers directory off the lib folder, but then symlinked to lib too, so that e.g. the bus drivers can be found as dependencies of the other drivers.
For running binaries within the build directory, I always recommend using a static build instead, to avoid all these issues - this is why static linking is still the DPDK default.
In terms of this patch, I have no problem with it if it fixed the issue.
/Bruce
Re: [dpdk-dev] [PATCH 2/2] devtools: add path to additional shared object files
In reply to David MarchandQuoted 68 lines
-----Original Message-----
From: David Marchand <[email protected]>
Sent: Wednesday, December 18, 2019 23:32
To: Laatz, Kevin <[email protected]>
Cc: Ruifeng Wang <[email protected]>; Bruce Richardson <[email protected]>; Aaron Conole <[email protected]>; Michael Santana <[email protected]>; [email protected]; Yigit, Ferruh <[email protected]>; Andrew Rybchenko <[email protected]>; dev <[email protected]>; Gavin Hu <[email protected]>; Honnappa Nagarahalli <[email protected]>; nd <[email protected]>
Subject: Re: [dpdk-dev] [PATCH 2/2] devtools: add path to additional shared object filesQuoted 3 lines · Kevin
Quoted 1 line · David Marchand
On Wed, Dec 18, 2019 at 6:39 AM Ruifeng Wang <[email protected]>
Quoted 39 lines · wrote:
Quoted 39 lines
Quoted 25 lines
librte_mempool_ring.so and librte_pmd_null.so are in 'drivers' folder. Add 'drivers' into
LD_LIBRARY_PATHso that testpmd can find and make use of these shared libraries.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>--- devtools/test-null.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)devtools/test-null.sh index renamed from devtools/test-null.sh +0
-0
f39af2c06..548de8113100755devtools/test-null.sh +2
-2@@ -20,7 +20,7 @@ if [ ! -f "$testpmd" ] ; then fi if ldd $testpmd | grep -q librte_ ; then - export LD_LIBRARY_PATH=$build/lib:$LD_LIBRARY_PATH + export + LD_LIBRARY_PATH=$build/drivers:$build/lib:$LD_LIBRARY_PATH libs='-d librte_mempool_ring.so -d librte_pmd_null.so' else libs= --Quoted 2 lines
2.17.1
I'm surprised to see this.
So far, the CI ran fine without it, so something is different in the environment.I can see that the RPATH entry disappeared from the testpmd binary. Xenial:
# readelf -d build/app/dpdk-testpmd |grep RPATH 0x000000000000000f (RPATH) Library rpath: [$ORIGIN/../lib:$ORIGIN/../drivers:XXXXXXXXXXXXX](not sure what XXXX purpose is, but different topic)
Quoted 8 lines
Quoted 2 lines
Bionic:
# readelf -d build/app/dpdk-testpmd |grep RPATHIt looks like RPATH just changed to be named RUNPATH in Bionic:
# readelf -d build/app/dpdk-testpmd | grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [$ORIGIN/../lib:$ORIGIN/../drivers:XXXXXXXXXXXXX]
Quoted 8 lines
Did some experiment with some test program and .so of mine. TL;DR, if I understand correctly, RPATH on the binary applies to all lookups, even in a subsequent .so code.
But RUNPATH only applies to the current ELF, meaning that thedlopen()in my intermediate .so does not get it.
dlopen()is called from librte_eal.so, and RUNPATH on testpmd is not enough.
Thanks for your experiment and analysis. Really happy to know more around the issue.
Quoted 75 lines
Details:
[dmarchan@dmarchan plop]$ catmain.c
extern void loader(void);int
main(int argc, char *argv[]){ loader(); return 0; }[dmarchan@dmarchan plop]$ cat
loader/loader.c#include <dlfcn.h> #include <stdio.h>void loader(void)
{ if (dlopen("lib.so", RTLD_NOW) == NULL) fprintf(stderr, "%s\n", dlerror()); }[dmarchan@dmarchan plop]$ cat
lib/lib.c
#include <stdio.h>__attribute__((constructor))
static void plop(void){ fprintf(stdout, "plop\n"); }# no rpath/runpath [dmarchan@dmarchan plop]$ gcc -o lib/lib.so -Wall -Werror -shared -fPIC lib/lib.c [dmarchan@dmarchan plop]$ gcc -o loader/loader.so -Wall -Werror - shared -fPIC loader/loader.c -ldl [dmarchan@dmarchan plop]$ gcc -o main - Wall -Werror main.c loader/loader.so [dmarchan@dmarchan plop]$ readelf - d main |grep R.*PATH [dmarchan@dmarchan plop]$ ./main lib.so: cannot open shared object file: No such file or directory# using rpath on final binary [dmarchan@dmarchan plop]$ gcc -o main -Wall -Werror main.c loader/loader.so -Wl,-rpath,loader:lib [dmarchan@dmarchan plop]$ readelf - d main |grep R.*PATH 0x000000000000000f (RPATH) Library rpath: [loader:lib] [dmarchan@dmarchan plop]$ ./main plop# using runpath on final binary [dmarchan@dmarchan plop]$ gcc -o main -Wall -Werror main.c loader/loader.so -Wl,-enable-new-dtag,-rpath,loader:lib [dmarchan@dmarchan plop]$ readelf -d main |grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [loader:lib] [dmarchan@dmarchan plop]$ ./main lib.so: cannot open shared object file: No such file or directory# using runpath on loader [dmarchan@dmarchan plop]$ gcc -o loader/loader.so -Wall -Werror -shared - fPIC loader/loader.c -ldl -Wl,-enable-new-dtag,-rpath,lib [dmarchan@dmarchan plop]$ readelf -d loader/loader.so |grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [lib] [dmarchan@dmarchan plop]$ gcc -o main -Wall -Werror main.c loader/loader.so -Wl,-enable-new-dtag,-rpath,loader [dmarchan@dmarchan plop]$ readelf -d main |grep R.*PATH 0x000000000000001d (RUNPATH) Library runpath: [loader] [dmarchan@dmarchan plop]$ ./main plopQuoted 9 lines
Quoted 3 lines
Adding Bruce and Kevin, as I think this is the same issue than:
http://mails.dpdk.org/archives/dev/2019-December/153627.html
Could it be a change in meson?Yes, looks like the same error to me.
I'm not sure this is solely a meson issue, I often need to pass -d librte_mempool_ring.so when using make builds too. Maybe I'm missing something here?
Quoted 7 lines
In a make build directory, all libraries ends up in the same
lib/directory and thetest-null.shscript work with the currentLD_LIBRARY_PATH.Ruifeng patch seems valid to me, but I would love some explanations in the commitlog.
Sure. I will re-spin to add explanations.
Quoted 2 lines
--
David Marchand
v2 cover add travis ci support for aarch64
In reply to Ruifeng WangThis patch set is to enable native aarch64 build in Travis CI. It leverages Travis CI multi arch support.
As the first step, compilation jobs are added.
Unit test is not added for now due to service limitation. We are planning to run unit test with no-huge in future.
This patch set has dependency on:
http://patches.dpdk.org/patch/63969/
v2:
Removed dist designation from matrix since base dist is changing. Add explanation for library path issue.
Ruifeng Wang (2):
ci: add travis ci support for aarch64
devtools: add path to additional shared object files
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 37 ++++++++++++++++++++++++++++++++++++- devtools/test-null.sh | 2 +- 3 files changed, 44 insertions(+), 6 deletions(-)
Signature · 1 line
2.17.1
PATCH v2 1/2 ci: add travis ci support for aarch64
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.
--- .ci/linux-setup.sh | 11 +++++++---- .travis.yml | 37 ++++++++++++++++++++++++++++++++++++- 2 files changed, 43 insertions(+), 5 deletions(-)
.ci/linux-setup.sh +7 -4
@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't run without it sudo python3 -m pip install --upgrade meson -# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# hugepage settings are skipped on aarch64 due to environment limitation +if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi
.travis.yml +36 -1
@@ -115,6 +115,41 @@ matrix: apt: packages: - *extra_packages - + - env: DEF_LIB="static" + arch: arm64 + compiler: gcc + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: gcc + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="static" + arch: arm64 + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1 + arch: arm64 + compiler: gcc + addons: + apt: + packages: + - *required_packages + - *doc_packages script: ./.ci/${TRAVIS_OS_NAME}-build.sh
Signature · 1 line
2.17.1
Re: [dpdk-dev] [PATCH v2 1/2] ci: add travis ci support for aarch64
Quoted 27 lines · Ruifeng Wang
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>--- .ci/linux-setup.sh | 11 +++++++---- .travis.yml | 37 ++++++++++++++++++++++++++++++++++++- 2 files changed, 43 insertions(+), 5 deletions(-).ci/linux-setup.sh +0
-0@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't runwithout it
sudo python3 -m pip install --upgrade meson
.ci/linux-setup.sh line 9
Quoted 4 lines
.ci/linux-setup.sh +0
-4-# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo
dont test for TRAVIS_ARCH here as multiple archs may need to avoid the hugepage setup as well.
How about:
if [ "$RUN_TESTS" = "1" ]; then
# setup hugepages
If your planning to add a tests using --no-huge option could we add a NOHUGEPAGES option to the matrix?
Quoted 55 lines
+# hugepage settings are skipped on aarch64 due to environment limitation
.ci/linux-setup.sh +6
-0+if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi.travis.yml +36
-1@@ -115,6 +115,41 @@ matrix: apt: packages: - *extra_packages - + - env: DEF_LIB="static" + arch: arm64 + compiler: gcc + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: gcc + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="static" + arch: arm64 + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1 + arch: arm64 + compiler: gcc + addons: + apt: + packages: + - *required_packages + - *doc_packages script: ./.ci/${TRAVIS_OS_NAME}-build.sh
Re: [dpdk-dev] [PATCH v2 1/2] ci: add travis ci support for aarch64
Quoted 48 lines
-----Original Message-----
From: dwilder <[email protected]>
Sent: Tuesday, January 7, 2020 04:17
To: Ruifeng Wang <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Gavin Hu <[email protected]>; Honnappa Nagarahalli <[email protected]>; nd <[email protected]>
Subject: Re: [dpdk-dev] [PATCH v2 1/2] ci: add travis ci support for aarch64Quoted 27 lines · Ruifeng Wang
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>--- .ci/linux-setup.sh | 11 +++++++---- .travis.yml | 37 ++++++++++++++++++++++++++++++++++++- 2 files changed, 43 insertions(+), 5 deletions(-).ci/linux-setup.sh index renamed from .ci/linux-setup.sh +0
-0
dfb9d4a20..a92978037100755.ci/linux-setup.sh +0
-0@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't runwithout it sudo python3 -m pip install --upgrade meson
.ci/linux-setup.sh line 9
Quoted 4 lines
.ci/linux-setup.sh +0
-4-# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfodont test for
TRAVIS_ARCHhere as multiple archs may need to avoid the hugepage setup as well.
Quoted 3 lines
How about:
if [ "$RUN_TESTS" = "1" ]; then# setup hugepages
This should work. I can try this approach in next version. My concern is the name may cause confusion. 'RUN_TESTS' will mean to run default tests (with hugepage).
Quoted 3 lines
If your planning to add a tests using --no-huge option could we add a NOHUGEPAGES option to the matrix?
Yes, this will give control to choose test suite. I will take this into consideration.
Quoted 56 lines
Quoted 56 lines
+# hugepage settings are skipped on aarch64 due to environment limitation
.ci/linux-setup.sh +6
-0+if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi.travis.yml index 8f90d06f2..048cb6ba5 renamed from .travis.yml +0
-0100644
.travis.yml +36
-1@@ -115,6 +115,41 @@ matrix: apt: packages: - *extra_packages - + - env: DEF_LIB="static" + arch: arm64 + compiler: gcc + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: gcc + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="static" + arch: arm64 + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1 + arch: arm64 + compiler: gcc + addons: + apt: + packages: + - *required_packages + - *doc_packages script: ./.ci/${TRAVIS_OS_NAME}-build.sh
PATCH v2 2/2 devtools: add path to additional shared object files
In reply to Ruifeng WangDrivers librte_mempool_ring.so and librte_pmd_null.so are loaded by librte_eal.so when running testpmd.
In Ubuntu Xenial, driver path is installed to RPATH on testpmd. This allows librte_eal.so to find drivers by using the RPATH. However, in Ubuntu Bionic, driver path is installed to RUNPATH instead. The RUNPATH on testpmd is not available by librte_eal.so and therefore lead to driver load failure:
EAL: Detected 32 lcore(s)
EAL: Detected 1 NUMA nodes
EAL: librte_mempool_ring.so: cannot open shared object file:
No such file or directory
EAL: FATAL: Cannot init plugins
EAL: Cannot init plugins
Add 'drivers' into LD_LIBRARY_PATH so that testpmd can find and make use of these shared libraries.
--- devtools/test-null.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
devtools/test-null.sh +1 -1
@@ -20,7 +20,7 @@ if [ ! -f "$testpmd" ] ; then fi if ldd $testpmd | grep -q librte_ ; then - export LD_LIBRARY_PATH=$build/lib:$LD_LIBRARY_PATH + export LD_LIBRARY_PATH=$build/drivers:$build/lib:$LD_LIBRARY_PATH libs='-d librte_mempool_ring.so -d librte_pmd_null.so' else libs=
Signature · 1 line
2.17.1
Quoted 8 lines · Ruifeng Wang
This patch set is to enable native aarch64 build in Travis CI. It leverages Travis CI multi arch support.
As the first step, compilation jobs are added.
Unit test is not added for now due to service limitation. We are planning to run unit test with no-huge in future.
Quoted 6 lines
This patch set has dependency on:
http://patches.dpdk.org/patch/63969/v2:
Removed dist designation from matrix since base dist is changing.
*If* (I did not think about the implications yet, hence the *If*) we switch the base distribution to Bionic, we can't push it anyway without your second patch.
Patches order must be reversed.
And for the jobs in travis, the distribution for aarch64 native jobs must be explicitely bionic distribution (you did not update the commitlog in the v2 but not a problem if you restore the dist: bionic entries).
We can then take your series.
Kevin patch that upgrades globally from xenial to bionic, can then be integrated after yours.
Quoted 1 line
Add explanation for library path issue.
Thanks for this.
Signature · 1 line
David Marchand
v3 cover add travis ci support for aarch64
In reply to Ruifeng WangThis patch set is to enable native aarch64 build in Travis CI. It leverages Travis CI multi arch support.
As the first step, compilation jobs are added.
Unit test is not added for now due to service limitation. We are planning to run unit test with no-huge in future.
v3:
Reverse patches order. Not depending on other patches. Restore distribution designation for aarch64 native jobs.
v2:
Removed dist designation from matrix since base dist is changing. Add explanation for library path issue.
Ruifeng Wang (2):
devtools: add path to additional shared object files
ci: add travis ci support for aarch64
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- devtools/test-null.sh | 2 +- 3 files changed, 49 insertions(+), 6 deletions(-)
Signature · 1 line
2.17.1
PATCH v3 1/2 devtools: add path to additional shared object files
Drivers librte_mempool_ring.so and librte_pmd_null.so are loaded by librte_eal.so when running testpmd.
In Ubuntu Xenial, driver path is installed to RPATH on testpmd. This allows librte_eal.so to find drivers by using the RPATH. However, in Ubuntu Bionic, driver path is installed to RUNPATH instead. The RUNPATH on testpmd is not available by librte_eal.so and therefore lead to driver load failure:
EAL: Detected 32 lcore(s)
EAL: Detected 1 NUMA nodes
EAL: librte_mempool_ring.so: cannot open shared object file:
No such file or directory
EAL: FATAL: Cannot init plugins
EAL: Cannot init plugins
Add 'drivers' into LD_LIBRARY_PATH so that testpmd can find and make use of these shared libraries.
--- devtools/test-null.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
devtools/test-null.sh +1 -1
@@ -20,7 +20,7 @@ if [ ! -f "$testpmd" ] ; then fi if ldd $testpmd | grep -q librte_ ; then - export LD_LIBRARY_PATH=$build/lib:$LD_LIBRARY_PATH + export LD_LIBRARY_PATH=$build/drivers:$build/lib:$LD_LIBRARY_PATH libs='-d librte_mempool_ring.so -d librte_pmd_null.so' else libs=
Signature · 1 line
2.17.1
PATCH v3 2/2 ci: add travis ci support for aarch64
In reply to Ruifeng WangAdd Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.
--- .ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 48 insertions(+), 5 deletions(-)
.ci/linux-setup.sh +7 -4
@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't run without it sudo python3 -m pip install --upgrade meson -# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# hugepage settings are skipped on aarch64 due to environment limitation +if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi
.travis.yml +41 -1
47 lines not on this page · raw message
Signature · 1 line
2.17.1
Re: [dpdk-dev] [PATCH v3 2/2] ci: add travis ci support for aarch64
Quoted 7 lines · Ruifeng Wang
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.
Quoted 7 lines
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
Can't we achieve the same thing by setting
arch:
- amd64
- arm64
in the build matrix? Or will that also force the intel builds to use the container infrastructure (in which case the no-huge support needs to be fixed)?
One thing I wonder, isn't is possible to use qemu-user to do the amd64 unit tests? Then do we really need some changes to do the native build? Does it buy us anything *today* given the cost of the hugepage restriction? Will that ever be resolved (I didn't see so from the docs on travis)?
Quoted 75 lines
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 48 insertions(+), 5 deletions(-).ci/linux-setup.sh +7
-4@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't run without it sudo python3 -m pip install --upgrade meson -# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# hugepage settings are skipped on aarch64 due to environment limitation +if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi.travis.yml +41
-1@@ -115,6 +115,46 @@ matrix: apt: packages: - *extra_packages - + - env: DEF_LIB="static" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="static" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1 + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - *doc_packages script: ./.ci/${TRAVIS_OS_NAME}-build.sh
Re: [dpdk-dev] [PATCH v3 2/2] ci: add travis ci support for aarch64
Quoted 28 lines
-----Original Message-----
From: Aaron Conole <[email protected]>
Sent: Monday, January 6, 2020 21:34
To: Ruifeng Wang <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Gavin Hu <[email protected]>; Honnappa Nagarahalli <[email protected]>; nd <[email protected]>
Subject: Re: [PATCH v3 2/2] ci: add travis ci support for aarch64Quoted 7 lines · Ruifeng Wang
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Quoted 7 lines
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
Quoted 8 lines
Can't we achieve the same thing by setting
arch:
- amd64
- arm64in the build matrix? Or will that also force the intel builds to use the container infrastructure (in which case the no-huge support needs to be fixed)?
No, container infrastructure will not be imposed to intel builds.
AFAIN, Travis infrastructure for a specific CPU arch is provided as is, and there is no config option to control. The problem with just adding 'arch' in build matrix is that RUN_TESTS on arm64 is not supported by now (Travis limitation). 'env' with RUN_TESTS will fail.
Quoted 3 lines
One thing I wonder, isn't is possible to use qemu-user to do the amd64 unit tests? Then do we really need some changes to do the native build?
Do you mean to use qemu-user to do unit tests for non-x86 arch?
Changes will be needed as well to enable qemu-user to do unit test.
Since Travis support multi CPU arch, I think native build and test is simpler and more natural.
Quoted 2 lines
Does it buy us anything *today* given the cost of the hugepage restriction? Will that ever be resolved (I didn't see so from the docs on travis)?
The hugepage issue has been reported to Travis. I think it will be resolved. But no set dates yet.
Quoted 76 lines
Quoted 76 lines
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 48 insertions(+), 5 deletions(-).ci/linux-setup.sh index renamed from .ci/linux-setup.sh +0
-0
dfb9d4a20..a92978037100755.ci/linux-setup.sh +0
-0@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't runwithout it sudo python3 -m pip install --upgrade meson
.ci/linux-setup.sh +7
-4-# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# hugepage settings are skipped on aarch64 due to environment +limitation if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi.travis.yml index 8f90d06f2..980c7605d renamed from .travis.yml +0
-0100644
.travis.yml +41
-1@@ -115,6 +115,46 @@ matrix: apt: packages: - *extra_packages - + - env: DEF_LIB="static" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="static" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1 + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - *doc_packages script: ./.ci/${TRAVIS_OS_NAME}-build.sh
Re: [dpdk-dev] [PATCH v3 2/2] ci: add travis ci support for aarch64
<snip>
Quoted 33 lines
Quoted 16 lines
Quoted 8 lines
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Quoted 7 lines
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
Quoted 8 lines
Can't we achieve the same thing by setting
arch:
- amd64
- arm64in the build matrix? Or will that also force the intel builds to use the container infrastructure (in which case the no-huge support needs to be
fixed)?
No, container infrastructure will not be imposed to intel builds. AFAIN, Travis infrastructure for a specific CPU arch is provided as is, and there is no config option to control.
The problem with just adding 'arch' in build matrix is thatRUN_TESTSon arm64 is not supported by now (Travis limitation). 'env' withRUN_TESTSwill fail.Quoted 1 line
Quoted 7 lines
Quoted 2 lines
One thing I wonder, isn't is possible to use qemu-user to do the amd64 unit tests? Then do we really need some changes to do the native build?
Do you mean to use qemu-user to do unit tests for non-x86 arch? Changes will be needed as well to enable qemu-user to do unit test. Since Travis support multi CPU arch, I think native build and test is simpler and more natural.
Yes, prefer to run the tests natively as the infrastructure is available and will improve further from here.
Quoted 83 lines
Quoted 3 lines
Does it buy us anything *today* given the cost of the hugepage restriction? Will that ever be resolved (I didn't see so from the docs on travis)?
The hugepage issue has been reported to Travis. I think it will be resolved. But no set dates yet.
Quoted 76 lines
Quoted 76 lines
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 48 insertions(+), 5 deletions(-).ci/linux-setup.sh index renamed from .ci/linux-setup.sh +0
-0
dfb9d4a20..a92978037100755.ci/linux-setup.sh +0
-0@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't runwithout it sudo python3 -m pip install --upgrade meson
.ci/linux-setup.sh +7
-4-# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# hugepage settings are skipped on aarch64 due to environment +limitation if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi.travis.yml index 8f90d06f2..980c7605d renamed from .travis.yml +0
-0100644
.travis.yml +41
-1@@ -115,6 +115,46 @@ matrix: apt: packages: - *extra_packages - + - env: DEF_LIB="static" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="static" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1 + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - *doc_packages script: ./.ci/${TRAVIS_OS_NAME}-build.sh
Re: [dpdk-dev] [PATCH v3 2/2] ci: add travis ci support for aarch64
Quoted 38 lines · Honnappa Nagarahalli
<snip>
Quoted 36 lines
Quoted 16 lines
Quoted 8 lines
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Quoted 7 lines
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
Quoted 8 lines
Can't we achieve the same thing by setting
arch:
- amd64
- arm64in the build matrix? Or will that also force the intel builds to use the container infrastructure (in which case the no-huge support needs to be
fixed)?
No, container infrastructure will not be imposed to intel builds. AFAIN, Travis infrastructure for a specific CPU arch is provided as is, and there is no config option to control.
The problem with just adding 'arch' in build matrix is thatRUN_TESTSon arm64 is not supported by now (Travis limitation). 'env' withRUN_TESTSwill fail.Quoted 3 lines
One thing I wonder, isn't is possible to use qemu-user to do the amd64 unit tests? Then do we really need some changes to do the native build?
Quoted 6 lines
Quoted 4 lines
Do you mean to use qemu-user to do unit tests for non-x86 arch? Changes will be needed as well to enable qemu-user to do unit test. Since Travis support multi CPU arch, I think native build and test is simpler and more natural.
Yes, prefer to run the tests natively as the infrastructure is available and will improve further from here.
Agreed. But we can't run the aarch64 tests for now, no matter which way we slice it.
Quoted 83 lines
Quoted 83 lines
Quoted 3 lines
Does it buy us anything *today* given the cost of the hugepage restriction? Will that ever be resolved (I didn't see so from the docs on travis)?
The hugepage issue has been reported to Travis. I think it will be resolved. But no set dates yet.
Quoted 76 lines
Quoted 76 lines
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 48 insertions(+), 5 deletions(-).ci/linux-setup.sh index renamed from .ci/linux-setup.sh +0
-0
dfb9d4a20..a92978037100755.ci/linux-setup.sh +0
-0@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't runwithout it sudo python3 -m pip install --upgrade meson
.ci/linux-setup.sh +7
-4-# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# hugepage settings are skipped on aarch64 due to environment +limitation if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi.travis.yml index 8f90d06f2..980c7605d renamed from .travis.yml +0
-0100644
.travis.yml +41
-1@@ -115,6 +115,46 @@ matrix: apt: packages: - *extra_packages - + - env: DEF_LIB="static" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="static" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1 + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - *doc_packages script: ./.ci/${TRAVIS_OS_NAME}-build.sh
Re: [dpdk-dev] [PATCH v3 2/2] ci: add travis ci support for aarch64
In reply to Ruifeng WangQuoted 33 lines · Ruifeng Wang
Quoted 33 lines
-----Original Message-----
From: Aaron Conole <[email protected]>
Sent: Monday, January 6, 2020 21:34
To: Ruifeng Wang <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Gavin Hu <[email protected]>; Honnappa Nagarahalli <[email protected]>; nd <[email protected]>
Subject: Re: [PATCH v3 2/2] ci: add travis ci support for aarch64Quoted 7 lines · Ruifeng Wang
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Quoted 7 lines
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
Can't we achieve the same thing by setting
arch:
- amd64
- arm64
Quoted 8 lines
Quoted 2 lines
in the build matrix? Or will that also force the intel builds to use the container infrastructure (in which case the no-huge support needs to be fixed)?
No, container infrastructure will not be imposed to intel builds.
AFAIN, Travis infrastructure for a specific CPU arch is provided as
is, and there is no config option to control.
The problem with just adding 'arch' in build matrix is thatRUN_TESTSon arm64 is not supported by now (Travis limitation). 'env' withRUN_TESTSwill fail.
Okay I see.
Quoted 5 lines
Quoted 3 lines
One thing I wonder, isn't is possible to use qemu-user to do the amd64 unit tests? Then do we really need some changes to do the native build?
Do you mean to use qemu-user to do unit tests for non-x86 arch?
Yes. This has the advantage of giving users a way to also do the multi-arch checks on their own systems (so a developer with just an x86 could at least do some testing on arm or ppc).
Quoted 2 lines
Changes will be needed as well to enable qemu-user to do unit test.
Since Travis support multi CPU arch, I think native build and test is simpler and more natural.
I agree, some script changes might be needed, but maybe not as many as you fear (can't we use binfmt_misc infrastructure to do this with qemu-user and then the actual 'execute' would work).
Quoted 5 lines
Quoted 2 lines
Does it buy us anything *today* given the cost of the hugepage restriction? Will that ever be resolved (I didn't see so from the docs on travis)?
The hugepage issue has been reported to Travis. I think it will be resolved. But no set dates yet.
Is there a plan for them to address? I guess probably not. So we either need the ability for tests to run in the no-huge environment (and detect that no hugepages are available to run the tests that way), or we need the travis environment supporting hugepages. Is there something I missed?
Quoted 76 lines
Quoted 76 lines
Quoted 76 lines
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 48 insertions(+), 5 deletions(-).ci/linux-setup.sh index renamed from .ci/linux-setup.sh +0
-0
dfb9d4a20..a92978037100755.ci/linux-setup.sh +0
-0@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't runwithout it sudo python3 -m pip install --upgrade meson
.ci/linux-setup.sh +7
-4-# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# hugepage settings are skipped on aarch64 due to environment +limitation if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi.travis.yml index 8f90d06f2..980c7605d renamed from .travis.yml +0
-0100644
.travis.yml +41
-1@@ -115,6 +115,46 @@ matrix: apt: packages: - *extra_packages - + - env: DEF_LIB="static" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="static" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1 + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - *doc_packages script: ./.ci/${TRAVIS_OS_NAME}-build.sh
Re: [dpdk-dev] [PATCH v3 2/2] ci: add travis ci support for aarch64
Quoted 66 lines · Aaron Conole
Quoted 33 lines · Ruifeng Wang
Quoted 33 lines
-----Original Message-----
From: Aaron Conole <[email protected]>
Sent: Monday, January 6, 2020 21:34
To: Ruifeng Wang <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Gavin Hu <[email protected]>; Honnappa Nagarahalli <[email protected]>; nd <[email protected]>
Subject: Re: [PATCH v3 2/2] ci: add travis ci support for aarch64Quoted 7 lines · Ruifeng Wang
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Quoted 7 lines
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
Can't we achieve the same thing by setting
arch:
- amd64
- arm64Quoted 8 lines
Quoted 2 lines
in the build matrix? Or will that also force the intel builds to use the container infrastructure (in which case the no-huge support needs to be fixed)?
No, container infrastructure will not be imposed to intel builds.
AFAIN, Travis infrastructure for a specific CPU arch is provided as
is, and there is no config option to control.
The problem with just adding 'arch' in build matrix is thatRUN_TESTSon arm64 is not supported by now (Travis limitation). 'env' withRUN_TESTSwill fail.Okay I see.
Quoted 5 lines
Quoted 3 lines
One thing I wonder, isn't is possible to use qemu-user to do the amd64 unit tests? Then do we really need some changes to do the native build?
Do you mean to use qemu-user to do unit tests for non-x86 arch?
Yes. This has the advantage of giving users a way to also do the multi-arch checks on their own systems (so a developer with just an x86 could at least do some testing on arm or ppc).
Quoted 2 lines
Changes will be needed as well to enable qemu-user to do unit test.
Since Travis support multi CPU arch, I think native build and test is simpler and more natural.I agree, some script changes might be needed, but maybe not as many as you fear (can't we use
binfmt_miscinfrastructure to do this with qemu-user and then the actual 'execute' would work).Quoted 3 lines
Quoted 2 lines
Does it buy us anything *today* given the cost of the hugepage restriction? Will that ever be resolved (I didn't see so from the docs on travis)?
Quoted 9 lines
Quoted 2 lines
The hugepage issue has been reported to Travis. I think it will be resolved. But no set dates yet.
Is there a plan for them to address? I guess probably not. So we either need the ability for tests to run in the no-huge environment (and detect that no hugepages are available to run the tests that way), or we need the travis environment supporting hugepages. Is there something I missed?
I think a reasonable number of tests should already run in a no-huge environment. Ideally we could have autotest detect the fact it's running with no-huge and skip all unsupported tests, but I think that would be quite a bit of work to undertake, given the number of tests there are.
/Bruce
Re: [dpdk-dev] [PATCH v3 2/2] ci: add travis ci support for aarch64
In reply to Aaron ConoleQuoted 63 lines
-----Original Message-----
From: Aaron Conole <[email protected]>
Sent: Thursday, January 9, 2020 00:05
To: Ruifeng Wang <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Gavin Hu <[email protected]>; Honnappa Nagarahalli <[email protected]>; nd <[email protected]>
Subject: Re: [PATCH v3 2/2] ci: add travis ci support for aarch64Quoted 7 lines · Ruifeng Wang
Quoted 7 lines
-----Original Message-----
From: Aaron Conole <[email protected]>
Sent: Monday, January 6, 2020 21:34
To: Ruifeng Wang <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Gavin Hu <[email protected]>;Honnappa
Quoted 20 lines
Quoted 20 lines
Nagarahalli <[email protected]>; nd <[email protected]>
Subject: Re: [PATCH v3 2/2] ci: add travis ci support for aarch64Quoted 14 lines · Ruifeng Wang
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
Quoted 8 lines
Quoted 8 lines
Can't we achieve the same thing by setting
arch:
- amd64
- arm64in the build matrix? Or will that also force the intel builds to use the container infrastructure (in which case the no-huge support needs to
be fixed)?
Quoted 6 lines
No, container infrastructure will not be imposed to intel builds. AFAIN, Travis infrastructure for a specific CPU arch is provided as is, and there is no config option to control.
The problem with just adding 'arch' in build matrix is thatRUN_TESTSon arm64 is not supported by now (Travis limitation). 'env' withRUN_TESTSwill fail.
Okay I see.
Quoted 3 lines
Quoted 3 lines
One thing I wonder, isn't is possible to use qemu-user to do the amd64 unit tests? Then do we really need some changes to do the native
Quoted 8 lines
build?
Quoted 2 lines
Do you mean to use qemu-user to do unit tests for non-x86 arch?
Yes. This has the advantage of giving users a way to also do the multi-arch checks on their own systems (so a developer with just an x86 could at least do some testing on arm or ppc).
Yes, users can do multi-arch checks *locally* by using qemu.
This patch aims to enable *public* CI for aarch64. It has no sense to rely on specific arch while infrastructure supports multi arch.
Quoted 8 lines
Quoted 2 lines
Changes will be needed as well to enable qemu-user to do unit test. Since Travis support multi CPU arch, I think native build and test is simpler
and more natural.
I agree, some script changes might be needed, but maybe not as many as you fear (can't we use
binfmt_miscinfrastructure to do this with qemu-user and then the actual 'execute' would work).
It is more like a tool for local validation, and should be another story.
Quoted 4 lines
Quoted 1 line
Quoted 1 line
Does it buy us anything *today* given the cost of the hugepage
restriction?
Quoted 2 lines
Quoted 1 line
Will that ever be resolved (I didn't see so from the docs on travis)?
Quoted 8 lines
Quoted 2 lines
The hugepage issue has been reported to Travis. I think it will be resolved. But no set dates yet.
Is there a plan for them to address? I guess probably not. So we either need the ability for tests to run in the no-huge environment (and detect that no hugepages are available to run the tests that way), or we need the travis environment supporting hugepages. Is there something I missed?
Yes, over half of quick tests can run in no-huge environment.
Quoted 78 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42+++++++++++++++++++++++++++++++++++++++++-
Quoted 55 lines
Quoted 55 lines
Quoted 55 lines
2 files changed, 48 insertions(+), 5 deletions(-).ci/linux-setup.sh index renamed from .ci/linux-setup.sh +0
-0
dfb9d4a20..a92978037100755.ci/linux-setup.sh +0
-0@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't runwithout it sudo python3 -m pip install --upgrade meson
.ci/linux-setup.sh +7
-4-# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# hugepage settings are skipped on aarch64 due to environment +limitation if [ "$TRAVIS_ARCH" != "aarch64" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi.travis.yml index 8f90d06f2..980c7605d renamed from .travis.yml +0
-0100644
.travis.yml +25
-1@@ -115,6 +115,46 @@ matrix: apt: packages: - *extra_packages - + - env: DEF_LIB="static" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" + arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="static" + arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared"Quoted 8 lines
Quoted 8 lines
.travis.yml matrix:
Quoted 8 lines
.travis.yml +8
-0+ arch: arm64 + dist: bionic + compiler: clang + addons: + apt: + packages: + - *required_packages + - env: DEF_LIB="shared" OPTS="-Denable_kmods=false"BUILD_DOCS=1
Quoted 10 lines
Quoted 10 lines
Quoted 10 lines
.travis.yml +8
-0+ arch: arm64 + compiler: gcc + dist: bionic + addons: + apt: + packages: + - *required_packages + - *doc_packages script: ./.ci/${TRAVIS_OS_NAME}-build.sh
Re: [dpdk-dev] [PATCH v3 2/2] ci: add travis ci support for aarch64
<snip>
Quoted 71 lines
Quoted 41 lines
Quoted 18 lines
Quoted 18 lines
Quoted 8 lines
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Quoted 7 lines
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
Can't we achieve the same thing by setting
Quoted 7 lines
Quoted 7 lines
arch:
- amd64
- arm64in the build matrix? Or will that also force the intel builds to use the container infrastructure (in which case the no-huge support needs to
be fixed)?
Quoted 7 lines
No, container infrastructure will not be imposed to intel builds. AFAIN, Travis infrastructure for a specific CPU arch is provided as is, and there is no config option to control.
The problem with just adding 'arch' in build matrix is thatRUN_TESTSon arm64 is not supported by now (Travis limitation). 'env' withRUN_TESTSwill fail.
Okay I see.
Quoted 4 lines
Quoted 4 lines
One thing I wonder, isn't is possible to use qemu-user to do the amd64 unit tests? Then do we really need some changes to do the native
Quoted 8 lines
build?
Quoted 2 lines
Do you mean to use qemu-user to do unit tests for non-x86 arch?
Yes. This has the advantage of giving users a way to also do the multi-arch checks on their own systems (so a developer with just an x86 could at least do some testing on arm or ppc).
Yes, users can do multi-arch checks *locally* by using qemu.
This patch aims to enable *public* CI for aarch64. It has no sense to rely on specific arch while infrastructure supports multi arch.Quoted 9 lines
Quoted 3 lines
Changes will be needed as well to enable qemu-user to do unit test. Since Travis support multi CPU arch, I think native build and test is simpler
and more natural.
I agree, some script changes might be needed, but maybe not as many as you fear (can't we use
binfmt_miscinfrastructure to do this with qemu-user and then the actual 'execute' would work).It is more like a tool for local validation, and should be another story.
Quoted 7 lines
Quoted 1 line
Quoted 1 line
Does it buy us anything *today* given the cost of the hugepage
restriction?
Quoted 4 lines
Quoted 1 line
Will that ever be resolved (I didn't see so from the docs on travis)?
The hugepage issue has been reported to Travis. I think it will be resolved. But no set dates yet.
Quoted 7 lines
Quoted 4 lines
Is there a plan for them to address? I guess probably not. So we either need the ability for tests to run in the no-huge environment (and detect that no hugepages are available to run the tests that way), or we need the travis environment supporting hugepages. Is there
something I missed?
Quoted 1 line
Yes, over half of quick tests can run in no-huge environment.
Plan is to enable the testing for whatever works today and work on fixing the remaining test cases. Is this ok?
<snip>
Re: [dpdk-dev] [PATCH v3 2/2] ci: add travis ci support for aarch64
Quoted 77 lines · Honnappa Nagarahalli
<snip>
Quoted 75 lines
Quoted 41 lines
Quoted 18 lines
Quoted 18 lines
Quoted 8 lines
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Quoted 7 lines
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
Can't we achieve the same thing by setting
Quoted 7 lines
Quoted 7 lines
arch:
- amd64
- arm64in the build matrix? Or will that also force the intel builds to use the container infrastructure (in which case the no-huge support needs to
be fixed)?
Quoted 7 lines
No, container infrastructure will not be imposed to intel builds. AFAIN, Travis infrastructure for a specific CPU arch is provided as is, and there is no config option to control.
The problem with just adding 'arch' in build matrix is thatRUN_TESTSon arm64 is not supported by now (Travis limitation). 'env' withRUN_TESTSwill fail.
Okay I see.
Quoted 4 lines
Quoted 4 lines
One thing I wonder, isn't is possible to use qemu-user to do the amd64 unit tests? Then do we really need some changes to do the native
Quoted 8 lines
build?
Quoted 2 lines
Do you mean to use qemu-user to do unit tests for non-x86 arch?
Yes. This has the advantage of giving users a way to also do the multi-arch checks on their own systems (so a developer with just an x86 could at least do some testing on arm or ppc).
Yes, users can do multi-arch checks *locally* by using qemu.
This patch aims to enable *public* CI for aarch64. It has no sense to rely on specific arch while infrastructure supports multi arch.Quoted 9 lines
Quoted 3 lines
Changes will be needed as well to enable qemu-user to do unit test. Since Travis support multi CPU arch, I think native build and test is simpler
and more natural.
I agree, some script changes might be needed, but maybe not as many as you fear (can't we use
binfmt_miscinfrastructure to do this with qemu-user and then the actual 'execute' would work).It is more like a tool for local validation, and should be another story.
Quoted 11 lines
Quoted 1 line
Quoted 1 line
Does it buy us anything *today* given the cost of the hugepage
restriction?
Quoted 4 lines
Quoted 1 line
Will that ever be resolved (I didn't see so from the docs on travis)?
The hugepage issue has been reported to Travis. I think it will be resolved. But no set dates yet.
Is there a plan for them to address? I guess probably not. So we either need the ability for tests to run in the no-huge environment (and detect that no hugepages are available to run the tests that way), or we need the travis environment supporting hugepages. Is there
Quoted 5 lines
Quoted 3 lines
something I missed?
Quoted 1 line
Yes, over half of quick tests can run in no-huge environment.
Plan is to enable the testing for whatever works today and work on fixing the remaining test cases. Is this ok?
Sounds good then.
Quoted 1 line
<snip>
v4 cover add travis ci support for aarch64
In reply to Ruifeng WangThis patch set is to enable native aarch64 build in Travis CI. It leverages Travis CI multi arch support.
As the first step, compilation jobs are added.
Unit test is not added for now due to service limitation. We are planning to run unit test with no-huge in future. Plan is to enable the testing for whatever works today and work on fixing the remaining test cases.
v4:
Test RUN_TESTS flag instead of arch when setting hugepage.
v3:
Reverse patches order. Not depending on other patches. Restore distribution designation for aarch64 native jobs.
v2:
Removed dist designation from matrix since base dist is changing. Add explanation for library path issue.
Ruifeng Wang (2):
devtools: add path to additional shared object files
ci: add travis ci support for aarch64
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- devtools/test-null.sh | 2 +- 3 files changed, 49 insertions(+), 6 deletions(-)
Signature · 1 line
2.17.1
PATCH v4 1/2 devtools: add path to additional shared object files
Drivers librte_mempool_ring.so and librte_pmd_null.so are loaded by librte_eal.so when running testpmd.
In Ubuntu Xenial, driver path is installed to RPATH on testpmd. This allows librte_eal.so to find drivers by using the RPATH. However, in Ubuntu Bionic, driver path is installed to RUNPATH instead. The RUNPATH on testpmd is not available by librte_eal.so and therefore lead to driver load failure:
EAL: Detected 32 lcore(s)
EAL: Detected 1 NUMA nodes
EAL: librte_mempool_ring.so: cannot open shared object file:
No such file or directory
EAL: FATAL: Cannot init plugins
EAL: Cannot init plugins
Add 'drivers' into LD_LIBRARY_PATH so that testpmd can find and make use of these shared libraries.
--- devtools/test-null.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
devtools/test-null.sh +1 -1
@@ -20,7 +20,7 @@ if [ ! -f "$testpmd" ] ; then fi if ldd $testpmd | grep -q librte_ ; then - export LD_LIBRARY_PATH=$build/lib:$LD_LIBRARY_PATH + export LD_LIBRARY_PATH=$build/drivers:$build/lib:$LD_LIBRARY_PATH libs='-d librte_mempool_ring.so -d librte_pmd_null.so' else libs=
Signature · 1 line
2.17.1
Re: [dpdk-dev] [PATCH v4 1/2] devtools: add path to additional shared object files
Quoted 15 lines · Ruifeng Wang
Drivers librte_mempool_ring.so and librte_pmd_null.so are loaded by librte_eal.so when running testpmd.
In Ubuntu Xenial, driver path is installed to RPATH on testpmd. This allows librte_eal.so to find drivers by using the RPATH. However, in Ubuntu Bionic, driver path is installed to RUNPATH instead. The RUNPATH on testpmd is not available by librte_eal.so and therefore lead to driver load failure:EAL: Detected 32 lcore(s)
EAL: Detected 1 NUMA nodes
EAL: librte_mempool_ring.so: cannot open shared object file:
No such file or directory
EAL: FATAL: Cannot init plugins
EAL: Cannot init plugins
Quoted 6 lines
Add 'drivers' into
LD_LIBRARY_PATHso that testpmd can find and make use of these shared libraries.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
PATCH v4 2/2 ci: add travis ci support for aarch64
In reply to Ruifeng WangAdd Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.
--- .ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 48 insertions(+), 5 deletions(-)
.ci/linux-setup.sh +7 -4
@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't run without it sudo python3 -m pip install --upgrade meson -# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# skip hugepage settings if tests will not run +if [ "$RUN_TESTS" = "1" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi
.travis.yml +41 -1
47 lines not on this page · raw message
Signature · 1 line
2.17.1
Re: [dpdk-dev] [PATCH v4 2/2] ci: add travis ci support for aarch64
Quoted 7 lines · Ruifeng Wang
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.
Quoted 7 lines
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
I think the above text should probably include 'native' since there are already aarch64 builds that go (but they are cross compiled). I also am glad that you didn't remove them.
Re: [dpdk-dev] [PATCH v4 2/2] ci: add travis ci support for aarch64
Quoted 24 lines
-----Original Message-----
From: Aaron Conole <[email protected]>
Sent: Friday, January 10, 2020 23:13
To: Ruifeng Wang <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Gavin Hu <[email protected]>; Honnappa Nagarahalli <[email protected]>; nd <[email protected]>
Subject: Re: [PATCH v4 2/2] ci: add travis ci support for aarch64Quoted 11 lines · Ruifeng Wang
Add Travis compilation jobs for aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.
Quoted 8 lines
Quoted 3 lines
Signed-off-by Ruifeng Wang <[email protected]>Reviewed-by Gavin Hu <[email protected]>---
I think the above text should probably include 'native' since there are already aarch64 builds that go (but they are cross compiled). I also am glad that you didn't remove them.
Agree.
I will submit new version with commit message update, and take your Ack. Thank you.
Quoted 1 line
Acked-by Aaron Conole <[email protected]>
v5 cover add travis ci support for native aarch64
In reply to Ruifeng WangThis patch set is to enable native aarch64 build in Travis CI. It leverages Travis CI multi arch support.
As the first step, compilation jobs are added.
Unit test is not added for now due to service limitation. We are planning to run unit test with no-huge in future. Plan is to enable the testing for whatever works today and work on fixing the remaining test cases.
v5:
Update commit message for 'native' build.
Taking Ack by Aaron from v4 with suggested commit message change.
v4:
Test RUN_TESTS flag instead of arch when setting hugepage.
v3:
Reverse patches order. Not depending on other patches. Restore distribution designation for aarch64 native jobs.
v2:
Removed dist designation from matrix since base dist is changing. Add explanation for library path issue.
Ruifeng Wang (2):
devtools: add path to additional shared object files
ci: add travis ci support for native aarch64
.ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- devtools/test-null.sh | 2 +- 3 files changed, 49 insertions(+), 6 deletions(-)
Signature · 1 line
2.17.1
PATCH v5 1/2 devtools: add path to additional shared object files
Drivers librte_mempool_ring.so and librte_pmd_null.so are loaded by librte_eal.so when running testpmd.
In Ubuntu Xenial, driver path is installed to RPATH on testpmd. This allows librte_eal.so to find drivers by using the RPATH. However, in Ubuntu Bionic, driver path is installed to RUNPATH instead. The RUNPATH on testpmd is not available by librte_eal.so and therefore lead to driver load failure:
EAL: Detected 32 lcore(s)
EAL: Detected 1 NUMA nodes
EAL: librte_mempool_ring.so: cannot open shared object file:
No such file or directory
EAL: FATAL: Cannot init plugins
EAL: Cannot init plugins
Add 'drivers' into LD_LIBRARY_PATH so that testpmd can find and make use of these shared libraries.
--- devtools/test-null.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
devtools/test-null.sh +1 -1
@@ -20,7 +20,7 @@ if [ ! -f "$testpmd" ] ; then fi if ldd $testpmd | grep -q librte_ ; then - export LD_LIBRARY_PATH=$build/lib:$LD_LIBRARY_PATH + export LD_LIBRARY_PATH=$build/drivers:$build/lib:$LD_LIBRARY_PATH libs='-d librte_mempool_ring.so -d librte_pmd_null.so' else libs=
Signature · 1 line
2.17.1
PATCH v5 2/2 ci: add travis ci support for native aarch64
In reply to Ruifeng WangAdd Travis compilation jobs for native aarch64. gcc/clang compilations for static/shared libraries are added.
Some limitations for current aarch64 Travis support:
1. Container is used. Huge page is not available due to security reason.
2. Missing kernel header package in Xenial distribution.
Solutions to address the limitations:
1. Not to add unit test for now. And run tests with no-huge in future.
2. Use Bionic distribution for all aarch64 jobs.
--- .ci/linux-setup.sh | 11 +++++++---- .travis.yml | 42 +++++++++++++++++++++++++++++++++++++++++- 2 files changed, 48 insertions(+), 5 deletions(-)
.ci/linux-setup.sh +7 -4
@@ -3,7 +3,10 @@ # need to install as 'root' since some of the unit tests won't run without it sudo python3 -m pip install --upgrade meson -# setup hugepages -cat /proc/meminfo -sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' -cat /proc/meminfo +# skip hugepage settings if tests will not run +if [ "$RUN_TESTS" = "1" ]; then + # setup hugepages + cat /proc/meminfo + sudo sh -c 'echo 1024 > /proc/sys/vm/nr_hugepages' + cat /proc/meminfo +fi
.travis.yml +41 -1
47 lines not on this page · raw message
Signature · 1 line
2.17.1
Re: [dpdk-dev] [PATCH v5 0/2] add travis ci support for native aarch64
In reply to Ruifeng WangQuoted 9 lines · Ruifeng Wang
This patch set is to enable native aarch64 build in Travis CI. It leverages Travis CI multi arch support.
As the first step, compilation jobs are added.
Unit test is not added for now due to service limitation. We are planning to run unit test with no-huge in future. Plan is to enable the testing for whatever works today and work on fixing the remaining test cases.
Series applied, thanks.
--
David Marchand