From: Jim Blandy <jimb@zwingli.cygnus.com>
To: Michael Elizabeth Chastain <chastain@cygnus.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFC] testsuite/gdb.base/arithmet.exp: re-write
Date: Tue, 12 Jun 2001 07:55:00 -0000 [thread overview]
Message-ID: <npzobdycf0.fsf@zwingli.cygnus.com> (raw)
In-Reply-To: <200106120454.VAA09428@bosch.cygnus.com>
That sounds totally fine to me --- thanks for explaining it.
I'm not a maintainer of the test suite, but I would be happy to see
this change go in.
Michael Elizabeth Chastain <chastain@cygnus.com> writes:
>
> Jim Blandy writes:
>
> > Can you characterize the differences (if any) between the operations
> > GDB executes in the old and proposed new versions?
>
> arithmet.exp operates on a program with four variables, "x" "y" "z" and "w".
> It assigns values to those variables and then does a lot of simple
> add-subtract-multiply-divide operations to check operator precedence
> and associativity.
>
> The tests themselves are already unique (the same expression is never
> used twice) so my new version executes the same tests as the old version.
>
> The assignment statements are different. The old version has a lot of
> alternation between "set variable z=2", "set variable z=3", and
> "set variable z=2" again. My new version has two groups of
> "set variable" statements and that's it.
>
> I believe that the point of arithmet.exp is to test the expressions,
> not the assignments. If desired, I could do the work in several phases,
> where the first phase is totally operationally compatible (and still
> has duplicate test names), so that people can be comfortable with a
> massive changeover to "gdb_test" and then operational changes can be
> reviewed separately (and much more effectively).
>
> Also, I'm not totally happy with the way that I achieve uniqueness.
> I achieve it quietly by knowing that this kind of code is bad:
>
> gdb_test "set variable z=2" ""
> gdb_test "print x-y-z" "10"
> gdb_test "set variable z=3" ""
> gdb_test "print x-y-z" "9" # oops, duplicate test
>
> So the test script gets influenced by this external constraint that
> doesn't actually get enforced when people make changes. We live with
> it I guess.
>
> Michael
>
next prev parent reply other threads:[~2001-06-12 7:55 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-06-11 21:48 Michael Elizabeth Chastain
2001-06-12 7:55 ` Jim Blandy [this message]
-- strict thread matches above, loose matches on Subject: below --
2001-06-12 9:42 Michael Elizabeth Chastain
2001-06-10 16:57 Michael Elizabeth Chastain
2001-06-11 7:31 ` Fernando Nasser
2001-06-11 17:55 ` Jim Blandy
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=npzobdycf0.fsf@zwingli.cygnus.com \
--to=jimb@zwingli.cygnus.com \
--cc=chastain@cygnus.com \
--cc=gdb-patches@sources.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