From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2024 invoked by alias); 20 Nov 2008 16:37:46 -0000 Received: (qmail 1848 invoked by uid 22791); 20 Nov 2008 16:37:45 -0000 X-Spam-Check-By: sourceware.org Received: from mtagate3.de.ibm.com (HELO mtagate3.de.ibm.com) (195.212.29.152) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 20 Nov 2008 16:37:02 +0000 Received: from d12nrmr1607.megacenter.de.ibm.com (d12nrmr1607.megacenter.de.ibm.com [9.149.167.49]) by mtagate3.de.ibm.com (8.13.8/8.13.8) with ESMTP id mAKGb0AC173922 for ; Thu, 20 Nov 2008 16:37:00 GMT Received: from d12av02.megacenter.de.ibm.com (d12av02.megacenter.de.ibm.com [9.149.165.228]) by d12nrmr1607.megacenter.de.ibm.com (8.13.8/8.13.8/NCO v9.1) with ESMTP id mAKGaxNY4190372 for ; Thu, 20 Nov 2008 17:36:59 +0100 Received: from d12av02.megacenter.de.ibm.com (loopback [127.0.0.1]) by d12av02.megacenter.de.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id mAKGawnC029015 for ; Thu, 20 Nov 2008 17:36:59 +0100 Received: from tuxmaker.boeblingen.de.ibm.com (tuxmaker.boeblingen.de.ibm.com [9.152.85.9]) by d12av02.megacenter.de.ibm.com (8.12.11.20060308/8.12.11) with SMTP id mAKGawpG029010; Thu, 20 Nov 2008 17:36:58 +0100 Message-Id: <200811201636.mAKGawpG029010@d12av02.megacenter.de.ibm.com> Received: by tuxmaker.boeblingen.de.ibm.com (sSMTP sendmail emulation); Thu, 20 Nov 2008 17:36:58 +0100 Subject: Re: Fix foll-fork.exp foll-vfork.exp fork-child-threads.exp To: pedro@codesourcery.com (Pedro Alves) Date: Fri, 21 Nov 2008 01:49:00 -0000 From: "Ulrich Weigand" Cc: gdb-patches@sourceware.org In-Reply-To: <200811201506.04087.pedro@codesourcery.com> from "Pedro Alves" at Nov 20, 2008 03:06:03 PM X-Mailer: ELM [version 2.5 PL2] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit 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: 2008-11/txt/msg00563.txt.bz2 Pedro Alves wrote: > On Thursday 20 November 2008 14:28:24, Ulrich Weigand wrote: > > > I guess the "regcache" and "gdbarch" variables now also contain stale > > information. That's not an actual problem right now, as regcache is > > (currently) not used after this point, and gdbarch (today) will never > > actually change -- but in order to reduce potential future problems, > > I think those should also be reset. > > Right, how about the attached? > 2008-11-20 Pedro Alves > > * infrun.c (resume): If following a fork, also reset regcache, > gdbarch and pc. Looks good to me, thanks. As a separate question, I'm wondering why this is the right place to put the follow-fork logic anyway (and not in handle_inferior_event like follow-exec ...). Do you know the history of this? Bye, Ulrich -- Dr. Ulrich Weigand GNU Toolchain for Linux on System z and Cell BE Ulrich.Weigand@de.ibm.com