From nobody Sat May 18 11:46:44 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1690566718; cv=none; d=zohomail.com; s=zohoarc; b=SuEYsxXwi5e7VLXpjNSB7wAinXs19myZ+3DqHXnyNWHQJBkMHO82zQFTgLnOD9vA77dORniHX8gfhQf85tptMit4UHFculK8HS1wwm/DsTS8ZCiWYS58OKuaqTlblZ7fJXIOq1nQjZOsjsfi0iWMtSog0K26DaaVUZGw+bAPfIo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1690566718; h=Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=ACJP/cSQlj33yExohwZEBzfmCkDyB3Wg5IYx7mUDA/A=; b=UQS3Mk4lnGmGTPd/qvHY1QZhusai11/xnp9JNEFaqS73+4510E0GypdDu8e+/c6Q8zeMHfLV2Xq2J3TDeuO/njM3dIMT+ocmFXAN8loFVqErLn059MjU4If/4oq7+2HQ01ZD7RVQImdxI/MD5piBliXT/sXND8enw69OkgEQKdQ= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 169056671883970.21872313361462; Fri, 28 Jul 2023 10:51:58 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qPRN8-0007Ni-Vz; Fri, 28 Jul 2023 13:35:27 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qPRN8-0007NS-0g for qemu-devel@nongnu.org; Fri, 28 Jul 2023 13:35:26 -0400 Received: from mail-pj1-x1029.google.com ([2607:f8b0:4864:20::1029]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qPRN6-0004vf-Bg for qemu-devel@nongnu.org; Fri, 28 Jul 2023 13:35:25 -0400 Received: by mail-pj1-x1029.google.com with SMTP id 98e67ed59e1d1-26837895fbbso1714338a91.3 for ; Fri, 28 Jul 2023 10:35:23 -0700 (PDT) Received: from stoup.. ([2602:ae:154e:c001:cfba:2f6a:7070:67a9]) by smtp.gmail.com with ESMTPSA id co4-20020a17090afe8400b00267e299f71dsm2821211pjb.7.2023.07.28.10.35.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Jul 2023 10:35:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1690565722; x=1691170522; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=ACJP/cSQlj33yExohwZEBzfmCkDyB3Wg5IYx7mUDA/A=; b=nzcLBorQHRlrUvpNb70CrsOL29VHZpRdyqTelcftm+lsOGRE8P3p/D/WvQOyNGbQPc 1oQRXZyrsoAAD4By3dXBpepFN5pLR2vv/56VJI7e2gFtMlg5FKYCTLbfZGGwiXA15lJk zlChX0ZPI6SJ4CT+q+AOvnOIfnBWAJWoUsPuJnPBiOui7jtmFQ29x7cVDFayGng4CoSr kg9q6KUPg0u27L7vwXBkcDrIkorIxq+Z2S3Iy9c3iN+U0fAG/QXsuAlHatUGtXtPsTGe sZUrNM1N7xFkM8eVrAczbHDKD6pngQh5YQDzvX0xLM0FMtUSsmwdUePKv5OmvO6YyVjF sXPA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690565722; x=1691170522; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ACJP/cSQlj33yExohwZEBzfmCkDyB3Wg5IYx7mUDA/A=; b=CiHQjcE+rBP2fJRd6nLtjOSw5T117Icx0rtAmw46ACHvioqhR785j6mKh3IhIQ5nyl RgtxI9CyD50jGZ5QQOnbM9FpWbdZGBTgGmBVPKAUw9mmnsQsvgOKaADdWDfHgGvgo4D6 8cRvlR39OOFElfDBAevTA0vyNV1k33v3HQnwsibwMMolM8BUCMDGeKNyKJiNt/TvLhR1 hL44aua8xrGRZ96vQvKI4myBp/BV8cfUK1N9DATzdAL6dNEGZ1OMW/4Sd+IjVBK0T5S8 pfsirCLE+GK6QV/kIQOcFtcDgytiSZ8h7F7OeQ3UuR8uqVyZQhsLZBpcBSGFregq8ydW Dldw== X-Gm-Message-State: ABy/qLYMhXubq7r+XZmTvKPzMeh41DCYHQ1SqEU4s3XosDO9HGkffKgs x1U37JmEH5MicgW+mjOPsZWqMO9GeLgfsU+gO/8= X-Google-Smtp-Source: APBJJlHbVP+e3LWoi08ZKSOPJNqJdwBhOsE+v/43Jk5DzEVxcmC0UAOCWmWihO4d9dM3ticvZWT9Jg== X-Received: by 2002:a17:90a:8c0e:b0:262:fbb0:8737 with SMTP id a14-20020a17090a8c0e00b00262fbb08737mr2385640pjo.33.1690565722646; Fri, 28 Jul 2023 10:35:22 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: qemu-ppc@nongnu.org, npiggin@gmail.com, groug@kaod.org, david@gibson.dropbear.id.au, clg@kaod.org Subject: [PATCH] target/ppc: Disable goto_tb with architectural singlestep Date: Fri, 28 Jul 2023 10:35:20 -0700 Message-Id: <20230728173520.486025-1-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2607:f8b0:4864:20::1029; envelope-from=richard.henderson@linaro.org; helo=mail-pj1-x1029.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=unavailable 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1690566719747100001 Content-Type: text/plain; charset="utf-8" The change to use translator_use_goto_tb went too far, as the CF_SINGLE_STEP flag managed by the translator only handles gdb single stepping and not the architectural single stepping modeled in DisasContext.singlestep_enabled. Fixes: 6e9cc373ec5 ("target/ppc: Use translator_use_goto_tb") Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1795 Signed-off-by: Richard Henderson Reviewed-by: C=C3=A9dric Le Goater Reviewed-by: Philippe Mathieu-Daud=C3=A9 --- target/ppc/translate.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/target/ppc/translate.c b/target/ppc/translate.c index e6a0709066..74796ec7ba 100644 --- a/target/ppc/translate.c +++ b/target/ppc/translate.c @@ -4175,6 +4175,9 @@ static void pmu_count_insns(DisasContext *ctx) =20 static inline bool use_goto_tb(DisasContext *ctx, target_ulong dest) { + if (unlikely(ctx->singlestep_enabled)) { + return false; + } return translator_use_goto_tb(&ctx->base, dest); } =20 --=20 2.34.1