From patchwork Fri Sep 6 18:07:22 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 13794596 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9B103E6FE3D for ; Fri, 6 Sep 2024 18:08:28 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1smdN9-0002Fy-Nv; Fri, 06 Sep 2024 14:07:52 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1smdMp-0001id-2o for qemu-devel@nongnu.org; Fri, 06 Sep 2024 14:07:34 -0400 Received: from mail-wr1-x435.google.com ([2a00:1450:4864:20::435]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1smdMm-000563-S2 for qemu-devel@nongnu.org; Fri, 06 Sep 2024 14:07:30 -0400 Received: by mail-wr1-x435.google.com with SMTP id ffacd0b85a97d-374c1e5fe79so1429262f8f.1 for ; Fri, 06 Sep 2024 11:07:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1725646046; x=1726250846; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=eLZYP9oZiGwTAwn0IB4n2i9sG23m9F19T+BjlVlZE4E=; b=wet083Pls+8muELKY+MIOyL6uy73mETXvfXhwOJcY9tZ81T0nRpFRf1WbxLdaHCyKI LQH0JwNrYBaicEMR5NfaYT0r33boKcKlJO+rIi2uOh1DB/AkOaqIq+R5K30iRgX+RHG2 HcgtROxEsS2X4dscarBgzLl0wk4gDxfnHDpJPqUdmuej+u3Ftadf866X4QXuv7f+rTZ4 whd5zbPES0T3MN8DnY+Fy61XivdCY22S7ZqREgw41B60eGUAgPX60aNiaCSdE3cgR02A CZKH4zWyDrdieyr1sNlCAgtYqluOzEtqnDBsEUrVJ4ka5GjWWcjhiomQwsLpoOAyhAHA VXSA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1725646046; x=1726250846; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=eLZYP9oZiGwTAwn0IB4n2i9sG23m9F19T+BjlVlZE4E=; b=bp8edsoUO83Q4/36SCHBUIvqu8flfZyjOGJAQcZasojW7JJhFmiTU+YGEY44Vk5BfI Dmay/0DD900zPo23zzxsAuV3qNCmVusNZzJ0dUvEmDA27AhPSxkHzS6W3MfVlVZQbWYB J9QXtdNTkgGWCDD5CTKYP8I3RxfPwXDmNdfTcHb6ZAvpkrmMO7gI6ad0jAGPM84W/W8v LUUMt6ZFVl8bC0Kqa5T6Azb/eaOdQtAZq6hrk5ZWb3hpFNHGGPHeaB8pWp8PVx+bolO0 vLFx6f7vFDzzafDJxDe5iR2lILaaV5Lr1o9AnIOQwOa0v2I0d6uELoh0hBnT3NW3QJqI Gb/Q== X-Gm-Message-State: AOJu0YyhyPm33BuSDtSz5wUWi6rFiEF5z926oFqbgIePOK7TNF7U838x yvcH7QyhumhxFCF4S5RLuOb/uKnsTfCOLD5lJzBlNnmPGsq2ZNtTMh4J/SC4W+JgWqNlHBTqpVa k X-Google-Smtp-Source: AGHT+IHKxxfmuyRYrzAbbqwdvP8qJJywc8TRmzIDsG5zXC4SlzSiHCC3r10Eet92VRHABwOeR8jFZw== X-Received: by 2002:a5d:670a:0:b0:374:c61a:69b8 with SMTP id ffacd0b85a97d-378895c9439mr2267106f8f.15.1725646046005; Fri, 06 Sep 2024 11:07:26 -0700 (PDT) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [2001:8b0:1d0::2]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-37891657a2csm441860f8f.95.2024.09.06.11.07.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Sep 2024 11:07:25 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Cc: Paolo Bonzini , Thomas Huth , =?utf-8?q?Alex_Benn=C3=A9e?= , =?utf-8?q?Philippe_M?= =?utf-8?q?athieu-Daud=C3=A9?= Subject: [PATCH 1/2] scripts/mtest2make: Honour MESON_TESTTHREADS if it is set Date: Fri, 6 Sep 2024 19:07:22 +0100 Message-Id: <20240906180723.503855-2-peter.maydell@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240906180723.503855-1-peter.maydell@linaro.org> References: <20240906180723.503855-1-peter.maydell@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::435; envelope-from=peter.maydell@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, T_SCC_BODY_TEXT_LINE=-0.01 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: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org 'meson test' has two ways to set how many tests to run in parallel: * the command line --num-processes option * the environment variable MESON_TESTTHREADS If both are given, then it prefers the command line option over the environment variable. This is an unfortunate order of precedence, because it's frequently handy to be able to override the default by setting an environment variable at the top level of a build or CI invocation. Fortunately, we can flip the order for our purposes, because we always invoke 'meson test' indirectly. We currently invoke 'meson test' passing it a --num-processes argument based on whatever the '-j' option to make was. Adjust the logic in mtest2make so that if MESON_TESTTHREADS is set then we honour that, and don't override it. Signed-off-by: Peter Maydell --- scripts/mtest2make.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/mtest2make.py b/scripts/mtest2make.py index eb01a05ddbd..6de0044134c 100644 --- a/scripts/mtest2make.py +++ b/scripts/mtest2make.py @@ -32,7 +32,11 @@ def names(self, base): ifneq ($(SPEED), quick) .mtestargs += --setup $(SPEED) endif +# If the user set MESON_TESTTHREADS then don't override that preference by +# passing --num-processes to 'meson test' +ifeq ($(MESON_TESTTHREADS),) .mtestargs += $(subst -j,--num-processes , $(filter-out -j, $(lastword -j1 $(filter -j%, $(MAKEFLAGS))))) +endif .check.mtestargs = $(MTESTARGS) $(.mtestargs) $(if $(V),--verbose,--print-errorlogs) .bench.mtestargs = $(MTESTARGS) $(.mtestargs) --benchmark --verbose''') From patchwork Fri Sep 6 18:07:23 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 13794594 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4E374E6FE41 for ; Fri, 6 Sep 2024 18:08:13 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1smdNK-0003MM-9B; Fri, 06 Sep 2024 14:08:02 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1smdMo-0001gA-Hf for qemu-devel@nongnu.org; Fri, 06 Sep 2024 14:07:32 -0400 Received: from mail-wr1-x436.google.com ([2a00:1450:4864:20::436]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1smdMm-00056B-S3 for qemu-devel@nongnu.org; Fri, 06 Sep 2024 14:07:30 -0400 Received: by mail-wr1-x436.google.com with SMTP id ffacd0b85a97d-371941bbfb0so1502997f8f.0 for ; Fri, 06 Sep 2024 11:07:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1725646047; x=1726250847; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=VkmnJaMxqtgMZowGKV1hTj0h4J0GCGj1CbJQcsCClRg=; b=KsLmXti8fyJrXj+A66NPNivXQteCB9ZHHfSLW63tLsvpPQ+HwJ/t+aYF0iblIl2aFE u4KooKxjDDBF7HgzhrKZ6glbXs9QYVakor9juslvT5EYSaBtGR3p1n6356s4wI0pOjKO LRP8RbodhHrWOYVfyHJ/DqQ2p6mdJxMUJQSpd4BpHR8i+pErkiebCkWQZ1ZMdSTvJ26I JBg7dIZFLXriqbV3qrqQyqtTxTqOiHhfT/Bpv3eE4WTzORYXRr5DegmnqP3oLsWbFbGr fNFO4x9Qb4sv+TRF8CuCp+8oTWbQNe7Vf+FTOzBd3culxwwDaYpH1S7ki970iU/0DIJC AfJw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1725646047; x=1726250847; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=VkmnJaMxqtgMZowGKV1hTj0h4J0GCGj1CbJQcsCClRg=; b=ss99bzcU9u96nTus+cs1LZeKtepLYtBvspcyCUxyQu3We3whSYg7hDIZxfrgowZP2s nvY3GY89FqwOCwRxQKSJC5R7wGZJBI59uJ7x5BK7dSn7XTiEjESOF1vYtoVRqKB31loR z9jTWQ9hWOoc4nb0Z0uluNvaEN2ubN+nbDnFtTdiZmq5g8QykrxIJtWV5mD6E+UlCJ++ SSye6tBRXmZDRpT2bKhvq8UBDjwgFs0VTF7ahm0r7/YCCKmrTHpQHqXeVnKeslVOM9hm MHVK6HfBt/lCV/hWRFWlrUdHA/IFofkwlxAtF39f3hp20NWOkanlPdDunqrxByLdzIoH DHfA== X-Gm-Message-State: AOJu0YyeSS+zP0DKNjKvpY88m7GSPvNFMM+0D8WPFZOfKV4TCIAhHP5i wJlUti95efjEgn95mYDVvZg32JT7qwUoF6cNg2NkjznMrJrX1YvNbONS6XkVAZkWLRlYxYekrFb q X-Google-Smtp-Source: AGHT+IFV4AU28HBXTQBYYX5rVec8epmE+aHNHf8s5Nl7e73Pl7CXi2ULj0OS0NoP4CHzQ4PnqR4cUA== X-Received: by 2002:a05:6000:18c9:b0:374:b6b5:4688 with SMTP id ffacd0b85a97d-37892703ea9mr28876f8f.49.1725646046595; Fri, 06 Sep 2024 11:07:26 -0700 (PDT) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [2001:8b0:1d0::2]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-37891657a2csm441860f8f.95.2024.09.06.11.07.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Sep 2024 11:07:26 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Cc: Paolo Bonzini , Thomas Huth , =?utf-8?q?Alex_Benn=C3=A9e?= , =?utf-8?q?Philippe_M?= =?utf-8?q?athieu-Daud=C3=A9?= Subject: [PATCH 2/2] .gitlab-ci.d/crossbuilds.yml: Force 'make check' single threaded for cross-i686-tci Date: Fri, 6 Sep 2024 19:07:23 +0100 Message-Id: <20240906180723.503855-3-peter.maydell@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240906180723.503855-1-peter.maydell@linaro.org> References: <20240906180723.503855-1-peter.maydell@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::436; envelope-from=peter.maydell@linaro.org; helo=mail-wr1-x436.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, T_SCC_BODY_TEXT_LINE=-0.01 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: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org The cross-i686-tci CI job is persistently flaky with various tests hitting timeouts. One theory for why this is happening is that we're running too many tests in parallel and so sometimes a test gets starved of CPU and isn't able to complete within the timeout. Set the MESON_TESTTHREADS environment variable to 1 for this job; this will cause 'meson test' to run only one test at a time. (Note that this relies on the change to meson2make that makes it honour MESON_TESTTHREADS; otherwise it will have no effect.) Signed-off-by: Peter Maydell --- Seems worth a try -- if this doesn't have an effect then we can revert it, but we'll at least have determined what the problem isn't... --- .gitlab-ci.d/crossbuilds.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitlab-ci.d/crossbuilds.yml b/.gitlab-ci.d/crossbuilds.yml index cb499e4ee0d..ca1db011b11 100644 --- a/.gitlab-ci.d/crossbuilds.yml +++ b/.gitlab-ci.d/crossbuilds.yml @@ -70,6 +70,9 @@ cross-i686-tci: ACCEL: tcg-interpreter EXTRA_CONFIGURE_OPTS: --target-list=i386-softmmu,i386-linux-user,aarch64-softmmu,aarch64-linux-user,ppc-softmmu,ppc-linux-user --disable-plugins --disable-kvm MAKE_CHECK_ARGS: check check-tcg + # Force 'meson test' to run only one test at once, to + # see whether this reduces the flakiness of this CI job. + MESON_TESTTHREADS: 1 cross-mipsel-system: extends: .cross_system_build_job