From patchwork Wed Feb 13 15:54:07 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Palmer Dabbelt X-Patchwork-Id: 1041392 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=209.51.188.17; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=sifive.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=sifive.com header.i=@sifive.com header.b="iyTXZaYZ"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4404Jh52T9z9s2P for ; Thu, 14 Feb 2019 03:11:16 +1100 (AEDT) Received: from localhost ([127.0.0.1]:59313 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gtx7y-0004zk-Le for incoming@patchwork.ozlabs.org; Wed, 13 Feb 2019 11:11:14 -0500 Received: from eggs.gnu.org ([209.51.188.92]:59456) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gtwtB-0001lX-CL for qemu-devel@nongnu.org; Wed, 13 Feb 2019 10:55:58 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gtwt9-0002Yb-Bs for qemu-devel@nongnu.org; Wed, 13 Feb 2019 10:55:57 -0500 Received: from mail-pg1-x534.google.com ([2607:f8b0:4864:20::534]:35254) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gtwt7-0001vV-CB for qemu-devel@nongnu.org; Wed, 13 Feb 2019 10:55:55 -0500 Received: by mail-pg1-x534.google.com with SMTP id s198so1322371pgs.2 for ; Wed, 13 Feb 2019 07:55:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sifive.com; s=google; h=subject:date:message-id:in-reply-to:references:cc:from:to; bh=KKieqmlC5XL3lWxjJnmmG+VwQjQnzvEmZPDTD0IIgJw=; b=iyTXZaYZyh70JzGyDtDeSx1AVF+tsaZqK2Tt8HoeItU9DihzYyL3jdn7bHCvPvE8G6 t+pd2gUl1iLv1jPBJB1hc3iFPR+x2iOqZ+2giMc5chqrcSQBn0ERPxcKTs9Mu7dhkIo/ CBGVbh5a7WXbjZ4HcyoyeFFuM+3QtUwHFwm973DS3GbaZrTODoKGqZTbjEluGCJxbV+1 BLFK6khHdNt+6/GwYgKj1NjhiI8WnuSHtd48ZZzI4EdLEmNgRCJ8vAc+wvkxqN9fQTVf uXES+aFgNhMa/n0+ZeAuVVU2qsVuc1NoF+V8c8xaHL9qNfqfrWH83L6kvvw5XP0Yoix1 wzIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:date:message-id:in-reply-to:references :cc:from:to; bh=KKieqmlC5XL3lWxjJnmmG+VwQjQnzvEmZPDTD0IIgJw=; b=KceNuPvFtoaOTo+15Ueu0fvcDOLXpvBFALIT4s8ocDnarBN84k/vkq9Z6uHEdzCkeE FPrwoe2nU0jNqvdy++6segMMhGnp5pmwetN8aoSHbksgIbmN+P1b1wsNcYqO2h1i+Oth T+UIy4wYdfp1Tr82C1Ahzv9+mGRVJJm7Nm8CYyaSHpXOGMzWE/ur8v2qe7oi5sDEGyct Dz0kaFWz33QEVKsmZpFlXw2zbVRs/Hh9i64FWw0B5LUKxN2AlZYeMGubxRKxNFARsIEo oKal5CvtfMd6dwNMTsY61Xj8JjUaR3QHK5FCDZ87pfbdR9AdBTMYIg5UnAreBpFz/Lh7 QvCQ== X-Gm-Message-State: AHQUAuYFqFPfn25yQazTIpWuyUXyrw05CnMhZ2GhHfV/LJnJ3eU9I/IR 1M+exzze1EzYU18YnwbkvCWb9KgkCBU= X-Google-Smtp-Source: AHgI3IbR0GQGStVUaQAyyzrLPN+2j65naogUgAaKq8XzZ7hQ9whpm2K0S3NvA48hJvzkKxcDh3M0xQ== X-Received: by 2002:a63:6a05:: with SMTP id f5mr1076441pgc.72.1550073321909; Wed, 13 Feb 2019 07:55:21 -0800 (PST) Received: from localhost ([12.206.222.5]) by smtp.gmail.com with ESMTPSA id l2sm23099094pgn.52.2019.02.13.07.55.20 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 13 Feb 2019 07:55:21 -0800 (PST) Date: Wed, 13 Feb 2019 07:54:07 -0800 Message-Id: <20190213155414.22285-29-palmer@sifive.com> X-Mailer: git-send-email 2.18.1 In-Reply-To: <20190213155414.22285-1-palmer@sifive.com> References: <20190213155414.22285-1-palmer@sifive.com> From: Palmer Dabbelt To: qemu-riscv@nongnu.org X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::534 Subject: [Qemu-devel] [PATCH v7 28/35] target/riscv: Rename trans_arith to gen_arith 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: Bastian Koppelmann , qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" From: Bastian Koppelmann Reviewed-by: Richard Henderson Signed-off-by: Bastian Koppelmann --- target/riscv/insn_trans/trans_rvi.inc.c | 18 +++++++++--------- target/riscv/insn_trans/trans_rvm.inc.c | 14 +++++++------- target/riscv/translate.c | 4 ++-- 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/target/riscv/insn_trans/trans_rvi.inc.c b/target/riscv/insn_trans/trans_rvi.inc.c index d94b371b4d00..aed34dc2bb11 100644 --- a/target/riscv/insn_trans/trans_rvi.inc.c +++ b/target/riscv/insn_trans/trans_rvi.inc.c @@ -307,12 +307,12 @@ static bool trans_srai(DisasContext *ctx, arg_srai *a) static bool trans_add(DisasContext *ctx, arg_add *a) { - return trans_arith(ctx, a, &tcg_gen_add_tl); + return gen_arith(ctx, a, &tcg_gen_add_tl); } static bool trans_sub(DisasContext *ctx, arg_sub *a) { - return trans_arith(ctx, a, &tcg_gen_sub_tl); + return gen_arith(ctx, a, &tcg_gen_sub_tl); } static bool trans_sll(DisasContext *ctx, arg_sll *a) @@ -322,17 +322,17 @@ static bool trans_sll(DisasContext *ctx, arg_sll *a) static bool trans_slt(DisasContext *ctx, arg_slt *a) { - return trans_arith(ctx, a, &gen_slt); + return gen_arith(ctx, a, &gen_slt); } static bool trans_sltu(DisasContext *ctx, arg_sltu *a) { - return trans_arith(ctx, a, &gen_sltu); + return gen_arith(ctx, a, &gen_sltu); } static bool trans_xor(DisasContext *ctx, arg_xor *a) { - return trans_arith(ctx, a, &tcg_gen_xor_tl); + return gen_arith(ctx, a, &tcg_gen_xor_tl); } static bool trans_srl(DisasContext *ctx, arg_srl *a) @@ -347,12 +347,12 @@ static bool trans_sra(DisasContext *ctx, arg_sra *a) static bool trans_or(DisasContext *ctx, arg_or *a) { - return trans_arith(ctx, a, &tcg_gen_or_tl); + return gen_arith(ctx, a, &tcg_gen_or_tl); } static bool trans_and(DisasContext *ctx, arg_and *a) { - return trans_arith(ctx, a, &tcg_gen_and_tl); + return gen_arith(ctx, a, &tcg_gen_and_tl); } #ifdef TARGET_RISCV64 @@ -399,12 +399,12 @@ static bool trans_sraiw(DisasContext *ctx, arg_sraiw *a) static bool trans_addw(DisasContext *ctx, arg_addw *a) { - return trans_arith(ctx, a, &gen_addw); + return gen_arith(ctx, a, &gen_addw); } static bool trans_subw(DisasContext *ctx, arg_subw *a) { - return trans_arith(ctx, a, &gen_subw); + return gen_arith(ctx, a, &gen_subw); } static bool trans_sllw(DisasContext *ctx, arg_sllw *a) diff --git a/target/riscv/insn_trans/trans_rvm.inc.c b/target/riscv/insn_trans/trans_rvm.inc.c index 949f59ddb2f9..5844d6f5beff 100644 --- a/target/riscv/insn_trans/trans_rvm.inc.c +++ b/target/riscv/insn_trans/trans_rvm.inc.c @@ -21,7 +21,7 @@ static bool trans_mul(DisasContext *ctx, arg_mul *a) { - return trans_arith(ctx, a, &tcg_gen_mul_tl); + return gen_arith(ctx, a, &tcg_gen_mul_tl); } static bool trans_mulh(DisasContext *ctx, arg_mulh *a) @@ -41,7 +41,7 @@ static bool trans_mulh(DisasContext *ctx, arg_mulh *a) static bool trans_mulhsu(DisasContext *ctx, arg_mulhsu *a) { - return trans_arith(ctx, a, &gen_mulhsu); + return gen_arith(ctx, a, &gen_mulhsu); } static bool trans_mulhu(DisasContext *ctx, arg_mulhu *a) @@ -61,28 +61,28 @@ static bool trans_mulhu(DisasContext *ctx, arg_mulhu *a) static bool trans_div(DisasContext *ctx, arg_div *a) { - return trans_arith(ctx, a, &gen_div); + return gen_arith(ctx, a, &gen_div); } static bool trans_divu(DisasContext *ctx, arg_divu *a) { - return trans_arith(ctx, a, &gen_divu); + return gen_arith(ctx, a, &gen_divu); } static bool trans_rem(DisasContext *ctx, arg_rem *a) { - return trans_arith(ctx, a, &gen_rem); + return gen_arith(ctx, a, &gen_rem); } static bool trans_remu(DisasContext *ctx, arg_remu *a) { - return trans_arith(ctx, a, &gen_remu); + return gen_arith(ctx, a, &gen_remu); } #ifdef TARGET_RISCV64 static bool trans_mulw(DisasContext *ctx, arg_mulw *a) { - return trans_arith(ctx, a, &gen_mulw); + return gen_arith(ctx, a, &gen_mulw); } static bool trans_divw(DisasContext *ctx, arg_divw *a) diff --git a/target/riscv/translate.c b/target/riscv/translate.c index 9ae7aaa7ed00..3d49c8ed4054 100644 --- a/target/riscv/translate.c +++ b/target/riscv/translate.c @@ -624,8 +624,8 @@ static bool gen_arith_div_w(DisasContext *ctx, arg_r *a, #endif -static bool trans_arith(DisasContext *ctx, arg_r *a, - void(*func)(TCGv, TCGv, TCGv)) +static bool gen_arith(DisasContext *ctx, arg_r *a, + void(*func)(TCGv, TCGv, TCGv)) { TCGv source1, source2; source1 = tcg_temp_new();