This is the mail archive of the gdb-patches@sourceware.org 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]
Other format: [Raw text]

Re: [PATCH 1/4] Move trace conditions tests from ftrace.exp to trace-condition.exp


On 05/17/2016 06:03 PM, Antoine Tremblay wrote:
> This patch moves conditional tests that were done in ftrace.exp to
> trace-conditon.exp.

Typo conditon.exp.

> 
> Note that emit_ref is now tested by the anarg local variable there is no
> need to test the register directly.
> 
> The test coverage remains the same.

How did you determine it that it's the same?

E.g., seems like the <, >, etc., conditions in ftrace.exp use a 
global variable, while the trace-condition.exp ones use constants.

I also notice that all tests in trace-condition.exp expect 10 frames
to be collected.  If a condition's handling is broken and the
tracepoints ends up unconditional, will we ever notice?

Seems like we have counter-cases using the same operators
but that eval false, like (relative to your patch):

    test_tracepoints $trace_command "21 == 21" 10
+    test_tracepoints $trace_command "21 == 22" 0
    test_tracepoints $trace_command "21 != 42" 10
+    test_tracepoints $trace_command "21 != 21" 0

Thanks,
Pedro Alves


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