summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Make simple probes work even without KPROBES in the kernel.Mark Wielaard2009-04-091-0/+8
| | | | | | | | | Without KPROBES very little works atm. But stack.c file is unconditionally imported, while these two functions are only used through context-unwind.stp. This at least lets us do simple sanity checks on "plain" kernels. * runtime/stack.c (_stp_stack_print, _stp_stack_snprint): Wrap in #if defined (CONFIG_KPROBES).
* Add tests for probefunc(), usymname(), uaddr() versus shared libraries.Mark Wielaard2009-04-092-0/+53
| | | | | * testsuite/systemtap.base/uprobes_uname.exp: New file. * testsuite/systemtap.base/uprobes_uname.stp: Likewise.
* Make new stap_task_finder_targets chain on correct list.Mark Wielaard2009-04-091-1/+1
| | | | | * runtime/task_finder.c (stap_register_task_finder_target): Also check both pathlen are zero.
* Make sure code using the vma tracker compiles again.Mark Wielaard2009-04-084-26/+6
| | | | | | | | * runtime/runtime.h: Include task_finder.c. * runtime/sym.c: Always define task_finder callbacks for usage in tapsets. * runtime/task_finder.c: Define dummy stap_task_finder_target when ! defined(CONFIG_UTRACE). * tapsets.cxx: Never include task_finder.c directly.
* Fix DEBUG_TASK_FINDER_VMA compilation.Mark Wielaard2009-04-081-1/+1
| | | | * runtime/sym.c (_stp_tf_mmap_cb): We get passed vm_flags, not flags.
* Add main executable symbol uprobe to uprobes_lib.exp test.Mark Wielaard2009-04-084-11/+23
| | | | | | | | | | | There was nothing wrong with the probe itself, but because the body was empty the compiler optimised away the actual call... * testsuite/systemtap.base/uprobes_lib.exp: Activate main exe probe, expect more output. * testsuite/systemtap.base/uprobes_lib.stp: Also probe main and main_lib. * testsuite/systemtap.base/uprobes_exe.c: Put some code in main_func. * testsuite/systemtap.base/uprobes_lib.c: Likewise for lib_func.
* Consider function when handling .labelStan Cox2009-04-082-16/+34
| | | | | | * tapsets.cxx(dwflpp::iterate_over_cu_labels): New parameter function. Do wildcard match for function. * testsuite/systemtap.base/labels.exp: Test .label function handling.
* Better error handling in 'setup_server'.David Smith2009-04-081-2/+2
| | | | | | 2009-04-08 David Smith <dsmith@redhat.com> * lib/systemtap.exp (setup_server): Better error handling.
* Added '#ifdef STP_NEED_VMA_TRACKER' around code that needs it.David Smith2009-04-081-1/+2
| | | | | | | 2009-04-08 David Smith <dsmith@redhat.com> * runtime/sym.c: Added '#ifdef STP_NEED_VMA_TRACKER' around code that needs it.
* Merge branch 'master' of ssh://sources.redhat.com/git/systemtapDavid Smith2009-04-088-43/+135
|\
| * Merge branch 'master' of ssh://sourceware.org/git/systemtapStan Cox2009-04-081-4/+4
| |\
| | * tweak nettop.stp demo to sort by accumulated counts despite mergingFrank Ch. Eigler2009-04-081-4/+4
| | |
| * | Do not do a partial name comparison for .label.Stan Cox2009-04-082-8/+9
| |/ | | | | | | * tapsets.cxx (dwflpp::iterate_over_cu_labels): Compare with strcmp not strncmp.
| * Fix stats for processes that only transmitted data without receivingEugeniy Meshcheryakov2009-04-081-0/+8
| |
| * Omit symbols that have suspicious addresses (before base) from symbol table.Mark Wielaard2009-04-081-2/+5
| | | | | | | | * translate.cxx (dump_unwindsyms): Filter out sym.st_value < base values.
| * Use _stp_snprintf in _stp_symbol_snprint.Mark Wielaard2009-04-081-2/+2
| | | | | | | | * runtime/sym.c (_stp_symbol_snprint): Use _stp_snprintf, no _stp_printf.
| * Add uaddr() context tapset function.Mark Wielaard2009-04-082-0/+33
| | | | | | | | | | * tapset/context.stp (uaddr): New sfunction. * testsuite/buildok/uaddr.stp: New test.
| * Fix so publicanized Tapset Reference manual can be generated again.William Cohen2009-04-071-30/+77
| |
* | Only includes task_finder.c when needed.David Smith2009-04-082-2/+22
|/ | | | | | | | | | | | | 2009-04-08 David Smith <dsmith@redhat.com> * tapsets.cxx (itrace_derived_probe_group::emit_module_decls): Added inclusion of task_finder.c back. Unconditionally including it when not needed causes all systemtap scripts to fail on kernels with no utrace support. (utrace_derived_probe_group::emit_module_decls): Ditto. (uprobe_derived_probe_group::emit_module_decls): Ditto. * runtime/runtime.h: Removed unconditional inclusion of task_finder.c.
* Add valid interval in error message when timer probe out of range.Mark Wielaard2009-04-071-10/+18
| | | | | | * tapsets.cxx (hrtimer_derived_probe): Take scale argument, add interval/scale to semantic_error message. (timer_builder): Set and pass scale.
* Track VMA per pid (group_leader/tgid).Mark Wielaard2009-04-071-5/+6
| | | | | * runtime/sym.c (_stp_tf_vm_cb): Add and remove tsk->group_leader. (_stp_mod_sec_lookup): find vma for task->group_leader.
* Create usymname and usymdata variant that trigger STP_NEED_VMA_TRACKER.Mark Wielaard2009-04-075-5/+72
| | | | | | | | | * tapset/context-symbols.stp (syname, symdata): Pass NULL for kernel address. * tapset/ucontext-symbols.stp: New file defining usymname and usymdata. * testsuite/systemtap.context/usymbols.exp: Use usymname, remove STP_NEED_VMA_TRACKER hack. * testsuite/buildok/usymdata.stp: New test. * testsuite/buildok/usymname.stp: Likewise.
* PR 9940. Rearchitected task_finder.c a bit.David Smith2009-04-073-309/+281
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2009-04-07 David Smith <dsmith@redhat.com> PR 9940. * tapsets.cxx (emit_vma_callback_probe_decl): Initialized new callbacks. (utrace_derived_probe_group::emit_probe_decl): Ditto. (uprobe_derived_probe_group::emit_module_decls): Uses new callback. Makes sure mapping is executable before trying to set a probe in it. (itrace_derived_probe_group::emit_module_init): Calls _stp_sym_init(). (utrace_derived_probe_group::emit_module_init): Ditto. (uprobe_derived_probe_group::emit_module_init): Ditto. * runtime/sym.c: Moved task_finder_vma.c inclusion here from task_finder.c. (_stp_sym_init): New function. (_stp_tf_mmap_cb): New function that replaces _stp_tf_vm_cb. (_stp_tf_munmap_cb): Ditto. * runtime/task_finder.c: Removed task_finder_vma.c inclusion. Split vm_callback into 3 callbacks: mmap_callback, munmap_callback, and mprotect_callback. (stap_register_task_finder_target): Initializes new events variables for the new callbacks. (__STP_TASK_VM_BASE_EVENTS): No longer specifies syscall entry events. (__stp_call_mmap_callbacks): New function. (__stp_call_mmap_callbacks_with_vma): Ditto. (__stp_call_munmap_callbacks): Ditto. (__stp_call_mprotect_callbacks): Ditto. (__stp_call_vm_callbacks): Removed. (__stp_utrace_task_finder_target_quiesce): Calls __stp_call_mmap_callbacks() instead of __stp_call_vm_callbacks(). (__stp_utrace_task_finder_target_syscall_entry): Removed function. (__stp_utrace_task_finder_target_syscall_exit): Reports raw mmap()/mprotect()/munmap() events.
* PR10026: Read marker/tracepoint args directlyJosh Stone2009-04-065-59/+43
| | | | | | | | | | We already stash the context variables for markers and tracepoints into the locals for the probe body, but then we were using separate functions to read those locals for each particular probe body. This patch instead teaches the unparser how to emit the local name directly for those context variables. The resulting code from the translator is much simpler now.
* PR10037: add target_symbol token to $context error messagesFrank Ch. Eigler2009-04-061-64/+81
| | | | | * tapsets.cxx (many foo-translate-bar): Add const target_symbol* parameter, for ->tok use when constructing semantic_errors.
* Run autoreconfEugeniy Meshcheryakov2009-04-061-3/+6
|
* Make install-scripts depend on install-binSCRIPTSEugeniy Meshcheryakov2009-04-061-1/+2
| | | | This is needed for running make with -j. Fixes Debian bug #522800.
* Amend process/errsnoop.stp shebangEugene Teo2009-04-051-1/+2
|
* Remove extra commas in SEE ALSO sectionsEugeniy Meshcheryakov2009-04-0411-11/+11
|
* Make examples executableEugeniy Meshcheryakov2009-04-042-0/+0
|
* PR5163: Assign need_uprobes during pass-2Josh Stone2009-04-031-2/+4
| | | | | | We were doing this in pass-3, which means it was never set for cached runs, and so staprun didn't get the -u flag. Now need_probes is set as soon as a uprobe_derived_probe is saved into the session in pass-2.
* PR10032: Trigger cleanup after relay thread errorsJosh Stone2009-04-032-10/+25
| | | | | | When the relay threads encounter an error, they now send SIGTERM to the rest of the process before the thread exit, so we get a clean shutdown. For EPIPE in particular, error messages are also suppressed.
* Correct column heading from uid to pid.William Cohen2009-04-031-1/+1
|
* Describe the ansi_colors.stp and ansi_colors2.stp. Label tables appropriately.William Cohen2009-04-038-7/+82
|
* new process/errsnoop.stp sample scriptEugene Teo2009-04-036-11/+105
|
* Make ansi_colors2.stp script executableEugene Teo2009-04-031-0/+0
|
* Update scripts to use the new ANSI tapsetEugene Teo2009-04-033-19/+28
| | | | | | This updates the example scripts to use the new ANSI escape sequences tapset. It also adds the copyright header that was missing in ansi_colors.stp for a long time.
* New ANSI escape sequences tapsetEugene Teo2009-04-032-0/+101
| | | | | | | This adds a new tapset for ANSI escape sequences. It is based on an existing tapset that was written by Masami Hiramatsu for the stapgames project. This also adds a version of ansi_color.stp script that displays other attributes other than the bold effect.
* make skip-badvars warning message sensitive to -w suppressionFrank Ch. Eigler2009-04-031-2/+3
|
* Improvements to errno tapsetEugene Teo2009-04-031-3/+11
| | | | | | This adds an errno_p() function that will return an absolute errno if it is valid, or zero if it is not. It also simplifies the if statement in the errno_str() function.
* Add a .gitignore for uprobesJosh Stone2009-04-021-0/+7
|
* Really fix run-stap this time, I promise!Josh Stone2009-04-025-55/+35
|
* Fix strftime format bugMasami Hiramatsu2009-04-021-3/+6
| | | | | This fixes bugs in strftime-subset function. This modifies %C, %l and %j to fit the output of date command.
* Fix a bug in file size limitation code.Masami Hiramatsu2009-04-022-3/+3
| | | | | | | | | This fixes a bug in stapio, which checks written data size and switches new file when it exceeds a limit. The problem is that written-data-size counter ignores the first written-data size when switching files. So, actual file size always exceeds the limit. This changes stapio to initialize written-data-size counter with the size of the data which will be written in new file.
* Reorder includes so regs.c and regs-ia64.c included before task_finder.c.William Cohen2009-04-022-2/+2
|
* Revert "runtime/syscall.h: Forward declare __ia64_fetch_register."William Cohen2009-04-021-3/+0
| | | | This reverts commit 49be62cc7130e60947bbae90b6bf177e173c8b29.
* runtime/syscall.h: Forward declare __ia64_fetch_register.Mark Wielaard2009-04-021-0/+3
|
* Disable ccache during kernel module buildsJosh Stone2009-04-021-0/+6
| | | | | | | | Our module builds always have a 0% ccache hit rate, because the compiler commands always include the randomized tmpdir. Thus, I'm setting CCACHE_DISABLE=1 so ccache never saves these one-use objects. (Besides, we already have our own caching in place for this stuff...)
* Rewrite stmt_rel.exp to only rely on -l output.Stan Cox2009-04-022-77/+38
| | | | * testsuite/systemtap.base/stmt_rel.exp: Rewrite.
* PR6580: Implement symname, symdata and modname context functions.Mark Wielaard2009-04-027-16/+98
| | | | | | | | | | | | | | | | | | This adds a couple of the suggested context/stack revamp functions from PR6580. In particular it replaces the symbolname() function that sneaked in with the pr6866 branch merge with the suggested symname(). * runtime/sym.c (_stp_mod_sec_lookup): Make section optional. (_stp_symbol_snprint): Provide a way to get optional module info. * tapset/context-symbols.stp: Replace symbolname() with symname(), add modname() and symdata(). (probemod): Implement pc based fallback. * tapset/context-unwind.stp (caller): Adjust for _stp_symbol_snprint change. * testsuite/systemtap.context/usymbols.exp: Use new symname. * testsuite/buildok/modname.stp: New test. * testsuite/buildok/symdata.stp: Likewise. * testsuite/buildok/symname.stp: Likewise.