It's only about compile-testing (there is too much noise when running
the tests), so let's simply add the -fsanitize=thread flag to a job that
only compiles the sources. The "build-gprof-gcov" seems to be a good
candidate.
Signed-off-by: Thomas Huth <thuth@redhat.com>
---
.gitlab-ci.yml | 1 +
.travis.yml | 51 --------------------------------------------------
2 files changed, 1 insertion(+), 51 deletions(-)
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 4654798523..e5c86e38c4 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -484,6 +484,7 @@ build-gprof-gcov:
variables:
IMAGE: ubuntu2004
CONFIGURE_ARGS: --enable-gprof --enable-gcov
+ --extra-cflags=-fsanitize=thread
MAKE_CHECK_ARGS: build-tcg
TARGETS: aarch64-softmmu mips64-softmmu ppc64-softmmu
riscv64-softmmu s390x-softmmu x86_64-softmmu
diff --git a/.travis.yml b/.travis.yml
index b3fc72f561..18e62f282f 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -120,57 +120,6 @@ after_script:
jobs:
include:
-
- # Using newer GCC with sanitizers
- - name: "GCC9 with sanitizers (softmmu)"
- dist: bionic
- addons:
- apt:
- update: true
- sources:
- # PPAs for newer toolchains
- - ubuntu-toolchain-r-test
- packages:
- # Extra toolchains
- - gcc-9
- - g++-9
- # Build dependencies
- - libaio-dev
- - libattr1-dev
- - libbrlapi-dev
- - libcap-ng-dev
- - libgnutls28-dev
- - libgtk-3-dev
- - libiscsi-dev
- - liblttng-ust-dev
- - libnfs-dev
- - libncurses5-dev
- - libnss3-dev
- - libpixman-1-dev
- - libpng-dev
- - librados-dev
- - libsdl2-dev
- - libsdl2-image-dev
- - libseccomp-dev
- - libspice-protocol-dev
- - libspice-server-dev
- - liburcu-dev
- - libusb-1.0-0-dev
- - libvte-2.91-dev
- - ninja-build
- - sparse
- - uuid-dev
- language: generic
- compiler: none
- env:
- - COMPILER_NAME=gcc CXX=g++-9 CC=gcc-9
- - CONFIG="--cc=gcc-9 --cxx=g++-9 --disable-linux-user"
- - TEST_CMD=""
- before_script:
- - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
- - ${SRC_DIR}/configure ${CONFIG} --extra-cflags="-g3 -O0 -fsanitize=thread" || { cat config.log meson-logs/meson-log.txt && exit 1; }
-
-
- name: "[aarch64] GCC check-tcg"
arch: arm64
dist: focal
--
2.27.0
Hi,
On 2/3/21 8:32 AM, Thomas Huth wrote:
> It's only about compile-testing (there is too much noise when running
> the tests), so let's simply add the -fsanitize=thread flag to a job that
> only compiles the sources. The "build-gprof-gcov" seems to be a good
> candidate.
>
> Signed-off-by: Thomas Huth <thuth@redhat.com>
> ---
> .gitlab-ci.yml | 1 +
> .travis.yml | 51 --------------------------------------------------
> 2 files changed, 1 insertion(+), 51 deletions(-)
It will be a little weird to see a gprof/gcov failing with a sanitize
error, but it seems indeed the best job.
Allow me to double-check: doesn't it need -g to show the line numbers?
- Wainer
>
> diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
> index 4654798523..e5c86e38c4 100644
> --- a/.gitlab-ci.yml
> +++ b/.gitlab-ci.yml
> @@ -484,6 +484,7 @@ build-gprof-gcov:
> variables:
> IMAGE: ubuntu2004
> CONFIGURE_ARGS: --enable-gprof --enable-gcov
> + --extra-cflags=-fsanitize=thread
> MAKE_CHECK_ARGS: build-tcg
> TARGETS: aarch64-softmmu mips64-softmmu ppc64-softmmu
> riscv64-softmmu s390x-softmmu x86_64-softmmu
> diff --git a/.travis.yml b/.travis.yml
> index b3fc72f561..18e62f282f 100644
> --- a/.travis.yml
> +++ b/.travis.yml
> @@ -120,57 +120,6 @@ after_script:
> jobs:
> include:
>
> -
> - # Using newer GCC with sanitizers
> - - name: "GCC9 with sanitizers (softmmu)"
> - dist: bionic
> - addons:
> - apt:
> - update: true
> - sources:
> - # PPAs for newer toolchains
> - - ubuntu-toolchain-r-test
> - packages:
> - # Extra toolchains
> - - gcc-9
> - - g++-9
> - # Build dependencies
> - - libaio-dev
> - - libattr1-dev
> - - libbrlapi-dev
> - - libcap-ng-dev
> - - libgnutls28-dev
> - - libgtk-3-dev
> - - libiscsi-dev
> - - liblttng-ust-dev
> - - libnfs-dev
> - - libncurses5-dev
> - - libnss3-dev
> - - libpixman-1-dev
> - - libpng-dev
> - - librados-dev
> - - libsdl2-dev
> - - libsdl2-image-dev
> - - libseccomp-dev
> - - libspice-protocol-dev
> - - libspice-server-dev
> - - liburcu-dev
> - - libusb-1.0-0-dev
> - - libvte-2.91-dev
> - - ninja-build
> - - sparse
> - - uuid-dev
> - language: generic
> - compiler: none
> - env:
> - - COMPILER_NAME=gcc CXX=g++-9 CC=gcc-9
> - - CONFIG="--cc=gcc-9 --cxx=g++-9 --disable-linux-user"
> - - TEST_CMD=""
> - before_script:
> - - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
> - - ${SRC_DIR}/configure ${CONFIG} --extra-cflags="-g3 -O0 -fsanitize=thread" || { cat config.log meson-logs/meson-log.txt && exit 1; }
> -
> -
> - name: "[aarch64] GCC check-tcg"
> arch: arm64
> dist: focal
On 2/3/21 4:23 PM, Wainer dos Santos Moschetta wrote:
> Hi,
>
> On 2/3/21 8:32 AM, Thomas Huth wrote:
>> It's only about compile-testing (there is too much noise when running
>> the tests), so let's simply add the -fsanitize=thread flag to a job that
>> only compiles the sources. The "build-gprof-gcov" seems to be a good
>> candidate.
>>
>> Signed-off-by: Thomas Huth <thuth@redhat.com>
>> ---
>> .gitlab-ci.yml | 1 +
>> .travis.yml | 51 --------------------------------------------------
>> 2 files changed, 1 insertion(+), 51 deletions(-)
>
> It will be a little weird to see a gprof/gcov failing with a sanitize
> error, but it seems indeed the best job.
>
> Allow me to double-check: doesn't it need -g to show the line numbers?
Never mind. It compiles with "-O2 -g". So:
Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com>
>
>
> - Wainer
>
>>
>> diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
>> index 4654798523..e5c86e38c4 100644
>> --- a/.gitlab-ci.yml
>> +++ b/.gitlab-ci.yml
>> @@ -484,6 +484,7 @@ build-gprof-gcov:
>> variables:
>> IMAGE: ubuntu2004
>> CONFIGURE_ARGS: --enable-gprof --enable-gcov
>> + --extra-cflags=-fsanitize=thread
>> MAKE_CHECK_ARGS: build-tcg
>> TARGETS: aarch64-softmmu mips64-softmmu ppc64-softmmu
>> riscv64-softmmu s390x-softmmu x86_64-softmmu
>> diff --git a/.travis.yml b/.travis.yml
>> index b3fc72f561..18e62f282f 100644
>> --- a/.travis.yml
>> +++ b/.travis.yml
>> @@ -120,57 +120,6 @@ after_script:
>> jobs:
>> include:
>> -
>> - # Using newer GCC with sanitizers
>> - - name: "GCC9 with sanitizers (softmmu)"
>> - dist: bionic
>> - addons:
>> - apt:
>> - update: true
>> - sources:
>> - # PPAs for newer toolchains
>> - - ubuntu-toolchain-r-test
>> - packages:
>> - # Extra toolchains
>> - - gcc-9
>> - - g++-9
>> - # Build dependencies
>> - - libaio-dev
>> - - libattr1-dev
>> - - libbrlapi-dev
>> - - libcap-ng-dev
>> - - libgnutls28-dev
>> - - libgtk-3-dev
>> - - libiscsi-dev
>> - - liblttng-ust-dev
>> - - libnfs-dev
>> - - libncurses5-dev
>> - - libnss3-dev
>> - - libpixman-1-dev
>> - - libpng-dev
>> - - librados-dev
>> - - libsdl2-dev
>> - - libsdl2-image-dev
>> - - libseccomp-dev
>> - - libspice-protocol-dev
>> - - libspice-server-dev
>> - - liburcu-dev
>> - - libusb-1.0-0-dev
>> - - libvte-2.91-dev
>> - - ninja-build
>> - - sparse
>> - - uuid-dev
>> - language: generic
>> - compiler: none
>> - env:
>> - - COMPILER_NAME=gcc CXX=g++-9 CC=gcc-9
>> - - CONFIG="--cc=gcc-9 --cxx=g++-9 --disable-linux-user"
>> - - TEST_CMD=""
>> - before_script:
>> - - mkdir -p ${BUILD_DIR} && cd ${BUILD_DIR}
>> - - ${SRC_DIR}/configure ${CONFIG} --extra-cflags="-g3 -O0
>> -fsanitize=thread" || { cat config.log meson-logs/meson-log.txt &&
>> exit 1; }
>> -
>> -
>> - name: "[aarch64] GCC check-tcg"
>> arch: arm64
>> dist: focal
>
>
© 2016 - 2026 Red Hat, Inc.