lkml.org 
[lkml]   [2018]   [Mar]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC V3 1/3] perf, tools: Support wildcards on pmu name in dynamic pmu events
On Wed, Mar 07, 2018 at 03:09:08PM -0500, Agustin Vega-Frias wrote:

SNIP

> > > > #include <fnmatch.h>
> > > > +/*
> > > > + * GNU extension, so better define it to 0 for systems such
> > > > + * as Android and Alpine Linux.
> > > > + */
> > > > +#ifndef FNM_EXTMATCH
> > > > +#define FNM_EXTMATCH 0
> > > > +#endif
> > > > #include <linux/compiler.h>
> > > > #include <linux/list.h>
> > > > #include <linux/types.h>
> > >
> > > Hey Jiri,
> > >
> > > The downside is that, while the compilation now works on those
> > > systems, the pattern will not work as intended in them :o(
> > > Let me cook something and send it ASAP.
> >
> > Well, do you think this is really a big problem? Even if we add nice
> > docs?
> >
> > I haven't tested something that works with this syntax on a capable
> > system and then on one that doesn't, to see how it would behave,
> > probably it would say something about a syntax error?
> >
>
> Most likely, yes, it would be flagged as a syntax error in the event name.
> I'd prefer we fix this. I have the new patch ready, do you want me to just
> send you that patch instead of the series?

we could also detect the extension via build features
and have HAVE_FEATURE_ macro defined for it, so we'd
have full functionality on system with its support

but maybe that's little too much for feature this size,
or we can add it later.. now I'd be ok with the limited
functionality as well

jirka

\
 
 \ /
  Last update: 2018-03-07 21:21    [W:0.076 / U:11.112 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site