From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Helmut Eller Newsgroups: gmane.emacs.devel Subject: Re: igc, macOS avoiding signals Date: Tue, 31 Dec 2024 15:40:29 +0100 Message-ID: <87bjwrgbky.fsf@gmail.com> References: <799DDBC5-2C14-4476-B1E0-7BA2FE9E7901@toadstyle.org> <87h66loc17.fsf@gmail.com> <878qrxoayj.fsf@gmail.com> <8734i5o6wc.fsf@gmail.com> <87cyh9mpn5.fsf@gmail.com> <874j2l1hei.fsf@protonmail.com> <874j2lmd37.fsf@gmail.com> <87msgdkt29.fsf@gmail.com> <86h66lnjrt.fsf@gnu.org> <868qrxnfrw.fsf@gnu.org> <87a5ccl2zx.fsf@gmail.com> <86o70sm1ts.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="27653"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: gerd.moellmann@gmail.com, pipcet@protonmail.com, spd@toadstyle.org, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Dec 31 15:41:00 2024 Return-path: Envelope-to: ged-emacs-devel@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 1tSdQa-00076b-3k for ged-emacs-devel@m.gmane-mx.org; Tue, 31 Dec 2024 15:41:00 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tSdQC-0006z2-PE; Tue, 31 Dec 2024 09:40:36 -0500 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 1tSdQA-0006yl-P0 for emacs-devel@gnu.org; Tue, 31 Dec 2024 09:40:35 -0500 Original-Received: from mail-ej1-x631.google.com ([2a00:1450:4864:20::631]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tSdQ8-00071X-UO; Tue, 31 Dec 2024 09:40:34 -0500 Original-Received: by mail-ej1-x631.google.com with SMTP id a640c23a62f3a-aa689a37dd4so1538282666b.3; Tue, 31 Dec 2024 06:40:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1735656031; x=1736260831; darn=gnu.org; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=d4XaOmAAKeuIJf67Z7Y6etSvR8VhnNWEpJHLbTjfRGA=; b=hKXSoOLJNTi84TuxcH26GkMjm9zl8D7ogRsI0y+pUHjBqbYG/ZbBxBa1q06qeeSFd0 n9ukI+CA1m48Jd/4n+IQ6gxKjfzS0PmKUj2ooRDEFjh1Gvw6d+wepOy8pnDwSzTyHvJ2 LcL/hu4W9XjDDUBy4+GhB2ENMj9BEL9lRHVV4mCes7HzUm6XNCjBPhqYvu5GazRLo5mj iRXbrkqbbsCNXhSI+7Lhz4094TfPQZQFj7wjjf0p5wqYE9ly2DiVCI/TbnroTnN0OtI/ CNfArHDJKewpQwPfxRCTylKeVRIQE9XW2AibiY7pU/GhMiyuOefHI5FHU6wEVbO3SkC7 fk/Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1735656031; x=1736260831; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=d4XaOmAAKeuIJf67Z7Y6etSvR8VhnNWEpJHLbTjfRGA=; b=QuzbJIkX/X7bE2wWkSi1y8aSheHppwNWE4a8Z6wcuiZxMu+EL2cQF+YalJXXkzQFTw rNgs1eRW61OS+w2meT9ZkxqEMfUpCHSOpNI40i1g9ciP3oJT1nUfai2/2ApZIIxhUaBB zVhbEdHr+OEnms/sdbtWv9GkRsj1oa6I8GA4rWWe8NmPuixtEk1ZRXK4zuJz/M5d+mLB HNDKKbdXBEOy1NMNSH4ifhhZc5uJ1F3DJknN6JU958A8eUK9mp2XdI8bU/Vk03Exi6qO iX7dqO4sVfpY52U9AeDz4wH6fTbgTLKZLb8LQjjhXm7SWheVsm00chWGmWKZRp+MhNUV SF9w== X-Forwarded-Encrypted: i=1; AJvYcCVsu4+E4i7R4cZJ4Yb6plVWssywIZpxw1cZPj34hau01N6I9KU6LORrgwbwWglMnHsFfXMYcwaCIYY9Ww==@gnu.org X-Gm-Message-State: AOJu0Yzl120andhnjgGjKMn/x5w7iYSWYoME+2/eW1Besfxd60Hjpnm+ 5bvDrOfFxZJlj8aHkr0yqpm+t3fnQVdx6cp0mcOY80GZ5jD7TBkmEMjP7PLE X-Gm-Gg: ASbGncupmWc6NC6Skh360QhORJr2opRX+NpIhljaZXG5uU8H+NzUcHY91GEIemuTsmd tO7TNVlBEK7sSoqUZTvGXQNfzJCXsdlALL/zpCJW0hWJXfMf008W4vim6y8p9rk5dmA3R+pPwc8 kY6FbReRsjXQemY+jlm/iXfF5XE7Piz4/WE9wGnDfFuxbwq7eB4Yh2XThkNU31TAjJ9OKhyNu4v aW9xTlMo0gswoYHn6kF7xoKDBpDq2hN1ipXYhNgDgRGE9842n0rHJ0= X-Google-Smtp-Source: AGHT+IFtf5fGG+MZlVN4CRY8GYMMOisWcpCOJdE1gk8gmQIW45ae3plrhgFPPd8yX7nfhcV2YWYNjA== X-Received: by 2002:a17:907:6092:b0:aab:c35e:509b with SMTP id a640c23a62f3a-aac3378bee1mr3167858466b.55.1735656030642; Tue, 31 Dec 2024 06:40:30 -0800 (PST) Original-Received: from caladan ([31.177.115.143]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-aac0e82ede9sm1571144466b.2.2024.12.31.06.40.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 31 Dec 2024 06:40:30 -0800 (PST) In-Reply-To: <86o70sm1ts.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 31 Dec 2024 15:14:39 +0200") Received-SPF: pass client-ip=2a00:1450:4864:20::631; envelope-from=eller.helmut@gmail.com; helo=mail-ej1-x631.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:327517 Archived-At: On Tue, Dec 31 2024, Eli Zaretskii wrote: >> Except the POSIX police: it says that pthread_mutex_trylock isn't async >> signal safe. I suppose this also makes it's unsafe to use MPS's fault >> handler in an async signal handler. Bummer. (Does the police take >> bribes?) > > Doesn't MPS itself call it from a SIGSEGV handler? Yes. But I'm not sure that SIGSEGV is considered an async signal. I supposed there is something like synchronous signals. >> I wonder if the backtrace that we see in the signal handler is any >> different from the backrace that we would see at the next safe point >> (i.e. the next time maybe_quit is called). > > I think we cannot rely on that, because maybe_quit must be called by > hand, it isn't magic. We call it from various places in the > interpreter, which could well be in some other place of a Lisp > program. Maybe somebody could do an experiment: record both backtraces for a while and see if they differ. > Once again, why not ask the MPS folks to give us a callback? Or maybe > we could try hacking MPS ourselves first, to see if that does the job, > and ask them then? Nobody stops you from doing this. :-) Helmut