Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: "Metzger, Markus T" <markus.t.metzger@intel.com>
Cc: Joel Brobecker <brobecker@adacore.com>,
	       "gdb-patches@sourceware.org" <gdb-patches@sourceware.org>,
	       "Pedro Alves (palves@redhat.com)" <palves@redhat.com>
Subject: Re: [patch] Fix cleanup in finish_command
Date: Fri, 21 Jun 2013 12:56:00 -0000	[thread overview]
Message-ID: <20130621114313.GA5381@host2.jankratochvil.net> (raw)
In-Reply-To: <A78C989F6D9628469189715575E55B230A96FF66@IRSMSX104.ger.corp.intel.com>

On Fri, 21 Jun 2013 10:03:21 +0200, Metzger, Markus T wrote:
> > Unrelated:
> > There is testcase FAILing randomly, reproducible with "read1.so" from:
> > 	http://sourceware.org/bugzilla/show_bug.cgi?id=12649
> > Running ./gdb.btrace/exception.exp ...
> > FAIL: gdb.btrace/exception.exp: exception - flat (timeout)
> 
> I do not think that this is an actual issue.  It runs into a timeout because
> there is so much memory to read.
> 
> When I add to my board file:
> 
> 	set_board_info gdb,timeout 8000
> 
> it takes a very long time, but the test eventually passes.

BTW the testcase is still not right, sometimes it fails due to:
	ERROR: internal buffer is full.
	ERROR: internal buffer is full.

(This is why I tried the "read1" reproducer for it...)

One can either increase the expect buffer size or rather use appropriate
lib/gdb.exp function for it.

To be just merged into the patchset I think.


Regards,
Jan


diff --git a/gdb/testsuite/gdb.btrace/exception.exp b/gdb/testsuite/gdb.btrace/exception.exp
index a8da2b0..430c84b 100644
--- a/gdb/testsuite/gdb.btrace/exception.exp
+++ b/gdb/testsuite/gdb.btrace/exception.exp
@@ -44,24 +44,28 @@ gdb_test_no_output "record btrace"
 gdb_continue_to_breakpoint "cont to $bp_2" ".*$srcfile:$bp_2.*"
 
 # show the flat branch trace
-gdb_test "record function-call-history 1" "
+send_gdb "record function-call-history 1\n"
+gdb_expect_list "exception - flat" "\r\n$gdb_prompt $" { "\r
 1\tmain\\(\\)\r
 2\ttest\\(\\)\r
 3\tfoo\\(\\)\r
 4\tbar\\(\\)\r
 5\tbad\\(\\)\r
-.*\r
-\[0-9\]*\ttest\\(\\)" "exception - flat"
+"
+    "\r\n\[0-9\]*\ttest\\(\\)"
+}
 
 # show the branch trace with calls indented
 #
 # here we see a known bug that the indentation starts at level 1 with
 # two leading spaces instead of level 0 without leading spaces.
-gdb_test "record function-call-history /c 1" "
+send_gdb "record function-call-history /c 1\n"
+gdb_expect_list "exception - calls indented" "\r\n$gdb_prompt $" { "\r
 1\tmain\\(\\)\r
 2\t  test\\(\\)\r
 3\t    foo\\(\\)\r
 4\t      bar\\(\\)\r
 5\t        bad\\(\\)\r
-.*\r
-\[0-9\]*\t  test\\(\\)" "exception - calls indented"
+"
+    "\r\n\[0-9\]*\t  test\\(\\)"
+}


  parent reply	other threads:[~2013-06-21 11:43 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-19 21:42 Jan Kratochvil
2013-06-20 14:42 ` Jan Kratochvil
2013-06-20 15:26   ` Joel Brobecker
2013-06-20 15:37     ` Metzger, Markus T
2013-06-20 16:45       ` Jan Kratochvil
2013-06-21  8:14         ` Metzger, Markus T
2013-06-21  8:23           ` Jan Kratochvil
2013-06-21  8:25             ` Metzger, Markus T
2013-07-02 14:50               ` Metzger, Markus T
2013-06-21 12:56           ` Jan Kratochvil [this message]
2013-06-20 16:06     ` 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=20130621114313.GA5381@host2.jankratochvil.net \
    --to=jan.kratochvil@redhat.com \
    --cc=brobecker@adacore.com \
    --cc=gdb-patches@sourceware.org \
    --cc=markus.t.metzger@intel.com \
    --cc=palves@redhat.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