All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alexei Starovoitov <ast@plumgrid.com>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
	Ingo Molnar <mingo@kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>,
	Theodore Tso <tytso@mit.edu>
Subject: Re: [PATCH 3/3] ftracetests: Add test to test event filter logic
Date: Tue, 2 Dec 2014 22:22:16 -0800	[thread overview]
Message-ID: <CAMEtUuyzfKYVSJUra6nib-wWYQ91uEPC6mizF9PLpg+5Kjb+3w@mail.gmail.com> (raw)
In-Reply-To: <20141203032106.156623189@goodmis.org>

On Tue, Dec 2, 2014 at 7:13 PM, Steven Rostedt <rostedt@goodmis.org> wrote:
> From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org>
>
> Add a test to test the event filter logic. It currently tests the
> following filters against sched:sched_switch event.
>
>    ( prev_pid != 0 )
>    ( prev_pid == 0 )
>    ( prev_pid < 100 )
>    ( prev_pid <= $$ )
>    ( prev_pid > 100 )
>    ( prev_pid >= $$ )
>   ! ( prev_pid != 0 )
>   ! ( prev_pid == 0 )
>   ! ( prev_pid < 100 )
>   ! ( prev_pid <= $$ )
>   ! ( prev_pid > 100 )
>   ! ( prev_pid >= $$ )
>    ( prev_pid != 0 && next_pid > 10 )
>    ( prev_pid != 0 || next_pid > 10 )
>   ! ( prev_pid != 0 && next_pid > 10 )
>   ! ( prev_pid != 0 || next_pid > 10 )
>    ( prev_pid & 1 )
>    ( prev_pid & 2 )
>    ( prev_pid & 4 )
>    ( prev_pid & 8 )
>    ( prev_pid & 16 )
>   ! ( prev_pid & 1 )
>   ! ( prev_pid & 2 )
>   ! ( prev_pid & 4 )
>   ! ( prev_pid & 8 )
>   ! ( prev_pid & 16 )
>    ( next_comm ~ "ftrace-test-fil" )
>    ( next_comm != "ftrace-test-fil" )
>   ! ( next_comm ~ "ftrace-test-fil" )
>   ! ( next_comm != "ftrace-test-fil" )

thanks for the tests!
Since you're adding full support for 'not',
I think would be good to have few more tests
where ! is not a top node. Like:
(prev_pid != 0 && !(next_pid & 2))
and another one with ! at multiple levels, like:
(prev_pid != 0 && !(next_pid != 2 && !(prev_pid > 3)))
... or reject them during parsing.

  reply	other threads:[~2014-12-03  6:22 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-03  3:13 [PATCH 0/3] tracing: Add event filter logic for !(...) Steven Rostedt
2014-12-03  3:13 ` [PATCH 1/3] tracing: Add NOT to filtering logic Steven Rostedt
2014-12-03  3:13 ` [PATCH 2/3] tracing: Allow NOT to filter AND and OR clauses Steven Rostedt
2014-12-03  3:13 ` [PATCH 3/3] ftracetests: Add test to test event filter logic Steven Rostedt
2014-12-03  6:22   ` Alexei Starovoitov [this message]
2014-12-03  8:40     ` Steven Rostedt
2014-12-03 17:53       ` Alexei Starovoitov
2014-12-03 18:01         ` Steven Rostedt
2014-12-03  9:26   ` Masami Hiramatsu
2014-12-03  9:34     ` Steven Rostedt
2014-12-03 16:20       ` Steven Rostedt
2014-12-04  8:12         ` Masami Hiramatsu
2014-12-03 23:14       ` Masami Hiramatsu
2014-12-03 23:29         ` Steven Rostedt
2014-12-04  3:18         ` [PATCH v2] " Steven Rostedt
2014-12-04 10:06           ` Masami Hiramatsu
2014-12-04 12:04             ` Steven Rostedt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAMEtUuyzfKYVSJUra6nib-wWYQ91uEPC6mizF9PLpg+5Kjb+3w@mail.gmail.com \
    --to=ast@plumgrid.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masami.hiramatsu.pt@hitachi.com \
    --cc=mingo@kernel.org \
    --cc=rostedt@goodmis.org \
    --cc=tytso@mit.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.