From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19783 invoked by alias); 13 Jan 2010 21:08:29 -0000 Received: (qmail 19774 invoked by uid 22791); 13 Jan 2010 21:08:28 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_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; Wed, 13 Jan 2010 21:08: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.13.8/8.13.8) with ESMTP id o0DL8Ne8011849 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 13 Jan 2010 16:08:23 -0500 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 o0DL8MBr017231; Wed, 13 Jan 2010 16:08:23 -0500 Received: from opsy.redhat.com (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 o0DL8MWc027496; Wed, 13 Jan 2010 16:08:22 -0500 Received: by opsy.redhat.com (Postfix, from userid 500) id E2DC137819A; Wed, 13 Jan 2010 14:08:21 -0700 (MST) From: Tom Tromey To: Jan Kratochvil Cc: gdb-patches@sourceware.org Subject: Re: [patch 14/15] PIE: Fix back valgrind --db-attach=yes [fixup] References: <20091109210114.GO19138@host0.dyn.jankratochvil.net> <20100110214208.GA1435@host0.dyn.jankratochvil.net> Reply-To: tromey@redhat.com Date: Wed, 13 Jan 2010 21:08:00 -0000 In-Reply-To: <20100110214208.GA1435@host0.dyn.jankratochvil.net> (Jan Kratochvil's message of "Sun, 10 Jan 2010 22:42:08 +0100") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii 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: 2010-01/txt/msg00364.txt.bz2 >>>>> "Jan" == Jan Kratochvil writes: Jan> `valgrind --db-attach=yes' will run GDB on the crashed PID which is only Jan> a virtual emulated program inside a virtual machine running at that PID. Jan> The /proc/PID/exe program is a valgrind tool (such as `memcheck'). [...] Thanks for the detailed explanation. This was very helpful. Jan> gdb/ Jan> Support Valgrind attachments broken by the PIE support. Jan> * auxv.c: Include gdbcore.h. Jan> (procfs_xfer_auxv): Make static. Reduce its comment. Drop its Jan> parameters ops, object and annex. Remove their assertions. Jan> (ld_so_xfer_auxv, memory_xfer_auxv): New function. Jan> * auxv.h (procfs_xfer_auxv): Remove comment. Rename to ... Jan> (memory_xfer_auxv): ... here. Jan> * linux-nat.c (linux_xfer_partial): Rename procfs_xfer_auxv to Jan> memory_xfer_auxv. Jan> * procfs.c (procfs_xfer_partial): Likewise. Jan> * solib-svr4.c (svr4_relocate_main_executable): New prototype. Jan> (svr4_special_symbol_handling): Call svr4_relocate_main_executable. Jan> (svr4_solib_create_inferior_hook): Conditionalize the Jan> svr4_relocate_main_executable call. Jan> gdb/testsuite/ Jan> * gdb.base/valgrind-db-attach.exp, gdb.base/valgrind-db-attach.c: New. Ok. Thanks. Tom