This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA PATCH 3/3 V3] Testcase for pascal/17815
- From: Pedro Alves <palves at redhat dot com>
- To: Pierre Muller <pierre dot muller at ics-cnrs dot unistra dot fr>
- Cc: "'gdb-patches'" <gdb-patches at sourceware dot org>
- Date: Fri, 23 Jan 2015 10:58:46 +0000
- Subject: Re: [RFA PATCH 3/3 V3] Testcase for pascal/17815
- Authentication-results: sourceware.org; auth=none
- References: <54ae4586 dot 01e3440a dot 7b06 dot fffff844SMTPIN_ADDED_BROKEN at mx dot google dot com> <54AE605A dot 8050308 at redhat dot com> <54ae7f9f dot c323460a dot 36ed dot ffffff30SMTPIN_ADDED_BROKEN at mx dot google dot com> <54AE8914 dot 4010507 at redhat dot com> <54ae911b dot 85e3440a dot 1d96 dot 5ffdSMTPIN_ADDED_BROKEN at mx dot google dot com> <54AFB2E5 dot 5080307 at redhat dot com> <54afff6b dot ee8d440a dot 16ee dot ffffb424SMTPIN_ADDED_BROKEN at mx dot google dot com> <54C0F10E dot 60402 at redhat dot com> <002c01d036a2$7015e7b0$5041b710$ at muller@ics-cnrs.unistra.fr>
On 01/23/2015 12:20 AM, Pierre Muller wrote:
> Hi Pedro,
>
>> -----Message d'origine-----
>> De : gdb-patches-owner@sourceware.org [mailto:gdb-patches-
>> owner@sourceware.org] De la part de Pedro Alves
>> Envoyé : jeudi 22 janvier 2015 13:46
>> À : Pierre Muller
>> Cc : 'gdb-patches'
>> Objet : Re: [RFA PATCH 3/3] Testcase for pascal/17815
>>
>> Thanks for adding the test case.
>>
>> On 01/09/2015 04:18 PM, Pierre Muller wrote:
>>> This adds the testcase for pascal/17815 bug report.
>>>
>>>
>>> gdb/testsuite/Changelog entry:
>>>
>>> 2015-01-09 Pierre Muller <muller@sourceware.org>
>>>
>>> gdb.pascal/gdb17815.pas: New file.
>>> gdb.pascal/gdb17815.exp: New file.
>>
>> Missing '*'.
> Fixed below.
>
>> Can you please pick a more descriptive name for the file?
>> One that suggests what's being tested, rather than a bug
>> number is ideal. E.g., gdb.pascal/case-insensitive.{exp|pas}.
>
> I used your suggestion, but this is not
> really a general case insensitiveness test...
You mean, it's just for symbols, rather than filesystems, etc?
gdb.pascal/case-insensitive-symbols.{exp|pas} would be my
suggestion then. But these are just suggestions. Feel free to
pick something else.
>
> No, I tried and using runto_main,
> I got only failures, because it apparently did not stop
> at all on the breakpoint set earlier...
> Is there some code inside runto_main that
> deleted previously installed breakpoints?
Yes, it's the first thing runto_main -> runto does.
Why not just set the breakpoints after reaching main?
Or simpler still, use "runto $foo" directly, like:
set bp_location [gdb_get_line_number "set breakpoint here"]
if { ![runto ${srcfile}:${bp_location}] } {
return 0
}
Or simpler still, just:
if { ![runto "check"] } {
return 0
}
Assuming that to set a breakpoint on the "check" function,
you'd do "break check" in GDB. If not, replace "check" with
whatever linespec would be used instead.
The patch looks good to me.
Thanks,
Pedro Alves