From nobody Mon Feb 9 15:11:00 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1555588219; cv=none; d=zoho.com; s=zohoarc; b=KtTyt/SvpWzKmNYeE8sVE1TidIdBiIHa0a+2Tt547yZPo24KVSl88EpQZf98IlC505iOag36vO56ivW9W1/DNc9PdTDHADisFSXWbmuHF+0WeUOiqapsYGJkDaeKOWpfDZ7Z76qkTZVT2zf5Wz4BPDo4qDWmXezR8hZ6Zn4ajFc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555588219; h=Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=gTXI7zwDFlTNHwaOwRPszY/SxxN5mGIwUfVzeuG5iYs=; b=UcKfNIOIPxb80JN9RkBqj1+y4b3Hg2Pv4XPn9OuwSTUL5hhUD9qnq/m3Ugon/U0Zg8KAIztmWEeKURNkWlN3hwIMaLZQ+E4aYzGlUqFNe513CO60odYVz6N/tsigsgU50YuYOXI3LL4Man0hatlqApvka0S3iHPULOmDhjEdw/k= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 155558821990768.3533686377449; Thu, 18 Apr 2019 04:50:19 -0700 (PDT) Received: from localhost ([127.0.0.1]:40067 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5YU-0007cS-0u for importer@patchew.org; Thu, 18 Apr 2019 07:50:14 -0400 Received: from eggs.gnu.org ([209.51.188.92]:53587) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5Sg-0003DM-8E for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:44:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5Se-0006ap-Bv for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:44:14 -0400 Received: from mx2.rt-rk.com ([89.216.37.149]:50796 helo=mail.rt-rk.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5Sa-0006NR-KU for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:44:10 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.rt-rk.com (Postfix) with ESMTP id 1BB601A20D0; Thu, 18 Apr 2019 13:42:53 +0200 (CEST) Received: from rtrkw310-lin.domain.local (rtrkw310-lin.domain.local [10.10.13.97]) by mail.rt-rk.com (Postfix) with ESMTPSA id D98E91A2460; Thu, 18 Apr 2019 13:42:52 +0200 (CEST) X-Virus-Scanned: amavisd-new at rt-rk.com From: Mateja Marjanovic To: qemu-devel@nongnu.org Date: Thu, 18 Apr 2019 13:42:45 +0200 Message-Id: <1555587766-985-6-git-send-email-mateja.marjanovic@rt-rk.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1555587766-985-1-git-send-email-mateja.marjanovic@rt-rk.com> References: <1555587766-985-1-git-send-email-mateja.marjanovic@rt-rk.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 89.216.37.149 Subject: [Qemu-devel] [PATCH v8 5/6] target/mips: Merge implementation of ILVEV.D and ILVR.D 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: arikalo@wavecomp.com, richard.henderson@linaro.org, philmd@redhat.com, amarkovic@wavecomp.com, aurelien@aurel32.net Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" From: Mateja Marjanovic The implementation for ILVEV.D and ILVR.D instructions is equivalent, so use a single handler for both of them. Suggested-by: Aleksandar Markovic Signed-off-by: Mateja Marjanovic --- target/mips/translate.c | 30 +++++++++++------------------- 1 file changed, 11 insertions(+), 19 deletions(-) diff --git a/target/mips/translate.c b/target/mips/translate.c index d4bbfc3..c6aa995 100644 --- a/target/mips/translate.c +++ b/target/mips/translate.c @@ -28078,20 +28078,6 @@ static inline void gen_ilvr_w(CPUMIPSState *env, u= int32_t wd, } =20 /* - * [MSA] ILVR.D wd, ws, wt - * - * Vector Interleave Right (doubleword data elements) - * - */ -static inline void gen_ilvr_d(CPUMIPSState *env, uint32_t wd, - uint32_t ws, uint32_t wt) -{ - tcg_gen_mov_i64(msa_wr_d[wd * 2 + 1], msa_wr_d[ws * 2]); - tcg_gen_mov_i64(msa_wr_d[wd * 2], msa_wr_d[wt * 2]); -} - - -/* * [MSA] ILVL.H wd, ws, wt * * Vector Interleave Left (halfword data elements) @@ -28314,11 +28300,17 @@ static inline void gen_ilvev_w(CPUMIPSState *env,= uint32_t wd, /* * [MSA] ILVEV.D wd, ws, wt * - * Vector Interleave Even (Doubleword data elements) + * Vector Interleave Even (doubleword data elements) + * + * [MSA] ILVR.D wd, ws, wt + * + * Vector Interleave Right (doubleword data elements) + * + * These two instructions are functionally equivalent. * */ -static inline void gen_ilvev_d(CPUMIPSState *env, uint32_t wd, - uint32_t ws, uint32_t wt) +static inline void gen_ilvev_ilvr_d(CPUMIPSState *env, uint32_t wd, + uint32_t ws, uint32_t wt) { tcg_gen_mov_i64(msa_wr_d[wd * 2 + 1], msa_wr_d[ws * 2]); tcg_gen_mov_i64(msa_wr_d[wd * 2], msa_wr_d[wt * 2]); @@ -28491,7 +28483,7 @@ static void gen_msa_3r(CPUMIPSState *env, DisasCont= ext *ctx) gen_ilvr_w(env, wd, ws, wt); break; case DF_DOUBLE: - gen_ilvr_d(env, wd, ws, wt); + gen_ilvev_ilvr_d(env, wd, ws, wt); break; default: assert(0); @@ -28521,7 +28513,7 @@ static void gen_msa_3r(CPUMIPSState *env, DisasCont= ext *ctx) gen_ilvev_w(env, wd, ws, wt); break; case DF_DOUBLE: - gen_ilvev_d(env, wd, ws, wt); + gen_ilvev_ilvr_d(env, wd, ws, wt); break; default: assert(0); --=20 2.7.4