From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#15794: Core dump after SIGTERM during GC marking Date: Tue, 05 Nov 2013 17:53:17 +0200 Message-ID: <83bo1y976a.fsf@gnu.org> References: <87k3gq2dpr.fsf@igel.home> <83d2mh9ydm.fsf@gnu.org> <877gcp2wiz.fsf@igel.home> <83a9hl9sau.fsf@gnu.org> <8738nd2kig.fsf@igel.home> <83zjpk96qr.fsf@gnu.org> <83y554889t.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1383666854 3938 80.91.229.3 (5 Nov 2013 15:54:14 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 5 Nov 2013 15:54:14 +0000 (UTC) Cc: schwab@suse.de, 15794@debbugs.gnu.org To: Barry OReilly Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Nov 05 16:54:17 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VdixN-0006Cn-7b for geb-bug-gnu-emacs@m.gmane.org; Tue, 05 Nov 2013 16:54:17 +0100 Original-Received: from localhost ([::1]:56870 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VdixM-00054g-Ui for geb-bug-gnu-emacs@m.gmane.org; Tue, 05 Nov 2013 10:54:16 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:57952) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VdixF-00052b-6s for bug-gnu-emacs@gnu.org; Tue, 05 Nov 2013 10:54:14 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vdix9-00075i-6L for bug-gnu-emacs@gnu.org; Tue, 05 Nov 2013 10:54:09 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:50146) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vdix9-000757-3H for bug-gnu-emacs@gnu.org; Tue, 05 Nov 2013 10:54:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Vdix8-0004ZY-35 for bug-gnu-emacs@gnu.org; Tue, 05 Nov 2013 10:54:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 05 Nov 2013 15:54:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15794 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 15794-submit@debbugs.gnu.org id=B15794.138366682017544 (code B ref 15794); Tue, 05 Nov 2013 15:54:01 +0000 Original-Received: (at 15794) by debbugs.gnu.org; 5 Nov 2013 15:53:40 +0000 Original-Received: from localhost ([127.0.0.1]:35932 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Vdiwl-0004Yt-K6 for submit@debbugs.gnu.org; Tue, 05 Nov 2013 10:53:39 -0500 Original-Received: from mtaout22.012.net.il ([80.179.55.172]:33211) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Vdiwi-0004Ye-7g for 15794@debbugs.gnu.org; Tue, 05 Nov 2013 10:53:37 -0500 Original-Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MVS00100S4UGU00@a-mtaout22.012.net.il> for 15794@debbugs.gnu.org; Tue, 05 Nov 2013 17:53:19 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MVS001T8S4U4Y80@a-mtaout22.012.net.il>; Tue, 05 Nov 2013 17:53:19 +0200 (IST) In-reply-to: X-012-Sender: halo1@inter.net.il X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:80022 Archived-At: > Date: Tue, 5 Nov 2013 10:27:32 -0500 > From: Barry OReilly > Cc: Eli Zaretskii , 15794 <15794@debbugs.gnu.org> > > I then started Emacs via GDB and issued a SIGTERM during the sleep. As > before, I witnessed an abort in a kill hook. The C and Lisp > backtraces: Thanks. But the Lisp backtrace doesn't tell which function of the kill-emacs-hook was running, and the C backtrace is different (no trace of regexp functions) anyway, and GC didn't really start doing its job, so it's not exactly the same crash. To try and see which function from those that are in kill-emacs-hook, go to frame #68: > #68 0x0000000000586c85 in Frun_hooks (nargs=1, args=0xbd2200) at eval.c:2367 > #69 0x00000000005031d5 in Fkill_emacs (arg=60) at emacs.c:1891 > #70 0x0000000000503300 in terminate_due_to_signal (sig=15, > backtrace_limit=40) at emacs.c:359 And look at the variable 'args', which should be a list. Since this session crashed in GC, it is not safe to print Lisp objects with "pp" and its likes. Instead, you will have to walk the list using "xcar" and "xcdr", display the type of each object in the list using "xtype", and then display the object itself with the appropriate x* command, normally "xsymbol", since the list is constructed from function symbols. If you cannot do this in frame 68 for some reason (yours is an optimized build, so variables might not reflect the true state of affairs), try the frame above it: > #67 0x0000000000586be0 in run_hook_with_args (nargs=1, args=0x7fffffff9e60, > funcall=0x589a60 ) at eval.c:2525 Again, look at 'args'. Btw, I'm not sure what we are trying to establish here. Shutting down Emacs in the middle of GC is inherently dangerous.