all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Manuel Giraud <manuel@ledu-giraud.fr>
Cc: emacs-devel@gnu.org
Subject: Re: Emacs without threads
Date: Fri, 15 Dec 2023 14:11:24 +0200	[thread overview]
Message-ID: <83zfyboec3.fsf@gnu.org> (raw)
In-Reply-To: <874jgju3ia.fsf@ledu-giraud.fr> (message from Manuel Giraud on Fri, 15 Dec 2023 12:08:45 +0100)

> From: Manuel Giraud <manuel@ledu-giraud.fr>
> Cc: emacs-devel@gnu.org
> Date: Fri, 15 Dec 2023 12:08:45 +0100
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> >> From: Manuel Giraud <manuel@ledu-giraud.fr>
> >> Cc: emacs-devel@gnu.org
> >> Date: Thu, 14 Dec 2023 15:12:31 +0100
> >> 
> >> Eli Zaretskii <eliz@gnu.org> writes:
> >> 
> >> > The threads you see under a debugger are not Lisp threads, they are
> >> > threads started by GTK and other libraries we link against.  You
> >> > cannot disable them, except by building Emacs without those libraries
> >> > (I think just without GTK should do, if you are on GNU/Linux).
> >> 
> >> I'm not using GTK so maybe it is another library (maybe librsvg-2).
> >
> > Look at the code those threads run (e.g., with "thread apply all bt"),
> > and you will know which library does that.
> >
> >> >> (FWIW, I want this to simplify debugging because on my machine I cannot
> >> >> make GDB to switch to the correct thread
> >> >
> >> > How come?
> >> 
> >> I don't know so I will just describe the symptoms: when I "run" Emacs
> >> into a 'M-x gdb' session at one point the *gud* buffer will output [New
> >> thread ...] and then the Emacs process is stuck and so is the process of
> >> the *gud* buffer.  So I have to kill and close everything.
> >
> > Never seen anything like that.  Any chance of describing under what
> > conditions this happens?  Is this 100% reproducible on your system?
> 
> This is not 100% reproducible but it eventually happens most of the time
> 😅.  For example, if I put a breakpoint on 'show_mouse_face' and run
> with -Q in gdb, I finally stuck like this at some point.

Unless someone who uses GDB on X can confirm this problem, I'd say
this is something to report to the GDB developers and/or the OpenBSD's
GDB distro maintainers.

Do you have any idea what code is run by those "New thread"s?

If you start GDB from the shell prompt, not from Emacs, does this
happen then as well?  If not, this could be some bug in gdb-mi.el.

> FWIW, I cannot set the scheduler-locking setting.  Here is what I
> get when I try:
> 
> (gdb) set scheduler-locking replay
> Target 'exec' cannot support this command.
> (gdb) show scheduler-locking
> Mode for locking scheduler during execution is "off".

OFF is OK for debugging Emacs, but why do you think scheduler-locking
is relevant to this issue?



  reply	other threads:[~2023-12-15 12:11 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-14 10:36 Emacs without threads Manuel Giraud via Emacs development discussions.
2023-12-14 11:16 ` Eli Zaretskii
2023-12-14 12:43   ` Manuel Giraud via Emacs development discussions.
2023-12-14 13:01     ` Eli Zaretskii
2023-12-14 14:12       ` Manuel Giraud via Emacs development discussions.
2023-12-14 16:34         ` Eli Zaretskii
2023-12-15 11:08           ` Manuel Giraud via Emacs development discussions.
2023-12-15 12:11             ` Eli Zaretskii [this message]
2023-12-15 13:58               ` Manuel Giraud via Emacs development discussions.
2023-12-16 13:13                 ` Eli Zaretskii
2023-12-16 19:13                   ` Manuel Giraud via Emacs development discussions.
2023-12-16 19:26                     ` Eli Zaretskii
2023-12-17 18:43                     ` Manuel Giraud via Emacs development discussions.
2023-12-18  3:24                       ` Eli Zaretskii
2023-12-18  6:53                         ` Manuel Giraud via Emacs development discussions.
2023-12-18 17:43                           ` Eli Zaretskii
2023-12-22  9:20                             ` Michael Albinus
2023-12-22 11:48                               ` Eli Zaretskii
2023-12-22 12:11                                 ` Michael Albinus
2023-12-22 13:55                                 ` Manuel Giraud via Emacs development discussions.
2023-12-22 14:28                                   ` Eli Zaretskii
2023-12-22 14:44                                     ` Manuel Giraud via Emacs development discussions.
2023-12-22 14:54                                       ` Eli Zaretskii
2023-12-22 14:45                                     ` Michael Albinus

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=83zfyboec3.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=manuel@ledu-giraud.fr \
    /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.