public inbox for dtrace@lists.linux.dev
 help / color / mirror / Atom feed
From: Kris Van Hees <kris.van.hees@oracle.com>
To: Kris Van Hees <kris.van.hees@oracle.com>
Cc: Eugene Loh <eugene.loh@oracle.com>,
	dtrace@lists.linux.dev, dtrace-devel@oss.oracle.com
Subject: Re: [DTrace-devel] [PATCH v3] trace: print alloca pointers as actual pointer values
Date: Tue, 16 Sep 2025 12:02:41 -0400	[thread overview]
Message-ID: <aMmKIR8E5rdokSAr@oracle.com> (raw)
In-Reply-To: <aMljZhoquVQGtvRB@oracle.com>

On Tue, Sep 16, 2025 at 09:17:26AM -0400, Kris Van Hees wrote:
> Eugene: Can you test with my kvh/2.0-branch-dev branch from ca-tools4?  I
> cannot reproduce the failures you are seeing with this patch, so I wonder
> if it is a combination of patches that resolves these issues, and testing
> with just this one just doesn't give you the right picture.

Ah, I just took my tree, and merged dev-queue into it, and now I am seeing the
issue pop up with tst.tid_pid.sh at least so will look at that right now.

> On Mon, Sep 15, 2025 at 11:20:28PM -0400, Kris Van Hees wrote:
> > On Mon, Sep 15, 2025 at 09:44:14PM -0400, Kris Van Hees wrote:
> > > On Mon, Sep 15, 2025 at 04:41:43PM -0400, Eugene Loh wrote:
> > > > Largely similar comments to previous versions of this patch:
> > > > 
> > > > On 9/15/25 13:36, Kris Van Hees via DTrace-devel wrote:
> > > > > Because alloca pointers are stored internally as ofssets into the
> > > > 
> > > > The same as for v1 and v2:  s/ofssets/offsets/.
> > > 
> > > Ok, yes, sorry - been spending time on functionality over typos.
> > > 
> > > > > scratchmem area, they were printed as small integers.  They are
> > > > > now printed as actual pointer values into kernel space.
> > > > 
> > > > And, again, the patch performs poorly against testing.
> > > > 
> > > > The new test gives me:
> > > >     -OK 1 OK 333 OK 55555
> > > >     +OK 1059965305 OK 1059965637 OK 1060020859
> > > > which is to say that the dereferenced values are wrong.  (They are all the
> > > > correct values plus some offset.)
> > > > 
> > > > And with this patch, these pre-existing tests fail:
> > > >     test/unittest/builtinvar/tst.tid_pid.sh: FAIL: erroneous exitcode (1).
> > > >     test/unittest/funcs/alloca/tst.alloca-bcopy-top.d: FAIL: expected
> > > > results differ.
> > > >     test/unittest/funcs/bcopy/tst.bcopy_arg_order.d: FAIL: expected results
> > > > differ.
> > > >     test/unittest/funcs/copyinto/tst.copyinto_arg_order.d: FAIL: expected
> > > > results differ.
> > > 
> > > Hm, this is getting frustrating.  Tracking down why I was not seeing those
> > > failures on my end.
> > 
> > Where are you seeing these failures?  Do you have the pointer subtraction patch
> > applied before this one?
> > 
> > > > btw...
> > > > 
> > > > > diff --git a/test/unittest/actions/trace/tst.alloca.r.p b/test/unittest/actions/trace/tst.alloca.r.p
> > > > > new file mode 100755
> > > > > @@ -0,0 +1,11 @@
> > > > > +#!/usr/bin/gawk -f
> > > > > +
> > > > > +{
> > > > > +	$1 = $1 > 0x7fffffff ? "OK" : "BAD";
> > > > > +	$3 = $3 > 0x7fffffff ? "OK" : "BAD";
> > > > > +	$5 = $5 > 0x7fffffff ? "OK" : "BAD";
> > > > > +}
> > > > > +
> > > > > +{
> > > > > +	print;
> > > > > +}
> > > > 
> > > > Why are these split over two awk clauses?  Can't they co-exist in the same
> > > > clause?
> > > 
> > > Yes they can.  But they don't have to.

  reply	other threads:[~2025-09-16 16:02 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-15 17:36 [PATCH v3] trace: print alloca pointers as actual pointer values Kris Van Hees
2025-09-15 20:41 ` [DTrace-devel] " Eugene Loh
2025-09-16  1:44   ` Kris Van Hees
2025-09-16  3:20     ` Kris Van Hees
2025-09-16 13:17       ` Kris Van Hees
2025-09-16 16:02         ` Kris Van Hees [this message]
2025-09-16 17:07           ` Eugene Loh
2025-09-16 18:00             ` Kris Van Hees
2025-09-16 18:56               ` Eugene Loh

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aMmKIR8E5rdokSAr@oracle.com \
    --to=kris.van.hees@oracle.com \
    --cc=dtrace-devel@oss.oracle.com \
    --cc=dtrace@lists.linux.dev \
    --cc=eugene.loh@oracle.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox