From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9090 invoked by alias); 29 May 2003 23:13:07 -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 9080 invoked from network); 29 May 2003 23:13:06 -0000 Received: from unknown (HELO localhost.redhat.com) (207.219.125.131) by sources.redhat.com with SMTP; 29 May 2003 23:13:06 -0000 Received: from redhat.com (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id CCE832B2F; Thu, 29 May 2003 19:12:53 -0400 (EDT) Message-ID: <3ED693F5.9040108@redhat.com> Date: Thu, 29 May 2003 23:13:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:1.0.2) Gecko/20030223 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Mark Kettenis Cc: mludvig@suse.cz, gdb@sources.redhat.com, Alexandre Oliva Subject: Re: dwarf-frame.c question References: <3ED381CB.5050207@suse.cz> <200305291544.h4TFi7aL031832@elgar.kettenis.dyndns.org> <3ED66564.1020506@redhat.com> <200305292222.h4TMMmGm000694@elgar.kettenis.dyndns.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2003-05/txt/msg00408.txt.bz2 Discussed this with AlexO (of gcc). Let us ruin your day. This problem can occure even without recursion. Consider the C snippet: foo () { if (i) abort (with, lots, of parameters) do; normal; stuff; } it can be turned into: branch !i, 1: push with push lots push of push parameters call abort 1: do normal stuff The return address can end up pointing at the ``do'' / 1: line and that's CFI info is definitly not correct for unwinding from abort(). One idea (the origins of which are unknown) is for the compiler to generate CFI info containing no addresses and have GDB look for that dependant on the PC address being obtained using return or resume (sigtramp, sentinel). However, first, does anyone know if the DWARF 2 spec has something to say abou this? Andrew