From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5899 invoked by alias); 18 Feb 2003 22:51:09 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 5880 invoked from network); 18 Feb 2003 22:51:08 -0000 Received: from unknown (HELO localhost.redhat.com) (172.16.49.200) by 172.16.49.205 with SMTP; 18 Feb 2003 22:51:08 -0000 Received: from redhat.com (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id AD2A62D37; Tue, 18 Feb 2003 17:55:53 -0500 (EST) Message-ID: <3E52B9F2.8050405@redhat.com> Date: Tue, 18 Feb 2003 22:51:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD i386; en-US; rv:1.0.2) Gecko/20030217 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Kevin Buettner Cc: Daniel Jacobowitz , gdb@sources.redhat.com Subject: Re: frame_register_unwind(): "frame != NULL" assertion failure References: <1030213212349.ZM2427@localhost.localdomain> <20030213212904.GA14115@nevyn.them.org> <1030213213526.ZM2489@localhost.localdomain> <1030213214819.ZM2541@localhost.localdomain> <1030213232706.ZM8198@localhost.localdomain> <3E4D042F.3060102@redhat.com> <20030214151451.GC30416@nevyn.them.org> <3E5101BA.5000504@redhat.com> <1030218015926.ZM1309@localhost.localdomain> Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-SW-Source: 2003-02/txt/msg00326.txt.bz2 > #2 0x005479cc in mips_get_saved_register (raw_buffer=0x7fff6db8 "\020\002\177°\177ÿmÈ\020\002\177°\177ÿmÐ", optimizedp=0x7fff6dc8, addrp=0x7fff6dd0, frame=0x100573c8, regnum=31, lvalp=0x7fff6ddc) at /home/devel/kevinb/sourceware-mips64/src.baseline/gdb/mips-tdep.c:5509 [...] > If I were to follow your above suggestion, I would also have to add some > explicit regcache fetching code to mips_get_saved_register() too, but I > really can't believe that this is the best approach. Each case should be examined individually. Change this call: frame_register_unwind (get_next_frame (frame), regnum, optimizedp, lvalp, addrp, &realnum, raw_buffer); to instead call: static void generic_unwind_get_saved_register (char *raw_buffer, int *optimizedp, CORE_ADDR *addrp, struct frame_info *frame, int regnum, enum lval_type *lvalp) (note that the get_next_frame(frame) call isn't needed - that function does not have a well chosen name). The function frame_register() would be better but because that knows about old style get_saved_register code it would result in infinite recursion :-( Andrew