[DTrace-devel] [PATCH v2-alternative] Implement the io provider
Eugene Loh
eugene.loh at oracle.com
Fri Nov 17 04:26:54 UTC 2023
I cannot vouch for the details of how the io stack works, but the use of
tracepoints instead of fbt sure makes this stuff look nicer! So,
Reviewed-by: Eugene Loh <eugene.loh at oracle.com>
though I'm not sure if I'm an eligible reviewer.
There continue to be some intermittent test failures.
Also (haven't thought about this yet), I see XFAIL "io:::start not fully
supported before 5.15" for
tst.fbt_probes.sh
tst.nfs2.sh
tst.wait.sh
Should there also be such a .x for
tst.nfs.sh
???
Also, with UEK6 (also need to think about this more), I get problems
with wait-* probes:
# dtrace -n 'io:::start { exit(0) }'
dtrace: description 'io:::start ' matched 1 probe
CPU ID FUNCTION:NAME
7 98772 :start
# dtrace -n 'io:::done { exit(0) }'
dtrace: description 'io:::done ' matched 1 probe
CPU ID FUNCTION:NAME
7 98773 :done
# dtrace -n 'io:::wait-start { exit(0) }'
dtrace: description 'io:::wait-start ' matched 1 probe
dtrace: could not enable tracing: Module does not contain any
CTF data
# dtrace -n 'io:::wait-done { exit(0) }'
dtrace: description 'io:::wait-done ' matched 1 probe
dtrace: could not enable tracing: Module does not contain any
CTF data
Also, the last arg to io_xfs_args() seems not to be used and therefore
could be dropped.
And...
On 11/16/23 11:28, Eugene Loh via DTrace-devel wrote:
> diff --git a/libdtrace/dt_prov_io.c b/libdtrace/dt_prov_io.c
> +
> + /* Handle the non-XFS wait-done flavor. */
> + if (strcmp(prp->desc->prb, "wait-done") == 0) {
> + /*
> + * We need instrument submit_bio_wait(struct bio *):
> + * - on entry, store the bio pointer into a TLS var
> + * - on return, retrieve the pointer (and clear the TLS var)
> + * We use a TLS var to distinguish among possible concurrent
> + * submit_bio_wait() on the CPU.
> + */
We need instrument...
->
We need to instrument...
> diff --git a/test/unittest/io/dump_io_probe_args.d b/test/unittest/io/dump_io_probe_args.d
> +io:::wait-start,
> +io:::wait-done,
> +io:::start,
> +io:::done
> +{
> + printf("%s: %s: %s: %11s %d %3x %9d %9d %p %d %d %5d %5d %p %d %d %d %d %d %d %s %s %s\n",
> + probeprov, probemod, probefunc, probename,
> + arg1,
I think that should be arg2. args[1] is also being dumped. Here, we're
trying to check that arg2==0.
Also, I think you changed some wording in check_io_probe_args.sh. I
guess that's okay, but in light of the fact that we're checking arg2
here rather than args[2], the original wording might be better.
> +
> + args[0]->b_flags,
> +
> + args[0]->b_bcount,
> + args[0]->b_bufsize,
More information about the DTrace-devel
mailing list