in the output of paths associated with file descriptors.
* Data dump for write syscalls (-e write) is performed regardless
of successfulness of these syscall (addresses Debian bug #436284).
+ * -r and -t options are now affect output independently. Previously,
+ -r option led to ignoring of the -t option (addresses Debian bug #466195).
* Improvements
* Implemented delay injection (-e inject=SET:delay_enter= and
Print a relative timestamp upon entry to each system call. This
records the time difference between the beginning of successive
system calls.
+Note that since
+.B \-r
+option uses the monotonic clock time for measuring time difference and not the
+wall clock time, its measurements can differ from the difference in time
+reported by the
+.B \-t
+option.
.TP
.BI "\-s " strsize
Specify the maximum string size to print (the default is 32). Note
if (tflag) {
struct timespec ts;
- clock_gettime(rflag ? CLOCK_MONOTONIC : CLOCK_REALTIME, &ts);
+ clock_gettime(CLOCK_REALTIME, &ts);
- if (rflag) {
- static struct timespec ots;
- if (ots.tv_sec == 0)
- ots = ts;
-
- struct timespec dts;
- ts_sub(&dts, &ts, &ots);
- ots = ts;
-
- tprintf("%6ld.%06ld ",
- (long) dts.tv_sec, (long) dts.tv_nsec / 1000);
- } else if (tflag > 2) {
+ if (tflag > 2) {
tprintf("%lld.%06ld ",
(long long) ts.tv_sec, (long) ts.tv_nsec / 1000);
} else {
tprintf("%s ", str);
}
}
+
+ if (rflag) {
+ struct timespec ts;
+ clock_gettime(CLOCK_MONOTONIC, &ts);
+
+ static struct timespec ots;
+ if (ots.tv_sec == 0)
+ ots = ts;
+
+ struct timespec dts;
+ ts_sub(&dts, &ts, &ots);
+ ots = ts;
+
+ tprintf("%s%6ld.%06ld%s ",
+ tflag ? "(+" : "",
+ (long) dts.tv_sec, (long) dts.tv_nsec / 1000,
+ tflag ? ")" : "");
+ }
+
if (iflag)
print_pc(tcp);
}
error_msg("-%c has no effect with -c", 'y');
}
- if (rflag) {
- if (tflag > 1)
- error_msg("-tt has no effect with -r");
- tflag = 1;
- }
-
acolumn_spaces = xmalloc(acolumn + 1);
memset(acolumn_spaces, ' ', acolumn);
acolumn_spaces[acolumn] = '\0';
$STRACE_EXE: -T has no effect with -c
$STRACE_EXE: -y has no effect with -c
$STRACE_EXE: $umsg" -u :nosuchuser: -cirtTy true
-
- check_e "-tt has no effect with -r
-$STRACE_EXE: $umsg" -u :nosuchuser: -r -tt true
fi
args='-p 2147483647'