emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 23.0.60; emacs hangs on WinXP with --disable-font-backend, and backt


From: Eli Zaretskii
Subject: Re: 23.0.60; emacs hangs on WinXP with --disable-font-backend, and backtrace
Date: Fri, 09 May 2008 10:22:11 +0300

> Date: Fri, 09 May 2008 09:05:09 +0800
> From: "Kyle M. Lee" <address@hidden>
> CC: address@hidden
> 
> (gdb) r --disable-font-backend
> Starting program: e:\emacs_gcc_std_install\bin\emacs.exe 
> --disable-font-backend
> [New thread 3376.0x30c]
> [New thread 3376.0x388]
> [New thread 3376.0xd80]
> [New thread 3376.0xa10]
> [Switching to thread 3376.0xa10]
> Quit (expect signal SIGINT when the program is resumed)
> (gdb) bt

There's a strange anomaly here: when I do the same, I only see 3
threads, not 4.  And 3 is what I'd expect: there are 2 threads in a
normally running Emacs (on Windows): one thread that reads input, the
other that runs the normal Emacs code.  The third thread is created by
Windows when you type C-c into the GDB window, because that's how
Windows handles SIGINT.

Please tell me when did you see the third thread, announced by this
line in GDB output:

> [New thread 3376.0xd80]

Was it when you typed C-c, or before?

Also, are you running GDB from a Command Prompt window, or in some
other manner?

> #0  0x7c810659 in KERNEL32!CreateThread ()
>    from C:\WINDOWS\system32\kernel32.dll
> Cannot access memory at address 0x3
> (gdb) xbacktrace
> (gdb) backtrace
> #0  0x7c810659 in KERNEL32!CreateThread ()
>    from C:\WINDOWS\system32\kernel32.dll
> Cannot access memory at address 0x3
> (gdb) c
> Continuing.
> [New thread 3376.0xc10]
> [Switching to thread 3376.0xc10]
> 0x7c810659 in KERNEL32!CreateThread () from C:\WINDOWS\system32\kernel32.dll
> Quit (expect signal SIGINT when the program is resumed)
> (gdb) bt
> #0  0x7c810659 in KERNEL32!CreateThread ()
>    from C:\WINDOWS\system32\kernel32.dll
> #1  0x90909090 in ?? ()
> #2  0x001165b8 in ?? ()
> #3  0x0300ba00 in ?? ()
> #4  0x12ff7ffe in ?? ()
> #5  0x900004c2 in ?? ()
> #6  0x90909090 in ?? ()

Oops, sorry: I forgot to tell you one important detail.  After you
type C-c into the GDB window, GDB delivers SIGINT to Emacs, and that
causes Windows to start another thread (see the "New thread" message
above).  When a new thread is started, GDB automatically switches to
that thread.  So after typing C-c you are in the thread created by
Windows to handle SIGINT.  But that thread is not the one whose
backtrace we need, which is why you see meaningless frames.

To see an interesting thread, type "thread 1" before "bt".  The first
thread in the running Emacs is the one where most processing happens.
(The GDB command "info threads" will show you all the threads GDB
knows about.)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]