[2/4] Add emit_less_unsigned test in trace-condition.exp

Message ID 1463504594-4419-2-git-send-email-antoine.tremblay@ericsson.com
State New, archived
Headers

Commit Message

Antoine Tremblay May 17, 2016, 5:03 p.m. UTC
  This patch adds coverage for emit_less_unsigned.

gdb/testsuite/ChangeLog:

	* gdb.trace/trace-condition.exp: Add emit_less_unsigned test.
---
 gdb/testsuite/gdb.trace/trace-condition.exp | 1 +
 1 file changed, 1 insertion(+)
  

Comments

Pedro Alves May 27, 2016, 12:02 p.m. UTC | #1
On 05/17/2016 06:03 PM, Antoine Tremblay wrote:


> diff --git a/gdb/testsuite/gdb.trace/trace-condition.exp b/gdb/testsuite/gdb.trace/trace-condition.exp
> index fa031ba..f5b59b1 100644
> --- a/gdb/testsuite/gdb.trace/trace-condition.exp
> +++ b/gdb/testsuite/gdb.trace/trace-condition.exp
> @@ -151,6 +151,7 @@ foreach trace_command { "trace" "ftrace" } {
>      test_tracepoints $trace_command "(0xaaaaaaaa ^ 0x55555555) == 0xffffffff" 10
>      test_tracepoints $trace_command "~0xaaaaaaaa == 0x55555555" 10
>      test_tracepoints $trace_command "21 < 42" 10
> +    test_tracepoints $trace_command "21U < 42U" 10

Shouldn't we add:

    test_tracepoints $trace_command "42U < 21U" 0

?

Thanks,
Pedro Alves
  
Antoine Tremblay May 27, 2016, 12:36 p.m. UTC | #2
Pedro Alves writes:

> On 05/17/2016 06:03 PM, Antoine Tremblay wrote:
>
>
>> diff --git a/gdb/testsuite/gdb.trace/trace-condition.exp b/gdb/testsuite/gdb.trace/trace-condition.exp
>> index fa031ba..f5b59b1 100644
>> --- a/gdb/testsuite/gdb.trace/trace-condition.exp
>> +++ b/gdb/testsuite/gdb.trace/trace-condition.exp
>> @@ -151,6 +151,7 @@ foreach trace_command { "trace" "ftrace" } {
>>      test_tracepoints $trace_command "(0xaaaaaaaa ^ 0x55555555) == 0xffffffff" 10
>>      test_tracepoints $trace_command "~0xaaaaaaaa == 0x55555555" 10
>>      test_tracepoints $trace_command "21 < 42" 10
>> +    test_tracepoints $trace_command "21U < 42U" 10
>
> Shouldn't we add:
>
>     test_tracepoints $trace_command "42U < 21U" 0
>
> ?


Yes as previous comments, will do.
  

Patch

diff --git a/gdb/testsuite/gdb.trace/trace-condition.exp b/gdb/testsuite/gdb.trace/trace-condition.exp
index fa031ba..f5b59b1 100644
--- a/gdb/testsuite/gdb.trace/trace-condition.exp
+++ b/gdb/testsuite/gdb.trace/trace-condition.exp
@@ -151,6 +151,7 @@  foreach trace_command { "trace" "ftrace" } {
     test_tracepoints $trace_command "(0xaaaaaaaa ^ 0x55555555) == 0xffffffff" 10
     test_tracepoints $trace_command "~0xaaaaaaaa == 0x55555555" 10
     test_tracepoints $trace_command "21 < 42" 10
+    test_tracepoints $trace_command "21U < 42U" 10
     test_tracepoints $trace_command "42 <= 42" 10
     test_tracepoints $trace_command "42 >= 42" 10
     test_tracepoints $trace_command "42 > 21" 10