From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47327) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W0dmL-0002zp-KX for qemu-devel@nongnu.org; Tue, 07 Jan 2014 16:01:42 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1W0dmG-0003Oj-UC for qemu-devel@nongnu.org; Tue, 07 Jan 2014 16:01:37 -0500 Received: from mail-qc0-x235.google.com ([2607:f8b0:400d:c01::235]:62368) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W0dmG-0003N0-LC for qemu-devel@nongnu.org; Tue, 07 Jan 2014 16:01:32 -0500 Received: by mail-qc0-f181.google.com with SMTP id e9so551883qcy.12 for ; Tue, 07 Jan 2014 13:01:31 -0800 (PST) Sender: Richard Henderson From: Richard Henderson Date: Tue, 7 Jan 2014 12:59:59 -0800 Message-Id: <1389128439-10067-10-git-send-email-rth@twiddle.net> In-Reply-To: <1389128439-10067-1-git-send-email-rth@twiddle.net> References: <1389128439-10067-1-git-send-email-rth@twiddle.net> Subject: [Qemu-devel] [PULL 09/49] target-i386: Remove gen_op_ld_T1_A0 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: aliguori@amazon.com Propagate its definition into all users. Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target-i386/translate.c | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) diff --git a/target-i386/translate.c b/target-i386/translate.c index 97bbc1f..b747e99 100644 --- a/target-i386/translate.c +++ b/target-i386/translate.c @@ -586,11 +586,6 @@ static inline void gen_op_ld_v(DisasContext *s, int idx, TCGv t0, TCGv a0) tcg_gen_qemu_ld_tl(t0, a0, s->mem_index, idx | MO_LE); } -static inline void gen_op_ld_T1_A0(DisasContext *s, int idx) -{ - gen_op_ld_v(s, idx, cpu_T[1], cpu_A0); -} - static inline void gen_op_st_v(DisasContext *s, int idx, TCGv t0, TCGv a0) { tcg_gen_qemu_st_tl(t0, a0, s->mem_index, idx | MO_LE); @@ -1244,7 +1239,7 @@ static inline void gen_lods(DisasContext *s, int ot) static inline void gen_scas(DisasContext *s, int ot) { gen_string_movl_A0_EDI(s); - gen_op_ld_T1_A0(s, ot); + gen_op_ld_v(s, ot, cpu_T[1], cpu_A0); gen_op(s, OP_CMPL, ot, R_EAX); gen_op_movl_T0_Dshift(ot); gen_op_add_reg_T0(s->aflag, R_EDI); @@ -1253,7 +1248,7 @@ static inline void gen_scas(DisasContext *s, int ot) static inline void gen_cmps(DisasContext *s, int ot) { gen_string_movl_A0_EDI(s); - gen_op_ld_T1_A0(s, ot); + gen_op_ld_v(s, ot, cpu_T[1], cpu_A0); gen_string_movl_A0_ESI(s); gen_op(s, OP_CMPL, ot, OR_TMP0); gen_op_movl_T0_Dshift(ot); @@ -4835,7 +4830,7 @@ static target_ulong disas_insn(CPUX86State *env, DisasContext *s, rm = (modrm & 7) | REX_B(s); if (mod != 3) { gen_lea_modrm(env, s, modrm, ®_addr, &offset_addr); - gen_op_ld_T1_A0(s, ot); + gen_op_ld_v(s, ot, cpu_T[1], cpu_A0); } else if (op == OP_XORL && rm == reg) { goto xor_zero; } else { @@ -5166,7 +5161,7 @@ static target_ulong disas_insn(CPUX86State *env, DisasContext *s, gen_eob(s); break; case 3: /* lcall Ev */ - gen_op_ld_T1_A0(s, ot); + gen_op_ld_v(s, ot, cpu_T[1], cpu_A0); gen_add_A0_im(s, 1 << (ot - MO_16 + 1)); gen_op_ld_v(s, MO_16, cpu_T[0], cpu_A0); do_lcall: @@ -5192,7 +5187,7 @@ static target_ulong disas_insn(CPUX86State *env, DisasContext *s, gen_eob(s); break; case 5: /* ljmp Ev */ - gen_op_ld_T1_A0(s, ot); + gen_op_ld_v(s, ot, cpu_T[1], cpu_A0); gen_add_A0_im(s, 1 << (ot - MO_16 + 1)); gen_op_ld_v(s, MO_16, cpu_T[0], cpu_A0); do_ljmp: @@ -5357,7 +5352,7 @@ static target_ulong disas_insn(CPUX86State *env, DisasContext *s, } else { gen_lea_modrm(env, s, modrm, ®_addr, &offset_addr); gen_op_mov_TN_reg(ot, 0, reg); - gen_op_ld_T1_A0(s, ot); + gen_op_ld_v(s, ot, cpu_T[1], cpu_A0); gen_op_addl_T0_T1(); gen_op_st_T0_A0(s, ot); gen_op_mov_reg_T1(ot, reg); @@ -5843,7 +5838,7 @@ static target_ulong disas_insn(CPUX86State *env, DisasContext *s, /* for xchg, lock is implicit */ if (!(prefixes & PREFIX_LOCK)) gen_helper_lock(); - gen_op_ld_T1_A0(s, ot); + gen_op_ld_v(s, ot, cpu_T[1], cpu_A0); gen_op_st_T0_A0(s, ot); if (!(prefixes & PREFIX_LOCK)) gen_helper_unlock(); @@ -5874,7 +5869,7 @@ static target_ulong disas_insn(CPUX86State *env, DisasContext *s, if (mod == 3) goto illegal_op; gen_lea_modrm(env, s, modrm, ®_addr, &offset_addr); - gen_op_ld_T1_A0(s, ot); + gen_op_ld_v(s, ot, cpu_T[1], cpu_A0); gen_add_A0_im(s, 1 << (ot - MO_16 + 1)); /* load the segment first to handle exceptions properly */ gen_op_ld_v(s, MO_16, cpu_T[0], cpu_A0); @@ -7680,7 +7675,7 @@ static target_ulong disas_insn(CPUX86State *env, DisasContext *s, gen_svm_check_intercept(s, pc_start, op==2 ? SVM_EXIT_GDTR_WRITE : SVM_EXIT_IDTR_WRITE); gen_lea_modrm(env, s, modrm, ®_addr, &offset_addr); - gen_op_ld_T1_A0(s, MO_16); + gen_op_ld_v(s, MO_16, cpu_T[1], cpu_A0); gen_add_A0_im(s, 2); gen_op_ld_v(s, CODE64(s) + MO_32, cpu_T[0], cpu_A0); if (!s->dflag) -- 1.8.4.2