Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 234485
b: refs/heads/master
c: 5571927
h: refs/heads/master
i:
  234483: 2613c20
v: v3
  • Loading branch information
Steven Rostedt authored and Steven Rostedt committed Feb 8, 2011
1 parent f54744a commit 6bbbec8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 61e9dea20e1ada886cc49a9ec6fe3c6ac0de7324
refs/heads/master: 55719274188f13cff9e3bd11fdd4c0e7617cd03d
12 changes: 9 additions & 3 deletions trunk/kernel/trace/trace_events_filter.c
Original file line number Diff line number Diff line change
Expand Up @@ -426,9 +426,15 @@ int filter_match_preds(struct event_filter *filter, void *rec)
pred->parent, &move);
continue;
case MOVE_UP_FROM_LEFT:
/* Check for short circuits */
if ((match && pred->op == OP_OR) ||
(!match && pred->op == OP_AND)) {
/*
* Check for short circuits.
*
* Optimization: !!match == (pred->op == OP_OR)
* is the same as:
* if ((match && pred->op == OP_OR) ||
* (!match && pred->op == OP_AND))
*/
if (!!match == (pred->op == OP_OR)) {
if (pred == root)
break;
pred = get_pred_parent(pred, preds,
Expand Down

0 comments on commit 6bbbec8

Please sign in to comment.