all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Gregor Zattler via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 74831@debbugs.gnu.org
Subject: bug#74831: 31.0.50; scratch/igc: segfaults on startup when called under gdb
Date: Thu, 12 Dec 2024 17:15:45 +0100	[thread overview]
Message-ID: <87cyhw513i.fsf@no.lan> (raw)
In-Reply-To: <86jzc5ymue.fsf@gnu.org>

Hi Eli,
* Eli Zaretskii <eliz@gnu.org> [2024-12-12; 16:53 +02]:
>> Date: Thu, 12 Dec 2024 15:26:32 +0100
>> From:  Gregor Zattler via "Bug reports for GNU Emacs,
>>  the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
>>
>> Program received signal SIGSEGV, Segmentation fault.
>> 0x0000555555779816 in XSETCDR (c=..., n=n@entry=...) at ./src/lisp.h:1605
>> 1605	  *xcdr_addr (c) = n;
>
> So what is the value of xcdr_addr(s) here?  It looks like
> dereferencing it causes the segfault, so its value might give us some
> hints.

sorry, I'm clueless:

(gdb) print xcdr_addr
No symbol "xcdr_addr" in current context.


> Also, where did you start GDB?  It looks like you started it not from
> the Emacs' src/ directory,

I started it in the Emacs src directory::

(gdb) pwd
Working directory /home/grfz/src/emacs-igc2/src.

because you once told me to do so for
gdb.


Anyway...

> in which case please say
>
>   (gdb) source /path/to/emacs/src/.gdbinit

I now added

 -ex "source /home/grfz/src/emacs-igc2/src/.gdbinit"

to my gdb invocation and tried again.
Now there are plenty of

Program received signal SIGSEGV, Segmentation fault.

lines in GDBs output but Emacs runs and
and (not so far) functions correct.


> before running Emacs.  That's because the MPS library uses SIGSEGV for
> its memory barriers, and .gdbinit there makes sure such SIGSEGVs don't
> stop Emacs.  IOW, this could be a false positive, not a real segfault.

That seemed to be the case.

Regards, Gregor





  reply	other threads:[~2024-12-12 16:15 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-12 14:26 bug#74831: 31.0.50; scratch/igc: segfaults on startup when called under gdb Gregor Zattler via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-12-12 14:53 ` Eli Zaretskii
2024-12-12 16:15   ` Gregor Zattler via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2024-12-12 16:43     ` Eli Zaretskii
2024-12-12 16:53       ` Gregor Zattler via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-12-12 18:56         ` Eli Zaretskii
2024-12-13  8:59           ` Pip Cet 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=87cyhw513i.fsf@no.lan \
    --to=bug-gnu-emacs@gnu.org \
    --cc=74831@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=telegraph@gmx.net \
    /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.