Re: [PATCH 3/3] Remove HP-UX references fom testsuite

Joel Brobecker
2015-12-20T05:08:41Z

On Sat, Dec 19, 2015 at 06:30:45PM -0500, Simon Marchi wrote:
> This patch removes all special cases for HP-UX, for which support has
> been removed earlier, that I found in the testsuite. Note that the hppa
> architecture != HP-UX, since other OSes can run on hppa, so I tried to
> leave everything that is not HP-UX specific.
>
> Two complete tests were completely HP-UX specific, so I removed them.
>
> I ran the testsuite on Linux x86-64, native and native-gdbserver, and
> noticed no regressions.
>
> gdb/testsuite/ChangeLog:
>
> * gdb.asm/asm-source.exp: Remove HP-UX references.
> * gdb.base/annota1.exp: Likewise.
> * gdb.base/annota3.exp: Likewise.
> * gdb.base/attach.exp: Likewise.
> * gdb.base/bigcore.exp: Likewise.
> * gdb.base/break.exp: Likewise.
> * gdb.base/call-ar-st.exp: Likewise.
> * gdb.base/callfuncs.exp: Likewise.
> * gdb.base/catch-fork-static.exp: Likewise.
> * gdb.base/display.exp: Likewise.
> * gdb.base/foll-exec-mode.exp: Likewise.
> * gdb.base/foll-exec.exp: Likewise.
> * gdb.base/foll-fork.exp: Likewise.
> * gdb.base/foll-vfork.exp: Likewise.
> * gdb.base/funcargs.exp: Likewise.
> * gdb.base/hbreak2.exp: Likewise.
> * gdb.base/inferior-died.exp: Likewise.
> * gdb.base/interrupt.exp: Likewise.
> * gdb.base/multi-forks.exp: Likewise.
> * gdb.base/nodebug.exp: Likewise.
> * gdb.base/sepdebug.exp: Likewise.
> * gdb.base/solib1.c: Likewise.
> * gdb.base/step-test.exp: Likewise.
> * gdb.dwarf2/pr10770.c: Likewise.
> * gdb.mi/non-stop.c: Likewise.
> * gdb.mi/pthreads.c: Likewise.
> * gdb.multi/bkpt-multi-exec.ex: Likewise.p
> * gdb.threads/pthreads.c: Likewise.
> * gdb.threads/staticthreads.exp: Likewise.
> * lib/future.exp: Likewise.
> * lib/gdb.exp: Likewise.
> * gdb.base/so-indr-cl.c: Remove.
> * gdb.base/so-indr-cl.exp: Likewise.
> * gdb.base/solib.c: Likewise.
> * gdb.base/solib.exp: Likewise.
> * gdb.base/solib2.c: Likewise.

Looks good to me, with one question below.

> index 003a73f..6ca910c 100644
> --- a/gdb/testsuite/gdb.base/break.exp
> +++ b/gdb/testsuite/gdb.base/break.exp
> @@ -485,24 +485,13 @@ gdb_test_multiple "catch fork" "$name" {
> }
>
>
> -# If we are on HP-UX 10.20, we expect an error message to be
> -# printed if we type "catch vfork" at the gdb gdb_prompt. This is
> -# because on HP-UX 10.20, we cannot catch vfork events.
> -
> set name "set catch vfork, never expected to trigger"
> -
> -if [istarget "hppa*-hp-hpux10.20"] then {
> - gdb_test "catch vfork" \
> - "Catch of vfork events not supported on HP-UX 10.20..*" \
> - "$name"
> -} else {
> - gdb_test_multiple "catch vfork" "$name" {
> - -re "Catchpoint \[0-9\]* .vfork..*$gdb_prompt $" {
> - pass $name
> - }
> - -re "Catch of vfork not yet implemented.*$gdb_prompt $" {
> - pass $name
> - }
> +gdb_test_multiple "catch vfork" "$name" {
> + -re "Catchpoint \[0-9\]* .vfork..*$gdb_prompt $" {
> + pass $name
> + }
> + -re "Catch of vfork not yet implemented.*$gdb_prompt $" {
> + pass $name
> }
> }
>
> @@ -641,32 +630,20 @@ gdb_test "break marker2" \
> "set breakpoint on to-be-called function"
>
> gdb_test "print marker2(99)" \
> - "The program being debugged stopped while in a function called from GDB.\r\nEvaluation of the expression containing the function\r\n.marker2$proto. will be abandoned.\r\nWhen the function is done executing, GDB will silently stop.*" \
> + "The program being debugged stopped while in a function called from GDB.\r\nEvaluation of the expression containing the function\r\n.marker2. will be abandoned.\r\nWhen the function is done executing, GDB will silently stop.*" \
> "hit breakpoint on called function"

There is a discrepancy I do not understand, here. You removed the $proto
suffix for marker2. proto is empty unless hp_aCC_compiler is non-zero.
I assume that HP ACC is only available on HP-UX, which means it's OK
to remove it here, but then why not remove...

if {$hp_aCC_compiler} {
set proto "\\(int\\)"
} else {
set proto ""
}

... earlier in the test, and all references to proto?

--
Joel