public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [pushed 0/5] [gdb/testsuite] Fix remote host issues in gdb.arch tests
@ 2023-03-15 15:38 Tom de Vries
  2023-03-15 15:38 ` [pushed 1/5] [gdb/testsuite] Fix gdb.arch/amd64*.exp with local-remote-host-native.exp Tom de Vries
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Tom de Vries @ 2023-03-15 15:38 UTC (permalink / raw)
  To: gdb-patches

I ran the gdb.arch test-cases on x86_64-linux with various
host/target boards from gdb/testsuite/boards and fixed issues, most of which
had to do with remote host testing.

Results after the fixes:
...
$ ./test-all.sh
 HOST/TARGET: local
 # of expected failures          2
 # of expected passes            913
 # of unsupported tests          118
 HOST: local, TARGET: native-gdbserver
 # of expected failures          1
 # of expected passes            926
 # of unsupported tests          117
 HOST: local, TARGET: native-extended-gdbserver
 # of expected failures          1
 # of expected passes            926
 # of unsupported tests          117
 HOST: local, TARGET: native-stdio-gdbserver
 # of expected failures          1
 # of expected passes            926
 # of unsupported tests          117
 HOST: local, TARGET: remote-gdbserver-on-localhost
 # of expected failures          1
 # of expected passes            780
 # of unsupported tests          119
 HOST: local, TARGET: remote-stdio-gdbserver
 # of expected failures          1
 # of expected passes            927
 # of unsupported tests          117
 HOST: local, TARGET: remote-stdio-gdbserver-remotedir
 # of expected failures          1
 # of expected passes            927
 # of unsupported tests          117
 HOST: local-remote-host-notty, TARGET: native-gdbserver
 FAIL: gdb.arch/ftrace-insn-reloc.exp: IPA loaded
 # of expected failures          1
 # of expected passes            777
 # of unexpected failures        1
 # of unsupported tests          119
 # of untested testcases         1
 HOST: local-remote-host-notty, TARGET: native-extended-gdbserver
 FAIL: gdb.arch/ftrace-insn-reloc.exp: IPA loaded
 # of expected failures          1
 # of expected passes            777
 # of unexpected failures        1
 # of unsupported tests          119
 # of untested testcases         1
 HOST: local-remote-host-notty, TARGET: native-stdio-gdbserver
 FAIL: gdb.arch/ftrace-insn-reloc.exp: IPA loaded
 # of expected failures          1
 # of expected passes            777
 # of unexpected failures        1
 # of unsupported tests          119
 # of untested testcases         1
 HOST: local-remote-host-notty, TARGET: remote-gdbserver-on-localhost
 # of expected failures          1
 # of expected passes            711
 # of unsupported tests          120
 HOST: local-remote-host-notty, TARGET: remote-stdio-gdbserver
 # of expected failures          1
 # of expected passes            788
 # of unsupported tests          119
 HOST: local-remote-host-notty, TARGET: remote-stdio-gdbserver-remotedir
 FAIL: gdb.arch/ftrace-insn-reloc.exp: IPA loaded
 # of expected failures          1
 # of expected passes            778
 # of unexpected failures        1
 # of unsupported tests          119
 # of untested testcases         1
 HOST: local-remote-host, TARGET: native-gdbserver
 FAIL: gdb.arch/ftrace-insn-reloc.exp: IPA loaded
 # of expected failures          1
 # of expected passes            777
 # of unexpected failures        1
 # of unsupported tests          119
 # of untested testcases         1
 HOST: local-remote-host, TARGET: native-extended-gdbserver
 FAIL: gdb.arch/ftrace-insn-reloc.exp: IPA loaded
 # of expected failures          1
 # of expected passes            777
 # of unexpected failures        1
 # of unsupported tests          119
 # of untested testcases         1
 HOST: local-remote-host, TARGET: native-stdio-gdbserver
 FAIL: gdb.arch/ftrace-insn-reloc.exp: IPA loaded
 # of expected failures          1
 # of expected passes            777
 # of unexpected failures        1
 # of unsupported tests          119
 # of untested testcases         1
 HOST: local-remote-host, TARGET: remote-gdbserver-on-localhost
 # of expected failures          1
 # of expected passes            711
 # of unsupported tests          120
 HOST: local-remote-host, TARGET: remote-stdio-gdbserver
 # of expected failures          1
 # of expected passes            788
 # of unsupported tests          119
 HOST: local-remote-host, TARGET: remote-stdio-gdbserver-remotedir
 FAIL: gdb.arch/ftrace-insn-reloc.exp: IPA loaded
 # of expected failures          1
 # of expected passes            778
 # of unexpected failures        1
 # of unsupported tests          119
 # of untested testcases         1
 HOST/TARGET: local-remote-host-native
 # of expected failures          2
 # of expected passes            776
 # of unsupported tests          120
...

The remaining failure is in test-case gdb.arch/ftrace-insn-reloc.exp, due to
RUNPATH not being set to $ORIGIN due to quoting issues, this WIP patch fixes
that:
...
@@ -4864,7 +4864,11 @@ proc gdb_compile {source dest type options} {
 	    if { $shlib_load } {
 		lappend new_options "libs=-ldl"
 	    }
-	    lappend new_options "ldflags=-Wl,-rpath,\\\$ORIGIN"
+	    if { [is_remote host] } {
+		lappend new_options "ldflags=-Wl,-rpath,\\\\\$ORIGIN"
+	    } else {
+		lappend new_options "ldflags=-Wl,-rpath,\\\$ORIGIN"
+	    }
 	}
     }
     set options $new_options
...

Tested on x86_64-linux.

Tom de Vries (5):
  [gdb/testsuite] Fix gdb.arch/amd64*.exp with
    local-remote-host-native.exp
  [gdb/testsuite] Unset DEBUGINFOD_URLS on remote host
  [gdb/testsuite] Fix gdb.arch/i386-pkru.exp for native-gdbserver
  [gdb/testsuite] Fix gdb.arch/amd64-stap-special-operands.exp for
    remote host
  [gdb/testsuite] Fix re-used exec in gdb.arch/ftrace-insn-reloc.exp

 .../gdb.arch/amd64-entry-value-inline.exp     | 12 +++++++----
 .../amd64-entry-value-param-dwarf5.exp        | 10 +++++++---
 .../gdb.arch/amd64-entry-value-param.exp      | 10 +++++++---
 .../gdb.arch/amd64-entry-value-paramref.exp   |  8 ++++++--
 .../gdb.arch/amd64-stap-special-operands.exp  |  5 +++--
 gdb/testsuite/gdb.arch/amd64-tailcall-ret.exp |  9 +++++++--
 gdb/testsuite/gdb.arch/ftrace-insn-reloc.exp  |  6 ++----
 gdb/testsuite/gdb.arch/i386-pkru.exp          | 15 +++++++++++---
 gdb/testsuite/lib/gdb.exp                     | 20 ++++++++++++++++++-
 9 files changed, 71 insertions(+), 24 deletions(-)


base-commit: 2d5783fad77c2cb9cdcb396d65fe0a60e3d8938b
-- 
2.35.3


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-03-15 15:38 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-15 15:38 [pushed 0/5] [gdb/testsuite] Fix remote host issues in gdb.arch tests Tom de Vries
2023-03-15 15:38 ` [pushed 1/5] [gdb/testsuite] Fix gdb.arch/amd64*.exp with local-remote-host-native.exp Tom de Vries
2023-03-15 15:38 ` [pushed 2/5] [gdb/testsuite] Unset DEBUGINFOD_URLS on remote host Tom de Vries
2023-03-15 15:38 ` [pushed 3/5] [gdb/testsuite] Fix gdb.arch/i386-pkru.exp for native-gdbserver Tom de Vries
2023-03-15 15:38 ` [pushed 4/5] [gdb/testsuite] Fix gdb.arch/amd64-stap-special-operands.exp for remote host Tom de Vries
2023-03-15 15:38 ` [pushed 5/5] [gdb/testsuite] Fix re-used exec in gdb.arch/ftrace-insn-reloc.exp Tom de Vries

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).