From: Steven Rostedt Date: Fri, 28 Jan 2011 04:16:51 +0000 (-0500) Subject: tracing/filter: Optimize filter by folding the tree X-Git-Tag: v2.6.39-rc1~510^2~39^2~4 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=43cd414552d8137157e926e46361678ea867e476;p=pandora-kernel.git tracing/filter: Optimize filter by folding the tree There are many cases that a filter will contain multiple ORs or ANDs together near the leafs. Walking up and down the tree to get to the next compare can be a waste. If there are several ORs or ANDs together, fold them into a single pred and allocate an array of the conditions that they check. This will speed up the filter by linearly walking an array and can still break out if a short circuit condition is met. Cc: Tom Zanussi Signed-off-by: Steven Rostedt --- Reading git-diff-tree failed