Commit eb0667fe authored by Peter Maydell's avatar Peter Maydell
Browse files

Merge remote-tracking branch 'remotes/stsquad/tags/pull-testing-next-140119-1' into staging



A bunch of fixes for testing:

  - Various Travis updates
  - "stable" SID snapshot for docker
  - avoid :latest docker tags
  - g_usleep fix for some tests

# gpg: Signature made Mon 14 Jan 2019 14:59:35 GMT
# gpg:                using RSA key FBD0DB095A9E2A44
# gpg: Good signature from "Alex Bennée (Master Work Key) <alex.bennee@linaro.org>"
# Primary key fingerprint: 6685 AE99 E751 67BC AFC8  DF35 FBD0 DB09 5A9E 2A44

* remotes/stsquad/tags/pull-testing-next-140119-1: (21 commits)
  Revert "tests: Disable qht-bench parallel test when using gprof"
  tests: use g_usleep instead of rem = sleep(time)
  tests/docker: remove SID_AGE test hack
  tests/docker: update our Travis image
  travis: bump to Xenial baseline
  docker: Use a stable snapshot for Debian Sid
  travis: remove matrix settings that duplicate global settings
  travis: run tests in verbose mode
  travis: stop using container based envs
  travis: stop redefining the script commands
  travis: use homebrew addon for MacOSX
  travis: don't clone git submodules upfront
  travis: standardize the syntax used for env variables
  travis: define all the build matrix entries in one place
  travis: add whitespace between each major section & matrix entry
  tests: use in-place sed magic for enabling deb-src in travis image
  tests: update Fedora i386 cross image to Fedora 29
  tests: update Fedora dockerfile to use Fedora 29
  tests: remove obsolete 'debian' dockerfile
  tests: run ldconfig after installing extra software
  ...

Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
parents 89bd861c a36270a4
Loading
Loading
Loading
Loading
+116 −56
Original line number Diff line number Diff line
# The current Travis default is a container based 14.04 Trust on EC2
# The current Travis default is a VM based 16.04 Xenial on GCE
# Additional builds with specific requirements for a full VM need to
# be added as additional matrix: entries later on
sudo: false
dist: trusty
dist: xenial
language: c
python:
  - "2.6"
compiler:
  - gcc
cache: ccache


addons:
  apt:
    packages:
@@ -35,10 +34,17 @@ addons:
      - libssh2-1-dev
      - liburcu-dev
      - libusb-1.0-0-dev
      - libvte-2.90-dev
      - libvte-2.91-dev
      - sparse
      - uuid-dev
      - gcovr
  homebrew:
    packages:
      - libffi
      - gettext
      - glib
      - pixman


# The channel name "irc.oftc.net#qemu" is encrypted against qemu/qemu
# to prevent IRC notifications from forks. This was created using:
@@ -49,88 +55,145 @@ notifications:
      - secure: "F7GDRgjuOo5IUyRLqSkmDL7kvdU4UcH3Lm/W2db2JnDHTGCqgEdaYEYKciyCLZ57vOTsTsOgesN8iUT7hNHBd1KWKjZe9KDTZWppWRYVwAwQMzVeSOsbbU4tRoJ6Pp+3qhH1Z0eGYR9ZgKYAoTumDFgSAYRp4IscKS8jkoedOqM="
    on_success: change
    on_failure: always


env:
  global:
    - SRC_DIR="."
    - BUILD_DIR="."
    - TEST_CMD="make check"
    - MAKEFLAGS="-j3"
  matrix:
    - CONFIG="--disable-system"
    - CONFIG="--disable-user"
    - CONFIG="--enable-debug --enable-debug-tcg"
    - CONFIG="--disable-linux-aio --disable-cap-ng --disable-attr --disable-brlapi --disable-uuid --disable-libusb --disable-user"
    - CONFIG="--enable-modules --disable-linux-user"
    - CONFIG="--with-coroutine=ucontext --disable-linux-user"
    - CONFIG="--with-coroutine=sigaltstack --disable-linux-user"
    - TEST_CMD="make check -j3 V=1"


git:
  # we want to do this ourselves
  submodules: false
before_install:
  - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew update ; fi
  - if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew install libffi gettext glib pixman ; fi
  - git submodule update --init --recursive capstone dtc ui/keycodemapdb


before_script:
  - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
  - ${SRC_DIR}/configure ${CONFIG} || { cat config.log && exit 1; }
script:
  - make ${MAKEFLAGS} && ${TEST_CMD}
  - make -j3 && ${TEST_CMD}


matrix:
  include:
    - env:
        - CONFIG="--disable-system"


    - env:
        - CONFIG="--disable-user"


    - env:
        - CONFIG="--enable-debug --enable-debug-tcg"


    - env:
        - CONFIG="--disable-linux-aio --disable-cap-ng --disable-attr --disable-brlapi --disable-uuid --disable-libusb --disable-user"


    - env:
        - CONFIG="--enable-modules --disable-linux-user"


    - env:
        - CONFIG="--with-coroutine=ucontext --disable-linux-user"


    - env:
        - CONFIG="--with-coroutine=sigaltstack --disable-linux-user"


    # Test out-of-tree builds
    - env: CONFIG="--enable-debug --enable-debug-tcg"
           BUILD_DIR="out-of-tree/build/dir" SRC_DIR="../../.."
    - env:
        - CONFIG="--enable-debug --enable-debug-tcg"
        - BUILD_DIR="out-of-tree/build/dir" SRC_DIR="../../.."


    # Test with Clang for compile portability (Travis uses clang-5.0)
    - env: CONFIG="--disable-system"
    - env:
        - CONFIG="--disable-system"
      compiler: clang
    - env: CONFIG="--disable-user"


    - env:
        - CONFIG="--disable-user"
      compiler: clang


    # gprof/gcov are GCC features
    - env: CONFIG="--enable-gprof --enable-gcov --disable-pie --target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
    - env:
        - CONFIG="--enable-gprof --enable-gcov --disable-pie --target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
      after_success:
        - ${SRC_DIR}/scripts/travis/coverage-summary.sh
      compiler: gcc


    # We manually include builds which we disable "make check" for
    - env: CONFIG="--enable-debug --enable-tcg-interpreter"
           TEST_CMD=""
      compiler: gcc
    - env:
        - CONFIG="--enable-debug --enable-tcg-interpreter"
        - TEST_CMD=""


    # We don't need to exercise every backend with every front-end
    - env: CONFIG="--enable-trace-backends=log,simple,syslog --disable-system"
           TEST_CMD=""
      compiler: gcc
    - env: CONFIG="--enable-trace-backends=ftrace --target-list=x86_64-softmmu"
           TEST_CMD=""
      compiler: gcc
    - env: CONFIG="--enable-trace-backends=ust --target-list=x86_64-softmmu"
           TEST_CMD=""
      compiler: gcc
    - env: CONFIG="--disable-tcg"
           TEST_CMD=""
      compiler: gcc
    - env:
        - CONFIG="--enable-trace-backends=log,simple,syslog --disable-system"
        - TEST_CMD=""


    - env:
        - CONFIG="--enable-trace-backends=ftrace --target-list=x86_64-softmmu"
        - TEST_CMD=""


    - env:
        - CONFIG="--enable-trace-backends=ust --target-list=x86_64-softmmu"
        - TEST_CMD=""


    - env:
        - CONFIG="--disable-tcg"
        - TEST_CMD=""


    # MacOSX builds
    - env: CONFIG="--target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
    - env:
        - CONFIG="--target-list=aarch64-softmmu,arm-softmmu,i386-softmmu,mips-softmmu,mips64-softmmu,ppc64-softmmu,riscv64-softmmu,s390x-softmmu,x86_64-softmmu"
      os: osx
      osx_image: xcode9.4
      compiler: clang
    - env: CONFIG="--target-list=i386-softmmu,ppc-softmmu,ppc64-softmmu,m68k-softmmu,x86_64-softmmu"


    - env:
        - CONFIG="--target-list=i386-softmmu,ppc-softmmu,ppc64-softmmu,m68k-softmmu,x86_64-softmmu"
      os: osx
      osx_image: xcode10
      compiler: clang


    # Python builds
    - env: CONFIG="--target-list=x86_64-softmmu"
    - env:
        - CONFIG="--target-list=x86_64-softmmu"
      python:
        - "3.0"
    - env: CONFIG="--target-list=x86_64-softmmu"


    - env:
        - CONFIG="--target-list=x86_64-softmmu"
      python:
        - "3.6"


    # Acceptance (Functional) tests
    - env: CONFIG="--python=/usr/bin/python3 --target-list=x86_64-softmmu"
           TEST_CMD="make AVOCADO_SHOW=app check-acceptance"
    - env:
        - CONFIG="--python=/usr/bin/python3 --target-list=x86_64-softmmu"
        - TEST_CMD="make AVOCADO_SHOW=app check-acceptance"
      addons:
        apt:
          packages:
            - python3-pip
            - python3.4-venv
            - python3.5-venv
    # Using newer GCC with sanitizers
    - addons:
        apt:
@@ -164,7 +227,7 @@ matrix:
            - libssh2-1-dev
            - liburcu-dev
            - libusb-1.0-0-dev
            - libvte-2.90-dev
            - libvte-2.91-dev
            - sparse
            - uuid-dev
      language: generic
@@ -175,11 +238,8 @@ matrix:
        - TEST_CMD=""
      before_script:
        - ./configure ${CONFIG} --extra-cflags="-g3 -O0 -fsanitize=thread -fuse-ld=gold" || { cat config.log && exit 1; }


    - env:
        - CONFIG="--disable-system --disable-docs"
        - TEST_CMD="make check-tcg"
      script:
        - make ${MAKEFLAGS} && ${TEST_CMD} ${MAKEFLAGS}
      sudo: required
      dist: trusty
      compiler: gcc
        - TEST_CMD="make -j3 check-tcg V=1"
+0 −1
Original line number Diff line number Diff line
@@ -7470,7 +7470,6 @@ alpha)
esac

if test "$gprof" = "yes" ; then
  echo "CONFIG_GPROF=y" >> $config_host_mak
  echo "TARGET_GPROF=y" >> $config_target_mak
  if test "$target_linux_user" = "yes" ; then
    cflags="-p $cflags"
+1 −2
Original line number Diff line number Diff line
@@ -88,8 +88,7 @@ check-unit-y += tests/test-rcu-simpleq$(EXESUF)
check-unit-y += tests/test-rcu-tailq$(EXESUF)
check-unit-y += tests/test-qdist$(EXESUF)
check-unit-y += tests/test-qht$(EXESUF)
# FIXME: {test-qht-par + gprof} often break on Travis CI
check-unit-$(call lnot,$(CONFIG_GPROF)) += tests/test-qht-par$(EXESUF)
check-unit-y += tests/test-qht-par$(EXESUF)
check-unit-y += tests/test-bitops$(EXESUF)
check-unit-y += tests/test-bitcnt$(EXESUF)
check-unit-y += tests/test-qdev-global-props$(EXESUF)
+2 −4
Original line number Diff line number Diff line
@@ -74,16 +74,14 @@ static void *thread_func(void *arg)

static void run_test(void)
{
    unsigned int remaining;
    unsigned int i;

    while (atomic_read(&n_ready_threads) != n_threads) {
        cpu_relax();
    }

    atomic_set(&test_start, true);
    do {
        remaining = sleep(duration);
    } while (remaining);
    g_usleep(duration * G_USEC_PER_SEC);
    atomic_set(&test_stop, true);

    for (i = 0; i < n_threads; i++) {
+2 −4
Original line number Diff line number Diff line
@@ -76,16 +76,14 @@ static void *thread_func(void *arg)

static void run_test(void)
{
    unsigned int remaining;
    unsigned int i;

    while (atomic_read(&n_ready_threads) != n_threads) {
        cpu_relax();
    }

    atomic_set(&test_start, true);
    do {
        remaining = sleep(duration);
    } while (remaining);
    g_usleep(duration * G_USEC_PER_SEC);
    atomic_set(&test_stop, true);

    for (i = 0; i < n_threads; i++) {
Loading