summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorRobb Matzke <matzke@llnl.gov>1998-11-16 15:29:54 (GMT)
committerRobb Matzke <matzke@llnl.gov>1998-11-16 15:29:54 (GMT)
commit841e168a04f14d5ce79713c2937e4cadb543ef0e (patch)
tree0b9511e36bc033d97c06368fdf5f50c863203b3e /bin
parentc3570e984a10701abcef85f3ada67b76d602c4cf (diff)
downloadhdf5-841e168a04f14d5ce79713c2937e4cadb543ef0e.zip
hdf5-841e168a04f14d5ce79713c2937e4cadb543ef0e.tar.gz
hdf5-841e168a04f14d5ce79713c2937e4cadb543ef0e.tar.bz2
[svn-r914] Changes since 19981113
---------------------- ./config/conclude.in ./test/Makefile.in ./tools/Makefile.in The Makefile $TESTS variable has finally been split into $TEST_PROGS and $TEST_SCRIPTS with the latter being the names of shell scripts that need to be run with `/bin/sh'. Now we don't have to copy each shell script before we run it. NOTE: THIS CHANGE DOES NOT AFFECT THE PABLO MAKEFILE SINCE THAT FILE IS A COPY OF A PREVIOUSLY GENERATED MAKEFILE. ./src/Makefile.in Added H5Snone.c to the source list. ./src/H5G.c Plugged a memory leak by emptying the object type "isa" table when the library is closed. ./src/H5Tconv.c ./src/H5Tpkg.h Added 48 new type functions to take advantage of hardware for integer type conversions. These functions are not registered in the conversion table yet because I haven't fully tested them. ./src/H5Tpkg.h Removed __unused__ qualifiers from prototypes.
Diffstat (limited to 'bin')
-rwxr-xr-xbin/iostats19
1 files changed, 16 insertions, 3 deletions
diff --git a/bin/iostats b/bin/iostats
index 924c273..d55d550 100755
--- a/bin/iostats
+++ b/bin/iostats
@@ -3,8 +3,9 @@
# Usage: pipe the output of Linux's `strace' program into the stdin of
# this command, and the output of this command into gnuplot.
-$filename = shift || "tstab2.h5";
-$total = 0;
+my $filename = shift || "tstab2.h5";
+my $total = 0;
+my %What; # What{pos}{nbytes}{r|w} = naccesses
while (<>) {
if (!defined $fd) {
@@ -22,6 +23,7 @@ while (<>) {
} elsif (/^write\((\d+), ".*?"(\.\.\.)?, \d+\)\s*= (\d+)/ &&
$1==$fd && $3>=0) {
my $nbytes = $3;
+ $What{$pos}{$nbytes}{w}++;
printf "%d %d\n", $total, $pos;
$pos += $nbytes;
$total += $nbytes;
@@ -30,6 +32,7 @@ while (<>) {
} elsif (/^read\((\d+), ".*?"(\.\.\.)?, \d+\)\s*= (\d+)/ &&
$1==$fd && $3>=0) {
my $nbytes = $3;
+ $What{$pos}{$nbytes}{r}++;
printf "%d %d\n", $total, $pos;
$pos += $nbytes;
$total += $nbytes;
@@ -37,4 +40,14 @@ while (<>) {
die $_;
}
}
-
+
+
+print "="x36, "\n";
+ printf "%8s %8s %8s %8s\n","Position","NBytes","NReads","NWrites";
+for $pos (sort {$a<=>$b} keys %What) {
+ for $nbytes (sort {$a<=>$b} keys %{$What{$pos}}) {
+ printf "%8d %8d %8d %8d\n", $pos, $nbytes,
+ $What{$pos}{$nbytes}{r},
+ $What{$pos}{$nbytes}{w};
+ }
+}