testsuite/2033: sigbpt.exp fails on Solaris10 and Solaris9 (possibly others)

steve@telxio.com steve@telxio.com
Wed Nov 16 02:08:00 GMT 2005


>Number:         2033
>Category:       testsuite
>Synopsis:       sigbpt.exp fails on Solaris10 and Solaris9 (possibly others)
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unasigned
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Wed Nov 16 02:08:01 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator:     Steve Williams
>Release:        gdb-6.3
>Organization:
>Environment:
sparc64-sun-solaris2.10
>Description:
The sigbpt.exp test fails because when stepping out of a signal trampoline, Solaris does not return directly to the faulting instruction. It passes thru various procedures in the C library, various PROCEDURE_LINKAGE_TABLE routines and finally into setcontext before context is set back to the faulting user procedure.

The current test does not allow for any of this.
>How-To-Repeat:
cd .../gdb-6.3/gdb/testsuite
runtest --tool=gdb GDB=../gdb gdb.base/sigbpt.exp
WARNING: Couldn't find the global config file.
Test Run By src_dev on Tue Nov 15 18:08:04 2005
Native configuration is sparc-sun-solaris2.10

                === gdb tests ===

Schedule of variations:
    unix

Running target unix
Using /opt/utsi/test/R500/opt/utsi/share/dejagnu/baseboards/unix.exp as board description file for target.
Using /opt/utsi/test/R500/opt/utsi/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/sigbpt.exp ...
FAIL: gdb.base/sigbpt.exp: stepi; stepi out of handler
FAIL: gdb.base/sigbpt.exp: stepi bp before segv; stepi out of handler
FAIL: gdb.base/sigbpt.exp: stepi bp at segv; stepi out of handler
FAIL: gdb.base/sigbpt.exp: stepi bp before and at segv; stepi out of handler

                === gdb Summary ===

# of expected passes            60
# of unexpected failures        4
../gdb version  6.3 -nx
>Fix:
Add catch all case to sigbpt.exp. In the case it does not recognise the next instruction, then just keep stepping:

--- gdb-6.3/gdb/testsuite/gdb.base/sigbpt.exp   2005-11-15 17:53:45.875684000 -0
800
+++ gdb-6.3p/gdb/testsuite/gdb.base/sigbpt.exp  2005-11-15 17:53:00.731963000 -0
800
@@ -187,6 +187,13 @@
        -re "pc *0x\[a-z0-9\]* .*bowler.*$gdb_prompt $" {
            kfail gdb/1702 "$test (corrupt pc)"
        }
+       -re "pc *0x\[a-z0-9\]*.*$gdb_prompt $" {
+           # This allows for targets that step off
+           # through the C library before returning
+           # to the faulting instruction
+           send_gdb "stepi\n"
+           exp_continue
+       }
     }

     # Clear any breakpoints
>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the Gdb-prs mailing list