All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kris Van Hees <kris.van.hees@oracle.com>
To: eugene.loh@oracle.com
Cc: dtrace@lists.linux.dev, dtrace-devel@oss.oracle.com
Subject: Re: [DTrace-devel] [PATCH] test: Have tst.ucaller use a predictable trigger
Date: Wed, 26 Feb 2025 11:54:38 -0500	[thread overview]
Message-ID: <Z79HTr6hTGJmsRvU@oracle.com> (raw)
In-Reply-To: <20250110190306.12814-1-eugene.loh@oracle.com>

On Fri, Jan 10, 2025 at 02:03:06PM -0500, eugene.loh--- via DTrace-devel wrote:
> From: Eugene Loh <eugene.loh@oracle.com>
> 
> Signed-off-by: Eugene Loh <eugene.loh@oracle.com>

Reviewed-by: Kris Van Hees <kris.van.hees@oracle.com>

> ---
>  test/unittest/vars/tst.ucaller.d  | 16 ++++++++++++
>  test/unittest/vars/tst.ucaller.r  |  2 +-
>  test/unittest/vars/tst.ucaller.sh | 42 -------------------------------
>  test/unittest/vars/tst.ucaller.x  |  1 -
>  4 files changed, 17 insertions(+), 44 deletions(-)
>  create mode 100644 test/unittest/vars/tst.ucaller.d
>  delete mode 100755 test/unittest/vars/tst.ucaller.sh
>  delete mode 120000 test/unittest/vars/tst.ucaller.x
> 
> diff --git a/test/unittest/vars/tst.ucaller.d b/test/unittest/vars/tst.ucaller.d
> new file mode 100644
> index 000000000..271297fef
> --- /dev/null
> +++ b/test/unittest/vars/tst.ucaller.d
> @@ -0,0 +1,16 @@
> +/*
> + * Oracle Linux DTrace.
> + * Copyright (c) 2025, Oracle and/or its affiliates. All rights reserved.
> + * Licensed under the Universal Permissive License v 1.0 as shown at
> + * http://oss.oracle.com/licenses/upl.
> + */
> +
> +/* @@trigger: ustack-tst-basic */
> +
> +#pragma D option quiet
> +
> +pid$target:a.out:myfunc_x:entry
> +{
> +        ufunc(ucaller);
> +        exit(0);
> +}
> diff --git a/test/unittest/vars/tst.ucaller.r b/test/unittest/vars/tst.ucaller.r
> index 9b09daa0c..bfcc80f4d 100644
> --- a/test/unittest/vars/tst.ucaller.r
> +++ b/test/unittest/vars/tst.ucaller.r
> @@ -1 +1 @@
> -  libc.so.6`strdup                                  
> +  ustack-tst-basic`myfunc_v                         
> diff --git a/test/unittest/vars/tst.ucaller.sh b/test/unittest/vars/tst.ucaller.sh
> deleted file mode 100755
> index a6376af46..000000000
> --- a/test/unittest/vars/tst.ucaller.sh
> +++ /dev/null
> @@ -1,42 +0,0 @@
> -#!/bin/bash
> -#
> -# Oracle Linux DTrace.
> -# Copyright (c) 2007, 2020, Oracle and/or its affiliates. All rights reserved.
> -# Licensed under the Universal Permissive License v 1.0 as shown at
> -# http://oss.oracle.com/licenses/upl.
> -#
> -# This test is a bit naughty; it's assuming that libc.so has an implementation
> -# of strup(3), and that it's implemented in terms of the libc.so
> -# implementation of malloc(3).  If you're reading this comment because
> -# those assumptions have become false, please accept my apologies...
> -#
> -# @@xfail: dtv2
> -
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
> -dtrace=$1
> -
> -$dtrace $dt_flags -qs /dev/stdin -c "/bin/wc -l /dev/zero" <<EOF
> -pid\$target::strdup:entry
> -{
> -	self->strdup = 1;
> -}
> -
> -pid\$target:libc.so:malloc:entry
> -/self->strdup/
> -{
> -	ufunc(ucaller);
> -	exit(0);
> -}
> -
> -pid\$target::strdup:return
> -/self->strdup/
> -{
> -	self->strdup = 0;
> -}
> -EOF
> -
> -exit 0
> diff --git a/test/unittest/vars/tst.ucaller.x b/test/unittest/vars/tst.ucaller.x
> deleted file mode 120000
> index 6507ccd87..000000000
> --- a/test/unittest/vars/tst.ucaller.x
> +++ /dev/null
> @@ -1 +0,0 @@
> -../pid/test.x
> \ No newline at end of file
> -- 
> 2.43.5
> 
> 
> _______________________________________________
> DTrace-devel mailing list
> DTrace-devel@oss.oracle.com
> https://oss.oracle.com/mailman/listinfo/dtrace-devel

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

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-10 19:03 [PATCH] test: Have tst.ucaller use a predictable trigger eugene.loh
2025-02-26 16:54 ` Kris Van Hees [this message]

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=Z79HTr6hTGJmsRvU@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.