From patchwork Fri Jul 23 15:17:00 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jun Koi X-Patchwork-Id: 59809 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 0C967B713E for ; Sat, 24 Jul 2010 01:21:15 +1000 (EST) Received: from localhost ([127.0.0.1]:49803 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OcK1w-0002g7-2h for incoming@patchwork.ozlabs.org; Fri, 23 Jul 2010 11:19:20 -0400 Received: from [140.186.70.92] (port=46700 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OcK0Y-0002D9-2c for qemu-devel@nongnu.org; Fri, 23 Jul 2010 11:17:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OcK01-0005AS-Bt for qemu-devel@nongnu.org; Fri, 23 Jul 2010 11:17:22 -0400 Received: from mail-iw0-f173.google.com ([209.85.214.173]:39448) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OcK01-0005AL-7H for qemu-devel@nongnu.org; Fri, 23 Jul 2010 11:17:21 -0400 Received: by iwn6 with SMTP id 6so304134iwn.4 for ; Fri, 23 Jul 2010 08:17:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:received:from:date :message-id:subject:to:content-type; bh=mFFdFL/HTOcPulFUgDn82MwotqRKyTFQShmtRqev4iU=; b=gNXPtOt2Lr9uspDpfxTxBndzb27a+gOvEyhgMx4AFLYUjp6Nc3YXeS5PVsR5+7mHdy i8rRj23E/IcVbvxU1de9gOyBF9zhOQ3wwepVyRyuCVl1R7BiDHNSA3C0Ew3nyUcARSBx 8IOXlcZPAHGHUi0Rm8YWFiDdg1Py5045w//9I= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:from:date:message-id:subject:to:content-type; b=RLpP+GZGlXMZTtC+HeA7MSPXcSil83XAsMcGJhlni/7STA3mL/hwdY/RMLnhJLiuZ0 kIo866+FIhiKsccQGjEKy9ZrqMLPsnrDpVV1v38Fj5KQhJA+2PDSZka0qU1IPNFZ4ajG ROHcahIPPlE1mz5pjdrB9e3Ci6RuOMAB3XS28= Received: by 10.231.13.199 with SMTP id d7mr3842379iba.167.1279898240367; Fri, 23 Jul 2010 08:17:20 -0700 (PDT) MIME-Version: 1.0 Received: by 10.231.148.131 with HTTP; Fri, 23 Jul 2010 08:17:00 -0700 (PDT) From: Jun Koi Date: Sat, 24 Jul 2010 00:17:00 +0900 Message-ID: To: qemu-devel@nongnu.org X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) Subject: [Qemu-devel] [patch] use symbol for DisasContext->is_jmp X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org This patch replaces constant value assigned for (DisasContext *)->is_jmp with DISAS_TB_JUMP. Signed-off-by: Jun Koi diff --git a/target-i386/translate.c b/target-i386/translate.c index 2fcc026..9543298 100644 --- a/target-i386/translate.c +++ b/target-i386/translate.c @@ -2322,7 +2322,7 @@ static inline void gen_jcc(DisasContext *s, int b, gen_set_label(l1); gen_goto_tb(s, 1, val); - s->is_jmp = 3; + s->is_jmp = DISAS_TB_JUMP; } else { l1 = gen_new_label(); @@ -2400,11 +2400,11 @@ static void gen_movl_seg_T0(DisasContext *s, int seg_reg, target_ulong cur_eip) stop as a special handling must be done to disable hardware interrupts for the next instruction */ if (seg_reg == R_SS || (s->code32 && seg_reg < R_FS)) - s->is_jmp = 3; + s->is_jmp = DISAS_TB_JUMP; } else { gen_op_movl_seg_T0_vm(seg_reg); if (seg_reg == R_SS) - s->is_jmp = 3; + s->is_jmp = DISAS_TB_JUMP; } } @@ -2672,7 +2672,7 @@ static void gen_exception(DisasContext *s, int trapno, target_ulong cur_eip) gen_op_set_cc_op(s->cc_op); gen_jmp_im(cur_eip); gen_helper_raise_exception(tcg_const_i32(trapno)); - s->is_jmp = 3; + s->is_jmp = DISAS_TB_JUMP; } /* an interrupt is different from an exception because of the @@ -2685,7 +2685,7 @@ static void gen_interrupt(DisasContext *s, int intno, gen_jmp_im(cur_eip); gen_helper_raise_interrupt(tcg_const_i32(intno), tcg_const_i32(next_eip - cur_eip)); - s->is_jmp = 3; + s->is_jmp = DISAS_TB_JUMP; } static void gen_debug(DisasContext *s, target_ulong cur_eip) @@ -2694,7 +2694,7 @@ static void gen_debug(DisasContext *s, target_ulong cur_eip) gen_op_set_cc_op(s->cc_op); gen_jmp_im(cur_eip); gen_helper_debug(); - s->is_jmp = 3; + s->is_jmp = DISAS_TB_JUMP; } /* generate a generic end of block. Trace exception is also generated @@ -2716,7 +2716,7 @@ static void gen_eob(DisasContext *s) } else { tcg_gen_exit_tb(0); } - s->is_jmp = 3; + s->is_jmp = DISAS_TB_JUMP; } /* generate a jump to eip. No segment change must happen before as a @@ -2729,7 +2729,7 @@ static void gen_jmp_tb(DisasContext *s, target_ulong eip, int tb_num) s->cc_op = CC_OP_DYNAMIC; } gen_goto_tb(s, tb_num, eip); - s->is_jmp = 3; + s->is_jmp = DISAS_TB_JUMP; } else { gen_jmp_im(eip); gen_eob(s); @@ -6968,7 +6968,7 @@ static target_ulong disas_insn(DisasContext *s, target_ulong pc_start) gen_op_set_cc_op(s->cc_op); gen_jmp_im(pc_start - s->cs_base); gen_helper_hlt(tcg_const_i32(s->pc - pc_start)); - s->is_jmp = 3; + s->is_jmp = DISAS_TB_JUMP; } break; case 0x100: @@ -7125,7 +7125,7 @@ static target_ulong disas_insn(DisasContext *s, target_ulong pc_start) gen_helper_vmrun(tcg_const_i32(s->aflag), tcg_const_i32(s->pc - pc_start)); tcg_gen_exit_tb(0); - s->is_jmp = 3; + s->is_jmp = DISAS_TB_JUMP; } break; case 1: /* VMMCALL */