unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: awrhygty@outlook.com
Cc: 69263@debbugs.gnu.org
Subject: bug#69263: 29.1; emacs freeze with memory swap
Date: Tue, 20 Feb 2024 16:40:51 +0200	[thread overview]
Message-ID: <86msrvnqq4.fsf@gnu.org> (raw)
In-Reply-To: <TYZPR01MB392082E7D101FD3AB6AE248CC3502@TYZPR01MB3920.apcprd01.prod.exchangelabs.com> (awrhygty@outlook.com)

> From: awrhygty@outlook.com
> Cc: 69263@debbugs.gnu.org
> Date: Tue, 20 Feb 2024 22:33:35 +0900
> 
> > So if you want to help us understand what happens in the strange case
> > where a Lisp program creates a 8GB Lisp string, and clear it all, on a
> > 8GB MS-Windows system, please attach GDB to Emacs after running the
> > above recipe, and produce a backtrace that can be used to try to
> > figure out what happens.  (I hope that your Emacs binary is not
> > stripped of debugging symbols, because if it's stripped, GDB will not
> > tell anything useful.)
> >
> > Thanks.
> 
> I installed MSYS2 and GDB for this.
> At first, I tried to attach with emacs PID.
> GDB says "Can't attach to process 1099".
> So I tried with WINPID.
> I am not sure it is a correct parameter.
> 
> Here is a log within MSYS2 shell:
> $ ps
>       PID    PPID    PGID     WINPID   TTY         UID    STIME COMMAND
>      1051       1    1051       3940  ?         197609 20:56:49 /usr/bin/mintty
>      1205    1052    1205       9776  pty0      197609 22:26:16 /usr/bin/ps
>      1052    1051    1052      11328  pty0      197609 20:56:49 /usr/bin/bash
>      1099    1052    1099       1384  pty0      197609 21:10:57 /c/Emacs/emacs-29.1/bin/emacs
> $ /mingw64/bin/gdb
> GNU gdb (GDB) 13.2
> Copyright (C) 2023 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law.
> Type "show copying" and "show warranty" for details.
> This GDB was configured as "x86_64-w64-mingw32".
> Type "show configuration" for configuration details.
> For bug reporting instructions, please see:
> <https://www.gnu.org/software/gdb/bugs/>.
> Find the GDB manual and other documentation resources online at:
>     <http://www.gnu.org/software/gdb/documentation/>.
> 
> For help, type "help".
> Type "apropos word" to search for commands related to "word".
> (gdb) attach 1384
> Attaching to process 1384
> [New Thread 1384.0xbbc]
> [New Thread 1384.0xbe0]
> [New Thread 1384.0x2bc0]
> [New Thread 1384.0x2cc4]
> [New Thread 1384.0x14a4]
> Reading symbols from C:\Emacs\emacs-29.1\bin\emacs.exe...
> (gdb) bt full
> #0  0x00007ffa73710b11 in ntdll!DbgBreakPoint () from C:\WINDOWS\SYSTEM32\ntdll.dll
> No symbol table info available.
> #1  0x00007ffa7373ca0e in ntdll!DbgUiRemoteBreakin () from C:\WINDOWS\SYSTEM32\ntdll.dll
> No symbol table info available.
> #2  0x00007ffa72237344 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
> No symbol table info available.
> #3  0x00007ffa736c26b1 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll
> No symbol table info available.
> #4  0x0000000000000000 in ?? ()
> No symbol table info available.
> (gdb) detach
> Detaching from program: C:\Emacs\emacs-29.1\bin\emacs.exe, process 1384
> [Inferior 1 (process 1384) detached]
> (gdb) exit

This backtrace is not from an interesting thread.  You need to say
"thread 1" before "bt full", to switch to the Emacs's main
(a.k.a. "Lisp") thread.

Alternatively, say "thread apply all bt full", which will produce the
backtrace of all the threads in the program.

Thanks.





  reply	other threads:[~2024-02-20 14:40 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-19  5:56 bug#69263: 29.1; emacs freeze with memory swap awrhygty
2024-02-19 12:41 ` Eli Zaretskii
2024-02-20 13:33   ` awrhygty
2024-02-20 14:40     ` Eli Zaretskii [this message]
2024-02-20 15:33       ` awrhygty
2024-02-20 17:08         ` Eli Zaretskii
2024-06-09 20:56           ` Stefan Kangas

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=86msrvnqq4.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=69263@debbugs.gnu.org \
    --cc=awrhygty@outlook.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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).