From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20558 invoked by alias); 19 Nov 2005 12:48:42 -0000 Received: (qmail 20546 invoked by uid 22791); 19 Nov 2005 12:48:41 -0000 Received: from ip127.bb146.pacific.net.hk (HELO stl.com.hk) (202.64.146.127) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Sat, 19 Nov 2005 12:48:41 +0000 Received: from 241.206.17.210.dyn.pacific.net.hk ([210.17.206.241] helo=[192.168.1.10]) by stl.com.hk with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.50) id 1EdS4s-0002t8-4R for gdb-patches@sources.redhat.com; Sat, 19 Nov 2005 20:44:22 +0800 Message-ID: <437F1F25.6040104@tausq.org> Date: Sat, 19 Nov 2005 16:06:00 -0000 From: Randolph Chung User-Agent: Debian Thunderbird 1.0.2 (X11/20050331) MIME-Version: 1.0 To: gdb-patches@sources.redhat.com Subject: [hpux] Improve sigtramp frame identification Content-Type: multipart/mixed; boundary="------------090904090508050402020607" Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2005-11/txt/msg00366.txt.bz2 This is a multi-part message in MIME format. --------------090904090508050402020607 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-length: 212 the old code used to be hardcoded to look for a "_sigreturn" function, but according to the ABI, the signal frame can be identified by a specific bit in the unwind record. Use that instead. committed randolph --------------090904090508050402020607 Content-Type: text/x-patch; name="hpux-sig.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="hpux-sig.diff" Content-length: 1007 2005-11-19 Randolph Chung * hppa-hpux-tdep.c (hppa_hpux_sigtramp_unwind_sniffer): Rely on the unwind record to determine a signal frame, instead of hardcoding a function name. Index: hppa-hpux-tdep.c =================================================================== RCS file: /cvs/src/src/gdb/hppa-hpux-tdep.c,v retrieving revision 1.43 diff -u -p -r1.43 hppa-hpux-tdep.c --- hppa-hpux-tdep.c 29 Oct 2005 21:31:45 -0000 1.43 +++ hppa-hpux-tdep.c 19 Nov 2005 12:43:47 -0000 @@ -1246,12 +1274,12 @@ static const struct frame_unwind hppa_hp static const struct frame_unwind * hppa_hpux_sigtramp_unwind_sniffer (struct frame_info *next_frame) { + struct unwind_table_entry *u; CORE_ADDR pc = frame_pc_unwind (next_frame); - char *name; - find_pc_partial_function (pc, &name, NULL, NULL); + u = find_unwind_entry (pc); - if (name && strcmp(name, "_sigreturn") == 0) + if (u && u->HP_UX_interrupt_marker) return &hppa_hpux_sigtramp_frame_unwind; return NULL; --------------090904090508050402020607--