Skip to contentSkip to conversation

Travis updates

PATCH Superseded Alex Bennée 4 participants 11 messages Jan 28, 2016 – Feb 2, 2016

v3 of 4 Superseded Latest is v4 →

lore
Share & tools
lore
#0 lore raw

v3 cover Travis updates

Hi,

The first patch has been reviewed and signed off. Long term I think it is worth applying but it look like the performance increase it negligible compared to the old style VM builds at the moment. I suspect this may be because the new infrastructure is under more load as more projects have migrated.

The remaining two patches widen the testing of the code.

The first making "make check" standard for all builds unless explicitly disabled. This reverts an original patch that moved it all to one build while we were experiencing instability in "make check".

The second add some supplemental builds to the matrix for additional co-routine builds. I've disabled "make check" for the gthread option as it is current broken.

Is everyone happy for these to go in via the trivial tree?

Alex Bennée (3):
.travis.yml: migrate to container builds .travis.yml: run make check for all matrix targets .travis.yml: enable each of the co-routine backends

 .travis.yml | 72 +++++++++++++++++++++++++++++++++++++++++++++----------------
 1 file changed, 53 insertions(+), 19 deletions(-)
Signature · 1 line
2.7.0
#1 lore raw

PATCH v3 1/3 .travis.yml: migrate to container builds

This moves the Travis tests from the legacy VM infrastructure (which only seems to run 5-6 jobs at once) to the new container based approach.

The principle difference is there is no sudo in the containers so all packages are installed using the apt add-on. This means one of the build combinations can be dropped as it was only for checking the build with additional packages.

--
v2
- re-enabled the user-space-tracing build
- disable optional extras (instead of having optional build)
- remove stray linux-user target from make check target
v3
- Add Dave's t-b and rb tags

---
 .travis.yml | 44 ++++++++++++++++++++++++++++++++------------
 1 file changed, 32 insertions(+), 12 deletions(-)
.travis.yml +32 -12
index 6ca0260..4a0c23a 100644
@@ -1,9 +1,37 @@
+sudo: false
 language: c
 python:
   - "2.4"
 compiler:
   - gcc
   - clang
+addons:
+  apt:
+    packages:
+      - libaio-dev
+      - libattr1-dev
+      - libbrlapi-dev
+      - libcap-ng-dev
+      - libgnutls-dev
+      - libgtk-3-dev
+      - libiscsi-dev
+      - liblttng-ust-dev
+      - libncurses5-dev
+      - libnss3-dev
+      - libpixman-1-dev
+      - libpng12-dev
+      - librados-dev
+      - libsdl1.2-dev
+      - libseccomp-dev
+      - libspice-protocol-dev
+      - libspice-server-dev
+      - libssh2-1-dev
+      - liburcu-dev
+      - libusb-1.0-0-dev
+      - libvte-2.90-dev
+      - sparse
+      - uuid-dev
+
 notifications:
   irc:
     channels:
@@ -14,11 +42,6 @@ env:
   global:
     - TEST_CMD=""
     - EXTRA_CONFIG=""
-    # Development packages, EXTRA_PKGS saved for additional builds
-    - CORE_PKGS="libusb-1.0-0-dev libiscsi-dev librados-dev libncurses5-dev"
-    - NET_PKGS="libseccomp-dev libgnutls-dev libssh2-1-dev  libspice-server-dev libspice-protocol-dev libnss3-dev"
-    - GUI_PKGS="libgtk-3-dev libvte-2.90-dev libsdl1.2-dev libpng12-dev libpixman-1-dev"
-    - EXTRA_PKGS=""
   matrix:
     # Group major targets together with their linux-user counterparts
     - TARGETS=alpha-softmmu,alpha-linux-user
@@ -43,8 +66,6 @@ git:
 before_install:
   - wget -O - http://people.linaro.org/~alex.bennee/qemu-submodule-git-seed.tar.xz | tar -xvJ
   - git submodule update --init --recursive
-  - sudo apt-get update -qq
-  - sudo apt-get install -qq ${CORE_PKGS} ${NET_PKGS} ${GUI_PKGS} ${EXTRA_PKGS}
 before_script:
   - ./configure --target-list=${TARGETS} --enable-debug-tcg ${EXTRA_CONFIG}
 script:
@@ -54,7 +75,7 @@ matrix:
   include:
     # Make check target (we only do this once)
     - env:
-        - TARGETS=alpha-softmmu,arm-softmmu,aarch64-softmmu,cris-softmmu,i386-softmmu,x86_64-softmmu,m68k-softmmu,microblaze-softmmu,microblazeel-softmmu,mips-softmmu,mips64-softmmu,mips64el-softmmu,mipsel-softmmu,or32-softmmu,ppc-softmmu,ppc64-softmmu,ppcemb-softmmu,s390x-softmmu,sh4-softmmu,sh4eb-softmmu,sparc-softmmu,sparc64-softmmu,unicore32-softmmu,unicore32-linux-user,lm32-softmmu,moxie-softmmu,tricore-softmmu,xtensa-softmmu,xtensaeb-softmmu
+        - TARGETS=alpha-softmmu,arm-softmmu,aarch64-softmmu,cris-softmmu,i386-softmmu,x86_64-softmmu,m68k-softmmu,microblaze-softmmu,microblazeel-softmmu,mips-softmmu,mips64-softmmu,mips64el-softmmu,mipsel-softmmu,or32-softmmu,ppc-softmmu,ppc64-softmmu,ppcemb-softmmu,s390x-softmmu,sh4-softmmu,sh4eb-softmmu,sparc-softmmu,sparc64-softmmu,unicore32-softmmu,lm32-softmmu,moxie-softmmu,tricore-softmmu,xtensa-softmmu,xtensaeb-softmmu
           TEST_CMD="make check"
       compiler: gcc
     # Debug related options
@@ -64,16 +85,16 @@ matrix:
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-debug --enable-tcg-interpreter"
       compiler: gcc
-    # All the extra -dev packages
+    # Disable a few of the optional features
     - env: TARGETS=i386-softmmu,x86_64-softmmu
-           EXTRA_PKGS="libaio-dev libcap-ng-dev libattr1-dev libbrlapi-dev uuid-dev libusb-1.0.0-dev"
+           EXTRA_CONFIG="--disable-linux-aio --disable-cap-ng --disable-attr --disable-brlapi --disable-uuid --disable-libusb"
       compiler: gcc
     # Currently configure doesn't force --disable-pie
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-gprof --enable-gcov --disable-pie"
       compiler: gcc
+    # Sparse
     - env: TARGETS=i386-softmmu,x86_64-softmmu
-           EXTRA_PKGS="sparse"
            EXTRA_CONFIG="--enable-sparse"
       compiler: gcc
     # All the trace backends (apart from dtrace)
@@ -87,7 +108,6 @@ matrix:
            EXTRA_CONFIG="--enable-trace-backends=ftrace"
       compiler: gcc
     - env: TARGETS=i386-softmmu,x86_64-softmmu
-          EXTRA_PKGS="liblttng-ust-dev liburcu-dev"
           EXTRA_CONFIG="--enable-trace-backends=ust"
       compiler: gcc
     - env: TARGETS=i386-softmmu,x86_64-softmmu
Signature · 1 line
2.7.0
#2 lore raw

PATCH v3 2/3 .travis.yml: run make check for all matrix targets

In reply to Alex Bennée

We only ran make check once before it used to be an unreliable target. It was only a stop gap measure and we should be able to revert it now. This also stops us needing a large all-MMU build.

We disable "make check" for a couple of the extra config targets which are currently broken.

---
 .travis.yml | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)
.travis.yml +8 -7
index 4a0c23a..16be23f 100644
@@ -40,7 +40,7 @@ notifications:
     on_failure: always
 env:
   global:
-    - TEST_CMD=""
+    - TEST_CMD="make check"
     - EXTRA_CONFIG=""
   matrix:
     # Group major targets together with their linux-user counterparts
@@ -73,17 +73,14 @@ script:
 matrix:
   # We manually include a number of additional build for non-standard bits
   include:
-    # Make check target (we only do this once)
-    - env:
-        - TARGETS=alpha-softmmu,arm-softmmu,aarch64-softmmu,cris-softmmu,i386-softmmu,x86_64-softmmu,m68k-softmmu,microblaze-softmmu,microblazeel-softmmu,mips-softmmu,mips64-softmmu,mips64el-softmmu,mipsel-softmmu,or32-softmmu,ppc-softmmu,ppc64-softmmu,ppcemb-softmmu,s390x-softmmu,sh4-softmmu,sh4eb-softmmu,sparc-softmmu,sparc64-softmmu,unicore32-softmmu,lm32-softmmu,moxie-softmmu,tricore-softmmu,xtensa-softmmu,xtensaeb-softmmu
-          TEST_CMD="make check"
-      compiler: gcc
     # Debug related options
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-debug"
       compiler: gcc
+    # We currently disable "make check"
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-debug --enable-tcg-interpreter"
+           TEST_CMD=""
       compiler: gcc
     # Disable a few of the optional features
     - env: TARGETS=i386-softmmu,x86_64-softmmu
@@ -104,11 +101,15 @@ matrix:
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-trace-backends=simple"
       compiler: gcc
+    # We currently disable "make check"
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-trace-backends=ftrace"
+           TEST_CMD=""
       compiler: gcc
+    # We currently disable "make check"
     - env: TARGETS=i386-softmmu,x86_64-softmmu
-          EXTRA_CONFIG="--enable-trace-backends=ust"
+           EXTRA_CONFIG="--enable-trace-backends=ust"
+           TEST_CMD=""
       compiler: gcc
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-modules"
Signature · 1 line
2.7.0
#3 lore raw

Re: [Qemu-devel] [PATCH v3 2/3] .travis.yml: run make check for all matrix targets

Quoted 8 lines · Alex Bennée

We only ran make check once before it used to be an unreliable target. It was only a stop gap measure and we should be able to revert it now. This also stops us needing a large all-MMU build.

We disable "make check" for a couple of the extra config targets which are currently broken.

So, in general I like the idea of running make check more widely.

However.. I was wondering - what's the rationale for having separate matrix builds for each target (or small group) rather than just doing one build with all the targets?

I can't see any obvious benefit to splitting the build that way, but it does increase the total build time significantly - and will do so rather more so with make check added.

Quoted 54 lines
---
 .travis.yml | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)
.travis.yml +8 -7
index 4a0c23a..16be23f 100644
@@ -40,7 +40,7 @@ notifications:
     on_failure: always
 env:
   global:
-    - TEST_CMD=""
+    - TEST_CMD="make check"
     - EXTRA_CONFIG=""
   matrix:
     # Group major targets together with their linux-user counterparts
@@ -73,17 +73,14 @@ script:
 matrix:
   # We manually include a number of additional build for non-standard bits
   include:
-    # Make check target (we only do this once)
-    - env:
-        - TARGETS=alpha-softmmu,arm-softmmu,aarch64-softmmu,cris-softmmu,i386-softmmu,x86_64-softmmu,m68k-softmmu,microblaze-softmmu,microblazeel-softmmu,mips-softmmu,mips64-softmmu,mips64el-softmmu,mipsel-softmmu,or32-softmmu,ppc-softmmu,ppc64-softmmu,ppcemb-softmmu,s390x-softmmu,sh4-softmmu,sh4eb-softmmu,sparc-softmmu,sparc64-softmmu,unicore32-softmmu,lm32-softmmu,moxie-softmmu,tricore-softmmu,xtensa-softmmu,xtensaeb-softmmu
-          TEST_CMD="make check"
-      compiler: gcc
     # Debug related options
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-debug"
       compiler: gcc
+    # We currently disable "make check"
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-debug --enable-tcg-interpreter"
+           TEST_CMD=""
       compiler: gcc
     # Disable a few of the optional features
     - env: TARGETS=i386-softmmu,x86_64-softmmu
@@ -104,11 +101,15 @@ matrix:
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-trace-backends=simple"
       compiler: gcc
+    # We currently disable "make check"
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-trace-backends=ftrace"
+           TEST_CMD=""
       compiler: gcc
+    # We currently disable "make check"
     - env: TARGETS=i386-softmmu,x86_64-softmmu
-          EXTRA_CONFIG="--enable-trace-backends=ust"
+           EXTRA_CONFIG="--enable-trace-backends=ust"
+           TEST_CMD=""
       compiler: gcc
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-modules"
Signature · 4 lines
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson
#4 lore raw

Re: [Qemu-devel] [PATCH v3 2/3] .travis.yml: run make check for all matrix targets

Quoted 8 lines · David Gibson
Quoted 7 lines · Alex Bennée

We only ran make check once before it used to be an unreliable target. It was only a stop gap measure and we should be able to revert it now. This also stops us needing a large all-MMU build.

We disable "make check" for a couple of the extra config targets which are currently broken.

Quoted 7 lines
Quoted 1 line

So, in general I like the idea of running make check more widely.

However.. I was wondering - what's the rationale for having separate matrix builds for each target (or small group) rather than just doing one build with all the targets?

Each individual part of the matrix can be run in parallel with the others so it makes sense to keep the build component small (as each softmmu target rebuilds a significant chunk of the build).

Having said that there is a fair amount of repetition as we are repeating all the generic qtests each time just so we can run the extra ${TARGET}-qtest binaries.

Travis does has an option for using ccache so it might be worth experimenting with that to see if things are improved.

Quoted 3 lines

I can't see any obvious benefit to splitting the build that way, but it does increase the total build time significantly - and will do so rather more so with make check added.

Elapsed and total are the ones to look at:

https://travis-ci.org/stsquad/qemu/builds/105401126

vs

https://travis-ci.org/qemu/qemu/builds/105711606

However it looks like Travis are having scaling growing pains because there "old style" VM approach is running a lot faster than it used to.

Quoted 47 lines
Quoted 47 lines
---
 .travis.yml | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)
.travis.yml +5 -6
index 4a0c23a..16be23f 100644
@@ -40,7 +40,7 @@ notifications:
     on_failure: always
 env:
   global:
-    - TEST_CMD=""
+    - TEST_CMD="make check"
     - EXTRA_CONFIG=""
   matrix:
     # Group major targets together with their linux-user counterparts
@@ -73,17 +73,14 @@ script:
 matrix:
   # We manually include a number of additional build for non-standard bits
   include:
-    # Make check target (we only do this once)
-    - env:
-        - TARGETS=alpha-softmmu,arm-softmmu,aarch64-softmmu,cris-softmmu,i386-softmmu,x86_64-softmmu,m68k-softmmu,microblaze-softmmu,microblazeel-softmmu,mips-softmmu,mips64-softmmu,mips64el-softmmu,mipsel-softmmu,or32-softmmu,ppc-softmmu,ppc64-softmmu,ppcemb-softmmu,s390x-softmmu,sh4-softmmu,sh4eb-softmmu,sparc-softmmu,sparc64-softmmu,unicore32-softmmu,lm32-softmmu,moxie-softmmu,tricore-softmmu,xtensa-softmmu,xtensaeb-softmmu
-          TEST_CMD="make check"
-      compiler: gcc
     # Debug related options
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-debug"
       compiler: gcc
+    # We currently disable "make check"
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-debug --enable-tcg-interpreter"
+           TEST_CMD=""
       compiler: gcc
     # Disable a few of the optional features
     - env: TARGETS=i386-softmmu,x86_64-softmmu
@@ -104,11 +101,15 @@ matrix:
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-trace-backends=simple"
       compiler: gcc
+    # We currently disable "make check"
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-trace-backends=ftrace"
+           TEST_CMD=""
       compiler: gcc
Quoted 8 lines

.travis.yml matrix: · line 115

Quoted 8 lines
.travis.yml +3 -1
+    # We currently disable "make check"
     - env: TARGETS=i386-softmmu,x86_64-softmmu
-          EXTRA_CONFIG="--enable-trace-backends=ust"
+           EXTRA_CONFIG="--enable-trace-backends=ust"
+           TEST_CMD=""
       compiler: gcc
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-modules"

--
Alex Bennée

#5 lore raw

Re: [Qemu-devel] [PATCH v3 2/3] .travis.yml: run make check for all matrix targets

Quoted 15 lines · Alex Bennée
Quoted 12 lines · David Gibson
Quoted 8 lines · Alex Bennée

We only ran make check once before it used to be an unreliable target. It was only a stop gap measure and we should be able to revert it now. This also stops us needing a large all-MMU build.

We disable "make check" for a couple of the extra config targets which are currently broken.

So, in general I like the idea of running make check more widely.

Quoted 7 lines
Quoted 3 lines

However.. I was wondering - what's the rationale for having separate matrix builds for each target (or small group) rather than just doing one build with all the targets?

Each individual part of the matrix can be run in parallel with the others so it makes sense to keep the build component small (as each softmmu target rebuilds a significant chunk of the build).

It does rebuild a significant chunk, but there's a significant chunk that isn't rebuilt as well. When I tried this I found a recombined build marginally decreases the elapsed time and significantly (maybe 30-40%) reduced the total time. Given the load the travis system is under, it seems to me that we should try to keep our total demand on its resources down when it doens't significantly lower our coverage.

Quoted 3 lines

Having said that there is a fair amount of repetition as we are repeating all the generic qtests each time just so we can run the extra ${TARGET}-qtest binaries.

That too.

Quoted 2 lines

Travis does has an option for using ccache so it might be worth experimenting with that to see if things are improved.

That does sound like something worth looking at.

One thing that does annoy me about travis is that it will do a full rebuild if you have two branches on exactly the same commit, or if you revert a branch to an earlier commit which was built previously.

Quoted 8 lines
Quoted 3 lines

I can't see any obvious benefit to splitting the build that way, but it does increase the total build time significantly - and will do so rather more so with make check added.

Elapsed and total are the ones to look at:

https://travis-ci.org/stsquad/qemu/builds/105401126

Quoted 7 lines

vs

https://travis-ci.org/qemu/qemu/builds/105711606

However it looks like Travis are having scaling growing pains because there "old style" VM approach is running a lot faster than it used to.

Not terribly surprising TBH.

Signature · 4 lines
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson
#6 lore raw

PATCH v3 3/3 .travis.yml: enable each of the co-routine backends

In reply to Alex Bennée

We disable "make check" for the gthread backend as it is broken.

---
 .travis.yml | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)
.travis.yml +14 -1
index 16be23f..021eec7 100644
@@ -94,6 +94,10 @@ matrix:
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-sparse"
       compiler: gcc
+    # Modules
+    - env: TARGETS=i386-softmmu,x86_64-softmmu
+           EXTRA_CONFIG="--enable-modules"
+      compiler: gcc
     # All the trace backends (apart from dtrace)
     - env: TARGETS=i386-softmmu,x86_64-softmmu
            EXTRA_CONFIG="--enable-trace-backends=stderr"
@@ -111,6 +115,15 @@ matrix:
            EXTRA_CONFIG="--enable-trace-backends=ust"
            TEST_CMD=""
       compiler: gcc
+    # All the co-routine backends (apart from windows)
+    # We currently disable "make check"
     - env: TARGETS=i386-softmmu,x86_64-softmmu
-           EXTRA_CONFIG="--enable-modules"
+           EXTRA_CONFIG="--with-coroutine=gthread"
+           TEST_CMD=""
+      compiler: gcc
+    - env: TARGETS=i386-softmmu,x86_64-softmmu
+           EXTRA_CONFIG="--with-coroutine=ucontext"
+      compiler: gcc
+    - env: TARGETS=i386-softmmu,x86_64-softmmu
+           EXTRA_CONFIG="--with-coroutine=sigaltstack"
       compiler: gcc
Signature · 1 line
2.7.0
#7 lore raw
In reply to Alex Bennée
Quoted 7 lines · Alex Bennée

Hi,

The first patch has been reviewed and signed off. Long term I think it is worth applying but it look like the performance increase it negligible compared to the old style VM builds at the moment. I suspect this may be because the new infrastructure is under more load as more projects have migrated.

I'm applying all this to -trivial, but without trying to understand what it is all about, as I don't know travis.

Thanks,

/mjt

#8 lore raw
Quoted 11 lines · Michael Tokarev
Quoted 7 lines · Alex Bennée

Hi,

The first patch has been reviewed and signed off. Long term I think it is worth applying but it look like the performance increase it negligible compared to the old style VM builds at the moment. I suspect this may be because the new infrastructure is under more load as more projects have migrated.

I'm applying all this to -trivial, but without trying to understand what it is all about, as I don't know travis.

Maybe we should hold off for now until the later ones have been reviewed (David has some comments on 2/3). I guess it was really a question of if trivial is the right tree for these patches to go upstream.

Maybe what's really needed is a build and test automation tree (and associated maintainer)? Peter any comments?

Quoted 4 lines

Thanks,

/mjt

--
Alex Bennée

#9 lore raw
Quoted 2 lines · Alex Bennée

Maybe what's really needed is a build and test automation tree (and associated maintainer)? Peter any comments?

If you want to be the submaintainer for that, be my guest :-)

thanks
-- PMM

#10 lore raw
In reply to Alex Bennée
Quoted 10 lines · Alex Bennée
Quoted 9 lines · Michael Tokarev
Quoted 7 lines · Alex Bennée

Hi,

The first patch has been reviewed and signed off. Long term I think it is worth applying but it look like the performance increase it negligible compared to the old style VM builds at the moment. I suspect this may be because the new infrastructure is under more load as more projects have migrated.

Quoted 6 lines
Quoted 2 lines

I'm applying all this to -trivial, but without trying to understand what it is all about, as I don't know travis.

Maybe we should hold off for now until the later ones have been reviewed (David has some comments on 2/3). I guess it was really a question of if trivial is the right tree for these patches to go upstream.

Ok, I removed the series from the -trivial patch queue for now.

Thanks,

/mjt