This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: pre-compiled modules


> > > To help move this along a bit, I've attached a patch that modifies the
> > > systemtap front end to take 2 new options:
> > > 
> > >    -S         Save the compiled module in the current directory
> > 
> > I would prefer to see an option to specify the directory, instead of
> > assuming $PWD.  You could always use '-S .', but some people might want
> > to drop it somewhere else.  Another possibility instead of -S is to just
> > extend the -m option to allow a path.
> 
> That's easy enough to add, but it seems like that 99% of the time I'd
> want it to go in the current directory.
> 
> Anyone else got any opinions?

The output compiled module is the single .ko file, right?  That being the
case, I think what makes the most sense is an option that takes a file name.

> > Have you thought about concurrent access to a precompiled module?  If
> > you have a systemtap module foo.ko on a multi-user system, you might end
> > up with a situation where multiple people want to run it at the same
> > time.  Of course you can only insmod one at a time, if nothing else
> > because of the naming issue.  
> 
> Hmm, no I hadn't considered that.  We've also got a similar but
> different problem.  What happens when 2 users both compile two different
> scripts called 'foo.stp' into 'foo.ko', then try to run them
> concurrently?

It doesn't matter what the name of the .ko file is at load time.  The
module name is embedded in the struct module that's compiled into the file
by the Kbuild process.  So as to the latter case of unrelated modules that
users think of as having the same name, that is easily avoided by choosing
unique names at module compilation time.  


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]