qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 3/3] ci: add -j to all "make" jobs


From: Paolo Bonzini
Subject: [PATCH 3/3] ci: add -j to all "make" jobs
Date: Tue, 18 May 2021 10:41:39 +0200

Run the tests in parallel, as that can greatly speed up the jobs.
"meson test" is able to report failures to the terminal in a way
that is readable enough even when tests are run in parallel.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 .cirrus.yml    | 18 +++++++++---------
 .gitlab-ci.yml |  8 ++++----
 .travis.yml    | 10 +++++-----
 3 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/.cirrus.yml b/.cirrus.yml
index 340fd395c0..fcf0f34a4c 100644
--- a/.cirrus.yml
+++ b/.cirrus.yml
@@ -32,11 +32,11 @@ macos_task:
                    --extra-cflags='-Wno-error=deprecated-declarations'
                    || { cat config.log meson-logs/meson-log.txt; exit 1; }
     - gmake -j$(sysctl -n hw.ncpu)
-    - gmake check-unit V=1
+    - gmake -j$(sysctl -n hw.ncpu) check-unit V=1
     - gmake check-block V=1
-    - gmake check-qapi-schema V=1
-    - gmake check-softfloat V=1
-    - gmake check-qtest-x86_64 V=1
+    - gmake -j$(sysctl -n hw.ncpu) check-qapi-schema V=1
+    - gmake -j$(sysctl -n hw.ncpu) check-softfloat V=1
+    - gmake -j$(sysctl -n hw.ncpu) check-qtest-x86_64 V=1
     - gmake install DESTDIR=$PWD/destdir
 
 macos_xcode_task:
@@ -51,11 +51,11 @@ macos_xcode_task:
     - ../configure --extra-cflags='-Wno-error=deprecated-declarations' 
--enable-modules --disable-strip
                    --enable-werror --cc=clang || { cat config.log 
meson-logs/meson-log.txt; exit 1; }
     - gmake -j$(sysctl -n hw.ncpu)
-    - gmake check-unit V=1
+    - gmake -j$(sysctl -n hw.ncpu) check-unit V=1
     - gmake check-block V=1
-    - gmake check-qapi-schema V=1
-    - gmake check-softfloat V=1
-    - gmake check-qtest-x86_64 V=1
+    - gmake -j$(sysctl -n hw.ncpu) check-qapi-schema V=1
+    - gmake -j$(sysctl -n hw.ncpu) check-softfloat V=1
+    - gmake -j$(sysctl -n hw.ncpu) check-qtest-x86_64 V=1
     - gmake install DESTDIR=$PWD/destdir
 
 windows_msys2_task:
@@ -163,5 +163,5 @@ windows_msys2_task:
     - C:\tools\msys64\usr\bin\bash.exe -lc "cd build && make -j8"
     - exit $LastExitCode
   test_script:
-    - C:\tools\msys64\usr\bin\bash.exe -lc "cd build && make V=1 check"
+    - C:\tools\msys64\usr\bin\bash.exe -lc "cd build && make -j4 V=1 check"
     - exit $LastExitCode
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 3f0d86cf0a..4c0cc47c25 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -50,7 +50,7 @@ include:
     - cd build
     - find . -type f -exec touch {} +
     # Avoid recompiling by hiding ninja with NINJA=":"
-    - make NINJA=":" $MAKE_CHECK_ARGS
+    - make -j"$JOBS" NINJA=":" $MAKE_CHECK_ARGS
 
 .meson_test_template: &meson_test_definition
   artifacts:
@@ -402,8 +402,8 @@ build-tcg-disabled:
     - ../configure --disable-tcg --audio-drv-list="" --with-coroutine=ucontext
       || { cat config.log meson-logs/meson-log.txt && exit 1; }
     - make -j"$JOBS"
-    - make check-unit
-    - make check-qapi-schema
+    - make check-unit -j"$JOBS"
+    - make check-qapi-schema -j"$JOBS"
     - cd tests/qemu-iotests/
     - ./check -raw 001 002 003 004 005 008 009 010 011 012 021 025 032 033 048
             052 063 077 086 101 104 106 113 148 150 151 152 157 159 160 163
@@ -689,7 +689,7 @@ build-oss-fuzz:
         "${fuzzer}" -runs=1 -seed=1 || exit 1 ;
       done
     # Unrelated to fuzzer: run some tests with -fsanitize=address
-    - cd build-oss-fuzz && make check-qtest-i386 check-unit MTESTARGS="-t 2"
+    - cd build-oss-fuzz && make check-qtest-i386 check-unit -j"$JOBS" 
MTESTARGS="-t 2"
 
 build-tci:
   extends: .native_build_job_template
diff --git a/.travis.yml b/.travis.yml
index 4609240b5a..42e8f0b348 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -73,7 +73,7 @@ env:
     - BUILD_DIR="build"
     - BASE_CONFIG="--disable-docs --disable-tools"
     - TEST_BUILD_CMD=""
-    - TEST_CMD="make check V=1"
+    - TEST_CMD="make check -j${JOBS} V=1"
     # This is broadly a list of "mainline" softmmu targets which have support 
across the major distros
     - 
MAIN_SOFTMMU_TARGETS="aarch64-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
     - CCACHE_SLOPPINESS="include_file_ctime,include_file_mtime"
@@ -151,7 +151,7 @@ jobs:
           # Tests dependencies
           - genisoimage
       env:
-        - TEST_CMD="make check check-tcg V=1"
+        - TEST_CMD="make check check-tcg -j${JOBS} V=1"
         - CONFIG="--disable-containers --target-list=${MAIN_SOFTMMU_TARGETS} 
--cxx=/bin/false"
         - UNRELIABLE=true
 
@@ -185,7 +185,7 @@ jobs:
           # Tests dependencies
           - genisoimage
       env:
-        - TEST_CMD="make check check-tcg V=1"
+        - TEST_CMD="make check check-tcg -j${JOBS} V=1"
         - CONFIG="--disable-containers 
--target-list=ppc64-softmmu,ppc64le-linux-user"
 
     - name: "[s390x] GCC check-tcg"
@@ -218,7 +218,7 @@ jobs:
           # Tests dependencies
           - genisoimage
       env:
-        - TEST_CMD="make check check-tcg V=1"
+        - TEST_CMD="make check check-tcg -j${JOBS} V=1"
         - CONFIG="--disable-containers 
--target-list=${MAIN_SOFTMMU_TARGETS},s390x-linux-user"
         - UNRELIABLE=true
       script:
@@ -301,7 +301,7 @@ jobs:
           - libvte-2.91-dev
           - ninja-build
       env:
-        - TEST_CMD="make check-unit"
+        - TEST_CMD="make check-unit -j${JOBS}"
         - CONFIG="--disable-containers --disable-tcg --enable-kvm
                   --disable-tools --host-cc=clang --cxx=clang++"
         - UNRELIABLE=true
-- 
2.31.1




reply via email to

[Prev in Thread] Current Thread [Next in Thread]