From patchwork Mon Jan 8 15:13:40 2024 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: 760765 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp935112wrz; Mon, 8 Jan 2024 07:14:11 -0800 (PST) X-Google-Smtp-Source: AGHT+IFzXJdODmIHYcCHyIS6xc1Dp+K+SEGl+AaiGUUCi9OPie/rMb4OtfNmeCGvaWGvC/IaD1VE X-Received: by 2002:a05:6122:4199:b0:4b6:c31f:5b26 with SMTP id cf25-20020a056122419900b004b6c31f5b26mr754991vkb.4.1704726851467; Mon, 08 Jan 2024 07:14:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726851; cv=none; d=google.com; s=arc-20160816; b=vldmP+V93Gbui72ytamJPo4gVk/b8czDEpoHHsZpIQgQloj16MVfSxun0t64tun/ft CntmRKkfRbk55d+GakyOGwzWKbY5JHUWnA3QBWliMfZ5JPJWX0yG6g/ma6LUMMklTI3h pTJaIx9swZOpNaKjHaglNDiCrgLwsJQ8fdLy/iBM/YqQyixnlxFNaTKX7DMLVXKP1Ss7 LBFh2m6DNjw1UC3b37F/pgP+sD+QHPc9W91tGFPAi5Ff88R5+fDIKdbuuNHBqsfVAGIB vWKy2QISPoijSbtmtphAbzbWey3OZd7wi7lXJcI3Q725UyG7XaJApLKG1kBB94BspX5g gAXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=OXuo8l/nA31Hwk3vdPvJmIYU7WuVY275jbIT2FWOsWk=; fh=MAaRFPXnyoD4zwhHv10xEZgOaBqaA6euXTk2ZPLPe8M=; b=OtUd+DfN9U7V+QUPcd5nmG0ZxYRQ+y5XVExF2/5zC0yyFxfYkcAmZXxm3ZTlpZB8c1 it1OtBXa1HAfX9AUpehw/gQGLOf29ojm3+jyHmsxhojoi/89Swzyl505WXr7xkvt6SM7 Ia7B2meSe8+lQ+V+vXfKYZqdWRoO3hojoXv2B3z4nHzKf2lzD+X2RwSjbD+jbyadRzXO TYw9kI763BxTdrSRwSAFmYzIAhiGUYQmf/O9ER9dCWp2cS0D7HYdfZVbwtT+bNzvqj9B fs/QF8nUPifN0P8mkaB+1lhjZG6jzdpoXOa74EOTBCkx8FDDdc8I3a9gMmUkDGYsvq4b xy0A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=fbXAgWJP; 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=pass (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 u28-20020ac5ca9c000000b004b6f2421c17si26384vkk.139.2024.01.08.07.14.11 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:14:11 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=fbXAgWJP; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKB-0004CS-Sb; Mon, 08 Jan 2024 10:13:59 -0500 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 1rMrKA-0004C9-1h for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:13:58 -0500 Received: from mail-wr1-x42b.google.com ([2a00:1450:4864:20::42b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrK7-0001Wc-Tf for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:13:57 -0500 Received: by mail-wr1-x42b.google.com with SMTP id ffacd0b85a97d-3368d1c7b23so1938529f8f.0 for ; Mon, 08 Jan 2024 07:13:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726834; x=1705331634; 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=OXuo8l/nA31Hwk3vdPvJmIYU7WuVY275jbIT2FWOsWk=; b=fbXAgWJPYjahZYqelUbD5rFvFE5XoA5rhDWul6ietHWtr08EvhVsXI6bbOtbj+T2p6 nOyH0aJQ7Dr713nJ7RqwaS4a5K7aV2MhODNM+yzJOrL3I/DK+InCtsdEmG8y3zErFSC6 FhzeMalnYhnFk9q4C7ZLIlDYv48Dwqb3/dWtZjDh7PkdVWPO5JcQOUrO9EeSBstbuOzp UAFV7pqzftjbK5ZHml0jci2iE4tJyNEskgsCM17JjgBV+2knYXdz1gke1wnTvHRS5o2r YwQsBhdnUzg7EWiH1hTwTUryfP42IXUF2PB2DT4HJ2TC7NWkHxVpnuWuvG0BzH4scs7g k7Gg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726834; x=1705331634; 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=OXuo8l/nA31Hwk3vdPvJmIYU7WuVY275jbIT2FWOsWk=; b=eO+5gjuyNPv03oKX1q/5hcaZS5kToCbOeySARQ7Z6w/JVu3S7J0iC+1rYukNGY0/kT qTBU0Di8szBPxKgm2osMVCUDJdSzu2SpaYZoVwPk/PKqUWBm5rZU6LfxTVrWj6PmNqA3 YojxuNIaT0rMAwc+vHbxJyfB51jZbFxhLC/oIajzDnPeWyTzYMSrzoTM0Kr8wDrNVj8O AiPnuHI0lnjiKf5bBiS2YAg3t7WS+owJJxCrNEe+72YMEycZ4zbOYFyCEIzYNANFXE/Y OrOsIVUNAG+b12RLAv15Y1DueB05pTrt5DhHkRm074WR+lDNC3wb41eyIzNUui9T8oeE rlWw== X-Gm-Message-State: AOJu0YyEXOZaWlvutBQx4Z+fhVQalRn3hcrjOqu0AKzxzrRZQlxzJhfW RnYtYDG93jhrgIB2ixKtcP8Hn9DbC/IAyQ== X-Received: by 2002:a5d:5184:0:b0:337:2296:adb0 with SMTP id k4-20020a5d5184000000b003372296adb0mr1925590wrv.54.1704726833743; Mon, 08 Jan 2024 07:13:53 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id a5-20020adffb85000000b003376af392e5sm2440383wrr.38.2024.01.08.07.13.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:13:53 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id F37B85F93F; Mon, 8 Jan 2024 15:13:52 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Pavel Dovgalyuk , Richard Henderson , Pavel Dovgalyuk , Paolo Bonzini , Cleber Rosa , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PULL 01/13] tests/avocado: add a simple i386 replay kernel test Date: Mon, 8 Jan 2024 15:13:40 +0000 Message-Id: <20240108151352.2199097-2-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42b; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42b.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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org There are a number of bugs against 32 bit x86 on the tracker. Lets at least establish a baseline pure kernel boot can do record/replay before we start looking at the devices. Acked-by: Pavel Dovgalyuk Acked-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-2-alex.bennee@linaro.org> diff --git a/tests/avocado/replay_kernel.py b/tests/avocado/replay_kernel.py index c37afa662c2..1eaa36444cb 100644 --- a/tests/avocado/replay_kernel.py +++ b/tests/avocado/replay_kernel.py @@ -82,6 +82,22 @@ def run_rr(self, kernel_path, kernel_command_line, console_pattern, class ReplayKernelNormal(ReplayKernelBase): + def test_i386_pc(self): + """ + :avocado: tags=arch:i386 + :avocado: tags=machine:pc + """ + kernel_url = ('https://storage.tuxboot.com/20230331/i386/bzImage') + kernel_hash = 'a3e5b32a354729e65910f5a1ffcda7c14a6c12a55e8213fb86e277f1b76ed956' + kernel_path = self.fetch_asset(kernel_url, + asset_hash=kernel_hash, + algorithm = "sha256") + + kernel_command_line = self.KERNEL_COMMON_COMMAND_LINE + 'console=ttyS0' + console_pattern = 'VFS: Cannot open root device' + + self.run_rr(kernel_path, kernel_command_line, console_pattern, shift=5) + # See https://gitlab.com/qemu-project/qemu/-/issues/2010 @skipUnless(os.getenv('QEMU_TEST_FLAKY_TESTS'), 'Test sometimes gets stuck') def test_x86_64_pc(self): From patchwork Mon Jan 8 15:13:41 2024 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: 760772 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp935802wrz; Mon, 8 Jan 2024 07:15:21 -0800 (PST) X-Google-Smtp-Source: AGHT+IHs47++60kt2skc1p7zdI5gDHauvgaBD6vYI4bvlf3mTPGjAAFsexHfJER/gsxRT9rmwDRT X-Received: by 2002:a05:6808:244a:b0:3bb:bfb1:dbdc with SMTP id bw10-20020a056808244a00b003bbbfb1dbdcmr3095575oib.104.1704726921031; Mon, 08 Jan 2024 07:15:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726920; cv=none; d=google.com; s=arc-20160816; b=bL0Q5DleV9WYK/nE4ALD+LzdOenDdi9p7fjZJG3bZzBMSrfBKiti3/Np9T3ifjXQWE Hq18+kyA7h4z2qqNxDpoMwVOcjsdTIkemQz0K2sz1rsfvvXBuvAlpZDW5G+qC321vpc6 Lz2XptTA5DB4+/EkPaQKHMTutnC45HyIi4lJzw1TFSq2nrTm5YVR0KJ0CYACcDrKbLi0 IiIqqOQv6BJBzjKG6QJqFNXzQPuZFmshVNXm0gStobUXg/Rlw6AeKW9M2IUJSj1PmeLC zc5qoqVUy3letBiSZ7MqJTkHju6X8yq931sK+x9tx4x0M4LM0KbXqQoBDE9w+v3V7rPI 0YTw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=wnYL/+L/m9RcK0IeiSLcPjsAr8XsHeZX4IFVvVVgTiE=; fh=DuHmGyobGheJG+Dsu2XJpSNwovH7B+uX1ztCvRm+mXc=; b=LXvWFlCZR23yqAQDRlCD5R04/WG3cvI8REe6i3m5q7DqLMCFgkhMuQLxvFAiYZS1qq z8kK9nCXVKhtGEMAWHJziAt5ovuL3qKf68xFp6ZImoaEZVIfaAdxFECYquQMxS1f9YCV 5k4VXLnrAaKyKxOmpaAK84c0mfXXrM90LlBSTIBTirBODrbbwrmyxIJ44gIUiMXG8Am5 3efzUgsSPSIIA+NaKmlVTRN8YRfhwH/LEfIwHm15R+y9YWkAvsMz3eD+4HA52DQh4Xyw 0uxvJ0IbFyZbs0NmY4HnvBxmpJg3KPwFF5Fqg5NBOaDvQ9xZTKE8vowIob4zclJJOY5Z 5irA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=I+5hDEFv; 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=pass (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 e22-20020a0cb456000000b0067f8d43804dsi70979qvf.453.2024.01.08.07.15.20 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:15:20 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=I+5hDEFv; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKG-0004Dt-07; Mon, 08 Jan 2024 10:14:04 -0500 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 1rMrKE-0004D9-FQ for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:02 -0500 Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrK8-0001Wl-8M for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:02 -0500 Received: by mail-wr1-x433.google.com with SMTP id ffacd0b85a97d-3367a304091so1894744f8f.3 for ; Mon, 08 Jan 2024 07:13:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726834; x=1705331634; 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=wnYL/+L/m9RcK0IeiSLcPjsAr8XsHeZX4IFVvVVgTiE=; b=I+5hDEFvayNb+0q1B+0rEY46a3fhCvdkJnOZ6OfsPnrXuRB0oO2wJLP9giKRkeA5NF LQjBvq1QhdIkKvCx/sM0lOCjANp2QQfNo13ImkYPT0g8zwjMWWZqIOFH+r3eThYzXA+i ISpYls4QVruv1/4rCTnGITnvqW2rdUp02pqdyNTwJfzUGZHWINmxhsEyB5DMpoczl1fm gzayI0mlOfamVHb3UlWidXPI67I24ByJ7WDr8TMVp10/oTeSwiH3FV/Swpw5DSxzNqNy 1/4YY5gNP4b19Lg1dDIPOPBhjQr2sgeF6WSSoaHB7YVWXQ517tuyzVDZr5vHPppx9I4M XsOw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726834; x=1705331634; 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=wnYL/+L/m9RcK0IeiSLcPjsAr8XsHeZX4IFVvVVgTiE=; b=vINewTDN9fqY0Kmesu3Dr+fX5xmza18JsLtsRs+hjW7GmuvFwmikwALWH293RGkU69 h8fb+wdd5NaD3DNEyT7mc22sYJ5QFrPWhWZ8KeCwuX0GhhNXYrtZnuocFatI1ZQ3fn0V 4rqHnu0u2YjO0xkqcIY90qMv6a+UGaWh6UDeMiQiCk4hIvUR3FxRlREdNcHXIZb0JkC2 G2rrnQ/e+5/CQlvvzFszsfp1eoQhZ0ghSbi7/B/Ct3rjmiKS3sJnvJnL84jFloNV3K3Q DMqwtuz5yX55ST0AwwhEJzXjWrWVYmN9b4lGuqwJIqYywAXYtihKFhicE/gadGFHJkIy S1ng== X-Gm-Message-State: AOJu0YwxmhlhkpYXItWSAZiZjEEwmQBynD97Kua3bgMxYBj3uXXJwM16 vQ+SuW5vnVKXdXhS+nQNk8IXY7N/cV/qhpuKN6Eo61XlAsI= X-Received: by 2002:a05:600c:1e0a:b0:40e:486f:45ac with SMTP id ay10-20020a05600c1e0a00b0040e486f45acmr377097wmb.19.1704726833941; Mon, 08 Jan 2024 07:13:53 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id v15-20020adfebcf000000b00336673a4153sm8020931wrn.80.2024.01.08.07.13.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:13:53 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 12CDB5F940; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Pavel Dovgalyuk , =?utf-8?q?Philippe_Mathieu-Dau?= =?utf-8?q?d=C3=A9?= , Richard Henderson , Pavel Dovgalyuk , Paolo Bonzini , Cleber Rosa , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PULL 02/13] tests/avocado: fix typo in replay_linux Date: Mon, 8 Jan 2024 15:13:41 +0000 Message-Id: <20240108151352.2199097-3-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-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, T_SCC_BODY_TEXT_LINE=-0.01, T_SPF_TEMPERROR=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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Reviewed-by: Pavel Dovgalyuk Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-3-alex.bennee@linaro.org> diff --git a/tests/avocado/replay_linux.py b/tests/avocado/replay_linux.py index 270ccc1eae8..e95bff32999 100644 --- a/tests/avocado/replay_linux.py +++ b/tests/avocado/replay_linux.py @@ -94,7 +94,7 @@ def launch_and_wait(self, record, args, shift): else: vm.event_wait('SHUTDOWN', self.timeout) vm.wait() - logger.info('successfully fihished the replay') + logger.info('successfully finished the replay') elapsed = time.time() - start_time logger.info('elapsed time %.2f sec' % elapsed) return elapsed From patchwork Mon Jan 8 15:13:42 2024 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: 760770 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp935597wrz; Mon, 8 Jan 2024 07:15:03 -0800 (PST) X-Google-Smtp-Source: AGHT+IG80Sncn3e1HIYt+mvFRS510jQtOGP3/jSbv4nNHul3uhU/3a1xnXqCuuHrW8bdxh/rWN3B X-Received: by 2002:a05:622a:130a:b0:429:8bdc:ce5d with SMTP id v10-20020a05622a130a00b004298bdcce5dmr3304699qtk.87.1704726903554; Mon, 08 Jan 2024 07:15:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726903; cv=none; d=google.com; s=arc-20160816; b=PMVjuIyQwODYgzEitbkjuVF/+4LDFUJdRJg3Nhuk0bt4LSn9ZdFMLCheXT13I9dH6a iAX9/SWKu0hjOfzclaHH60z6d1fdVW3e7M8AdGWKp5VGpOZ997ultIGrdet11/g4JG4z xm7GySfXO6ltJlCGKx+9SSsqXGwkJZb9aKhQ0le2rswBuxWKDjw1UjgbZRS5yS9aKGem 4p5LJcFd8D9vOjmlS7++gLq4Qa3v5mYYu3UIiVEDtXJ+hK1dfFIbZmOTq6cXuTnavtIj s+SiyKKXrGl9sStO8LlKRZKlqlyqvZEs4sPgZQZ8fnHLjZfZv/2rZLfaUVsbtcYyC9AS 1B6A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=D+qYSiNuHCw9vpeOMvQUbkSg7Ml8q939vYKp9TceBTU=; fh=Arx73Mj5ZbsiQoNGhMleF485LHX8jGL6juntVeo59X8=; b=gY2qtSR8N88DtxIRXPcnTLWZnTFQ6MDdB+zatgTyCkB22/2b8zKccL+lHXnKBGSNrE YEETRTes+GSUVZOwDYFgFKKSBIHxwMXWR9BF10GKfJQ2MIrGJh9EA4jBw6Xk+7V08HRa 9RLamZVVFpsdLxgFBqvkdw/uyClfVjQsiN+glIgjc42hN3sNSGwLO9SaesvEIFaplgxf N5ONaaOVmUn4EZBQAIxT9q76gmTp2xSxSGTrWLQJuhK7mFDdOuSuPcor6394fNvNREJo 721jtW5TWztfc/wzaAVoEq8j1z5PIH5U48vESUyWb8URAiRZwYajpXmS3ElfByibUHQl vTAA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="o/FI/5r+"; 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=pass (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 f9-20020ac85d09000000b004281e7364f5si4458718qtx.455.2024.01.08.07.15.03 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:15:03 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b="o/FI/5r+"; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKN-0004JM-Hu; Mon, 08 Jan 2024 10:14:11 -0500 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 1rMrKL-0004Gk-Ml for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:09 -0500 Received: from mail-wm1-x333.google.com ([2a00:1450:4864:20::333]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKA-0001YJ-WC for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:09 -0500 Received: by mail-wm1-x333.google.com with SMTP id 5b1f17b1804b1-40e45504006so7481445e9.1 for ; Mon, 08 Jan 2024 07:13:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726836; x=1705331636; 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=D+qYSiNuHCw9vpeOMvQUbkSg7Ml8q939vYKp9TceBTU=; b=o/FI/5r+Uum1O0bvD5lHergn1BHTM4ASLdPgayHTsdzkBUPQ6k56oa7um9OeiAEMn5 SjS/7/04CzB62fEuoUPmy1dgABJJcG9DyD6nbzBWT1+pmh756qMSh0J7eYJeR4Z0C23a P+HpzMolEoOu8phodHcMoudtP5iS4cESy/liOUs76CORtRmOlyjvSFBxxELTpz8rafgI CK8+Sq6bSEzFvF4bDRWDRb0mtSsiHg46BmaY/3CthBBQ6Vq5UA25MLEsQkM94lpwNfQs jf5kFQkgjBMJPNHvCT6zgRH/r2yTGNTeQWBDpTPRh846+/DjEO4qD4UScr3WIL3unYkO 6z2Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726836; x=1705331636; 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=D+qYSiNuHCw9vpeOMvQUbkSg7Ml8q939vYKp9TceBTU=; b=HhJrrTZyHvE2DpQTyatNPaS3vdZK6uCNx0oRfQHbVP8RYvwHSIGRbEh2WtRUnWv4rL j8dSNs7tPhKhgUyt0EujL8mGYaLfYVBEWKjSNgbm6dvcxV9o5PWkgI8NoSftv/RlWWLq jlgnzQeCz1j1jXWmFpVL6YGrKG8gteh0CIfKqpEgVRsEGIDrI4hV5KezlIlbeieiYtVY Bqvcaehz+E0XPm/4DWo52eFIrk0LuoHSBVESTGa41/NdZoG3T/iczPEEqsUPjowkjYl5 uDx+RNcagZg+baz3dnumVBx7tfSYhPrKiFIITk/qGy9Xk011xjY4JJsM3YZduvx2+qH4 6Ouw== X-Gm-Message-State: AOJu0YyMnSxhjZf+XTBJv5eHwC7nB09pnzzZ2e2o9nbsJNcy2DmQORH1 0FN/bWMlpJkKUL1unHYlbIluk+1EH7TMeA== X-Received: by 2002:a05:600c:3f87:b0:40e:44c3:e0eb with SMTP id fs7-20020a05600c3f8700b0040e44c3e0ebmr1167197wmb.28.1704726836343; Mon, 08 Jan 2024 07:13:56 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id j23-20020a05600c1c1700b0040d8ff79fd8sm150554wms.7.2024.01.08.07.13.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:13:53 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 28A885F942; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Pavel Dovgalyuk , Paolo Bonzini , Cleber Rosa , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PULL 03/13] tests/avocado: modernise the drive args for replay_linux Date: Mon, 8 Jan 2024 15:13:42 +0000 Message-Id: <20240108151352.2199097-4-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::333; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x333.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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org QEMU complains about us not being explicit with setting snapshot so lets do that. Also as cdroms are RO media we don't need to jump the hoops of setting up snapshots and replay disks - just declare the drive is a cdrom and nothing should change. Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-4-alex.bennee@linaro.org> diff --git a/tests/avocado/replay_linux.py b/tests/avocado/replay_linux.py index e95bff32999..f3a43dc98c2 100644 --- a/tests/avocado/replay_linux.py +++ b/tests/avocado/replay_linux.py @@ -48,12 +48,15 @@ def vm_add_disk(self, vm, path, id, device): bus_string = '' if self.bus: bus_string = ',bus=%s.%d' % (self.bus, id,) - vm.add_args('-drive', 'file=%s,snapshot,id=disk%s,if=none' % (path, id)) + vm.add_args('-drive', 'file=%s,snapshot=on,id=disk%s,if=none' % (path, id)) vm.add_args('-drive', 'driver=blkreplay,id=disk%s-rr,if=none,image=disk%s' % (id, id)) vm.add_args('-device', '%s,drive=disk%s-rr%s' % (device, id, bus_string)) + def vm_add_cdrom(self, vm, path, id, device): + vm.add_args('-drive', 'file=%s,id=disk%s,if=none,media=cdrom' % (path, id)) + def launch_and_wait(self, record, args, shift): self.require_netdev('user') vm = self.get_vm() @@ -65,7 +68,7 @@ def launch_and_wait(self, record, args, shift): if args: vm.add_args(*args) self.vm_add_disk(vm, self.boot_path, 0, self.hdd) - self.vm_add_disk(vm, self.cloudinit_path, 1, self.cd) + self.vm_add_cdrom(vm, self.cloudinit_path, 1, self.cd) logger = logging.getLogger('replay') if record: logger.info('recording the execution...') From patchwork Mon Jan 8 15:13:43 2024 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: 760769 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp935573wrz; Mon, 8 Jan 2024 07:15:00 -0800 (PST) X-Google-Smtp-Source: AGHT+IG+4Eq0F8A5yhYP7n6c3vcndoAUlp04kO5DO4GvCVKcuksfJw4QnxEQ3cdCpLOsy4V3eVUE X-Received: by 2002:ac8:5519:0:b0:429:7621:ed42 with SMTP id j25-20020ac85519000000b004297621ed42mr6495472qtq.56.1704726900269; Mon, 08 Jan 2024 07:15:00 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726900; cv=none; d=google.com; s=arc-20160816; b=aSpeguojOH0jFyWr7gAKb/yZr1pZjHCEJXDfq+YFCuUrHGRY8c79ckfxCr2TsQtiig fVraKSYCVPkC2hD+J9A2cvUzQEHeahjgRe/JwUVVj0BfzJcyb5KFsBEVdGmxDJR8sHGw I7j9Wb2HQy0lR85VJUkQu16tKFlKR0I+hi2B1JpIKTMCGP6CCru7dUeCuZCeNKY7Oh54 u90rMCWjOnq9Ja9dVgLxCRsBXtFie9s5C7k09PWaMiJQNsEIbQ1fSuAEUa76fTR4M9yc j5XO0amTc01hYuLBZab0G2vaip0RYO+GIW9A74jgoscjS5RjEel/h0KDp5vpva+4vA4e Jmqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=ytoJGUOfVhpGlmTk7EPY0JIdgCeWa/v+zzjLeogcti8=; fh=ra0OSLEMXNlonSyKAVIM13n8iWfD/AoKsZMvSls3j/k=; b=T5u+DibMQ7Q2M8FnYmuMZR3JTeYlVzDD3sQJfV+26b2k3/ZKjYsTnkGBiEXEz3GN+G 3mqqBC1ls4iyOWtziL4t7P50+Hjo2ZcibGFQP+5hdEbVW6kVRU041xLbe7My5CQDQ2Fs C4N95/Pd3QAiwb5+RZfIuLcZDeX1zMmm3L5Gr+/Sdjq/jJ6mb8KxaDplttFZROYQOdJX ocbbXhko3I5huSVP6MxwuhR+Nj+pdyLRxM87zjxyyZUfK4StYBnLvEBLHwkbHhJ4Am+K P0B/aPlMhbzukpZg4xV/HbgtEcbu0hUSF0k2XgCyU7VBj1G5DlcaCQXysau1vs9zbD3x 1b0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=DpUrXjZV; 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=pass (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 d7-20020ac85ac7000000b0042992d10b30si2782428qtd.643.2024.01.08.07.15.00 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:15:00 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=DpUrXjZV; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKH-0004Ei-Lk; Mon, 08 Jan 2024 10:14:05 -0500 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 1rMrKF-0004Do-Nu for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:03 -0500 Received: from mail-wr1-x42e.google.com ([2a00:1450:4864:20::42e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKA-0001YM-5M for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:03 -0500 Received: by mail-wr1-x42e.google.com with SMTP id ffacd0b85a97d-336788cb261so1852102f8f.3 for ; Mon, 08 Jan 2024 07:13:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726836; x=1705331636; 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=ytoJGUOfVhpGlmTk7EPY0JIdgCeWa/v+zzjLeogcti8=; b=DpUrXjZV95ey8DPQn+7cGZO+fQof3YY2Ni12pA92IRMpzVJ7YGOcHnDk7BKV2LYttK S6SdbYMF+oTgF2XB+OR2fHpY04vyz6Z9HK520G4hiLy3NKebl3O54DGr1QmJGzvo8LB3 e/JO2xDMLqJlDd6q+2hif7vpu8qYFP2MBw+GNn7wFi0e3kY8AAO6/K5Klzd8yhLarWpJ ywHTwIgbmMMzq4y/T62PRVbQ09zjYkJsD9eEMKiwZ+FuvYRHxayfOkQ/XPRkgQY/Izlb jSOQQomHe6Ig2+C59Fq9d5Rm2S9ntAV3WtdGGMbEFKOg5P9fkYOJk/cgqKp1WbJlm0e/ M8fA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726836; x=1705331636; 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=ytoJGUOfVhpGlmTk7EPY0JIdgCeWa/v+zzjLeogcti8=; b=jOB5jNRYlwe/Eb8EUvtguNt+KwYDahkeIvRl6YxhzRpSX+RyHSaDr1FLYo6FKBvlqM sSBLcTroZ/ZsSkQpht/caZWsxvwlq8QNSwaw3q8I9Hdv+YxqWcJ4TpqpSpy3AMzj6xKd D+mBBgZ4OfkB1WOaBErW//mv7DjbfPEX3v0GElwhFGmssOEqObrp8EbIr9uVgsq64XP2 Wb9uIUPT6w3/D374o2dnD26N71bsut4QnZjzHeuagmDkCTdxMs0InJdvaOpwMxuZaBoQ 1ACE4GabV+OZh1V93XRiS03Z2ozfma7Dy/BhQGJZWG+99WnTL492CZHh6Eot6Uduwubh CIPg== X-Gm-Message-State: AOJu0YyO9PlSBMHO0vwrbhO0TZmmtxxDp0MFeu3GHJvN8zw43fZPw32p KUsK5iznHL/jn1Swo2jjqp3HX07ShQyvlcuZVF2Rrv/zEv8= X-Received: by 2002:a5d:4343:0:b0:337:5b64:7414 with SMTP id u3-20020a5d4343000000b003375b647414mr1763861wrr.100.1704726836540; Mon, 08 Jan 2024 07:13:56 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id l3-20020adff483000000b0033719111458sm8056448wro.36.2024.01.08.07.13.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:13:53 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 3C7F25F944; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Richard Henderson , John Snow , Cleber Rosa Subject: [PULL 04/13] scripts/replay-dump: update to latest format Date: Mon, 8 Jan 2024 15:13:43 +0000 Message-Id: <20240108151352.2199097-5-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-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, T_SCC_BODY_TEXT_LINE=-0.01, T_SPF_TEMPERROR=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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org To help debugging replay logs I've implemented decode_plain and decode_char_write as well as put in a new table for the current format of log. Reviewed-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-5-alex.bennee@linaro.org> diff --git a/scripts/replay-dump.py b/scripts/replay-dump.py index b89dc29555a..6f300e4c54e 100755 --- a/scripts/replay-dump.py +++ b/scripts/replay-dump.py @@ -21,6 +21,7 @@ import argparse import struct from collections import namedtuple +from os import path # This mirrors some of the global replay state which some of the # stream loading refers to. Some decoders may read the next event so @@ -82,6 +83,12 @@ def read_qword(fin): "Read a 64 bit word" return struct.unpack('>Q', fin.read(8))[0] +def read_array(fin): + "Read a sized array" + size = read_dword(fin) + data = fin.read(size) + return data + # Generic decoder structure Decoder = namedtuple("Decoder", "eid name fn") @@ -115,6 +122,11 @@ def decode_unimp(eid, name, _unused_dumpfile): print("%s not handled - will now stop" % (name)) return False +def decode_plain(eid, name, _unused_dumpfile): + "Plain events without additional data" + print_event(eid, name, "no data") + return True + # Checkpoint decoder def swallow_async_qword(eid, name, dumpfile): "Swallow a qword of data without looking at it" @@ -151,6 +163,12 @@ def decode_instruction(eid, name, dumpfile): print_event(eid, name, "0x%x" % (ins_diff)) return True +def decode_char_write(eid, name, dumpfile): + res = read_dword(dumpfile) + offset = read_dword(dumpfile) + print_event(eid, name, "%d -> %d" % (offset, res)) + return True + def decode_audio_out(eid, name, dumpfile): audio_data = read_dword(dumpfile) print_event(eid, name, "%d" % (audio_data)) @@ -189,14 +207,19 @@ def decode_clock(eid, name, dumpfile): print_event(eid, name, "0x%x" % (clock_data)) return True +def decode_random(eid, name, dumpfile): + ret = read_dword(dumpfile) + data = read_array(dumpfile) + print_event(eid, "%d bytes of random data" % len(data)) + return True # pre-MTTCG merge v5_event_table = [Decoder(0, "EVENT_INSTRUCTION", decode_instruction), Decoder(1, "EVENT_INTERRUPT", decode_interrupt), - Decoder(2, "EVENT_EXCEPTION", decode_unimp), + Decoder(2, "EVENT_EXCEPTION", decode_plain), Decoder(3, "EVENT_ASYNC", decode_async), Decoder(4, "EVENT_SHUTDOWN", decode_unimp), - Decoder(5, "EVENT_CHAR_WRITE", decode_unimp), + Decoder(5, "EVENT_CHAR_WRITE", decode_char_write), Decoder(6, "EVENT_CHAR_READ_ALL", decode_unimp), Decoder(7, "EVENT_CHAR_READ_ALL_ERROR", decode_unimp), Decoder(8, "EVENT_CLOCK_HOST", decode_clock), @@ -215,10 +238,10 @@ def decode_clock(eid, name, dumpfile): # post-MTTCG merge, AUDIO support added v6_event_table = [Decoder(0, "EVENT_INSTRUCTION", decode_instruction), Decoder(1, "EVENT_INTERRUPT", decode_interrupt), - Decoder(2, "EVENT_EXCEPTION", decode_unimp), + Decoder(2, "EVENT_EXCEPTION", decode_plain), Decoder(3, "EVENT_ASYNC", decode_async), Decoder(4, "EVENT_SHUTDOWN", decode_unimp), - Decoder(5, "EVENT_CHAR_WRITE", decode_unimp), + Decoder(5, "EVENT_CHAR_WRITE", decode_char_write), Decoder(6, "EVENT_CHAR_READ_ALL", decode_unimp), Decoder(7, "EVENT_CHAR_READ_ALL_ERROR", decode_unimp), Decoder(8, "EVENT_AUDIO_OUT", decode_audio_out), @@ -250,7 +273,7 @@ def decode_clock(eid, name, dumpfile): Decoder(10, "EVENT_SHUTDOWN_GUEST_RESET", decode_unimp), Decoder(11, "EVENT_SHUTDOWN_GUEST_PANIC", decode_unimp), Decoder(12, "EVENT_SHUTDOWN___MAX", decode_unimp), - Decoder(13, "EVENT_CHAR_WRITE", decode_unimp), + Decoder(13, "EVENT_CHAR_WRITE", decode_char_write), Decoder(14, "EVENT_CHAR_READ_ALL", decode_unimp), Decoder(15, "EVENT_CHAR_READ_ALL_ERROR", decode_unimp), Decoder(16, "EVENT_AUDIO_OUT", decode_audio_out), @@ -268,6 +291,48 @@ def decode_clock(eid, name, dumpfile): Decoder(28, "EVENT_CP_RESET", decode_checkpoint), ] +v12_event_table = [Decoder(0, "EVENT_INSTRUCTION", decode_instruction), + Decoder(1, "EVENT_INTERRUPT", decode_interrupt), + Decoder(2, "EVENT_EXCEPTION", decode_plain), + Decoder(3, "EVENT_ASYNC", decode_async), + Decoder(4, "EVENT_ASYNC", decode_async), + Decoder(5, "EVENT_ASYNC", decode_async), + Decoder(6, "EVENT_ASYNC", decode_async), + Decoder(6, "EVENT_ASYNC", decode_async), + Decoder(8, "EVENT_ASYNC", decode_async), + Decoder(9, "EVENT_ASYNC", decode_async), + Decoder(10, "EVENT_ASYNC", decode_async), + Decoder(11, "EVENT_SHUTDOWN", decode_unimp), + Decoder(12, "EVENT_SHUTDOWN_HOST_ERR", decode_unimp), + Decoder(13, "EVENT_SHUTDOWN_HOST_QMP_QUIT", decode_unimp), + Decoder(14, "EVENT_SHUTDOWN_HOST_QMP_RESET", decode_unimp), + Decoder(14, "EVENT_SHUTDOWN_HOST_SIGNAL", decode_unimp), + Decoder(15, "EVENT_SHUTDOWN_HOST_UI", decode_unimp), + Decoder(16, "EVENT_SHUTDOWN_GUEST_SHUTDOWN", decode_unimp), + Decoder(17, "EVENT_SHUTDOWN_GUEST_RESET", decode_unimp), + Decoder(18, "EVENT_SHUTDOWN_GUEST_PANIC", decode_unimp), + Decoder(19, "EVENT_SHUTDOWN_GUEST_SUBSYSTEM_RESET", decode_unimp), + Decoder(20, "EVENT_SHUTDOWN_GUEST_SNAPSHOT_LOAD", decode_unimp), + Decoder(21, "EVENT_SHUTDOWN___MAX", decode_unimp), + Decoder(22, "EVENT_CHAR_WRITE", decode_char_write), + Decoder(23, "EVENT_CHAR_READ_ALL", decode_unimp), + Decoder(24, "EVENT_CHAR_READ_ALL_ERROR", decode_unimp), + Decoder(25, "EVENT_AUDIO_IN", decode_unimp), + Decoder(26, "EVENT_AUDIO_OUT", decode_audio_out), + Decoder(27, "EVENT_RANDOM", decode_random), + Decoder(28, "EVENT_CLOCK_HOST", decode_clock), + Decoder(29, "EVENT_CLOCK_VIRTUAL_RT", decode_clock), + Decoder(30, "EVENT_CP_CLOCK_WARP_START", decode_checkpoint), + Decoder(31, "EVENT_CP_CLOCK_WARP_ACCOUNT", decode_checkpoint), + Decoder(32, "EVENT_CP_RESET_REQUESTED", decode_checkpoint), + Decoder(33, "EVENT_CP_SUSPEND_REQUESTED", decode_checkpoint), + Decoder(34, "EVENT_CP_CLOCK_VIRTUAL", decode_checkpoint), + Decoder(35, "EVENT_CP_CLOCK_HOST", decode_checkpoint), + Decoder(36, "EVENT_CP_CLOCK_VIRTUAL_RT", decode_checkpoint), + Decoder(37, "EVENT_CP_INIT", decode_checkpoint_init), + Decoder(38, "EVENT_CP_RESET", decode_checkpoint), +] + def parse_arguments(): "Grab arguments for script" parser = argparse.ArgumentParser() @@ -278,14 +343,18 @@ def parse_arguments(): def decode_file(filename): "Decode a record/replay dump" dumpfile = open(filename, "rb") - + dumpsize = path.getsize(filename) # read and throwaway the header version = read_dword(dumpfile) junk = read_qword(dumpfile) + # see REPLAY_VERSION print("HEADER: version 0x%x" % (version)) - if version == 0xe02007: + if version == 0xe0200c: + event_decode_table = v12_event_table + replay_state.checkpoint_start = 30 + elif version == 0xe02007: event_decode_table = v7_event_table replay_state.checkpoint_start = 12 elif version == 0xe02006: @@ -299,8 +368,13 @@ def decode_file(filename): decode_ok = True while decode_ok: event = read_event(dumpfile) - decode_ok = call_decode(event_decode_table, event, dumpfile) + decode_ok = call_decode(event_decode_table, event, + dumpfile) + except Exception as inst: + print(f"error {inst}") + finally: + print(f"Reached {dumpfile.tell()} of {dumpsize} bytes") dumpfile.close() if __name__ == "__main__": From patchwork Mon Jan 8 15:13:44 2024 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: 760776 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp936351wrz; Mon, 8 Jan 2024 07:16:21 -0800 (PST) X-Google-Smtp-Source: AGHT+IE8lkpUbz6O8z5VtPqKZT7HO5wVThs12Y2OjVjM0QgE5u6fVpI2FrVOv4h/bOVWpMiJb7ee X-Received: by 2002:a05:6808:1245:b0:3bb:d122:9a47 with SMTP id o5-20020a056808124500b003bbd1229a47mr3303932oiv.13.1704726981200; Mon, 08 Jan 2024 07:16:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726981; cv=none; d=google.com; s=arc-20160816; b=XeBo9LY+m+kfKQPb+WXf4b6/lW9zsGSo9z52tIXLlNrwYwocZWoFTgz+IkbB27GBsF PFb0LdoQ+kptVxhaZjuLrPBSYZ8EcPZMxUG6qlizbcJ5AuOqTkG60+HnaviZougr4vMw KFgpFSWHpNY/X+w+45rhsPKQvYxSPZTdNTQ9cPnauDryXpE2n2DJPfEJ6+SWOSPOLB4N ubJPmIFjGedUabTLT8QK4vzYpVYfOO1UssI0ec3bn4WEthLpZ3YmFukENBLoPTyt2vxS Ip6almXwSu/a8he+HHfm4NHNWAbcOEAf4+rJ13iu+B3GExcRCvxGo69Hx+PGIAZoMCai yPfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=AwDKE536xixs1EyATvmJWMG8HzyVCBtTOCg149auIRI=; fh=NxPT/FbXjTzIhvLKInfxDJs5HKvPoLPUT6F25/FErrM=; b=FHrb47xcTHpo1pyfIwUZHPSUMSUyyT8O/r6vqieC3rlmyzJPMhvS12kUN3xjq3xVT5 udOxkQBJ7/m04kLT8q6jrHr9J+CqlxuupN4gjxJo4FBDP0I14CJaLiyaXPBpAYLuyqrb 4uRYWeZ24tZX7UbPTz9NHX0kDqI+y9NcYTd+TxeHvS8G++qHjzJu8fpu9PYSoqce2B1t AcRODJEITLQI1lHoexxVEMBaGyqwa3lzaI+PNEgH8hYVVlZvqK22vJ6tuPH3sWNijTdv eSXNmfK7hKIeUv6s78c62tRSxBwo45BwKUSn6e7kNPHCi1qGXSyVWh8Fy8oiIQNscWvk I7yg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=QiufuyNw; 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=pass (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 jf5-20020a05610217c500b00466fc147dafsi29384vsb.10.2024.01.08.07.16.21 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:16:21 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=QiufuyNw; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKK-0004Fq-45; Mon, 08 Jan 2024 10:14:08 -0500 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 1rMrKH-0004Ej-NF for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:05 -0500 Received: from mail-wm1-x32e.google.com ([2a00:1450:4864:20::32e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKE-0001ak-NV for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:05 -0500 Received: by mail-wm1-x32e.google.com with SMTP id 5b1f17b1804b1-40d5336986cso25384865e9.1 for ; Mon, 08 Jan 2024 07:14:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726840; x=1705331640; 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=AwDKE536xixs1EyATvmJWMG8HzyVCBtTOCg149auIRI=; b=QiufuyNwMTV1H55JtJ8X1Yzx5GMAFhD5rqZStaV/emhkLY4aDfKvUeAucwn9feANOr D1se0IKVOmkvgQhcNl2Ui4zym0Ibszja10d+t7aDLm5K6vMaHCuUuOd5jX4+w1W1aOR8 NfDXjErm8xkLugGk0QcJbELLxts9VHq9rSH3FkkelSUNXrgPagHURs92/vsWHbghAYSz z7yR6xdGrb0LuR8nHIA5Dmx6j4IdDpJ9Dh7yjQpi2kDnEL0NrF2JBN66uGWyz3fSy7Mr 6fPm2qxVISU7FeRPHIC80mGo/q6kydy9Yp8E9E9C3PHOSguDgc4Ok4/EhMFTn2GRhlNw q5Vw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726840; x=1705331640; 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=AwDKE536xixs1EyATvmJWMG8HzyVCBtTOCg149auIRI=; b=U98agXRzPWyVOCO9WHOEHx+d+TU4iXH9jHrVplQTdsvGVHH8ZCAmQlZKlTe9V5PRXu krHaLjt8/c44KQ99jUn8DvOnxGWHa4CtsPqAkseSfy+c4mZrwxqE7J3DVu5sfi1Het5/ 7uY9XT6q4KS/p+4XmvcE1kfJr6RHpSplKCbV6nlk/M5rFGSaTaFVmAE9+W4lERMXJHP+ 6MZC92ggy6AK4yQyrQGWeOKsqF6p9P+Rc+XtDsXzZD+OF5HC//W7prx4nFuUp/Nxk6FJ It4Znh145wTr8ro+TmqEWcKLNkDqyhzW1LjS7A0WKConE9Lr+PGpbMq1X2CJfDmEWaEZ CKHA== X-Gm-Message-State: AOJu0YxfJG9pZhLgeMsI32emgV/7IFDlT59fXKkHXmKbWyJ96WAiglG8 hEdScDYZc8i6Lujl/wIH9BuPeGiaQ0I6RQ== X-Received: by 2002:a05:600c:4e0e:b0:40e:4b1c:13db with SMTP id b14-20020a05600c4e0e00b0040e4b1c13dbmr134175wmq.18.1704726840013; Mon, 08 Jan 2024 07:14:00 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id j1-20020adfe501000000b0033686e8f02dsm8038809wrm.45.2024.01.08.07.13.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:13:56 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 50F065F946; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Pavel Dovgalyuk , =?utf-8?q?Philippe_Mathieu-Dau?= =?utf-8?q?d=C3=A9?= , Richard Henderson , John Snow , Cleber Rosa Subject: [PULL 05/13] scripts/replay_dump: track total number of instructions Date: Mon, 8 Jan 2024 15:13:44 +0000 Message-Id: <20240108151352.2199097-6-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32e; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32e.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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org This will help in tracking where we are in the stream when debugging. Reviewed-by: Pavel Dovgalyuk Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-6-alex.bennee@linaro.org> diff --git a/scripts/replay-dump.py b/scripts/replay-dump.py index 6f300e4c54e..d668193e793 100755 --- a/scripts/replay-dump.py +++ b/scripts/replay-dump.py @@ -157,10 +157,13 @@ def decode_async(eid, name, dumpfile): return call_decode(async_decode_table, async_event_kind, dumpfile) +total_insns = 0 def decode_instruction(eid, name, dumpfile): + global total_insns ins_diff = read_dword(dumpfile) - print_event(eid, name, "0x%x" % (ins_diff)) + total_insns += ins_diff + print_event(eid, name, "+ %d -> %d" % (ins_diff, total_insns)) return True def decode_char_write(eid, name, dumpfile): From patchwork Mon Jan 8 15:13:45 2024 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: 760773 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp935864wrz; Mon, 8 Jan 2024 07:15:26 -0800 (PST) X-Google-Smtp-Source: AGHT+IEbkeHKDcP5ts7Zrr56725dPDjP1NtEC6euyFV6WEJLFjcjMVC+rRMv++1ARn5TzJ1Ntswz X-Received: by 2002:a05:6870:658c:b0:203:6e5c:6d20 with SMTP id fp12-20020a056870658c00b002036e5c6d20mr5328996oab.70.1704726925694; Mon, 08 Jan 2024 07:15:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726925; cv=none; d=google.com; s=arc-20160816; b=0QkZyDhyQL7gtSAPsirjjuQcnsJph9NH5QYKIr1Qwy5W5oAjNwkDOxWIlpBoKM8jfs ZX21u2GGbkKrsJcEtAsIB3JZcndwA6mrrxcDBfbwYasBDYe+0BIYoJhqadpxZZG83nRY 5lLN5feUx7YANIPALW2rb47oRVI31bEc740d0v8tQsxweLTmqUMPHel+UTMINrsBvyC2 MqTltVsUG4SqTwfJ6uMqJ8IUCZQqIXpQj64HjSKAh5HXYPtcjlQAEQTnsL1lHMXLdwKl TMYh+iAQ4eN0fh3+uHD9xQLBOCnDDx8Ur3BDUoDWQO1/dksFzn2pIb7HxBn3yhx71Z+i 7KDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=MMV6mhc2gSysrpUH6HPMUt3N81sB5EX397Qla+10sMg=; fh=kqAo0HFKvioGek6PiJRhKo1I+CuCD3OlToJArz8NN6I=; b=crBKEW6e5pYY2LkL4hWNC0fV2l1VG9d2b+rQnt3/AGBmc1PcChazRZdSluzsNcYPK9 wGo3Gl6LXP7sF+8IDgdu3WVEm8dYra4FKTCXbYUkldYROgpBz41kN5EFTczQJOL82JrP leJrZp9bjngUGiJoFzcGuxxzeU5QXG5Iwmc+/VFdi6mPrCIKf9+q1Wkzxu66SiJjvnFM 6LlFA0dT/F0jzsCzeiNlzmYG6Xh4Ty9WL+FmHERZ9V9gmmFjQh7x/5hBKTg5REGotM0N wsqR+EvYTqI5hi/7hHlFq3OHM26nrO31SsEs5ESX/7mby9SrUWmIxO+b6OryIIG1yy4u RGdg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="JL/NBzuY"; 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=pass (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 y17-20020a05610207d100b00466ffaaa939si20102vsg.257.2024.01.08.07.15.25 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:15:25 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b="JL/NBzuY"; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKF-0004DZ-2T; Mon, 08 Jan 2024 10:14:03 -0500 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 1rMrKD-0004D0-Pu for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:01 -0500 Received: from mail-wm1-x332.google.com ([2a00:1450:4864:20::332]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKA-0001YS-9j for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:01 -0500 Received: by mail-wm1-x332.google.com with SMTP id 5b1f17b1804b1-40e4ad831b0so3241505e9.2 for ; Mon, 08 Jan 2024 07:13:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726837; x=1705331637; 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=MMV6mhc2gSysrpUH6HPMUt3N81sB5EX397Qla+10sMg=; b=JL/NBzuYAFFdo8/Nere2q28B9odOXr5Ls+Vpgc/3bsaw3iHYK+8t0JD72tU9iZjM8j rfrJNzBgsZy3AL5mI/Ubyc4lyokKNdnmTOhHkMqmfqVtYIax7qZpFEyHopl5WuczX1yO 5eEqqaT83Ji3UZXBz5rKcpcU7oH+FPYcOQMdJe2tdDGSpJU3dEmMUHbpB9q+iVzAQTO2 q7iePPhBI72Mv5fZS4wL6rH5UaVVsKIb5Cs1l6s1BYDN1AuZUQmfDaNoq4ufTgBBv54C W8+aXROmSnL74DqerodEivlwAhLizeq0gh6GYSsNeCVU9ZWoezEtxdExTDDvpAnloEIZ r9Sw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726837; x=1705331637; 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=MMV6mhc2gSysrpUH6HPMUt3N81sB5EX397Qla+10sMg=; b=Ar0hj5nbdRua5u7hoSD2/jTpefx6m6UEZ0PFBSvm/TlZZYLv2JKU7OqsclZ3jFe4P0 Xw6ufxdhcKkMPblbby9ejOH3XsDBq8XnMXeHAXMgWjxzo/CEZjxmgW9fFasSIB1uWa3r bsoUALiaKZlPtIoon184FqUD1RYNcnXTnTBEWYlD7faUpYfG/2UQlldscJG0LXnHcsz4 jlwKWpnr+pEIcRHEKuRGrg3rUWJKPkSHJDzIdq9lbfRww5sdkye+ZYyZWXzxjGuX3lCG E9aNPRILhafLeXK7l/AbQiyMSlU9A+uSy4N4MNOJlQy3u6PcjdlPm7rj1kMiDAFf1NVe 5oTw== X-Gm-Message-State: AOJu0YzBIcTArW0aKIIs0PuM9mWPdzQiw0JUluLjqY2BjeHYweZSomAT FYGQ1j9uKB9ZK48gUlFZZPj0Uv/26amwIw== X-Received: by 2002:a05:600c:1f11:b0:40e:49c6:45e0 with SMTP id bd17-20020a05600c1f1100b0040e49c645e0mr454314wmb.23.1704726836834; Mon, 08 Jan 2024 07:13:56 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id m21-20020a05600c3b1500b0040d5c58c41dsm140532wms.24.2024.01.08.07.13.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:13:56 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 63D705F948; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Richard Henderson , Pavel Dovgalyuk , =?utf-8?q?Philippe_Mathieu-Dau?= =?utf-8?q?d=C3=A9?= , Pavel Dovgalyuk , Paolo Bonzini Subject: [PULL 06/13] replay: remove host_clock_last Date: Mon, 8 Jan 2024 15:13:45 +0000 Message-Id: <20240108151352.2199097-7-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-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, 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Fixes: a02fe2ca70 (replay: Remove host_clock_last) Reviewed-by: Richard Henderson Reviewed-by: Pavel Dovgalyuk Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-7-alex.bennee@linaro.org> diff --git a/replay/replay-internal.h b/replay/replay-internal.h index b6836354ac5..516147ddbca 100644 --- a/replay/replay-internal.h +++ b/replay/replay-internal.h @@ -80,8 +80,6 @@ typedef struct ReplayState { This counter is global, because requests from different block devices should not get overlapping ids. */ uint64_t block_request_id; - /*! Prior value of the host clock */ - uint64_t host_clock_last; /*! Asynchronous event id read from the log */ uint64_t read_event_id; } ReplayState; From patchwork Mon Jan 8 15:13:46 2024 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: 760767 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp935338wrz; Mon, 8 Jan 2024 07:14:38 -0800 (PST) X-Google-Smtp-Source: AGHT+IFifOaFMSj9N9uY01fFTqrMyOpfjrEPUYyNVM1nYMMKO2m45SIiMuAyqLTSEBPhlrSH2wr4 X-Received: by 2002:a05:620a:288f:b0:781:a645:8a24 with SMTP id j15-20020a05620a288f00b00781a6458a24mr9642430qkp.55.1704726878162; Mon, 08 Jan 2024 07:14:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726878; cv=none; d=google.com; s=arc-20160816; b=ps18YiB4h5WIdFSkRYXTb2uIyqvnLO+Th/KDMfZ6QdpZjkDLSa2fA+3WefuNH0a9lc i+hqVSHq7CQVt6/QtXuNtfAtdSRyvVOVqnNdlVieU0e8i2VM1EZNC77CPAILlq0GreoM IoGmFRzfJLUsky+aF2yRPxqg6+rm2unzc9R/7mqtj9u36ITfhRpp3QsQ/lWZ1zx6N3ET nHszLxKHm1BPdjdOx7WBCbKv2WR5vFGw9+x0/tBmVa3WfYuVzyj2ZoMD+7DaLjsbP10t YCALFN1hihOBbFA9cH3ZwVSyzOpdBht0+RFJ1wc7Mn2tJzue160hcv0gXquZyJrOmLsD YaQQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=sGtlVmj/cLSRItSFI6o6Pd2FVVc8E9gmG7YjPACLCW8=; fh=bjKFmQKxNnC3SfFt2fSIy5ygbVRALQM+QebBlFG0Z4Y=; b=QFFacmH25FVsRqk4rsHtMj7NbBALY2oOz2hy8rM1Zwjf7iGV/hh21rnd7LeBA7jJ4Z 5h9+4L5eN7c7dvvHwcfJhMngFwPHxJxHLzm1sJt1A3HcaxsRYumTQT2gfFOTdWcFatTb Asf6iiniRUIyLIsKMLqSSZPZilfZ2g2j7qtU6MmmzEM/ZtdYle0rBQsyrCAtVAoSL2Kt sIWGdXYqbJolTcrHV9EXkE48aAwUVWG3s8WEv9kUU9v4k+J82L2Lwa/fJJERP8JxiWDX frqDVd8iw7h2dwDesy9KBHSkA/UeaxZxuoEW/NCR5WbV0OnQjzuJ5GuAe+bOU28NNl0c nJFg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jPRLjZp3; 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=pass (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 da1-20020a05620a360100b0078306193918si7651561qkb.532.2024.01.08.07.14.38 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:14:38 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=jPRLjZp3; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKP-0004LU-4H; Mon, 08 Jan 2024 10:14:13 -0500 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 1rMrKO-0004Jx-0D for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:12 -0500 Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKA-0001Yf-TN for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:11 -0500 Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-40d87df95ddso21231725e9.0 for ; Mon, 08 Jan 2024 07:13:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726837; x=1705331637; 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=sGtlVmj/cLSRItSFI6o6Pd2FVVc8E9gmG7YjPACLCW8=; b=jPRLjZp3PetcpyNYsqbZve+HKDNZynXGDxa1QO7/T++T5HTUYpnndHHxndk8UPquUN RlcxaeKjOC3R651AtOSsuWRZTEmfxs+SWPUrNy+cgshaj3a439+PA/uuOz6cK3hufso3 to6kXPSjaQCC5e1rdBMBRNGe3Rv6i7SkmW0Zo5SpN5UXbJNrBAQrmfPC1eZL1zbA0NxA yiaXARki24AjlQrgB1QD8bJ846/bWS6aAetc5kkSSLWGcrJ/Ap16y92VKbvfmny+ggOX lsydc9uI3kBG4eiFUmsMvIz18d8H6uwTRl8QZZvXJauQvASOj5XJBkif3uwMSL9dZLaL h91g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726837; x=1705331637; 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=sGtlVmj/cLSRItSFI6o6Pd2FVVc8E9gmG7YjPACLCW8=; b=puUhRB7b7j+5nRGLHJ6ErYhwqcpfilozj+iq7GhD9oHfM6YuwLcZUSymVv77k8vTRP hm4l2xdXzwNW5+RhXk6PAfZ3igIItlAGdhmEbkXpDikc7rX/h/RSiE9pBtt3pkQCzaes rXgBw0uuMy3Qpubk6LCnWvOj6Aslp0Ettb7IaZaoPtJylc9Q8DAc1ASitNP1WvNqzVYP gqnWQJORl7iRjqXxB7KTan8vbIrEielhmmfRFxyo7OFD5PVCF3y013DiK0WUcshzbVzY D7+vVlEK2hkcG6d980UrcsXUqVa1v0acM4NE2R9Mlp29vtO/Y46FGlWZzmFYIKWWpB9h TglA== X-Gm-Message-State: AOJu0Yx/boptH2Us+anGn4TyuEhQTwwzdrDan9AGMLGIyF+U3Y34V44z HuaK66lvyzmF4nMLmCgUapBtOTxpJRHqMA== X-Received: by 2002:a05:600c:1f16:b0:40e:4239:5075 with SMTP id bd22-20020a05600c1f1600b0040e42395075mr876947wmb.364.1704726836992; Mon, 08 Jan 2024 07:13:56 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id u2-20020a7bc042000000b0040d79997731sm5233915wmc.0.2024.01.08.07.13.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:13:56 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 775185F949; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Pavel Dovgalyuk , =?utf-8?q?Philippe_Mathieu-Dau?= =?utf-8?q?d=C3=A9?= , Pavel Dovgalyuk , Paolo Bonzini Subject: [PULL 07/13] replay: add proper kdoc for ReplayState Date: Mon, 8 Jan 2024 15:13:46 +0000 Message-Id: <20240108151352.2199097-8-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::330; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x330.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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Remove the non-standard comment formatting and move the descriptions into a proper kdoc comment. Reviewed-by: Pavel Dovgalyuk Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-8-alex.bennee@linaro.org> diff --git a/replay/replay-internal.h b/replay/replay-internal.h index 516147ddbca..98ca3748edb 100644 --- a/replay/replay-internal.h +++ b/replay/replay-internal.h @@ -63,24 +63,31 @@ enum ReplayEvents { EVENT_COUNT }; +/** + * typedef ReplayState - global tracking Replay state + * + * This structure tracks where we are in the current ReplayState + * including the logged events from the recorded replay stream. Some + * of the data is also stored/restored from VMStateDescription when VM + * save/restore events take place. + * + * @cached_clock: Cached clocks values + * @current_icount: number of processed instructions + * @instruction_count: number of instructions until next event + * @data_kind: current event + * @has_unread_data: 1 if event not yet processed + * @file_offset: offset into replay log at replay snapshot + * @block_request_id: current serialised block request id + * @read_event_id: current async read event id + */ typedef struct ReplayState { - /*! Cached clock values. */ int64_t cached_clock[REPLAY_CLOCK_COUNT]; - /*! Current icount - number of processed instructions. */ uint64_t current_icount; - /*! Number of instructions to be executed before other events happen. */ int instruction_count; - /*! Type of the currently executed event. */ unsigned int data_kind; - /*! Flag which indicates that event is not processed yet. */ unsigned int has_unread_data; - /*! Temporary variable for saving current log offset. */ uint64_t file_offset; - /*! Next block operation id. - This counter is global, because requests from different - block devices should not get overlapping ids. */ uint64_t block_request_id; - /*! Asynchronous event id read from the log */ uint64_t read_event_id; } ReplayState; extern ReplayState replay_state; From patchwork Mon Jan 8 15:13:47 2024 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: 760774 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp936159wrz; Mon, 8 Jan 2024 07:15:59 -0800 (PST) X-Google-Smtp-Source: AGHT+IHXk96NdMO7J8gweUlpG4J5eFlUA5n0olMloXW3UMTvVGKk54mdCSc5T16KXkDrWhhoV0oq X-Received: by 2002:ae9:f114:0:b0:783:783:1ded with SMTP id k20-20020ae9f114000000b0078307831dedmr4398164qkg.152.1704726959334; Mon, 08 Jan 2024 07:15:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726959; cv=none; d=google.com; s=arc-20160816; b=qliD0uMdlk7rh7yRVipLUgFoYM00h8FugYYKYJ7dnuRSwtSma4PvvoUv96ahItxVzQ XisNi3LxokVx8qdpzlCrBZ5ygtymz8vfqb+f4yrQdmSp0epzDYDo8UEuOZZOmyZabT6P r8dfNU/ugz+gT6u1GtgROJ4FDx89c8nBd16niNNQ1hPRq02KdnZ2sSgIhRvyKFOowbeq tLvkem3ftbfevrlNOmpt7BDt2AfxS7io9/fRoVNA/49Yc4ySZpS+SU1liTJF/qSgBSWg KTX8rYCuQrdDcVsnj+6yR04xBJ0WWsAu/ezg/lPm48RnLv1/e58cTEJmNe8Nf9xm7ALP 2fuA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=SPOk6AJuTFsbsY/JbpngsdrxHBBFNIYVyd4S9YTkZ9o=; fh=4tnIo1nwYqKXRyJrm3zCLHpat1pd+2G19fIpj41A82g=; b=0obH9LvRykDEkTiCPu8ZUF0A7tPIp8xYO06gE0gOeZSvQcCrAzq/p1LoOflVHulkks RnqUlq0Vt2MnikkpTw+9CIQCW6zXPf2ZGGc7azADxJ4/NahxtHsrzdHslR9mTTGG476i O6sduf+17FDx+kTmAg9ElOPhZArqwSyCJhKyMLt12KTlKMjkJRHlWhqrtqMwpTmc+AyB fVYjUGnUQsBgyc/8lcxHU2xXMo17LKvS+hnrZZw5IXS7rj4owMcrY21cfqk3MehGqztp Hj2Yon8bscCcFGxs1T07You8k3pd3JhHxanf9ZqZ78x71U6mK+JxqQAIIJu3aOqBPfXc iOQw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=elbBRmRy; 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=pass (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 v3-20020ae9e303000000b0078192520d69si7755438qkf.544.2024.01.08.07.15.59 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:15:59 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=elbBRmRy; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKI-0004FK-Oj; Mon, 08 Jan 2024 10:14:06 -0500 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 1rMrKG-0004EK-W9 for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:05 -0500 Received: from mail-wm1-x331.google.com ([2a00:1450:4864:20::331]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKE-0001ai-HF for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:04 -0500 Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-40d89446895so11540495e9.0 for ; Mon, 08 Jan 2024 07:14:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726840; x=1705331640; 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=SPOk6AJuTFsbsY/JbpngsdrxHBBFNIYVyd4S9YTkZ9o=; b=elbBRmRyT5xCIwaPYLGpbkkLhHL1pETurwbivmsWFxxAYyaCKJhGsmcVYT+Sprr0ip zJUnGMEg6K+WRtgaIxmF5Nx3prqfSjr4I6nHOhEF+gC0UXAgKLZY7ebhxWKuczS2f+Bk R2726ECtzNvRvooOr2iO2fa9JNqQrbqExWF12O0fNuWCF9CZNqigUl8GaHQU6WQQUh4z JkLh1gL4OVPYbr3npcRPVO77AG3k2wkvz+EZZ+0KEokO0rXwqtUQSmMn8Ahv9tGKv5UN ba2L+HyFSAvG0iEzCs3UQ7pbYfIXEEaOPeV2DDrh44OFQowe3VMoohLWLP2q8glxH24H SxHg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726840; x=1705331640; 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=SPOk6AJuTFsbsY/JbpngsdrxHBBFNIYVyd4S9YTkZ9o=; b=XvGpXpGjsCJ+OL9sdf04acm+JmAgfly9Ak+snMtQnsBZQQYHT7oyaw7JJ1kjOS9zkr NPhVlTyhQUpaEYQ54p0nBN6SEKoD7uXOSIJEDyy3y+XyyJutNuvvrLrpq5/Q5At0qdxl qbj0Xs/toPNBJL2bgDJCHhLZfV/gzV7VZ+sxOkhFAc6jtGqYVR3MHHL2hRyDnvneWnXU N3u2EtEXgx+4lPkfKa3tg8s41JiNQl76zQBpQsWsn98ga/It6nN2LLAh7eBKQcUqe4lu c0hImG7W5VPvs3FghRSzCusqtA//Bhz+jqN7Nq3b+Btvy4mE4xeddFevMuWkDJBBJBjW zZrA== X-Gm-Message-State: AOJu0Yz8n2sJaCfofbIY3Hvzz+SNXNYw+6syt0O0f0Ao8q9x1WGBIsMp cBRATUUxILY06dXDqCIzeucpv0fx299Tmg== X-Received: by 2002:a05:600c:35d1:b0:40d:887e:fc85 with SMTP id r17-20020a05600c35d100b0040d887efc85mr1906231wmq.32.1704726839847; Mon, 08 Jan 2024 07:13:59 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id j8-20020a05600c190800b0040d6d755c90sm119705wmq.42.2024.01.08.07.13.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:13:56 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 8D7FD5F94A; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , =?utf-8?q?Philipp?= =?utf-8?q?e_Mathieu-Daud=C3=A9?= , Pavel Dovgalyuk , Richard Henderson , Pavel Dovgalyuk , Paolo Bonzini Subject: [PULL 08/13] replay: make has_unread_data a bool Date: Mon, 8 Jan 2024 15:13:47 +0000 Message-Id: <20240108151352.2199097-9-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::331; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x331.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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org For clarity given it only has two states. Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Pavel Dovgalyuk Reviewed-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-9-alex.bennee@linaro.org> diff --git a/replay/replay-internal.h b/replay/replay-internal.h index 98ca3748edb..1bc8fd50868 100644 --- a/replay/replay-internal.h +++ b/replay/replay-internal.h @@ -75,7 +75,7 @@ enum ReplayEvents { * @current_icount: number of processed instructions * @instruction_count: number of instructions until next event * @data_kind: current event - * @has_unread_data: 1 if event not yet processed + * @has_unread_data: true if event not yet processed * @file_offset: offset into replay log at replay snapshot * @block_request_id: current serialised block request id * @read_event_id: current async read event id @@ -85,7 +85,7 @@ typedef struct ReplayState { uint64_t current_icount; int instruction_count; unsigned int data_kind; - unsigned int has_unread_data; + bool has_unread_data; uint64_t file_offset; uint64_t block_request_id; uint64_t read_event_id; diff --git a/replay/replay-internal.c b/replay/replay-internal.c index 77d0c82327e..634025096ef 100644 --- a/replay/replay-internal.c +++ b/replay/replay-internal.c @@ -179,7 +179,7 @@ void replay_fetch_data_kind(void) replay_state.instruction_count = replay_get_dword(); } replay_check_error(); - replay_state.has_unread_data = 1; + replay_state.has_unread_data = true; if (replay_state.data_kind >= EVENT_COUNT) { error_report("Replay: unknown event kind %d", replay_state.data_kind); @@ -191,7 +191,7 @@ void replay_fetch_data_kind(void) void replay_finish_event(void) { - replay_state.has_unread_data = 0; + replay_state.has_unread_data = false; replay_fetch_data_kind(); } diff --git a/replay/replay-snapshot.c b/replay/replay-snapshot.c index e5e39161e33..d4f6cb7cda8 100644 --- a/replay/replay-snapshot.c +++ b/replay/replay-snapshot.c @@ -47,8 +47,8 @@ static int replay_post_load(void *opaque, int version_id) static const VMStateDescription vmstate_replay = { .name = "replay", - .version_id = 2, - .minimum_version_id = 2, + .version_id = 3, + .minimum_version_id = 3, .pre_save = replay_pre_save, .post_load = replay_post_load, .fields = (const VMStateField[]) { @@ -56,7 +56,7 @@ static const VMStateDescription vmstate_replay = { VMSTATE_UINT64(current_icount, ReplayState), VMSTATE_INT32(instruction_count, ReplayState), VMSTATE_UINT32(data_kind, ReplayState), - VMSTATE_UINT32(has_unread_data, ReplayState), + VMSTATE_BOOL(has_unread_data, ReplayState), VMSTATE_UINT64(file_offset, ReplayState), VMSTATE_UINT64(block_request_id, ReplayState), VMSTATE_UINT64(read_event_id, ReplayState), From patchwork Mon Jan 8 15:13:48 2024 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: 760768 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp935461wrz; Mon, 8 Jan 2024 07:14:51 -0800 (PST) X-Google-Smtp-Source: AGHT+IH7UrGs5W9nkCRrlZ7dumtZN+JOiw0tljkfLCddyXeBgfolKpoTAXqwvO8A+gEj1YOC7bTn X-Received: by 2002:a05:6358:880a:b0:175:43ba:2f36 with SMTP id hv10-20020a056358880a00b0017543ba2f36mr1984115rwb.42.1704726890779; Mon, 08 Jan 2024 07:14:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726890; cv=none; d=google.com; s=arc-20160816; b=aoEfIxCr5QJWu+ZfMgjKvO+DGP/vAA0/kTCT6z4I/kRF3Ld2fW721yJDj+cTtV0LyA PA9hgdH+VLMeZneHVZpORUGDNRkTaSd2OeDS1Q5phJrV3hI/pXLy/IojlWZfCeJRqCq+ MtXpMdKY/hehFJ6GKvTALSSOiVn0RvE3qHzRO4G1wNzkbWb/uFNywrrFOmpAYiB+9zf4 ppQ/a7Rc68LH4WB444FZG88BYgWlsMdofkpGUWM1hzqd5I6j2Srq1MTTH815zCyjdl9X 2TcnkFr8ClWL+fzQ7U/9qgznu6uXD1/KqavsphBzkVb/6IqxlYZmokxK+QYy+naaJyJL eVAg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=fLTiWwdEIfg9JspvYt86f20QV2JuGa01IK1rdNLR1WY=; fh=g0tniTQGvTweTFoeEF7OF4zugwZFysymytcP6QxI5CU=; b=MrAKDQ/xkVGMtAC+SIqeM0JpaMf+abPRKGGIjQmTTa5gXITYapZC980mzOKrfQA5X4 3yqPBOyHHw9myvZWnjv9q3u8rwpro+Z2SV0Kwott2uIYvP0LF1auxlgkuozTR8EMS9I/ /3Z9Z+b0uCMUi2BS1hww+F4gcIKVALGCS2nvahJNgUyAIGNNVpa1JKI7OH/AymCV0o/h SHaOCTKBJnCKqKodUDNyqRbB6qycUCoROK04twrsgc+vi7LWReBWMWvfumU4+b8uq/4F cE9YwgBCURqBKgDf2RY0fFZCny1h65LY/DlG+EHrDb69IrRXkvOpURJPMo5Yw4rW9cKb GyvQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=enDk4Zm6; 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=pass (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 c22-20020a05620a11b600b00783249b2987si1591675qkk.318.2024.01.08.07.14.50 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:14:50 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=enDk4Zm6; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKM-0004Gl-Q4; Mon, 08 Jan 2024 10:14:10 -0500 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 1rMrKK-0004Fw-Do for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:08 -0500 Received: from mail-wr1-x42f.google.com ([2a00:1450:4864:20::42f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKF-0001bp-BY for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:07 -0500 Received: by mail-wr1-x42f.google.com with SMTP id ffacd0b85a97d-33678156e27so1931651f8f.1 for ; Mon, 08 Jan 2024 07:14:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726842; x=1705331642; 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=fLTiWwdEIfg9JspvYt86f20QV2JuGa01IK1rdNLR1WY=; b=enDk4Zm6NbV8OSzLRhkP7LawH1UnkkuY7IAcmLXCJw2e0KNvJiH+XZ4k2Ecl/TkyVc 63MbBlnv3B8wtnvmYAe1ZdBbWxd7luqq3zUN1jnup++bNk/8HQU3ToRi9pRdaoYp+cgD hXuBXrWR84MdfZh6Mb/QGbJgmEYmY5YxnzcOEDDa+gOz+TBDcCPVhjFtDccShWw6wtIh 1oWAs55fbzCuArrQ1gGmmGiNMG22xn6S97E8vDaJOFJ2O7VWuzA3JN1QT0vymz29xCKH KIhvEUco6+KuMRwmEGrLR7eRcmS0eYImWvhh3ywVjHhWK9gbdqWeehzjNu4Kk2EEalJW FRdA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726842; x=1705331642; 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=fLTiWwdEIfg9JspvYt86f20QV2JuGa01IK1rdNLR1WY=; b=ozFDLOso6JxRXhMsFzWWXclXGTeZTdLRIgx93Jt//BR0bomnfR+kHiaInGLa4HFxFh f4WmYKciFXHs2BxgLB7XIDX/vthY+1o/PMV6XZ2l7RAyyOliLEg6gIj5AZ2Z9xYshfWL yryRu4Xp1KPTHJiCLhBt3D63FOifcvWGXySfMm1XzeFdIMPk9bsoBCl613eGkQye85yF 88KRsPMy7vZ/mSQp8ZaQFF2KcEdBM1eGqmNU9pCgafT2hCG0o3royttXrv3GPxLuIBQJ jYG1brAd30pFDqcypism/+ZflErQQywSayJC8kYM9HWMM9i9+z+5vv8o0oXNapQSDR60 licw== X-Gm-Message-State: AOJu0YzTPPeHHwrZ06tq4Pzm0AEW3K2BNR1om8TxLZES9wgoBeu+OrxD kfxgqIUERfvooL6EcpfiRRNCyX/XhR4wcQ== X-Received: by 2002:adf:b612:0:b0:336:c00c:c84c with SMTP id f18-20020adfb612000000b00336c00cc84cmr1695956wre.28.1704726841966; Mon, 08 Jan 2024 07:14:01 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id cg2-20020a5d5cc2000000b00336c120855dsm8018589wrb.84.2024.01.08.07.13.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:13:56 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id A34305F756; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Richard Henderson , Pavel Dovgalyuk , Paolo Bonzini Subject: [PULL 09/13] replay: introduce a central report point for sync errors Date: Mon, 8 Jan 2024 15:13:48 +0000 Message-Id: <20240108151352.2199097-10-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42f; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42f.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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Figuring out why replay has failed is tricky at the best of times. Lets centralise the reporting of a replay sync error and add a little bit of extra information to help with debugging. Reviewed-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-10-alex.bennee@linaro.org> diff --git a/replay/replay-internal.h b/replay/replay-internal.h index 1bc8fd50868..75249b76936 100644 --- a/replay/replay-internal.h +++ b/replay/replay-internal.h @@ -25,7 +25,12 @@ typedef enum ReplayAsyncEventKind { REPLAY_ASYNC_COUNT } ReplayAsyncEventKind; -/* Any changes to order/number of events will need to bump REPLAY_VERSION */ +/* + * Any changes to order/number of events will need to bump + * REPLAY_VERSION to prevent confusion with old logs. Also don't + * forget to update replay_event_name() to make your debugging life + * easier. + */ enum ReplayEvents { /* for instruction event */ EVENT_INSTRUCTION, @@ -74,6 +79,7 @@ enum ReplayEvents { * @cached_clock: Cached clocks values * @current_icount: number of processed instructions * @instruction_count: number of instructions until next event + * @current_event: current event index * @data_kind: current event * @has_unread_data: true if event not yet processed * @file_offset: offset into replay log at replay snapshot @@ -84,6 +90,7 @@ typedef struct ReplayState { int64_t cached_clock[REPLAY_CLOCK_COUNT]; uint64_t current_icount; int instruction_count; + unsigned int current_event; unsigned int data_kind; bool has_unread_data; uint64_t file_offset; @@ -188,6 +195,16 @@ void replay_event_net_save(void *opaque); /*! Reads network from the file. */ void *replay_event_net_load(void); +/* Diagnostics */ + +/** + * replay_sync_error(): report sync error and exit + * + * When we reach an error condition we want to report it centrally so + * we can also dump some useful information into the logs. + */ +G_NORETURN void replay_sync_error(const char *error); + /* VMState-related functions */ /* Registers replay VMState. diff --git a/replay/replay-internal.c b/replay/replay-internal.c index 634025096ef..654b99cfb55 100644 --- a/replay/replay-internal.c +++ b/replay/replay-internal.c @@ -175,6 +175,7 @@ void replay_fetch_data_kind(void) if (replay_file) { if (!replay_state.has_unread_data) { replay_state.data_kind = replay_get_byte(); + replay_state.current_event++; if (replay_state.data_kind == EVENT_INSTRUCTION) { replay_state.instruction_count = replay_get_dword(); } diff --git a/replay/replay-snapshot.c b/replay/replay-snapshot.c index d4f6cb7cda8..ccb4d89dda7 100644 --- a/replay/replay-snapshot.c +++ b/replay/replay-snapshot.c @@ -55,6 +55,7 @@ static const VMStateDescription vmstate_replay = { VMSTATE_INT64_ARRAY(cached_clock, ReplayState, REPLAY_CLOCK_COUNT), VMSTATE_UINT64(current_icount, ReplayState), VMSTATE_INT32(instruction_count, ReplayState), + VMSTATE_UINT32(current_event, ReplayState), VMSTATE_UINT32(data_kind, ReplayState), VMSTATE_BOOL(has_unread_data, ReplayState), VMSTATE_UINT64(file_offset, ReplayState), diff --git a/replay/replay.c b/replay/replay.c index 0f7d766efe8..ff197f436bf 100644 --- a/replay/replay.c +++ b/replay/replay.c @@ -38,6 +38,107 @@ static GSList *replay_blockers; uint64_t replay_break_icount = -1ULL; QEMUTimer *replay_break_timer; +/* Pretty print event names */ + +static const char *replay_async_event_name(ReplayAsyncEventKind event) +{ + switch (event) { +#define ASYNC_EVENT(_x) case REPLAY_ASYNC_EVENT_ ## _x: return "ASYNC_EVENT_"#_x + ASYNC_EVENT(BH); + ASYNC_EVENT(BH_ONESHOT); + ASYNC_EVENT(INPUT); + ASYNC_EVENT(INPUT_SYNC); + ASYNC_EVENT(CHAR_READ); + ASYNC_EVENT(BLOCK); + ASYNC_EVENT(NET); +#undef ASYNC_EVENT + default: + g_assert_not_reached(); + } +} + +static const char *replay_clock_event_name(ReplayClockKind clock) +{ + switch (clock) { +#define CLOCK_EVENT(_x) case REPLAY_CLOCK_ ## _x: return "CLOCK_" #_x + CLOCK_EVENT(HOST); + CLOCK_EVENT(VIRTUAL_RT); +#undef CLOCK_EVENT + default: + g_assert_not_reached(); + } +} + +/* Pretty print shutdown event names */ +static const char *replay_shutdown_event_name(ShutdownCause cause) +{ + switch (cause) { +#define SHUTDOWN_EVENT(_x) case SHUTDOWN_CAUSE_ ## _x: return "SHUTDOWN_CAUSE_" #_x + SHUTDOWN_EVENT(NONE); + SHUTDOWN_EVENT(HOST_ERROR); + SHUTDOWN_EVENT(HOST_QMP_QUIT); + SHUTDOWN_EVENT(HOST_QMP_SYSTEM_RESET); + SHUTDOWN_EVENT(HOST_SIGNAL); + SHUTDOWN_EVENT(HOST_UI); + SHUTDOWN_EVENT(GUEST_SHUTDOWN); + SHUTDOWN_EVENT(GUEST_RESET); + SHUTDOWN_EVENT(GUEST_PANIC); + SHUTDOWN_EVENT(SUBSYSTEM_RESET); + SHUTDOWN_EVENT(SNAPSHOT_LOAD); +#undef SHUTDOWN_EVENT + default: + g_assert_not_reached(); + } +} + +static const char *replay_checkpoint_event_name(enum ReplayCheckpoint checkpoint) +{ + switch (checkpoint) { +#define CHECKPOINT_EVENT(_x) case CHECKPOINT_ ## _x: return "CHECKPOINT_" #_x + CHECKPOINT_EVENT(CLOCK_WARP_START); + CHECKPOINT_EVENT(CLOCK_WARP_ACCOUNT); + CHECKPOINT_EVENT(RESET_REQUESTED); + CHECKPOINT_EVENT(SUSPEND_REQUESTED); + CHECKPOINT_EVENT(CLOCK_VIRTUAL); + CHECKPOINT_EVENT(CLOCK_HOST); + CHECKPOINT_EVENT(CLOCK_VIRTUAL_RT); + CHECKPOINT_EVENT(INIT); + CHECKPOINT_EVENT(RESET); +#undef CHECKPOINT_EVENT + default: + g_assert_not_reached(); + } +} + +static const char *replay_event_name(enum ReplayEvents event) +{ + /* First deal with the simple ones */ + switch (event) { +#define EVENT(_x) case EVENT_ ## _x: return "EVENT_"#_x + EVENT(INSTRUCTION); + EVENT(INTERRUPT); + EVENT(EXCEPTION); + EVENT(CHAR_WRITE); + EVENT(CHAR_READ_ALL); + EVENT(AUDIO_OUT); + EVENT(AUDIO_IN); + EVENT(RANDOM); +#undef EVENT + default: + if (event >= EVENT_ASYNC && event <= EVENT_ASYNC_LAST) { + return replay_async_event_name(event - EVENT_ASYNC); + } else if (event >= EVENT_SHUTDOWN && event <= EVENT_SHUTDOWN_LAST) { + return replay_shutdown_event_name(event - EVENT_SHUTDOWN); + } else if (event >= EVENT_CLOCK && event <= EVENT_CLOCK_LAST) { + return replay_clock_event_name(event - EVENT_CLOCK); + } else if (event >= EVENT_CHECKPOINT && event <= EVENT_CHECKPOINT_LAST) { + return replay_checkpoint_event_name(event - EVENT_CHECKPOINT); + } + } + + g_assert_not_reached(); +} + bool replay_next_event_is(int event) { bool res = false; @@ -226,6 +327,15 @@ bool replay_has_event(void) return res; } +G_NORETURN void replay_sync_error(const char *error) +{ + error_report("%s (insn total %"PRId64"/%d left, event %d is %s)", error, + replay_state.current_icount, replay_state.instruction_count, + replay_state.current_event, + replay_event_name(replay_state.data_kind)); + abort(); +} + static void replay_enable(const char *fname, int mode) { const char *fmode = NULL; @@ -258,6 +368,7 @@ static void replay_enable(const char *fname, int mode) replay_state.data_kind = -1; replay_state.instruction_count = 0; replay_state.current_icount = 0; + replay_state.current_event = 0; replay_state.has_unread_data = 0; /* skip file header for RECORD and check it for PLAY */ From patchwork Mon Jan 8 15:13:49 2024 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: 760771 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp935713wrz; Mon, 8 Jan 2024 07:15:15 -0800 (PST) X-Google-Smtp-Source: AGHT+IFqlndQFajZ3LvaOxNsJKE+qswKfQoOORb+LUAjV4yTaO1Tpf0Hkn5O7pTw6qyxB3WLPCIG X-Received: by 2002:a05:620a:b52:b0:781:62cf:8600 with SMTP id x18-20020a05620a0b5200b0078162cf8600mr4367242qkg.100.1704726915045; Mon, 08 Jan 2024 07:15:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726915; cv=none; d=google.com; s=arc-20160816; b=YcP3IObSoMGJOn2hjUzwldXb6lIFZ4z+tvcndiOkI06I6vr9udGOJnE9xXMzCxHbOB sEOTZTFGuJgpzncoMeyXJ7DiMQ8ONm9rX5KbV1ZXJkDhOnM8pgqDDISHD5el7YWg2fjv NNUoAX4oxXghww4o6MOsfA1QymeB40CwRNhSW15CmZHQBW/iSsyyHG49L4Juck8VTuik BtdpeO79xqzE8e7+/XMCm+sNP6lAR+9SQXkqgmDzXMfaWZ5xE+A5RJKZdeSRtJ7CCx1f YZgVMqxqFq9bnLvV6sgofmSwy8njjveDjW8rwmy2ysd7TBl+4PeX8lxXIGnZeCPw4Csk J0Ew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=k9MwYzVVCpi8aRF113OyWJJfAJmZSssygUp+Otb9ZUM=; fh=g0tniTQGvTweTFoeEF7OF4zugwZFysymytcP6QxI5CU=; b=xs8r2sXYw1BqiEUOqfDWJTXV06nJtpb87rXW6T/y0zDnFQ+TlvQQJTeNBbnNQnDK7u qb73zN9piHsHsaRT7X9eDTV+8w75K2K6MwxpmFi9bFVDZZ9/DsjAZOesxbf/76OY9iMN Cw0zcEgVfrARDXkKHU0NonmHhHqOR1cO8ImeK+sszL+rWdxQJoJCY6SLwejy6+bqCATJ W0EdM9PhOx5gB7GppPrGcZEsIM8SKhRMJLBStF5mQECrbnhfVLxHqOg2i0rViEXkKfVh gXs0Jb7aj8YLABgY7VGWPONupff82FY7d8HA2t8/QqqyoJpUAEDQs1DVK6s7R/s8NUfY ggtA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=YXS7hglE; 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=pass (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 a8-20020a05620a102800b00783264580b0si1093637qkk.57.2024.01.08.07.15.14 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:15:15 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=YXS7hglE; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKK-0004GK-Hr; Mon, 08 Jan 2024 10:14:08 -0500 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 1rMrKI-0004Er-6f for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:06 -0500 Received: from mail-wr1-x42f.google.com ([2a00:1450:4864:20::42f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKF-0001aY-8Y for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:05 -0500 Received: by mail-wr1-x42f.google.com with SMTP id ffacd0b85a97d-33765009941so1594206f8f.3 for ; Mon, 08 Jan 2024 07:14:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726839; x=1705331639; 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=k9MwYzVVCpi8aRF113OyWJJfAJmZSssygUp+Otb9ZUM=; b=YXS7hglEEUflE7sy6TJB7AtaVu2eupXd7DiMSywJV2moysIrqrvHckOprwfa7L8SJ7 3EcyMV4vgF5yHHUZktmzLdds510bu+1rDNf3Q3eCTzBpoJ9j7YAtMbRf8ILF6ZIQEtYk qiwvTX19Z/UGlO7XCE5DFw9dCWqomh/NgWQa0JUT7pV8lZAIPCqs2t/Qae2QTMxOQDra 1GSCsoXtzye5ZVnPzMytHzVQhXkxtnOgS1o4i79RDPBUYm1CUVdoFQqvhVNrhZGEkdw7 KjD5Zr5uZu56+rTS7pJ1DF7O0lFb/OZm3acH8SRI4m+OtcTQz/Oi5L0O/BCITNYFvQ1B /dzw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726839; x=1705331639; 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=k9MwYzVVCpi8aRF113OyWJJfAJmZSssygUp+Otb9ZUM=; b=UkQ2WhWz8PogixZjfW//rWUjI+GMGDmUiWQtqYITie8Giw/4H3+KiFEqKKYwyfb/T6 +VIcSR6p1NQUhf0BQRQuvnXU1i4aTM9KR0RqCdEywurJqmr0NKXUUe8/wyRybonBNR0/ g86kpi6+T9IPDF2EShNQYLtX14+Vjll205N8MTnu3RtETjQpCNgE6k6rreGI/9UAq1YF rzBrGpx0GpoetIsVhBJFAFh/nL9x/AyflAMvAtdbZtJ2D2Kg/YSoHiSIrhjFK6yrRTrp q9+P/wNKbqJJgQlyA4+sQ2I80mH1W1B1c3EFeygtR2mo/GRKZHJUf3nPRhS2/3gkCw7q GVaQ== X-Gm-Message-State: AOJu0Yx0h2dxZ7L+uYiAH4fuwCG1zU+94t/vYFTihyKcvBXlPlPXcutH QEegspdGCXen7lDfyXAqK3bdrHFu//fE4w== X-Received: by 2002:a05:6000:1204:b0:337:5ba9:3435 with SMTP id e4-20020a056000120400b003375ba93435mr2090385wrx.124.1704726839640; Mon, 08 Jan 2024 07:13:59 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id h13-20020a5d6e0d000000b0033677a4e0d6sm8039039wrz.13.2024.01.08.07.13.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:13:56 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id B75D85F94E; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Richard Henderson , Pavel Dovgalyuk , Paolo Bonzini Subject: [PULL 10/13] replay/replay-char: use report_sync_error Date: Mon, 8 Jan 2024 15:13:49 +0000 Message-Id: <20240108151352.2199097-11-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42f; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42f.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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Now we have a centralised report function use it for missing character events. Reviewed-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-11-alex.bennee@linaro.org> diff --git a/replay/replay-char.c b/replay/replay-char.c index a31aded032e..72b1f832dde 100644 --- a/replay/replay-char.c +++ b/replay/replay-char.c @@ -113,8 +113,7 @@ void replay_char_write_event_load(int *res, int *offset) *offset = replay_get_dword(); replay_finish_event(); } else { - error_report("Missing character write event in the replay log"); - exit(1); + replay_sync_error("Missing character write event in the replay log"); } } @@ -135,8 +134,7 @@ int replay_char_read_all_load(uint8_t *buf) replay_finish_event(); return res; } else { - error_report("Missing character read all event in the replay log"); - exit(1); + replay_sync_error("Missing character read all event in the replay log"); } } From patchwork Mon Jan 8 15:13:50 2024 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: 760778 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp936755wrz; Mon, 8 Jan 2024 07:17:05 -0800 (PST) X-Google-Smtp-Source: AGHT+IHY0GIJPKS9X7IcHohwD6a+KcybHhh0jtUdtM1UtrZClzk49lXSjhvJZA1dBez80wVMMTlY X-Received: by 2002:a05:620a:8221:b0:77f:25ef:eb92 with SMTP id ow33-20020a05620a822100b0077f25efeb92mr8417879qkn.27.1704727025601; Mon, 08 Jan 2024 07:17:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704727025; cv=none; d=google.com; s=arc-20160816; b=UXb58ib9voOG8lgbp+ShY4JQCeTErplBLdRdgaPC3QFFBlvW2l0vCtSkRIvuDsIrv8 RH4XrPmS9wBCnK+HHnNChBF47R5Y6lFhEdeQYiHNNBEP/1lgjGx/Na2QzHo5uPOQfnb6 5gptvcb9W0BgUV8E+dlx9PDuk6vsUwAnS5YqinL6k4yzYKnRipyoVeXVOJYRfRgqcIpQ n7Q7AkLo2zTrWvK8tO2295FubsgwgJbXb9Xyj90CTCC9H1GdNJ/hLNH5dZLRjhyonr9B kjkoMl1SXUECJyePJlw9NF4RxQktAlLA8/Tlw06fci5qew4bcf5lYD1YZpTIgSifE9cA i3Tg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=/3f/gZt7kuZhNsGlk9QFjConVSBhlieoHxarURcJ0oU=; fh=v8eUbSUNaJKjz9SiTsbhAf2H0lhjbptzvgb2Wnk2470=; b=XDFoTKJCFujxrIkiLFqc6ByYnwiaskqBFaAS4nXX8CPhBcQhmy+qMsGf5DKU4FUsBk kYCDKPwDaxgjp6eIZtIRQJKGOkT4J+K95pBtP+PXn+geiQkjslhNdDLFM8jK7cI1O9Eh SvaC4CafswXtN9rRfkxPM+9YQ3IKepOU5xpQkcHRVBUPR6liKD/0Nxpd12WujhbEYy5H GP4KPOq+ChMEUktuXBQn3O1iW2aIydZQV5RTeOHo8fSi54mgIHF5O/aMcRGIRYGczhpX RsisX8RZYFNnD5ETjLGJVXbFBUoLnrgTV3alEhB3oZsG0Kf68GY8YfnF2RRPJQuRsy5P W9nw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="I/LFI0BL"; 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=pass (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 j20-20020a05620a289400b0076d81c85ecesi8056333qkp.723.2024.01.08.07.17.05 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:17:05 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b="I/LFI0BL"; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKN-0004J9-An; Mon, 08 Jan 2024 10:14:11 -0500 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 1rMrKL-0004Gj-Ms for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:09 -0500 Received: from mail-wm1-x32f.google.com ([2a00:1450:4864:20::32f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKF-0001c2-MQ for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:08 -0500 Received: by mail-wm1-x32f.google.com with SMTP id 5b1f17b1804b1-40e4b20a52bso2169005e9.3 for ; Mon, 08 Jan 2024 07:14:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726842; x=1705331642; 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=/3f/gZt7kuZhNsGlk9QFjConVSBhlieoHxarURcJ0oU=; b=I/LFI0BL5RQe6weroZ1gezUBYUaosPFCVYGZUnqcUcmZPJngqqw62jmJtT88Hypvl9 pwPrhRrUucZwTdbFk1ph0Bq9LUEJN9tNBXWEiSJf5e+FneiF7X53V62uqHhAZfUjJKaD a3v9whsDxjCTTL/AmISoxwXtFrQkcCwVaq/h4DT2QxDn7fafbT2s+XR9AUefjBWHyIPq 9I7h9EwyAa0CKLDTRokHTVwOPIAN/MTEl7QXfD4x+3JwvjQJLopJkCCIiR/Oqu8qcXjC /1h3JC8MIBNbXPoLv6KW/Zk3ekc+ArpZKx//ObdfTHhyR7ZIXIggVIOhh74K60VBPbzq Ql2w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726842; x=1705331642; 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=/3f/gZt7kuZhNsGlk9QFjConVSBhlieoHxarURcJ0oU=; b=VltuFMbzxdKQop/ypg35ii8BwOKhmwMv+QVED/euvGdPDZme2qFDuS00t9cvOPd54z kJolC4AJDvDO5ui4fY+ebS+rUGSEsFbyP1cp6n7XVl6U/N4fOEPndL/wVc4kuCXmYq0Z PR4zU+bNe3GGmxFYQGbZJUB9mqryNmsWZCxBhyuDEI6SjXQS4i1Z8quMFLzAijT3a1Gl 2YsecVBkMtBggOk034KSdD5yGAg/zZ8i4sW1TaVK0k9BFu0L86sKSZypRU3ezByxdKNJ 9L3j4UGWd27ivlhkEta9dTRnckfkhYxKps+R8Cvicnj4jwCewTV5xNY0OsktNhTElc+Q gq5A== X-Gm-Message-State: AOJu0YyMadkkO3AyJq2SI1PqWAef5+SIq9LG/C//8zIyTYK1vVxfQmXK In2cj44aqr9Oc3swuUKUkm9VctiJwMjLwA== X-Received: by 2002:a7b:c4c5:0:b0:40e:4a75:e6c8 with SMTP id g5-20020a7bc4c5000000b0040e4a75e6c8mr410391wmk.116.1704726842222; Mon, 08 Jan 2024 07:14:02 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id k25-20020a05600c1c9900b0040d87b9eec7sm11452358wms.32.2024.01.08.07.13.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:14:01 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id CD36F5F950; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Pavel Dovgalyuk , Richard Henderson , Paolo Bonzini Subject: [PULL 11/13] replay: stop us hanging in rr_wait_io_event Date: Mon, 8 Jan 2024 15:13:50 +0000 Message-Id: <20240108151352.2199097-12-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32f; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32f.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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org A lot of the hang I see are when we end up spinning in rr_wait_io_event for an event that will never come in playback. As a new check functions which can see if we are in PLAY mode and kick us us the wait function so the event can be processed. This fixes most of the failures in replay_kernel.py Fixes: https://gitlab.com/qemu-project/qemu/-/issues/2013 Cc: Pavel Dovgalyuk Reviewed-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-12-alex.bennee@linaro.org> diff --git a/include/sysemu/replay.h b/include/sysemu/replay.h index 08aae5869fc..83995ae4bd4 100644 --- a/include/sysemu/replay.h +++ b/include/sysemu/replay.h @@ -70,6 +70,11 @@ int replay_get_instructions(void); /*! Updates instructions counter in replay mode. */ void replay_account_executed_instructions(void); +/** + * replay_can_wait: check if we should pause for wait-io + */ +bool replay_can_wait(void); + /* Processing clocks and other time sources */ /*! Save the specified clock */ diff --git a/accel/tcg/tcg-accel-ops-rr.c b/accel/tcg/tcg-accel-ops-rr.c index 611932f3c3a..825e35b3dc4 100644 --- a/accel/tcg/tcg-accel-ops-rr.c +++ b/accel/tcg/tcg-accel-ops-rr.c @@ -109,7 +109,7 @@ static void rr_wait_io_event(void) { CPUState *cpu; - while (all_cpu_threads_idle()) { + while (all_cpu_threads_idle() && replay_can_wait()) { rr_stop_kick_timer(); qemu_cond_wait_iothread(first_cpu->halt_cond); } diff --git a/replay/replay.c b/replay/replay.c index ff197f436bf..3fd241a4fcc 100644 --- a/replay/replay.c +++ b/replay/replay.c @@ -449,6 +449,27 @@ void replay_start(void) replay_enable_events(); } +/* + * For none/record the answer is yes. + */ +bool replay_can_wait(void) +{ + if (replay_mode == REPLAY_MODE_PLAY) { + /* + * For playback we shouldn't ever be at a point we wait. If + * the instruction count has reached zero and we have an + * unconsumed event we should go around again and consume it. + */ + if (replay_state.instruction_count == 0 && replay_state.has_unread_data) { + return false; + } else { + replay_sync_error("Playback shouldn't have to iowait"); + } + } + return true; +} + + void replay_finish(void) { if (replay_mode == REPLAY_MODE_NONE) { From patchwork Mon Jan 8 15:13:51 2024 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: 760777 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp936751wrz; Mon, 8 Jan 2024 07:17:05 -0800 (PST) X-Google-Smtp-Source: AGHT+IFoMplPOpWG+tIleLK3c9/hWfExM7fwtSprsaklikrxFIVgzby+ytrXFqoLH+fbjxpXtODf X-Received: by 2002:a05:6214:5195:b0:681:b69:6565 with SMTP id kl21-20020a056214519500b006810b696565mr833846qvb.87.1704727025479; Mon, 08 Jan 2024 07:17:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704727025; cv=none; d=google.com; s=arc-20160816; b=yJjXWGuvNsfqxr0GHCVBYHbtwkZLQlYtUxVAgSdZ8bd+ETbXzM/8g+JErerRuyw3VJ GTIAvDv3eQxwMjubbgdC1bHNi+yj+Yi1zJnL7zhtnShhAI1QZX+Adw4+zYsAK8wFFP8e omkanHwffqGZwqK+S5rj7VAISIAv5hdOIGGjwH9qecEFMm/Laq6jZn4hBDDvkT1JfF2w j9y181V5uTVHuQ+QBPpRW4oNJIoiVvnO2bPny1a2tYSvNcAe+jGvym63HowTc6IOjDb9 QUyXntZpSwcA2B2iswIw7j55suasdnge2VSri9Vo2ZoN2pEopANsMC3ma2qE42GbZPh8 T8LA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=p2vXh+pSNK2Iht3pnXQCJkC17vaS5mbAQ1w3JtGP+qY=; fh=9Hwe9/PrniLSkf2HOIame21WnQQ7cqLwRKrPSOIAEU0=; b=VGgLHZRYP5Zns9UG28rws2/VyjLIe1PqPIees4en2pLIKvUvA/8mMMXU+gNJ9KHCyy XUsny3T3nHtxOLbo5cLFt/z4tPAeI9vHjBwy+Uag238J3KYMXvCTePjsHueNU+YpmGp5 tQtEjGGgG4g4Vuyn6AFxy4+5RlOyiT075ozb8TFRYzghraRDwzqXCnqsVUrHwcN5gE98 /fvJ1X5iCULx/L6vnqC5ajOB+u/mg0pXuzX5Vbyt9HbdFj4aLqs6sukWDc7hSwsexKku Mi/3/O4h2+WY2QNskb55wKnF330XTCwINu0RIWzMDO/et4Cm2Hbw1HkhztJbN6YaK9Wz GkvQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=oWZf1+8b; 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=pass (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 y15-20020a0ce04f000000b0067f7b58a4e1si79265qvk.212.2024.01.08.07.17.05 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:17:05 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=oWZf1+8b; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKO-0004K8-51; Mon, 08 Jan 2024 10:14:12 -0500 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 1rMrKK-0004GN-J1 for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:08 -0500 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKF-0001c7-Sv for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:08 -0500 Received: by mail-wm1-x334.google.com with SMTP id 5b1f17b1804b1-40e4b499b4aso1418595e9.0 for ; Mon, 08 Jan 2024 07:14:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726842; x=1705331642; 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=p2vXh+pSNK2Iht3pnXQCJkC17vaS5mbAQ1w3JtGP+qY=; b=oWZf1+8b2crFBvFf7ptRGSu05YyKKtSSPiU95RbOImfmPJc1j1vfOzMmJnJdCxS3m7 /v7jkt7HcA6/Z+rwNmEKHHgvpNO/m2+XBip9sFqLR14grlw14h+mqMASqcYxKbwBQH5R VFk4CBoKDby4sWQ/N1kLLAiAZwz3y2I+kt48PfP1149/rH2Xg2g5o2ltV+IApV0V2FfU VMWlXMSPy0+bUisBykangTpzJDhNUnKVmXU6wTQb4UfdCLcAN5GGlwIKxP48rAav5gNF /5aEXv0qRp7I7BJXKilSmi6/76e9vNv3on/ot/jLwMPiJfs/zBSJZAdgljm2Yj0PlW66 /QFg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726842; x=1705331642; 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=p2vXh+pSNK2Iht3pnXQCJkC17vaS5mbAQ1w3JtGP+qY=; b=lml8cNW1kJ/o6tLOFO4vs6d5BSQbxJeePBMx/JkuRTKTm9F4ESpPCTrfA9IlTgE5Gc LIFhtggV1jqP5OPubJj7Es5wTVCJ82lhbOSvSc4sixeop7gt2KT2eKWmGalW4cUFMMpt 1OycIgL6R29DsoAi7Yd1yaZ9Pm/v0x8GFGuBUWCljqKE/z9rUsbfOHp0fNx9LNgryXwP IadVz9BhbnGjke1EjVHi1BP3uFypGIEyziWOUnjEdiM05Ak8a5c54NT42eQ6WjE5DzCK Aeu2fCg5odNrHTgHQE0B475SmNKDgyKEVOJgW6Iwoy2xQYB8TnQArk0ueYIrVaPApQsQ EPlQ== X-Gm-Message-State: AOJu0YwCt1J6Lf8JF5as4p1pyWZ+2h9FI6FdkbU+zejeUuftACSx8ul5 iXdO+bzo7Wk8JgR0oAY0m+G6bG0LXHVwoA== X-Received: by 2002:a05:600c:4e8c:b0:40e:435b:4a41 with SMTP id f12-20020a05600c4e8c00b0040e435b4a41mr1573362wmq.89.1704726842394; Mon, 08 Jan 2024 07:14:02 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id cg2-20020a5d5cc2000000b00336c120855dsm8018677wrb.84.2024.01.08.07.13.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:14:01 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id DF2525F93F; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Pavel Dovgalyuk , =?utf-8?q?Philippe_Mathieu-Dau?= =?utf-8?q?d=C3=A9?= , Richard Henderson , =?utf-8?q?Marc-Andr=C3=A9?= =?utf-8?q?_Lureau?= , Paolo Bonzini Subject: [PULL 12/13] chardev: force write all when recording replay logs Date: Mon, 8 Jan 2024 15:13:51 +0000 Message-Id: <20240108151352.2199097-13-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-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, 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org This is mostly a problem within avocado as serial generally isn't busy enough to overfill pipes. However the consequences of recording a failed write will haunt us on replay when the log will be out of sync to the playback. Fixes: https://gitlab.com/qemu-project/qemu/-/issues/2010 Acked-by: Pavel Dovgalyuk Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-13-alex.bennee@linaro.org> diff --git a/chardev/char.c b/chardev/char.c index 996a024c7a2..48f28881c28 100644 --- a/chardev/char.c +++ b/chardev/char.c @@ -171,6 +171,18 @@ int qemu_chr_write(Chardev *s, const uint8_t *buf, int len, bool write_all) return res; } + if (replay_mode == REPLAY_MODE_RECORD) { + /* + * When recording we don't want temporary conditions to + * perturb the result. By ensuring we write everything we can + * while recording we avoid playback being out of sync if it + * doesn't encounter the same temporary conditions (usually + * triggered by external programs not reading the chardev fast + * enough and pipes filling up). + */ + write_all = true; + } + res = qemu_chr_write_buffer(s, buf, len, &offset, write_all); if (qemu_chr_replay(s) && replay_mode == REPLAY_MODE_RECORD) { From patchwork Mon Jan 8 15:13:52 2024 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: 760775 Delivered-To: patch@linaro.org Received: by 2002:a5d:6e02:0:b0:337:62d3:c6d5 with SMTP id h2csp936279wrz; Mon, 8 Jan 2024 07:16:13 -0800 (PST) X-Google-Smtp-Source: AGHT+IEbtBCnQJFec56CmVOGPkxzaIkmPE2L5jtTLgB6affK1e1BDM9AwdDOeSZSMYatiHrUPuZg X-Received: by 2002:a05:620a:4722:b0:781:e973:29bc with SMTP id bs34-20020a05620a472200b00781e97329bcmr5522017qkb.144.1704726973345; Mon, 08 Jan 2024 07:16:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704726973; cv=none; d=google.com; s=arc-20160816; b=UQp+m1OB6yVfiZy3zaNmCqKavioETjCVVFamq7dUTIvE74jRSg5F1x5trNVaOQW10m 9KkjE/BepioUhwsRl3r0ytqgULLabEgk8N7jegunaT4Gs4Vu/gmLRpCWO8VqRY/czmVv c3EvOudrwV7POHgnif+HdLXJU2nMygub/6Jz2WtCkoeRiAc1YhyZFb292aGp97A037Cw CIJkyBySz5IEeAm63shMwgaohqW1jN82KiO8V4QTexuveQ7e3lDllLOKMVlSlaIcvMnB 0o6F8DipEzIf1/+5ltg8QW9QCRb4higlLIyePB9iiEwiQEMA3u9XOUU/HzyHMcmanPoz 7dQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=CCcg7ysSyOpy/NHtcycGrXvCgSegX/kK/v3WtacdHyY=; fh=NtC0c/BN25XLBfbNkbcmcqHqcFGdCp1JfAsgzwgoJVk=; b=LB7S1i3/V7ca1Xuew7StIs1HPH6/vz6UOD7Jd3ArtYZOJalQyNQAmwagCg5qERoLVB kyfYnNcP0Hvz/XgLkY1qzxX9b/fsTZwH8HvlU+6jAv31eilsDNLRZRiiSGr0maYT8ukp vVhNE92yKuvyMGMoNNRc972ebQxyXBgeIMb3uiiyKVnJolaiCQdqf3ne6s6Aj4S5npS3 6vZARsxNeSrhry9G7cY0YltbQ2keVZMVdvV2K9XwgDe2fJGcsxJ0Vs3nx1Bc9fj/aba1 yHCEBnx/dMan4+9EnM7PtKmV96e+arIX8gKOvu7EeIY9yqaZFdkJJl8oMP36JgbBRfPe SOgQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=j0FXqPgo; 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=pass (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 l20-20020a37f514000000b007811762c5aesi7571112qkk.207.2024.01.08.07.16.13 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 08 Jan 2024 07:16:13 -0800 (PST) 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=pass header.i=@linaro.org header.s=google header.b=j0FXqPgo; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rMrKN-0004Hl-AO; Mon, 08 Jan 2024 10:14:11 -0500 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 1rMrKL-0004Ga-42 for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:09 -0500 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rMrKH-0001d8-GW for qemu-devel@nongnu.org; Mon, 08 Jan 2024 10:14:08 -0500 Received: by mail-wr1-x432.google.com with SMTP id ffacd0b85a97d-33678156e27so1931683f8f.1 for ; Mon, 08 Jan 2024 07:14:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1704726844; x=1705331644; 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=CCcg7ysSyOpy/NHtcycGrXvCgSegX/kK/v3WtacdHyY=; b=j0FXqPgotKUB+gP1zd3Wgzkh8Lp4s5pV5kV4A+WCacIdHiPPYUf9J1X7qgrwMADSlN o/xoTppEi+QbFNd/wpJPXUbXHJY39aL3/6G8a2K2rZZqJp7S/Pc2rCjCi+Udg9bix/qC kmcOS1rd5QKutNYK/kWLu35Ba5oCHXVO3QRya8taDXQDMt0bWPfuMrD1ZeptNVKrR4nB 9LvJqfB+/dRlB3amHriR9NMUyfUTwsznEtjSF+ctPA5w+KVJZG7p/OGU5tzYNc41iltC RNf8g7yNNQacoj8LzVsqzogobp1ap4M8SLl0lFG5pa0eCRvc/TmJyWXL1kaByiF8oPJ3 ZPCw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704726844; x=1705331644; 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=CCcg7ysSyOpy/NHtcycGrXvCgSegX/kK/v3WtacdHyY=; b=gkmyn2LF/9V/S6n4Fyw+TPY6zMKH/7TIzHQy4nOMwfJETnF5NNIWKq/gKpJ5Q/AtOt UPR3LASNGKTyss9uCtr9VI9On5mW6bPryZYxlNJ2SMPwM1g+ZKmRKnhsv7JAoc3eDMyN bqlK8zk8K+zM6sd0POyytu4/sZeIEb1vjdYUKeDQvSR/FVSUGKJhc5Z9e2kr858LQoev jDQJBDlpmjQiaixo2uCvRDvaS2AirANkONXaP7Jn82piQZfHAM6uqOQBCIVGGVgKU6jG mBBq384+d6YELl4TCHXwybNiCBVd+j258HKQNKae+HXUkd4ksEw+E3OFyJc5WPgSPP+L S7LQ== X-Gm-Message-State: AOJu0YxSaoI0ePWoDTCwq84C7TBeHZAYkezvDYL6e7ytqDW2FhB81mZ1 RLIsfvpvWbyxgb87VFMYwo3epGDIpUNP6w== X-Received: by 2002:a5d:4d01:0:b0:336:7e06:390e with SMTP id z1-20020a5d4d01000000b003367e06390emr2009413wrt.134.1704726843906; Mon, 08 Jan 2024 07:14:03 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id o5-20020adfca05000000b00336ee9edbb3sm8028968wrh.94.2024.01.08.07.13.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Jan 2024 07:14:01 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id F2BEA5F951; Mon, 8 Jan 2024 15:13:53 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Pavel Dovgalyuk , Pavel Dovgalyuk , Paolo Bonzini , Cleber Rosa , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PULL 13/13] tests/avocado: remove skips from replay_kernel Date: Mon, 8 Jan 2024 15:13:52 +0000 Message-Id: <20240108151352.2199097-14-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240108151352.2199097-1-alex.bennee@linaro.org> References: <20240108151352.2199097-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, 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org With the latest fixes for #2010 and #2013 these tests look pretty stable now. Of course the only way to be really sure is to run it in the CI infrastructure and see what breaks. Acked-by: Pavel Dovgalyuk Signed-off-by: Alex Bennée Message-Id: <20231211091346.14616-14-alex.bennee@linaro.org> diff --git a/tests/avocado/replay_kernel.py b/tests/avocado/replay_kernel.py index 1eaa36444cb..6fdcbd6ac3d 100644 --- a/tests/avocado/replay_kernel.py +++ b/tests/avocado/replay_kernel.py @@ -98,13 +98,10 @@ def test_i386_pc(self): self.run_rr(kernel_path, kernel_command_line, console_pattern, shift=5) - # See https://gitlab.com/qemu-project/qemu/-/issues/2010 - @skipUnless(os.getenv('QEMU_TEST_FLAKY_TESTS'), 'Test sometimes gets stuck') def test_x86_64_pc(self): """ :avocado: tags=arch:x86_64 :avocado: tags=machine:pc - :avocado: tags=flaky """ kernel_url = ('https://archives.fedoraproject.org/pub/archive/fedora' '/linux/releases/29/Everything/x86_64/os/images/pxeboot' @@ -135,8 +132,6 @@ def test_mips_malta(self): self.run_rr(kernel_path, kernel_command_line, console_pattern, shift=5) - # See https://gitlab.com/qemu-project/qemu/-/issues/2013 - @skipUnless(os.getenv('QEMU_TEST_FLAKY_TESTS'), 'Test is unstable on GitLab') def test_mips64el_malta(self): """ This test requires the ar tool to extract "data.tar.gz" from @@ -152,7 +147,6 @@ def test_mips64el_malta(self): :avocado: tags=arch:mips64el :avocado: tags=machine:malta - :avocado: tags=flaky """ deb_url = ('http://snapshot.debian.org/archive/debian/' '20130217T032700Z/pool/main/l/linux-2.6/' @@ -200,13 +194,10 @@ def test_arm_virt(self): self.run_rr(kernel_path, kernel_command_line, console_pattern, shift=1) - @skipUnless(os.getenv('QEMU_TEST_FLAKY_TESTS'), 'Test is unstable on GitLab') - def test_arm_cubieboard_initrd(self): """ :avocado: tags=arch:arm :avocado: tags=machine:cubieboard - :avocado: tags=flaky """ deb_url = ('https://apt.armbian.com/pool/main/l/' 'linux-5.10.16-sunxi/linux-image-current-sunxi_21.02.2_armhf.deb') @@ -354,7 +345,6 @@ def test_m68k_mcf5208evb(self): file_path = self.fetch_asset(tar_url, asset_hash=tar_hash) self.do_test_advcal_2018(file_path, 'sanity-clause.elf') - @skip("Test currently broken") # Console stuck as of 5.2-rc1 def test_microblaze_s3adsp1800(self): """ :avocado: tags=arch:microblaze @@ -389,7 +379,6 @@ def test_or1k_sim(self): file_path = self.fetch_asset(tar_url, asset_hash=tar_hash) self.do_test_advcal_2018(file_path, 'vmlinux') - @skip("nios2 emulation is buggy under record/replay") def test_nios2_10m50(self): """ :avocado: tags=arch:nios2