Message ID | 20210629185455.3131172-39-richard.henderson@linaro.org |
---|---|
State | Accepted |
Commit | 8fcfc6bff61f1faf0a530b4fae292931a39cc32b |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a02:c94a:0:0:0:0:0 with SMTP id u10csp5265282jao; Tue, 29 Jun 2021 12:49:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzB5+YXBXxpKlkQZ2WxPz6r1g8FXgVaOaJLPhlaQneG9fFNSG+7zfMHL9p4DNs1bw62vdXF X-Received: by 2002:a9f:2c91:: with SMTP id w17mr29101535uaj.73.1624996197259; Tue, 29 Jun 2021 12:49:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624996197; cv=none; d=google.com; s=arc-20160816; b=A6+XwIuQ2XM3d14+sVYWqRdQGGg1jH5IP36dKBsdOUrhHi0NPgLchVVnLedexIROn6 KZSiPe4UJQydVw97hzAgpZL/vyBTM+cQ07lrr7E74YkE/y0DGKUj2JGWEEme2T0VBEqu KpvOqcNe4nyA+fCUD/eEfY7LVUj8tOMSvXoaBjK+2ChK3L6eCIXKMMvJ3EHEzxglYio8 w1qz0TlXFlIn+jDstSilLLCQLCF4FkBuS22LtfvbiVaLPzNnNMWUl7szgZ3cteLo40Fj tVGmeuxm/meEha2EsGhH3vrWJ8nhCTSOcQSBqXwN31jOOTWYRjb/nNy5HOnTdzrPIoD6 dRZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc: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:to:from :dkim-signature; bh=RzG+IK53XdySkGDuIO25Vl9LUHRHkp4N6+CK9vmLiEo=; b=NMu2aPpq6Gp6i1jfhkjWJ6ChskqcOLDak/YPqDU5NiXCVQvoaC8aqYg+0K8cOkf1ui RY7ej4njWqvZTi5OYDc5AOLHaa1BZKfAQMy4ODOFjjwLhWr2JRBd7PKLOGFirwS9956o zhvtoKXrHagBzc/iqgRfDDMM2D0VopZRkowcjHJ0y2VPOi4iFCmxHcbWs8pCbB0czol4 a5FK+RFOVddKwhQfRPgH1PGtpY/snd4GtwHW2tHPg+bgb2cp+lKMma93yUzgHHntG8yR domIsaCRgKGmu8kvDM+0iFV/598NAITFyRS0s3zHJ4K+ERxcu6gw2YCyBU7hc4qKjVzc zCUQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=SXb3y76b; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: <qemu-devel-bounces+patch=linaro.org@nongnu.org> Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id a4si10951106vsn.4.2021.06.29.12.49.57 for <patch@linaro.org> (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 29 Jun 2021 12:49:57 -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=fail header.i=@linaro.org header.s=google header.b=SXb3y76b; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:58058 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from <qemu-devel-bounces+patch=linaro.org@nongnu.org>) id 1lyJk4-0003OJ-MC for patch@linaro.org; Tue, 29 Jun 2021 15:49:56 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:38824) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <richard.henderson@linaro.org>) id 1lyItU-0000C0-B2 for qemu-devel@nongnu.org; Tue, 29 Jun 2021 14:55:36 -0400 Received: from mail-pf1-x433.google.com ([2607:f8b0:4864:20::433]:41747) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <richard.henderson@linaro.org>) id 1lyItF-0000z2-58 for qemu-devel@nongnu.org; Tue, 29 Jun 2021 14:55:36 -0400 Received: by mail-pf1-x433.google.com with SMTP id c5so90902pfv.8 for <qemu-devel@nongnu.org>; Tue, 29 Jun 2021 11:55:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=RzG+IK53XdySkGDuIO25Vl9LUHRHkp4N6+CK9vmLiEo=; b=SXb3y76bCDgPgKDSZJ7Zzzkh2RdxrRTnRcaZfdfa0OTJV+dtAEJsh+89cwc6Wz9GUn Ubc6/Kz2tquuejdADQaYMIWb26YY5aSXZCcYo38lTlDWABdOJRABb2elwpgvc7k3rPg7 aA5LIHAU5IWK1J6hcfFvBBbbPdYZuDO2FeDXHA7RTT47V6tUzsFIYiOpvkEu8R6j0g5w VvJd8RTdpd+WkdkawtFyxYGVni/ywBxC1TthS0G4YQtuKQOIwbjT34a0t6nT7O4rESJ3 UKBB7T/zYVH8MvY9YnG463gOQ7h3PIHMuS2zog9kCEG0NPe2qshCHN/kxNG+xV6MG0T4 H3sA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=RzG+IK53XdySkGDuIO25Vl9LUHRHkp4N6+CK9vmLiEo=; b=mMja9IF8llR82UQYGSBQ/PcsF/6q2WdZOwUkrLxROaLHBylTziRU86KupmysdgwKkE d1t+aeWJ0194W5xvD3BW1Qmc+BHH6MKcmoDh014o24h4ozycl4vDRdtzA12kAUaHElSa MWm1nUyuP35f8o6Lc4GSvNgL9k91raylsM9nKNu5s7wVPUutY09yIwciis6KSHto1J0n 8hnzU0R+yRNxRaYw9PIKDWKfzloRGfLoUTKLQzIGYWKbEGDsvn7aRnfNt1pm6zzI2B+b THHD/jxA+t7S6JWHeG5solB0gKaXe5Txji7VvpImxLCwzdDSMnomlomDUrPiio2KZ20l t10g== X-Gm-Message-State: AOAM5328hkK4+QaIP6klBg72sqqBjnQoglOtAlOmZFucip02CI5jYeeF zbzGuQGNwpRs85odgo7FBKIlgjgurfUmew== X-Received: by 2002:a62:cf02:0:b029:307:f3d:6a2a with SMTP id b2-20020a62cf020000b02903070f3d6a2amr4466948pfg.9.1624992919854; Tue, 29 Jun 2021 11:55:19 -0700 (PDT) Received: from localhost.localdomain ([71.212.149.176]) by smtp.gmail.com with ESMTPSA id j2sm18811253pfb.53.2021.06.29.11.55.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 29 Jun 2021 11:55:19 -0700 (PDT) From: Richard Henderson <richard.henderson@linaro.org> To: qemu-devel@nongnu.org Subject: [PULL 38/63] tcg/aarch64: Support bswap flags Date: Tue, 29 Jun 2021 11:54:30 -0700 Message-Id: <20210629185455.3131172-39-richard.henderson@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210629185455.3131172-1-richard.henderson@linaro.org> References: <20210629185455.3131172-1-richard.henderson@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2607:f8b0:4864:20::433; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-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, 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.23 Precedence: list List-Id: <qemu-devel.nongnu.org> List-Unsubscribe: <https://lists.nongnu.org/mailman/options/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe> List-Archive: <https://lists.nongnu.org/archive/html/qemu-devel> List-Post: <mailto:qemu-devel@nongnu.org> List-Help: <mailto:qemu-devel-request@nongnu.org?subject=help> List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Cc: Peter Maydell <peter.maydell@linaro.org>, =?utf-8?q?Philippe_Mathieu-D?= =?utf-8?b?YXVkw6k=?= <f4bug@amsat.org> Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" <qemu-devel-bounces+patch=linaro.org@nongnu.org> |
Series |
tcg patch queue
|
expand
|
diff --git a/tcg/aarch64/tcg-target.c.inc b/tcg/aarch64/tcg-target.c.inc index 8619e54fca..72aa7e0e74 100644 --- a/tcg/aarch64/tcg-target.c.inc +++ b/tcg/aarch64/tcg-target.c.inc @@ -2177,12 +2177,24 @@ static void tcg_out_op(TCGContext *s, TCGOpcode opc, tcg_out_rev(s, TCG_TYPE_I64, MO_64, a0, a1); break; case INDEX_op_bswap32_i64: + tcg_out_rev(s, TCG_TYPE_I32, MO_32, a0, a1); + if (a2 & TCG_BSWAP_OS) { + tcg_out_sxt(s, TCG_TYPE_I64, MO_32, a0, a0); + } + break; case INDEX_op_bswap32_i32: tcg_out_rev(s, TCG_TYPE_I32, MO_32, a0, a1); break; case INDEX_op_bswap16_i64: case INDEX_op_bswap16_i32: tcg_out_rev(s, TCG_TYPE_I32, MO_16, a0, a1); + if (a2 & TCG_BSWAP_OS) { + /* Output must be sign-extended. */ + tcg_out_sxt(s, ext, MO_16, a0, a0); + } else if ((a2 & (TCG_BSWAP_IZ | TCG_BSWAP_OZ)) == TCG_BSWAP_OZ) { + /* Output must be zero-extended, but input isn't. */ + tcg_out_uxt(s, MO_16, a0, a0); + } break; case INDEX_op_ext8s_i64: