This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [RFA] [PATCH] gdb.base/break.exp


Michael Snyder observes ...

> Would it be worth the effort to define a symbol in the testcase
> that would be unlikely to be duplicated?  Such as maybe
> "gdb_break_test_unique_symbol"?

Mmmm, this is getting into a can of worms.

What happens if a real user issues the "finish" command from "main" and
then then decides "I want to run the program again and break on "main"
this time"?  gdb does something that is correct, but confusing.

Perhaps break.exp is at fault because it issues a "finish" command, which
leaves the program counter in a symbol scope that it does not control,
and then executes other commands with symbol names in them.  That would
imply more work on break.exp than just changing a name.

Perhaps __libc_start_main should be changed so that its first argument
is named "mainp", not "main".  But I do not want to get into libc patches;
that is too far from my task at hand.

Michael, would you be happy with "break marker1" or "break marker5"
or something like that?  break.exp already uses these, and so do a lot of
other gdb test cases.  That is my favorite solution right now.  But I am
not averse to "gdb_break_test_unique_symbol" or "gdb_func_for_clear_test".

I will defer to Michael Snyder's good taste here.

Michael Elizabeth Chastain
<chastain@redhat.com>
"love without fear"

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]