This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Make tests more flexible


On Wed, 15 Jan 2003 21:10:04 -0500, Elena Zannoni <ezannoni@redhat.com> said:

> David, try this, if it works for you I'll check it in as obvious.

It gets rid of some of them, but not all of them:

Running ./gdb.base/until.exp ...
FAIL: gdb.base/until.exp: until func, not called by current frame
Running ./gdb.base/advance.exp ...
FAIL: gdb.base/advance.exp: advance function not called by current frame
FAIL: gdb.base/advance.exp: continue to call to func3 in main
FAIL: gdb.base/advance.exp: advance function called as param
FAIL: gdb.base/advance.exp: advance with no argument

Log attached.

David Carlton
carlton@math.stanford.edu


Test Run By carlton on Wed Jan 15 20:46:59 2003
Native configuration is i686-pc-linux-gnu

		=== gdb tests ===

Schedule of variations:
    unix

Running target unix
Using /usr/local/share/dejagnu/baseboards/unix.exp as board description file for target.
Using /usr/local/share/dejagnu/config/unix.exp as generic interface file for target.
Using ./config/unix.exp as tool-and-target-specific interface file.
Running ./gdb.base/until.exp ...
Executing on build: rm -f /extra/gdb/mirror/src/gdb/testsuite/gdb.base/break    (timeout = 300)
spawn rm -f /extra/gdb/mirror/src/gdb/testsuite/gdb.base/break 
Executing on host: gcc ./gdb.base/break.c  -g  -lm   -o /extra/gdb/mirror/src/gdb/testsuite/gdb.base/break    (timeout = 300)
spawn gcc ./gdb.base/break.c -g -lm -o /extra/gdb/mirror/src/gdb/testsuite/gdb.base/break 
spawn /extra/gdb/mirror/src/gdb/testsuite/../../gdb/gdb -nw -nx 
GNU gdb 2003-01-15-cvs
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu".
(gdb) set height 0
(gdb) set width 0
(gdb) dir
Reinitialize source path to empty? (y or n) y
Source directories searched: $cdir:$cwd
(gdb) dir ./gdb.base
Source directories searched: /extra/gdb/mirror/src/gdb/testsuite/./gdb.base:$cdir:$cwd
(gdb) file /extra/gdb/mirror/src/gdb/testsuite/gdb.base/break
Reading symbols from /extra/gdb/mirror/src/gdb/testsuite/gdb.base/break...done.
(gdb) delete breakpoints
(gdb) info breakpoints
No breakpoints or watchpoints.
(gdb) break main
Breakpoint 1 at 0x8048520: file gdb.base/break.c, line 75.
(gdb) run 
Starting program: /extra/gdb/mirror/src/gdb/testsuite/gdb.base/break 

Breakpoint 1, main (argc=1, argv=0xbffff804, envp=0xbffff80c) at gdb.base/break.c:75
75	    if (argc == 12345) {  /* an unlikely value < 2^16, in case uninited */
(gdb) until 79
main (argc=1, argv=0xbffff804, envp=0xbffff80c) at gdb.base/break.c:79
79	    printf ("%d\n", factorial (atoi ("6")));
(gdb) PASS: gdb.base/until.exp: until line number
until 80 then stop
Junk at end of arguments.
(gdb) PASS: gdb.base/until.exp: malformed until
delete breakpoints
Delete all breakpoints? (y or n) y
(gdb) info breakpoints
No breakpoints or watchpoints.
(gdb) break factorial
Breakpoint 2 at 0x80485be: file gdb.base/break.c, line 96.
(gdb) run 
The program being debugged has been started already.
Start it from the beginning? (y or n) y
Starting program: /extra/gdb/mirror/src/gdb/testsuite/gdb.base/break 

Breakpoint 2, factorial (value=6) at gdb.base/break.c:96
96	    if (value > 1) {
(gdb) delete breakpoints
Delete all breakpoints? (y or n) y
(gdb) info breakpoints
No breakpoints or watchpoints.
(gdb) until 99
factorial (value=720) at gdb.base/break.c:99
99	    return (value);
(gdb) PASS: gdb.base/until.exp: until factorial, recursive function
delete breakpoints
(gdb) info breakpoints
No breakpoints or watchpoints.
(gdb) break marker2
Breakpoint 3 at 0x80484fd: file gdb.base/break.c, line 49.
(gdb) run 
The program being debugged has been started already.
Start it from the beginning? (y or n) y
Starting program: /extra/gdb/mirror/src/gdb/testsuite/gdb.base/break 
720

Breakpoint 3, 0x080484fd in marker2 (a=43) at gdb.base/break.c:49
49	int marker2 (a) int a; { return (1); }
(gdb) delete breakpoints
Delete all breakpoints? (y or n) y
(gdb) info breakpoints
No breakpoints or watchpoints.
(gdb) until marker3
main (argc=1, argv=0xbffff804, envp=0xbffff80c) at gdb.base/break.c:83
83	    marker3 ("stack", "trace");
(gdb) FAIL: gdb.base/until.exp: until func, not called by current frame
testcase ./gdb.base/until.exp completed in 1 seconds
Running ./gdb.base/advance.exp ...
Executing on build: rm -f /extra/gdb/mirror/src/gdb/testsuite/gdb.base/advance    (timeout = 300)
spawn rm -f /extra/gdb/mirror/src/gdb/testsuite/gdb.base/advance 
Executing on host: gcc ./gdb.base/advance.c  -g  -lm   -o /extra/gdb/mirror/src/gdb/testsuite/gdb.base/advance    (timeout = 300)
spawn gcc ./gdb.base/advance.c -g -lm -o /extra/gdb/mirror/src/gdb/testsuite/gdb.base/advance 
spawn /extra/gdb/mirror/src/gdb/testsuite/../../gdb/gdb -nw -nx 
GNU gdb 2003-01-15-cvs
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu".
(gdb) set height 0
(gdb) set width 0
(gdb) dir
Reinitialize source path to empty? (y or n) y
Source directories searched: $cdir:$cwd
(gdb) dir ./gdb.base
Source directories searched: /extra/gdb/mirror/src/gdb/testsuite/./gdb.base:$cdir:$cwd
(gdb) file /extra/gdb/mirror/src/gdb/testsuite/gdb.base/advance
Reading symbols from /extra/gdb/mirror/src/gdb/testsuite/gdb.base/advance...done.
(gdb) delete breakpoints
(gdb) info breakpoints
No breakpoints or watchpoints.
(gdb) break main
Breakpoint 1 at 0x804849c: file gdb.base/advance.c, line 37.
(gdb) run 
Starting program: /extra/gdb/mirror/src/gdb/testsuite/gdb.base/advance 

Breakpoint 1, main () at gdb.base/advance.c:37
37	  c = 5;
(gdb) list advance.c:1,1
1	
(gdb) search advance this location
38	  b = 3;    /* advance this location */
(gdb) advance 38
main () at gdb.base/advance.c:38
38	  b = 3;    /* advance this location */
(gdb) PASS: gdb.base/advance.exp: advance line number
list advance.c:1,1
1	
(gdb) search advance malformed
43	  return 0; /* advance malformed */
(gdb) advance 43 then stop
Junk at end of arguments.
(gdb) PASS: gdb.base/advance.exp: malformed advance
advance func
func () at gdb.base/advance.c:18
18	  x = x + 5;
(gdb) PASS: gdb.base/advance.exp: advance func
advance func3
main () at gdb.base/advance.c:41
41	  func3 (); /* break here */
(gdb) FAIL: gdb.base/advance.exp: advance function not called by current frame
list advance.c:1,1
1	
(gdb) search break here
41	  func3 (); /* break here */
(gdb) break 41
Breakpoint 2 at 0x80484b5: file gdb.base/advance.c, line 41.
(gdb) PASS: gdb.base/advance.exp: set breakpoint at call to func3
continue
Continuing.

Program exited normally.
(gdb) FAIL: gdb.base/advance.exp: continue to call to func3 in main
advance foo
The program is not running.
(gdb) FAIL: gdb.base/advance.exp: advance function called as param
advance
The program is not running.
(gdb) FAIL: gdb.base/advance.exp: advance with no argument
testcase ./gdb.base/advance.exp completed in 1 seconds

		=== gdb Summary ===

# of expected passes		7
# of unexpected failures	5
Executing on host: /extra/gdb/mirror/src/gdb/testsuite/../../gdb/gdb -nw --command gdb_cmd    (timeout = 300)
spawn /extra/gdb/mirror/src/gdb/testsuite/../../gdb/gdb -nw --command gdb_cmd 
GNU gdb 2003-01-15-cvs
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu".
/extra/gdb/mirror/src/gdb/testsuite/../../gdb/gdb version  2003-01-15-cvs -nx

runtest completed at Wed Jan 15 20:47:02 2003


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]