From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15699 invoked by alias); 6 Oct 2003 21:23:58 -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 15690 invoked from network); 6 Oct 2003 21:23:57 -0000 Received: from unknown (HELO Cantor.suse.de) (195.135.220.2) by sources.redhat.com with SMTP; 6 Oct 2003 21:23:57 -0000 Received: from Hermes.suse.de (Hermes.suse.de [195.135.221.8]) (using TLSv1 with cipher EDH-RSA-DES-CBC3-SHA (168/168 bits)) (No client certificate requested) by Cantor.suse.de (Postfix) with ESMTP id 6281C16B8068 for ; Mon, 6 Oct 2003 23:23:57 +0200 (CEST) To: gdb-patches@sources.redhat.com Subject: Improvement to i386_analyze_frame_setup From: Andreas Schwab X-Yow: Is it clean in other dimensions? Date: Mon, 06 Oct 2003 21:23:00 -0000 Message-ID: User-Agent: Gnus/5.1002 (Gnus v5.10.2) Emacs/21.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-SW-Source: 2003-10/txt/msg00130.txt.bz2 This patch improves the i386 frame setup analyzer by recognizing one more case that GCC might generate. Andreas. 2003-10-06 Andreas Schwab * i386-tdep.c (i386_analyze_frame_setup): Also handle xorl/subl with %eax. --- gdb/i386-tdep.c.~1.170.~ 2003-10-06 10:19:03.000000000 +0200 +++ gdb/i386-tdep.c 2003-10-06 23:21:29.000000000 +0200 @@ -499,12 +499,14 @@ i386_analyze_frame_setup (CORE_ADDR pc, xorl %ebx, %ebx xorl %ecx, %ecx xorl %edx, %edx + xorl %eax, %eax and the equivalent subl %ebx, %ebx subl %ecx, %ecx subl %edx, %edx + subl %eax, %eax Make sure we only skip these instructions if we later see the `movl %esp, %ebp' that actually sets up the frame. */ @@ -516,6 +518,7 @@ i386_analyze_frame_setup (CORE_ADDR pc, case 0xdb: /* %ebx */ case 0xc9: /* %ecx */ case 0xd2: /* %edx */ + case 0xc0: /* %eax */ skip += 2; break; default: -- Andreas Schwab, SuSE Labs, schwab@suse.de SuSE Linux AG, Deutschherrnstr. 15-19, D-90429 Nürnberg Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different."