From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20114 invoked by alias); 13 Jan 2002 17:32:44 -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 20071 invoked from network); 13 Jan 2002 17:32:41 -0000 Received: from unknown (HELO cygnus.com) (205.180.230.5) by sources.redhat.com with SMTP; 13 Jan 2002 17:32:41 -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 JAA20894; Sun, 13 Jan 2002 09:32:39 -0800 (PST) Received: (from kev@localhost) by cse.cygnus.com (8.11.6/8.11.6) id g0DHOQZ25644; Sun, 13 Jan 2002 10:24:26 -0700 Date: Sun, 13 Jan 2002 09:32:00 -0000 From: Kevin Buettner Message-Id: <1020113172426.ZM25643@localhost.localdomain> In-Reply-To: Richard Earnshaw "Re: [PATCH] ARM: Eliminate EXTRA_FRAME_INFO & FRAME_FIND_SAVED_REGS" (Jan 13, 3:28pm) References: <200201131528.PAA21457@cam-mail2.cambridge.arm.com> X-Mailer: Z-Mail (4.0.1 13Jan97 Caldera) To: Richard.Earnshaw@arm.com Subject: Re: [PATCH] ARM: Eliminate EXTRA_FRAME_INFO & FRAME_FIND_SAVED_REGS Cc: Kevin Buettner , gdb-patches@sources.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2002-01/txt/msg00346.txt.bz2 On Jan 13, 3:28pm, Richard Earnshaw wrote: > > On Jan 12, 11:50am, Richard Earnshaw wrote: > > > > > This patch eliminates the deprecated macros EXTRA_FRAME_INFO & > > > FRAME_FIND_SAVED_REGS from the arm target support files and replaces them > > > with the new methods for doing this. > > > > I submitted a patch to do this last month. Unfortunately, the ARM > > maintainers have not had a chance to review it yet. > > > > See http://sources.redhat.com/ml/gdb-patches/2001-12/msg00397.html [...] > Hmm, it seems substantially the same as mine, but with a couple of minor > differences. > > 1) You don't seem to initialize the pointer fields in the static frame > structure "prologue_cache". My patch does this allocation in _initialize_arm_tdep() whereas yours does it in check_prologue_cache() and save_prologue_cache(). > 2) Similarly you don't seem to be allocating the saved_regs for the > caller_fi frame (arm_frame_chain). You do, however, allocate the > extra_info. > 3) You have a cleanup for the extra_info allocated above, which I hadn't > thought about. I think one is also needed for the saved_regs. Are you sure? Here are what I believe to be the relevant lines from the arm_frame_chain hunk: + caller_fi.saved_regs = (CORE_ADDR *) xcalloc (1, SIZEOF_FRAME_SAVED_REGS); + old_chain = make_cleanup (xfree, caller_fi.saved_regs); + caller_fi.extra_info = xcalloc (1, sizeof (struct frame_extra_info)); + make_cleanup (xfree, caller_fi.extra_info); saved_regs is being allocated and a cleanup is being created. Were you perhaps refering to some other hunk? Kevin