From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27719 invoked by alias); 20 Oct 2003 23:57:06 -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 27712 invoked from network); 20 Oct 2003 23:57:05 -0000 Received: from unknown (HELO localhost.redhat.com) (207.219.125.105) by sources.redhat.com with SMTP; 20 Oct 2003 23:57:05 -0000 Received: from gnu.org (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id C386F2B89; Mon, 20 Oct 2003 19:57:04 -0400 (EDT) Message-ID: <3F947650.8090601@gnu.org> Date: Mon, 20 Oct 2003 23:57:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:1.0.2) Gecko/20030820 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Kevin Buettner Cc: gdb-patches@sources.redhat.com Subject: Re: [PATCH] frv-tdep.c: Stop backtraces in entry func, not entry file References: <1031014205135.ZM29586@localhost.localdomain> <3F8C70CE.5020504@gnu.org> <1031016000707.ZM23790@localhost.localdomain> <3F8DF0F5.4090807@gnu.org> <1031016033144.ZM24591@localhost.localdomain> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2003-10/txt/msg00631.txt.bz2 >> I'd like to avoid re-introducing a dependency on inside_entry_func() as >> that places garish requirements on the object file readers :-( > > > I agree that object file readers should not attempt to track of > the bounds of the start function. However, given an arbitrary > address, it's not unreasonable to ask the symtab machinery to attempt > to figure out the function bounds. And, in fact, this is just what > find_pc_partial_function() does. Begs the question. How come it wasn't done that way originally? Same for main()? One common problem is badly written crt0.o files. For instance: _start: set-sp-insn for-insn endloop clear-mem-insn endloop: call-insn main should use numeric lables so that the symbol table code doesn't get tripped up thinking "endloop" is a function. > > I also suspect that just removing the test fixes the bug. > > > What bug? The original one: "An FR-V user reported being unable to see useful backtraces when debugging functions inside the entry file." Removing the entry-file test gives the user a meaningful backtrace. (Oh, the assembler tests don't pass if that test is present.) > As noted earlier, I'm seeing unwelcome behavior regardless of whether > the test is enabled or not. I've looked at what's going on in > inside_entry_func() and have already determined that it's not working > properly for me. Andrew