From patchwork Thu Apr 17 19:32:54 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 340031 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id B97D214008F for ; Fri, 18 Apr 2014 05:43:46 +1000 (EST) Received: from localhost ([::1]:34704 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WasDo-0005j6-9o for incoming@patchwork.ozlabs.org; Thu, 17 Apr 2014 15:43:44 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55906) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Was4m-0001Qc-Lp for qemu-devel@nongnu.org; Thu, 17 Apr 2014 15:34:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Was4g-0002Nq-My for qemu-devel@nongnu.org; Thu, 17 Apr 2014 15:34:24 -0400 Received: from mail-qc0-x234.google.com ([2607:f8b0:400d:c01::234]:41700) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Was4g-0002Nj-IC for qemu-devel@nongnu.org; Thu, 17 Apr 2014 15:34:18 -0400 Received: by mail-qc0-f180.google.com with SMTP id w7so895513qcr.39 for ; Thu, 17 Apr 2014 12:34:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:subject:date:message-id:in-reply-to:references; bh=DpHZgWCIL80PKY3t7SMrtmgHxxrT2duL1Ac+7XF/f00=; b=g/T7uiZ+b2larEeMcSAIcRDoVoeuZnI7+x+oa2aF1UWTVtiBpR1jrW2ZcyWpLo7WTp C69AwVDwyZr222x9Jpf2UEi+JchNCLp3HOiggWgQbIN1pDs4qM3A7XF7YPMNn4Vox8pK JB/8fyGJAR/mqjbG/x7UOlHeOSYAivy9l0PIUTCvBfRVvOp9ifY66wpp3XdodywBWvJM hNh5brxGffgNkngRWY85ecosmRLydK58W3Q3H6T6klYorIlrKEu+QztG1DxmZTMv0BUx YXoZ6GBoSAU45dli6pe9ZOq5xQLigFBSYzpGiZPl2fpsEuW2/ro8u+R89wM+WshnRUS7 sl+A== X-Received: by 10.140.51.161 with SMTP id u30mr13195534qga.69.1397763258156; Thu, 17 Apr 2014 12:34:18 -0700 (PDT) Received: from anchor.com (50-194-63-110-static.hfc.comcastbusiness.net. [50.194.63.110]) by mx.google.com with ESMTPSA id b62sm2694452qge.2.2014.04.17.12.34.16 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 17 Apr 2014 12:34:17 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Date: Thu, 17 Apr 2014 12:32:54 -0700 Message-Id: <1397763195-1485-20-git-send-email-rth@twiddle.net> X-Mailer: git-send-email 1.9.0 In-Reply-To: <1397763195-1485-1-git-send-email-rth@twiddle.net> References: <1397763195-1485-1-git-send-email-rth@twiddle.net> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:400d:c01::234 Subject: [Qemu-devel] [PATCH 19/40] target-alpha: Convert ARITH3_EX to source/sink X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Signed-off-by: Richard Henderson --- target-alpha/translate.c | 49 ++++++------------------------------------------ 1 file changed, 6 insertions(+), 43 deletions(-) diff --git a/target-alpha/translate.c b/target-alpha/translate.c index 026372d..0fbb1f2 100644 --- a/target-alpha/translate.c +++ b/target-alpha/translate.c @@ -1457,43 +1457,6 @@ ARITH3(maxuw4) ARITH3(maxsw4) ARITH3(perr) -/* Code to call arith3 helpers */ -#define ARITH3_EX(name) \ - static inline void glue(gen_, name)(int ra, int rb, int rc, \ - int islit, uint8_t lit) \ - { \ - if (unlikely(rc == 31)) { \ - return; \ - } \ - if (ra != 31) { \ - if (islit) { \ - TCGv tmp = tcg_const_i64(lit); \ - gen_helper_ ## name(cpu_ir[rc], cpu_env, \ - cpu_ir[ra], tmp); \ - tcg_temp_free(tmp); \ - } else { \ - gen_helper_ ## name(cpu_ir[rc], cpu_env, \ - cpu_ir[ra], cpu_ir[rb]); \ - } \ - } else { \ - TCGv tmp1 = tcg_const_i64(0); \ - if (islit) { \ - TCGv tmp2 = tcg_const_i64(lit); \ - gen_helper_ ## name(cpu_ir[rc], cpu_env, tmp1, tmp2); \ - tcg_temp_free(tmp2); \ - } else { \ - gen_helper_ ## name(cpu_ir[rc], cpu_env, tmp1, cpu_ir[rb]); \ - } \ - tcg_temp_free(tmp1); \ - } \ - } -ARITH3_EX(addlv) -ARITH3_EX(sublv) -ARITH3_EX(addqv) -ARITH3_EX(subqv) -ARITH3_EX(mullv) -ARITH3_EX(mulqv) - #define MVIOP2(name) \ static inline void glue(gen_, name)(int rb, int rc) \ { \ @@ -2032,11 +1995,11 @@ static ExitStatus translate_one(DisasContext *ctx, uint32_t insn) break; case 0x40: /* ADDL/V */ - gen_addlv(ra, rb, rc, islit, lit); + gen_helper_addlv(vc, cpu_env, va, vb); break; case 0x49: /* SUBL/V */ - gen_sublv(ra, rb, rc, islit, lit); + gen_helper_sublv(vc, cpu_env, va, vb); break; case 0x4D: /* CMPLT */ @@ -2044,11 +2007,11 @@ static ExitStatus translate_one(DisasContext *ctx, uint32_t insn) break; case 0x60: /* ADDQ/V */ - gen_addqv(ra, rb, rc, islit, lit); + gen_helper_addqv(vc, cpu_env, va, vb); break; case 0x69: /* SUBQ/V */ - gen_subqv(ra, rb, rc, islit, lit); + gen_helper_subqv(vc, cpu_env, va, vb); break; case 0x6D: /* CMPLE */ @@ -2321,11 +2284,11 @@ static ExitStatus translate_one(DisasContext *ctx, uint32_t insn) break; case 0x40: /* MULL/V */ - gen_mullv(ra, rb, rc, islit, lit); + gen_helper_mullv(vc, cpu_env, va, vb); break; case 0x60: /* MULQ/V */ - gen_mulqv(ra, rb, rc, islit, lit); + gen_helper_mulqv(vc, cpu_env, va, vb); break; default: goto invalid_opc;