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]

new task_finder and inodes-uprobes


Srikar,

We had a conversation on #systemtap where your name came up quite often
(there may have been more to this conversation that I missed, I was
suffering from network issues):

====
drsmith_alt: Sigh.  ananth we're struggling with the new utrace-less
code using tracepoints, which don't allow us to sleep.  We need to sleep
to read/set semaphores, check build-ids, etc.
drsmith_alt: (since the above could cause pagefaults)
drsmith_alt: I can do read/write user memory in a workqueue handler, but
I somehow need to freeze the task until the workqueue handler is done.
drsmith_alt: ananth: If you have any ideas, I'm all ears...
ananth: drsmith_alt: is this for the task_finder?
drsmith_alt: right (well, code called from the task_finder)
ananth: drsmith_alt: srikar_away has written up a mmap() notifier for
uprobes... dunno if you can subscribe to the same
ananth: drsmith_alt: I guess srikar_away may actually have better
ideas.. he has been wading through that sea for a while now
drsmith_alt: ananth: I've had vague notions in that direction.  Instead
of doing all the user memory read/writes at one shot, monitor mmaps and
do it as they come in.
drsmith_alt: ananth: Is the mmap() notifier in the latest uprobes
patches or is it separate?
ananth: drsmith_alt: hmm... we were only interested in text mmaps...
this may not suffice for your purpose
fche2: ananth, part of the point is to check that the user-space program
actually running is the one we expected
fche2: ie that its inode wasn't simply reused and contents replaced, but
actual build-id checking
fche2: so we'd want to force-page-in the build-id area at leastananth:
fche2: hmm.. srikar_away did some investigation on the perf task
filters... his ideas could be a good place to start
====

So, Srikar, do you have any ideas here?

Basically the task_finder2 stuff uses tracepoints to implement
utrace-like handlers - with the big difference being that you could
sleep in a utrace handler.  You can't sleep while in a tracepoint
handler, which means we can't page user memory in to check build ids and
set semaphores.

If you think some of the ideas you are using in the inodes-uprobes code
will help us out here, could you give me a few pointers?

Thanks for the help.

-- 
David Smith
dsmith@redhat.com
Red Hat
http://www.redhat.com
256.217.0141 (direct)
256.837.0057 (fax)


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