aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2020-11-23 11:27:44 +0000
committerPeter Maydell <peter.maydell@linaro.org>2020-11-23 11:27:44 +0000
commit6ab64cc2a51dd30f4b19eba707f5bfcba0524a0a (patch)
treea585109df5d6a7331464e2158fb247e67c4d6936
parent8cc30eb1400fc01f2b139cdd3dc524f8b84dbe07 (diff)
parent534f80e1dffbf520bed9bf5fd5ae98de6662e126 (diff)
downloadqemu-6ab64cc2a51dd30f4b19eba707f5bfcba0524a0a.zip
qemu-6ab64cc2a51dd30f4b19eba707f5bfcba0524a0a.tar.gz
qemu-6ab64cc2a51dd30f4b19eba707f5bfcba0524a0a.tar.bz2
Merge remote-tracking branch 'remotes/stsquad/tags/pull-for-5.2-rc3-231120-1' into staging
Misc CI fixes: - more helpful logic for git-pipeline-status - fix tempdir leak in avocado - move remaining x86 check-tcg to gitlab - add tracing headers to ubuntu2004 docker - move tracing backend tests to gitlab - bump up timeouts on cirrus MacOS # gpg: Signature made Mon 23 Nov 2020 09:58:18 GMT # gpg: using RSA key 6685AE99E75167BCAFC8DF35FBD0DB095A9E2A44 # gpg: Good signature from "Alex Bennée (Master Work Key) <alex.bennee@linaro.org>" [full] # Primary key fingerprint: 6685 AE99 E751 67BC AFC8 DF35 FBD0 DB09 5A9E 2A44 * remotes/stsquad/tags/pull-for-5.2-rc3-231120-1: .cirrus.yml: bump timeout period for MacOS builds gitlab-ci: Move trace backend tests across to gitlab tests/docker: Install liblttng-ust-dev package in Ubuntu 20.04 image gitlab: move remaining x86 check-tcg targets to gitlab tests/avocado: clean-up socket directory after run tests: add prefixes to the bare mkdtemp calls scripts/ci: clean up default args logic a little Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-rw-r--r--.cirrus.yml2
-rw-r--r--.gitlab-ci.yml35
-rw-r--r--.travis.yml45
-rw-r--r--python/qemu/machine.py3
-rwxr-xr-xscripts/ci/gitlab-pipeline-status24
-rw-r--r--tests/acceptance/avocado_qemu/__init__.py4
-rw-r--r--tests/docker/dockerfiles/ubuntu2004.docker1
7 files changed, 56 insertions, 58 deletions
diff --git a/.cirrus.yml b/.cirrus.yml
index f0209b7..08db7c4 100644
--- a/.cirrus.yml
+++ b/.cirrus.yml
@@ -18,6 +18,7 @@ freebsd_12_task:
- gmake -j$(sysctl -n hw.ncpu) check V=1
macos_task:
+ timeout_in: 90m
osx_instance:
image: catalina-base
install_script:
@@ -32,6 +33,7 @@ macos_task:
- gmake check V=1
macos_xcode_task:
+ timeout_in: 90m
osx_instance:
# this is an alias for the latest Xcode
image: catalina-xcode
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 9a8b375..d0173e8 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -247,6 +247,15 @@ build-user:
CONFIGURE_ARGS: --disable-tools --disable-system
MAKE_CHECK_ARGS: check-tcg
+# Only build the softmmu targets we have check-tcg tests for
+build-some-softmmu:
+ <<: *native_build_job_definition
+ variables:
+ IMAGE: debian-all-test-cross
+ CONFIGURE_ARGS: --disable-tools --enable-debug-tcg
+ TARGETS: xtensa-softmmu arm-softmmu aarch64-softmmu alpha-softmmu
+ MAKE_CHECK_ARGS: check-tcg
+
# Run check-tcg against linux-user (with plugins)
# we skip sparc64-linux-user until it has been fixed somewhat
# we skip cris-linux-user as it doesn't use the common run loop
@@ -258,6 +267,14 @@ build-user-plugins:
MAKE_CHECK_ARGS: check-tcg
timeout: 1h 30m
+build-some-softmmu-plugins:
+ <<: *native_build_job_definition
+ variables:
+ IMAGE: debian-all-test-cross
+ CONFIGURE_ARGS: --disable-tools --disable-user --enable-plugins --enable-debug-tcg
+ TARGETS: xtensa-softmmu arm-softmmu aarch64-softmmu alpha-softmmu
+ MAKE_CHECK_ARGS: check-tcg
+
build-clang:
<<: *native_build_job_definition
variables:
@@ -398,6 +415,24 @@ check-crypto-only-gnutls:
IMAGE: centos7
MAKE_CHECK_ARGS: check
+# We don't need to exercise every backend with every front-end
+build-trace-multi-user:
+ <<: *native_build_job_definition
+ variables:
+ IMAGE: ubuntu2004
+ CONFIGURE_ARGS: --enable-trace-backends=log,simple,syslog --disable-system
+
+build-trace-ftrace-system:
+ <<: *native_build_job_definition
+ variables:
+ IMAGE: ubuntu2004
+ CONFIGURE_ARGS: --enable-trace-backends=ftrace --target-list=x86_64-softmmu
+
+build-trace-ust-system:
+ <<: *native_build_job_definition
+ variables:
+ IMAGE: ubuntu2004
+ CONFIGURE_ARGS: --enable-trace-backends=ust --target-list=x86_64-softmmu
check-patch:
stage: build
diff --git a/.travis.yml b/.travis.yml
index a3d7817..1f80bdb 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -232,25 +232,6 @@ jobs:
- TEST_CMD=""
- # We don't need to exercise every backend with every front-end
- - name: "GCC trace log,simple,syslog (user)"
- env:
- - CONFIG="--enable-trace-backends=log,simple,syslog --disable-system"
- - TEST_CMD=""
-
-
- - name: "GCC trace ftrace (x86_64-softmmu)"
- env:
- - CONFIG="--enable-trace-backends=ftrace --target-list=x86_64-softmmu"
- - TEST_CMD=""
-
-
- - name: "GCC trace ust (x86_64-softmmu)"
- env:
- - CONFIG="--enable-trace-backends=ust --target-list=x86_64-softmmu"
- - TEST_CMD=""
-
-
# Using newer GCC with sanitizers
- name: "GCC9 with sanitizers (softmmu)"
dist: bionic
@@ -301,32 +282,6 @@ jobs:
- ${SRC_DIR}/configure ${CONFIG} --extra-cflags="-g3 -O0 -fsanitize=thread" || { cat config.log meson-logs/meson-log.txt && exit 1; }
- # Run check-tcg against linux-user
- - name: "GCC check-tcg (user)"
- env:
- - CONFIG="--disable-system --enable-debug-tcg"
- - TEST_BUILD_CMD="make build-tcg"
- - TEST_CMD="make check-tcg"
- - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-debug-tcg"
-
-
- # Run check-tcg against softmmu targets
- - name: "GCC check-tcg (some-softmmu)"
- env:
- - CONFIG="--enable-debug-tcg --target-list=xtensa-softmmu,arm-softmmu,aarch64-softmmu,alpha-softmmu"
- - TEST_BUILD_CMD="make build-tcg"
- - TEST_CMD="make check-tcg"
- - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-debug-tcg"
-
-
- # Run check-tcg against softmmu targets (with plugins)
- - name: "GCC plugins check-tcg (some-softmmu)"
- env:
- - CONFIG="--enable-plugins --enable-debug-tcg --target-list=xtensa-softmmu,arm-softmmu,aarch64-softmmu,alpha-softmmu"
- - TEST_BUILD_CMD="make build-tcg"
- - TEST_CMD="make check-tcg"
- - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-debug-tcg"
-
- name: "[aarch64] GCC check-tcg"
arch: arm64
dist: focal
diff --git a/python/qemu/machine.py b/python/qemu/machine.py
index 6420f01..64d966a 100644
--- a/python/qemu/machine.py
+++ b/python/qemu/machine.py
@@ -303,7 +303,8 @@ class QEMUMachine:
return args
def _pre_launch(self) -> None:
- self._temp_dir = tempfile.mkdtemp(dir=self._test_dir)
+ self._temp_dir = tempfile.mkdtemp(prefix="qemu-machine-",
+ dir=self._test_dir)
self._qemu_log_path = os.path.join(self._temp_dir, self._name + ".log")
self._qemu_log_file = open(self._qemu_log_path, 'wb')
diff --git a/scripts/ci/gitlab-pipeline-status b/scripts/ci/gitlab-pipeline-status
index bac8233..78e72f6 100755
--- a/scripts/ci/gitlab-pipeline-status
+++ b/scripts/ci/gitlab-pipeline-status
@@ -31,7 +31,7 @@ class NoPipelineFound(Exception):
"""Communication is successfull but pipeline is not found."""
-def get_local_branch_commit(branch='staging'):
+def get_local_branch_commit(branch):
"""
Returns the commit sha1 for the *local* branch named "staging"
"""
@@ -126,18 +126,16 @@ def create_parser():
help=('The GitLab project ID. Defaults to the project '
'for https://gitlab.com/qemu-project/qemu, that '
'is, "%(default)s"'))
- try:
- default_commit = get_local_branch_commit()
- commit_required = False
- except ValueError:
- default_commit = ''
- commit_required = True
- parser.add_argument('-c', '--commit', required=commit_required,
- default=default_commit,
+ parser.add_argument('-b', '--branch', type=str, default="staging",
+ help=('Specify the branch to check. '
+ 'Use HEAD for your current branch. '
+ 'Otherwise looks at "%(default)s"'))
+ parser.add_argument('-c', '--commit',
+ default=None,
help=('Look for a pipeline associated with the given '
'commit. If one is not explicitly given, the '
- 'commit associated with the local branch named '
- '"staging" is used. Default: %(default)s'))
+ 'commit associated with the default branch '
+ 'is used.'))
parser.add_argument('--verbose', action='store_true', default=False,
help=('A minimal verbosity level that prints the '
'overall result of the check/wait'))
@@ -149,6 +147,10 @@ def main():
"""
parser = create_parser()
args = parser.parse_args()
+
+ if not args.commit:
+ args.commit = get_local_branch_commit(args.branch)
+
success = False
try:
if args.wait:
diff --git a/tests/acceptance/avocado_qemu/__init__.py b/tests/acceptance/avocado_qemu/__init__.py
index 4cda037..bf54e41 100644
--- a/tests/acceptance/avocado_qemu/__init__.py
+++ b/tests/acceptance/avocado_qemu/__init__.py
@@ -171,7 +171,8 @@ class Test(avocado.Test):
self.cancel("No QEMU binary defined or found in the build tree")
def _new_vm(self, *args):
- vm = QEMUMachine(self.qemu_bin, sock_dir=tempfile.mkdtemp())
+ self._sd = tempfile.TemporaryDirectory(prefix="avo_qemu_sock_")
+ vm = QEMUMachine(self.qemu_bin, sock_dir=self._sd.name)
if args:
vm.add_args(*args)
return vm
@@ -192,6 +193,7 @@ class Test(avocado.Test):
def tearDown(self):
for vm in self._vms.values():
vm.shutdown()
+ self._sd = None
def fetch_asset(self, name,
asset_hash=None, algorithm=None,
diff --git a/tests/docker/dockerfiles/ubuntu2004.docker b/tests/docker/dockerfiles/ubuntu2004.docker
index 355bbb3..ae889d8 100644
--- a/tests/docker/dockerfiles/ubuntu2004.docker
+++ b/tests/docker/dockerfiles/ubuntu2004.docker
@@ -23,6 +23,7 @@ ENV PACKAGES flex bison \
libiscsi-dev \
libjemalloc-dev \
libjpeg-turbo8-dev \
+ liblttng-ust-dev \
liblzo2-dev \
libncurses5-dev \
libncursesw5-dev \