]> sourceware.org Git - systemtap.git/log
systemtap.git
11 years agoPR15044: remove error return string in ip.stp
Jonathan Lebon [Mon, 3 Jun 2013 18:13:06 +0000 (14:13 -0400)]
PR15044: remove error return string in ip.stp

11 years agolinux/context-symbols: fix small typo in cutesy error return
Jonathan Lebon [Mon, 3 Jun 2013 17:51:06 +0000 (13:51 -0400)]
linux/context-symbols: fix small typo in cutesy error return

Fixes a typo in the return value which could affect backwards
compatibility with versions <= 2.2.

11 years agoPR15044: change _stp_text_str() from void to int and clean up tapset
Jonathan Lebon [Fri, 31 May 2013 18:38:02 +0000 (14:38 -0400)]
PR15044: change _stp_text_str() from void to int and clean up tapset

The tapset functions user_string_quoted() and user_string_n_quoted()
now no longer return "NULL" and _stp_text_str() in stp_string.c no
longer returns "<unknown>". Instead, _stp_text_str() was changed to
return an int which the tapset checks for to detect an error.

11 years agoPR15044: cleaned up functions in uconversions.stp
Jonathan Lebon [Thu, 30 May 2013 19:59:02 +0000 (15:59 -0400)]
PR15044: cleaned up functions in uconversions.stp

Made multiple changes to the way functions report errors. Also added
two new functions to help the cause: user_string2_warn() and
user_string2_n_warn().

11 years agoPR15044: clean up funcs in errno.stp and string.stp
Jonathan Lebon [Thu, 30 May 2013 19:11:44 +0000 (15:11 -0400)]
PR15044: clean up funcs in errno.stp and string.stp

In errno.stp, made returnstr() report an error if there are no
registers available rather than returning 0. In string.stp, changed
stringat() to report an error if pos is out of bounds.

Minor typo fix in logging.stp.

11 years agostapregex PR15064: update docs
Serguei Makarov [Wed, 5 Jun 2013 19:38:56 +0000 (15:38 -0400)]
stapregex PR15064: update docs

11 years agoPR15575: Return host order in __tcp_sock_dport/sport
Josh Stone [Wed, 5 Jun 2013 01:23:41 +0000 (18:23 -0700)]
PR15575: Return host order in __tcp_sock_dport/sport

The dport and sport are in network order in inet_sock.  When these
tapset functions extract them, they should convert to host order.

Reported-by: "bcall" on freenode #systemtap
11 years agoerrsnoop sample: reduce memory consumption
Frank Ch. Eigler [Tue, 4 Jun 2013 20:49:33 +0000 (16:49 -0400)]
errsnoop sample: reduce memory consumption

The previous version of the code used a stats- (per-cpu-) array with a
5-tuple of index keys, three of them strings.  Multiplying all that
out could could yield several hundred MB of requested kernel RAM at
startup.  Not that anything's wrong with that, but let's not be so
gluttinous.

The new code uses one formatted string as the key column.

11 years agostapregex PR15064: additional testsuite for chr classes
Serguei Makarov [Tue, 4 Jun 2013 18:14:41 +0000 (14:14 -0400)]
stapregex PR15064: additional testsuite for chr classes

11 years agostapregex PR15064 oops: actual proper \ escaping in chr class
Serguei Makarov [Tue, 4 Jun 2013 17:03:36 +0000 (13:03 -0400)]
stapregex PR15064 oops: actual proper \ escaping in chr class

11 years agostapregex PR15064: add remaining essential character classes
Serguei Makarov [Mon, 3 Jun 2013 21:04:06 +0000 (17:04 -0400)]
stapregex PR15064: add remaining essential character classes

This completes POSIX ERE support (ostensibly), but the chr classes
are largely untested at the moment; future commits will add testcases.

11 years agostapregex PR15064 testsuite OOPS: escaping support for ':' in testcase format
Serguei Makarov [Mon, 3 Jun 2013 21:03:38 +0000 (17:03 -0400)]
stapregex PR15064 testsuite OOPS: escaping support for ':' in testcase format

11 years agostapregex PR15064: groundwork for named chr class support
Serguei Makarov [Mon, 3 Jun 2013 18:45:31 +0000 (14:45 -0400)]
stapregex PR15064: groundwork for named chr class support

Current support is missing most of the standard chr classes,
need to find a good and proper reference for them.

* stapregex.cxx (regex_parser::parse_char_range): respect [: :] brackets
  when slurping character classes.
* re2c-regex.h (Range::Range): fix lack of deep-copy in copy constructor
  for ranges.
* re2c-regex.cxx (namedCharacterClasses): new global table of char ranges.
  (Scanner::namedChrClass): new function.
  (Scanner::ranToRA): new function.
  (Scanner::ranToRE): change to use ranToRA.
  (Scanner::getRange): check for '[:' digraph and replace named chr class.

11 years agostapregex: fix spacing in re2c_error message
Serguei Makarov [Mon, 3 Jun 2013 17:12:48 +0000 (13:12 -0400)]
stapregex: fix spacing in re2c_error message

11 years agoPR15064: re-enable basic testcases
Serguei Makarov [Mon, 3 Jun 2013 14:56:40 +0000 (10:56 -0400)]
PR15064: re-enable basic testcases

11 years ago(Re)Fix BZ15198 by updating syscall.sigaltstack probe.
David Smith [Tue, 4 Jun 2013 19:26:30 +0000 (14:26 -0500)]
(Re)Fix BZ15198 by updating syscall.sigaltstack probe.

* tapset/linux/syscalls2.stp: Use generic 'sigaltstack' probe alias when
  CONFIG_GENERIC_SIGALTSTACK is set or we're running on a 3.9 (or higher)
  kernel (where CONFIG_GENERIC_SIGALTSTACK is the default).
* tapset/linux/nd_syscalls2.stp: Ditto.
* tapset/linux/i386/nd_syscalls.stp: Only use arch-specific 'sigaltstack'
  probe alias if CONFIG_GENERIC_SIGALTSTACK isn't set or we're running on
  a earlier kernel than 3.8.
* tapset/linux/i386/syscalls.stp: Ditto.
* tapset/linux/ia64/nd_syscalls.stp: Ditto.
* tapset/linux/ia64/syscalls.stp: Ditto.
* tapset/linux/powerpc/nd_syscalls.stp: Ditto.
* tapset/linux/powerpc/syscalls.stp: Ditto.
* tapset/linux/s390/nd_syscalls.stp: Ditto.
* tapset/linux/s390/syscalls.stp: Ditto.
* tapset/linux/x86_64/nd_syscalls.stp: Ditto.
* tapset/linux/x86_64/syscalls.stp: Ditto.

11 years agoEliminate the possibility of ioblktime.stp global array overflow
William Cohen [Tue, 4 Jun 2013 16:05:12 +0000 (12:05 -0400)]
Eliminate the possibility of ioblktime.stp global array overflow

In some cases the global array tracking IO operations in flight could
overflow when the machine is doing many IO operations (RHBZ743591).
The possiblity of overflow is addressed by increasing the amount of
space allocated for the global array and using the '%' specifier for
the global array.

11 years agoFixed PR15572 by updating the ipmip.stp tapset.
David Smith [Tue, 4 Jun 2013 16:06:33 +0000 (11:06 -0500)]
Fixed PR15572 by updating the ipmip.stp tapset.

* tapset/linux/ipmib.stp: Updated the 'ipmib.InNoRoutes' and
  'ipmib.InAddrErrors' probe aliases for the 3.10 kernel. Those probe
  aliases now probe the return of the ip_route_input_noref() kernel
  function.

11 years agoUpdate testsuite/buildok/nfs_proc-embedded.stp for nfs_proc.stp changes.
David Smith [Tue, 4 Jun 2013 13:36:12 +0000 (08:36 -0500)]
Update testsuite/buildok/nfs_proc-embedded.stp for nfs_proc.stp changes.

11 years agoFixed PR15523 by updating the socket.stp tapset.
David Smith [Tue, 4 Jun 2013 13:31:48 +0000 (08:31 -0500)]
Fixed PR15523 by updating the socket.stp tapset.

* tapset/linux/socket.stp: Reimplemented functions as macros. The old
  functions were deprecated. Used those new macros throughout the tapset,
  to avoid trying to use NULL pointers.
* NEWS: Mentioned function deprecations.
* testsuite/buildok/socket-embedded.stp: No longer test deprecated
  functions.

11 years agoFixed readability issues in tapset/linux/socket.stp. No code change.
David Smith [Mon, 3 Jun 2013 16:35:12 +0000 (11:35 -0500)]
Fixed readability issues in tapset/linux/socket.stp. No code change.

11 years agoActually deprecate items marked as deprecated in nfs_proc.stp.
David Smith [Mon, 3 Jun 2013 16:23:53 +0000 (11:23 -0500)]
Actually deprecate items marked as deprecated in nfs_proc.stp.

* tapset/linux/nfs_proc.stp: The 'stap_NFS_CLIENT' and '__getfh_inode'
  functions had a comment stating they were deprecated. Actually make it
  happen.
* NEWS: Mentioned function deprecations.

11 years agoHandle CONFIG_USER_NS/CONFIG_UIDGID_STRICT_TYPE_CHECKS in the runtime.
Alexander Y. Fomichev [Fri, 31 May 2013 19:46:56 +0000 (14:46 -0500)]
Handle CONFIG_USER_NS/CONFIG_UIDGID_STRICT_TYPE_CHECKS in the runtime.

* runtime/linux/task_finder.c: Add CONFIG_UIDGID_STRICT_TYPE_CHECKS code.
* runtime/linux/task_finder2.c: Ditto.
* runtime/transport/control.c: Ditto.
* runtime/transport/transport.c: Ditto.
* runtime/linux/autoconf-uidgid.c: New autoconf test.
* buildrun.cxx (compile_pass): Add STAPCONF_LINUX_UIDGID_H autoconf test.
* runtime/procfs.c: Include uidgid_compatibility.h.
* runtime/proc_fs_compatibility.h: Move KUIDT_INIT()/KGIDT_INIT() macros
  to uidgid_compatibility.h.
* runtime/transport/debugfs.c: Use KUIDT_INIT/KGIDT_INIT macros.
* runtime/transport/relay_v2.c: Ditto
* runtime/uidgid_compatibility.h: New file.

11 years agoMerge branch 'master' of ssh://sourceware.org/git/systemtap
Lukas Berk [Fri, 31 May 2013 15:37:05 +0000 (11:37 -0400)]
Merge branch 'master' of ssh://sourceware.org/git/systemtap

11 years agoAdjust stapbm.in and docs to avoid recurssion
Lukas Berk [Fri, 31 May 2013 15:33:03 +0000 (11:33 -0400)]
Adjust stapbm.in and docs to avoid recurssion

*NEWS: added news blurb
*java/stapbm.in: due to change in tapset-method.cxx and only probing
 probe begin, we're able to remove java recursion gaurds
 and simply
*main/stapprobes.3stap: update docs reflecting requirement of jvm pid's
to be prexisting and if a string is passed for
process name, it needs to be listed in a jps -l
invocation
*tapset-method.cxx: switch process("java").begin probe to probe begin
    in order to avoid recurssion due to byteman operations

11 years agoFixed BZ920444 by using macros to handle nfs parameter changes.
David Smith [Fri, 31 May 2013 14:05:23 +0000 (09:05 -0500)]
Fixed BZ920444 by using macros to handle nfs parameter changes.

* tapset/linux/nfs_proc.stpm: New file.
* tapset/linux/nfs_proc.stp: Remove __i2n_ip_proto(),
  __nfs_read_data_info(), and __nfs_write_data_info() functions. Callers
  of those functions now use new macros in nfs_proc.stpm. The advantage
  the macros have, besides clarity, is that they preserve type
  information. Kernel commit 0b7c01533aa9f4a228d07d2768d084acb3a387bc
  changed the commit functions to take a nfs_commit_data structure instead
  of a nfs_write_data_structure. Because functions lose type information,
  systemtap didn't notice this change.

11 years agoFixed readability issues in tapset/linux/nfs_proc.stp. No actual code change.
David Smith [Thu, 30 May 2013 14:49:19 +0000 (09:49 -0500)]
Fixed readability issues in tapset/linux/nfs_proc.stp. No actual code change.

11 years agoDouble-check DW_AT_comp_dir before we try to use it
Josh Stone [Wed, 29 May 2013 20:52:58 +0000 (13:52 -0700)]
Double-check DW_AT_comp_dir before we try to use it

In building tracepoints, we try a late search for the kernel source tree
using DW_AT_comp_dir, and add extra includes based on that path.  That
comp_dir is not always reliable though; for instance, Ubuntu leaves it
something like "/build/buildd/linux...", which is not an installed path.

(See also http://brainstorm.ubuntu.com/idea/11327)

* tapsets.cxx (tracepoint_builder::init_dw): Verify that the given
  DW_AT_comp_dir actually exists before we use it.

11 years agoRemove redundant assert_is_myproc from utf functions
Josh Stone [Wed, 29 May 2013 19:53:59 +0000 (12:53 -0700)]
Remove redundant assert_is_myproc from utf functions

* tapset/uconversions.stp (user_string_utf16, user_string_utf32): These
  are marked "/* myproc-unprivileged */", so the translator will insert
  the necessary assert_is_myproc() already.  Having a redundant check
  doesn't actually hurt, except it adds confusion by implying that other
  similar functions are in error for not having this too.

11 years agoFix PR15549 by updating the 'sunrpc.clnt.create_client' probe alias.
David Smith [Wed, 29 May 2013 18:53:59 +0000 (13:53 -0500)]
Fix PR15549 by updating the 'sunrpc.clnt.create_client' probe alias.

* tapset/linux/rpc.stp: Fix the 'sunrpc.clnt.create_client' probe alias by
  updating the '_sunrpc.clnt.create_client.rpc_new_client' probe alias.

11 years agosemop-watch: add some goofy <2.3 compatibility
Frank Ch. Eigler [Wed, 29 May 2013 16:45:49 +0000 (12:45 -0400)]
semop-watch: add some goofy <2.3 compatibility

11 years agonew sample: semop-watch.stp
Casey Dahlin [Wed, 29 May 2013 16:34:41 +0000 (12:34 -0400)]
new sample: semop-watch.stp

This sample demonstrates pulling apart userspace struct/array
parameters from syscall.* probe context.

11 years agotapset: standardize sem*op(2) sops_uaddr variable
Frank Ch. Eigler [Wed, 29 May 2013 15:52:23 +0000 (11:52 -0400)]
tapset: standardize sem*op(2) sops_uaddr variable

* tapset/linux/syscalls2.stp, nd_syscalls2.stp (semops): Use
  sops_uaddr, deprecate tsops_uaddr.
* testsuite/buildok/*syscalls2*: Corresponding changes.

11 years agostap.1: drop deprecation history details
Frank Ch. Eigler [Tue, 28 May 2013 22:21:15 +0000 (18:21 -0400)]
stap.1: drop deprecation history details

11 years agofix thread-business.stp sample permissions
Frank Ch. Eigler [Tue, 28 May 2013 20:39:24 +0000 (16:39 -0400)]
fix thread-business.stp sample permissions

11 years agostapregex: ditch dynamic_cast<> use for regex_query->right
Serguei Makarov [Wed, 29 May 2013 16:14:35 +0000 (12:14 -0400)]
stapregex: ditch dynamic_cast<> use for regex_query->right

11 years agofix build failure after stapregex merge
Serguei Makarov [Wed, 29 May 2013 15:55:47 +0000 (11:55 -0400)]
fix build failure after stapregex merge

11 years agoAlways grab the rcu read lock in rcu_dereference().
David Smith [Wed, 29 May 2013 15:28:14 +0000 (10:28 -0500)]
Always grab the rcu read lock in rcu_dereference().

11 years agostapregex testsuite fails: add chr range order check to fix 2:a[b-a]:-
Serguei Makarov [Wed, 29 May 2013 14:27:25 +0000 (10:27 -0400)]
stapregex testsuite fails: add chr range order check to fix 2:a[b-a]:-

11 years agoPR15063: enable additional testcases for ^$ oddities
Serguei Makarov [Tue, 28 May 2013 15:39:21 +0000 (11:39 -0400)]
PR15063: enable additional testcases for ^$ oddities

11 years agoPR15063 cleanup: mark extra pinpointing-tests as successful
Serguei Makarov [Tue, 28 May 2013 14:35:40 +0000 (10:35 -0400)]
PR15063 cleanup: mark extra pinpointing-tests as successful

11 years agoPR15063 quickfix: just disable the whole YYFILL mechanism
Serguei Makarov [Mon, 27 May 2013 21:58:26 +0000 (17:58 -0400)]
PR15063 quickfix: just disable the whole YYFILL mechanism

11 years agostapregex cleanup: move maxFill inside of class DFA
Serguei Makarov [Mon, 27 May 2013 21:56:33 +0000 (17:56 -0400)]
stapregex cleanup: move maxFill inside of class DFA

11 years agoPR15063 (additional debugging statements)
Serguei Makarov [Fri, 24 May 2013 18:04:59 +0000 (14:04 -0400)]
PR15063 (additional debugging statements)

11 years agostapregex testsuite fails: fix 1:a\x:a\x
Serguei Makarov [Wed, 22 May 2013 15:01:01 +0000 (11:01 -0400)]
stapregex testsuite fails: fix 1:a\x:a\x

11 years agostapregex cleanup: get through some minor TODOXXX
Serguei Makarov [Tue, 9 Apr 2013 20:54:27 +0000 (16:54 -0400)]
stapregex cleanup: get through some minor TODOXXX

11 years agostapregex cleanup: error checking in numberical parsing
Serguei Makarov [Tue, 9 Apr 2013 20:53:14 +0000 (16:53 -0400)]
stapregex cleanup: error checking in numberical parsing

11 years agotranslate.cxx oops (how did that even happen??)
Serguei Makarov [Mon, 8 Apr 2013 20:31:06 +0000 (16:31 -0400)]
translate.cxx oops (how did that even happen??)

11 years agostapregex cleanup: clarify some of the TODOXXX
Serguei Makarov [Fri, 5 Apr 2013 18:43:45 +0000 (14:43 -0400)]
stapregex cleanup: clarify some of the TODOXXX

11 years agostapregex cleanup: explanatory comment for (lack of) const_folder::visit_regex_query
Serguei Makarov [Fri, 5 Apr 2013 16:15:02 +0000 (12:15 -0400)]
stapregex cleanup: explanatory comment for (lack of) const_folder::visit_regex_query

11 years agostapregex cleanup: clarify void_statement_reducer::visit_regex_query behaviour
Serguei Makarov [Fri, 5 Apr 2013 16:11:40 +0000 (12:11 -0400)]
stapregex cleanup: clarify void_statement_reducer::visit_regex_query behaviour

11 years agostapregex cleanup: properly set rc after gen_dfa_table()
Serguei Makarov [Fri, 5 Apr 2013 15:55:20 +0000 (11:55 -0400)]
stapregex cleanup: properly set rc after gen_dfa_table()

11 years agostapregex cleanup: ditch redundant regex_query::re field in favour of dynamic_cast...
Serguei Makarov [Fri, 5 Apr 2013 15:39:26 +0000 (11:39 -0400)]
stapregex cleanup: ditch redundant regex_query::re field in favour of dynamic_cast<...> use

11 years agoAdd buildok testcase for rcu.stp.
David Smith [Wed, 29 May 2013 14:36:42 +0000 (09:36 -0500)]
Add buildok testcase for rcu.stp.

11 years agoCheck for a valid address in rcu_dereference().
David Smith [Wed, 29 May 2013 14:31:46 +0000 (09:31 -0500)]
Check for a valid address in rcu_dereference().

* tapset/linux/rcu.stp: Call kderef() to make sure the address is safe to
  read.

11 years agoMerge branch 'master' of ssh://sourceware.org/git/systemtap
David Smith [Tue, 28 May 2013 21:43:22 +0000 (16:43 -0500)]
Merge branch 'master' of ssh://sourceware.org/git/systemtap

11 years agoFix PR15543 by fixing the 'servername' convenience variables in the rpc tapset.
David Smith [Tue, 28 May 2013 21:42:03 +0000 (16:42 -0500)]
Fix PR15543 by fixing the 'servername' convenience variables in the rpc tapset.

* tapset/linux/rpc.stp: Handle kernel change that moves the 'cl_server'
  field of the 'rpc_clnt' structure into the 'rpc_xprt' structure.
* tapset/linux/rcu.stp: New file.

11 years agoPR14454: search for the full path to a module, not only for the module name
Martin Lazar [Tue, 28 May 2013 19:16:42 +0000 (15:16 -0400)]
PR14454: search for the full path to a module, not only for the module name

11 years agoRemove a direct include of rwlock.h which fail on a kernel with the RT patches
Raphaël Beamonte [Tue, 28 May 2013 01:45:55 +0000 (21:45 -0400)]
Remove a direct include of rwlock.h which fail on a kernel with the RT patches

The file linux/rwlock.h should not be included directly as stated by
an #error message at the 5th line of the file. With a RT patched
kernel, linux/rwlock_rt.h should be included instead of linux/rwlock.h.
The file linux/spinlock.h already do the proper check. We then should
let the include be done by this file.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Yannick Brosseau <yannick.brosseau@gmail.com>
11 years agoPR14440: made usage of pfiles.stp and plimit.stp more consistent
Jonathan Lebon [Mon, 27 May 2013 20:43:20 +0000 (16:43 -0400)]
PR14440: made usage of pfiles.stp and plimit.stp more consistent

Added support for plimit.stp to accept a target PID through both -x and
$1, just like in pfiles.stp. Also removed the //bin/true hack from
pfiles.stp and '#!/usr/bin/env stap' from plimit.stp so that both of
them must be run using stap -g.

11 years agoMerge branch 'master' of ssh://sourceware.org/git/systemtap
Lukas Berk [Mon, 27 May 2013 19:25:02 +0000 (15:25 -0400)]
Merge branch 'master' of ssh://sourceware.org/git/systemtap

11 years agoRework xvfb-run check and invocation, update autoconf generated files
Lukas Berk [Mon, 27 May 2013 19:24:07 +0000 (15:24 -0400)]
Rework xvfb-run check and invocation, update autoconf generated files

11 years agopfiles.stp: explain use of //bin/true hack
Frank Ch. Eigler [Mon, 27 May 2013 18:36:50 +0000 (14:36 -0400)]
pfiles.stp: explain use of //bin/true hack

11 years agoAdd xvfb-run workaround for docs generation
Lukas Berk [Mon, 27 May 2013 18:35:10 +0000 (14:35 -0400)]
Add xvfb-run workaround for docs generation

*configure.ac: add AC_PROG_CHECK for xvfb-run
*doc/beginners/Makefile.am: exec xvfb-run -a publican ...
*systemtap.spec: add buildrequires line for building stap

11 years agoPR15525: removed duplicate O_CLOEXEC flag check
Jonathan Lebon [Mon, 27 May 2013 15:00:01 +0000 (11:00 -0400)]
PR15525: removed duplicate O_CLOEXEC flag check

The O_CLOEXEC flag was being checked twice, which caused it to be
printed out twice in the flag string when present. The duplication
was removed and the flags were put back in alphabetical order (same
order as in `man 2 open`) to ensure this does not happen again.

11 years agocodegen optimization: for foo <<< N, don't use explicit temporary for the N value
Frank Ch. Eigler [Mon, 27 May 2013 15:14:25 +0000 (11:14 -0400)]
codegen optimization: for foo <<< N, don't use explicit temporary for the N value

11 years agoChange use of jps to ps and stop bmsubmit recursion issue
Lukas Berk [Mon, 27 May 2013 14:09:04 +0000 (10:09 -0400)]
Change use of jps to ps and stop bmsubmit recursion issue

*java/stapbm.in: we can make use of ps instead of jps as the java
 name we're looking for is also passed as an argument
 to java and this avoids starting another java proc
 also add a lockfile to bmsubmit via rulename to stop
 further recursion

11 years agoman stap: fixed typos
Jonathan Lebon [Fri, 24 May 2013 21:21:30 +0000 (17:21 -0400)]
man stap: fixed typos

11 years agoREADME.security: typo
Jonathan Lebon [Fri, 24 May 2013 17:59:49 +0000 (13:59 -0400)]
README.security: typo

11 years agotraceio.stp example: check for negative $return
Jonathan Lebon [Fri, 24 May 2013 14:33:06 +0000 (10:33 -0400)]
traceio.stp example: check for negative $return

The I/O reads and writes should only be counted when $return is
nonnegative. A negative $result occurs if an error was met (e.g.
EAGAIN = -11).

We could have instead here used the bytes_read/written variables
provided by the tapset, but this example demonstrates the use of
local vars and is also consistent with the disktop.stp example.

11 years agonew sample: thread-business.stp
Frank Ch. Eigler [Fri, 24 May 2013 17:18:13 +0000 (13:18 -0400)]
new sample: thread-business.stp

11 years agoregen samples index
Frank Ch. Eigler [Fri, 24 May 2013 02:03:20 +0000 (22:03 -0400)]
regen samples index

11 years agoexamples: add pf4.{stp,meta}
Frank Ch. Eigler [Fri, 24 May 2013 02:02:27 +0000 (22:02 -0400)]
examples: add pf4.{stp,meta}

11 years agoUpdated doc info about utrace/uprobe for newer kernels
Jonathan Lebon [Thu, 23 May 2013 19:03:36 +0000 (15:03 -0400)]
Updated doc info about utrace/uprobe for newer kernels

11 years agoFixed typos
Jonathan Lebon [Wed, 22 May 2013 15:25:55 +0000 (11:25 -0400)]
Fixed typos

11 years agoman/Makefile.in: regenerate
Timo Juhani Lindfors [Wed, 22 May 2013 06:39:55 +0000 (09:39 +0300)]
man/Makefile.in: regenerate

11 years agoman/Makefile.am: add stap-report.1
Timo Juhani Lindfors [Wed, 22 May 2013 06:39:54 +0000 (09:39 +0300)]
man/Makefile.am: add stap-report.1

11 years agoman: add man page for stap-report(1)
Timo Juhani Lindfors [Wed, 22 May 2013 06:39:53 +0000 (09:39 +0300)]
man: add man page for stap-report(1)

11 years agostapdyn: Restrict visibility in generated modules
Josh Stone [Wed, 22 May 2013 23:17:30 +0000 (16:17 -0700)]
stapdyn: Restrict visibility in generated modules

We only want to expose a few specific functions, per stapdyn.h, and we
also want our internal use of those to be bound internally.  This is
accomplished by "-fvisibility=hidden", and then setting visibility to
"protected" by #pragma just for stapdyn.h.

11 years agostapdyn: separate enter_dyninst_uprobe_regs
Josh Stone [Wed, 22 May 2013 23:14:18 +0000 (16:14 -0700)]
stapdyn: separate enter_dyninst_uprobe_regs

That function calls enter_dyninst_uprobe, which is only defined when
uprobes are active, so we have a weak binding in place.  By instead
splitting this into a new file, which is only included when uprobes are
known to be active, it doesn't need the weak reference.

11 years agostapdyn: isolate the tls context pointer more
Josh Stone [Wed, 22 May 2013 21:16:42 +0000 (14:16 -0700)]
stapdyn: isolate the tls context pointer more

* runtime/dyninst/runtime_context.h: Rename contexts to tls_context to
  better indicate the purpose of this pointer; update everywhere.
  (_stp_runtime_entryfn_put_context): Take a pointer argument for the
  context you're releasing, to slightly help prevent coding accidents.
* runtime/dyninst/transport.c: Stop the insider-trading of contexts, not
  renaming to tls_context either.  Use _stp_runtime_get_context().
* tapsets.cxx, translate.cxx: Pass the argument to put_context.

11 years agoPR14574 partial fix: Add dyninst support to system_func.exp test.
David Smith [Wed, 22 May 2013 16:14:20 +0000 (11:14 -0500)]
PR14574 partial fix: Add dyninst support to system_func.exp test.

* testsuite/systemtap.base/system_func.exp: Add dyninst support.
* testsuite/systemtap.base/system_func.stp: Ditto.

11 years agoFix testcase permissions.
David Smith [Wed, 22 May 2013 15:51:02 +0000 (10:51 -0500)]
Fix testcase permissions.

11 years agoFix PR15513 by adding a 'runtime' preprocessor conditional.
David Smith [Wed, 22 May 2013 15:49:06 +0000 (10:49 -0500)]
Fix PR15513 by adding a 'runtime' preprocessor conditional.

* parse.cxx (eval_pp_conditional): Added 'runtime' preprocessor conditional.
* man/stap.1: Added 'runtime' preprocessor conditional documentation.
* testsuite/parseok/fourteen.stp: Added 'runtime' preprocessor conditional
  test.
* testsuite/systemtap.base/preprocessor.exp: Ditto.
* testsuite/parseko/preprocess18.stp: New file.
* testsuite/parseko/preprocess19.stp: Ditto.

11 years agostapdyn: retry incomplete/EINTR transport writes
Josh Stone [Wed, 22 May 2013 01:01:20 +0000 (18:01 -0700)]
stapdyn: retry incomplete/EINTR transport writes

Adds _stp_write_retry() which loops over incomplete or otherwise
interrupted write() syscalls.

11 years agostapdyn: Remove the _stp_err copy of stderr
Josh Stone [Wed, 22 May 2013 00:45:31 +0000 (17:45 -0700)]
stapdyn: Remove the _stp_err copy of stderr

The only places left using _stp_err were the transport debug messages,
and _stp_vlog only when transport fails.  Both may as well use whatever
stderr is local to the process directly.

11 years agostapdyn: move MAX_STORED_WARNINGS to the top of transport.c
Josh Stone [Tue, 21 May 2013 23:57:34 +0000 (16:57 -0700)]
stapdyn: move MAX_STORED_WARNINGS to the top of transport.c

11 years agostapdyn: Remove the _stp_out copy of stdout
Josh Stone [Tue, 21 May 2013 23:18:56 +0000 (16:18 -0700)]
stapdyn: Remove the _stp_out copy of stdout

With the transport in place, the only remaining use of _stp_out was for
that transport thread to get its out_fd.  This thread runs within
stapdyn, and we know we'll keep our stdout intact, so _stp_out is no
longer necessary.  Just set out_fd to STDOUT_FILENO, and be prepared for
this to be a -o file (PR14791).

11 years agoRemove the vestigial _stp_dyninst_transport_init
Josh Stone [Tue, 21 May 2013 22:14:05 +0000 (15:14 -0700)]
Remove the vestigial _stp_dyninst_transport_init

11 years agostapdyn: remove the clunky stp_dyninst_master
Josh Stone [Tue, 21 May 2013 22:02:22 +0000 (15:02 -0700)]
stapdyn: remove the clunky stp_dyninst_master

This is a holdover from early stapdyn, which ran all module code within
the mutatee, and even tried to run module_exit in the DSO destructor to
catch the mutatee as it was exiting.  We now do these things more
reliably in stapdyn itself.

It was kept around as a bit of a fallback to let new modules keep
working with stapdyn 2.0, but frankly this is bad code and untested
compatibility, that we shouldn't feel nostalgic about.  Modules will now
require at least stapdyn 2.1, detected by having properly initialized
their shared memory before stp_dyninst_session_init is called.

11 years agofixed typo in doc -- replaced /n by \n
Jonathan Lebon [Tue, 21 May 2013 20:58:27 +0000 (16:58 -0400)]
fixed typo in doc -- replaced /n by \n

11 years agoRemoved overly-paranoid comment.
David Smith [Tue, 21 May 2013 20:51:43 +0000 (15:51 -0500)]
Removed overly-paranoid comment.

11 years agostap-server: also report KALLSYMS config
Frank Ch. Eigler [Tue, 21 May 2013 20:40:30 +0000 (16:40 -0400)]
stap-server: also report KALLSYMS config

11 years agostap-report: also include libdw* in package list
Frank Ch. Eigler [Tue, 21 May 2013 20:32:03 +0000 (16:32 -0400)]
stap-report: also include libdw* in package list

11 years agoFix PR15083 by adding dyninst system() support.
David Smith [Tue, 21 May 2013 20:00:49 +0000 (15:00 -0500)]
Fix PR15083 by adding dyninst system() support.

* runtime/dyninst/transport.c (__stp_d_t_run_command): New function.
(_stp_dyninst_transport_thread_func): Add STP_DYN_SYSTEM support.
(_stp_ctl_send): New function.
* runtime/dyninst/transport.h: Added STP_DYN_SYSTEM and
  STP_DYN_OOB_DATA_MASK.

11 years agoFix PR15486 by handling debug messages properly in dyninst mode.
David Smith [Fri, 17 May 2013 18:18:06 +0000 (13:18 -0500)]
Fix PR15486 by handling debug messages properly in dyninst mode.

* runtime/dyninst/io.c (_stp_vlog): If we're handling a message of type
  DBUG, don't allocate a transport log buffer. Instead use the temporary
  buffer.
* testsuite/systemtap.printf/dbug.exp: New test file.
* testsuite/systemtap.printf/dbug.stp: Ditto.

11 years agoPR15484: have staprun disable kprobes-optimization again
Frank Ch. Eigler [Fri, 17 May 2013 14:45:28 +0000 (10:45 -0400)]
PR15484: have staprun disable kprobes-optimization again

11 years agoPR15481: Only destroy mutexes from stapdyn itself
Josh Stone [Fri, 17 May 2013 01:53:39 +0000 (18:53 -0700)]
PR15481: Only destroy mutexes from stapdyn itself

The primary bug was since commit 8ca891c, _stp_shm_destroy was calling
_stp_runtime_context_free, which calls pthread_mutex_destroy on the
context locks.  But _stp_shm_destroy is only meant to destroy *one*
processes view of shm -- it still needs to leave the contents intact for
other processes!  This was making it so a child process ended and
destroyed the contexts, and thus in stapdyn it couldn't grab a context
to run the end probes.

* runtime/dyninst/shm.c (_stp_shm_destroy): Don't destroy contexts!
* runtime/dyninst/runtime_context.h (_stp_runtime_contexts_free): Remove
  the __-prefixed variant, and explain in comments who should call this.
* tapsets.cxx (common_probe_entryfn_epilogue): Only call put_context if
  we had successfully called get_context before.
* testsuite/systemtap.base/be_loaded.*: Test the simple begin/end case
  with a child command loaded.
* translate.cxx (c_unparser::emit_module_exit): This generated exit
  function is the best place to free the contexts and also shutdown the
  transport, because this is the final call among all processes.
* runtime/dyninst/runtime.h (stp_dyninst_dtor): Don't shutdown the
  transport here, because this is called by every process that has the
  module loaded.

11 years agostapdyn: implement tapset tzinfo.stp
Josh Stone [Fri, 17 May 2013 00:11:44 +0000 (17:11 -0700)]
stapdyn: implement tapset tzinfo.stp

* runtime/dyninst/session_attributes.*: Add tz_gmtoff and tz_name.
* stapdyn/mutator.cxx (mutator::init_session_attributes): Set them.
* tapset/tzinfo.stp: Reduce to just the common tz_ctime().
* tapset/linux/tzinfo.stp: Move the linux tz_gmtoff() and tz_name here.
* tapset/dyninst/tzinfo.stp: Implement dyninst versions of the same.
* doc/SystemTap_Tapset_Reference/tapsets.tmpl: Get docstrings from the
  new linux/tzinfo.stp too.

11 years agoImprove the kernel target_set.stp and add a stapdyn version
Josh Stone [Thu, 16 May 2013 23:12:02 +0000 (16:12 -0700)]
Improve the kernel target_set.stp and add a stapdyn version

* tapset/linux/target_set.stp: Prefer process.begin/end for better
  tracking *process* lifetime. (syscall.exit covers thread exits too!)
* tapset/dyninst/target_set.stp: Implement stapdyn target_set.
* testsuite/systemtap.base/target_set_thread.*: Test that thread exits
  don't cause target_set to lose sight of a process.
* main.cxx (run_sdt_benchmark): Save the timing info for verbose runs.

This page took 0.06229 seconds and 5 git commands to generate.