From patchwork Mon Feb 18 14:30:38 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Gibson X-Patchwork-Id: 158625 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp2605573jaa; Mon, 18 Feb 2019 07:14:25 -0800 (PST) X-Google-Smtp-Source: AHgI3IY3xxRhayJrLkj1Qr5TqBFH2hq3GoJ7LI4Zm6g53UEh3cQXCBvNr7k8BPlxeetjyilH1OcP X-Received: by 2002:a25:28c:: with SMTP id 134mr18852950ybc.405.1550502865847; Mon, 18 Feb 2019 07:14:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550502865; cv=none; d=google.com; s=arc-20160816; b=dvQPurvjrXzqYAYr/6bX9MDLXvImAU4wJjLnA1zhroE8wEKclRMfx4mu7lLCLr+baZ iT0uetv8meUeuiq6Huv2WEDcF9W6dOk7/f/M/L/1/oFTjI1UAugjxDZnYlS/JdKICRAr z+nk/CBzgJwkW5MafuROLggBWZYF8P92b0dIGax/kJuFbPaODjkcNQOdM/82F9vQ5jMa Vqo4fFYgVeZWqwHb2VTtIHM8FOxd0DKfuEjMS54NMzDa45U17xKZXmX+UYMTwTptJLau aAi2pyebtid/xGqlHIjPQ0mrzr5gH73GMJ3LaIT/5IqB82Cg1TT5mIFlfPK31wwv9UdV yF2w== 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:subject :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:to:from:dkim-signature; bh=e+5bTT7cAo+OnNE7qOIYzk/hM6Sfwy8R/EC8msNhfxI=; b=c4Gb8TwgaO2DYr3BCpAh/ulVNhWWoAMkZVX90nkQo2gEBBU78vxqkhD8x8NCL99Ty4 28Cp2BMrcMqGNDso68HdiE5x72UBe7c4lYjUXpZ+xX40fskyctGfdmcYLBoaiFTGDxcA m6rBGopPCvkPkK9w+k7kn0MOQzeAkDMsrpqpO6c2bH0+42Kgyjly6SIf9w4J7sZxu23N 0zltQhF/tUIZi7tb9q1asg3YROXn7XXAcBOpZQJgtyyWTpxR02E5P2YVwTUK3e365Zig Qo3DmSbMQS88bZXBlztHq0qW2s5Q+EFUiu3S+xoUSvdM1wp10fD5lLPOrCHD/Htjm+Iw BiPw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gibson.dropbear.id.au header.s=201602 header.b="nM/aErQv"; 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" Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 15si3517784ybf.275.2019.02.18.07.14.25 for (version=TLS1 cipher=AES128-SHA bits=128/128); Mon, 18 Feb 2019 07:14:25 -0800 (PST) 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=neutral (body hash did not verify) header.i=@gibson.dropbear.id.au header.s=201602 header.b="nM/aErQv"; 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" Received: from localhost ([127.0.0.1]:60262 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gvkcj-0007gC-9x for patch@linaro.org; Mon, 18 Feb 2019 10:14:25 -0500 Received: from eggs.gnu.org ([209.51.188.92]:39908) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gvjyY-00078D-69 for qemu-devel@nongnu.org; Mon, 18 Feb 2019 09:32:55 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gvjyW-0003Ys-Hz for qemu-devel@nongnu.org; Mon, 18 Feb 2019 09:32:54 -0500 Received: from ozlabs.org ([2401:3900:2:1::2]:39379) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gvjyW-0003C9-27; Mon, 18 Feb 2019 09:32:52 -0500 Received: by ozlabs.org (Postfix, from userid 1007) id 4435s157Z1z9sRW; Tue, 19 Feb 2019 01:31:16 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gibson.dropbear.id.au; s=201602; t=1550500277; bh=l/uZnwapLXCAmSRW+SLynhpQG35UrcsG7sMrQKApUc8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=nM/aErQvBDHwAsTyQVEZ/ki8hIN4/dayJb0M15H+ZFfyWMMr6Ozg97v72YdHzjQeo Msefz9Q56mypIDsCvLP2BmkFI1txLHEWEO0AbBA3WQDMJXRTIB+TqpuO7hyQoPf8Qz rj1ZBmEv0ECEeexIJCwNH91dqTFG30l4LZxkYddc= From: David Gibson To: peter.maydell@linaro.org Date: Tue, 19 Feb 2019 01:30:38 +1100 Message-Id: <20190218143049.17142-33-david@gibson.dropbear.id.au> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190218143049.17142-1-david@gibson.dropbear.id.au> References: <20190218143049.17142-1-david@gibson.dropbear.id.au> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2401:3900:2:1::2 Subject: [Qemu-devel] [PULL 32/43] target/ppc: convert xxspltib 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: Richard Henderson , groug@kaod.org, qemu-devel@nongnu.org, qemu-ppc@nongnu.org, clg@kaod.org, David Gibson Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Richard Henderson Signed-off-by: Richard Henderson Acked-by: David Gibson Message-Id: <20190215100058.20015-7-mark.cave-ayland@ilande.co.uk> Signed-off-by: David Gibson --- target/ppc/translate/vsx-impl.inc.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) -- 2.20.1 diff --git a/target/ppc/translate/vsx-impl.inc.c b/target/ppc/translate/vsx-impl.inc.c index 2576d81ac5..944fc0608a 100644 --- a/target/ppc/translate/vsx-impl.inc.c +++ b/target/ppc/translate/vsx-impl.inc.c @@ -1397,9 +1397,10 @@ static void gen_xxspltw(DisasContext *ctx) static void gen_xxspltib(DisasContext *ctx) { - unsigned char uim8 = IMM8(ctx->opcode); - TCGv_i64 vsr; - if (xS(ctx->opcode) < 32) { + uint8_t uim8 = IMM8(ctx->opcode); + int rt = xT(ctx->opcode); + + if (rt < 32) { if (unlikely(!ctx->altivec_enabled)) { gen_exception(ctx, POWERPC_EXCP_VPU); return; @@ -1410,11 +1411,7 @@ static void gen_xxspltib(DisasContext *ctx) return; } } - vsr = tcg_temp_new_i64(); - tcg_gen_movi_i64(vsr, pattern(uim8)); - set_cpu_vsrh(xT(ctx->opcode), vsr); - set_cpu_vsrl(xT(ctx->opcode), vsr); - tcg_temp_free_i64(vsr); + tcg_gen_gvec_dup8i(vsr_full_offset(rt), 16, 16, uim8); } static void gen_xxsldwi(DisasContext *ctx)