From patchwork Wed Nov 3 17:05:38 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516774 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp893695iml; Wed, 3 Nov 2021 10:11:50 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyNTbt5YebC+XtCQGrKCRmlP+ldN22awqQh/BeNK9Sxni0AAvyetnpulq7XgeNTx6KBXjuy X-Received: by 2002:a9d:360a:: with SMTP id w10mr3736936otb.195.1635959510200; Wed, 03 Nov 2021 10:11:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959510; cv=none; d=google.com; s=arc-20160816; b=Qig4z6ZkbzSERnrndqWKBh8k0KLmb1wn5taqNVjXmmnt0PxO8py1YGerab4/14Bxor 1XVkIwZtiVBibvueaY23DtOQpoi1roAU9DN6zJGfFmBYsKEwAJRw+W7QkuM7E2RxLqCI aW+coWZkYvLW7riJbhPaOsOAvBsGefqtwaZ48H1LwaeaUVJGKBZjoK/F4zIk3zZnpOss pVca/6V1FNiTmVCJPc8g0pyRgErNLvpYVFHU/WJ6Y8NEwei4TVk8EiOirHMc/XOiigsH D2SBxdO8acRY4u/IiWjMEJSgeBehekDo1S/dAhGwil4r1WSE5AgUAWswewAbH8UKGPrw XaFA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=KyTYAyNZxP7n3cRNsSLSLMm5Q1UB+DpXikehQPlbSNE=; b=sE26ogHXJPKq3rSwG50JEJYq37XffUR+dXDsWVsDb/++KVC18CUdGl/oy5KiGu8rQJ 1qHCNVv+rCfUswRXCVknBzIMKQsXuM3rMNuy8LkD8nWMoKj1N9ZiDeDH30RlvBCG08Pb r4qUB3zY2pglTFrq/XrTf2xin4VyfQrWx9+besi+wAeh1OMZpnHmmtztl+1IC+zDpNXC nr8/X4t+5Jn5k9KmtG+miRdoPCvq/4nI/4s7J/xaMRZmY//c9taZNXOzkQPLo4qdBeIX Zb5qSTNctfLLXW/9wu9cZJMuyvR0X8Gq2PCSzv5QqZ26dJ+pC5Say+XZCTPFW6dGImgx v8QQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=yxWaFkwA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id r44si4994839otv.301.2021.11.03.10.11.50 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:11:50 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=yxWaFkwA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:57766 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJnh-00010y-JW for patch@linaro.org; Wed, 03 Nov 2021 13:11:49 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34972) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiE-0003bZ-T7 for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:10 -0400 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]:37698) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiC-0003YB-5y for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:10 -0400 Received: by mail-wm1-x334.google.com with SMTP id y84-20020a1c7d57000000b00330cb84834fso5181755wmc.2 for ; Wed, 03 Nov 2021 10:06:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=KyTYAyNZxP7n3cRNsSLSLMm5Q1UB+DpXikehQPlbSNE=; b=yxWaFkwAyVsGi/QymVQESV0uK0m1JH15xEVWkovC4xswIlaPJtA5ashKids4GFcp7H JhBqZ75i83io6kvPwiGM1QpP2PS8itUhYUSCaGd20aStACJNWWmJRpi48zui+3UMxwoC 6JV2M/sNI6sMFOMxA2FTA9dD6cVL/a/ftKkxZLsBtdq49LUuwxywCKil40ODrozLI6xs A6ZNh1jolW1ZCRKoz1M/DINU50ypLdspBARn/nF6VnsiNT3Ju65GJH1SOo54Xt2pXmHM 6DtfRrZxNoudmV+mWwPbpFidrkT0rUY7FC6NXV5LjTwgo8U9OcK1rWE/YWRf8YrofsOe QQgA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=KyTYAyNZxP7n3cRNsSLSLMm5Q1UB+DpXikehQPlbSNE=; b=yt7t3pK9tiTJfy8oe+dU7Uuc5LH3K+drYg3uq2MekOD9NtdE4JjRK/CWsqlRRYSlFD +jk+Nd2fS66p7KUss1Sox6ybCQIQ2ZuKQqcBD/jAZQ2CRBOEotNEMUPf0OtuSrdnaUI8 Ec2CcTnz+1ZrbjKGEfqU71CDiEofZZmikaEnIh2JNvH85nNksXDByogwMIXnT+oC/Pzo l1+K1cKJs5GqWXcQkm4zbQS3NLX/aH8XxxiVsd+XZTRMG1tz5Ezy+QjGMKuk8FSNj2DB pNCViYfS4nnOjIjYC1XN4wktd0C3/h6DI5+L+hreSxKmakoz5l3jMFZt6c7ReaN+5KEG NjmA== X-Gm-Message-State: AOAM533py2x+UqnoK4tbOh67ueffXTeHYoVxZAOPUfy6vJGCZ7ROLznM pmhPiSfuJpz1mcFPenOsfNDtmg== X-Received: by 2002:a1c:4686:: with SMTP id t128mr16658219wma.194.1635959166495; Wed, 03 Nov 2021 10:06:06 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id u2sm2032463wrs.17.2021.11.03.10.05.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:02 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 91FB61FF98; Wed, 3 Nov 2021 17:05:58 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 01/21] tests/docker: Update debian-hexagon-cross to a newer toolchain Date: Wed, 3 Nov 2021 17:05:38 +0000 Message-Id: <20211103170558.717981-2-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::334; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x334.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Brian Cain , Thomas Huth , richard.henderson@linaro.org, qemu-devel@nongnu.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , Willian Rampazzo , Taylor Simpson , =?utf-8?q?Alex_Benn=C3=A9e?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Richard Henderson The new dockerfile uses a complete toolchain built by CodeLinaro. Remove the special casing that was necessary when the dockerfile built the toolchain from source. Suggested-by: Brian Cain Signed-off-by: Richard Henderson [AJB: fix MAINTAINERS, restore local build-dep, skip signals] Signed-off-by: Alex Bennée Message-Id: <20211014224435.2539547-4-richard.henderson@linaro.org> -- 2.30.2 diff --git a/MAINTAINERS b/MAINTAINERS index 7cbae14422..b7ef31e701 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -205,7 +205,6 @@ F: tests/tcg/hexagon/ F: disas/hexagon.c F: configs/targets/hexagon-linux-user/default.mak F: docker/dockerfiles/debian-hexagon-cross.docker -F: docker/dockerfiles/debian-hexagon-cross.docker.d/build-toolchain.sh HPPA (PA-RISC) TCG CPUs M: Richard Henderson diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include index b9d4094c2e..d223100dff 100644 --- a/tests/docker/Makefile.include +++ b/tests/docker/Makefile.include @@ -148,33 +148,11 @@ docker-image-debian-sparc64-cross: docker-image-debian10 # The native build should never use the registry docker-image-debian-native: DOCKER_REGISTRY= - -# -# The build rule for hexagon-cross is special in so far for most of -# the time we don't want to build it. While dockers caching does avoid -# this most of the time sometimes we want to force the issue. -# -docker-image-debian-hexagon-cross: $(DOCKER_FILES_DIR)/debian-hexagon-cross.docker - $(if $(NOCACHE), \ - $(call quiet-command, \ - $(DOCKER_SCRIPT) build -t qemu/debian-hexagon-cross -f $< \ - $(if $V,,--quiet) --no-cache \ - --registry $(DOCKER_REGISTRY) --extra-files \ - $(DOCKER_FILES_DIR)/debian-hexagon-cross.docker.d/build-toolchain.sh, \ - "BUILD", "debian-hexagon-cross"), \ - $(call quiet-command, \ - $(DOCKER_SCRIPT) fetch $(if $V,,--quiet) \ - qemu/debian-hexagon-cross $(DOCKER_REGISTRY), \ - "FETCH", "debian-hexagon-cross") \ - $(call quiet-command, \ - $(DOCKER_SCRIPT) update $(if $V,,--quiet) \ - qemu/debian-hexagon-cross --add-current-user, \ - "PREPARE", "debian-hexagon-cross")) - # Specialist build images, sometimes very limited tools docker-image-debian-tricore-cross: docker-image-debian10 docker-image-debian-all-test-cross: docker-image-debian10 docker-image-debian-arm64-test-cross: docker-image-debian11 +docker-image-debian-hexagon-cross: docker-image-debian10 docker-image-debian-powerpc-test-cross: docker-image-debian11 # These images may be good enough for building tests but not for test builds diff --git a/tests/docker/dockerfiles/debian-hexagon-cross.docker b/tests/docker/dockerfiles/debian-hexagon-cross.docker index d5dc299dc1..f6f8898645 100644 --- a/tests/docker/dockerfiles/debian-hexagon-cross.docker +++ b/tests/docker/dockerfiles/debian-hexagon-cross.docker @@ -1,45 +1,18 @@ # # Docker Hexagon cross-compiler target # -# This docker target is used for building hexagon tests. As it also -# needs to be able to build QEMU itself in CI we include it's -# build-deps. It is also a "stand-alone" image so as not to be -# triggered by re-builds on other base images given it takes a long -# time to build. -# FROM qemu/debian10 -# Install common build utilities -RUN apt update && \ - DEBIAN_FRONTEND=noninteractive apt install -yy eatmydata && \ - DEBIAN_FRONTEND=noninteractive eatmydata \ +RUN DEBIAN_FRONTEND=noninteractive eatmydata \ apt install -y --no-install-recommends \ - bison \ - cmake \ - flex \ - lld \ - rsync \ - wget - -ENV TOOLCHAIN_INSTALL /usr/local -ENV ROOTFS /usr/local - -ENV LLVM_URL https://github.com/llvm/llvm-project/archive/bfcd21876adc3498065e4da92799f613e730d475.tar.gz -ENV MUSL_URL https://github.com/quic/musl/archive/aff74b395fbf59cd7e93b3691905aa1af6c0778c.tar.gz -ENV LINUX_URL https://cdn.kernel.org/pub/linux/kernel/v5.x/linux-5.6.18.tar.xz - -ADD build-toolchain.sh /root/hexagon-toolchain/build-toolchain.sh + curl \ + xz-utils +RUN DEBIAN_FRONTEND=noninteractive eatmydata \ + apt build-dep -yy --arch-only qemu -RUN cd /root/hexagon-toolchain && ./build-toolchain.sh +RUN curl -#SL https://codelinaro.jfrog.io/artifactory/codelinaro-toolchain-for-hexagon/v2021.09.10/clang+llvm-Sept-2021-cross-hexagon-unknown-linux-musl.tar.xz \ + | tar -xJC /opt -FROM debian:buster-slim -# Duplicate deb line as deb-src -RUN cat /etc/apt/sources.list | sed "s/^deb\ /deb-src /" >> /etc/apt/sources.list -# Install QEMU build deps for use in CI -RUN apt update && \ - DEBIAN_FRONTEND=noninteractive apt install -yy eatmydata && \ - DEBIAN_FRONTEND=noninteractive eatmydata apt install -yy git ninja-build && \ - DEBIAN_FRONTEND=noninteractive eatmydata \ - apt build-dep -yy --arch-only qemu -COPY --from=0 /usr/local /usr/local -ENV PATH $PATH:/usr/local/bin/ +ENV PATH $PATH:/opt/clang+llvm-Sept-2021-cross-hexagon-unknown-linux-musl/x86_64-linux-gnu/bin +ENV DEF_TARGET_LIST hexagon-linux-user +ENV QEMU_CONFIGURE_OPTS --disable-docs --disable-tools --cross-cc-hexagon=hexagon-unknown-linux-musl-clang diff --git a/tests/docker/dockerfiles/debian-hexagon-cross.docker.d/build-toolchain.sh b/tests/docker/dockerfiles/debian-hexagon-cross.docker.d/build-toolchain.sh deleted file mode 100755 index 19b1c9f83e..0000000000 --- a/tests/docker/dockerfiles/debian-hexagon-cross.docker.d/build-toolchain.sh +++ /dev/null @@ -1,141 +0,0 @@ -#!/bin/bash - -set -e - -BASE=$(readlink -f ${PWD}) - -TOOLCHAIN_INSTALL=$(readlink -f "$TOOLCHAIN_INSTALL") -ROOTFS=$(readlink -f "$ROOTFS") - -TOOLCHAIN_BIN=${TOOLCHAIN_INSTALL}/bin -HEX_SYSROOT=${TOOLCHAIN_INSTALL}/hexagon-unknown-linux-musl -HEX_TOOLS_TARGET_BASE=${HEX_SYSROOT}/usr - -function cdp() { - DIR="$1" - mkdir -p "$DIR" - cd "$DIR" -} - -function fetch() { - DIR="$1" - URL="$2" - TEMP="$(readlink -f "$PWD/tmp.tar.gz")" - wget --quiet "$URL" -O "$TEMP" - cdp "$DIR" - tar xaf "$TEMP" --strip-components=1 - rm "$TEMP" - cd - -} - -build_llvm_clang() { - fetch "$BASE/llvm-project" "$LLVM_URL" - cdp "$BASE/build-llvm" - - cmake -G Ninja \ - -DCMAKE_BUILD_TYPE=Release \ - -DCMAKE_INSTALL_PREFIX=${TOOLCHAIN_INSTALL} \ - -DLLVM_ENABLE_LLD=ON \ - -DLLVM_TARGETS_TO_BUILD="Hexagon" \ - -DLLVM_ENABLE_PROJECTS="clang;lld" \ - "$BASE/llvm-project/llvm" - ninja all install - cd ${TOOLCHAIN_BIN} - ln -sf clang hexagon-unknown-linux-musl-clang - ln -sf clang++ hexagon-unknown-linux-musl-clang++ - ln -sf llvm-ar hexagon-unknown-linux-musl-ar - ln -sf llvm-objdump hexagon-unknown-linux-musl-objdump - ln -sf llvm-objcopy hexagon-unknown-linux-musl-objcopy - ln -sf llvm-readelf hexagon-unknown-linux-musl-readelf - ln -sf llvm-ranlib hexagon-unknown-linux-musl-ranlib - - # workaround for now: - cat < hexagon-unknown-linux-musl.cfg --G0 --sysroot=${HEX_SYSROOT} -EOF -} - -build_clang_rt() { - cdp "$BASE/build-clang_rt" - cmake -G Ninja \ - -DCMAKE_BUILD_TYPE=Release \ - -DLLVM_CONFIG_PATH="$BASE/build-llvm/bin/llvm-config" \ - -DCMAKE_ASM_FLAGS="-G0 -mlong-calls -fno-pic --target=hexagon-unknown-linux-musl " \ - -DCMAKE_SYSTEM_NAME=Linux \ - -DCMAKE_C_COMPILER="${TOOLCHAIN_BIN}/hexagon-unknown-linux-musl-clang" \ - -DCMAKE_ASM_COMPILER="${TOOLCHAIN_BIN}/hexagon-unknown-linux-musl-clang" \ - -DCMAKE_INSTALL_PREFIX=${HEX_TOOLS_TARGET_BASE} \ - -DCMAKE_CROSSCOMPILING=ON \ - -DCMAKE_C_COMPILER_FORCED=ON \ - -DCMAKE_CXX_COMPILER_FORCED=ON \ - -DCOMPILER_RT_BUILD_BUILTINS=ON \ - -DCOMPILER_RT_BUILTINS_ENABLE_PIC=OFF \ - -DCMAKE_SIZEOF_VOID_P=4 \ - -DCOMPILER_RT_OS_DIR= \ - -DCAN_TARGET_hexagon=1 \ - -DCAN_TARGET_x86_64=0 \ - -DCOMPILER_RT_SUPPORTED_ARCH=hexagon \ - -DLLVM_ENABLE_PROJECTS="compiler-rt" \ - "$BASE/llvm-project/compiler-rt" - ninja install-compiler-rt -} - -build_musl_headers() { - fetch "$BASE/musl" "$MUSL_URL" - cd "$BASE/musl" - make clean - CC=${TOOLCHAIN_BIN}/hexagon-unknown-linux-musl-clang \ - CROSS_COMPILE=hexagon-unknown-linux-musl \ - LIBCC=${HEX_TOOLS_TARGET_BASE}/lib/libclang_rt.builtins-hexagon.a \ - CROSS_CFLAGS="-G0 -O0 -mv65 -fno-builtin -fno-rounding-math --target=hexagon-unknown-linux-musl" \ - ./configure --target=hexagon --prefix=${HEX_TOOLS_TARGET_BASE} - PATH=${TOOLCHAIN_BIN}:$PATH make CROSS_COMPILE= install-headers - - cd ${HEX_SYSROOT}/.. - ln -sf hexagon-unknown-linux-musl hexagon -} - -build_kernel_headers() { - fetch "$BASE/linux" "$LINUX_URL" - mkdir -p "$BASE/build-linux" - cd "$BASE/linux" - make O=../build-linux ARCH=hexagon \ - KBUILD_CFLAGS_KERNEL="-mlong-calls" \ - CC=${TOOLCHAIN_BIN}/hexagon-unknown-linux-musl-clang \ - LD=${TOOLCHAIN_BIN}/ld.lld \ - KBUILD_VERBOSE=1 comet_defconfig - make mrproper - - cd "$BASE/build-linux" - make \ - ARCH=hexagon \ - CC=${TOOLCHAIN_BIN}/clang \ - INSTALL_HDR_PATH=${HEX_TOOLS_TARGET_BASE} \ - V=1 \ - headers_install -} - -build_musl() { - cd "$BASE/musl" - make clean - CROSS_COMPILE=hexagon-unknown-linux-musl- \ - AR=llvm-ar \ - RANLIB=llvm-ranlib \ - STRIP=llvm-strip \ - CC=clang \ - LIBCC=${HEX_TOOLS_TARGET_BASE}/lib/libclang_rt.builtins-hexagon.a \ - CFLAGS="-G0 -O0 -mv65 -fno-builtin -fno-rounding-math --target=hexagon-unknown-linux-musl" \ - ./configure --target=hexagon --prefix=${HEX_TOOLS_TARGET_BASE} - PATH=${TOOLCHAIN_BIN}/:$PATH make CROSS_COMPILE= install - cd ${HEX_TOOLS_TARGET_BASE}/lib - ln -sf libc.so ld-musl-hexagon.so - ln -sf ld-musl-hexagon.so ld-musl-hexagon.so.1 - cdp ${HEX_TOOLS_TARGET_BASE}/../lib - ln -sf ../usr/lib/ld-musl-hexagon.so.1 -} - -build_llvm_clang -build_kernel_headers -build_musl_headers -build_clang_rt -build_musl diff --git a/tests/tcg/hexagon/Makefile.target b/tests/tcg/hexagon/Makefile.target index 8b07a28166..84a722e1bc 100644 --- a/tests/tcg/hexagon/Makefile.target +++ b/tests/tcg/hexagon/Makefile.target @@ -21,6 +21,12 @@ EXTRA_RUNS = CFLAGS += -Wno-incompatible-pointer-types -Wno-undefined-internal CFLAGS += -fno-unroll-loops +# There is a 4-7% failure rate which becomes 100% during CI +run-signals: signals + $(call skip-test, $<, "BROKEN") +run-plugin-signals-with-%: + $(call skip-test, $<, "BROKEN") + HEX_SRC=$(SRC_PATH)/tests/tcg/hexagon VPATH += $(HEX_SRC) From patchwork Wed Nov 3 17:05:39 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516771 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp889263iml; Wed, 3 Nov 2021 10:07:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxE50ARnnSFs3axb8pEJCG9txLbNwHYzv1+nHAbCGVnIfpYbI2C4AjLz1WPEE+D86JPHAbN X-Received: by 2002:aca:58d6:: with SMTP id m205mr12267636oib.126.1635959276311; Wed, 03 Nov 2021 10:07:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959276; cv=none; d=google.com; s=arc-20160816; b=BaeFz0wd2TeCGipFwZR56xGkAzX5T7soEys0RKsGFkYGo+gkGNtnTmVitI4zKLYJsg TR3eHmFVpjaLLsilpFuq+4TEJJ27e6A9ogDM9AMpD4lBFIqgQKieYWNjDYkvdWFRD/5w DWYEGwjQpfkXgdQauAdQqkhygaO1clOEIt2Bjy+CcenedQmq+KuTlr7WHFj6ZmqTI56n 2rAx75VMLioNG4LUdLxd2GA8dVYr/h3vSGZ2mdU6wBnQSpxWp6QDj8sl/HqrwnJUK5et J4uiaFNYAW/gIAP9GZWquq3zIMU50uxXz1/bSnx+s5kehsfJZLOt/oGZXMfQfreC0pZj 8y+Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=6DX1I2E4+u1vvC4m9Xo0AYvLcsWD6MSuCT1+7cARLN0=; b=DC7OeCeO+k06dbG4PSC4785F6GYGg39d+mstOhU25A4mD7eJ1R33Wh0xgIBy7mA2Pc BUrzsgCZgrUEC8qpdK5ZgxQX3yaOCjmDWzSR8Y38W1i7z7pZNuIxsGADXYJXBWQJ9IJQ 62RrgBiY1Yx+4N4BdChqmSkcBVc9MGT9fJTwn0bkrIroxO9oNRWnsn4cNW8H1mPlT2aK Xf2arYcp1U8zaElIkFdNsRC0hAl7lvQ4iKBYCpHzSrNnPIuvLoUrlTCkLqbxepoLRsjj UGWL+USIUNNUrrBn+iuGkR/gOmFwxS5tiYY4UlX2lRTrZQ2SsZ7WN6F/lr/t8yiyMxPi HJ/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=zkZ+wKIm; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id x28si4848881ote.92.2021.11.03.10.07.56 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:07:56 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=zkZ+wKIm; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:48930 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJjv-0003Nk-QL for patch@linaro.org; Wed, 03 Nov 2021 13:07:55 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34888) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJi8-0003LR-E0 for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:04 -0400 Received: from mail-wr1-x435.google.com ([2a00:1450:4864:20::435]:44843) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJi5-0003XY-Vo for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:03 -0400 Received: by mail-wr1-x435.google.com with SMTP id d13so4597357wrf.11 for ; Wed, 03 Nov 2021 10:06:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=6DX1I2E4+u1vvC4m9Xo0AYvLcsWD6MSuCT1+7cARLN0=; b=zkZ+wKImbI/mY/M9WdpHuXK1P3St5aTEmKoP8flP705V3CGmALJW6QfAfr8VcZVec0 ucbWj5pp3TqfCio90hn4Bl/4yqDUPFyR3fBlejpJYgnZC+Y+fCNz7z7cwI+SDNi/FNk+ /NqzWrk3TuUcGSQa1ealZcWrHmwgneNhlsibWPOg3gKl8kBNe/bBSaqHuOaaYPjgurKM yLYXJqetMcjRFVM1QeHWWbz9Uhsdl9tkFNfM7yJrSLGDSo0zxbqOlaZpQSQlCpX7CDzz LCh2rUOSSsF/Mb4187z+9gn5VSHi0gkY45WtaUsnQnHk9RRC7EuMPx/CoJk3nsApJq/T qolA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=6DX1I2E4+u1vvC4m9Xo0AYvLcsWD6MSuCT1+7cARLN0=; b=TllOC0nFGom2ejM1p9x9NwkEGibhxnfuEdSvZ4nEkdomrPeZQVdcFbRxVJW3lFwoaR gf+f+JmAHr0C2sSnqxn3oo+JvgXfrVl0YIWdjJOSAsGVdDPOfH6vkiPF68nVeMiCh0N5 6MGsxReNafXFJC2QmknmYod7PAWNopGtIs7irMv6QNbXteqLsCeNwyLTh3n37CQK3xuf 0xHUMT+Kanr5TyNoPCaIIAT2Q86WjmOwEqDqygDswwcXi31+n/qpwsClr7JaV3PNr7gw 4hny/L5RcaMOwVoE/iP076lD/cer7ZfDwKc5bga0APJ87bOUJbK+aGzk76ypnsWt4msZ wV6A== X-Gm-Message-State: AOAM5305fktTB6QcvB2RxqaNdcFATVHr20Nl0EeNZVz2ikoS1w6LLOVJ UUaqzFspNTEcHTagSTGK32vukg== X-Received: by 2002:a5d:508d:: with SMTP id a13mr13895335wrt.41.1635959160319; Wed, 03 Nov 2021 10:06:00 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id c11sm2866164wmq.27.2021.11.03.10.05.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:05:59 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id AB0371FF99; Wed, 3 Nov 2021 17:05:58 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 02/21] gitlab-ci: Remove special casing for hexagon testing Date: Wed, 3 Nov 2021 17:05:39 +0000 Message-Id: <20211103170558.717981-3-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::435; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x435.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Huth , richard.henderson@linaro.org, qemu-devel@nongnu.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe?= =?utf-8?q?_Mathieu-Daud=C3=A9?= , Willian Rampazzo , =?utf-8?q?Alex_Benn=C3=A9e?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Richard Henderson Now that the hexagon container is using a pre-built toolchain, we do not need to make the build optional. Signed-off-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20211014224435.2539547-5-richard.henderson@linaro.org> Reviewed-by: Willian Rampazzo Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20211026102234.3961636-5-alex.bennee@linaro.org> -- 2.30.2 diff --git a/.gitlab-ci.d/buildtest.yml b/.gitlab-ci.d/buildtest.yml index 6c1301e912..3031917840 100644 --- a/.gitlab-ci.d/buildtest.yml +++ b/.gitlab-ci.d/buildtest.yml @@ -249,14 +249,10 @@ build-user-static: CONFIGURE_ARGS: --disable-tools --disable-system --static MAKE_CHECK_ARGS: check-tcg -# Because the hexagon cross-compiler takes so long to build we don't rely -# on the CI system to build it and hence this job has an optional dependency -# declared. The image is manually uploaded. build-user-hexagon: extends: .native_build_job_template needs: job: hexagon-cross-container - optional: true variables: IMAGE: debian-hexagon-cross TARGETS: hexagon-linux-user diff --git a/.gitlab-ci.d/container-cross.yml b/.gitlab-ci.d/container-cross.yml index a3b5b90552..ed7a849a69 100644 --- a/.gitlab-ci.d/container-cross.yml +++ b/.gitlab-ci.d/container-cross.yml @@ -47,33 +47,12 @@ armhf-debian-cross-container: variables: NAME: debian-armhf-cross -# We never want to build hexagon in the CI system and by default we -# always want to refer to the master registry where it lives. hexagon-cross-container: - image: docker:stable - stage: containers - rules: - - if: '$CI_PROJECT_NAMESPACE == "qemu-project"' - when: never - - when: always + extends: .container_job_template + stage: containers-layer2 + needs: ['amd64-debian10-container'] variables: NAME: debian-hexagon-cross - GIT_DEPTH: 1 - services: - - docker:dind - before_script: - - export TAG="$CI_REGISTRY_IMAGE/qemu/$NAME:latest" - - export COMMON_TAG="$CI_REGISTRY/qemu-project/qemu/qemu/$NAME:latest" - - docker info - - docker login $CI_REGISTRY -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" - script: - - echo "TAG:$TAG" - - echo "COMMON_TAG:$COMMON_TAG" - - docker pull $COMMON_TAG - - docker tag $COMMON_TAG $TAG - - docker push "$TAG" - after_script: - - docker logout hppa-debian-cross-container: extends: .container_job_template From patchwork Wed Nov 3 17:05:40 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516778 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp895741iml; Wed, 3 Nov 2021 10:13:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyuR4JLUuyRp5n8TC+z6TxiSEhKmvzQQbeL9FEMMRJx+mN5ttEIsdo32iTgN/owRpkim31m X-Received: by 2002:a05:6808:171c:: with SMTP id bc28mr11809699oib.18.1635959625819; Wed, 03 Nov 2021 10:13:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959625; cv=none; d=google.com; s=arc-20160816; b=BDOEo2mY+UErpOURY3G7xpte+QMaG9kMiF6fMeQejroPnjiLmO4kVTq5mxx+hj69BA 6MWF91o3Oywd4g9cr2rf/0Cy0qgml/KYWJgu/rhXZ6uKTgmynKh//A+u5u//TokIbopL GHQLikfeiMxQIxK7xAufqjywhTPCDEiOQr1wfXqlQrU4z60dQ6NbNatFRDm5dfouiTwT zay7A0JgWeQw7wBp6u9+mFhY8y+8ME/nOFDvlnyao/TMPGLuqD2ngLGBmfSoGVtVJJCl w5hrwCUgka2mGe5dRavVfjx/6V/GiV+Y/CclJOvimGUH2n59gk8GP22d3BC8vB9lL44V iTDg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=dtnjkaZPBasI3/4a9EGC8osxlwlyzz3NvP9JZJUVSlY=; b=rGYC9eVOXcZhnQ0gKSc5soKtNlGYnBSWFFFDsBQdtrjtd+4r+dT/kT1hqKhZ+tpAia nzpCgNUyyILhThHCO999Mowve5kmWE2Qsl3WNl8U3uqJgNSwvsRNMIQTEhfk+TMmYgGR qPbdHOU9yRQLzp93MMKsJnFUAII4sJNX5SGpLbdlXgnx6eZBVQLGcqp4YeUrs/aHfwRv Ch8iG4+FgBW7tgVv4A6cS8wveB5PbKBSY5SNtUWFGUuba0YOQBB23pfgz18RtVBuVs8G 8sSBUrnXLKbaQ3pYL/0fSVwBSZ26WnvvnQsG+fd+2SEVQ0SPmtEA5oJZQY8c9/VFBg5C u8Yg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=V3BlD4fB; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id q19si3812831otn.296.2021.11.03.10.13.45 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:13:45 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=V3BlD4fB; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:37930 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJpZ-0006g9-9I for patch@linaro.org; Wed, 03 Nov 2021 13:13:45 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34980) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiF-0003c3-6H for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:11 -0400 Received: from mail-wm1-x32d.google.com ([2a00:1450:4864:20::32d]:42535) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiA-0003Xx-MW for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:09 -0400 Received: by mail-wm1-x32d.google.com with SMTP id d72-20020a1c1d4b000000b00331140f3dc8so2375244wmd.1 for ; Wed, 03 Nov 2021 10:06:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=dtnjkaZPBasI3/4a9EGC8osxlwlyzz3NvP9JZJUVSlY=; b=V3BlD4fBNJkkmFpsUJtYSgtD2glDR2bN0qPpZqaM99viaf/xe+HmH52IvjY0IojU0o RO0iyWX/Ih4YP+tgHmekLQEnZ4nChhf1uNLrVw50YGe6fSqEipAmc1+95qyf29boD43V 3y2EP+7EZzUzCD1P15twetPsMAJDil5Q8PO3w9rclzCYLW2o65eExFqVrVOeEmOtw4iC pZCKEesBvm7tFitXeBoswVr3S4ouZ4yOVY3oe0fZlvdIOVo0TiC45d6lYmjgyHjJYW9i TBs4xdzeuEGXYd62DmEE6H9W4Ib3YW4ORbmZ6lY6ItCCAQQTQsdM9ULlHf0uJnos6BWj yrTw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=dtnjkaZPBasI3/4a9EGC8osxlwlyzz3NvP9JZJUVSlY=; b=a7M89gbmxTqUnqVcISrPg2/R/cmuQV78G0ZR5fpnCNMKPgJH/OnCHCNwtF+l2mimAW 93cfviFPWx2L18CI9l4mSRcLDHCU0eFZFsZWSRJS3/d2lSVlwG1uU92iORz5ekB+CIwV 05klkmYqe4exggZ5kkUEb6Civ2dFC9Gsbwqe1EDjhxjN+xgz5nat11ojTw7pN5W+Z1LS xrHcNa4l/lkQS32JoGORyU0XsaLswuQsVV6LJvUjeSjbjtPyHTh7kBL1n+upgEBkvIaa AsZIqob+6AggwiaDQhksNx1e9G4L8u4LcVsADvC078NUlqtZKXPaG5GrJmwanRutaMcx 3G6Q== X-Gm-Message-State: AOAM530J5uJ8rpmOV/wwYmIrR/djUZ4uot3ejhVIH0wtSyV+zfqv+cqS 0kYkg9E8J+9mOQwGG9e3qYtLEQ== X-Received: by 2002:a7b:c452:: with SMTP id l18mr17087305wmi.46.1635959163356; Wed, 03 Nov 2021 10:06:03 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id d9sm2457909wre.52.2021.11.03.10.05.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:00 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id C9B221FF9A; Wed, 3 Nov 2021 17:05:58 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 03/21] tests/docker: Add debian-nios2-cross image Date: Wed, 3 Nov 2021 17:05:40 +0000 Message-Id: <20211103170558.717981-4-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32d; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32d.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Marek Vasut , Thomas Huth , Chris Wulff , richard.henderson@linaro.org, qemu-devel@nongnu.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe?= =?utf-8?q?_Mathieu-Daud=C3=A9?= , Willian Rampazzo , =?utf-8?q?Alex_Benn=C3=A9e?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Richard Henderson Build the entire cross tool chain from source. For this reason, default to caching. Signed-off-by: Richard Henderson [AJB: honour NOUSER in cached fetch and build, update MAINTAINERS] Signed-off-by: Alex Bennée Message-Id: <20211014224435.2539547-6-richard.henderson@linaro.org> Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Willian Rampazzo Message-Id: <20211026102234.3961636-6-alex.bennee@linaro.org> -- 2.30.2 diff --git a/MAINTAINERS b/MAINTAINERS index b7ef31e701..e07134aa28 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -252,6 +252,7 @@ F: target/nios2/ F: hw/nios2/ F: disas/nios2.c F: configs/devices/nios2-softmmu/default.mak +F: tests/docker/dockerfiles/debian-nios2-cross.d/build-toolchain.sh OpenRISC TCG CPUs M: Stafford Horne diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include index d223100dff..24ed5c1f1d 100644 --- a/tests/docker/Makefile.include +++ b/tests/docker/Makefile.include @@ -148,11 +148,35 @@ docker-image-debian-sparc64-cross: docker-image-debian10 # The native build should never use the registry docker-image-debian-native: DOCKER_REGISTRY= +debian-toolchain-run = \ + $(if $(NOCACHE), \ + $(call quiet-command, \ + $(DOCKER_SCRIPT) build -t qemu/$1 -f $< \ + $(if $V,,--quiet) --no-cache \ + --registry $(DOCKER_REGISTRY) --extra-files \ + $(DOCKER_FILES_DIR)/$1.d/build-toolchain.sh, \ + "BUILD", $1), \ + $(call quiet-command, \ + $(DOCKER_SCRIPT) fetch $(if $V,,--quiet) \ + qemu/$1 $(DOCKER_REGISTRY), \ + "FETCH", $1) \ + $(call quiet-command, \ + $(DOCKER_SCRIPT) update $(if $V,,--quiet) \ + qemu/$1 \ + $(if $(NOUSER),,--add-current-user) \ + "PREPARE", $1)) +debian-toolchain = $(call debian-toolchain-run,$(patsubst docker-image-%,%,$1)) + +docker-image-debian-nios2-cross: $(DOCKER_FILES_DIR)/debian-toolchain.docker \ + $(DOCKER_FILES_DIR)/debian-nios2-cross.d/build-toolchain.sh + $(call debian-toolchain, $@) + # Specialist build images, sometimes very limited tools docker-image-debian-tricore-cross: docker-image-debian10 docker-image-debian-all-test-cross: docker-image-debian10 docker-image-debian-arm64-test-cross: docker-image-debian11 docker-image-debian-hexagon-cross: docker-image-debian10 +docker-image-debian-nios2-cross: docker-image-debian10 docker-image-debian-powerpc-test-cross: docker-image-debian11 # These images may be good enough for building tests but not for test builds @@ -161,6 +185,7 @@ DOCKER_PARTIAL_IMAGES += debian-arm64-test-cross DOCKER_PARTIAL_IMAGES += debian-powerpc-test-cross DOCKER_PARTIAL_IMAGES += debian-hppa-cross DOCKER_PARTIAL_IMAGES += debian-m68k-cross debian-mips64-cross +DOCKER_PARTIAL_IMAGES += debian-nios2-cross DOCKER_PARTIAL_IMAGES += debian-sh4-cross debian-sparc64-cross DOCKER_PARTIAL_IMAGES += debian-tricore-cross DOCKER_PARTIAL_IMAGES += debian-xtensa-cross diff --git a/tests/docker/dockerfiles/debian-nios2-cross.d/build-toolchain.sh b/tests/docker/dockerfiles/debian-nios2-cross.d/build-toolchain.sh new file mode 100755 index 0000000000..ba3c9d8aff --- /dev/null +++ b/tests/docker/dockerfiles/debian-nios2-cross.d/build-toolchain.sh @@ -0,0 +1,87 @@ +#!/bin/bash + +set -e + +TARGET=nios2-linux-gnu +LINUX_ARCH=nios2 + +J=$(expr $(nproc) / 2) +TOOLCHAIN_INSTALL=/usr/local +TOOLCHAIN_BIN=${TOOLCHAIN_INSTALL}/bin +CROSS_SYSROOT=${TOOLCHAIN_INSTALL}/$TARGET/sys-root + +export PATH=${TOOLCHAIN_BIN}:$PATH + +# +# Grab all of the source for the toolchain bootstrap. +# + +wget https://ftp.gnu.org/gnu/binutils/binutils-2.37.tar.xz +wget https://ftp.gnu.org/gnu/gcc/gcc-11.2.0/gcc-11.2.0.tar.xz +wget https://ftp.gnu.org/gnu/glibc/glibc-2.34.tar.xz +wget https://cdn.kernel.org/pub/linux/kernel/v5.x/linux-5.10.70.tar.xz + +tar axf binutils-2.37.tar.xz +tar axf gcc-11.2.0.tar.xz +tar axf glibc-2.34.tar.xz +tar axf linux-5.10.70.tar.xz + +mv binutils-2.37 src-binu +mv gcc-11.2.0 src-gcc +mv glibc-2.34 src-glibc +mv linux-5.10.70 src-linux + +mkdir -p bld-hdr bld-binu bld-gcc bld-glibc +mkdir -p ${CROSS_SYSROOT}/usr/include + +# +# Install kernel and glibc headers +# + +cd src-linux +make headers_install ARCH=${LINUX_ARCH} INSTALL_HDR_PATH=${CROSS_SYSROOT}/usr +cd .. + +cd bld-hdr +../src-glibc/configure --prefix=/usr --host=${TARGET} +make install-headers DESTDIR=${CROSS_SYSROOT} +touch ${CROSS_SYSROOT}/usr/include/gnu/stubs.h +cd .. + +# +# Build binutils +# + +cd bld-binu +../src-binu/configure --disable-werror \ + --prefix=${TOOLCHAIN_INSTALL} --with-sysroot --target=${TARGET} +make -j${J} +make install +cd .. + +# +# Build gcc, without shared libraries, because we do not yet +# have a shared libc against which to link. +# + +cd bld-gcc +../src-gcc/configure --disable-werror --disable-shared \ + --prefix=${TOOLCHAIN_INSTALL} --with-sysroot --target=${TARGET} \ + --enable-languages=c --disable-libssp --disable-libsanitizer \ + --disable-libatomic --disable-libgomp --disable-libquadmath +make -j${J} +make install +cd .. + +# +# Build glibc +# There are a few random things that use c++ but we didn't build that +# cross-compiler. We can get away without them. Disable CXX so that +# glibc doesn't try to use the host c++ compiler. +# + +cd bld-glibc +CXX=false ../src-glibc/configure --prefix=/usr --host=${TARGET} +make -j${j} +make install DESTDIR=${CROSS_SYSROOT} +cd .. diff --git a/tests/docker/dockerfiles/debian-toolchain.docker b/tests/docker/dockerfiles/debian-toolchain.docker new file mode 100644 index 0000000000..738d808aa6 --- /dev/null +++ b/tests/docker/dockerfiles/debian-toolchain.docker @@ -0,0 +1,36 @@ +# +# Docker toolchain cross-compiler +# +# This dockerfile is used for building a cross-compiler toolchain. +# The script for building the toolchain is supplied via extra-files. +# +FROM qemu/debian10 + +# Install build utilities for building gcc and glibc. +# ??? The build-dep isn't working, missing a number of +# minimal build dependiencies, e.g. libmpc. + +RUN apt update && \ + DEBIAN_FRONTEND=noninteractive apt install -yy eatmydata && \ + DEBIAN_FRONTEND=noninteractive eatmydata \ + apt install -y --no-install-recommends \ + bison \ + flex \ + gawk \ + libmpc-dev \ + libmpfr-dev \ + rsync \ + texinfo \ + wget && \ + DEBIAN_FRONTEND=noninteractive eatmydata \ + apt build-dep -yy --arch-only gcc glibc + +ADD build-toolchain.sh /root/build-toolchain.sh + +RUN cd /root && ./build-toolchain.sh + +# Throw away the extra toolchain build deps, the downloaded source, +# and the build trees by restoring the original debian10 image, +# then copying the built toolchain from stage 0. +FROM qemu/debian10 +COPY --from=0 /usr/local /usr/local From patchwork Wed Nov 3 17:05:41 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516782 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp898685iml; Wed, 3 Nov 2021 10:16:36 -0700 (PDT) X-Google-Smtp-Source: ABdhPJykdciwvvXFRJaQgojR9rGewACEJEDMpNe5nfwjSCyM5ozRzmRT+13eT6JFmjSEHHPUWH8+ X-Received: by 2002:a9d:5508:: with SMTP id l8mr9471493oth.27.1635959795886; Wed, 03 Nov 2021 10:16:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959795; cv=none; d=google.com; s=arc-20160816; b=Wmnak7RTpHFk7+nhkInMr8j5unX3AF+I8aPX2qf+PwcStxbh144TEqjhS5zZm4soBa 9xrl5yjdDc850MLC64nqCpDFPTyD6oOjXMUL3EZXBbxefkE1q/7Zls5VCIMgdTF4RFu0 ZAvM9bO0tYcupvjOVrSsXTCLzKFZUG+1pCpKc57qtQB8oBcFWdBLNQRebrGg/LGhaGOT xIcO0p9J1Ywu58MgzQM+JBIDT3s9Ao4grX7fIqGc2difTKuqOdC0i1X/bSpySrESGIj7 7p88dAvafXAqo3xl6PFQqXKiiMhKyYswCgbvSNg96PbDUd+ZxGyg+/t9SBtwYLEWh5Zy gSqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=EaaPl8F8ppW5z5fedqGy1eQqxGS9mK5OSP2e+zsFqfU=; b=LFOc4L7Jcv2YQNWZM5woqJgwN3KZuhNmvGh91N4eWEInULEkI106TLiqMtqj7LHM6J g1hCKbvjx8vDjSd3jgSE4PfSB+FAtwPs6h5aII4vAYvVE21d9Omm4H0ViL3x2c8pvFQ6 rZta8ZDIWgJxjfKXhKCDlZxXEP8nNE+GBG+GLdrmfjZhUCDW0J7il0GWs7YjO+ZZ5YWl jzZAXME75IjsMPKnXm0sJul4uWveAc6EW1lU6jNIkRfehWRFwsbpnr+cQLLnxT1sma0R Smi30Dy4dGVQ+oy188QhhMgPvUJ3nPOu+bkLvSj/IjW5ib7bU56A4NXySWFRaETnIuhV yFGQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=QAP2DLNu; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id ay16si3921893oib.307.2021.11.03.10.16.35 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:16:35 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=QAP2DLNu; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:46758 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJsJ-000424-BI for patch@linaro.org; Wed, 03 Nov 2021 13:16:35 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34990) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiF-0003d0-DI for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:11 -0400 Received: from mail-wm1-x335.google.com ([2a00:1450:4864:20::335]:34731) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiD-0003YI-2W for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:11 -0400 Received: by mail-wm1-x335.google.com with SMTP id o4-20020a1c7504000000b0032cab7473caso3778273wmc.1 for ; Wed, 03 Nov 2021 10:06:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=EaaPl8F8ppW5z5fedqGy1eQqxGS9mK5OSP2e+zsFqfU=; b=QAP2DLNudG/OHcJBNv0vXa7iFZMLj37Y6sgQ1fEXvrPgtFuvU/Ay9zoM+G90lfrThZ X92c131LURgdjwNqruf4Rp9i5uIQoISrQyRRmjbFQzS+8KnWaelTW6aih/51u4S/+tgW lwxPCMiuNyz4vpYaWbgDixKhaFYeHqi2EuZ+P/2yUVu+88H8pi3RJzwotQFwf03PFnt5 XVH9FDM61OEwV22oMIDvVJEaFOheC1xV60B1sy92FuSiA+DKUtdGojkYDGQx5XmO2Rqz NgslImk1Tf8R4ucf2ApKewczl3sYlvVEjghw69dYGDCLsdJWRPzODm/pRqR2WJa3vUTn jvPg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=EaaPl8F8ppW5z5fedqGy1eQqxGS9mK5OSP2e+zsFqfU=; b=RNq4p9TVjtw52Hb72o/JsIKXHlLKN50G1ofKqs+voiIS4jKzb+LqDULAF44F7iC8xO /xMQpTC4kJrz/4P/n3zF2G/+G356RyKuVXc4kGr+zKwueBVu7zoV0zdhO2easxtAuBXQ efI47dV3uVdNPacmpR/M9R81ZjlbtsTje9UukvYgjybTkY0CgMu8fBinM6+yYHwcT6Cn DGFErzA/602e7sSb6YGwiOeBc8SJxGJsvmxPTtEeKMQ0rFRh/H5rwefQpGgjaVM3Lv2K CovVJPZrgltxZEAF9S9sXdQDVIFNCMtpiabsZbEucSwfnQ9cpAFdOvhI5XNWB/noFNWD tmVw== X-Gm-Message-State: AOAM532Elk1SmUQkWw5HE9qc7F+7nD5GC2HqawUnqBDat8npXWY778uJ JydpWXRtyzfH4ffjachGE4xZyA== X-Received: by 2002:a1c:7910:: with SMTP id l16mr16838777wme.36.1635959167302; Wed, 03 Nov 2021 10:06:07 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id o1sm2498218wru.91.2021.11.03.10.05.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:02 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id E1D2A1FF9B; Wed, 3 Nov 2021 17:05:58 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 04/21] tests/docker: Add debian-microblaze-cross image Date: Wed, 3 Nov 2021 17:05:41 +0000 Message-Id: <20211103170558.717981-5-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::335; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x335.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Huth , richard.henderson@linaro.org, qemu-devel@nongnu.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe?= =?utf-8?q?_Mathieu-Daud=C3=A9?= , Willian Rampazzo , "Edgar E. Iglesias" , =?utf-8?q?Alex_Benn=C3=A9e?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Richard Henderson Build the entire cross tool chain from source. For this reason, default to caching. Signed-off-by: Richard Henderson [AJB: Update MAINTAINERS] Signed-off-by: Alex Bennée Message-Id: <20211014224435.2539547-7-richard.henderson@linaro.org> Reviewed-by: Willian Rampazzo Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20211026102234.3961636-7-alex.bennee@linaro.org> -- 2.30.2 diff --git a/MAINTAINERS b/MAINTAINERS index e07134aa28..a4d7a6f2e5 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -227,6 +227,7 @@ S: Maintained F: target/microblaze/ F: hw/microblaze/ F: disas/microblaze.c +F: tests/docker/dockerfiles/debian-microblaze-cross.d/build-toolchain.sh MIPS TCG CPUs M: Philippe Mathieu-Daudé diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include index 24ed5c1f1d..e943ac33b0 100644 --- a/tests/docker/Makefile.include +++ b/tests/docker/Makefile.include @@ -167,6 +167,10 @@ debian-toolchain-run = \ "PREPARE", $1)) debian-toolchain = $(call debian-toolchain-run,$(patsubst docker-image-%,%,$1)) +docker-image-debian-microblaze-cross: $(DOCKER_FILES_DIR)/debian-toolchain.docker \ + $(DOCKER_FILES_DIR)/debian-microblaze-cross.d/build-toolchain.sh + $(call debian-toolchain, $@) + docker-image-debian-nios2-cross: $(DOCKER_FILES_DIR)/debian-toolchain.docker \ $(DOCKER_FILES_DIR)/debian-nios2-cross.d/build-toolchain.sh $(call debian-toolchain, $@) @@ -176,6 +180,7 @@ docker-image-debian-tricore-cross: docker-image-debian10 docker-image-debian-all-test-cross: docker-image-debian10 docker-image-debian-arm64-test-cross: docker-image-debian11 docker-image-debian-hexagon-cross: docker-image-debian10 +docker-image-debian-microblaze-cross: docker-image-debian10 docker-image-debian-nios2-cross: docker-image-debian10 docker-image-debian-powerpc-test-cross: docker-image-debian11 @@ -185,6 +190,7 @@ DOCKER_PARTIAL_IMAGES += debian-arm64-test-cross DOCKER_PARTIAL_IMAGES += debian-powerpc-test-cross DOCKER_PARTIAL_IMAGES += debian-hppa-cross DOCKER_PARTIAL_IMAGES += debian-m68k-cross debian-mips64-cross +DOCKER_PARTIAL_IMAGES += debian-microblaze-cross DOCKER_PARTIAL_IMAGES += debian-nios2-cross DOCKER_PARTIAL_IMAGES += debian-sh4-cross debian-sparc64-cross DOCKER_PARTIAL_IMAGES += debian-tricore-cross diff --git a/tests/docker/dockerfiles/debian-microblaze-cross.d/build-toolchain.sh b/tests/docker/dockerfiles/debian-microblaze-cross.d/build-toolchain.sh new file mode 100755 index 0000000000..23ec0aa9a7 --- /dev/null +++ b/tests/docker/dockerfiles/debian-microblaze-cross.d/build-toolchain.sh @@ -0,0 +1,88 @@ +#!/bin/bash + +set -e + +TARGET=microblaze-linux-musl +LINUX_ARCH=microblaze + +J=$(expr $(nproc) / 2) +TOOLCHAIN_INSTALL=/usr/local +TOOLCHAIN_BIN=${TOOLCHAIN_INSTALL}/bin +CROSS_SYSROOT=${TOOLCHAIN_INSTALL}/$TARGET/sys-root + +export PATH=${TOOLCHAIN_BIN}:$PATH + +# +# Grab all of the source for the toolchain bootstrap. +# + +wget https://ftp.gnu.org/gnu/binutils/binutils-2.37.tar.xz +wget https://ftp.gnu.org/gnu/gcc/gcc-11.2.0/gcc-11.2.0.tar.xz +wget https://www.musl-libc.org/releases/musl-1.2.2.tar.gz +wget https://cdn.kernel.org/pub/linux/kernel/v5.x/linux-5.10.70.tar.xz + +tar axf binutils-2.37.tar.xz +tar axf gcc-11.2.0.tar.xz +tar axf musl-1.2.2.tar.gz +tar axf linux-5.10.70.tar.xz + +mv binutils-2.37 src-binu +mv gcc-11.2.0 src-gcc +mv musl-1.2.2 src-musl +mv linux-5.10.70 src-linux + +mkdir -p bld-hdr bld-binu bld-gcc bld-musl +mkdir -p ${CROSS_SYSROOT}/usr/include + +# +# Install kernel headers +# + +cd src-linux +make headers_install ARCH=${LINUX_ARCH} INSTALL_HDR_PATH=${CROSS_SYSROOT}/usr +cd .. + +# +# Build binutils +# + +cd bld-binu +../src-binu/configure --disable-werror \ + --prefix=${TOOLCHAIN_INSTALL} --with-sysroot --target=${TARGET} +make -j${J} +make install +cd .. + +# +# Build gcc, just the compiler so far. +# + +cd bld-gcc +../src-gcc/configure --disable-werror --disable-shared \ + --prefix=${TOOLCHAIN_INSTALL} --with-sysroot --target=${TARGET} \ + --enable-languages=c --disable-libssp --disable-libsanitizer \ + --disable-libatomic --disable-libgomp --disable-libquadmath +make -j${J} all-gcc +make install-gcc +cd .. + +# +# Build musl. +# We won't go through the extra step of building shared libraries +# because we don't actually use them in QEMU docker testing. +# + +cd bld-musl +../src-musl/configure --prefix=/usr --host=${TARGET} --disable-shared +make -j${j} +make install DESTDIR=${CROSS_SYSROOT} +cd .. + +# +# Go back and build the compiler runtime +# + +cd bld-gcc +make -j${j} +make install +cd .. From patchwork Wed Nov 3 17:05:42 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516780 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp896219iml; Wed, 3 Nov 2021 10:14:14 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzSP9uvX151VRW6kD2G2uCm1a1NYqMlgXLcU0CnhuE14Sr3Rk4Kivvs0DLlKxT7GAek+GO2 X-Received: by 2002:a05:6808:ec8:: with SMTP id q8mr11806855oiv.96.1635959654413; Wed, 03 Nov 2021 10:14:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959654; cv=none; d=google.com; s=arc-20160816; b=oHSlJVd7z9gQkLGSJOtb9CtTlrm6JaFS+UcWh8fKtnQuWtcCYdzIC7jsjXYLQdey5d V5AXg3xClK14L4HrILjtgEWrjGDIdlSuz9k9oOVEj5EKVOgtBzxNM76EMCvY2PqZdVTR 7oyoeETZLQjQMTV7U7AFAoCPI0FtW3KXG9Yuyj7pAd0X5o797UbrsufRf24IG78/Xuyy SbQM8mBxEPi5Xtnvl14Mk7yuHaKSXwDbh5SyC5fIqXN6yTouYBRCWwJv3UMUUxeu6Qfc wmtB/WoN9RJjOlU+c4CF65HJDoSKp05HpIQhMSk1ZlL8+He2lvb9RNglXIWLo1q9kXHh tw3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=M5fYOctlTURM4vfZYvc+pbC8U3ts65RhrBvT4OPTIOc=; b=c7G1O/XVb56xMvF/L89UEXnQjgSYWrPavRIxQYYbr+3Ov7vxlFPTTTQQ1/ieq0bDf8 gpMbF+QurnS96+6PZv1CUvGbq28gGBG17+sKx6RPTLE2r1ag4xZLMPHqgpmXj4/aGvTD nsvU1IFd6feCzcM0lXSax//SgVaqTGGFad4oH4rpKtppcJ/ebZQ+uf1XfiT81MzEIUIf ehPOG7NicrftHIRN4jW/9ADoKcfW5nSejOQjvOTSUqPfjEGvHYDlOoIyRvfc1wwrQgbD BOxAVD6AsJhXPHoH2VgOmgOxWHjBwbGn2YmWiM4o3Oi2xzd9Dffe1GA6oHw1uDppjlSC fcjA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=QLeReWhD; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id a5si3784130oil.217.2021.11.03.10.14.14 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:14:14 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=QLeReWhD; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:40892 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJq1-0000AL-TZ for patch@linaro.org; Wed, 03 Nov 2021 13:14:13 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35024) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiH-0003hY-Qg for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:13 -0400 Received: from mail-wr1-x42e.google.com ([2a00:1450:4864:20::42e]:41617) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiF-0003Z6-Pv for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:13 -0400 Received: by mail-wr1-x42e.google.com with SMTP id d3so4604856wrh.8 for ; Wed, 03 Nov 2021 10:06:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=M5fYOctlTURM4vfZYvc+pbC8U3ts65RhrBvT4OPTIOc=; b=QLeReWhDFXzzEwxAAoAkVsRHurqOsVjTktHlI262OWrZ4uw7jTM8pWZNyI5Q2TLH68 nnpo2iHHtdoC+T6/ZLWnPsE5mUIQIbSuej4iUCKkSqDKd58yiKG1hkevxJh84uKMBFiT K3UOtW6UExftRf8YzChw2HaSnENTGezVeXY2qIUE67hw3qLaSYgKAYSiNqEGoYULzojG FfwufXJeHJjQQtJUmPeF0svZEYxKFt2b4jt4bwxvXF58Y9+Pxs+IaZX0TbfN+hX2IKlq x8Zkp6ofiXtnwiLUFxcI9ZlUTcVQHAB21chpxP8qgv2Hdk/k75LRR/njCUGY7oiw/K6P lWAA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=M5fYOctlTURM4vfZYvc+pbC8U3ts65RhrBvT4OPTIOc=; b=SACu1f9kxrTEKLWk6xE83wg3DVuienQLSuW0aYIxkRwsOs3oe/GwOh5J5zthvdFcbH dSxPxAPmDHItR14LpQdAiOMcHpFDT/Zwmmpr2BS8aFLKiuIN5HYZ470gH5d++tvOQdwq 8G0Eg1Ci5wKIRjGOJfLeLliXqopm6hWlpzmr6VuQb88BHEYa4b91vC2xGRzRsN4sl5SS 9jkODM+0M+m5MDfqx1dI2E/Vj+DJV2Kq/iHgLqcggJHYhy51f8XEejKJfsuTWkNLhXc7 JHmr2n7iSs6LZVaNIlgVHyKd9x84dy0NNjhPEqFqJDjKpGnvel+inkEp7oW61CBypr+z 2yZQ== X-Gm-Message-State: AOAM531TUYTxe20G5r3lfXmMNDtch40djUkNK1Zx62/DRBfo8tlkx0N4 Pcn2BLE9JpdXxUkOteYjhTHa5g== X-Received: by 2002:a5d:64a2:: with SMTP id m2mr5756291wrp.248.1635959170302; Wed, 03 Nov 2021 10:06:10 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id j40sm2605239wms.16.2021.11.03.10.06.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:03 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 031041FF9C; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 05/21] tests/tcg: Enable container_cross_cc for microblaze Date: Wed, 3 Nov 2021 17:05:42 +0000 Message-Id: <20211103170558.717981-6-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42e; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42e.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, qemu-devel@nongnu.org, =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Richard Henderson Signed-off-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20211014224435.2539547-8-richard.henderson@linaro.org> Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20211026102234.3961636-8-alex.bennee@linaro.org> -- 2.30.2 diff --git a/tests/tcg/configure.sh b/tests/tcg/configure.sh index 1f985ccfc0..ccf84e5559 100755 --- a/tests/tcg/configure.sh +++ b/tests/tcg/configure.sh @@ -55,6 +55,7 @@ fi : ${cross_cc_i386="i686-linux-gnu-gcc"} : ${cross_cc_cflags_i386="-m32"} : ${cross_cc_m68k="m68k-linux-gnu-gcc"} +: ${cross_cc_microblaze="microblaze-linux-musl-gcc"} : $(cross_cc_mips64el="mips64el-linux-gnuabi64-gcc") : $(cross_cc_mips64="mips64-linux-gnuabi64-gcc") : $(cross_cc_mipsel="mipsel-linux-gnu-gcc") @@ -133,6 +134,11 @@ for target in $target_list; do container_image=debian-m68k-cross container_cross_cc=m68k-linux-gnu-gcc ;; + microblaze-*) + container_hosts=x86_64 + container_image=debian-microblaze-cross + container_cross_cc=microblaze-linux-musl-gcc + ;; mips64el-*) container_hosts=x86_64 container_image=debian-mips64el-cross From patchwork Wed Nov 3 17:05:43 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516772 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp889564iml; Wed, 3 Nov 2021 10:08:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw/7QaudKz8fYCFHmD4TXLQNKGDGYixtTTSPzD9yA4GE3lMH+zj0VU4MsVWt+2f/KcWEWDp X-Received: by 2002:aca:ac0b:: with SMTP id v11mr12106276oie.155.1635959293186; Wed, 03 Nov 2021 10:08:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959293; cv=none; d=google.com; s=arc-20160816; b=wexHI93kuKAHNbP1h/HKNIorM5ceqyxHa2yjaB0fmqJ1VP8Q4wN3/9uUqaoR27qMpt WZibdeF9f8oeoArLEHl6D7Gz2/zLcX7FrUREK47GfXUb/MOqDI6lEsIfEy/+KQbdQ4Dq cpw9Q3rrQzlK0fcD2fxBhC7YQkcVnQrxXPYF0Kk2TDVtfuQWAJM+7MdK94BHmqrQn2r/ S9pEYNrkKxZdWQu+42TsnxYM9ipjhtYwY5m6/C5Hd2pCgC7AgViFJyd53GRWEZJnUIHd 8gUNmRTrgZrbHFB89b+702DU4YzrzBQBZUB6Ic70qSWkmwhfw69YREs6pXkdKBSFOJW8 P/gQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=hsyzSfNK3dBgoCFVsZ9lOYqPSB9PzljxnnVJgvNEjq0=; b=qcjxlnKFXp7DYjULZGDmfMIVNCNAhP7jDCS81tncNtZ++f1N717ZA3hxCN54XVGh7Y nmxGMyJcY6JNM9SgicZj+an5CodTMTW8QgLTMKeOZsyqhUCUl9dyHETs2t94YGUINoHC WB54avE+wPr9aR9FPdWDcnPCJT7joebLytmtpnZirQH/YtHwmcRVcHKQRSScV1IejaDW hP1d6CwR6yOJwC89nwUak0J4sCl4tX4QK5jn8dI03KqaXploS3/+VamZaFCPZ/FoHQm1 Red6oJkH+lryu5Sej8l98q5hJcwEZJUezt9QcrbOrdxN9QSDF2VwLmCESuT9EZSapY4E GFeg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=m2Tordfy; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id o20si4246568oiw.174.2021.11.03.10.08.13 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:08:13 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=m2Tordfy; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:49480 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJkC-0003kl-KH for patch@linaro.org; Wed, 03 Nov 2021 13:08:12 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35022) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiH-0003ft-BY for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:13 -0400 Received: from mail-wr1-x42a.google.com ([2a00:1450:4864:20::42a]:41613) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiF-0003Yk-2w for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:13 -0400 Received: by mail-wr1-x42a.google.com with SMTP id d3so4604806wrh.8 for ; Wed, 03 Nov 2021 10:06:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=hsyzSfNK3dBgoCFVsZ9lOYqPSB9PzljxnnVJgvNEjq0=; b=m2Tordfy4dWXxx3MJQfltnw64sdqI5/7ECBEDW0P4rFnDIh2eFHn++jpRmANV7wCbn FkPNeRMlNcMYCWYkal3Wu2d+ap4WegMWMSdK+POogGy3via5Clae/1B0Cgn3JOg7Yrpo KU87o6hv6Y+D6e0jHhkpqF98cOXwOG7LqMBotcwREa79oh7vt1aam8qhCNBKJbbq1L5l l3X79wSGe6tImVzcBPC/WgT2zVBiT2S9iWt2SHMyJ3kYRbbLRelbXipSaLt6j3E0gqOx cQ7XNLYi5g5Zsjc6FsB1NTZiFVSWVlYGFHegZWkdRoaq5XT3IDZXQ0GbVofLnmqlTmWB s7Tw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=hsyzSfNK3dBgoCFVsZ9lOYqPSB9PzljxnnVJgvNEjq0=; b=LexT7gAEUrk/NR05oJDO90UmMiomwv5W4dNp6ivxy2AN/WfR/9PJ4ygS9zOP55aqeo wHtu8k0GwaEzViNlopT+D0tscluPoRPx8MCu6SyDXo+AOnHlzZSZGxQRjlkksYBWUCNU OmFakVwECPwgpL81GJ+0alQti+3nfW14cdx14kGW4i0S8ZleEGSnGYTOvp4cZcXlOgg4 hn2l+4mWQJg70AJo3joWTP1Pid/Xe4rse4FpQNQD0RR/6lqUZsqMfTovMQ3TLeVcj/dQ v2yjcJveirKsaYpspIOmSN3TCABDz1vA1BVVmrqwq99agiGkmRRygDQ/EMg5Gh/mvyKK uyFQ== X-Gm-Message-State: AOAM530myyqU/A1IjknNpSOjaaWDz5/AYBIHRTQmcF32xXpfyV76axUj 8lfDCp90dmCX1VnCtv10ZYHudQ== X-Received: by 2002:adf:8b06:: with SMTP id n6mr58787096wra.5.1635959169612; Wed, 03 Nov 2021 10:06:09 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id o3sm2942236wms.10.2021.11.03.10.06.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:03 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 0FBA81FF9D; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 06/21] tests/tcg: Fix some targets default cross compiler path Date: Wed, 3 Nov 2021 17:05:43 +0000 Message-Id: <20211103170558.717981-7-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42a; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42a.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, qemu-devel@nongnu.org, =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Philippe Mathieu-Daudé We do not want a shell command substitution, but a parameter substitution (with assignment). Replace $() -> ${}, otherwise the expanded command return an empty string and the $cross_cc variable is not set. Fixes: 634ef789f8e ("tests/tcg: add more default compilers to configure.sh") Signed-off-by: Philippe Mathieu-Daudé [AJB: disable sh4 linux-test] Signed-off-by: Alex Bennée Message-Id: <20211023164329.328137-1-f4bug@amsat.org> Reviewed-by: Richard Henderson Message-Id: <20211026102234.3961636-9-alex.bennee@linaro.org> -- 2.30.2 diff --git a/tests/tcg/configure.sh b/tests/tcg/configure.sh index ccf84e5559..d74ed50c18 100755 --- a/tests/tcg/configure.sh +++ b/tests/tcg/configure.sh @@ -46,7 +46,7 @@ fi : ${cross_cc_aarch64="aarch64-linux-gnu-gcc"} : ${cross_cc_aarch64_be="$cross_cc_aarch64"} : ${cross_cc_cflags_aarch64_be="-mbig-endian"} -: $(cross_cc_alpha="alpha-linux-gnu-gcc") +: ${cross_cc_alpha="alpha-linux-gnu-gcc"} : ${cross_cc_arm="arm-linux-gnueabihf-gcc"} : ${cross_cc_cflags_armeb="-mbig-endian"} : ${cross_cc_hexagon="hexagon-unknown-linux-musl-clang"} @@ -56,17 +56,17 @@ fi : ${cross_cc_cflags_i386="-m32"} : ${cross_cc_m68k="m68k-linux-gnu-gcc"} : ${cross_cc_microblaze="microblaze-linux-musl-gcc"} -: $(cross_cc_mips64el="mips64el-linux-gnuabi64-gcc") -: $(cross_cc_mips64="mips64-linux-gnuabi64-gcc") -: $(cross_cc_mipsel="mipsel-linux-gnu-gcc") -: $(cross_cc_mips="mips-linux-gnu-gcc") +: ${cross_cc_mips64el="mips64el-linux-gnuabi64-gcc"} +: ${cross_cc_mips64="mips64-linux-gnuabi64-gcc"} +: ${cross_cc_mipsel="mipsel-linux-gnu-gcc"} +: ${cross_cc_mips="mips-linux-gnu-gcc"} : ${cross_cc_ppc="powerpc-linux-gnu-gcc"} : ${cross_cc_cflags_ppc="-m32"} : ${cross_cc_ppc64="powerpc64-linux-gnu-gcc"} : ${cross_cc_ppc64le="powerpc64le-linux-gnu-gcc"} -: $(cross_cc_riscv64="riscv64-linux-gnu-gcc") +: ${cross_cc_riscv64="riscv64-linux-gnu-gcc"} : ${cross_cc_s390x="s390x-linux-gnu-gcc"} -: $(cross_cc_sh4="sh4-linux-gnu-gcc") +: ${cross_cc_sh4="sh4-linux-gnu-gcc"} : ${cross_cc_cflags_sparc="-m32 -mv8plus -mcpu=ultrasparc"} : ${cross_cc_sparc64="sparc64-linux-gnu-gcc"} : ${cross_cc_cflags_sparc64="-m64 -mcpu=ultrasparc"} diff --git a/tests/tcg/sh4/Makefile.target b/tests/tcg/sh4/Makefile.target index 47c39a44b6..0e96aeff16 100644 --- a/tests/tcg/sh4/Makefile.target +++ b/tests/tcg/sh4/Makefile.target @@ -12,3 +12,9 @@ run-signals: signals $(call skip-test, $<, "BROKEN") run-plugin-signals-with-%: $(call skip-test, $<, "BROKEN") + +# This test is currently broken: https://gitlab.com/qemu-project/qemu/-/issues/704 +run-linux-test: linux-test + $(call skip-test, $<, "BROKEN") +run-plugin-linux-test-with-%: + $(call skip-test, $<, "BROKEN") From patchwork Wed Nov 3 17:05:44 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516783 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp899458iml; Wed, 3 Nov 2021 10:17:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx25uwHMFS9TOkmot1PqJR2A6d0uIoMU1/PEhNREo0YdwlzlIpgXGYfRAa7gsl7R7mwHmTK X-Received: by 2002:a05:6830:2805:: with SMTP id w5mr9610395otu.374.1635959840169; Wed, 03 Nov 2021 10:17:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959840; cv=none; d=google.com; s=arc-20160816; b=RjCK6MYCF78PfRG/BUEEZJgAsx/0EZRamjoz01AJdxiFuEe615gL1kZpPmkaXaUz+s T7YBVCpG1jciPDIZ8zlyWFwXgfVNCvQOHuA/qxo17ZE7vfzqj+kfvGhFVAimHBOPhGb/ r+XW3d4UWovMFI8MKMJM7p4I0uGHGPksrhPplP/kHN7+CYGX407RSldIL2DAVtWrI1MP lWt0q+l0qKxUkjdM9+am66Y8qhCfq6l+dZXTKtet3yJ6xx7ABuLE+OiBK+bb6jMlydPj jJIJXBr0y2wUxO8GsI/fVUEmxt6/FIMtNmslj+ZOlLNsZXYaYNj31W4gvonnXmm/4Wcg 0lCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=LhCMj49V450oWkOKk125VLrGAzkn15HxQfeeMwD8j/0=; b=mAfG38nUawPd50C0/xZBTns9u5qWVQMC/fw16imT382aJIDsK9wsrBG3DK/Kyh+M12 oNfr/7EzfGLtAY29/v2dgBPxpPKmgWw1jawMdbvBp0K0M74TpDVh3BuXPSTH4ZezQhLd CK7EfeI2zOHuI6GVRxtkLctPMpZjzEbeBoSs9BjJoQFcAMgaynrjOYDf3iaSAEMHjtwv ZRR+NWyKE7hWaBVyEUcn2pqOFSisH6zpag4Ot1grT0fyJQm0fwXtccPHTQ4ujoUw/5BX mwRJZ9fZ2Oam7dGeJ2kz2BxIlnHUuuSB8pR3afeMdcuttbFYJHDYS6Wif3ZvmEiPDoRb AHpA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=B1hx1u15; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id s3si3020311oig.131.2021.11.03.10.17.20 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:17:20 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=B1hx1u15; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:49320 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJt1-0005qr-GU for patch@linaro.org; Wed, 03 Nov 2021 13:17:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35068) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiM-0003qy-4u for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:18 -0400 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]:56316) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiK-0003lZ-8L for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:17 -0400 Received: by mail-wm1-x334.google.com with SMTP id v127so2513692wme.5 for ; Wed, 03 Nov 2021 10:06:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=LhCMj49V450oWkOKk125VLrGAzkn15HxQfeeMwD8j/0=; b=B1hx1u15oK++G9Yz/L54MoPanwALIbmx7eoaAIGjY+OUDbQ6Jy0Tiu2Y/jQDWnImm9 pdkCEzfn01DvuZ41gleIEnQqZ2GUwLikCYjvoXkQL5wleDHdSOxKB508ihF0kq950d3P tH6VXlsJTX2G9NNRu75VFWR5Ag+eH+AuREnHc1GNdY18bsj+Zl09jky/8zuFN25k/UDV mqLkO42vQHYsp4beAPZmBQCdRTNKREKCRGxdh9fw4OwxWGg324j12vhqZNaLzIfPI5F4 w1EbMkkrdsnFF2JCgktythTw8ooMqO7eSDU5qp0mH9KX5laLfEaasC8lCyjntKiCQduc N4rg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=LhCMj49V450oWkOKk125VLrGAzkn15HxQfeeMwD8j/0=; b=EIqV7yZI2J3yEgz13iewc0+roUVqPUauwCcdMSL+BREN1fNUr/LEnSs959mB/u2Xx5 1ekvwiKyFKVf+rdh6q5yGRu/aRl2MQD9Y2CMWI+7X4eOqodXaWEapPm1AT8xAblRIWB8 7sFJGq4e55fkSpvfKTa0HAIGjrsRpCN+6LHBm3/kYtjN4U4zDR33HpVS6nPFkTDpS34H R6ZIhN2yl+Qa2Uw3Yja7Qz8B2R15ZdKANm/gGePXK/g/C7DrGxCX5v5Mo5/EGZeTt4N1 MyiziquOmP2eUx6S7cFym9Xt/MJNrDRr4GbT/fx2KjQdcWveZIezP65aTJZYETaMfNe7 8RGQ== X-Gm-Message-State: AOAM5335MFE2PSKWvgm8yBxH+1z72huG3td9QeofcZ2u6Z2ofycWKz3G I7WGkOTq+txfD1PxLEB4dF9vnTfegjEEVg== X-Received: by 2002:a1c:1f06:: with SMTP id f6mr16548230wmf.55.1635959173760; Wed, 03 Nov 2021 10:06:13 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id u15sm2812406wmq.12.2021.11.03.10.06.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 250B11FF9E; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 07/21] tests/docker: split PARTIAL into PARTIAL and VIRTUAL images Date: Wed, 3 Nov 2021 17:05:44 +0000 Message-Id: <20211103170558.717981-8-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::334; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x334.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Huth , richard.henderson@linaro.org, qemu-devel@nongnu.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe?= =?utf-8?q?_Mathieu-Daud=C3=A9?= , Willian Rampazzo , =?utf-8?q?Alex_Benn=C3=A9e?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" This is mostly to ensure we don't include the toolchain and bootstrap builds in DOCKER_IMAGES which is useful when verifying all images still build. Signed-off-by: Alex Bennée Reviewed-by: Willian Rampazzo Reviewed-by: Richard Henderson Message-Id: <20211026102234.3961636-10-alex.bennee@linaro.org> -- 2.30.2 diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include index e943ac33b0..5bbbaceed1 100644 --- a/tests/docker/Makefile.include +++ b/tests/docker/Makefile.include @@ -11,8 +11,10 @@ HOST_ARCH = $(if $(ARCH),$(ARCH),$(shell uname -m)) DOCKER_SUFFIX := .docker DOCKER_FILES_DIR := $(SRC_PATH)/tests/docker/dockerfiles # we don't run tests on intermediate images (used as base by another image) -DOCKER_PARTIAL_IMAGES := debian10 debian11 debian-bootstrap empty -DOCKER_IMAGES := $(sort $(notdir $(basename $(wildcard $(DOCKER_FILES_DIR)/*.docker)))) +DOCKER_PARTIAL_IMAGES := debian10 debian11 +# we don't directly build virtual images (they are used to build other images) +DOCKER_VIRTUAL_IMAGES := debian-bootstrap debian-toolchain empty +DOCKER_IMAGES := $(sort $(filter-out $(DOCKER_VIRTUAL_IMAGES), $(notdir $(basename $(wildcard $(DOCKER_FILES_DIR)/*.docker))))) DOCKER_TARGETS := $(patsubst %,docker-image-%,$(DOCKER_IMAGES)) # Use a global constant ccache directory to speed up repetitive builds DOCKER_CCACHE_DIR := $$HOME/.cache/qemu-docker-ccache @@ -204,7 +206,7 @@ DOCKER_PARTIAL_IMAGES += fedora-cris-cross # packages. # Expand all the pre-requistes for each docker image and test combination -$(foreach i,$(filter-out $(DOCKER_PARTIAL_IMAGES),$(DOCKER_IMAGES)), \ +$(foreach i,$(filter-out $(DOCKER_PARTIAL_IMAGES) $(DOCKER_VIRTUAL_IMAGES),$(DOCKER_IMAGES)), \ $(foreach t,$(DOCKER_TESTS), \ $(eval .PHONY: docker-$t@$i) \ $(eval docker-$t@$i: docker-image-$i docker-run-$t@$i) \ From patchwork Wed Nov 3 17:05:45 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516786 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp900993iml; Wed, 3 Nov 2021 10:18:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyWkBMiQyWEtG06781pg5fFEhAzJ9vZ49lXeiPT/T4/Ifr9F/YEBxVU4uZBTkmTMsyluAmn X-Received: by 2002:a05:6808:124b:: with SMTP id o11mr11552492oiv.1.1635959931484; Wed, 03 Nov 2021 10:18:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959931; cv=none; d=google.com; s=arc-20160816; b=ZVvYB9GJ2rZ3WqhowraXYo8LJKgTXV0FDJ6z7KJUPTycgXJpb8bR9YqjxPUSTypKi3 pvKHAAXFPyT01c+moSjNM/9pto3n6VSbUV6WgsACJfSyknipfBdU5LbXtPwFRPVStBcb iR0W9pwF1tlt2EyJ68ayRvCm8DzmOU5S1O7Ng+YjDtI+5l+GFF61++0BoiMFGpJSsLNt lGWsn+vPkXqG6v8WXKTaiJWrjq/ctDmBI9xHmupSJplozYHLBuZ8VssVuBOVEVKDcdrQ XCp6oeJxuRG4OiP/8rNFro/AIj5Op/9rgID9HGRSX2kfr5UMPLqwPpb7n9OdF13QnwCp K38A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=v1JcCS5FU5lQIgjMOx9iobI/E3bd5os0yVrUnngO3MA=; b=07pGRSUuChr/eU2GsXC+jqnoc2JfUwrTKjY6/sc+bNczMmBIlFVDAyyA8QbdDBjwtY mibwuFP5/28/wlvKuG8cMFT7uz++01wcXYQVwq78Ei0mnAcGJoWScw/MTSoyVmFC9DyJ z5X8tR4lvFEk6JF/2w8UD2C7P8a4C+M90OCg5BfT18yrI0j2RfHA35SsXesif/BV9D9R izVhTQtsCH57M2Q9DrPHtOSkHI6zVh/OngtOLOvIUkynVKCTmKhJaGidvjIGjlcBugiy UwiUexJO6Z5p/hih160FJsOsqli87gAsxypE7TciIXAzQe13IbusowYgszwmm7LfwTXR n7WQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=PPnQ6xVL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id g6si3888461otr.36.2021.11.03.10.18.51 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:18:51 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=PPnQ6xVL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:55502 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJuU-0001ZT-Su for patch@linaro.org; Wed, 03 Nov 2021 13:18:50 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35168) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiR-00047B-SJ for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:23 -0400 Received: from mail-wr1-x434.google.com ([2a00:1450:4864:20::434]:43900) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiQ-0003x6-8f for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:23 -0400 Received: by mail-wr1-x434.google.com with SMTP id t30so4596410wra.10 for ; Wed, 03 Nov 2021 10:06:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=v1JcCS5FU5lQIgjMOx9iobI/E3bd5os0yVrUnngO3MA=; b=PPnQ6xVLKofP4mDH7vGWOqXA9tRzQRCqS3lxPZ9EzRgTGfdVing9AFKyJfCZKtqzcG hFM98766+FhGVz4H4FK5MqNOX+ftmNrj4nexabgvTquOPWSAGzps/sFb+3sB1shnQ2wR eA9Af5VSXOzDmqoYp+YOgpCkU7JcHv4kHaEcFZQOCOboaYhoPRplqvRtV0yQotLsIx7S Stuh+/pc0S2n3gFBAZAzlvCn3SpHBUsqBDbkUfnsmwNPJ01WgDmUpOtDB6girZMwl2Hw R/FXQXeNglyr8WFTdAXZeySoM7G5NDDOfJ2HUEpRzwAygibBsTpkjWIgK4J2y0iFcV3L chBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=v1JcCS5FU5lQIgjMOx9iobI/E3bd5os0yVrUnngO3MA=; b=IxHHHshwvncJ+IRWY0WEBQpzMVmRrhmKTlNINRA/7/+H4cCYYsKJa/zAcTgXLbP8U/ nJdEAvE+odbkA3pvCEeWsLHZX+SwUe/tgIOpVP3o42jqIcfynGEKauGns9T35OleV4g5 11AK1BEMO82fjofeDF1HDxD9i7Rwe6VTGHZo8+tyVh60SR0EbF6ITmmNwx2srxO4Up+U 5lZ10z2NlrnaRT5pKAG6SUYS0pxSr+DnHcmZyQ1QwHBU0kMYjt2wAgenUeBuaieku6SE jyff58PnUYWJnaPVhfGk2YgxzpVlgT9b3o0VbD6wInCA+/dcZvhxuj4OR0FnPkkZKXfn ISRw== X-Gm-Message-State: AOAM5335bk0W4a2qzjQEBaBUacIg0ZMhZi3lJaybssq0Vn2SMBTP0hGT LqHrzPgnd+UcoJjx0CL99jsA4Q== X-Received: by 2002:adf:db47:: with SMTP id f7mr39845141wrj.113.1635959179675; Wed, 03 Nov 2021 10:06:19 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id m22sm642504wmq.38.2021.11.03.10.06.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 354701FF9F; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 08/21] tests/tcg: enable debian-nios2-cross for test building Date: Wed, 3 Nov 2021 17:05:45 +0000 Message-Id: <20211103170558.717981-9-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::434; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x434.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Edgar E. Iglesias" , =?utf-8?q?Alex_Benn?= =?utf-8?b?w6ll?= , richard.henderson@linaro.org, qemu-devel@nongnu.org, =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Now we have a nios2 test image we can start using it to build tests. However signal handling in nios2 is still broken so we disable the signals and linux-test tests that trigger the bug. Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Message-Id: <20211026102234.3961636-12-alex.bennee@linaro.org> -- 2.30.2 diff --git a/MAINTAINERS b/MAINTAINERS index a4d7a6f2e5..a2ad6f71b0 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -228,6 +228,7 @@ F: target/microblaze/ F: hw/microblaze/ F: disas/microblaze.c F: tests/docker/dockerfiles/debian-microblaze-cross.d/build-toolchain.sh +F: tests/tcg/nios2/Makefile.target MIPS TCG CPUs M: Philippe Mathieu-Daudé diff --git a/tests/tcg/configure.sh b/tests/tcg/configure.sh index d74ed50c18..9b76f58258 100755 --- a/tests/tcg/configure.sh +++ b/tests/tcg/configure.sh @@ -60,6 +60,7 @@ fi : ${cross_cc_mips64="mips64-linux-gnuabi64-gcc"} : ${cross_cc_mipsel="mipsel-linux-gnu-gcc"} : ${cross_cc_mips="mips-linux-gnu-gcc"} +: ${cross_cc_nios2="nios2-linux-gnu-gcc"} : ${cross_cc_ppc="powerpc-linux-gnu-gcc"} : ${cross_cc_cflags_ppc="-m32"} : ${cross_cc_ppc64="powerpc64-linux-gnu-gcc"} @@ -159,6 +160,11 @@ for target in $target_list; do container_image=debian-mips-cross container_cross_cc=mips-linux-gnu-gcc ;; + nios2-*) + container_hosts=x86_64 + container_image=debian-nios2-cross + container_cross_cc=nios2-linux-gnu-gcc + ;; ppc-*|ppc64abi32-*) container_hosts=x86_64 container_image=debian-powerpc-test-cross diff --git a/tests/tcg/nios2/Makefile.target b/tests/tcg/nios2/Makefile.target new file mode 100644 index 0000000000..b38e2352b7 --- /dev/null +++ b/tests/tcg/nios2/Makefile.target @@ -0,0 +1,11 @@ +# nios2 specific test tweaks + +# Currently nios2 signal handling is broken +run-signals: signals + $(call skip-test, $<, "BROKEN") +run-plugin-signals-with-%: + $(call skip-test, $<, "BROKEN") +run-linux-test: linux-test + $(call skip-test, $<, "BROKEN") +run-plugin-linux-test-with-%: + $(call skip-test, $<, "BROKEN") From patchwork Wed Nov 3 17:05:46 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516779 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp895761iml; Wed, 3 Nov 2021 10:13:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy+ZlcKvDGHgij0NFAdehHVXzcFimwcmx8xExxXKcOunGNYGn2YQc7qROr7bIHD36bS4LmT X-Received: by 2002:a05:6830:22ef:: with SMTP id t15mr32315949otc.368.1635959627184; Wed, 03 Nov 2021 10:13:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959627; cv=none; d=google.com; s=arc-20160816; b=Rzf0AKsN5bBI8cbPMM0rtHYBdCjsZRrX8BJzC9nFEY1jyfVegS+ui5+0XJp1qAh46g WrM13SMOAmb/pDngz7TLKNljjDRF2DklrZLQn3oudneFku3yMmz8o11Phw2rAa7p3S9E FM1Tzb2lMSASIIDCMKSqO7kmPPW4EPHXI6Dg0veCwqof+ybEFcGNJniqj9vtyF7CjEcu +789fopkOgwzB6r/T7sFJHDPVv6eDKFxOq7MVDqxe+s/P9s9/01Lw4u4mKm7POfxbFox urddl3sGW1IxJZTCOOar12qtJHgXURlE27FEUrepWE+ZW7eFk0u5ljpyofEp34QjHE3V R2lg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=iU3AMdEBCQKtdf9aSWlMsz42VXkzXjYt6iiEQb9B4Do=; b=YD55m4L/aTs4Cu/ezUb9/KgfgDpf7RTBZEtXbhHb1Jb5zXqkN2XkhsbV7T8fBNivbF 3k8Cyq2a/LEmYDDG6bJ7Odu/C1GVTf/h2TIY3OzHJawjR4DHpkiVMsW3SbkjrTWJThg8 2eDS3WRJYaIxpkIPJwtdj15w38flUwoK4x5IM0ZpTeG/VFdpjyaJwjhJTeIQ79Aq5JAj 7ToAhrGzlkNN8L8qfS2tA53PPXsR1l4T9r5X9lMZv12LMP8pNCAH88aEnkFNBa8RjAwx 6n1fzpDA36Te2GMk4DLmxDUEOKT8lRqw9g8zxwYCz+r546fD2QNNNQ44P0/Kh+X3V5gT XghA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=zGuVYFOc; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id j4si3671827otq.200.2021.11.03.10.13.47 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:13:47 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=zGuVYFOc; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:38238 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJpa-0006rh-Jq for patch@linaro.org; Wed, 03 Nov 2021 13:13:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35130) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiQ-00041N-8P for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:22 -0400 Received: from mail-wr1-x42d.google.com ([2a00:1450:4864:20::42d]:33287) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiM-0003rH-MN for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:21 -0400 Received: by mail-wr1-x42d.google.com with SMTP id d24so4692153wra.0 for ; Wed, 03 Nov 2021 10:06:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=iU3AMdEBCQKtdf9aSWlMsz42VXkzXjYt6iiEQb9B4Do=; b=zGuVYFOc3HJpop7VfI/x7i4REfCFvwpx512l7Rzutq//7PhOFDGgSHZtl92sddu36K 4WY+l97jCy1UNOtrIOWHTCBMYnilKcYuy/crJhfwZ9n7YoTuO/Q7+dHNO5NdYO6mazFf 6syJ3AIWtD7rQds5z8+a84r05ld3CTQU47yqgG6ldGITolVTGRlyrITcgMYtJnLSbEau HQPx4mqrWhDOzeEz46rGpfcXYtOY9mRbGnuMoGIlD5RZYOz2A/e/cbm1X8PU2DP+44pj v0szCfnIZB0dl8CwGQOxTTZsCQrq7Bn+8OmCgrd3pn1RkErkJUq9rTur/kQCmNgcXn/A yvBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=iU3AMdEBCQKtdf9aSWlMsz42VXkzXjYt6iiEQb9B4Do=; b=ZcSoZ6Bu+2nFWjEvNtzLO2wYX9dcP/uZYCW9orf8M+veLAfghEzSbiXKdFobKPp2SW 6xi2zk/pWQz6UwsgbaO9nmCZzDVK6KX09uVAsYd2yWR3bLwcCwX0WoPBa8e4ki5dtc0g A9jB4cI5AX+Rzs8zP+VcLKkzCd41sj9pSAQXXlp/UN4Z4ErM5emex7As87TjBG4mKaEf oQB+0ahOdp4CRDUcMdO7FYpr66p4Xr6s6BbMel67o84amusg4dVqiBRVSjK4wnZ4wugb dflroXixpPwbWsL9cb4tk/6xc4TvBof2dcqgFPaIJqCslbasVNtKCLV1v7Typ7MZ0iUf L8sA== X-Gm-Message-State: AOAM533GnvPxPZVoU7g5R3LItLN/3HbVqdI0uBsOk8LyqTqQ6dGwSH8B X5OYZ/Cc7rEBGS43TgQUiQ/VUA== X-Received: by 2002:a5d:4890:: with SMTP id g16mr59196846wrq.10.1635959177312; Wed, 03 Nov 2021 10:06:17 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id g3sm2836052wri.45.2021.11.03.10.06.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 4A3721FFA5; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 09/21] ebpf: really include it only in system emulators Date: Wed, 3 Nov 2021 17:05:46 +0000 Message-Id: <20211103170558.717981-10-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42d; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42d.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Paolo Bonzini , richard.henderson@linaro.org, qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Paolo Bonzini eBPF libraries are being included in user emulators, which is useless and also breaks --static compilation if a shared library for libbpf is present in the system. Reported-by: Alex Bennée Signed-off-by: Paolo Bonzini Signed-off-by: Alex Bennée Message-Id: <20211012162252.263933-1-pbonzini@redhat.com> Reviewed-by: Richard Henderson Reviewed-bt: Warner Losh Message-Id: <20211026102234.3961636-13-alex.bennee@linaro.org> -- 2.30.2 diff --git a/meson.build b/meson.build index 26c58123e9..fa2e6cceff 100644 --- a/meson.build +++ b/meson.build @@ -2610,8 +2610,6 @@ subdir('bsd-user') subdir('linux-user') subdir('ebpf') -common_ss.add(libbpf) - specific_ss.add_all(when: 'CONFIG_BSD_USER', if_true: bsd_user_ss) linux_user_ss.add(files('thunk.c')) From patchwork Wed Nov 3 17:05:47 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516787 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp901984iml; Wed, 3 Nov 2021 10:19:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyG770v4gmgCvRacj6nZ/v80xExl8WjLge//qz3jdhGcMMS8iWgQsyqFxKAhEFZRf7qyAtp X-Received: by 2002:a05:6830:2b2b:: with SMTP id l43mr15458294otv.45.1635959991672; Wed, 03 Nov 2021 10:19:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959991; cv=none; d=google.com; s=arc-20160816; b=umLvs6uWM38ieRk2Ypcxr41Ip3CW5xvW3t+I6/22FnUb+DSJl1o5lwW6L6S/Ak5JiU +dwjtuNRc5xZYWac3ufsa6x+6wwGcMtcz6boPkR9u4ds6vUf1vvSOIhVIs/H+XP7aNVN gCTAxMBTM+hgSPHWu+MpryLtJuWAZFj7Mku3bOUsJIiwsFrozHDQWZ6aErwVikpgRZky 7thheZ40s+UKBx2+SiKgtiYJwSUu3QuFTi3xOIuX1IkD9Q3UszhZmIIp0fbU1TWjDuOP SUypmhOf6zNlHBt78slE+N5C9Mhg5idQl37YfJ0XQXP9esBOb4uZvwfZK0eaxs7XG9CE wf7Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=VsOqJgkZe7opATttK+pb9o0h59FfEOaRn+sckMRUzQ8=; b=ejVnutk9V30uVA3/cN+XyV/r13TqJUJg4ES8OEuEJRLIZt6dhdCIigdb4InyZgPhYw vnTBbfikTaTl6Dg3rUrG2eTqusVxNvvZxmnsnV71aSzr/tGjoi1+vPhBpAdV/t7dHDgL 9a6ypaO/eDXqIGLOHP01vXBUziqJwjqw8gfVIl7xytu73V3CKgTDSEJhH8CJ1RfSQuyE kNZJO4GGxK2kqbhcTmDHJkYFVTyJkTk17aQGeuY9iZo+o39sD3Q5bRVOqVmCBq2nNl0P LUbZv4HvKlpC1iTz76bhfQYxpCfxNzCKwpIFMs7rbSbjFXsvDlk6OnsKdRg13cafnR8T sC1w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=pYzaaqWT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id w196si3078508oiw.201.2021.11.03.10.19.51 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:19:51 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=pYzaaqWT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:58078 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJvS-0003LD-OI for patch@linaro.org; Wed, 03 Nov 2021 13:19:51 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35114) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiO-0003xv-RV for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:20 -0400 Received: from mail-wm1-x332.google.com ([2a00:1450:4864:20::332]:40471) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiL-0003nA-So for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:20 -0400 Received: by mail-wm1-x332.google.com with SMTP id j128-20020a1c2386000000b003301a98dd62so5152314wmj.5 for ; Wed, 03 Nov 2021 10:06:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=VsOqJgkZe7opATttK+pb9o0h59FfEOaRn+sckMRUzQ8=; b=pYzaaqWTP4FJJKTLCUF0setiPezIBfA8lHmre57bj9uNQ0BFJxrcDm1RTMeqchL7qm Jo7Oz50S8rZh5tGhdYOX1H9bmFV5W2lIKDgJm+eRJwmu/UNppwdm0fI5AXrhX+FRFx3L CRvm9ilcaHDoy10p4Mg83Xn1hP62awyOBnBujzLQ6VOx3pomESCKVTa/m+XNOE3DAtyg j/GsuHOa/X/x9C4EYDk3e4pkkxMqQDX3nov1S2I2LdmWfvyt0Rm4buZfvI2IA/O8x/kz 3NdpVqTsont/3OYZKjzWF35baXy3Njr2z1ROu7YikDqOGUCi1OaoU7/Qu7RdKJyfsMG7 OehQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=VsOqJgkZe7opATttK+pb9o0h59FfEOaRn+sckMRUzQ8=; b=XQyHJypnKQHCjDswOIXC0nhkgSpv32F6HR0HPVTcmja0XsaUm03IuNlbCgMIoH6NNU Kp3sqvkXfhvsJFQxmN0+x6Ja65gTEcMyeLWO8MDEsJCN7F7qwSf+tXDsLScuIVezY+1b akZ1JVLEX+Ew6ELyIqWnS2pKs0d2hyi5VzT5FRAaL22yx8qH6LUkQn362XFEBfmrpqqd /dDGmZTs7gG/9D2TNvwbCoIR0egTYoUnzo8rBwbmK4Nl8hsG5Tnj8tV9u/kZvIgzfA8B IoiHSwsLHwNIHl4gXWuhmV0LEoup9iFboZVUoKM74ifz1tzsU18+LR2HYsU3UOV6LcK1 9oVQ== X-Gm-Message-State: AOAM533c4cT0OGG9yDpqwe3P5PIkVJA+IfWPoSLdeJZhOh6bI3SMpVf5 fOKVIqBHj9DFwpiUfUmjrJIGDw== X-Received: by 2002:a05:600c:2195:: with SMTP id e21mr16914411wme.187.1635959176475; Wed, 03 Nov 2021 10:06:16 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id d24sm2333154wmb.35.2021.11.03.10.06.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 557211FFA6; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 10/21] plugins/cache: freed heap-allocated mutexes Date: Wed, 3 Nov 2021 17:05:47 +0000 Message-Id: <20211103170558.717981-11-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::332; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x332.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: richard.henderson@linaro.org, qemu-devel@nongnu.org, =?utf-8?q?Philipp?= =?utf-8?q?e_Mathieu-Daud=C3=A9?= , Alexandre Iooss , Mahmoud Mandour , =?utf-8?q?Alex_Benn=C3=A9e?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Mahmoud Mandour Signed-off-by: Mahmoud Mandour Signed-off-by: Alex Bennée Message-Id: <20210810134844.166490-2-ma.mandourr@gmail.com> Reviewed-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20211026102234.3961636-14-alex.bennee@linaro.org> -- 2.30.2 diff --git a/contrib/plugins/cache.c b/contrib/plugins/cache.c index a1e03ca882..a255e26e25 100644 --- a/contrib/plugins/cache.c +++ b/contrib/plugins/cache.c @@ -614,6 +614,9 @@ static void plugin_exit(qemu_plugin_id_t id, void *p) caches_free(dcaches); caches_free(icaches); + g_free(dcache_locks); + g_free(icache_locks); + g_hash_table_destroy(miss_ht); } From patchwork Wed Nov 3 17:05:48 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516775 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp893836iml; Wed, 3 Nov 2021 10:11:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwDX5Q35hZUJG5Fr0AiLyKYX8O9QmmCePMPJ60IZRVs/J2Y2OR7w/Oct91h3lXk/TjLKqVO X-Received: by 2002:aca:1219:: with SMTP id 25mr11161035ois.149.1635959517508; Wed, 03 Nov 2021 10:11:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959517; cv=none; d=google.com; s=arc-20160816; b=TzS56Spi9j//x/sCiVCk03boaef8g3LlmZGHA+cG1cNUa7b4yy4kfZpiOK2bAs6Ors HKiriX9GB0fC4oGZdKhzbXx5iFT2vf4jaC/ax39l1s/AJIlO4zouE/nE/E/n/ZEVSbzb ASHQEtzobQrvfSEV4/I4WmaqqpLgfk+/vCqB3cI1VE1rh0/1lKbwZmHeUEqMu1Evcqwm BlNzV9L/LRZjlS48KXQJbCKM2kAhzKDGo9zQXWoto68QoSsfBsQ/+mITgvNLKn8NGcY+ WokeY4eCkHmrKbGPq9tdCYu6zBhUKZcNGCn94aA5AL6bveoqeliwSzKBLrWbmHV3rhrA D6fw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=PJG6gdZB2EJbdv/Yjd6QTnykYCxkitP2mIWHAYJwzvc=; b=Nowr+d4+3u/Uylga3xz85+VL/fzNi4fe0hwBOWckmDNQTdo3SXCl7qbX0gLk2+sYx6 Fhk7rZIa+ddFk7+gopGFCanfF46POORs7OAzagHSnj22xiEnU+8aLPaPG4PZbEeqeZaf /APL5uZBGFxWL15pvlfjIfGCl4ne4EjTfsCAfl7cv4CKlNea8B/CIV+Xn9NuvnJJZYo+ dWArm/nKqIg5s7MULis2BuhGE6yho+bqNSY9B2+gLHgtwr5fAkhhzDE2moNrJ+vUYPBf oNMI1+Aqf1pF91Mm9aS6EPYUNyjYRBHyW34Ji9MhqYyNEiUO3l2cUN+EKlMwo0Bd/nVH dpJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=uBJ4nGAV; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id k14si3567936otb.41.2021.11.03.10.11.57 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:11:57 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=uBJ4nGAV; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:58258 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJno-0001MB-Tk for patch@linaro.org; Wed, 03 Nov 2021 13:11:56 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35106) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiP-0003wf-HP for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:21 -0400 Received: from mail-wm1-x335.google.com ([2a00:1450:4864:20::335]:44719) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiL-0003lh-GT for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:20 -0400 Received: by mail-wm1-x335.google.com with SMTP id c71-20020a1c9a4a000000b0032cdcc8cbafso2360663wme.3 for ; Wed, 03 Nov 2021 10:06:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=PJG6gdZB2EJbdv/Yjd6QTnykYCxkitP2mIWHAYJwzvc=; b=uBJ4nGAVOVeCNoicnZ1acgbSifQwQeWdwpp1a4nxEtVRgPDpHwhyZZWAomwWiNYpIq VKg7i3C1AXDwMGZ+wuhNivf+Iw6Fsxs268osRhOg+V9A4Ga/asLB3ONRbZLpFho6dCcG 7BTiqiYZMvsaBHY/O/ZONFaX+y23b9/2ObFz9L4d9qjzfbo5qJBr62YkE2bmNGzOFp7D ChCh+9qW6Eqz4DOqUoQw7L6+WyOai2KwMZk/LmHeNGDswwQ1zDEwpdZcXwq3zh0R/S8f DIyxH6u1Gg7mqpsbArieb32MpWuVj5Pz+zh//t+5Mtq7mT8s7qGXB48ILeJx/x62yc8w NbJA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=PJG6gdZB2EJbdv/Yjd6QTnykYCxkitP2mIWHAYJwzvc=; b=jCsUOrrOSrdEenv+pMmjFiafElY6Zth1gp5uFMifnDbS6mbKlzbtPiFwDuEGkaCJ9k CdFSgBBt+xurzeaebWec6TH0Gh69z9yN+9HKphmXx5ZCIK60UHhPhp7Tds44C+AJSESW dTLnVkX0lCPJkFzpzfqItub+6PhkYz3QjnXe7TKzJwe4h18EuUb8Shlb4fgvrgZNiras bWk9RsNhY4qp5nZDvgjjJlF/gToiLgGzJTTc4eZD4aahcvkz0BcKu3kitUrNx8d3SW7E MoUOIhn0tKODZZicppeupoY0DDUXyyHwTGtKjjSvrGobM/O5viv/Jb1Ohdq7jr26okv+ yjOA== X-Gm-Message-State: AOAM530vUzeiEZmJLY0BHXUUcMlUR+1S1r6QZwQ7zvrdB1Etr14E2bX3 CyXnMitGSWnwNk1i+H4KNw/UCQ== X-Received: by 2002:a05:600c:202:: with SMTP id 2mr16580058wmi.167.1635959174613; Wed, 03 Nov 2021 10:06:14 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id v185sm5952132wme.35.2021.11.03.10.06.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 6ED211FFA9; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 11/21] plugins/cache: implement unified L2 cache emulation Date: Wed, 3 Nov 2021 17:05:48 +0000 Message-Id: <20211103170558.717981-12-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::335; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x335.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Mahmoud Mandour , richard.henderson@linaro.org, qemu-devel@nongnu.org, Alexandre Iooss Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Mahmoud Mandour This adds an implementation of a simple L2 configuration, in which a unified L2 cache (stores both blocks of instructions and data) is maintained for each core separately, with no inter-core interaction taken in account. The L2 cache is used as a backup for L1 and is only accessed if the wanted block does not exist in L1. In terms of multi-threaded user-space emulation, the same approximation of L1 is done, a static number of caches is maintained, and each and every memory access initiated by a thread will have to go through one of the available caches. An atomic increment is used to maintain the number of L2 misses per instruction. The default cache parameters of L2 caches is: 2MB cache size 16-way associativity 64-byte blocks Signed-off-by: Mahmoud Mandour Signed-off-by: Alex Bennée Message-Id: <20210810134844.166490-3-ma.mandourr@gmail.com> Message-Id: <20211026102234.3961636-15-alex.bennee@linaro.org> -- 2.30.2 diff --git a/contrib/plugins/cache.c b/contrib/plugins/cache.c index a255e26e25..908c967a09 100644 --- a/contrib/plugins/cache.c +++ b/contrib/plugins/cache.c @@ -82,8 +82,9 @@ typedef struct { char *disas_str; const char *symbol; uint64_t addr; - uint64_t dmisses; - uint64_t imisses; + uint64_t l1_dmisses; + uint64_t l1_imisses; + uint64_t l2_misses; } InsnData; void (*update_hit)(Cache *cache, int set, int blk); @@ -93,15 +94,20 @@ void (*metadata_init)(Cache *cache); void (*metadata_destroy)(Cache *cache); static int cores; -static Cache **dcaches, **icaches; +static Cache **l1_dcaches, **l1_icaches; +static Cache **l2_ucaches; -static GMutex *dcache_locks; -static GMutex *icache_locks; +static GMutex *l1_dcache_locks; +static GMutex *l1_icache_locks; +static GMutex *l2_ucache_locks; -static uint64_t all_dmem_accesses; -static uint64_t all_imem_accesses; -static uint64_t all_imisses; -static uint64_t all_dmisses; +static uint64_t l1_dmem_accesses; +static uint64_t l1_imem_accesses; +static uint64_t l1_imisses; +static uint64_t l1_dmisses; + +static uint64_t l2_mem_accesses; +static uint64_t l2_misses; static int pow_of_two(int num) { @@ -382,6 +388,7 @@ static void vcpu_mem_access(unsigned int vcpu_index, qemu_plugin_meminfo_t info, struct qemu_plugin_hwaddr *hwaddr; int cache_idx; InsnData *insn; + bool hit_in_l1; hwaddr = qemu_plugin_get_hwaddr(info, vaddr); if (hwaddr && qemu_plugin_hwaddr_is_io(hwaddr)) { @@ -391,14 +398,29 @@ static void vcpu_mem_access(unsigned int vcpu_index, qemu_plugin_meminfo_t info, effective_addr = hwaddr ? qemu_plugin_hwaddr_phys_addr(hwaddr) : vaddr; cache_idx = vcpu_index % cores; - g_mutex_lock(&dcache_locks[cache_idx]); - if (!access_cache(dcaches[cache_idx], effective_addr)) { + g_mutex_lock(&l1_dcache_locks[cache_idx]); + hit_in_l1 = access_cache(l1_dcaches[cache_idx], effective_addr); + if (!hit_in_l1) { + insn = (InsnData *) userdata; + __atomic_fetch_add(&insn->l1_dmisses, 1, __ATOMIC_SEQ_CST); + l1_dcaches[cache_idx]->misses++; + } + l1_dcaches[cache_idx]->accesses++; + g_mutex_unlock(&l1_dcache_locks[cache_idx]); + + if (hit_in_l1) { + /* No need to access L2 */ + return; + } + + g_mutex_lock(&l2_ucache_locks[cache_idx]); + if (!access_cache(l2_ucaches[cache_idx], effective_addr)) { insn = (InsnData *) userdata; - __atomic_fetch_add(&insn->dmisses, 1, __ATOMIC_SEQ_CST); - dcaches[cache_idx]->misses++; + __atomic_fetch_add(&insn->l2_misses, 1, __ATOMIC_SEQ_CST); + l2_ucaches[cache_idx]->misses++; } - dcaches[cache_idx]->accesses++; - g_mutex_unlock(&dcache_locks[cache_idx]); + l2_ucaches[cache_idx]->accesses++; + g_mutex_unlock(&l2_ucache_locks[cache_idx]); } static void vcpu_insn_exec(unsigned int vcpu_index, void *userdata) @@ -406,18 +428,34 @@ static void vcpu_insn_exec(unsigned int vcpu_index, void *userdata) uint64_t insn_addr; InsnData *insn; int cache_idx; + bool hit_in_l1; insn_addr = ((InsnData *) userdata)->addr; cache_idx = vcpu_index % cores; - g_mutex_lock(&icache_locks[cache_idx]); - if (!access_cache(icaches[cache_idx], insn_addr)) { + g_mutex_lock(&l1_icache_locks[cache_idx]); + hit_in_l1 = access_cache(l1_icaches[cache_idx], insn_addr); + if (!hit_in_l1) { + insn = (InsnData *) userdata; + __atomic_fetch_add(&insn->l1_imisses, 1, __ATOMIC_SEQ_CST); + l1_icaches[cache_idx]->misses++; + } + l1_icaches[cache_idx]->accesses++; + g_mutex_unlock(&l1_icache_locks[cache_idx]); + + if (hit_in_l1) { + /* No need to access L2 */ + return; + } + + g_mutex_lock(&l2_ucache_locks[cache_idx]); + if (!access_cache(l2_ucaches[cache_idx], insn_addr)) { insn = (InsnData *) userdata; - __atomic_fetch_add(&insn->imisses, 1, __ATOMIC_SEQ_CST); - icaches[cache_idx]->misses++; + __atomic_fetch_add(&insn->l2_misses, 1, __ATOMIC_SEQ_CST); + l2_ucaches[cache_idx]->misses++; } - icaches[cache_idx]->accesses++; - g_mutex_unlock(&icache_locks[cache_idx]); + l2_ucaches[cache_idx]->accesses++; + g_mutex_unlock(&l2_ucache_locks[cache_idx]); } static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) @@ -493,30 +531,28 @@ static void caches_free(Cache **caches) } } -static int dcmp(gconstpointer a, gconstpointer b) -{ - InsnData *insn_a = (InsnData *) a; - InsnData *insn_b = (InsnData *) b; - - return insn_a->dmisses < insn_b->dmisses ? 1 : -1; -} - -static void append_stats_line(GString *line, uint64_t daccess, uint64_t dmisses, - uint64_t iaccess, uint64_t imisses) +static void append_stats_line(GString *line, uint64_t l1_daccess, + uint64_t l1_dmisses, uint64_t l1_iaccess, + uint64_t l1_imisses, uint64_t l2_access, + uint64_t l2_misses) { - double dmiss_rate, imiss_rate; + double l1_dmiss_rate, l1_imiss_rate, l2_miss_rate; - dmiss_rate = ((double) dmisses) / (daccess) * 100.0; - imiss_rate = ((double) imisses) / (iaccess) * 100.0; + l1_dmiss_rate = ((double) l1_dmisses) / (l1_daccess) * 100.0; + l1_imiss_rate = ((double) l1_imisses) / (l1_iaccess) * 100.0; + l2_miss_rate = ((double) l2_misses) / (l2_access) * 100.0; g_string_append_printf(line, "%-14lu %-12lu %9.4lf%% %-14lu %-12lu" - " %9.4lf%%\n", - daccess, - dmisses, - daccess ? dmiss_rate : 0.0, - iaccess, - imisses, - iaccess ? imiss_rate : 0.0); + " %9.4lf%% %-12lu %-11lu %10.4lf%%\n", + l1_daccess, + l1_dmisses, + l1_daccess ? l1_dmiss_rate : 0.0, + l1_iaccess, + l1_imisses, + l1_iaccess ? l1_imiss_rate : 0.0, + l2_access, + l2_misses, + l2_access ? l2_miss_rate : 0.0); } static void sum_stats(void) @@ -525,43 +561,66 @@ static void sum_stats(void) g_assert(cores > 1); for (i = 0; i < cores; i++) { - all_imisses += icaches[i]->misses; - all_dmisses += dcaches[i]->misses; - all_imem_accesses += icaches[i]->accesses; - all_dmem_accesses += dcaches[i]->accesses; + l1_imisses += l1_icaches[i]->misses; + l1_dmisses += l1_dcaches[i]->misses; + l1_imem_accesses += l1_icaches[i]->accesses; + l1_dmem_accesses += l1_dcaches[i]->accesses; + + l2_misses += l2_ucaches[i]->misses; + l2_mem_accesses += l2_ucaches[i]->accesses; } } +static int dcmp(gconstpointer a, gconstpointer b) +{ + InsnData *insn_a = (InsnData *) a; + InsnData *insn_b = (InsnData *) b; + + return insn_a->l1_dmisses < insn_b->l1_dmisses ? 1 : -1; +} + static int icmp(gconstpointer a, gconstpointer b) { InsnData *insn_a = (InsnData *) a; InsnData *insn_b = (InsnData *) b; - return insn_a->imisses < insn_b->imisses ? 1 : -1; + return insn_a->l1_imisses < insn_b->l1_imisses ? 1 : -1; +} + +static int l2_cmp(gconstpointer a, gconstpointer b) +{ + InsnData *insn_a = (InsnData *) a; + InsnData *insn_b = (InsnData *) b; + + return insn_a->l2_misses < insn_b->l2_misses ? 1 : -1; } static void log_stats(void) { int i; - Cache *icache, *dcache; + Cache *icache, *dcache, *l2_cache; g_autoptr(GString) rep = g_string_new("core #, data accesses, data misses," " dmiss rate, insn accesses," - " insn misses, imiss rate\n"); + " insn misses, imiss rate," + " l2 accesses, l2 misses," + " l2 miss rate\n"); for (i = 0; i < cores; i++) { g_string_append_printf(rep, "%-8d", i); - dcache = dcaches[i]; - icache = icaches[i]; + dcache = l1_dcaches[i]; + icache = l1_icaches[i]; + l2_cache = l2_ucaches[i]; append_stats_line(rep, dcache->accesses, dcache->misses, - icache->accesses, icache->misses); + icache->accesses, icache->misses, l2_cache->accesses, + l2_cache->misses); } if (cores > 1) { sum_stats(); g_string_append_printf(rep, "%-8s", "sum"); - append_stats_line(rep, all_dmem_accesses, all_dmisses, - all_imem_accesses, all_imisses); + append_stats_line(rep, l1_dmem_accesses, l1_dmisses, + l1_imem_accesses, l1_imisses, l2_mem_accesses, l2_misses); } g_string_append(rep, "\n"); @@ -585,7 +644,7 @@ static void log_top_insns(void) if (insn->symbol) { g_string_append_printf(rep, " (%s)", insn->symbol); } - g_string_append_printf(rep, ", %ld, %s\n", insn->dmisses, + g_string_append_printf(rep, ", %ld, %s\n", insn->l1_dmisses, insn->disas_str); } @@ -598,7 +657,20 @@ static void log_top_insns(void) if (insn->symbol) { g_string_append_printf(rep, " (%s)", insn->symbol); } - g_string_append_printf(rep, ", %ld, %s\n", insn->imisses, + g_string_append_printf(rep, ", %ld, %s\n", insn->l1_imisses, + insn->disas_str); + } + + miss_insns = g_list_sort(miss_insns, l2_cmp); + g_string_append_printf(rep, "%s", "\naddress, L2 misses, instruction\n"); + + for (curr = miss_insns, i = 0; curr && i < limit; i++, curr = curr->next) { + insn = (InsnData *) curr->data; + g_string_append_printf(rep, "0x%" PRIx64, insn->addr); + if (insn->symbol) { + g_string_append_printf(rep, " (%s)", insn->symbol); + } + g_string_append_printf(rep, ", %ld, %s\n", insn->l2_misses, insn->disas_str); } @@ -611,11 +683,13 @@ static void plugin_exit(qemu_plugin_id_t id, void *p) log_stats(); log_top_insns(); - caches_free(dcaches); - caches_free(icaches); + caches_free(l1_dcaches); + caches_free(l1_icaches); + caches_free(l2_ucaches); - g_free(dcache_locks); - g_free(icache_locks); + g_free(l1_dcache_locks); + g_free(l1_icache_locks); + g_free(l2_ucache_locks); g_hash_table_destroy(miss_ht); } @@ -647,19 +721,24 @@ int qemu_plugin_install(qemu_plugin_id_t id, const qemu_info_t *info, int argc, char **argv) { int i; - int iassoc, iblksize, icachesize; - int dassoc, dblksize, dcachesize; + int l1_iassoc, l1_iblksize, l1_icachesize; + int l1_dassoc, l1_dblksize, l1_dcachesize; + int l2_assoc, l2_blksize, l2_cachesize; limit = 32; sys = info->system_emulation; - dassoc = 8; - dblksize = 64; - dcachesize = dblksize * dassoc * 32; + l1_dassoc = 8; + l1_dblksize = 64; + l1_dcachesize = l1_dblksize * l1_dassoc * 32; + + l1_iassoc = 8; + l1_iblksize = 64; + l1_icachesize = l1_iblksize * l1_iassoc * 32; - iassoc = 8; - iblksize = 64; - icachesize = iblksize * iassoc * 32; + l2_assoc = 16; + l2_blksize = 64; + l2_cachesize = l2_assoc * l2_blksize * 2048; policy = LRU; @@ -668,21 +747,27 @@ int qemu_plugin_install(qemu_plugin_id_t id, const qemu_info_t *info, for (i = 0; i < argc; i++) { char *opt = argv[i]; if (g_str_has_prefix(opt, "iblksize=")) { - iblksize = g_ascii_strtoll(opt + 9, NULL, 10); + l1_iblksize = g_ascii_strtoll(opt + 9, NULL, 10); } else if (g_str_has_prefix(opt, "iassoc=")) { - iassoc = g_ascii_strtoll(opt + 7, NULL, 10); + l1_iassoc = g_ascii_strtoll(opt + 7, NULL, 10); } else if (g_str_has_prefix(opt, "icachesize=")) { - icachesize = g_ascii_strtoll(opt + 11, NULL, 10); + l1_icachesize = g_ascii_strtoll(opt + 11, NULL, 10); } else if (g_str_has_prefix(opt, "dblksize=")) { - dblksize = g_ascii_strtoll(opt + 9, NULL, 10); + l1_dblksize = g_ascii_strtoll(opt + 9, NULL, 10); } else if (g_str_has_prefix(opt, "dassoc=")) { - dassoc = g_ascii_strtoll(opt + 7, NULL, 10); + l1_dassoc = g_ascii_strtoll(opt + 7, NULL, 10); } else if (g_str_has_prefix(opt, "dcachesize=")) { - dcachesize = g_ascii_strtoll(opt + 11, NULL, 10); + l1_dcachesize = g_ascii_strtoll(opt + 11, NULL, 10); } else if (g_str_has_prefix(opt, "limit=")) { limit = g_ascii_strtoll(opt + 6, NULL, 10); } else if (g_str_has_prefix(opt, "cores=")) { cores = g_ascii_strtoll(opt + 6, NULL, 10); + } else if (g_str_has_prefix(opt, "l2cachesize=")) { + l2_cachesize = g_ascii_strtoll(opt + 6, NULL, 10); + } else if (g_str_has_prefix(opt, "l2blksize=")) { + l2_blksize = g_ascii_strtoll(opt + 6, NULL, 10); + } else if (g_str_has_prefix(opt, "l2assoc=")) { + l2_assoc = g_ascii_strtoll(opt + 6, NULL, 10); } else if (g_str_has_prefix(opt, "evict=")) { gchar *p = opt + 6; if (g_strcmp0(p, "rand") == 0) { @@ -703,24 +788,33 @@ int qemu_plugin_install(qemu_plugin_id_t id, const qemu_info_t *info, policy_init(); - dcaches = caches_init(dblksize, dassoc, dcachesize); - if (!dcaches) { - const char *err = cache_config_error(dblksize, dassoc, dcachesize); + l1_dcaches = caches_init(l1_dblksize, l1_dassoc, l1_dcachesize); + if (!l1_dcaches) { + const char *err = cache_config_error(l1_dblksize, l1_dassoc, l1_dcachesize); fprintf(stderr, "dcache cannot be constructed from given parameters\n"); fprintf(stderr, "%s\n", err); return -1; } - icaches = caches_init(iblksize, iassoc, icachesize); - if (!icaches) { - const char *err = cache_config_error(iblksize, iassoc, icachesize); + l1_icaches = caches_init(l1_iblksize, l1_iassoc, l1_icachesize); + if (!l1_icaches) { + const char *err = cache_config_error(l1_iblksize, l1_iassoc, l1_icachesize); fprintf(stderr, "icache cannot be constructed from given parameters\n"); fprintf(stderr, "%s\n", err); return -1; } - dcache_locks = g_new0(GMutex, cores); - icache_locks = g_new0(GMutex, cores); + l2_ucaches = caches_init(l2_blksize, l2_assoc, l2_cachesize); + if (!l2_ucaches) { + const char *err = cache_config_error(l2_blksize, l2_assoc, l2_cachesize); + fprintf(stderr, "L2 cache cannot be constructed from given parameters\n"); + fprintf(stderr, "%s\n", err); + return -1; + } + + l1_dcache_locks = g_new0(GMutex, cores); + l1_icache_locks = g_new0(GMutex, cores); + l2_ucache_locks = g_new0(GMutex, cores); qemu_plugin_register_vcpu_tb_trans_cb(id, vcpu_tb_trans); qemu_plugin_register_atexit_cb(id, plugin_exit, NULL); From patchwork Wed Nov 3 17:05:49 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516790 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp904110iml; Wed, 3 Nov 2021 10:22:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwXUzg8OeegcAwbhP3TC1zQLiM1IhkNL9EQ0G/uvTeRiUckm2x2FDEJIm2/aJSCkLmWff9L X-Received: by 2002:a9d:7597:: with SMTP id s23mr18791386otk.31.1635960125295; Wed, 03 Nov 2021 10:22:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635960125; cv=none; d=google.com; s=arc-20160816; b=QCG9yHJaga5Ru/uZcxeW4+IWrnj5sTGBY57GpBZWfl8Mt48pzh2+S1qdYm67FAJDQq Sidwt8wRfMlG1WC8hMWGh5rch37NManAlnLHyMKjpfe74HqjmDHO5T/h9hwwBcoROkU5 JnWDbF+CsgzddnjvTdD1t+K2VmhEAxFfAXzDF55sL8ondU9BYg5LoRmeNd9s2hI3A/NH R6dvX7znE8VCqcE0uvj6Jnckrdnf4hkXVafyaTKSZYLHVSGcPo/SFt6WpXiD0IbJK7MG zrGTlq5shU4swgTxH4oO16jEvO73eWSL9kfoC1DnzCXo47bVeX9oeQu/a+RCEF0SefbA CgQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=rK81rLaycn75GU/7jkMSQO8ubSWMfzaA7wAThWraCKQ=; b=Cuk5KO00L93zOq7ozY3OQctxMz1fGeRN4zkXPCDvtqxwjhQfUSXBaENbrprntM2LJT 2oMWxCHeUncFvsngzql8AA1sAVNkrH8SSl1H6PSjMDa/Kl0TQz+KXbkYlSAA47Br/rc9 bLV8WytQ4HDccPlV6ZXALMBfXHJBROhXNzYSAXv7g6iJm7QXkvHLyd77bh7whRBjirnO mf4vYdbCkfqBj4J/wVZkOyOmMNuxoV9PXWpIeaBeZmPyyWwDCpHfmNwYKVFWtEHRD6Ud V2KEK2KAM5XUPZW+tj5TgIMmbQL0rn5OZ8E5L/O+6Om1cV25pMCBCtMRiJ7HnFHCxzWm SuBw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=KkZzVEsg; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id x20si5434237oiv.290.2021.11.03.10.22.05 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:22:05 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=KkZzVEsg; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:38506 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJxc-0000ln-Ij for patch@linaro.org; Wed, 03 Nov 2021 13:22:04 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37090) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJoG-0005Sb-Ae for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:24 -0400 Received: from mail-wr1-x431.google.com ([2a00:1450:4864:20::431]:44911) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJoD-00074Y-VS for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:23 -0400 Received: by mail-wr1-x431.google.com with SMTP id d13so4625460wrf.11 for ; Wed, 03 Nov 2021 10:12:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=rK81rLaycn75GU/7jkMSQO8ubSWMfzaA7wAThWraCKQ=; b=KkZzVEsghPmvFIB0mj4Nsty7/IzoL2ZJklu/F47q0bK3s7plDiC7gtV7EEwkyegzS7 nMf6eWz/iitxYhlrKZcgahbf05D8TlU5rFOBcsUhMvfXxBM8WBCTk2Rrr0r635kHcYK/ AJU6oYKz0Jq7/NagsPYqAwrGGcNYaf10GB906g8EGAt9qOU1RvbDZVu15CgU8XYZ6vVg IxbzHRA3ExnTc7OtApK6yUwGT746j+YPk0+TJ/uNxBdulR1iLKrIz8A1QxdZYW3OPf3O l3Mmoq5kIuJHJmLGsf8hHHtBTNFYxWBtIXSsb3qg1V1nheBLMddrhMooCxERLJldti7I S/iw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=rK81rLaycn75GU/7jkMSQO8ubSWMfzaA7wAThWraCKQ=; b=OhG+eSaHGokfuwk5TP9fItkEzrPc/yMkePOY/Lnjm/rUL5c4mZ7PNzF1jYp5G9wlt/ TbTFitdoiOR6Q+gEf1d0BV9Wf33RAuyubDeVSGSJo831F3GC16LJg4y67C8TED89uJx1 ZTlZY+lZMtPwC5Ebmp46z17290h3hVE3OTk9QP8/qubz0JOFQ8VfAHpNEJ+8+pptN6aW enHIEDEuthKM2tLNo7G/lk4VIdQoMcW61kxowYjHr+KCv5drKECVMO902JwN4yEIMwtk 5Q2vOCkKH7pHIJi4/wne1upzfSvRDCrGYSbQaVv+QMUF2Zi9fO0/dU0CiOh+wWyuKoNC uDnw== X-Gm-Message-State: AOAM533740ljHMirfEMlLR0+p1Al/mrGs4rh/mRRXiICYN3tBydnmBBv 5M8eWQ2xqkUJrPHmK6we6bxUqnXJbzcZ6g== X-Received: by 2002:a05:6000:1868:: with SMTP id d8mr21410229wri.285.1635959540584; Wed, 03 Nov 2021 10:12:20 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id u16sm5719960wmc.21.2021.11.03.10.12.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:12:18 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 84FBC1FFAA; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 12/21] plugins/cache: split command line arguments into name and value Date: Wed, 3 Nov 2021 17:05:49 +0000 Message-Id: <20211103170558.717981-13-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::431; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x431.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Mahmoud Mandour , richard.henderson@linaro.org, qemu-devel@nongnu.org, Alexandre Iooss Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Mahmoud Mandour This way of handling args is more lenient and sets a better framework to parse boolean command line arguments. Signed-off-by: Mahmoud Mandour Signed-off-by: Alex Bennée Message-Id: <20210810134844.166490-4-ma.mandourr@gmail.com> Message-Id: <20211026102234.3961636-16-alex.bennee@linaro.org> -- 2.30.2 diff --git a/contrib/plugins/cache.c b/contrib/plugins/cache.c index 908c967a09..ff325beb9f 100644 --- a/contrib/plugins/cache.c +++ b/contrib/plugins/cache.c @@ -11,6 +11,8 @@ #include +#define STRTOLL(x) g_ascii_strtoll(x, NULL, 10) + QEMU_PLUGIN_EXPORT int qemu_plugin_version = QEMU_PLUGIN_VERSION; static enum qemu_plugin_mem_rw rw = QEMU_PLUGIN_MEM_RW; @@ -746,35 +748,36 @@ int qemu_plugin_install(qemu_plugin_id_t id, const qemu_info_t *info, for (i = 0; i < argc; i++) { char *opt = argv[i]; - if (g_str_has_prefix(opt, "iblksize=")) { - l1_iblksize = g_ascii_strtoll(opt + 9, NULL, 10); - } else if (g_str_has_prefix(opt, "iassoc=")) { - l1_iassoc = g_ascii_strtoll(opt + 7, NULL, 10); - } else if (g_str_has_prefix(opt, "icachesize=")) { - l1_icachesize = g_ascii_strtoll(opt + 11, NULL, 10); - } else if (g_str_has_prefix(opt, "dblksize=")) { - l1_dblksize = g_ascii_strtoll(opt + 9, NULL, 10); - } else if (g_str_has_prefix(opt, "dassoc=")) { - l1_dassoc = g_ascii_strtoll(opt + 7, NULL, 10); - } else if (g_str_has_prefix(opt, "dcachesize=")) { - l1_dcachesize = g_ascii_strtoll(opt + 11, NULL, 10); - } else if (g_str_has_prefix(opt, "limit=")) { - limit = g_ascii_strtoll(opt + 6, NULL, 10); - } else if (g_str_has_prefix(opt, "cores=")) { - cores = g_ascii_strtoll(opt + 6, NULL, 10); - } else if (g_str_has_prefix(opt, "l2cachesize=")) { - l2_cachesize = g_ascii_strtoll(opt + 6, NULL, 10); - } else if (g_str_has_prefix(opt, "l2blksize=")) { - l2_blksize = g_ascii_strtoll(opt + 6, NULL, 10); - } else if (g_str_has_prefix(opt, "l2assoc=")) { - l2_assoc = g_ascii_strtoll(opt + 6, NULL, 10); - } else if (g_str_has_prefix(opt, "evict=")) { - gchar *p = opt + 6; - if (g_strcmp0(p, "rand") == 0) { + g_autofree char **tokens = g_strsplit(opt, "=", 2); + + if (g_strcmp0(tokens[0], "iblksize") == 0) { + l1_iblksize = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "iassoc") == 0) { + l1_iassoc = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "icachesize") == 0) { + l1_icachesize = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "dblksize") == 0) { + l1_dblksize = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "dassoc") == 0) { + l1_dassoc = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "dcachesize") == 0) { + l1_dcachesize = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "limit") == 0) { + limit = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "cores") == 0) { + cores = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "l2cachesize") == 0) { + l2_cachesize = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "l2blksize") == 0) { + l2_blksize = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "l2assoc") == 0) { + l2_assoc = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "evict") == 0) { + if (g_strcmp0(tokens[1], "rand") == 0) { policy = RAND; - } else if (g_strcmp0(p, "lru") == 0) { + } else if (g_strcmp0(tokens[1], "lru") == 0) { policy = LRU; - } else if (g_strcmp0(p, "fifo") == 0) { + } else if (g_strcmp0(tokens[1], "fifo") == 0) { policy = FIFO; } else { fprintf(stderr, "invalid eviction policy: %s\n", opt); From patchwork Wed Nov 3 17:05:50 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516777 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp895247iml; Wed, 3 Nov 2021 10:13:19 -0700 (PDT) X-Google-Smtp-Source: ABdhPJze5ewfHnoS/UgiN5bopLOsWtsCE6jzrzIR82PmVEL+rOrsnG+JvF1TC496JZWY9XTYaxFs X-Received: by 2002:a9d:4f1a:: with SMTP id d26mr31846511otl.65.1635959599820; Wed, 03 Nov 2021 10:13:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959599; cv=none; d=google.com; s=arc-20160816; b=U5DCZAuPsD3XiGchGXpq8rhuUQaSJ/9HkMLju9COZEuA4UujkrxistKlgnrcp6r8QP qKW5pEqriNYpYsuA7HgDw2pSYetDpxVH0S/41OAFCPmylMsHEJY13cxVHrYvK48ppjal xyeXI/WigJUp3XoeBwGif+QFCtp3kurjFzXOUU5jirXZD0G/BqWkmIxsvpPVKaipHnbt 2LimRmumXDQuZcv6FNq0j984bfQEQWW8GwA4vITFk5rrSp7C66mN701zY/4+FUpHGnPV o7AKAAT1IxxhMmhpV8wHa/lFfENK/D5Ri5hPsRJs+1PM0E05CmkfPhBAIPu88e9wV6He oVDA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=m3OZRZ6+tmKnw7GakdlKZKV5dmhTWdnq+opHPpGWJrY=; b=zc0dDMq7e5uEj7kQgFrNQU+fEbPA417d/biDnNuDgHSmyHCHVBHbUiRVBipTddZeth n/jO16WjrB6xdLDztCaRNCb/A648R2/06K/8ly6rHgGBL4RQe1wTsHkroN129EUsv4FX D37rqak7GN5gYGxOYWl8HvxFO42sArJx0QmrtqrDB6HsY+68a8MEZDx8a4v6aI/sGKbf UC4Lm+CnKintpbQxikEXwPa4yuGIt6+OlBeDYN6ErkHFQo/ceE/coCcJ2XH3nQio9AoG yzR+L6vgkG4rImCsMM75FPBzV/WM+yNJKK0Fhd4fP0wm+1h+pYyAyD8O7kzNrdMnsAPa soEw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=AHnyp3VA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id c35si5097436otu.6.2021.11.03.10.13.19 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:13:19 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=AHnyp3VA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:35652 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJp9-00058O-8e for patch@linaro.org; Wed, 03 Nov 2021 13:13:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36994) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJo8-000519-PG for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:16 -0400 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]:44755) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJo6-00073E-Oq for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:16 -0400 Received: by mail-wm1-x334.google.com with SMTP id c71-20020a1c9a4a000000b0032cdcc8cbafso2373253wme.3 for ; Wed, 03 Nov 2021 10:12:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=m3OZRZ6+tmKnw7GakdlKZKV5dmhTWdnq+opHPpGWJrY=; b=AHnyp3VAe0vHGV2nC6gIWb6AF+UHDQ9JwQGeaHTn/hHC8iIDTmm1mrhEo9QyOZN9Vc MwoUQk/C5mCF3v51juyFmh9Azr5gKOL818MVqipInrFuPUv87VT58L4M28xcTcZTI9G6 Uk4ZU+k5cUzI5eJwa/rcVhYmmQMVpxhXCsOESJ75EA0ymHfpYc+fipgEr7XOh9IpXNqI moZHigQDcituR2FNd1wChAb4WNtstvq55soTMVbg54XqL9RF6VDHBte/rQ1CFRkB7rSG i5K8TMnWbZvP4hwncKxv1K8Egq3vo2fmbDu8OBe2xo6/T+yg34BS9NmKwfNEu3MefrfH oIdA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=m3OZRZ6+tmKnw7GakdlKZKV5dmhTWdnq+opHPpGWJrY=; b=HLRVkvfzfChngzq3xSJvbR9V/7EdIwL/O5PT2/gAdI+f0Coh/0YE8G1tHw4KfFLMJ9 VOzN/PR2XkNhZTwOOWId56WHP7JvVBYePYHiGMmgXO2jmGlHCNOs/Oa6CmtBB+DNV5tq C1IkIiU7XDA+f+BQW5ytjwDrkEbzg4lObbtDxBba19EpdMop/JWhkbIXBBDvraSR7N0M 11yA8O1HVtNzxKkpAgVZCOC3dDRJf09yiufm0Fsw85zDEiE3BK9vAwa3ibJtm9+kFT1t R+AjSP2v0mxHNFOEmPLy5tNJ6hmXwyU5QvVSWE0DF3XjG3X3NS/pSoisDPB+XAYTHQmi ihiA== X-Gm-Message-State: AOAM530+Ha4HF9oWe9MFaON6JcaqaISBSrDAlgyxZS9aYBcu1RhyFhne rJsTmGPmfP7RzZD2Mn/gxY2KNQ== X-Received: by 2002:a7b:cb97:: with SMTP id m23mr16493532wmi.182.1635959532931; Wed, 03 Nov 2021 10:12:12 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id f6sm2415170wmj.40.2021.11.03.10.12.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:12:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 9BFD11FFAB; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 13/21] plugins/cache: make L2 emulation optional through args Date: Wed, 3 Nov 2021 17:05:50 +0000 Message-Id: <20211103170558.717981-14-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::334; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x334.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Mahmoud Mandour , richard.henderson@linaro.org, qemu-devel@nongnu.org, Alexandre Iooss Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Mahmoud Mandour By default L2 is not enabled and is enabled by either using the newly-introduced "l2" boolean argument, or by setting any of the L2 cache parameters using args. On specifying "l2=on", the default cache configuration is used. Signed-off-by: Mahmoud Mandour Signed-off-by: Alex Bennée Message-Id: <20210810134844.166490-5-ma.mandourr@gmail.com> Message-Id: <20211026102234.3961636-17-alex.bennee@linaro.org> -- 2.30.2 diff --git a/contrib/plugins/cache.c b/contrib/plugins/cache.c index ff325beb9f..b9226e7c40 100644 --- a/contrib/plugins/cache.c +++ b/contrib/plugins/cache.c @@ -97,6 +97,8 @@ void (*metadata_destroy)(Cache *cache); static int cores; static Cache **l1_dcaches, **l1_icaches; + +static bool use_l2; static Cache **l2_ucaches; static GMutex *l1_dcache_locks; @@ -410,7 +412,7 @@ static void vcpu_mem_access(unsigned int vcpu_index, qemu_plugin_meminfo_t info, l1_dcaches[cache_idx]->accesses++; g_mutex_unlock(&l1_dcache_locks[cache_idx]); - if (hit_in_l1) { + if (hit_in_l1 || !use_l2) { /* No need to access L2 */ return; } @@ -445,7 +447,7 @@ static void vcpu_insn_exec(unsigned int vcpu_index, void *userdata) l1_icaches[cache_idx]->accesses++; g_mutex_unlock(&l1_icache_locks[cache_idx]); - if (hit_in_l1) { + if (hit_in_l1 || !use_l2) { /* No need to access L2 */ return; } @@ -542,19 +544,25 @@ static void append_stats_line(GString *line, uint64_t l1_daccess, l1_dmiss_rate = ((double) l1_dmisses) / (l1_daccess) * 100.0; l1_imiss_rate = ((double) l1_imisses) / (l1_iaccess) * 100.0; - l2_miss_rate = ((double) l2_misses) / (l2_access) * 100.0; g_string_append_printf(line, "%-14lu %-12lu %9.4lf%% %-14lu %-12lu" - " %9.4lf%% %-12lu %-11lu %10.4lf%%\n", + " %9.4lf%%", l1_daccess, l1_dmisses, l1_daccess ? l1_dmiss_rate : 0.0, l1_iaccess, l1_imisses, - l1_iaccess ? l1_imiss_rate : 0.0, - l2_access, - l2_misses, - l2_access ? l2_miss_rate : 0.0); + l1_iaccess ? l1_imiss_rate : 0.0); + + if (use_l2) { + l2_miss_rate = ((double) l2_misses) / (l2_access) * 100.0; + g_string_append_printf(line, " %-12lu %-11lu %10.4lf%%", + l2_access, + l2_misses, + l2_access ? l2_miss_rate : 0.0); + } + + g_string_append(line, "\n"); } static void sum_stats(void) @@ -568,8 +576,10 @@ static void sum_stats(void) l1_imem_accesses += l1_icaches[i]->accesses; l1_dmem_accesses += l1_dcaches[i]->accesses; - l2_misses += l2_ucaches[i]->misses; - l2_mem_accesses += l2_ucaches[i]->accesses; + if (use_l2) { + l2_misses += l2_ucaches[i]->misses; + l2_mem_accesses += l2_ucaches[i]->accesses; + } } } @@ -604,25 +614,31 @@ static void log_stats(void) g_autoptr(GString) rep = g_string_new("core #, data accesses, data misses," " dmiss rate, insn accesses," - " insn misses, imiss rate," - " l2 accesses, l2 misses," - " l2 miss rate\n"); + " insn misses, imiss rate"); + + if (use_l2) { + g_string_append(rep, ", l2 accesses, l2 misses, l2 miss rate"); + } + + g_string_append(rep, "\n"); for (i = 0; i < cores; i++) { g_string_append_printf(rep, "%-8d", i); dcache = l1_dcaches[i]; icache = l1_icaches[i]; - l2_cache = l2_ucaches[i]; + l2_cache = use_l2 ? l2_ucaches[i] : NULL; append_stats_line(rep, dcache->accesses, dcache->misses, - icache->accesses, icache->misses, l2_cache->accesses, - l2_cache->misses); + icache->accesses, icache->misses, + l2_cache ? l2_cache->accesses : 0, + l2_cache ? l2_cache->misses : 0); } if (cores > 1) { sum_stats(); g_string_append_printf(rep, "%-8s", "sum"); append_stats_line(rep, l1_dmem_accesses, l1_dmisses, - l1_imem_accesses, l1_imisses, l2_mem_accesses, l2_misses); + l1_imem_accesses, l1_imisses, + l2_cache ? l2_mem_accesses : 0, l2_cache ? l2_misses : 0); } g_string_append(rep, "\n"); @@ -663,6 +679,10 @@ static void log_top_insns(void) insn->disas_str); } + if (!use_l2) { + goto finish; + } + miss_insns = g_list_sort(miss_insns, l2_cmp); g_string_append_printf(rep, "%s", "\naddress, L2 misses, instruction\n"); @@ -676,6 +696,7 @@ static void log_top_insns(void) insn->disas_str); } +finish: qemu_plugin_outs(rep->str); g_list_free(miss_insns); } @@ -687,11 +708,14 @@ static void plugin_exit(qemu_plugin_id_t id, void *p) caches_free(l1_dcaches); caches_free(l1_icaches); - caches_free(l2_ucaches); g_free(l1_dcache_locks); g_free(l1_icache_locks); - g_free(l2_ucache_locks); + + if (use_l2) { + caches_free(l2_ucaches); + g_free(l2_ucache_locks); + } g_hash_table_destroy(miss_ht); } @@ -767,11 +791,19 @@ int qemu_plugin_install(qemu_plugin_id_t id, const qemu_info_t *info, } else if (g_strcmp0(tokens[0], "cores") == 0) { cores = STRTOLL(tokens[1]); } else if (g_strcmp0(tokens[0], "l2cachesize") == 0) { + use_l2 = true; l2_cachesize = STRTOLL(tokens[1]); } else if (g_strcmp0(tokens[0], "l2blksize") == 0) { + use_l2 = true; l2_blksize = STRTOLL(tokens[1]); } else if (g_strcmp0(tokens[0], "l2assoc") == 0) { + use_l2 = true; l2_assoc = STRTOLL(tokens[1]); + } else if (g_strcmp0(tokens[0], "l2") == 0) { + if (!qemu_plugin_bool_parse(tokens[0], tokens[1], &use_l2)) { + fprintf(stderr, "boolean argument parsing failed: %s\n", opt); + return -1; + } } else if (g_strcmp0(tokens[0], "evict") == 0) { if (g_strcmp0(tokens[1], "rand") == 0) { policy = RAND; @@ -807,8 +839,8 @@ int qemu_plugin_install(qemu_plugin_id_t id, const qemu_info_t *info, return -1; } - l2_ucaches = caches_init(l2_blksize, l2_assoc, l2_cachesize); - if (!l2_ucaches) { + l2_ucaches = use_l2 ? caches_init(l2_blksize, l2_assoc, l2_cachesize) : NULL; + if (!l2_ucaches && use_l2) { const char *err = cache_config_error(l2_blksize, l2_assoc, l2_cachesize); fprintf(stderr, "L2 cache cannot be constructed from given parameters\n"); fprintf(stderr, "%s\n", err); @@ -817,7 +849,7 @@ int qemu_plugin_install(qemu_plugin_id_t id, const qemu_info_t *info, l1_dcache_locks = g_new0(GMutex, cores); l1_icache_locks = g_new0(GMutex, cores); - l2_ucache_locks = g_new0(GMutex, cores); + l2_ucache_locks = use_l2 ? g_new0(GMutex, cores) : NULL; qemu_plugin_register_vcpu_tb_trans_cb(id, vcpu_tb_trans); qemu_plugin_register_atexit_cb(id, plugin_exit, NULL); From patchwork Wed Nov 3 17:05:51 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516773 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp890854iml; Wed, 3 Nov 2021 10:09:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzAR1Ttyce+KS/m8m55zEedLR/dlcbU/+LwplUEDBpfTD4ki3oCVRjWP/buU8/C/vQEI+eJ X-Received: by 2002:a9d:2002:: with SMTP id n2mr8973240ota.362.1635959363633; Wed, 03 Nov 2021 10:09:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959363; cv=none; d=google.com; s=arc-20160816; b=RYtrrB77ADf2A/3QSPWYb/WdV0d+Vbf9BEmf3qRkzHJwDh+vS20JbHispXtG/C7JqM QjQ/Lvg2hJm+zZ4LfCjfOJCZv/lgd40m8LXgl4Yh3PLJau/4RrqC+Gxns7b0UpZlBwlz jtSBYv9Vlt7MRW9k2IzS58aR3HvXLe6JCRAwO+Y3/ILQdf53gAYlUNwWc8PoZcEouoxr nPC+A5BrCb5TUh9rlGbScoX3M+oGTB5cVW6LxVKI06R0/zwm2StQPUxeI0sDEHjPzXt0 KW9HBuMjoXudb1oJUyuwpmtoy6IQQ0YMc9NryBjKmt7+Bv4gWRydjngJi5eDuZl1ki03 csrA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=RHcYTC5lNCjrZHkm+0rV2h3yz1/+QOqms6mqHEoCWSE=; b=jzTaA0ZmNCTm92QE1VWWtZ4KEmt4l8gMo9XLRQjks3G05DrcEzUIb6xRzr8E/vxR3O 7ZDTC5nqByIP3R6Yi3cZeyoQFjNyUn5fCiJDOhS1r6Ptd8Ky77cli/Ka8GVAHOMDV4Ha i4RKUmSHzN6KXXpNmn6w+85vZ7lOQULqHmrluF85Ii8llLYZkMsDSMbuPzPPwQyeZdGi hckOMBpoovgfVHeifa3J4IBQ+5S1Agv9mPLGOhnOaRzNxaRrRNXdUkYY1kPVO+X1xNep Gh3pLzfNJrmlTHu2hFmalr3FHscHWG2JLn69BGFBatjSCJSxLnW8rK3BqCVrmHq3+UCm G5Kg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Xxj0EVrb; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id s10si4524448otv.278.2021.11.03.10.09.23 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:09:23 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Xxj0EVrb; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:51702 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJlJ-0005Ht-VO for patch@linaro.org; Wed, 03 Nov 2021 13:09:22 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35174) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJiS-0004B9-OF for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:25 -0400 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]:34597) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJiQ-0003xV-DT for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:06:24 -0400 Received: by mail-wr1-x432.google.com with SMTP id d5so4651539wrc.1 for ; Wed, 03 Nov 2021 10:06:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=RHcYTC5lNCjrZHkm+0rV2h3yz1/+QOqms6mqHEoCWSE=; b=Xxj0EVrbIWFh3dwOXMXBLs4amXEhGGfsGWYMZOke2otHIO2efFfQxpHz2NXKqOZAcW psJAm+aqLddTTqLCOoTkV65UY2WKs1SzFaccUnPVUJnOzYJ9Pzk2AqQvlS/nWcuxXeWC ycftZBbmJ2jjglqstwMfnu3bANBIh4APE22W+lybcmC680ZEYj62EcpQfp5xbzw5Cqu3 o6RX/DPGk3kkMrhxXWyahkRIFv6SvA2iZHqqQ8gHyBTzFiKlfJx4ME6el7gOxcXJo6ZJ Bcjeb1pY6J+QKWuN+DBoXy8Rw9u9lwvrrqsGoFyL6lHMs1p09IwQHmelTTSDcX/3azwv hR5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=RHcYTC5lNCjrZHkm+0rV2h3yz1/+QOqms6mqHEoCWSE=; b=0Pw+RJooDcoR9epb9hXdSTHm4cINZ4e+uzS2i6N6vX5vNImHY05cCvYW8TRJE0EHpQ w9+ThsP/wS1XcbWMwOxaWuNKFmmlmoJTgfQTHYBp5WC6tdHMBjHDWtoCClNQzXyIVjMT EdpNKbpLdvCWRKs1TwLgjEm+aXIgIy+2j9+/+7qZtnWcViVcYnNjKmLit089EXG0Wuqf eI81IzX4AZ9TxEnipdphcCST6sa+Wlq0+shYBXml3D3GWB++ZoNtyNQoRxEBRsAY2nTD Ylp2fpgFnsj3SN9vQgT2RAElS9hea50rWRHRU9liJ+DQl/Tt4NNf6rYLBDLHW6AnKR4k Orpw== X-Gm-Message-State: AOAM533BU5k3eXAP/jkg5ZffdUVy2oftBeSnJ34lIZK2WkWVdAGHM13s swLQ/VMlYzoYuvcGIYs9hzJ/CnVAE6XYdg== X-Received: by 2002:a5d:46cb:: with SMTP id g11mr40342135wrs.26.1635959181044; Wed, 03 Nov 2021 10:06:21 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id l7sm3449809wry.86.2021.11.03.10.06.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:06:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id A840C1FFAC; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 14/21] docs/tcg-plugins: add L2 arguments to cache docs Date: Wed, 3 Nov 2021 17:05:51 +0000 Message-Id: <20211103170558.717981-15-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::432; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x432.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Mahmoud Mandour , richard.henderson@linaro.org, qemu-devel@nongnu.org, Alexandre Iooss Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Mahmoud Mandour cache plugin now allows optional L2 per-core cache emulation that can be configured through plugin arguments, this commit adds this functionality to the docs. While I'm at it, I editted the bullet point for cache plugin to say: contrib/plugins/cache.c instead of contrib/plugins/cache to match other plugins. Signed-off-by: Mahmoud Mandour Signed-off-by: Alex Bennée Message-Id: <20210810134844.166490-6-ma.mandourr@gmail.com> Message-Id: <20211026102234.3961636-18-alex.bennee@linaro.org> -- 2.30.2 diff --git a/docs/devel/tcg-plugins.rst b/docs/devel/tcg-plugins.rst index 842ae01a4c..59a7d838be 100644 --- a/docs/devel/tcg-plugins.rst +++ b/docs/devel/tcg-plugins.rst @@ -361,8 +361,9 @@ which will output an execution trace following this structure:: - contrib/plugins/cache.c -Cache modelling plugin that measures the performance of a given cache -configuration when a given working set is run:: +Cache modelling plugin that measures the performance of a given L1 cache +configuration, and optionally a unified L2 per-core cache when a given working +set is run:: qemu-x86_64 -plugin ./contrib/plugins/libcache.so \ -d plugin -D cache.log ./tests/tcg/x86_64-linux-user/float_convs @@ -420,3 +421,18 @@ The plugin has a number of arguments, all of them are optional: Sets the number of cores for which we maintain separate icache and dcache. (default: for linux-user, N = 1, for full system emulation: N = cores available to guest) + + * l2=on + + Simulates a unified L2 cache (stores blocks for both instructions and data) + using the default L2 configuration (cache size = 2MB, associativity = 16-way, + block size = 64B). + + * l2cachesize=N + * l2blksize=B + * l2assoc=A + + L2 cache configuration arguments. They specify the cache size, block size, and + associativity of the L2 cache, respectively. Setting any of the L2 + configuration arguments implies ``l2=on``. + (default: N = 2097152 (2MB), B = 64, A = 16) From patchwork Wed Nov 3 17:05:52 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516792 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp904754iml; Wed, 3 Nov 2021 10:22:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxYMUwU2GQH2WuN2ToPGCUh8CBukUX2XHfq8wwbpMn9ALKHmdhCKxwcFIHNAjYSVR75Dkpk X-Received: by 2002:a05:6830:55b:: with SMTP id l27mr33773575otb.309.1635960163396; Wed, 03 Nov 2021 10:22:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635960163; cv=none; d=google.com; s=arc-20160816; b=CWuqXYOgitAAuvNQ0n65sMwYf4guhkRXsIXyZlgE3orUff1pKTfSJbu+9PUaeHZIVx BxDumflTDpbhBGH3qJ4mBEUkjNcLUuCI+btVKppWOa1r9jDOzCfCCgELx5CO8yC0KoEj 74dYn5/s9TjQMoNKqmYOh/3FZkkfHxHLJkQRqDsEHCoboGxxY+ap4H9jW4zks64y3kWP tio9ORIOmxdpIVR5Bmwg7+tOrHtsjdNMnIcnfD4YMVEbaDc8rio3OFS0bC53vAOCz3fL 1xkR14d52XBBCaTn8E/14twUhaGI71W01lB3kpZllg+y3R2zOaQ/M6ODX5Lslvyirpga i2bQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=e6CwJoaEBKjKMYgYgC8qHcZ4bffXqP81dXgxRXrPAtQ=; b=AzSpMlPZ/fFOy8aDTIDknimSOpvnbQIYJ+TZ2RA86QHFQ9gBfhBoaeQ+kWiGikP2xi TGaO+hp/yahIC8WtvXAZXCUHKSHWJv65KloJXDEOnvg2evreDympxGmdYiPqDsIYZS7w WjjA9D2rvfUDfBZRY4pGWPkIm+0WER2OgpEYZ33PIvrYcw2TlgKqtUuewbpnsD2iii+H usycr/LHEqfpMwaTb7bY6/jk6sUS5Qg5hT2bs2hjTmbfzhEtuuYAlOmpBOc7tpwphsSc Tn7pZvM7V3sQmoI9E3rmkKohj6y8rja0LEqGlb/GuyQCiy6bTtCGGC/PkoSdkemnR+pp dP4A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=evIiUVtA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id y16si3435151otk.236.2021.11.03.10.22.43 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:22:43 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=evIiUVtA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:41154 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJyE-0002aV-TW for patch@linaro.org; Wed, 03 Nov 2021 13:22:42 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37138) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJoI-0005cp-Qs for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:26 -0400 Received: from mail-wr1-x42d.google.com ([2a00:1450:4864:20::42d]:40728) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJoG-00074t-Hg for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:26 -0400 Received: by mail-wr1-x42d.google.com with SMTP id r8so4632414wra.7 for ; Wed, 03 Nov 2021 10:12:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=e6CwJoaEBKjKMYgYgC8qHcZ4bffXqP81dXgxRXrPAtQ=; b=evIiUVtAEpCKDO2ru74x1vhM30z6THoYQrEBhGxB5c93JfFR0iq/KxMmL/E8mgh/LD Tdn0L8t5IZJ2/F9lyssesxL6TowrrJSq/VZw2R30+h70TxbcO2C7ClnFMscfGc2yY8+U OoJLi9KSRzhjchUfbwpw6RlPH9ngrnUPR/Sl2ICujRWMbOakM5AnSMFozXiT+Z2pQ5Fb MEOIs80o4reFbrXzcit0eRQAx8rPK7TvJItL/kXEfjP4rlbwJw/8W7R6kSlnvo59xI/r z6sn1Q71fS/l7mP0ZEGKNB6Rv0/l2MgmShgQFqcighThtu/NTVSnQIbgaWIRXw50KJJn ntMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=e6CwJoaEBKjKMYgYgC8qHcZ4bffXqP81dXgxRXrPAtQ=; b=pHhCMrYYhmMIH833wD4c6dC/0/GFkU3qXElRaETgG6hs3gEurMT/aZVervgdvm7VuX p2KmMnpkZw7J5s1Y/sxAKJ3HrpEmi6/uIoJ6RlxPAY5ma+/VoKI8L85n0puSdoqXcipk OLSVc+V30/bGEjsiTV0Uyv30OCl7dcxPU7cbPs1CgskSWfh+1ZGr3ytPL3YL+3y2t+/s dqOfxQEQULvmFuBFF1sBThBOVj88pjaYjVGWCOZH/qzBjQPrw8RbvXvunjeao3f7alte J/8aFyxGU+08pEqZNTn3TbItV6zXbOE+eeVBMOkPDrvZ0WW3pyY83CfSqXUAUJWEjwHG vdQA== X-Gm-Message-State: AOAM530iQ0eL2akph1+CxGxviV8Ku4jmknQqLldJEZ80N+UuGXHALH2x h3iUtxCOoDIUAX5bPEIDoSc/Dg== X-Received: by 2002:a05:6000:1842:: with SMTP id c2mr31651325wri.301.1635959543152; Wed, 03 Nov 2021 10:12:23 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id 10sm7013942wme.27.2021.11.03.10.12.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:12:18 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id C2C6D1FFAE; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 15/21] chardev: don't exit() straight away on C-a x Date: Wed, 3 Nov 2021 17:05:52 +0000 Message-Id: <20211103170558.717981-16-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42d; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42d.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , richard.henderson@linaro.org, qemu-devel@nongnu.org, =?utf-8?q?Lukas_?= =?utf-8?q?J=C3=BCnger?= , Paolo Bonzini , =?utf-8?q?Marc-Andr=C3=A9_Lureau?= , =?utf-8?q?Alex_Benn=C3=A9e?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" While there are a number of uses in the code-base of the exit(0) pattern it gets in the way of clean exit which can do all of it's house-keeping. In particular it was reported that you can crash plugins this way because TCG can still be running on other threads when the atexit callback is called. Use qmp_quit() instead which takes care of some housekeeping before triggering the shutdown. Signed-off-by: Alex Bennée Reported-by: Lukas Jünger Reviewed-by: Marc-André Lureau Reviewed-by: Philippe Mathieu-Daudé Acked-by: Paolo Bonzini Message-Id: <20211026102234.3961636-19-alex.bennee@linaro.org> -- 2.30.2 diff --git a/chardev/char-mux.c b/chardev/char-mux.c index ada0c6866f..ee2d47b20d 100644 --- a/chardev/char-mux.c +++ b/chardev/char-mux.c @@ -28,6 +28,7 @@ #include "qemu/option.h" #include "chardev/char.h" #include "sysemu/block-backend.h" +#include "qapi/qapi-commands-control.h" #include "chardev-internal.h" /* MUX driver for serial I/O splitting */ @@ -157,7 +158,7 @@ static int mux_proc_byte(Chardev *chr, MuxChardev *d, int ch) { const char *term = "QEMU: Terminated\n\r"; qemu_chr_write_all(chr, (uint8_t *)term, strlen(term)); - exit(0); + qmp_quit(NULL); break; } case 's': diff --git a/stubs/qmp-quit.c b/stubs/qmp-quit.c new file mode 100644 index 0000000000..a3ff47f7bd --- /dev/null +++ b/stubs/qmp-quit.c @@ -0,0 +1,8 @@ +#include "qemu/osdep.h" +#include "qapi/qapi-commands-control.h" +#include "qapi/qmp/dispatch.h" + +void qmp_quit(Error **errp) +{ + g_assert_not_reached(); +} diff --git a/stubs/meson.build b/stubs/meson.build index f6aa3aa94f..71469c1d50 100644 --- a/stubs/meson.build +++ b/stubs/meson.build @@ -31,6 +31,7 @@ stub_ss.add(files('pci-bus.c')) stub_ss.add(files('qemu-timer-notify-cb.c')) stub_ss.add(files('qmp_memory_device.c')) stub_ss.add(files('qmp-command-available.c')) +stub_ss.add(files('qmp-quit.c')) stub_ss.add(files('qtest.c')) stub_ss.add(files('ram-block.c')) stub_ss.add(files('ramfb.c')) From patchwork Wed Nov 3 17:05:53 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516789 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp902846iml; Wed, 3 Nov 2021 10:20:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyR4Bc6PIC8pvd8ybYqUgA0/hMcSw6EDh0InOwuWDHIKFJrjb/F1uOzYnrwAxaKjwiIx0ZE X-Received: by 2002:a05:6830:2463:: with SMTP id x35mr17082286otr.246.1635960047313; Wed, 03 Nov 2021 10:20:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635960047; cv=none; d=google.com; s=arc-20160816; b=BYEAZa1IzVfyaSopPyxg4aEslVcGu9nXz1NuawsH8z6NQ5/wq2f7D2QxHB1IBfCZze 0kSqctJfwmCDSEnktTt/+9hux8bnijceb4vwqU48uf669nT41evJBi9kG15TUpn7kjXJ Wmzfuz7a+Cb0tIUuh5gdGm4UWlM+9p2/GDtm25PZWt7dhBFQrkIcdMT4XhhwE6eKrSw1 NhvMyO21RFhx7of6BGWj/xPBD0p5mBsQ61WtQnePHlFannzKagabrvzXdKE6vxmbaYgV 8ypNBQBY7KhCdkY0p3XRUMu8d60paOwK6fOXQNdiOe7MjqO1u7BQNkZ+CFVc1GJ44JN2 vULw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=yyRfS3iCiw1/tG9HJBOoGZjbjgeiOJQ9Q/Je/hZdaRg=; b=lIbmo3e1jGXw9ofmhtw5PIM5z+Fptz4jVXMYqM6tQMaTNgdMJ5q7gTOvKct8nnyVb7 OyEPJvyrqYqpAhPCqGRFlXol20PLS53FHZmTcPA+jn5oAsCGlK46eXQFt3w1iAQI7MUR pNRYPJXYFOkFi53bL7tUamI8qdKfj1wIs/cJ0Ff142ncnSvdgns/7L8ka+bv51VvGbQR scQ0N0Vu7eZukYmqXkfRxtQeT2YSNfQtFs1k43xRt63gnjH1oDOSR1x/5d59R1M2ZL2/ hNnSkkQ++PR1he9HxZw0oN3Z9MWZ82/Avw4oJa5bTGHw/dHjD/eotg4KzbgGc5cAAgjE j49Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=cqoV8aek; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id l2si4087998otl.322.2021.11.03.10.20.47 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:20:47 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=cqoV8aek; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:33422 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJwM-0005jX-Ow for patch@linaro.org; Wed, 03 Nov 2021 13:20:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37078) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJoF-0005N9-1f for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:23 -0400 Received: from mail-wm1-x336.google.com ([2a00:1450:4864:20::336]:34762) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJoD-00074T-3q for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:22 -0400 Received: by mail-wm1-x336.google.com with SMTP id o4-20020a1c7504000000b0032cab7473caso3787876wmc.1 for ; Wed, 03 Nov 2021 10:12:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=yyRfS3iCiw1/tG9HJBOoGZjbjgeiOJQ9Q/Je/hZdaRg=; b=cqoV8aekGmrLmeADR2FQU9Opie4UHv44PCSmpdKoYNsOxgUL97i5txKIrHKtVhDkl8 cAH6Bwwn3diZhcpuyiTAzLYmUpbLYK99COevWvU+wGRTWpVp4Bji6b/b3crDVpwEwf9C zgSp1UFNa1NpT+DgVBivGIvT64FNthZZtueQp336mTl6JwVH00S3kkjjTJ69OzjwJf64 /uTCe22IyUjZH5NBnuv0SC3MZ35zbFyhq+yVfInjVEjTRueuMMRrROg6xj+6oTh04gJt auaWwXvYIRu/7D1nbmFy/E9loELlnxwpscg1dYyLBDdIquPpAm3kcUolKHtPgxvvT3Ne nl+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=yyRfS3iCiw1/tG9HJBOoGZjbjgeiOJQ9Q/Je/hZdaRg=; b=u+C25FuKD699DhFzSNG3FAI/FTv83dnPlSTuPdQRdej4NHLZ7u94LuFrR59kC0dZDt htlwN+RAF98a/iUJ6p886g/kUxcGzlKGXhKMX+Mp1wOwvOuWyAv+CCfolvbilW6y1ZB1 3jAaF/aQF5XWC4bHsJ+1t2MBp6azc9mxP14zzmxmra1YDiDoSUy2UQs5/oDbUnMc6kQe K0ob5lh+XwDJqeNDmpQ2IXTGOSGmx60E+A4v/56Fes721OY1JmKBeOswpZ7FMqh3bF3I 2mon0E4aaap0qqO+rXEOtaQW0X6msW7Xo2TQNLzRF9whF9XqjkZvV+9WHiouHIRS7RU1 JOFw== X-Gm-Message-State: AOAM532m/uYl0lpyxF2wYf23VE8aOFYPk/16MvBsWCCiraC/KlmKeAo+ c6OEjUzXR+9hu/Q4W4YSln7mbQ== X-Received: by 2002:a1c:4681:: with SMTP id t123mr16849867wma.83.1635959539731; Wed, 03 Nov 2021 10:12:19 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id z11sm2529620wrt.58.2021.11.03.10.12.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:12:18 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id D8A161FFAF; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 16/21] tests/plugins: extend the insn plugin to track opcode sizes Date: Wed, 3 Nov 2021 17:05:53 +0000 Message-Id: <20211103170558.717981-17-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::336; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x336.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Mahmoud Mandour , richard.henderson@linaro.org, qemu-devel@nongnu.org, Alexandre Iooss Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" This is mostly a convenience feature for identifying frontends that do multiple repeat loads so I can test changes to the instruction tracking interface. Signed-off-by: Alex Bennée Message-Id: <20211026102234.3961636-20-alex.bennee@linaro.org> -- 2.30.2 diff --git a/tests/plugin/insn.c b/tests/plugin/insn.c index 0f6a1938c1..d229fdc001 100644 --- a/tests/plugin/insn.c +++ b/tests/plugin/insn.c @@ -18,6 +18,8 @@ QEMU_PLUGIN_EXPORT int qemu_plugin_version = QEMU_PLUGIN_VERSION; static uint64_t insn_count; static bool do_inline; +static bool do_size; +static GArray *sizes; static void vcpu_insn_exec_before(unsigned int cpu_index, void *udata) { @@ -49,13 +51,35 @@ static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) insn, vcpu_insn_exec_before, QEMU_PLUGIN_CB_NO_REGS, GUINT_TO_POINTER(vaddr)); } + + if (do_size) { + size_t sz = qemu_plugin_insn_size(insn); + if (sz > sizes->len) { + g_array_set_size(sizes, sz); + } + unsigned long *cnt = &g_array_index(sizes, unsigned long, sz); + (*cnt)++; + } } } static void plugin_exit(qemu_plugin_id_t id, void *p) { - g_autofree gchar *out = g_strdup_printf("insns: %" PRIu64 "\n", insn_count); - qemu_plugin_outs(out); + g_autoptr(GString) out = g_string_new(NULL); + + if (do_size) { + int i; + for (i = 0; i <= sizes->len; i++) { + unsigned long *cnt = &g_array_index(sizes, unsigned long, i); + if (*cnt) { + g_string_append_printf(out, + "len %d bytes: %ld insns\n", i, *cnt); + } + } + } else { + g_string_append_printf(out, "insns: %" PRIu64 "\n", insn_count); + } + qemu_plugin_outs(out->str); } QEMU_PLUGIN_EXPORT int qemu_plugin_install(qemu_plugin_id_t id, @@ -70,12 +94,21 @@ QEMU_PLUGIN_EXPORT int qemu_plugin_install(qemu_plugin_id_t id, fprintf(stderr, "boolean argument parsing failed: %s\n", opt); return -1; } + } else if (g_strcmp0(tokens[0], "sizes") == 0) { + if (!qemu_plugin_bool_parse(tokens[0], tokens[1], &do_size)) { + fprintf(stderr, "boolean argument parsing failed: %s\n", opt); + return -1; + } } else { fprintf(stderr, "option parsing failed: %s\n", opt); return -1; } } + if (do_size) { + sizes = g_array_new(true, true, sizeof(unsigned long)); + } + qemu_plugin_register_vcpu_tb_trans_cb(id, vcpu_tb_trans); qemu_plugin_register_atexit_cb(id, plugin_exit, NULL); return 0; From patchwork Wed Nov 3 17:05:54 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516788 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp902764iml; Wed, 3 Nov 2021 10:20:40 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwJI0SGxRzA7M7pySvYNlm369oO1K/og0vrTls7H/5fPuX81GEjnROitkb+QktLdTyO7m1O X-Received: by 2002:a05:6808:d4f:: with SMTP id w15mr11937735oik.99.1635960039949; Wed, 03 Nov 2021 10:20:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635960039; cv=none; d=google.com; s=arc-20160816; b=H/ynTgVXOWWR2sxG7reDgqNBx8m7tL88DKDRysDfvTQ+QNE7l2sRWBgP8pvx6bOBgF M+Lva6bsCpxm1B5fM4Cb/i4VM2JP05FZb0ArVUbx8rbeQirrwuflQ2SoAUCfnk3Zif8W iPlZR/3MZITt+DYAvAsGib7yMCiXWdFSG+RcjHxTYIGqt4YP7EyBCWK9DiOb9r7MbRoh Cw++9kGZMeZS0EFZnNGs3onG4UGNV7lVtpVfKfI/jn0DFXP9zN7/jwq1jZbN1wNA6rhN T2fJIK1xSIyPZA5Hg6HSz7JV/h4I1d55dwi8r4+N49O+SDt80uMAy7RlujTK5juTMRQW oUaQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=AwxpI2bFznxmZpBb5VRsZbQtkWT+77Twu4jSfg8KH/E=; b=JmjH6MdwUJfK0mrRrpm6uTgoHIa7lOUIJnWiAX62g7lIuorurx+rvO+G3FbB4r7Osu BtSRUMlvmkil5dtmTpESdoptOhToftAzqqgFlBjaV1Q0r4w9kt8KUSO4xqf00pMFEdjO eVzvGOKUEmsUPqE/iNn3VhEp4RnJnZ+TFpC8723NXNmfX3T3bmyHYT5iJDC24DL2UNtW rpuYKV+HsHi2A4fI+WcQZZlXdqyVPTcBVxaPSp6z7WJS/P2iU6SQZhvgzk+gWIlpXuPZ DusSEbQwhrweZEJFY2lqKkD3oD7WPWlSnm+ijovpsBgZh7sXvnNBs5R3jaVqtHlnbo0x 6BVQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b="f/1Rijjt"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id w7si3848945otm.161.2021.11.03.10.20.39 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:20:39 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b="f/1Rijjt"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:60928 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJwF-0005Dr-B8 for patch@linaro.org; Wed, 03 Nov 2021 13:20:39 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37124) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJoH-0005YH-I4 for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:25 -0400 Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]:33359) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJoF-00074n-UN for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:25 -0400 Received: by mail-wr1-x433.google.com with SMTP id d24so4719183wra.0 for ; Wed, 03 Nov 2021 10:12:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=AwxpI2bFznxmZpBb5VRsZbQtkWT+77Twu4jSfg8KH/E=; b=f/1RijjtCRik+SvSTXx2n1YdCb9lq6UIdewCxVrB3+nk56rI3V53n0n8QG0mP3ud1t rIXW1az/TPrKLALQP78tQ79evB/W/9Yy4KBBniallDUs9KcAmo7KBeYmOiuUOiPTRh0/ Lu5iK0WXjwHFoh4ZGpjQES4UyWWYQ+tPt5F6F2NSAoWMlOR6KC8zeVUMMhscfFD/BK1R TjOUrMvChFIq9MADeGM0w9GpblaBVlYzUVqXZMzI6OWOweBmifUcSxwDl33CFz8ZqLxm U2PEWUh4fx58Rlofu6je0Y4Xml/MXFOW35XH6w9e3MnJxDJdxG0dkCT4YfkGeDVvS4nK 5+Qg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=AwxpI2bFznxmZpBb5VRsZbQtkWT+77Twu4jSfg8KH/E=; b=DKsUVlbu/XJv5/bJxPk7lj3gja8xh/0aImJlxTCtFoz0JnKq33PrplWilIXU4dVd/z LDnxtPZUCJkx6vnIUNYWY+qme9co87zNWg4WUjLX19MbaVV/JA6pvdcYJkXXc/4lRn06 /p8mPAj/IOgvmXxrzSRzCABHkWEFEy84YbVpVTdlL7w1ytBkNe0MJPHvVt1OpBPX1C7+ wxsFSrNsMXOqyJD7AYVouitBNm9Rgq1oCgjXUU5VpWg52aBU1PSN+fi4Wk42JE0PkoFk TEvmhxgIxMdt9A/UIlpCc9cE6d475qexMyxvVxEurtPauLvzvkdBZ7Snj+Zw3/TTc1xb BAag== X-Gm-Message-State: AOAM532tnZmLuHC/pxlIDK/mLaG2V/Ztws6Tk5D9Ageefx+c11BObWmF ih4LjyMIUhielHo62Jcfd1rv5A== X-Received: by 2002:adf:a1d4:: with SMTP id v20mr15931221wrv.190.1635959542286; Wed, 03 Nov 2021 10:12:22 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id g5sm3115553wrd.59.2021.11.03.10.12.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:12:18 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id EA9721FFB1; Wed, 3 Nov 2021 17:05:59 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 17/21] plugins: try and make plugin_insn_append more ergonomic Date: Wed, 3 Nov 2021 17:05:54 +0000 Message-Id: <20211103170558.717981-18-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::433; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x433.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, qemu-devel@nongnu.org, Paolo Bonzini Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Currently we make the assumption that the guest frontend loads all op code bytes sequentially. This mostly holds up for regular fixed encodings but some architectures like s390x like to re-read the instruction which causes weirdness to occur. Rather than changing the frontends make the plugin API a little more ergonomic and able to handle the re-read case. Stuff will still get strange if we read ahead of the opcode but so far no front ends have done that and this patch asserts the case so we can catch it early if they do. Signed-off-by: Alex Bennée Suggested-by: Richard Henderson Reviewed-by: Richard Henderson Message-Id: <20211026102234.3961636-21-alex.bennee@linaro.org> -- 2.30.2 diff --git a/include/exec/plugin-gen.h b/include/exec/plugin-gen.h index b1b72b5d90..f92f169739 100644 --- a/include/exec/plugin-gen.h +++ b/include/exec/plugin-gen.h @@ -27,13 +27,21 @@ void plugin_gen_insn_end(void); void plugin_gen_disable_mem_helpers(void); void plugin_gen_empty_mem_callback(TCGv addr, uint32_t info); -static inline void plugin_insn_append(const void *from, size_t size) +static inline void plugin_insn_append(abi_ptr pc, const void *from, size_t size) { struct qemu_plugin_insn *insn = tcg_ctx->plugin_insn; + abi_ptr off; if (insn == NULL) { return; } + off = pc - insn->vaddr; + if (off < insn->data->len) { + g_byte_array_set_size(insn->data, off); + } else if (off > insn->data->len) { + /* we have an unexpected gap */ + g_assert_not_reached(); + } insn->data = g_byte_array_append(insn->data, from, size); } @@ -62,7 +70,7 @@ static inline void plugin_gen_disable_mem_helpers(void) static inline void plugin_gen_empty_mem_callback(TCGv addr, uint32_t info) { } -static inline void plugin_insn_append(const void *from, size_t size) +static inline void plugin_insn_append(abi_ptr pc, const void *from, size_t size) { } #endif /* CONFIG_PLUGIN */ diff --git a/include/qemu/plugin.h b/include/qemu/plugin.h index b3172b147f..145f8a221a 100644 --- a/include/qemu/plugin.h +++ b/include/qemu/plugin.h @@ -163,10 +163,12 @@ struct qemu_plugin_tb { /** * qemu_plugin_tb_insn_get(): get next plugin record for translation. - * + * @tb: the internal tb context + * @pc: address of instruction */ static inline -struct qemu_plugin_insn *qemu_plugin_tb_insn_get(struct qemu_plugin_tb *tb) +struct qemu_plugin_insn *qemu_plugin_tb_insn_get(struct qemu_plugin_tb *tb, + uint64_t pc) { struct qemu_plugin_insn *insn; int i, j; @@ -179,6 +181,7 @@ struct qemu_plugin_insn *qemu_plugin_tb_insn_get(struct qemu_plugin_tb *tb) g_byte_array_set_size(insn->data, 0); insn->calls_helpers = false; insn->mem_helper = false; + insn->vaddr = pc; for (i = 0; i < PLUGIN_N_CB_TYPES; i++) { for (j = 0; j < PLUGIN_N_CB_SUBTYPES; j++) { diff --git a/accel/tcg/plugin-gen.c b/accel/tcg/plugin-gen.c index 61be64b78c..22d95fe1c3 100644 --- a/accel/tcg/plugin-gen.c +++ b/accel/tcg/plugin-gen.c @@ -876,9 +876,8 @@ void plugin_gen_insn_start(CPUState *cpu, const DisasContextBase *db) struct qemu_plugin_tb *ptb = tcg_ctx->plugin_tb; struct qemu_plugin_insn *pinsn; - pinsn = qemu_plugin_tb_insn_get(ptb); + pinsn = qemu_plugin_tb_insn_get(ptb, db->pc_next); tcg_ctx->plugin_insn = pinsn; - pinsn->vaddr = db->pc_next; plugin_gen_empty_callback(PLUGIN_GEN_FROM_INSN); /* diff --git a/accel/tcg/translator.c b/accel/tcg/translator.c index 390bd9db0a..f06c314266 100644 --- a/accel/tcg/translator.c +++ b/accel/tcg/translator.c @@ -169,7 +169,7 @@ static inline void translator_maybe_page_protect(DisasContextBase *dcbase, if (do_swap) { \ ret = swap_fn(ret); \ } \ - plugin_insn_append(&ret, sizeof(ret)); \ + plugin_insn_append(pc, &ret, sizeof(ret)); \ return ret; \ } From patchwork Wed Nov 3 17:05:55 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516781 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp897683iml; Wed, 3 Nov 2021 10:15:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxViAYo9j5FYZSgN+mYTdns+Dl0KS3FWxLKZ/up4OQLs/uwwhfpgJXNUCUBjXvDaFG+LSjY X-Received: by 2002:a05:6808:ab3:: with SMTP id r19mr12044936oij.133.1635959737923; Wed, 03 Nov 2021 10:15:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959737; cv=none; d=google.com; s=arc-20160816; b=weJ3TJJQ5yh9wiPAmNQFIREYv4QwU1gSDX3C7ts5JUnJwiDcXA5shZz//hvBozfNlL lfvKeZ7LYo3fDJxlfUK/9q1NT9oyiPoGF2odiMyMz3EFRCITUfO33UwvtuPYKja/5rhy le7s2dgDngK38E9Bxc3ahwK5fbg4yHIUQKrUkr3PV69RE4eaZ5nWPWqtUuw8Laj6UF0i hE24esogiy2OWs09EpKIV6IgnwYiYLzPIb+88kHrxE0Q2rKt9HLiRIXW4CA6hEzrPRBq MStEKvNE7C9JorNLOT15NBDcJg6teeLy7rMeGn5l2sN4XpBcOP7kK1X4o5SXNiFBXpPy X8CA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=gN/nCnYHg37RzH2ySF2xwAPVmqvP9Hor2tdZRDmd/rA=; b=z7v3oxr14N1PunWIDu7rBwya/5lfNgR3hFING/kCf1R7JvQxQT5rVgI7OUxcTntehK eWAafd18WKPfU4KCvN2GIgsurW16sl5xBS9MSf8Aqpjx7O8nZyQyFH+HmNPE7WesJvj0 V7q7mAQSgVRQ6/K0WmoHu/7quCMXEw9SgY1iCheUj2NKVKH89wSF6FTwKrYrEQZ4Y+fM lIDmHJZww20tLzh9p1R+lqEZ4CdKgNx0Lt02IBUXMnFJ77dlBA1TqDXA/wSvoI+tioml G2w7G0KLBwWTXxmfyINHpgf5GrYYMB1NcypXI40fl2WQ0mlYvUw0VyfsZNwvi8Qe0+jH ahRQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=s+G9BvPT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id z3si3293119oih.100.2021.11.03.10.15.37 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:15:37 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=s+G9BvPT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:44410 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJrN-0002UB-BF for patch@linaro.org; Wed, 03 Nov 2021 13:15:37 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37026) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJoA-00056V-Bl for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:18 -0400 Received: from mail-wm1-x32a.google.com ([2a00:1450:4864:20::32a]:46947) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJo8-00073i-UM for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:18 -0400 Received: by mail-wm1-x32a.google.com with SMTP id b184-20020a1c1bc1000000b0033140bf8dd5so2360650wmb.5 for ; Wed, 03 Nov 2021 10:12:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=gN/nCnYHg37RzH2ySF2xwAPVmqvP9Hor2tdZRDmd/rA=; b=s+G9BvPTYfVKT1SAmnx1/GFQ8ofROLhHCRma2cBRlmtLxmlpVHMTD4iRRHiPHh4rBm qy3ZBQWSvvad7B+QSqRH/VeSX5u1u+5xJ3C3odi6YPuT+1Z0YXtCfgQv81cMLpYWk/8A Fk4Z9MKWClaUqWyS9kYx/IBHfk72yW9j+G1GGwNE3b7opk63Xc9vfKFpDYpoqJv/A02a qRN52z3RsplMKJvPuA5teKrc2ap5X3QZr6dEvhTEQL2Ucvx4dBjtHZ6F0NUmmznvPYd5 tpuSIcRXLsurMYD1DqQ55kqnvKfy710QcVf0nxfNaGEekstSxhHJgHyXuy7HkTRbTUXH h9Cg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=gN/nCnYHg37RzH2ySF2xwAPVmqvP9Hor2tdZRDmd/rA=; b=YME+W9l00NxyESQEPNadDGN87iNLrxdzMuBQn3Xc0SY9m9Ow1yzQHgdVex6PhT0v1G 9P9Hy5guvyKRDEIGbxknRQ1P/HHTu2JidW61kQCW7S0SiyCQRuSsqfx2N5b7OMy1hKi7 58x78N7kEDSwWmPA63YcyVQmhWFvRlkX7BbwsxevbIZSE+FxDJuWV36FO0nNbMSc6D9y 08vNrbaMVgDKkDu9bdOzhcEBn76P+uRHJIFDrpvusdfhrJU2faZjZIImCWoNhXbzye5P 4oIVptaX39gWZe2NK0v0DlRPAvDCZpSmGscz8HFH3ybdRXRg6q4ylq1Po6fA73gQ00Pj HcNA== X-Gm-Message-State: AOAM530hNtF9WwLqy7Ao33vr/yCf+KQ/F5J2sxXmh469vFxprClNf/GF k5k8o1JxJw1xLVaXWfhu6OHhNQ== X-Received: by 2002:a1c:2507:: with SMTP id l7mr16478349wml.186.1635959535351; Wed, 03 Nov 2021 10:12:15 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id n7sm2463588wro.68.2021.11.03.10.12.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:12:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 0C7021FFB3; Wed, 3 Nov 2021 17:06:00 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 18/21] tests/tcg: remove duplicate EXTRA_RUNS Date: Wed, 3 Nov 2021 17:05:55 +0000 Message-Id: <20211103170558.717981-19-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32a; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32a.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, qemu-devel@nongnu.org, =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" We set it bellow outside the #if leg. Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20211026102234.3961636-28-alex.bennee@linaro.org> -- 2.30.2 diff --git a/tests/tcg/multiarch/Makefile.target b/tests/tcg/multiarch/Makefile.target index 6ccb592aac..c0d9e638e9 100644 --- a/tests/tcg/multiarch/Makefile.target +++ b/tests/tcg/multiarch/Makefile.target @@ -61,8 +61,6 @@ run-gdbstub-sha1: sha1 --bin $< --test $(MULTIARCH_SRC)/gdbstub/sha1.py, \ "basic gdbstub support") -EXTRA_RUNS += run-gdbstub-sha1 - run-gdbstub-qxfer-auxv-read: sha1 $(call run-test, $@, $(GDB_SCRIPT) \ --gdb $(HAVE_GDB_BIN) \ From patchwork Wed Nov 3 17:05:56 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516784 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp900128iml; Wed, 3 Nov 2021 10:17:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJybnptuo2eNy9pmStWuMmjCNX91BzHyicVsOGslqmsenE/SY8RCE7m4lz18Hf+mbjC1OEUG X-Received: by 2002:a05:6808:b2b:: with SMTP id t11mr6962638oij.47.1635959878816; Wed, 03 Nov 2021 10:17:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959878; cv=none; d=google.com; s=arc-20160816; b=zVPjlxXln1k5m+Zqq/cJ4MRBtKGs8iAC/k3AuQdH27cKdhXKhfKbN8/I3lOVOx/C44 ofiZSThgCR23+0+8BetoGJEQPlv0INmBTlhk+zcZqu05+lmL157WpS5BluLCICqYYtp7 XsZmFJ9N0GPk18X/B+q6a05NXCJDmrydL60Zw4IEqmeaQoJTefikN01jnKAG90kGJZ2F 4dNhu145FCwXryyhUvfbVoHO7VN1L4HKU7oAuo8+n+Om5GQIfIT4U4/lpYnVOmgusPOe QyJltRooIfqsYQUoXtpl8Kz82N9nVxY/1Cn2DvpcUlZEM0REbp2iFjf+Gm60XPbdvqTt MNlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=jEm8wFXqDZuskzPXAa1Sb29OHvLZldSUOvxYEh9L5yg=; b=Lxh05grssgZhjKQtsDEhe7PpZBeSY/B4NAA41OTGVkvhwqwN9wYhckTF2L21jWNggm wh/HC7JvoSyE3LmgioxNiJyz873TOgHpppT43iQjm1mPNRZCsyNqFBAM9ewTZS4YDXtd Xvor4mqiui+zw/i9hibFnClTv3iCTFXFHnJUsgGwmyISwhsMe+PaJE2R4eD+UUW8HWu0 YiioSDa9EJ1NEnSHwe7czGIP03ct21X8Wt6kqab/srDsohRGSfgDqD7aQxjC/dJB6Af6 VugYQThYW6j3iCgwoWezMdTD7v4A6JCYhaspltA6oOFXx9TX74u0UdgZKy2FL2R+Ca4O Su5g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b="dfOo/WUO"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id l2si4180398otl.324.2021.11.03.10.17.58 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:17:58 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b="dfOo/WUO"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:52288 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJte-0007tO-5s for patch@linaro.org; Wed, 03 Nov 2021 13:17:58 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37044) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJoB-0005CK-Qm for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:19 -0400 Received: from mail-wm1-x332.google.com ([2a00:1450:4864:20::332]:50860) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJo9-00073r-Jh for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:19 -0400 Received: by mail-wm1-x332.google.com with SMTP id 133so2584975wme.0 for ; Wed, 03 Nov 2021 10:12:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=jEm8wFXqDZuskzPXAa1Sb29OHvLZldSUOvxYEh9L5yg=; b=dfOo/WUO+sMaPXo5fePo76AvghODAB2fA4E4BJ1ebmYTI2ji8XN15VCd7VDBeMSRKp yKcnLUNIaTPxmMycpLoxEIQJUx3y7vax0LjW4jbx07E0lWfFyNDHkXxzuTRbW130P9C/ 0VlLC3FYr2HjU29cVvcEAKr+as0FmNnFNME+idi4RxfjMuFNyeMTWDAjlZJztRnK7x/r fC9hTz3qjAhu+sOXj3ViGpl5yWxlJVe8+UVjC5pPiyeiUhcEuTy204JJ3WfSC9XQD7AV 1I0iZemxUe7ps21nQorhkFVCdTvn6bQjFDXjVPugXEjrQ/6F0hwpjX/Shqhi1BMAbm8E BU4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=jEm8wFXqDZuskzPXAa1Sb29OHvLZldSUOvxYEh9L5yg=; b=ELG2RFj3dy6IMb5xvGoY0lb9xNvxzrH4q1nc69BB0RUXVzvhxjGMe9E8dZPip/BF2s xMGUWumkDXZQDJNpstT/HtNvAK+7a9NCZJvFzkDuFsBSmSD2C+aX6VxG/gmsG15pQQuH fjdvm+TuLC1I/ATw3JjBrb1t8C8LEN7STLw6Tjssar795QZoHkuXJfaB7tVmUSbuF8MS IpIouV1YSco6AriJmCNbQz6iVFEgIDnJKkaaJ4F8svQEXDanB85aJgdss+tysfBIvdtj 7cfr2XzI5lHRGRK8EnA2FlcenHfXoZwtU17lrxMsGtQQnC+9fYs43TjILkfYs1OErl2B lXPA== X-Gm-Message-State: AOAM530w7VoQWwuAvXl2jJtR9otKkRfgQBw2t5znnPhE1eA61L4gq2KZ BmVYGV7+mA2kg6ycjE//PJkSow== X-Received: by 2002:a1c:6a0e:: with SMTP id f14mr16351901wmc.58.1635959536218; Wed, 03 Nov 2021 10:12:16 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id k187sm6170771wme.0.2021.11.03.10.12.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:12:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 1C8291FFB4; Wed, 3 Nov 2021 17:06:00 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 19/21] gdbstub: Switch to the thread receiving a signal Date: Wed, 3 Nov 2021 17:05:56 +0000 Message-Id: <20211103170558.717981-20-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::332; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x332.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Pavel Labath , richard.henderson@linaro.org, qemu-devel@nongnu.org, =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Pavel Labath Respond with Txxthread:yyyy; instead of a plain Sxx to indicate which thread received the signal. Otherwise, the debugger will associate it with the main one. Also automatically select this thread, as that is what gdb expects. Signed-off-by: Pavel Labath Message-Id: <20211019174953.36560-1-pavel@labath.sk> Signed-off-by: Alex Bennée Reviewed-by: Richard Henderson Message-Id: <20211026102234.3961636-29-alex.bennee@linaro.org> -- 2.30.2 diff --git a/gdbstub.c b/gdbstub.c index 36b85aa50e..23baaef40e 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -3138,8 +3138,12 @@ gdb_handlesig(CPUState *cpu, int sig) tb_flush(cpu); if (sig != 0) { - snprintf(buf, sizeof(buf), "S%02x", target_signal_to_gdb(sig)); - put_packet(buf); + gdb_set_stop_cpu(cpu); + g_string_printf(gdbserver_state.str_buf, + "T%02xthread:", target_signal_to_gdb(sig)); + gdb_append_thread_id(cpu, gdbserver_state.str_buf); + g_string_append_c(gdbserver_state.str_buf, ';'); + put_strbuf(); } /* put_packet() might have detected that the peer terminated the connection. */ diff --git a/tests/tcg/multiarch/Makefile.target b/tests/tcg/multiarch/Makefile.target index c0d9e638e9..b962ed8236 100644 --- a/tests/tcg/multiarch/Makefile.target +++ b/tests/tcg/multiarch/Makefile.target @@ -68,11 +68,19 @@ run-gdbstub-qxfer-auxv-read: sha1 --bin $< --test $(MULTIARCH_SRC)/gdbstub/test-qxfer-auxv-read.py, \ "basic gdbstub qXfer:auxv:read support") +run-gdbstub-thread-breakpoint: testthread + $(call run-test, $@, $(GDB_SCRIPT) \ + --gdb $(HAVE_GDB_BIN) \ + --qemu $(QEMU) --qargs "$(QEMU_OPTS)" \ + --bin $< --test $(MULTIARCH_SRC)/gdbstub/test-thread-breakpoint.py, \ + "hitting a breakpoint on non-main thread") + else run-gdbstub-%: $(call skip-test, "gdbstub test $*", "need working gdb") endif -EXTRA_RUNS += run-gdbstub-sha1 run-gdbstub-qxfer-auxv-read +EXTRA_RUNS += run-gdbstub-sha1 run-gdbstub-qxfer-auxv-read \ + run-gdbstub-thread-breakpoint # ARM Compatible Semi Hosting Tests # diff --git a/tests/tcg/multiarch/gdbstub/test-thread-breakpoint.py b/tests/tcg/multiarch/gdbstub/test-thread-breakpoint.py new file mode 100644 index 0000000000..798d508bc7 --- /dev/null +++ b/tests/tcg/multiarch/gdbstub/test-thread-breakpoint.py @@ -0,0 +1,60 @@ +from __future__ import print_function +# +# Test auxiliary vector is loaded via gdbstub +# +# This is launched via tests/guest-debug/run-test.py +# + +import gdb +import sys + +failcount = 0 + +def report(cond, msg): + "Report success/fail of test" + if cond: + print ("PASS: %s" % (msg)) + else: + print ("FAIL: %s" % (msg)) + global failcount + failcount += 1 + +def run_test(): + "Run through the tests one by one" + + sym, ok = gdb.lookup_symbol("thread1_func") + gdb.execute("b thread1_func") + gdb.execute("c") + + frame = gdb.selected_frame() + report(str(frame.function()) == "thread1_func", "break @ %s"%frame) + +# +# This runs as the script it sourced (via -x, via run-test.py) +# +try: + inferior = gdb.selected_inferior() + arch = inferior.architecture() + print("ATTACHED: %s" % arch.name()) +except (gdb.error, AttributeError): + print("SKIPPING (not connected)", file=sys.stderr) + exit(0) + +if gdb.parse_and_eval('$pc') == 0: + print("SKIP: PC not set") + exit(0) + +try: + # These are not very useful in scripts + gdb.execute("set pagination off") + gdb.execute("set confirm off") + + # Run the actual tests + run_test() +except (gdb.error): + print ("GDB Exception: %s" % (sys.exc_info()[0])) + failcount += 1 + pass + +print("All tests complete: %d failures" % failcount) +exit(failcount) From patchwork Wed Nov 3 17:05:57 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516793 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp904913iml; Wed, 3 Nov 2021 10:22:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzUCSkZyhuuEHr9f7JEoW06m5wqkJ3Y4pCp3T6Hg3lscE08dhQVf+4iS1FplLg40Zcqig4Z X-Received: by 2002:a9d:360a:: with SMTP id w10mr3788336otb.195.1635960172806; Wed, 03 Nov 2021 10:22:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635960172; cv=none; d=google.com; s=arc-20160816; b=z9VN1jIbh9gMUMMbt0umrI6/Pub7NMcYj5f0wTT+moC14O+LdUIzSFh2WcOahSfaYV IvmjqbBCwIj/1evNpGR6TDCTPVOzfijTW5Uw8MNB+d09rW+0c3TOKpV2EEL8dG6+zVDT Ggoe8kZajsX/qVTb0MB1O3hbozjQN+VUFqIAZjzgXVc7de1HqhWCYKFJoZM0l+/obawV oi36XfjNgzBfZhkphEi5/lVXJ3lpYL/IzDTgPYvOcoKmGrC/hcUiimylUvQUqkdyCiJg cDOMvaYJFJw6rG4JkJeOa60eM6zqYVyyzZ9Z/UhrXFqwb8P2pHGthY51Ni4FSbRfvkdc 26qQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=/FYDfyeABj7CDR/MgjAQldLjA0oTUIGaG3FQyOZ6q8w=; b=ItR84CCAFcNWKQH5PzGeaSHn8unPryof/LwTMcRCygCoZ1YS2SV1d5hpJwZ1L61tlX 3G0Ib1GTHYqAclJG8pEKY3fIQRF/3176WGUZVfOjE9z9ONveokxuPskSAViVPl5Uwxbh lSd2xw4ondnokhjdQ+buvhzrosZe1zAlOPaJ5QZP850UVZhEVf9new8h7RwvyoR8CWgO smaULm9HC8MK9qWgv97RhHV1kr9lc3p7HHGEYQjQ1NIrNuw63Krcg/yd8Xvl14SSIyZs tG+LO2gkfV/Q4tYsgmGL/vLESBYNUqDQUW6jqeJ7qS/T4oHTRpo0sFMHdl7FMKuJDLqb Tz7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=HyBW2RSY; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id w12si2655360ooj.46.2021.11.03.10.22.52 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:22:52 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=HyBW2RSY; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:41866 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJyO-00033s-9x for patch@linaro.org; Wed, 03 Nov 2021 13:22:52 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37142) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJoM-0005vF-Oz for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:31 -0400 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]:36354) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJoB-000748-GD for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:30 -0400 Received: by mail-wr1-x429.google.com with SMTP id s13so4682630wrb.3 for ; Wed, 03 Nov 2021 10:12:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=/FYDfyeABj7CDR/MgjAQldLjA0oTUIGaG3FQyOZ6q8w=; b=HyBW2RSYWE19Ye3Cgd9Uf45qe1oahrr+4n16f6cU/VfBmx8ylNaDlJwniYoL59g5Hp v2dRKvOmN6h8kUqvjhNs5pieOLix/h2CCWjJw3pxbBQeHUlFsf3U5jgWFEiId6RVccDG 0aXYtG90ganwIho2asWuaoF63ckKnoO0EPm7rP10s8fi+lvmyzG6CC98Nf2eUthH17tH GAtRV47ITUiHZw2AkKv+asS1gyFTKxG3lrkJeRmlA9CQfP+VjHSLIKxdmYOffQZi4j20 Ggi2/wLs+1t48hocBPkk7onHn1J6ZAxJPVgCXNL7n4/MALlkToq36oHmOKuD/VmH8D45 sUkw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=/FYDfyeABj7CDR/MgjAQldLjA0oTUIGaG3FQyOZ6q8w=; b=iHfiGzqju68Mw1g4QWbEBB2mPyGeXwhHJGvgkD+Vw/q8aB9vSL1AUDkh39v41UVMxO zN4Pie5KUfNDFUOQVLDi+7UlbqZykTQCBipM85B/8cn+Hum6Md+6tMYfpQQuQpNElz+h PBetm2EjvxhNoG0v+mn73WgZ6lWgWieyLIzXk3UErQR4gRu7fFYfDI4cUtG5wXCBawuf 2xNCUbzyIBBSwEMou9S/1ZzpOHIyVdv6r2kSIDBlbWrj6vVBEIGIZA5RpAeWtH81Pq7r FGFg8IE/YAPawIqGvTBYTT/buj2txmGZOkEq8PQhAwkn0S0A2f7NRJT/+Rnpir6e431z nDoQ== X-Gm-Message-State: AOAM531RgqKO+zUli1oS7qigU/IlqkwBjk5Ctd56NVhNmn9b8PV/oBBC SkQGTnG9GQ1e8XRKWhZsg8HcvA== X-Received: by 2002:a5d:4481:: with SMTP id j1mr12611366wrq.6.1635959537654; Wed, 03 Nov 2021 10:12:17 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id k21sm2439020wmj.45.2021.11.03.10.12.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:12:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 33A6F1FFB5; Wed, 3 Nov 2021 17:06:00 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 20/21] tests/tcg: remove debug polluting make output Date: Wed, 3 Nov 2021 17:05:57 +0000 Message-Id: <20211103170558.717981-21-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::429; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x429.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, qemu-devel@nongnu.org, =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Fixes: 5343a837cd ("tests/tcg: move some multiarch files and make conditional") Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Message-Id: <20211026173914.79377-1-alex.bennee@linaro.org> -- 2.30.2 diff --git a/tests/tcg/multiarch/Makefile.target b/tests/tcg/multiarch/Makefile.target index b962ed8236..a83efb4a9d 100644 --- a/tests/tcg/multiarch/Makefile.target +++ b/tests/tcg/multiarch/Makefile.target @@ -16,7 +16,6 @@ MULTIARCH_SRCS += $(notdir $(wildcard $(MULTIARCH_SRC)/linux/*.c)) endif MULTIARCH_TESTS = $(MULTIARCH_SRCS:.c=) -$(info SRCS=${MULTIARCH_SRCS} and ${MULTIARCH_TESTS}) # # The following are any additional rules needed to build things # From patchwork Wed Nov 3 17:05:58 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 516785 Delivered-To: patch@linaro.org Received: by 2002:ad5:5208:0:0:0:0:0 with SMTP id p8csp900345iml; Wed, 3 Nov 2021 10:18:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx2V+4pbq0wBKdtM+0oVN0I0224YTliAD4DfLjY/D+b/CnPKdjsqYB6KogHZDLVZK3iryOa X-Received: by 2002:aca:3b02:: with SMTP id i2mr11602050oia.85.1635959891419; Wed, 03 Nov 2021 10:18:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635959891; cv=none; d=google.com; s=arc-20160816; b=fBngJ0JbYxXYQ2kg1iToeC8img0xie2FvO7xrGi2qpsSAU5Eqo00w4zs24MY+5dogT wSQOL8efydYOUt76pSKwER6+q0IqmZOZcJxpgLRJJhw9eWpW3yFHVtbdhZPXTA/ZrKlK JEEJmbRkQuzRWu0oqmjnhDId+reETosIAIAoigX30ilIoAUdKA1mHhojGayQMXb1WZL/ rPIygIGP4YJz44TEUflF4AtvyiCDKCDh3Zck0WtzqKzG+VOUlJB+I9m0Mm1jm4BfpmwD Vq4HCBty6sy2hxh6daeZg8twvbtnSmwzNnIHoPTNCkDBNEVLg/LXsN7bx39m8vwjhcco 9ktg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=eSTCgBq0uk3l/07IcpsOMHYU2kSqHZONAnfF9tBHDUo=; b=c9QVti6v+6lLnCCRxkP8VVO0Cqh+fnalHm4v2EJBE2vWUWWKJNgff4gbvANhyJ8Dbu rhYLZt3TZp0GacqXz5qdFNF9yMZ9bd8jmViHkZLhp1gDb3/1aRAFl6UicrSid6TjPd5n WNePf1RAfnbD0GrGq2ugFJHhPTi+uEgCn4/A/GV70kQ2dDQxl/vd1DnGtzgMHSDxrNwJ JcongyHqlAg+9Jr5PazUtcrT/BG8nYwELWq2Abed+8XB04sQDw6ChIR6IED4us+AbSqL 0Hco2qoEZxL0/2Vg9WZ0F0vwG9uw5PU/JOsvnbS2vwwNYiHR129jtrIvbwtLKW4Teoyj 2Umg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=TcM1Fgy3; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id c12si4841957otu.304.2021.11.03.10.18.11 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 03 Nov 2021 10:18:11 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=TcM1Fgy3; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:53084 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1miJtq-0008Oz-To for patch@linaro.org; Wed, 03 Nov 2021 13:18:10 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37030) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1miJoA-00056p-EQ for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:18 -0400 Received: from mail-wr1-x430.google.com ([2a00:1450:4864:20::430]:44909) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1miJo7-00073a-0w for qemu-devel@nongnu.org; Wed, 03 Nov 2021 13:12:18 -0400 Received: by mail-wr1-x430.google.com with SMTP id d13so4624936wrf.11 for ; Wed, 03 Nov 2021 10:12:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=eSTCgBq0uk3l/07IcpsOMHYU2kSqHZONAnfF9tBHDUo=; b=TcM1Fgy3hgB86D9jmh59lMonjLXXEyPL3TTDFxsyJaQNtU6+j7I5FokHY6vGbf3gKu zxzs1VvwP91ggM6UFywj/VT3GTOZKfF6QESET1dsfco7QjQSRcp1Rmn4b8OOrBp5IUAS bUfOmeUEPeknO0lDfpkqi35NIkwFimmzOTd9xcAv7YAtnv8pI9RINy204DkmJ7v3+G4D DLW2ePn2tFVIFoIXWnlKK8fkv7lwGH5ZFNmsLmcaaXmvhmZsNMtRWK2eI62AVW4kRkfZ MKQ0U09WEXwhnCqzhCE4JBoc3jlK6F83EYejHfYLNKD4Egt+RmycI673stqNI6wPEMYI fXUw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=eSTCgBq0uk3l/07IcpsOMHYU2kSqHZONAnfF9tBHDUo=; b=DqllZ0dLaZiuMXiT3STaV1ev3XYokCNn3b0LLkU6I1nCyODFR5E1DjwMlGNyLBVEXe wCeO2hXpUqYO9KZua1jY4cazyvwTbG6nodswqSLU79niBEzqubmkxrPA/cFH119nhHxK tj1+d1Hl2Zv1PV4HFNE1mswnqhv6Z5njh4bC2qR67QzZ61Yo5UB/HzjYMUWsDOSSENy+ ShAaCYbLQuuqN5zNCo2dGXK/vh7Uy34PuVr0AoV80IRNg3jTiBHQTyCv7ap1CaJgAwSF GpgPRdv0gy/ZZ6cbzVSD8HxWy9XySPg4aM2j5L7HiSApihraOqjlVbu/6qTS7+zrKd/7 jsIg== X-Gm-Message-State: AOAM532kikfwKlNezKPV+Km8W9Y178lUar+BFmQhifHChBTM3WsqJLvL 9VsS7ZK7aNtKIRJbVBST3pK0Cw== X-Received: by 2002:adf:f34b:: with SMTP id e11mr28741352wrp.62.1635959533566; Wed, 03 Nov 2021 10:12:13 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id q8sm2512412wrx.71.2021.11.03.10.12.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 10:12:11 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 3F5E61FFB7; Wed, 3 Nov 2021 17:06:00 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 21/21] tests/vm/openbsd: Update to release 7.0 Date: Wed, 3 Nov 2021 17:05:58 +0000 Message-Id: <20211103170558.717981-22-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20211103170558.717981-1-alex.bennee@linaro.org> References: <20211103170558.717981-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::430; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x430.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Huth , richard.henderson@linaro.org, qemu-devel@nongnu.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe?= =?utf-8?q?_Mathieu-Daud=C3=A9?= , Willian Rampazzo , =?utf-8?q?Alex_Benn=C3=A9e?= , Brad Smith Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Richard Henderson There are two minor changes required in the script for the network configuration of the newer release. Signed-off-by: Richard Henderson Tested-by: Thomas Huth Message-Id: <20211018205313.3526915-1-richard.henderson@linaro.org> Signed-off-by: Alex Bennée -- 2.30.2 diff --git a/tests/vm/openbsd b/tests/vm/openbsd index c4c78a80f1..337fe7c303 100755 --- a/tests/vm/openbsd +++ b/tests/vm/openbsd @@ -22,8 +22,8 @@ class OpenBSDVM(basevm.BaseVM): name = "openbsd" arch = "x86_64" - link = "https://cdn.openbsd.org/pub/OpenBSD/6.9/amd64/install69.iso" - csum = "140d26548aec680e34bb5f82295414228e7f61e4f5e7951af066014fda2d6e43" + link = "https://cdn.openbsd.org/pub/OpenBSD/7.0/amd64/install70.iso" + csum = "1882f9a23c9800e5dba3dbd2cf0126f552605c915433ef4c5bb672610a4ca3a4" size = "20G" pkgs = [ # tools @@ -95,10 +95,9 @@ class OpenBSDVM(basevm.BaseVM): self.console_wait_send("Terminal type", "xterm\n") self.console_wait_send("System hostname", "openbsd\n") self.console_wait_send("Which network interface", "vio0\n") - self.console_wait_send("IPv4 address", "dhcp\n") + self.console_wait_send("IPv4 address", "autoconf\n") self.console_wait_send("IPv6 address", "none\n") self.console_wait_send("Which network interface", "done\n") - self.console_wait_send("DNS domain name", "localnet\n") self.console_wait("Password for root account") self.console_send("%s\n" % self._config["root_pass"]) self.console_wait("Password for root account")