From: Joel Brobecker <brobecker@adacore.com>
To: Richard Henderson <rth@redhat.com>
Cc: gdb-patches@gcc.gnu.org
Subject: Re: [testsuite/alpha] Add test for step over fbne instruction
Date: Thu, 26 May 2005 05:02:00 -0000 [thread overview]
Message-ID: <20050526034416.GM1525@adacore.com> (raw)
In-Reply-To: <20050526031128.GA9264@redhat.com>
> Hmm, now that I think about it, one potential problem with this form
> is that we're not correctly testing for branch taken. The scenerio
> is that we expect taken, set the bp on the ret, the branch *isn't*
> taken, but we fall through to the ret anyway.
I think we do test both possibilities. That's because I verify that
we landed on the correct instruction after the stepi:
# Step test, followed by the check that we landed on the expected
# instruction (the testcase should be written in such a way that
# the branch is taken on the first call to this function.
gdb_test "stepi" \
"0x\[0-9a-fA-F\]+.*" \
"stepi on fb$function (first call)"
gdb_test "x /i \$pc" \
"0x\[0-9a-fA-F\]+ <.*>:\[ \t\]+ret\[ \t\]+.*" \
"Check stepi over fb$function stopped on ret"
(I think this is what Daniel was suggesting).
When the branch is not taken, we do the following test:
gdb_test "x /i \$pc" \
"0x\[0-9a-fA-F\]+ <.*>:\[ \t\]+fneg\[ \t\]+.*" \
"Check stepi over fb$function stopped on fneg instruction"
--
Joel
next prev parent reply other threads:[~2005-05-26 3:44 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-25 15:09 Richard Henderson
2005-05-26 3:14 ` Joel Brobecker
2005-05-26 3:27 ` Richard Henderson
2005-05-26 3:41 ` Daniel Jacobowitz
2005-05-26 5:02 ` Joel Brobecker [this message]
2005-05-26 6:04 ` Daniel Jacobowitz
2005-05-28 22:10 ` Daniel Jacobowitz
2005-05-29 2:53 ` Joel Brobecker
-- strict thread matches above, loose matches on Subject: below --
2005-05-20 7:02 Joel Brobecker
2005-05-20 11:31 ` Richard Henderson
2005-05-25 5:15 ` Joel Brobecker
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=20050526034416.GM1525@adacore.com \
--to=brobecker@adacore.com \
--cc=gdb-patches@gcc.gnu.org \
--cc=rth@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