Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Alan Hayward <Alan.Hayward@arm.com>
To: "gdb-patches@sourceware.org" <gdb-patches@sourceware.org>
Cc: nd <nd@arm.com>, Alan Hayward <Alan.Hayward@arm.com>
Subject: [PATCH] testsuite: disable break-interp.exp for Arm buildbot
Date: Fri, 09 Aug 2019 09:21:00 -0000	[thread overview]
Message-ID: <20190809092128.94802-1-alan.hayward@arm.com> (raw)

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


             reply	other threads:[~2019-08-09  9:21 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-09  9:21 Alan Hayward [this message]
2019-08-09 17:22 ` Pedro Alves
2019-08-12 15:53   ` Alan Hayward
2019-08-15 17:49     ` Pedro Alves

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190809092128.94802-1-alan.hayward@arm.com \
    --to=alan.hayward@arm.com \
    --cc=gdb-patches@sourceware.org \
    --cc=nd@arm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox