From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36133) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VCYEV-0003xL-MR for qemu-devel@nongnu.org; Thu, 22 Aug 2013 12:59:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VCYEO-0005gY-JZ for qemu-devel@nongnu.org; Thu, 22 Aug 2013 12:59:39 -0400 Received: from mail-qe0-x236.google.com ([2607:f8b0:400d:c02::236]:36359) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VCYEO-0005gO-FQ for qemu-devel@nongnu.org; Thu, 22 Aug 2013 12:59:32 -0400 Received: by mail-qe0-f54.google.com with SMTP id i11so1267095qej.27 for ; Thu, 22 Aug 2013 09:59:32 -0700 (PDT) Sender: Richard Henderson From: Richard Henderson Date: Thu, 22 Aug 2013 09:58:36 -0700 Message-Id: <1377190729-14008-6-git-send-email-rth@twiddle.net> In-Reply-To: <1377190729-14008-1-git-send-email-rth@twiddle.net> References: <1377190729-14008-1-git-send-email-rth@twiddle.net> Subject: [Qemu-devel] [PATCH 05/18] tcg: Define TCG_TYPE_PTR properly List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: aurelien@aurel32.net Signed-off-by: Richard Henderson --- tcg/tcg.h | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tcg/tcg.h b/tcg/tcg.h index bfe420a..b71dcf4 100644 --- a/tcg/tcg.h +++ b/tcg/tcg.h @@ -173,9 +173,12 @@ typedef enum TCGType { TCG_TYPE_REG = TCG_TYPE_I64, #endif - /* An alias for the size of the native pointer. We don't currently - support any hosts with 64-bit registers and 32-bit pointers. */ - TCG_TYPE_PTR = TCG_TYPE_REG, + /* An alias for the size of the native pointer. */ +#if UINTPTR_MAX == UINT32_MAX + TCG_TYPE_PTR = TCG_TYPE_I32, +#else + TCG_TYPE_PTR = TCG_TYPE_I64, +#endif /* An alias for the size of the target "long", aka register. */ #if TARGET_LONG_BITS == 64 -- 1.8.1.4