Re: [PATCH 1/7] New test case gdb.trace/signal.exp

Pedro Alves
2016-04-26T12:57:37Z

On 04/22/2016 11:52 AM, Yao Qi wrote:
> Pedro Alves <palves@redhat.com> writes:
>
>>> +# Record the hit times of each tracepoint in this array.
>>> +array set tracepoint_hits { }
>>> +
>>> +set test "tfind 0"
>>> +gdb_test_multiple $test $test {
>>
>> Why do we need this separate "tfind 0" step? I'd think the
>> "tfind" loop below would be sufficient?
>
> I don't know the first "tfind" can find the first snapshot , and I think
> "tfind 0" should be the first one in all other "tfind X" commands.
>
> The usage like this is not documented.

I didn't know it wasn't documented. I think the testsuite
uses it extensively.

> In current doc:
>
> tfind
>
> No argument means find the next trace snapshot.
>
> We probably need to change the doc to
>
> No argument means find the next trace snapshot or find the first
> one if no trace snapshot is selected.

Yeah.

Thanks,
Pedro Alves