Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@false.org>
To: Yoriko Komatsuzaki <yoriko@sm.sony.co.jp>,
		Mark Kettenis <mark.kettenis@xs4all.nl>,
	gdb-patches@sourceware.org
Subject: Re: deal thread id as unsigned
Date: Mon, 14 May 2007 16:56:00 -0000	[thread overview]
Message-ID: <20070514165646.GC27054@caradoc.them.org> (raw)
In-Reply-To: <20070514165333.GB27054@caradoc.them.org>

On Mon, May 14, 2007 at 12:53:33PM -0400, Daniel Jacobowitz wrote:
> On Tue, Apr 17, 2007 at 11:01:43AM +0900, Yoriko Komatsuzaki wrote:
> > 
> > Thank you for your reply and suggestion.
> > 
> > I get my mind around no modification of defs.h because of the care for other
> > os'es. 
> > 
> > Concerning to thread id printing, I would appreciate it if you could
> > consider to print it by hexadecimal notation.
> 
> Yes, this is a good idea.  Sorry for the delay; I checked in this
> patch, to change the output to hexadecimal.  Tested on x86_64-linux.
> 
> I've just realized that the test change won't work on remote
> debugging; I'll fix up linux-dp.exp.

Like so.  gdbserver reports the LWP ID (PID) as the thread ID, so
decimal is appropriate.

-- 
Daniel Jacobowitz
CodeSourcery

2007-05-14  Daniel Jacobowitz  <dan@codesourcery.com>

	* gdb.threads/linux-dp.exp: Allow non-hexadecimal IDs also.

Index: testsuite/gdb.threads/linux-dp.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.threads/linux-dp.exp,v
retrieving revision 1.16
diff -u -p -r1.16 linux-dp.exp
--- testsuite/gdb.threads/linux-dp.exp	14 May 2007 16:52:13 -0000	1.16
+++ testsuite/gdb.threads/linux-dp.exp	14 May 2007 16:55:29 -0000
@@ -74,7 +74,7 @@ for {set i 0} {$i < 5} {incr i} {
 	-re "info threads\r\n" {
 	    exp_continue
 	}
-	-re "^. +(\[0-9\]+ Thread 0x\[0-9a-f\]+) \[^\n\]*\n" {
+	-re "^. +(\[0-9\]+ Thread \[-0-9a-fx\]+) \[^\n\]*\n" {
 	    verbose -log "found thread $expect_out(1,string)" 2
 	    lappend threads_before $expect_out(1,string)
 	    exp_continue
@@ -147,7 +147,7 @@ for {set i 0} {$i < 5} {incr i} {
 	-re "info threads\r\n" {
 	    exp_continue
 	}
-	-re "^. +(\[0-9\]+ Thread 0x\[0-9a-f\]+) \[^\n\]*\n" {
+	-re "^. +(\[0-9\]+ Thread \[-0-9a-fx\]+) \[^\n\]*\n" {
 	    set name $expect_out(1,string)
 	    for {set j 0} {$j != [llength $threads_before] } {incr j} {
 		if {$name == [lindex $threads_before $j]} {


      reply	other threads:[~2007-05-14 16:56 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-04-16 12:02 Yoriko Komatsuzaki
2007-04-16 14:19 ` Mark Kettenis
2007-04-16 15:14   ` Daniel Jacobowitz
2007-04-17 14:50     ` Yoriko Komatsuzaki
2007-05-14 16:53       ` Daniel Jacobowitz
2007-05-14 16:56         ` Daniel Jacobowitz [this message]

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=20070514165646.GC27054@caradoc.them.org \
    --to=drow@false.org \
    --cc=gdb-patches@sourceware.org \
    --cc=mark.kettenis@xs4all.nl \
    --cc=yoriko@sm.sony.co.jp \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox