From: Michael Chastain <mec.gnu@mindspring.com>
To: msnyder@redhat.com, manjo@austin.ibm.com
Cc: gilliam@us.ibm.com, gdb-patches@sources.redhat.com
Subject: Re: [RFC] New thread testcase.
Date: Tue, 10 Aug 2004 07:24:00 -0000 [thread overview]
Message-ID: <41187827.nailB8H1E9AWV@mindspring.com> (raw)
In-Reply-To: <Pine.LNX.4.58.0408091818400.18782@lazy>
Hi Manoj,
I am not the maintainer of gdb.threads -- that is Michael Snyder.
(See the gdb/MAINTAINERS file for a list of who maintains what
subdirectory). You'll have to work with Michael Snyder on this
patch. I can give you some feedback though.
The basic idea of the test is good but it needs revision. Don't get
discouraged by the long list that follows. I spent some time
proof-reading this because I think it's good and I want it to get in.
Also, since this is Michael Snyder's area, anything he says
outweighs anything I say. The changes below are just my advice.
Michael C
===
tbug.c
I think this name is too generic. gdb.threads is full of
files which are about thread bugs.
* Please email any bugs, comments, and/or additions to this file to:
* bug-gdb@prep.ai.mit.edu
Drop this part, bug-gdb@prep.ai.mit.edu is dead.
sleep(2);
See the call to sleep() in gdb.mi/pthreads.c:
/* When gdb is running, it sets hidden breakpoints in the thread
library. The signals caused by these hidden breakpoints can
cause system calls such as 'sleep' to return early. Pay attention
to the return value from 'sleep' to get the full sleep. */
int unslept = 9;
while (unslept > 0)
unslept = sleep (unslept);
All the sleep() calls in gdb.threads need to be like this.
See gdb.texinfo, section "Stopping and starting multi-thread
programs", for more information on this.
thread_check.exp
Same complaint about the name.
'bracktrace'
Typo.
'On ppc64 system this test is known to fail due to kernel bug
in ptrace system call.'
This is a start, but more info please. ppc64 is just a processor,
we need a whole gnu triple here, like ppc64-unknown-linux-gnu.
Run 'config.guess' on the system where it fails and report that
info. Also run 'uname -a' and get the kernel version. And it
would help to report the libc / glibc version as well.
send_gdb / gdb_expect
We are moving away from those to gdb_test_multiple.
With gdb_test_multiple, you don't need the default FAIL case
and the timeout case.
send_gdb "delete\n"
gdb_expect 100 {
Drop the timeout, you should not need a special timeout
for deleting breakpoints.
-re "39.*sprintf.* .*\r\n$gdb_prompt $" {
Do not use absolute line numbers! Call gdb_get_line_number to
get the line number you want.
set marker_1 [gdb_get_line_number "marker 1"]
...
-re "$marker_1.*sprintf.* .*\r\n$gdb_prompt $" {
Then in the test program, do this:
sprintf(number, "tf(%ld): begin", (long)arg); /* marker 1 */
-re ".*3.* .*0x.* in clone.* from .*libc.*$" {
This is not generic enough. There's no guarantee that
pthread_create is implemented with clone. For your purposes,
is it good enough to look for pthread_create on the stack?
next prev parent reply other threads:[~2004-08-10 7:24 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-08-09 22:18 [patch/testsuite/mi/copyright] gdb.mi/mi2-*.exp: update copyright years Michael Chastain
2004-08-10 6:10 ` [RFC] New thread testcase Manoj Iyer
2004-08-10 7:24 ` Michael Chastain [this message]
2004-08-10 15:13 ` Andrew Cagney
2004-08-10 20:22 ` Manoj Iyer
2004-08-10 20:33 ` Andrew Cagney
2004-08-10 20:44 ` Manoj Iyer
2004-08-12 16:04 ` Andrew Cagney
2004-08-27 3:25 ` Michael Snyder
2004-08-27 13:48 ` Manoj Iyer
2004-08-10 20:13 ` Manoj Iyer
2004-08-12 0:26 ` Michael Snyder
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=41187827.nailB8H1E9AWV@mindspring.com \
--to=mec.gnu@mindspring.com \
--cc=gdb-patches@sources.redhat.com \
--cc=gilliam@us.ibm.com \
--cc=manjo@austin.ibm.com \
--cc=msnyder@redhat.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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox