This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
RE: pre-compiled modules
- From: David Smith <dsmith at redhat dot com>
- To: "Stone, Joshua I" <joshua dot i dot stone at intel dot com>
- Cc: "Frank Ch. Eigler" <fche at redhat dot com>, Systemtap List <systemtap at sources dot redhat dot com>
- Date: Tue, 27 Jun 2006 14:59:28 -0500
- Subject: RE: pre-compiled modules
- References: <C56DB814FAA30B418C75310AC4BB279D2B7A20@scsmsx413.amr.corp.intel.com>
Thanks for the response. See stuff below.
On Tue, 2006-06-27 at 12:47 -0700, Stone, Joshua I wrote:
> On Tuesday, June 27, 2006 11:52 AM, David Smith wrote:
> >> Blatant modversions mismatches will be detected during the actual
> >> insertion attempt - IMO there is no need to make a dry run first. We
> >> will need more self-protective code though for purposes of verifying
> >> module addresses. Specifically, we need to find a kernel API routine
> >> that, given a module name, gives its loaded base address.
> >
> > Hmm, I hadn't considered that. Will this code go in the module itself
> > or go in the runtime?
>
> Is there a difference? The runtime is still compiled into the module,
> right?
Sorry, I meant to say: "Will this code go in the module itself or the
stpd daemon?"
> > 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?
> > -P PRE_COMPILED_MODULE
> > Run pre-compiled module
>
> Looks fine.
>
> 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?
I'm unsure of what we can do in either case.
--
David Smith
dsmith@redhat.com
Red Hat, Inc.
http://www.redhat.com
256.217.0141 (direct)
256.837.0057 (fax)