From nobody Tue Feb 10 13:37:20 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1545117078378504.0813250114088; Mon, 17 Dec 2018 23:11:18 -0800 (PST) Received: from localhost ([::1]:52217 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gZ9X6-000216-Ny for importer@patchew.org; Tue, 18 Dec 2018 02:11:12 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53250) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gZ934-0001s8-IK for qemu-devel@nongnu.org; Tue, 18 Dec 2018 01:40:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gZ92v-0002xp-Bm for qemu-devel@nongnu.org; Tue, 18 Dec 2018 01:40:10 -0500 Received: from mail-pg1-x543.google.com ([2607:f8b0:4864:20::543]:35930) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gZ92u-0002a2-VS for qemu-devel@nongnu.org; Tue, 18 Dec 2018 01:40:01 -0500 Received: by mail-pg1-x543.google.com with SMTP id n2so7350519pgm.3 for ; Mon, 17 Dec 2018 22:39:46 -0800 (PST) Received: from cloudburst.twiddle.net (97-126-115-157.tukw.qwest.net. [97.126.115.157]) by smtp.gmail.com with ESMTPSA id c7sm27072509pfh.18.2018.12.17.22.39.44 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 17 Dec 2018 22:39:44 -0800 (PST) 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; bh=G/n0AtjzKeXwi2DOVDVEH8AoSvsXLdyE81u7l7jdtpE=; b=Rkv6RHSBDhKp459NEvsMaKECfjPUg/3B+5kOnsKeh+BihrAYM9np05xImHR1r1rqx9 w7cn2pZqCeLqBiS6spONNXDiXpz6KC06LtGkH0wBzScgGe+4WsLalJD9fn6DFGhIF4EB WzS04crtdOY6qVrAks/6PmY2eo8fKWV+UH4Jc= 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; bh=G/n0AtjzKeXwi2DOVDVEH8AoSvsXLdyE81u7l7jdtpE=; b=Rm5qhz3K7dgZJuYK7F2xDvFqy5WjQdeSszMIvma+Gp8lqVgP4b+7bshtE/4wHcwJGD NiYYQFvFI9MVkOpy5owgHIF4pJOkyWGBEzsKL59dsYjGyOP3JbQaOAPmW4FWeOSCIsvX jtsWjrp8HYLliA41OgJuVmYWUTXYg6eggem4Mw/YvuGoRtxKO7ziPSRwWkzdwv4O7NKl zu84xW/yDvnBzLe9CfvTNshjyGWK50/28QQ0LvNjDyWh88Jz8qb4FTZGJ3Uj7Z8juypA zB0H3qZxw7HuiUh7y0jqplT3eYzOmi3nXl1dM9jqj0EoPU5qV0MjOSPVpdPEVW07Hi69 pxOw== X-Gm-Message-State: AA+aEWa2wOSGprbmbHTVzNyNlzMR7RuaO9yLbQOu8J79X1GxCcisyGpS ZQKHPbjYYjRoF+hjz3/Cv1zJjVupEgE= X-Google-Smtp-Source: AFSGD/XqQ+9welMvSblbSGO8Dkh52z+redRRs0XUkCZFN9zaAcIsmA0MC8U0QiCkf+5t14xvdNzHIw== X-Received: by 2002:a65:520a:: with SMTP id o10mr1909877pgp.276.1545115185643; Mon, 17 Dec 2018 22:39:45 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Date: Mon, 17 Dec 2018 22:39:01 -0800 Message-Id: <20181218063911.2112-25-richard.henderson@linaro.org> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20181218063911.2112-1-richard.henderson@linaro.org> References: <20181218063911.2112-1-richard.henderson@linaro.org> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::543 Subject: [Qemu-devel] [PATCH 24/34] target/ppc: convert xxspltw to vector operations X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: qemu-ppc@nongnu.org, mark.cave-ayland@ilande.co.uk, david@gibson.dropbear.id.au Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Signed-off-by: Richard Henderson Acked-by: David Gibson --- target/ppc/translate/vsx-impl.inc.c | 36 +++++++++-------------------- 1 file changed, 11 insertions(+), 25 deletions(-) diff --git a/target/ppc/translate/vsx-impl.inc.c b/target/ppc/translate/vsx= -impl.inc.c index d88d6bbd74..a040038ed4 100644 --- a/target/ppc/translate/vsx-impl.inc.c +++ b/target/ppc/translate/vsx-impl.inc.c @@ -1318,38 +1318,24 @@ static void gen_xxsel(DisasContext * ctx) =20 static void gen_xxspltw(DisasContext *ctx) { - TCGv_i64 b, b2; - TCGv_i64 vsr; - - vsr =3D tcg_temp_new_i64(); - if (UIM(ctx->opcode) & 2) { - get_cpu_vsrl(vsr, xB(ctx->opcode)); - } else { - get_cpu_vsrh(vsr, xB(ctx->opcode)); - } + int rt =3D xT(ctx->opcode); + int rb =3D xB(ctx->opcode); + int uim =3D UIM(ctx->opcode); + int tofs, bofs; =20 if (unlikely(!ctx->vsx_enabled)) { gen_exception(ctx, POWERPC_EXCP_VSXU); return; } =20 - b =3D tcg_temp_new_i64(); - b2 =3D tcg_temp_new_i64(); + tofs =3D vsr_full_offset(rt); + bofs =3D vsr_full_offset(rb); + bofs +=3D uim << MO_32; +#ifndef HOST_WORDS_BIG_ENDIAN + bofs ^=3D 8 | 4; +#endif =20 - if (UIM(ctx->opcode) & 1) { - tcg_gen_ext32u_i64(b, vsr); - } else { - tcg_gen_shri_i64(b, vsr, 32); - } - - tcg_gen_shli_i64(b2, b, 32); - tcg_gen_or_i64(vsr, b, b2); - set_cpu_vsrh(xT(ctx->opcode), vsr); - set_cpu_vsrl(xT(ctx->opcode), vsr); - - tcg_temp_free_i64(vsr); - tcg_temp_free_i64(b); - tcg_temp_free_i64(b2); + tcg_gen_gvec_dup_mem(MO_32, tofs, bofs, 16, 16); } =20 #define pattern(x) (((x) & 0xff) * (~(uint64_t)0 / 0xff)) --=20 2.17.2