From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:36238) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RB84H-0004jE-S6 for qemu-devel@nongnu.org; Tue, 04 Oct 2011 12:42:14 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RB84G-0006R3-LN for qemu-devel@nongnu.org; Tue, 04 Oct 2011 12:42:09 -0400 Received: from v220110690675601.yourvserver.net ([78.47.199.172]:59720) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RB84G-0006Qt-DJ for qemu-devel@nongnu.org; Tue, 04 Oct 2011 12:42:08 -0400 Message-ID: <4E8B372B.3020603@weilnetz.de> Date: Tue, 04 Oct 2011 18:41:15 +0200 From: Stefan Weil MIME-Version: 1.0 References: <4E8AF3EB.1010103@de.ibm.com> <4E8AFAA9.3060705@suse.de> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] build errors on s390 tcg List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: Carsten Otte , Alexander Graf , QEMU Developers , Blue Swirl , Christian Borntraeger , rth@twiddle.net Am 04.10.2011 14:44, schrieb Peter Maydell: > On 4 October 2011 13:23, Alexander Graf wrote: >> The problem is that tcg.c defines the functions with int arguments >> for TCG >> register indexes, while s390/tcg-target.c takes TCGReg parameters. >> I'm not >> sure which way is better, but using TCGReg feels more type safe to me. > > You're not consistent, though; for example the s390 > tcg_target_reg_alloc_order > array is declared as int[], not TCGReg[]. > > -- PMM I did not notice that s390 was different when I wrote my patch, but I agree with Alex that TCGReg is more type safe. I also think that using TCGReg documents the meaning of a parameter better than using a simple int. So there are two tasks to be done: - Look for inconsistencies and fix them. - Add and use TCGReg for all other targets, too. Or are there any reasons why we should keep the int type parameters? Regards, Stefan Weil