Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: gdb-patches@sourceware.org
Cc: Sergio Durigan Junior <sergiodj@redhat.com>
Subject: [testsuite patch] Fix false FAIL in stap-probe.exp
Date: Sun, 11 Sep 2016 14:04:00 -0000	[thread overview]
Message-ID: <20160911140413.GA557@host1.jankratochvil.net> (raw)

[-- Attachment #1: Type: text/plain, Size: 925 bytes --]

Hi,

gcc-6.2.1-1.fc26.x86_64

    # Set a breakpoint with multiple probe locations.
    gdb_test "break -pstap test:two" \
        "Breakpoint \[0-9\]+ at $hex.*2 locations.*" \
        "set multi-location probe breakpoint (probe two)"
break -pstap test:two^M
Breakpoint 2 at 0x4004e0^M
(gdb) FAIL: gdb.base/stap-probe.exp: without semaphore, optimized: set multi-location probe breakpoint (probe two)

    # Set a breakpoint with multiple probe locations.
    # In this scenario, we may expect more than 2 locations because of
    # the optimizations (inlining, loop unrolling, etc).
    gdb_test "break -pstap test:two" \
        "Breakpoint .* at $hex.*\[0-9\]+ locations.*" \
        "set multi-location probe breakpoint (probe two)"
break -pstap test:two^M
Breakpoint 2 at 0x4004e0^M
(gdb) FAIL: gdb.base/stap-probe.exp: with semaphore, optimized: set multi-location probe breakpoint (probe two)

OK for check-in?


Jan

[-- Attachment #2: 1 --]
[-- Type: text/plain, Size: 841 bytes --]

gdb/testsuite/ChangeLog
2016-09-11  Jan Kratochvil  <jan.kratochvil@redhat.com>

	* gdb.base/stap-probe.exp (stap_test_no_debuginfo): Try to use
	-fno-ipa-icf.

diff --git a/gdb/testsuite/gdb.base/stap-probe.exp b/gdb/testsuite/gdb.base/stap-probe.exp
index df46e80..9258926 100644
--- a/gdb/testsuite/gdb.base/stap-probe.exp
+++ b/gdb/testsuite/gdb.base/stap-probe.exp
@@ -97,8 +97,11 @@ proc stap_test_no_debuginfo {exec_name {arg ""}} {
     global testfile hex
 
     if {[prepare_for_testing ${testfile}.exp ${exec_name} ${testfile}.c \
-	   {$arg nodebug optimize=-O2}]} {
-	return -1
+	   {$arg nodebug optimize=-O2 "additional_flags=-fno-ipa-icf"}]} {
+	if {[prepare_for_testing ${testfile}.exp ${exec_name} ${testfile}.c \
+	       {$arg nodebug optimize=-O2}]} {
+	    return -1
+	}
     }
 
     if {[runto "-pstap test:user"]} {

             reply	other threads:[~2016-09-11 14:04 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-11 14:04 Jan Kratochvil [this message]
2016-09-11 17:43 ` Sergio Durigan Junior
2016-09-11 17:56   ` Jan Kratochvil
2016-09-11 20:57     ` Sergio Durigan Junior
2016-09-11 21:15       ` Jan Kratochvil
2016-09-12  4:22         ` Sergio Durigan Junior

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=20160911140413.GA557@host1.jankratochvil.net \
    --to=jan.kratochvil@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=sergiodj@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