[Bug runtime/12877] New: task_finder doesn't get non-standard exec's right

dsmith at redhat dot com sourceware-bugzilla@sourceware.org
Fri Jun 10 20:26:00 GMT 2011


http://sourceware.org/bugzilla/show_bug.cgi?id=12877

           Summary: task_finder doesn't get non-standard exec's right
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: runtime
        AssignedTo: systemtap@sourceware.org
        ReportedBy: dsmith@redhat.com


While debugging BZ699342, I found that when a thread does an exec (which it
isn't supposed to do), the task_finder doesn't get the resulting events quite
right.  The task_finder also mishandles an exec without a preceeding fork()
incorrectly.  Things work correctly in the normal fork/exec case.

The problem occurs on exec.  When the exec happens, the new program text has
already overlaid the old program text.  The task_finder needs to notify clients
that the original program is gone (if it was "interesting") and check out the
new program (to see if it is "interesting").

To see if the original program was "interesting", it looks up the path of the
parent process.  However, in the case of a thread doing an exec or just an
exec() with no fork(), this will mean task_finder is looking at the wrong path.
 This causes task_finder to miss the original program going away.

A possible solution to this problem is for the task_finder to use a task
specific utrace exec callback for exec (as it does for death).  Then
task_finder wouldn't need to do a path-based lookup, it would just know that
this task was an interesting one.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the Systemtap mailing list