From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Andrea Corallo Newsgroups: gmane.emacs.bugs Subject: bug#58956: mark_object, mark_objects(?) crash Date: Thu, 03 Nov 2022 21:25:08 +0000 Message-ID: References: <874jvi5edp.fsf@melete.silentflame.com> <20221103030046.GA57325@zira.vinc17.org> <83o7to8rh1.fsf@gnu.org> <20221103101308.GD9442@zira.vinc17.org> <83zgd872q2.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="4382"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) Cc: 58956@debbugs.gnu.org, Vincent Lefevre , 1017711@bugs.debian.org, spwhitton@spwhitton.name To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Nov 03 22:26:31 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oqhjJ-0000se-0H for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 03 Nov 2022 22:26:29 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oqhj1-00040U-MS; Thu, 03 Nov 2022 17:26:11 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oqhiv-0003zq-R6 for bug-gnu-emacs@gnu.org; Thu, 03 Nov 2022 17:26:08 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oqhis-0006r3-KA for bug-gnu-emacs@gnu.org; Thu, 03 Nov 2022 17:26:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oqhis-00085D-5L for bug-gnu-emacs@gnu.org; Thu, 03 Nov 2022 17:26:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Andrea Corallo Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 03 Nov 2022 21:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 58956 X-GNU-PR-Package: emacs Original-Received: via spool by 58956-submit@debbugs.gnu.org id=B58956.166751071431011 (code B ref 58956); Thu, 03 Nov 2022 21:26:02 +0000 Original-Received: (at 58956) by debbugs.gnu.org; 3 Nov 2022 21:25:14 +0000 Original-Received: from localhost ([127.0.0.1]:50933 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oqhi5-000846-VU for submit@debbugs.gnu.org; Thu, 03 Nov 2022 17:25:14 -0400 Original-Received: from mx.sdf.org ([205.166.94.24]:57312) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oqhi3-00083v-Bi for 58956@debbugs.gnu.org; Thu, 03 Nov 2022 17:25:12 -0400 Original-Received: from ma.sdf.org (ma.sdf.org [205.166.94.33]) by mx.sdf.org (8.15.2/8.14.5) with ESMTPS id 2A3LP745017047 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits) verified NO); Thu, 3 Nov 2022 21:25:07 GMT In-Reply-To: <83zgd872q2.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 03 Nov 2022 12:27:01 +0200") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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: , Original-Sender: "bug-gnu-emacs" Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:247025 Archived-At: Eli Zaretskii writes: >> Date: Thu, 3 Nov 2022 11:13:08 +0100 >> From: Vincent Lefevre >> Cc: spwhitton@spwhitton.name, 58956@debbugs.gnu.org, >> 1017711@bugs.debian.org >> >> On 2022-11-03 08:47:06 +0200, Eli Zaretskii wrote: >> > > On 2022-11-02 14:24:51 +0200, Eli Zaretskii wrote: >> > > > Signal 1 is SIGHUP, AFAIU. Why should Emacs receive SIGHUP in the >> > > > middle of GC, I have no idea. Maybe ask the user what was he doing at >> > > > that time. E.g., could that be a remote Emacs session? >> > > >> > > No, it is on my local machine. >> > >> > So how come Emacs gets a SIGHUP? This is the crucial detail that is >> > missing here. Basically, if SIGHUP is delivered to Emacs, Emacs is >> > supposed to die a violent death. >> >> I suspect the SIGHUP comes from Emacs itself. According to strace >> output, the only processes started by Emacs are "/usr/bin/emacs" >> (there are many of them). I don't see what other process could be >> aware of the situation. Unfortunately, I couldn't reproduce the >> issue with strace (I suspect some race condition). >> >> > > I run emacs, and quit it immediately. The generation of the core dump >> > > is almost 100% reproducible. Ditto with "emacs -nw". >> > >> > Wait, you mean the crash is during exiting Emacs? >> >> For this test, yes. In general, I don't know. >> >> > That could mean Emacs receives some input event when it's half-way >> > through the shutdown process, and the input descriptor is already >> > closed. >> >> Note that the process that crashes is not the Emacs I started, >> but a subprocess run by Emacs itself, since it has arguments like >> "-no-comp-spawn --batch -l /tmp/emacs-async-comp-url.el-FGov4z.el". > > Andrea, could you please look into this? The SIGHUP could be because > the parent process exits, but that shouldn't cause a crash in the > sub-process that performs native compilation? Hi Eli, AFAIU the Emacs subprocess we use to compile should behave like a regular Emacs. Now, the only option that comes to my mind is that libgccjit (being strictly derived from the GCC codebase) might be registering a signal handler of some kind that alters the behaviour we expect. But if this is the case we should find trace of it the strace, or we can use gdb setting a break point into 'signal' as well to check. Indeed if this theory is true I think should be classified as a libgccjit bug. Andrea