public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] testsuite: disable break-interp.exp for Arm buildbot
@ 2019-08-09  9:21 Alan Hayward
  2019-08-09 17:22 ` Pedro Alves
  0 siblings, 1 reply; 4+ messages in thread
From: Alan Hayward @ 2019-08-09  9:21 UTC (permalink / raw)
  To: gdb-patches; +Cc: nd, Alan Hayward

[As a side note, the Arm buildbot worker is now up and running!]

[The better solution here would be to fix stop on solib, but I have no idea
 why it's failing (yet working on a real Arm box, which is where it really
 matters), for the moment I'd rather get buildbot working.]

Add is_aarch32_on_aarch64_target to detect an Arm target that is running on
AArch64 (for example, in an AArch64 docker).  The key here is that the target
will be Arm, but uname will still report AArch64.

Use this test to disable gdb.base/break-interp.exp, as this test currently
generates 132 sequential timeouts.

This change will enable the Arm buildbot worker setup to run the testsuite
within a reasonable timeframe.

gdb/testsuite/ChangeLog:

2019-08-09  Alan Hayward  <alan.hayward@arm.com>

	* gdb.base/break-interp.exp: Skip if is AArch32 on AArch64 target.
	* lib/future.exp (gdb_find_uname): New procedure.
	* lib/gdb.exp (is_aarch32_on_aarch64_target): Likewise.
---
 gdb/testsuite/gdb.base/break-interp.exp |  3 ++-
 gdb/testsuite/lib/future.exp            | 10 ++++++++++
 gdb/testsuite/lib/gdb.exp               | 20 ++++++++++++++++++++
 3 files changed, 32 insertions(+), 1 deletion(-)

diff --git a/gdb/testsuite/gdb.base/break-interp.exp b/gdb/testsuite/gdb.base/break-interp.exp
index d6da653529..6a366db49f 100644
--- a/gdb/testsuite/gdb.base/break-interp.exp
+++ b/gdb/testsuite/gdb.base/break-interp.exp
@@ -15,7 +15,8 @@
 
 # This test only works on GNU/Linux.
 if { ![isnative] || [is_remote host] || [use_gdb_stub]
-     || ![istarget *-linux*] || [skip_shlib_tests]} {
+     || ![istarget *-linux*] || [skip_shlib_tests]
+     || [is_aarch32_on_aarch64_target]} {
     continue
 }
 
diff --git a/gdb/testsuite/lib/future.exp b/gdb/testsuite/lib/future.exp
index 122e652858..d43dd95904 100644
--- a/gdb/testsuite/lib/future.exp
+++ b/gdb/testsuite/lib/future.exp
@@ -172,6 +172,16 @@ proc gdb_find_eu-unstrip {} {
     return $eu_unstrip
 }
 
+proc gdb_find_uname {} {
+    global UNAME_FOR_TARGET
+    if [info exists UNAME_FOR_TARGET] {
+	set uname $UNAME_FOR_TARGET
+    } else {
+	set uname [transform uname]
+    }
+    return $uname
+}
+
 proc gdb_default_target_compile {source destfile type options} {
     global target_triplet
     global tool_root_dir
diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp
index edc8dfcdfd..ffdb763104 100644
--- a/gdb/testsuite/lib/gdb.exp
+++ b/gdb/testsuite/lib/gdb.exp
@@ -2629,6 +2629,26 @@ proc is_aarch64_target {} {
     return [expr ![is_aarch32_target]]
 }
 
+# Return 1 if this target is AArch32/Arm running on AArch64.
+
+proc is_aarch32_on_aarch64_target {} {
+    if { ![istarget "arm*-*-*"] } {
+	return 0
+    }
+
+    set uname_program [gdb_find_uname]
+    set command "exec $uname_program -m"
+    verbose -log "command is $command"
+    set result [catch $command output]
+    verbose -log "result is $result"
+    verbose -log "output is $output"
+    if {$result == 0 && [string match $output "aarch64"]} {
+	return 1
+    }
+    return 0
+}
+
+
 # Return 1 if displaced stepping is supported on target, otherwise, return 0.
 proc support_displaced_stepping {} {
 
-- 
2.20.1 (Apple Git-117)

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

end of thread, other threads:[~2019-08-15 17:49 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-09  9:21 [PATCH] testsuite: disable break-interp.exp for Arm buildbot Alan Hayward
2019-08-09 17:22 ` Pedro Alves
2019-08-12 15:53   ` Alan Hayward
2019-08-15 17:49     ` Pedro Alves

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).