From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10314 invoked by alias); 28 Jul 2011 15:57:43 -0000 Received: (qmail 10306 invoked by uid 22791); 28 Jul 2011 15:57:42 -0000 X-SWARE-Spam-Status: No, hits=-7.5 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,SPF_HELO_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 28 Jul 2011 15:57:24 +0000 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p6SFvN9Y003303 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 28 Jul 2011 11:57:23 -0400 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id p6SFvMbL000942; Thu, 28 Jul 2011 11:57:23 -0400 Received: from barimba (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id p6SFvLan008337; Thu, 28 Jul 2011 11:57:21 -0400 From: Tom Tromey To: Sanjoy Das Cc: gdb-patches@sourceware.org Subject: Re: [PATCH 1/4] Adds a new header file, jit-reader.h.in. References: <1311523427-20501-1-git-send-email-sanjoy@playingwithpointers.com> <1311523427-20501-2-git-send-email-sanjoy@playingwithpointers.com> Date: Thu, 28 Jul 2011 16:39:00 -0000 In-Reply-To: <1311523427-20501-2-git-send-email-sanjoy@playingwithpointers.com> (Sanjoy Das's message of "Sun, 24 Jul 2011 21:33:44 +0530") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2011-07/txt/msg00790.txt.bz2 >>>>> "Sanjoy" == Sanjoy Das writes: Sanjoy> jit-reader.h.in will host the interface to be implemented and Sanjoy> the API to be used by the reader. The file needs to be processed Sanjoy> by ./configure to get the correct typedef for GDB_CORE_ADDR. Sanjoy> +AC_CHECK_SIZEOF(unsigned long long) Sanjoy> +AC_CHECK_SIZEOF(unsigned long) Sanjoy> +AC_CHECK_SIZEOF(unsigned __int128) Sanjoy> + Sanjoy> +if test "x${ac_cv_sizeof_unsigned_long}" = "x8"; then Sanjoy> + HOST_U_64_BIT="unsigned long" Sanjoy> +elif test "x${ac_cv_sizeof_unsigned_long_long}" = "x8"; then Sanjoy> + HOST_U_64_BIT="unsigned long long" Sanjoy> +elif test "x${ac_cv_sizeof_unsigned___int128}" = "x16"; then Sanjoy> + HOST_U_64_BIT="unsigned __int128" Sanjoy> +else Sanjoy> + AC_MSG_ERROR([could not find a 64 bit integer type]) It should not be a fatal error if a 64-bit type cannot be found. It is possible to build GDB on a 32-bit host that does not have a 64-bit type. Nothing prevents this; you just won't be able to debug 64-bit processes. Sanjoy> +# The default path from which to load readers Sanjoy> +GDB_JIT_READER_PATH="${prefix}/lib/gdb" It is more normal to use libdir here, but then you get into problems with how configure represents these variables. There may be some helpful macros in config/, not sure. Sanjoy> + extern int __gdb_reader_interface_version (void) \ No need for the leading "__". Tom