public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
From: "vries at gcc dot gnu.org" <sourceware-bugzilla@sourceware.org>
To: gdb-prs@sourceware.org
Subject: [Bug testsuite/30383] New: [gdb/testsuite, -std=gnu90] FAIL: gdb.opt/inline-locals.exp: info locals above bar 2
Date: Sun, 23 Apr 2023 08:57:02 +0000 [thread overview]
Message-ID: <bug-30383-4717@http.sourceware.org/bugzilla/> (raw)
https://sourceware.org/bugzilla/show_bug.cgi?id=30383
Bug ID: 30383
Summary: [gdb/testsuite, -std=gnu90] FAIL:
gdb.opt/inline-locals.exp: info locals above bar 2
Product: gdb
Version: HEAD
Status: NEW
Severity: normal
Priority: P2
Component: testsuite
Assignee: unassigned at sourceware dot org
Reporter: vries at gcc dot gnu.org
Target Milestone: ---
Using this patch and gcc 7.5.0 we have:
...
diff --git a/gdb/testsuite/gdb.opt/inline-locals.exp
b/gdb/testsuite/gdb.opt/inline-locals.exp
index 3980f4ddd2a..60f62eca90d 100644
--- a/gdb/testsuite/gdb.opt/inline-locals.exp
+++ b/gdb/testsuite/gdb.opt/inline-locals.exp
@@ -16,7 +16,7 @@
standard_testfile .c inline-markers.c
if {[prepare_for_testing "failed to prepare" $testfile \
- [list $srcfile $srcfile2] {debug additional_flags=-Winline}]} {
+ [list $srcfile $srcfile2] {debug additional_flags=-Winline
additional_flags=-std=gnu90}]} {
return -1
}
...
we have:
...
FAIL: gdb.opt/inline-locals.exp: info locals above bar 2
FAIL: gdb.opt/inline-locals.exp: info locals above bar 3
FAIL: gdb.opt/inline-locals.exp: print local 3
FAIL: gdb.opt/inline-locals.exp: scoped info locals at bp for locals 1
FAIL: gdb.opt/inline-locals.exp: scoped info locals at bp for locals 2
FAIL: gdb.opt/inline-locals.exp: scoped info locals at bp for locals 3
...
First sign of trouble is:
...
(gdb) PASS: gdb.opt/inline-locals.exp: func1 inlined 2
info locals^M
array = {0 <repeats 58 times>, 4195280, 0, -11296, 32767, 0, 0}^M
array = <optimized out>^M
(gdb) FAIL: gdb.opt/inline-locals.exp: info locals above bar 2
...
The problem seems to be that there's a difference of option about the address
of array:
...
(gdb) s
func1 (arg1=0) at /data/vries/gdb/src/gdb/testsuite/gdb.opt/inline-locals.c:43
43 init_array (array, 64);
(gdb) p &array
$1 = (int (*)[64]) 0x7fffffffda50
(gdb) s
init_array (array=0x7fffffffda30, n=64) at
/data/vries/gdb/src/gdb/testsuite/gdb.opt/inline-locals.c:36
36 for (i = 0; i < n; ++i)
...
Then with gcc 8.2.1:
...
FAIL: gdb.opt/inline-locals.exp: scoped info locals at bp for locals 1
FAIL: gdb.opt/inline-locals.exp: scoped info locals at bp for locals 2
...
and all clear with gcc 9.3.1.
--
You are receiving this mail because:
You are on the CC list for the bug.
reply other threads:[~2023-04-23 8:57 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=bug-30383-4717@http.sourceware.org/bugzilla/ \
--to=sourceware-bugzilla@sourceware.org \
--cc=gdb-prs@sourceware.org \
/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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).