[DTrace-devel] [PATCH v2 20/20] Support probeprov, probemod, probefunc, probename built-in variables
Kris Van Hees
kris.van.hees at oracle.com
Tue Jun 8 09:36:14 PDT 2021
On Tue, Jun 08, 2021 at 11:34:06AM -0400, Kris Van Hees wrote:
> On Mon, Jun 07, 2021 at 06:57:46PM -0400, Eugene Loh wrote:
<< irrelevant portion omitted >>
> > I guess I already mentioned in my other email that I don't think the
> > prefix should be written to the output buffer. (The consumer not only
> > tries to print the varint, but it also checks it for unprintable
> > characters, leading to rather surprising variations in output.) The
> > other email proposes a patch, though I imagine you can cook one up just
> > as easily. Main thing is tests to catch this sort of thing. I'd be
> > interested in seeing this patch again after such fixes.
>
> I think your conclusion is wrong. There is nothing wrong with including the
> prefix in the output buffer, and in fact it can be very beneficial and may be
> used in the future to reduce wasted space in output records and a variety of
> other improvements based on having this information readily available.
>
> The fact that the trace() action is nt behaving right is not necessarily a
> function of this code putting out the wrong data (length prefix included with
> the string data). It seems more like a problem with trace() not being able
> to digest the data correctly. And yes, trace() has not been updated to deal
> with strings - and that is an interesting issue that will need some attention
> and simply not make it into this patch series.
>
> And yes, tests should catch this stuff and it shows that we still have some
> major holes in the test coverage. This case is where there need to be more
> tests for the trace() action to cover all the cases we should support (and
> negative tests for things that should not be supported).
I'll be posting a patch in a moment that adds support to trace() for string
data. This will also flip the actions/trace/tst.str.d test to PASS (from
XFAIL). I'll check to see if other tests are now passing as well.
Kris
More information about the DTrace-devel
mailing list