From patchwork Sat Oct 1 14:09:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 611376 Delivered-To: patch@linaro.org Received: by 2002:a17:522:c983:b0:460:3032:e3c4 with SMTP id kr3csp230308pvb; Sat, 1 Oct 2022 07:44:04 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5/uwwYRBOnSgSgDa3eaq5xJIpcrVEVGJeIjvXS/cLQuiAXdWAlOLrRJS1DDMfr59TMtYmK X-Received: by 2002:a05:620a:4306:b0:6d4:1a11:38ad with SMTP id u6-20020a05620a430600b006d41a1138admr2027194qko.422.1664635444480; Sat, 01 Oct 2022 07:44:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664635444; cv=none; d=google.com; s=arc-20160816; b=bgkEekzK4Pre33h19kigy0o7CIvhPVRAUvD59AVfBwHvF11uOiwzx80BOYUheUupbh +I04+UsoysALTYo5kyDa6Ax5xBcF/6mUf+F0bJMfor1dseI4l5+yiw3+R2GV0VIqLLhD BPLcNTl7iNcSUNkF/PLow5e030MGDs84v0JjerPuWVo7WJWRL4rhH2nXOeEvUDMBrwx8 8XrOYQuNwfzclrp6d53oXvqjkmEOGBGR/ITKTShcYMbcrxueBxt3ZxnRUPYRYAoj6vO8 6PQ8/b2r3mhlddaol3VVHGI3hFWtQpj8t5goOHv81T552dyc+8ZbnhIFykHJRDZ3jBmi gwFA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=8MfuyolaoDT+tZpZqL/C4qLqklcFNW0LgruPwvffFJY=; b=QxUD8qDg2+bEfiHhKppQ/Ag1T3We7BEwkQUCxCA+bM4a4L6dyuhxnlox7ea3N8gk0x 11B1tWX/jBRN8r0lWEjgt5AGsBqXgk/fvV42gX9wlxTQ0D/Ez4+jB7fGoSc22Oj9/PJ+ flJO05hGz85eD86+eZ22acjC1OlXXrZwSBfq3VXbOh/Xi/H6cq0iLZ8K6zqoZJxjuD98 uedpn6GCeNZP6tRYZWhF+mWKHnrb7gsqmDkBUuVyEXLlDknWIXmBJ1Y03LKa6teHrPSe wURorSh26stQJhaxJsSxTgGZX8JpMaSPEiCBkF7CWXFkpGF4L5jROM5VY20m7dt+tMs0 l09Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wurZlAXw; 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"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id jt9-20020a05621427e900b0049909498b94si2429591qvb.218.2022.10.01.07.44.04 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sat, 01 Oct 2022 07:44:04 -0700 (PDT) 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=pass header.i=@linaro.org header.s=google header.b=wurZlAXw; 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"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:59160 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oedim-000489-2A for patch@linaro.org; Sat, 01 Oct 2022 10:44:04 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37514) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oedCU-0003Mi-Do for qemu-devel@nongnu.org; Sat, 01 Oct 2022 10:10:43 -0400 Received: from mail-qt1-x82f.google.com ([2607:f8b0:4864:20::82f]:34558) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oedCS-0004I4-OW for qemu-devel@nongnu.org; Sat, 01 Oct 2022 10:10:42 -0400 Received: by mail-qt1-x82f.google.com with SMTP id e20so4082421qts.1 for ; Sat, 01 Oct 2022 07:10:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=8MfuyolaoDT+tZpZqL/C4qLqklcFNW0LgruPwvffFJY=; b=wurZlAXwCCkX41HgmB72WCLBVwJFA9PjNs0h1VrpDAUvOdtJKDqU8UcPG0ZSp6Blbc c9YszLUv/xrdE5mWR+75uaG6VZWZ6GwqW4maAzcTrsx3326YsVv9UXDBMjnn1dZg50SX tISqwQ/n/uQh4Vxi6jXI3RBzHEykRX6A2f1q6jmTmuTkeDDnKC69ShBakYJOiqNgDwz7 SyN4I5TDIxuUEOmKr7R/9Iely77KhDPuTfhGRTfm3N7L5lgngkF82SldOZyVHS29mTBJ HLN2ea/Hs7FQmFi31muMpHN8aKI6RxH72swcMdTJHrgnfYLvS9vyHQogSj2tdFiYS26N /pyg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=8MfuyolaoDT+tZpZqL/C4qLqklcFNW0LgruPwvffFJY=; b=dByyfxiwve7rrZNp/wMbyBSNs4MO6QjJHFl6h+PUssjTBoh9U4zzYXaoAovBz5EW9E 9tJJ/L2gpf3U7sps4r+ton+KvaRxcko/4XxplS0W4f4iycqoiN2lrkZaS9Y4Y5Z3800U SM3VF6SIoaIAsCHW72ylnYV5frsbqVna8EFUMVVQ3hmIE5LAamKacCBWwT1chlgSw2Us aQY0xtZW/ilMEjq/wHHfJU1FHlx7NF+kvuT0j95zFe9QOB0t3sTAh/tr4Rs4EsWlzRAG dQW+NiBlOb6k2DZK3ompT836ZSc9P2Q3VzhIZ+QJcJVeAg5YMWakBHhdYUJ4E32J1bm4 Mptg== X-Gm-Message-State: ACrzQf2aGwgP/vXC48Kq6hSGB+hfFwLPGQEC9WRC3HFYxepJilzY/FmQ i87fNly6QNODwzz2uqeWPRickPXzII7YJ77I X-Received: by 2002:ac8:5d49:0:b0:35c:f197:e81d with SMTP id g9-20020ac85d49000000b0035cf197e81dmr10676718qtx.125.1664633439724; Sat, 01 Oct 2022 07:10:39 -0700 (PDT) Received: from stoup.. ([2605:ef80:8080:8162:afc7:8362:2616:ac15]) by smtp.gmail.com with ESMTPSA id j16-20020a05620a289000b006b615cd8c13sm6075914qkp.106.2022.10.01.07.10.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 01 Oct 2022 07:10:38 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: pbonzini@redhat.com Subject: [PATCH v3 25/26] target/i386: Inline gen_jmp_im Date: Sat, 1 Oct 2022 07:09:34 -0700 Message-Id: <20221001140935.465607-26-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221001140935.465607-1-richard.henderson@linaro.org> References: <20221001140935.465607-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::82f; envelope-from=richard.henderson@linaro.org; helo=mail-qt1-x82f.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Expand this function at each of its callers. Signed-off-by: Richard Henderson --- target/i386/tcg/translate.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/target/i386/tcg/translate.c b/target/i386/tcg/translate.c index f08fa060c4..689a45256c 100644 --- a/target/i386/tcg/translate.c +++ b/target/i386/tcg/translate.c @@ -517,19 +517,14 @@ static inline void gen_op_st_rm_T0_A0(DisasContext *s, int idx, int d) } } -static void gen_jmp_im(DisasContext *s, target_ulong pc) -{ - tcg_gen_movi_tl(cpu_eip, pc); -} - static void gen_update_eip_cur(DisasContext *s) { - gen_jmp_im(s, s->base.pc_next - s->cs_base); + tcg_gen_movi_tl(cpu_eip, s->base.pc_next - s->cs_base); } static void gen_update_eip_next(DisasContext *s) { - gen_jmp_im(s, s->pc - s->cs_base); + tcg_gen_movi_tl(cpu_eip, s->pc - s->cs_base); } static int cur_insn_len(DisasContext *s) @@ -2767,17 +2762,17 @@ static void gen_jmp_rel(DisasContext *s, MemOp ot, int diff, int tb_num) gen_update_cc_op(s); set_cc_op(s, CC_OP_DYNAMIC); if (!s->jmp_opt) { - gen_jmp_im(s, dest); + tcg_gen_movi_tl(cpu_eip, dest); gen_eob(s); } else if (translator_use_goto_tb(&s->base, dest)) { /* jump to same page: we can use a direct jump */ tcg_gen_goto_tb(tb_num); - gen_jmp_im(s, dest); + tcg_gen_movi_tl(cpu_eip, dest); tcg_gen_exit_tb(s->base.tb, tb_num); s->base.is_jmp = DISAS_NORETURN; } else { /* jump to another page */ - gen_jmp_im(s, dest); + tcg_gen_movi_tl(cpu_eip, dest); gen_jr(s); } }