> * Peter Zijlstra (
a.p.zijlstra@chello.nl) wrote:
> > On Tue, 2008-04-15 at 08:32 -0400, Mathieu Desnoyers wrote:
> > > * Peter Zijlstra (
a.p.zijlstra@chello.nl) wrote:
> > > > On Tue, 2008-04-15 at 17:23 +0530, K. Prasad wrote:
> > > >
> > > > > + trace_mark(futex_wait_called, "uaddr:%p fshared:%p val:%u "
> > > > > + "abs_time:%p bitset:%d",
> > > > > + uaddr, fshared, val, abs_time, bitset);
> > > >
> > > > This is some seriuosly ugly looking gunk, why would we want stuff like
> > > > that scattered across the code?
> > > >
> > >
> > > I don't really see how it differs so much from printks, which kernel
> > > developers are already familiar with.
> >
> > Which never last longer than the debug session and are never exposed to
> > enterprise kABI crap.
> >
> > > > What is wrong with a few simple hooks like:
> > > >
> > > > trace_futex_wait(uaddr, fshares, val, abs_time, bitset);
> > > >
> > > > and then deal with that.
> > > >
> > >
> > > If any of your variable type changes, then you are exporting an unknown
> > > data structure to user-space. _That_ would break a userspace tracer
> > > whenever you change any of these kernel variables and you don't want
> > > that.
> >
> > trace_futex_wait()'s signature would make the compiler issue a complaint
> > when the arguments suddenly changes type, no?
> >
>
> Yes, but then you would have to create new code for each event you want
> to trace. In the end, it would increase the icache footprint
> considerably and would also make addition of new events cumbersome.