summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordsmith <dsmith>2006-09-26 21:39:52 +0000
committerdsmith <dsmith>2006-09-26 21:39:52 +0000
commit3ae203b24203fc169e39f7b733f11038aafa80ef (patch)
tree50ff792a57834d21fba71791276dd7de519bac13
parentcc6dac44fe06855e8d1f69f9582ba5525869c4ab (diff)
downloadsystemtap-steved-3ae203b24203fc169e39f7b733f11038aafa80ef.tar.gz
systemtap-steved-3ae203b24203fc169e39f7b733f11038aafa80ef.tar.xz
systemtap-steved-3ae203b24203fc169e39f7b733f11038aafa80ef.zip
2006-09-26 David Smith <dsmith@redhat.com>
* README: Changed 'stpd' references to 'staprun'. * README.doc: Ditto. * TODO: Ditto. * io.c: Ditto. * print.c: Ditto. * runtime.h: Ditto. * bench2/bench.rb: Ditto.
-rw-r--r--runtime/ChangeLog10
-rw-r--r--runtime/README2
-rw-r--r--runtime/README.doc31
-rw-r--r--runtime/TODO4
-rw-r--r--runtime/bench2/bench.rb18
-rw-r--r--runtime/io.c10
-rw-r--r--runtime/print.c4
-rw-r--r--runtime/runtime.h2
8 files changed, 46 insertions, 35 deletions
diff --git a/runtime/ChangeLog b/runtime/ChangeLog
index 30d7e8f0..867dca3d 100644
--- a/runtime/ChangeLog
+++ b/runtime/ChangeLog
@@ -1,3 +1,13 @@
+2006-09-26 David Smith <dsmith@redhat.com>
+
+ * README: Changed 'stpd' references to 'staprun'.
+ * README.doc: Ditto.
+ * TODO: Ditto.
+ * io.c: Ditto.
+ * print.c: Ditto.
+ * runtime.h: Ditto.
+ * bench2/bench.rb: Ditto.
+
2006-09-26 Martin Hunt <hunt@redhat.com>
* time.c (_stp_init_time): Use dynamic percpu allocations
instead of evil static allocations.
diff --git a/runtime/README b/runtime/README
index 470cad16..efabcfef 100644
--- a/runtime/README
+++ b/runtime/README
@@ -1,4 +1,4 @@
-To build everything (relayfs, transport, stpd, and example probes):
+To build everything (relayfs, transport, staprun, and example probes):
> make
To clean up:
diff --git a/runtime/README.doc b/runtime/README.doc
index 2fa3f5ff..27484184 100644
--- a/runtime/README.doc
+++ b/runtime/README.doc
@@ -11,13 +11,14 @@ and code fragments needed by the compiler/translator to
include in building a kernel module using kprobes. It
also includes I/O code to transmit its output from the kernel to userspace.
-In addition to the library, the runtime includes a SystemTap user-space daemon
-(stpd). Stpd grabs data sent from the I/O code in the runtime and displays it
-and/or saves it to files. Stpd will handle other issues like
-inserting and removing modules.
+In addition to the library, the runtime includes a SystemTap
+user-space daemon (staprun). Staprun grabs data sent from the I/O
+code in the runtime and displays it and/or saves it to files. Staprun
+will handle other issues like inserting and removing modules.
-Stpd and the I/O code makes use of /proc (and optionally relayfs) for communications. For
-kernels without relayfs builtin, it is provided as a standalone module under the runtime directory.
+Staprun and the I/O code makes use of /proc (and optionally relayfs)
+for communications. For kernels without relayfs builtin, it is
+provided as a standalone module under the runtime directory.
@ref start_page
@@ -104,18 +105,18 @@ This timestamps the accumulated print buffer and sends it to relayfs.
When relayfs fills an internal buffer, the user-space daemon is notified
data is ready and reads a big per-cpu chunk.
-The user-daemon (stpd) saves this data to a file named something like
-"stpd_cpu2". When the user hits ^c, a timer expires, or the probe
-module notifies stpd that it wants
-to terminate, stpd does "system(rmmod)" then collects the last output
-before exiting.
-As an option, if we want high-speed bulk per-cpu data, we can put
+The user-daemon (staprun) saves this data to a file named something
+like "stpd_cpu2". When the user hits ^c, a timer expires, or the
+probe module notifies staprun that it wants to terminate, staprun does
+"system(rmmod)" then collects the last output before exiting. As an
+option, if we want high-speed bulk per-cpu data, we can put
\code
#define STP_RELAYFS
\endcode
-at the top of the module and all output will go over relayfs.
-In the SystemTap language, we will provide some simple functions to control the buffering policy, which
-will control the parameters to relayfs and stpd.
+at the top of the module and all output will go over relayfs. In the
+SystemTap language, we will provide some simple functions to control
+the buffering policy, which will control the parameters to relayfs and
+staprun.
*/
diff --git a/runtime/TODO b/runtime/TODO
index 794110d9..9acb11b9 100644
--- a/runtime/TODO
+++ b/runtime/TODO
@@ -2,9 +2,9 @@
@file TODO
@brief To-Do List
-***** STPD *****
+***** STAPRUN *****
-@todo stpd - Implement command that runtime can send to stpd to tell it to fork a specified program and pass
+@todo staprun - Implement command that runtime can send to staprun to tell it to fork a specified program and pass
the output from the probe module to it. Create example probe to use it.
***** runtime *****
diff --git a/runtime/bench2/bench.rb b/runtime/bench2/bench.rb
index 4b8bc2ff..42792461 100644
--- a/runtime/bench2/bench.rb
+++ b/runtime/bench2/bench.rb
@@ -27,10 +27,10 @@ class Bench
if @@printed_header == 0
print_header
end
- if @@stpd.nil?
- for path in ['/usr/libexec/systemtap/stpd', '/usr/local/libexec/systemtap/stpd']
+ if @@staprun.nil?
+ for path in ['/usr/bin/staprun', '/usr/local/bin/staprun']
if File.exist?(path)
- @@stpd = path
+ @@staprun = path
break
end
end
@@ -67,8 +67,8 @@ class Bench
sum=0
threads.times {|cpu| fork {exec "./itest #{threads} > #{@dir}/bench#{cpu}"}}
threads.times {Process.waitpid(-1)} # wait for itest(s) to exit
- `sudo killall -HUP stpd`
- Process.wait # wait for stpd to exit
+ `sudo killall -HUP staprun`
+ Process.wait # wait for staprun to exit
threads.times {|x| sum = sum + `cat #{@dir}/bench#{x}`.split[0].to_i - @@ftime}
@results[threads] = sum / (threads * threads)
File.open("#{@dir}/xxx.out") do |file|
@@ -115,13 +115,13 @@ class Bench
@@ftime = 0
@@printed_header = 0
- @@stpd = nil
+ @@staprun = nil
@@runtime = nil
@@num_threads = []
@@minfreq = 0
def cleanup
- system('sudo killall -HUP stpd &> /dev/null')
+ system('sudo killall -HUP staprun &> /dev/null')
system('sudo /sbin/rmmod bench &> /dev/null')
`/bin/rm -f stap.out` if File.exists?("stap.out")
`/bin/rm -f bench.stp` if File.exists?("bench.stp")
@@ -132,7 +132,7 @@ class Bench
def load
args = "-q -b 8"
if @trans == RELAYFS then args = "-q" end
- fork do exec "sudo #{@@stpd} #{args} #{@dir}/bench.ko > #{@dir}/xxx 2> #{@dir}/xxx.out" end
+ fork do exec "sudo #{@@staprun} #{args} #{@dir}/bench.ko > #{@dir}/xxx 2> #{@dir}/xxx.out" end
sleep 5
end
@@ -270,7 +270,7 @@ class Stapbench < Bench
end
args = "-q -b 8"
if @trans == RELAYFS then args = "-q" end
- fork do exec "sudo #{@@stpd} #{args} #{@dir}/bench.ko > #{@dir}/xxx 2> #{@dir}/xxx.out" end
+ fork do exec "sudo #{@@staprun} #{args} #{@dir}/bench.ko > #{@dir}/xxx 2> #{@dir}/xxx.out" end
sleep 5
end
diff --git a/runtime/io.c b/runtime/io.c
index 846a83d8..cee9acf1 100644
--- a/runtime/io.c
+++ b/runtime/io.c
@@ -67,7 +67,7 @@ static void _stp_vlog (enum code type, char *func, int line, const char *fmt, va
}
/** Logs Data.
- * This function sends the message immediately to stpd. It
+ * This function sends the message immediately to staprun. It
* will also be sent over the bulk transport (relayfs) if it is
* being used. If the last character is not a newline, then one
* is added. This function is not as efficient as _stp_printf()
@@ -85,7 +85,7 @@ void _stp_log (const char *fmt, ...)
}
/** Prints warning.
- * This function sends a warning message immediately to stpd. It
+ * This function sends a warning message immediately to staprun. It
* will also be sent over the bulk transport (relayfs) if it is
* being used. If the last character is not a newline, then one
* is added.
@@ -100,7 +100,7 @@ void _stp_warn (const char *fmt, ...)
}
/** Exits and unloads the module.
- * This function sends a signal to stpd to tell it to
+ * This function sends a signal to staprun to tell it to
* unload the module and exit. The module will not be
* unloaded until after the current probe returns.
* @note Be careful to not treat this like the Linux exit()
@@ -113,7 +113,7 @@ void _stp_exit (void)
}
/** Prints error message and exits.
- * This function sends an error message immediately to stpd. It
+ * This function sends an error message immediately to staprun. It
* will also be sent over the bulk transport (relayfs) if it is
* being used. If the last character is not a newline, then one
* is added.
@@ -133,7 +133,7 @@ void _stp_error (const char *fmt, ...)
/** Prints error message.
- * This function sends an error message immediately to stpd. It
+ * This function sends an error message immediately to staprun. It
* will also be sent over the bulk transport (relayfs) if it is
* being used. If the last character is not a newline, then one
* is added.
diff --git a/runtime/print.c b/runtime/print.c
index 904104f8..ae220f28 100644
--- a/runtime/print.c
+++ b/runtime/print.c
@@ -25,7 +25,7 @@
* _stp_print_flush() is called.
*
* The reason to do this is to allow multiple small prints to be combined then
- * timestamped and sent together to stpd. This is more efficient than sending
+ * timestamped and sent together to staprun. This is more efficient than sending
* numerous small packets.
*
* This function is called automatically when the print buffer is full.
@@ -80,7 +80,7 @@ void _stp_print_flush (void)
return;
#ifdef STP_RELAYFS_MERGE
- /* In merge-mode, stpd expects relayfs data to start with a 4-byte length */
+ /* In merge-mode, staprun expects relayfs data to start with a 4-byte length */
/* followed by a 4-byte sequence number. In non-merge mode, anything goes. */
*((uint32_t *)pb->timestamp) = _stp_seq_inc();
diff --git a/runtime/runtime.h b/runtime/runtime.h
index dec664d5..26153cb7 100644
--- a/runtime/runtime.h
+++ b/runtime/runtime.h
@@ -38,7 +38,7 @@
#ifdef DEBUG
/** Prints debug line.
- * This function prints a debug message immediately to stpd.
+ * This function prints a debug message immediately to staprun.
* If the last character is not a newline, then one is added.
* @param args A variable number of args in a format like printf.
* @ingroup io