From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21733 invoked by alias); 25 Jul 2008 18:22:36 -0000 Received: (qmail 21723 invoked by uid 22791); 25 Jul 2008 18:22:36 -0000 X-Spam-Check-By: sourceware.org Received: from elasmtp-curtail.atl.sa.earthlink.net (HELO elasmtp-curtail.atl.sa.earthlink.net) (209.86.89.64) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 25 Jul 2008 18:22:16 +0000 Received: from [68.108.140.98] (helo=macbook-2.local) by elasmtp-curtail.atl.sa.earthlink.net with esmtpa (Exim 4.67) (envelope-from ) id 1KMRvi-0005WW-HE; Fri, 25 Jul 2008 14:22:14 -0400 Message-ID: <488A19D3.40706@earthlink.net> Date: Fri, 25 Jul 2008 18:32:00 -0000 From: Stan Shebs User-Agent: Thunderbird 2.0.0.16 (Macintosh/20080707) MIME-Version: 1.0 To: Michael Snyder , gdb@sourceware.org Subject: Re: Address spaces References: <4887C7BD.80601@earthlink.net> <4887CCF2.6020503@codesourcery.com> <1216956513.3549.536.camel@localhost.localdomain> In-Reply-To: <1216956513.3549.536.camel@localhost.localdomain> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-ELNK-Trace: ae6f8838ff913eba0cc1426638a40ef67e972de0d01da94021d37d4f37a632755c11386952e10f02350badd9bab72f9c350badd9bab72f9c350badd9bab72f9c X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2008-07/txt/msg00271.txt.bz2 Michael Snyder wrote: > Anyway, the idea of making CORE_ADDR a struct has been > around for a long time. We've done our best to avoid it, > but sort of always known it would come back one day. > Where my prototyping is evolving is to have a new type of object that is the struct, tentatively called "target address", consisting of address space + CORE_ADDR. From poking through all the references to CORE_ADDR, it looks to me like 90%+ have an implicit single address space, so structifying seems like an unnecessary nuisance. For instance, when you're doing prologue analysis you're only going to be working in the one address space (at least for non-Harvard). So I'm thinking higher levels will pass around target addresses in a mostly-opaque way, then when one gets down to working on a specific program / address space, the CORE_ADDRs are extracted and used much as they are now. While not as abstractly elegant as making all addresses into objects right off, it doesn't preclude us from going in that direction; someone who wants to make a subsystem use target addresses instead of CORE_ADDRs throughout could do so. Stan