From patchwork Thu May 2 05:44:16 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 794089 Delivered-To: patch@linaro.org Received: by 2002:adf:a153:0:b0:34d:5089:5a9e with SMTP id r19csp77856wrr; Wed, 1 May 2024 22:45:34 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCUYHC1Lno31++2iZfW660vDqPZoL2RA7nJQ7hwhlhc6THgyf+r2IpbMZgSpbOztfD+jtrCGEpcjieza5J79hjU0 X-Google-Smtp-Source: AGHT+IE2rkA7jXlXuGSh5nK+Dh6dCIbe4FnenxaKxBNyzv34TQ5QifiN6nMGo+f9jH65HANrt1FK X-Received: by 2002:a05:6808:1813:b0:3c9:147c:bd22 with SMTP id bh19-20020a056808181300b003c9147cbd22mr5388794oib.29.1714628734378; Wed, 01 May 2024 22:45:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1714628734; cv=none; d=google.com; s=arc-20160816; b=EMkKTU1U2Y5brGe6NGh3MtX2dKEQFtnTX2UURqFFHjRWh8kQeV3MUm85X5CI91lve+ DPZtFIM8iiJm+VZu5sBu6AjXRv8IUeILkr7MVuiaTKInAkAjh21Sjdwkbsa7pA43Ys1k Gw0ZMHSvq+Jus9YAqnRz26VWYrTNKLJF4XBbB9L2fy2xPbtrdsiJN9SNc6ZUMVsDAlDO gn2xoSb91IyK8CUoUOS/NaZD857ilBm7eZzcyrePXh+QrHzjEo0Ze6dHLm3Q/Ft8nRZl noEAINTh3MmdkHKOq+AyUKiL6cgmVrZVkOi9OmtYgVL3FLacI0bmshQuqrdGXF8Jo5tN 6LoA== 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=lH/q0WCjN3MJHGH0D+l3dpNzf1frODIUflx11LUrBRY=; fh=vvIHVEExtoxBacLa1w/xvEOdET6IjbTxlMJ0GExg4HQ=; b=Q8KMYWMTm4tdjFbYYF0lfwuSje4SscX9Q/J+4ScKmW1BgZHnu5see7wMZyf1/iC8EE kUyfcPc51FbGf0WuNJcJ0N82P4LwJFrSoswEkPOyLwXAQRxOFIC4HZ/lz0TTG2ThcTtZ wEF7fTrye1IiMuPQRPVmIB9uYa6nftPQ9XQuOzKBRNYmTXfxV/lCNnfnHEcqzCK+9MHm ZLPTDKrM1YrBz2986G0S8n2LIzjhl9T2f18RDLoXpscC+59uWcU+cHPPLRGrpkw9iTiu UGaAoOIP+4z/h4h3sbP7rbef+5nIWTziP2GAMCLWZGGMLPPsOq2E64YOt+hF5t+Vu/JN mNYg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cPHxv6hc; 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 bk13-20020a05620a1a0d00b007919c01a191si238824qkb.494.2024.05.01.22.45.34 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 May 2024 22:45:34 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cPHxv6hc; 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 1s2PFR-000086-2p; Thu, 02 May 2024 01:44:49 -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 1s2PFK-0008SY-7x for qemu-devel@nongnu.org; Thu, 02 May 2024 01:44:42 -0400 Received: from mail-oo1-xc33.google.com ([2607:f8b0:4864:20::c33]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1s2PFB-0002fY-UT for qemu-devel@nongnu.org; Thu, 02 May 2024 01:44:41 -0400 Received: by mail-oo1-xc33.google.com with SMTP id 006d021491bc7-5af03aa8814so5103533eaf.2 for ; Wed, 01 May 2024 22:44:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1714628673; x=1715233473; 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=lH/q0WCjN3MJHGH0D+l3dpNzf1frODIUflx11LUrBRY=; b=cPHxv6hcEc3AD4eUUzqAbdntZyQyEkbmI8N3JZAkD301cQEmybkNi2HTZtTlNwSXfo sWixZ7W7nwglgb95C4OY3NSwJZJI+DkLmAeB1NBgMcMdX9UbeC28DcLnLja2BlVfiCHT yrRYdYbVOlKTcrln+EYFgU0byxJlWm19XW4423lu6Lmqx7ZVo9b+jHc9RRseQjUm5PK4 XAZ64b833TZYLWJ5LNRw/ij7vGJ8tZNOyDz1sawws7wx5wBpU80r8ZoHZYc3V+w8zTtk RNE5CSdRbSezbpOUZlo/cxAJ1k/oT1KDAVfNWS1ATCUH98/ov8UIj0C9VTMdvUo/a+Nq u4mw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714628673; x=1715233473; 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=lH/q0WCjN3MJHGH0D+l3dpNzf1frODIUflx11LUrBRY=; b=jRfD0Ds/1p1L8v/yULVjECOim6MC25OIzBGl5oq31hV0wNT1Hc3WfMY0kg1vjE24m5 Y2BqMWP5i9uW9ZrWjHFW3mRB1MA4X1MmnY075bbf3LPiwKc+ihy3/sekt40yK9TtZLWI I12/LvWUz+GIBxxqk86Z00PKR2tkAsVnPIS1kG/Qh80TFUf0PHtydv/0mcqIgY6Fs0pJ z4zEVfxoS7RtLsqNZ2xjMkgpXMIZvMDt0d04CQ2YGjuuU18SkNO1XlvM5LatQXO7aTTb VKGpeMBOZbTAfCv6DZSA77K9tmhSIkk6s0PaNZa4b3R/0d7ctdRmJ2BlPKW+T7V6s06Z VtvA== X-Gm-Message-State: AOJu0YwnueLr/A+/vSXDSZ2Xx8vuZtkcYnvcoudq1DX1O+ti/01gw9rY V7S6sWrKHETgBW/F7WdIksT0wmtvCFoMRMHSWTpxoWf7C7KId0osMkSMeOcmrcZ/pGrPkr/l601 r X-Received: by 2002:a05:6358:481a:b0:17e:69a1:a797 with SMTP id k26-20020a056358481a00b0017e69a1a797mr5551981rwn.30.1714628672730; Wed, 01 May 2024 22:44:32 -0700 (PDT) Received: from stoup.. (174-21-72-5.tukw.qwest.net. [174.21.72.5]) by smtp.gmail.com with ESMTPSA id e18-20020a656492000000b006089cf2cde5sm294401pgv.26.2024.05.01.22.44.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 May 2024 22:44:32 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: qemu-s390x@nongnu.org, iii@linux.ibm.com, david@redhat.com, thuth@redhat.com Subject: [PATCH 13/14] target/s390x: Adjust check of noreturn in translate_one Date: Wed, 1 May 2024 22:44:16 -0700 Message-Id: <20240502054417.234340-14-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240502054417.234340-1-richard.henderson@linaro.org> References: <20240502054417.234340-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::c33; envelope-from=richard.henderson@linaro.org; helo=mail-oo1-xc33.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org If help_op is not set, ret == DISAS_NEXT. Shift the test up from surrounding help_wout, help_cout to skipping to out, as we do elsewhere in the function. Signed-off-by: Richard Henderson --- target/s390x/tcg/translate.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/target/s390x/tcg/translate.c b/target/s390x/tcg/translate.c index 7cf2920aec..8e9c0847e3 100644 --- a/target/s390x/tcg/translate.c +++ b/target/s390x/tcg/translate.c @@ -6343,14 +6343,15 @@ static DisasJumpType translate_one(CPUS390XState *env, DisasContext *s) } if (insn->help_op) { ret = insn->help_op(s, &o); + if (ret == DISAS_NORETURN) { + goto out; + } } - if (ret != DISAS_NORETURN) { - if (insn->help_wout) { - insn->help_wout(s, &o); - } - if (insn->help_cout) { - insn->help_cout(s, &o); - } + if (insn->help_wout) { + insn->help_wout(s, &o); + } + if (insn->help_cout) { + insn->help_cout(s, &o); } /* io should be the last instruction in tb when icount is enabled */