From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28822 invoked by alias); 7 Jul 2009 16:54:22 -0000 Received: (qmail 28814 invoked by uid 22791); 7 Jul 2009 16:54:21 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 07 Jul 2009 16:54:14 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id 630DD108CB; Tue, 7 Jul 2009 16:54:11 +0000 (GMT) Received: from caradoc.them.org (209.195.188.212.nauticom.net [209.195.188.212]) by nan.false.org (Postfix) with ESMTP id D5ABD104AB; Tue, 7 Jul 2009 16:54:10 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.69) (envelope-from ) id 1MODvi-0008QQ-Cb; Tue, 07 Jul 2009 12:54:06 -0400 Date: Tue, 07 Jul 2009 16:54:00 -0000 From: Daniel Jacobowitz To: Ulrich Weigand Cc: Jan Kratochvil , Tom Tromey , Mark Kettenis , gdb-patches@sourceware.org Subject: Re: [patch] Fix i386 memory-by-register access on amd64 Message-ID: <20090707165406.GA32069@caradoc.them.org> Mail-Followup-To: Ulrich Weigand , Jan Kratochvil , Tom Tromey , Mark Kettenis , gdb-patches@sourceware.org References: <20090706081927.GA18324@host0.dyn.jankratochvil.net> <200907071624.n67GO6bj015890@d12av02.megacenter.de.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200907071624.n67GO6bj015890@d12av02.megacenter.de.ibm.com> User-Agent: Mutt/1.5.20 (2009-06-14) X-IsSubscribed: yes 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: 2009-07/txt/msg00204.txt.bz2 On Tue, Jul 07, 2009 at 06:24:06PM +0200, Ulrich Weigand wrote: > Jan Kratochvil wrote: > > > Updated the patch to do on 64bit hosts exactly the same what 32bit hosts do. > > 32bit hosts do all the CORE_ADDR calculations 64bit, just the final ptrace > > call strips the width to 32bits. > > Hmm, I'm wondering how this would affect platforms where addresses are > generally treated as signed integers (MIPS ?). Dan, do you know if the > kernel expects the ptrace address argument to be sign-extended on MIPS? Ptrace takes a long. If GDB is o32/n32, we're only passing it 32 bits. If we are an n64 application, debugging an o32 application, I'm not sure what happens with sign extension... but it doesn't much matter; 32-bit userspace applications only get to use the low half of the address space anyway. -- Daniel Jacobowitz CodeSourcery