From patchwork Thu Nov 2 01:29:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 740373 Delivered-To: patch@linaro.org Received: by 2002:a5d:538f:0:b0:32d:baff:b0ca with SMTP id d15csp595104wrv; Wed, 1 Nov 2023 18:37:50 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFVqCDJb9eP8DmPqe/COFPcDpFNyLsONd1iKoljpd0vwxhRr1czA56cW9Nm2sgj7uYQTVhy X-Received: by 2002:a05:620a:2ae9:b0:77a:1cc0:6e5c with SMTP id bn41-20020a05620a2ae900b0077a1cc06e5cmr13303978qkb.21.1698889069951; Wed, 01 Nov 2023 18:37:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698889069; cv=none; d=google.com; s=arc-20160816; b=wWbC5e6LowQad1vX915VBeiy0KXo2wSnWQ6UwHeGBiXeYW2mu3IAYtdLMZ7ML5EKS/ +Tm4motkzd5AWg5oxEJc1JUxnQ3Q/GLpwI0hH3PJygbVEWv7LZgpuH6rPX6x3ICJNS3Q 24xozdu2TGb01BcxoEBWlIj6vSmHI0gMKiwEL5mBfGYJVwmi8GlrtNZT5wbQR5pMJqaS rQ9iGsO7WYXFxEWfBSw0x6Q6BpP8+sX8gKRPvOVKNSa3oqDPnKBSZigb4ZcXiUA+KkkC Uk7yiZizdpqJuCciAcBqJqUCaD27tPIUvx5+qkmPDwtnRnWJXcHnmQjeTpjfpzYOh082 zPJA== 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=Qv/a5qw7IRMvc9+1bsPwBvAxjMkczYjB4ck+5MvAjzA=; fh=f2WZoDMBYjCKWIIOoPI+rQtxlv4fmOm4u+dLdQLqpOk=; b=G2HjYetFzc6zGnt5mOLrC0wQhtfcGLw3tbyBGjb3GdRWq6PNhWXyk4LWzKuxLZT80p qsrwtK1+EJmvSBwYuRS5kHp7V4tZSJZPZ9z5tcop4ybykdATpek7oARY8EQ4Yi8TSu/a xqNbOYnh0C0jdFzs0g6R8tK05PPZqWjsWAxZDkcMWJt2eV+tU6ZfXRZa+9Cbj31V8+C5 5Eg+jiKZ2AZbtBY5WhpXyjkwe2uVjrb7dmnzQB99p7AUCvZTNKSQ/lrEUJZQAHylkmqm iV7A8+nmLnsxW0JIJm95Jv/PPgXqGj50K9TcZhTBBJvr8DBVHL9dIMff8o21/KJBlRG+ DFGA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="RSqI8Wn/"; 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 ty5-20020a05620a3f4500b00773fa71cbb8si3438699qkn.512.2023.11.01.18.37.49 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Nov 2023 18:37:49 -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="RSqI8Wn/"; 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 1qyMcm-000165-Vc; Wed, 01 Nov 2023 21:35:57 -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 1qyMay-0006OV-1P for qemu-devel@nongnu.org; Wed, 01 Nov 2023 21:34:04 -0400 Received: from mail-pg1-x531.google.com ([2607:f8b0:4864:20::531]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qyMaw-0001vd-Ku for qemu-devel@nongnu.org; Wed, 01 Nov 2023 21:34:03 -0400 Received: by mail-pg1-x531.google.com with SMTP id 41be03b00d2f7-5ab94fc098cso298532a12.1 for ; Wed, 01 Nov 2023 18:34:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1698888840; x=1699493640; 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=Qv/a5qw7IRMvc9+1bsPwBvAxjMkczYjB4ck+5MvAjzA=; b=RSqI8Wn/LNxAn1kHwFTf8Cgu3c6ZcUurxNRACwJ6OkYzRv2+ywQ2bFNXJXC0M6F1hi XzXe3Iv3K+YTDygHw2cRJ2iXaYd7sPTLLQL+lNVENnzznRG/0fqnJrqg2qnjn62mPRWf zhdgU0FoOa92TghtCkNoBdDAq/QT4pqH2Kj24v/qClYbjanguLOgDt6Ak/N9IxJIPYK/ k6xyHCjjkwtT/xfhHoPod3nnz1MkcCsSEcZWqe18ZMqmQukWrTFPt2uO68BqE/tLIxH8 vhpYCtPiqKgllNhwK/tUzOgwKNUe6WLSH4lkGNlaFl8kFoNkew8fs/pI29ADMpTO268Y ziDg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698888840; x=1699493640; 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=Qv/a5qw7IRMvc9+1bsPwBvAxjMkczYjB4ck+5MvAjzA=; b=IPpqaQxBP7rnmVMFtCpA0RU1M3vJy5aRWgPiv32TUGC/sp5BOYNTb2hwqcUWG4xhU5 QrJst92brgRkHU4dqHscOxBgpPMOnqOgJ4OXTxYXE4HgAs2SvdDqgMKlhG/+0WtVWAac tJHrJKAaxIifSpelWHsd13gnoN6HR6T8pWFRe9x6+vP35RNR8JRWDRFjfdVe+754qM6m QM+Uz+kxoqLzcZaIxADI/OvvnzyGTSw4WYUF2ezZQOCegnCDsN4UlKDcUjiVmIsYC4wd OtLAEBcymGo0duwXVBAXLYmGirW8kzC1IFLsv7wwOGzi7Ct7PLm4uZsSsKxicNIB2ZK6 Rr8A== X-Gm-Message-State: AOJu0YyUvsDZ77IVQGCAL57QdaVd2EoB7fghZJneSVGWRFh3adkqbi67 ZuequMrvUz58wTUKA3UVpwurW3i8lCNFhXOWnp4= X-Received: by 2002:a17:902:d2c7:b0:1cc:4efc:c87d with SMTP id n7-20020a170902d2c700b001cc4efcc87dmr11620470plc.55.1698888840490; Wed, 01 Nov 2023 18:34:00 -0700 (PDT) Received: from stoup.. ([71.212.149.95]) by smtp.gmail.com with ESMTPSA id t2-20020a1709027fc200b001a98f844e60sm1918125plb.263.2023.11.01.18.33.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Nov 2023 18:34:00 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: deller@gmx.de Subject: [PATCH v3 48/88] target/hppa: Decode ADDB double-word Date: Wed, 1 Nov 2023 18:29:36 -0700 Message-Id: <20231102013016.369010-49-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231102013016.369010-1-richard.henderson@linaro.org> References: <20231102013016.369010-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::531; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x531.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 Signed-off-by: Richard Henderson --- target/hppa/translate.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/target/hppa/translate.c b/target/hppa/translate.c index 7f767fea64..1b4fa401ba 100644 --- a/target/hppa/translate.c +++ b/target/hppa/translate.c @@ -3143,6 +3143,17 @@ static bool do_addb(DisasContext *ctx, unsigned r, TCGv_reg in1, DisasCond cond; bool d = false; + /* + * For hppa64, the ADDB conditions change with PSW.W, + * dropping ZNV, SV, OD in favor of double-word EQ, LT, LE. + */ + if (ctx->tb_flags & PSW_W) { + d = c >= 5; + if (d) { + c &= 3; + } + } + in2 = load_gpr(ctx, r); dest = tcg_temp_new(); sv = NULL;