all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Alan Third <alan@idiocy.org>
Cc: gerd.moellmann@gmail.com, 75275@debbugs.gnu.org, stefankangas@gmail.com
Subject: bug#75275: 30.0.92; `make-thread` bug on macOS 15.2
Date: Thu, 02 Jan 2025 17:31:07 +0200	[thread overview]
Message-ID: <86msg9jkqs.fsf@gnu.org> (raw)
In-Reply-To: <Z3ZylsXjH2vbX8LB@faroe.holly.idiocy.org> (message from Alan Third on Thu, 2 Jan 2025 11:03:50 +0000)

> Date: Thu, 2 Jan 2025 11:03:50 +0000
> From: Alan Third <alan@idiocy.org>
> Cc: Eli Zaretskii <eliz@gnu.org>, stefankangas@gmail.com,
> 	75275@debbugs.gnu.org
> 
> > > I don't know.  Is there anything in the following code that can be
> > > relevant to a non-main thread?  Note that non-main threads can
> > > legitimately call wait_reading_process_output, which calls ns_select.
> > > For example, what happens if a non-main Lisp thread starts a
> > > sub-process? we do expect to be able to read the output from that
> > > sub-process.
> 
> My take on how this works was that in a non-main thread ns_select
> should just act like pselect, hence it used to literally just call
> pselect and return.

In general, this is not right: calls to ns_select are expected to call
thread_select, in all threads, so that other threads could get a
chance on grabbing the global lock while this (non-main) thread waits
for sub-process output.

Maybe this cannot currently work in the NS build, but then it means
any non-main thread will never relinquish the global lock until its
function returns or signals an error.

> FWIW, I still think the NS code in its current form is unsuitable for
> multi-threaded use and must be rewritten.

Then maybe we should stop supporting a with-threads build in NS?





  parent reply	other threads:[~2025-01-02 15:31 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-02  4:57 bug#75275: 30.0.92; `make-thread` bug on macOS 15.2 Stefan Kangas
2025-01-02  5:46 ` Gerd Möllmann
2025-01-02  5:55   ` Gerd Möllmann
2025-01-02  6:47   ` Stefan Kangas
2025-01-02  7:12     ` Gerd Möllmann
2025-01-02 14:35       ` Stefan Kangas
2025-01-02 14:38         ` Gerd Möllmann
2025-01-02 14:45           ` Gerd Möllmann
2025-01-02 15:19             ` Stefan Kangas
2025-01-02 16:06               ` Alan Third
2025-01-02 16:47                 ` Alan Third
2025-01-02 16:58                 ` Eli Zaretskii
2025-01-02 17:09                   ` Gerd Möllmann
2025-01-02 17:22                     ` Eli Zaretskii
2025-01-02 17:25                       ` Gerd Möllmann
2025-01-02 17:42                         ` Alan Third
2025-01-02 17:48                           ` Gerd Möllmann
2025-01-02 17:37                       ` Alan Third
2025-01-02 17:46                         ` Gerd Möllmann
2025-01-02 17:52                           ` Gerd Möllmann
2025-01-02 19:26                             ` Alan Third
2025-01-02 19:59                               ` Gerd Möllmann
2025-01-02 16:46               ` Eli Zaretskii
2025-01-02  7:53     ` Eli Zaretskii
2025-01-02  7:58       ` Stefan Kangas
2025-01-02  7:13 ` Eli Zaretskii
2025-01-02  7:30   ` Gerd Möllmann
2025-01-02  8:28     ` Eli Zaretskii
2025-01-02  8:33       ` Gerd Möllmann
2025-01-02  8:41         ` Gerd Möllmann
2025-01-02  8:55           ` Eli Zaretskii
2025-01-02 10:04             ` Gerd Möllmann
2025-01-02 11:03               ` Alan Third
2025-01-02 13:05                 ` Gerd Möllmann
2025-01-02 13:53                   ` Alan Third
2025-01-02 14:03                     ` Gerd Möllmann
2025-01-02 14:17                       ` Alan Third
2025-01-02 15:31                 ` Eli Zaretskii [this message]
2025-01-02 15:37                   ` Gerd Möllmann
2025-01-02 15:55                     ` Alan Third
2025-01-02 16:08                       ` Gerd Möllmann
2025-01-02  8:51         ` Gerd Möllmann
2025-01-02  7:31   ` Stefan Kangas
2025-01-02  8:31     ` Eli Zaretskii
2025-01-02 10:31     ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86msg9jkqs.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=75275@debbugs.gnu.org \
    --cc=alan@idiocy.org \
    --cc=gerd.moellmann@gmail.com \
    --cc=stefankangas@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.