From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23487 invoked by alias); 4 Feb 2002 07:09:19 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 23383 invoked from network); 4 Feb 2002 07:09:16 -0000 Received: from unknown (HELO cygnus.com) (205.180.230.5) by sources.redhat.com with SMTP; 4 Feb 2002 07:09:16 -0000 Received: from cse.cygnus.com (cse.sfbay.redhat.com [205.180.230.236]) by runyon.cygnus.com (8.8.7-cygnus/8.8.7) with ESMTP id KAA02857; Sun, 3 Feb 2002 10:01:52 -0800 (PST) Received: (from kev@localhost) by cse.cygnus.com (8.11.6/8.11.6) id g13I1Er12780; Sun, 3 Feb 2002 11:01:14 -0700 Date: Sun, 03 Feb 2002 23:09:00 -0000 From: Kevin Buettner Message-Id: <1020203180114.ZM12779@localhost.localdomain> In-Reply-To: Jim Blandy "RFA: Do solib address arithmetic with appropriate truncation" (Feb 2, 8:31pm) References: <20020203013131.C26295E9DE@zwingli.cygnus.com> X-Mailer: Z-Mail (4.0.1 13Jan97 Caldera) To: Jim Blandy , gdb-patches@sources.redhat.com Subject: Re: RFA: Do solib address arithmetic with appropriate truncation MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2002-02/txt/msg00065.txt.bz2 On Feb 2, 8:31pm, Jim Blandy wrote: > Sat Feb 2 17:03:26 2002 Jim Blandy > > * solib-svr4.c (svr4_truncate_ptr): New function. > (svr4_relocate_section_addresses): Do the address arithmetic with > the appropriate truncation for target addresses, even when > CORE_ADDR is larger than a target address. I think this is a satisfactory short term (or even mid term) solution. I think the long term solution will be to introduce a method for adding offsets to CORE_ADDRs. See http://sources.redhat.com/ml/gdb/2001-10/msg00036.html I think it's okay to commit this patch, but I'd appreciate it if you'd add a comment indicating that svr4_truncate_ptr() should be removed when methods for adding displacements to CORE_ADDRs are introduced. Kevin