Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10.13) id 19AGt0-0004Tj-00 for qemu-devel@nongnu.org; Mon, 28 Apr 2003 18:14:10 -0400 Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) id 19AGet-00010c-00 for qemu-devel@nongnu.org; Mon, 28 Apr 2003 17:59:36 -0400 Received: from mx02.uni-tuebingen.de ([134.2.3.12]) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 19AGep-0000yi-00 for qemu-devel@nongnu.org; Mon, 28 Apr 2003 17:59:31 -0400 Received: from juist (semeai.Informatik.Uni-Tuebingen.De [134.2.15.66]) by mx02.uni-tuebingen.de (8.12.3/8.12.3) with ESMTP id h3SLxSpi015582 for ; Mon, 28 Apr 2003 23:59:29 +0200 Received: from falk by juist with local (Exim 3.36 #1 (Debian)) id 19AGek-0000MH-00 for ; Mon, 28 Apr 2003 23:59:26 +0200 Subject: Re: [Qemu-devel] Alpha support References: <87fzo35yov.fsf@student.uni-tuebingen.de> <87adeb5xwd.fsf@student.uni-tuebingen.de> <87znmail7k.fsf@student.uni-tuebingen.de> From: Falk Hueffner Date: 28 Apr 2003 23:59:26 +0200 In-Reply-To: <87znmail7k.fsf@student.uni-tuebingen.de> Message-ID: <87d6j6i8qp.fsf@student.uni-tuebingen.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii List-Id: List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , To: qemu-devel@nongnu.org Hi, it's me again :) The easiest I could think of is to declare for example void OPPROTO op_jb_cc(void) { if (cc_table[CC_OP].compute_c()) EIP = PARAM1; else EIP = PARAM2; FORCE_RET(); } as void OPPROTO op_jb_cc(PARAMS2) { if (cc_table[CC_OP].compute_c()) EIP = PARAM1; else EIP = PARAM2; FORCE_RET(); } and #ifdef __alpha__ #define PARAMS2 int a0, int a1 #define PARAM1 a0 #define PARAM2 a1 #else #define PARAMS2 void #endif and emit C code to dyngen_code that will manually emit instructions to set up a0 and a1. Added bonus is that a jump gets converted to a conditional move :) Does that sound like a good idea? -- Falk