[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20091003113627.GA6366@nowhere>
Date: Sat, 3 Oct 2009 13:36:29 +0200
From: Frederic Weisbecker <fweisbec@...il.com>
To: Steven Rostedt <rostedt@...dmis.org>
Cc: Peter Zijlstra <a.p.zijlstra@...llo.nl>,
Ingo Molnar <mingo@...e.hu>,
LKML <linux-kernel@...r.kernel.org>,
Tom Zanussi <tzanussi@...il.com>,
Li Zefan <lizf@...fujitsu.com>
Subject: Re: [GIT PULL v2] bkl tracepoints + filter regex support
On Sat, Sep 26, 2009 at 06:44:21AM -0400, Steven Rostedt wrote:
>
> Perhaps when we put full perl regex into the kernel (my goal ;-) then we
> should look to keep different kinds of equals.
>
> == - is direct match. Only use of strcmp is needed.
>
> ~ - is globing. We can add a '*' which means match anything.
>
> and if we do add true regex...
>
> =~ could be that. field =~ '^spin.*{lock|unlock}$'
Ok.
I'm personnally fine with it.
> Perl is considered a much better language for regex. It has one of the
> most (if not the most) powerful regex engines. I'm sure recordmcount.pl
> would be much larger if I chose to do it in python. Same goes with
> streamline_config.pl. They both have strong needs for complex regex.
Yeah, python was a joke. I mean I think it's a nice language
but not a syntax for what we want to do. It's an object oriented
language and I guess we don't want to do:
import re
r = re.compile("blah")
m = r.match("string")
m.group(1)
....
:-)
> >
> > More seriously, as I said above, I think most developers are familiar with C
> > syntax, so IMHO this is one of our best possibility.
> >
>
> To avoid the Python vs Perl, I say we stick with sed/awk. That is also a
> requirement for most unix developers.
Yeah I'm fine with it. As long as this is something already familiar
for most users.
Let's then pick ~ for glob and ~= for regex
I'll fix that soon.
Thanks.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists