public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* Cannot fetch general-purpose registers for thread 1342445920: generic error
@ 2006-06-19 17:35 Christoph Bartoschek
  2006-06-20 12:33 ` Daniel Jacobowitz
  0 siblings, 1 reply; 11+ messages in thread
From: Christoph Bartoschek @ 2006-06-19 17:35 UTC (permalink / raw)
  To: gdb

Hi,

when I want to debug my application I often get the following error:

Cannot fetch general-purpose registers for thread 1342445920: generic error

After this message I have to detach gdb and reattach it. What could be the 
problem? How can I avoid these errors?

Christoph Bartoschek

^ permalink raw reply	[flat|nested] 11+ messages in thread
* Re: Cannot fetch general-purpose registers for thread 1342445920:  generic error
@ 2006-09-01  0:14 Chuck Simmons
  2006-09-01  0:20 ` Daniel Jacobowitz
  0 siblings, 1 reply; 11+ messages in thread
From: Chuck Simmons @ 2006-09-01  0:14 UTC (permalink / raw)
  To: bartoschek, drow, gdb

Historically, in my experience, GDB has rarely handled threads well.  
(There was a year or two about 10 to 15 years ago where things worked 
fairly well, but since then...)  Here is a short session on Suse Linux 
using Posix threads:

"
(gdb) run 44123:127.0.0.1 dsk log.3382
Starting program: /home/csimmons/src/sysmon/sysmon2 44123:127.0.0.1 dsk 
log.3382
[Thread debugging using libthread_db enabled]
[New Thread 1075110560 (LWP 31423)]
main: policy=2, prio=1
[New Thread 1077214128 (LWP 31426)]
ping_cpu: policy=2, prio=1
[New Thread 1079315376 (LWP 31427)]
Couldn't get registers: No such process.
"

This is probably a timing related bug in the implementation of GDB.  
When debugging programs that spawn threads using back to back gdb 
sessions, some runs will allow one to do debugging, and some runs won't.

Cs

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2006-09-01 12:24 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-06-19 17:35 Cannot fetch general-purpose registers for thread 1342445920: generic error Christoph Bartoschek
2006-06-20 12:33 ` Daniel Jacobowitz
2006-06-20 13:00   ` Christoph Bartoschek
2006-06-20 13:20     ` Daniel Jacobowitz
2006-06-20 13:27       ` Christoph Bartoschek
2006-06-20 13:28         ` Daniel Jacobowitz
2006-06-20 16:21           ` Christoph Bartoschek
     [not found]             ` <20060620135351.GA9853@host0.dyn.jankratochvil.net>
2006-06-20 16:27               ` [filtered] " Christoph Bartoschek
2006-09-01  0:14 Chuck Simmons
2006-09-01  0:20 ` Daniel Jacobowitz
2006-09-01 12:24   ` Alex Bligh

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).