Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Nag58-0002mZ-FM for qemu-devel@nongnu.org; Thu, 28 Jan 2010 20:55:34 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Nag52-0002ia-8r for qemu-devel@nongnu.org; Thu, 28 Jan 2010 20:55:34 -0500 Received: from [199.232.76.173] (port=36326 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Nag52-0002iX-0s for qemu-devel@nongnu.org; Thu, 28 Jan 2010 20:55:28 -0500 Received: from web15907.mail.cnb.yahoo.com ([202.165.103.52]:23499) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1Nag51-0000Dr-1o for qemu-devel@nongnu.org; Thu, 28 Jan 2010 20:55:27 -0500 Message-ID: <62332.72612.qm@web15907.mail.cnb.yahoo.com> Date: Fri, 29 Jan 2010 09:55:18 +0800 (CST) From: identifier scorpio Subject: Re: [Qemu-devel] [PATCH] Porting TCG to alpha platform In-Reply-To: <4B5E4311.10707@twiddle.net> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="0-65406561-1264730118=:72612" List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Richard Henderson Cc: qemu-devel@nongnu.org --0-65406561-1264730118=:72612 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable I'v reviewed your code and applied the patch to 0.12.0.rc1. After fixing so= me small bugs I run it on my debian/alpha platform, and it hung after runni= ng abort 3 TBs. I'll continue to trace your code. The bugs that are fixed are listed as follow: 1. adding constraints for operation mov_i32/movi_i32/mov_i64/movi_i64 2. replacing "goto do_arith" with "break" for INDEX_op_not_i32/i64 case han= dling in tcg_out_op 3. removing the redundant declaration for "alpha_tb_set_jmp_target()" at ta= il of tcg-target.c, it has been declared in exec-all.h I just find that a suspect bug in tcg_out_brcond() and have not tried yet. if ( opc =3D=3D 0) { =C2=A0=C2=A0=C2=A0 opc =3D cmp_opc[cond]; =C2=A0=C2=A0=C2=A0 if ( const_arg2) {=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0 /* should be if (const_arg2 && arg2 & ~0xff =3D=3D 0) ? =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 tcg_out_fmt_opi(s, opc, ...) ... Your code is more skilled and I learn a lot from it, but I haven't yet reco= gnized the key difference between your version and mine. In last mail, you'= ve said that "Mainly, tcg_target_long was used places that could be holding= HOST values, which means that the host values would have been truncated to= 32 bits.", and I can't fully understand it, may you put it more clearly. BTW, there is no internet access in my daily working environment, so forgiv= e me for not being able to check my mail regularly. Dong Weiyu. =0A=0A=0A ___________________________________________________________ = =0A =E5=A5=BD=E7=8E=A9=E8=B4=BA=E5=8D=A1=E7=AD=89=E4=BD=A0=E5=8F=91=EF=BC= =8C=E9=82=AE=E7=AE=B1=E8=B4=BA=E5=8D=A1=E5=85=A8=E6=96=B0=E4=B8=8A=E7=BA=BF= =EF=BC=81 =0Ahttp://card.mail.cn.yahoo.com/ --0-65406561-1264730118=:72612 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable
I'v reviewed your code and applied the patch = to 0.12.0.rc1. After fixing some small bugs I run it on my debian/alpha pla= tform, and it hung after running abort 3 TBs. I'll continue to trace your c= ode.

The bugs that are fixed are listed as follow:
1. adding cons= traints for operation mov_i32/movi_i32/mov_i64/movi_i64
2. replacing "go= to do_arith" with "break" for INDEX_op_not_i32/i64 case handling in tcg_out= _op
3. removing the redundant declaration for "alpha_tb_set_jmp_target()= " at tail of tcg-target.c, it has been declared in exec-all.h

I just= find that a suspect bug in tcg_out_brcond() and have not tried yet.
if ( opc =3D=3D 0) {
    opc =3D cmp_opc[cond];
 = ;   if ( const_arg2) {       &= nbsp;  /* should be if (const_arg2 && arg2 & ~0xff =3D=3D = 0) ?
        tcg_out_fmt_opi(s, opc, ..= .)
...

Your code is more skilled and I learn a lot from it, but I= haven't yet recognized the key difference between your version and mine. I= n last mail, you've said that "Mainly, tcg_target_long was used places that= could be holding HOST values, which means that the host values would have = been truncated to 32 bits.", and I can't fully understand it, may you put i= t more clearly.

BTW, there is no internet access in my daily working= environment, so forgive me for not being able to check my mail regularly.<= br>
Dong Weiyu.

=0A=0A=0A
=E5=A5=BD=E7=8E=A9=E8=B4=BA=E5=8D=A1=E7=AD=89=E4=BD=A0=E5=8F=91= =EF=BC=8C=E9=82=AE=E7=AE=B1=E8=B4=BA=E5=8D=A1=E5=85=A8=E6=96=B0=E4=B8=8A=E7= =BA=BF=EF=BC=81 --0-65406561-1264730118=:72612--