public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
From: naresh kamboju <naresh.kernel@gmail.com>
To: systemtap@sources.redhat.com
Cc: "Frank Ch. Eigler" <fche@redhat.com>,
	Masami Hiramatsu <mhiramat@redhat.com>,
	 	David Smith <dsmith@redhat.com>,
	Dave Brolley <brolley@redhat.com>,
	 	David Howells <dhowells@redhat.com>,
	ananth@in.ibm.com
Subject: Re: unresolved type-semantic error
Date: Tue, 08 Dec 2009 09:53:00 -0000	[thread overview]
Message-ID: <f5a7b3810912080153n49a88c6l67b02e333745016c@mail.gmail.com> (raw)
In-Reply-To: <f5a7b3810912070736q287ff981s317f32aedd72d94f@mail.gmail.com>

Hi,

As per my analysis, these below tapsets are presented from
>=systemtap-v.0.6 and also which are known failures.

 /********************************************************************/
File1: testsuite/systemtap.pass1-4/buildok.exp:

------------------------------------------------------------

set self buildok

foreach file [lsort [glob -nocomplain $srcdir/$self/*.stp]] {

    set test $self/[file tail $file]

    verbose -log "Running $file"

    set rc [stap_run_batch $file]

    # some tests are known to fail.

    switch $test {

        buildok/perfmon01.stp {setup_kfail 909 *-*-*}

        buildok/twentyseven.stp {setup_kfail 4166 *-*-*}

        buildok/sched_test.stp {setup_kfail 1155 *-*-*}

        buildok/process_test.stp {setup_kfail 1155 *-*-*}

        buildok/rpc-all-probes.stp {setup_kfail 4413 *-*-*}

        buildok/nfs-all-probes.stp {setup_kfail 4413 *-*-*}

        buildok/per-process-syscall.stp {if {![utrace_p]} {
setup_kfail 9999 *-*-*} }

    }

    if {$rc == 0} { pass $test } else { fail $test }

}

/********************************************************************/

please provide your comments.

Best regards
Naresh Kamboju

On Mon, Dec 7, 2009 at 9:06 PM, naresh kamboju <naresh.kernel@gmail.com> wrote:
> Hi,
>
> I have come across with semantic errors in the SystemTap testsuite
> while building test cases.
> /*************************************************************/
> File: tapset/signal.stp
> /*************************************************************/
> probe signal.handle = kernel.function("handle_signal")
> {
>    sig = $sig
>    sig_name = _signal_name($sig)
>    .
>    .
>    // Check whether the signal is a User Mode or Kernel mode Signal.
>
>    if (sinfo == 0 && sig_code <= 0)
>        sig_mode = "User Mode Signal"
>    else if (sinfo >=  1)
>        sig_mode = "Kernel Mode Signal"
> }
>
> probe signal.handle.return = kernel.function("handle_signal").return ?
> {
>    retstr = returnstr(1)
> }
> /*************************************************************/
> build log
> /*************************************************************/
> semantic error: failed to retrieve return value location for
> copy_process(kernel/fork.c): identifier '$return' at
> /usr/local/arm/devel/share/systemtap/tapset/kprocess.stp:28:12
>        source:     task = $return
>                           ^
> semantic error: failed to retrieve return value location for
> do_execve(fs/exec.c): identifier '$return' at :78:13
>        source:     errno = $return
>                            ^
> semantic error: not accessible at this address (0x80025c5c):
> identifier '$sig' at
> /usr/local/arm/devel/share/systemtap/tapset/signal.stp:526:11
>        source:     sig = $sig
>                          ^
> semantic error: not accessible at this address (0x80025c5c):
> identifier '$sig' at :527:29
>        source:     sig_name = _signal_name($sig)
>                                            ^
> semantic error: probe_1813 with unresolved type: identifier 'sig' at
> /usr/local/arm/devel/share/systemtap/tapset/signal.stp:526:5
>        source:     sig = $sig
>                    ^
> semantic error: probe_1813 with unresolved type: identifier 'sig' at
> process_test.stp:43:14
>        source:   log(sprint(sig))
>                             ^
> semantic error: probe_1813 with unresolved type: identifier 'sprint' at :43:7
>        source:   log(sprint(sig))
>                      ^
> semantic error: probe_1813 with unresolved type: identifier 'log' at :43:3
>        source:   log(sprint(sig))
>                  ^
> Pass 2: analyzed script: 11 probe(s), 16 function(s), 16 embed(s), 0
> global(s) in 230usr/50sys/289real ms.
> Pass 2: analysis failed.  Try again with another '--vp 01' option.
> Keeping temporary directory "/tmp/stapFqPOLz"
> /*************************************************************/
> This symbol is not present in the Kernel
> #nm vmlinux | grep "handle_signal"
> << nothing related to handle_signal >>
> /*************************************************************/
> I have made the following changes to Kernel make test work
>
> make global and Export:
> ------------------------------------------------------------------------------------
>  Index: b/arch/arm/kernel/signal.c
> ===================================================================
> --- a/arch/arm/kernel/signal.c
> +++ b/arch/arm/kernel/signal.c
> @@ -584,8 +584,14 @@ struct arm_abi arm_abi = {
>        .restart        = __NR_restart_syscall
>  };
>
> +#if 0
>  static int handle_signal(unsigned long sig, siginfo_t *info,
>        struct k_sigaction *ka, sigset_t *oldset, struct pt_regs *regs)
> +#else
> +#include <linux/module.h>
> +int handle_signal(unsigned long sig, siginfo_t *info,
> +       struct k_sigaction *ka, sigset_t *oldset, struct pt_regs *regs)
> +#endif
>  {
>        int ret;
>
> @@ -621,6 +627,7 @@ static int handle_signal(unsigned long s
>
>        return ret;
>  }
> +EXPORT_SYMBOL(handle_signal);
>
>  static void do_signal(struct pt_regs *regs)
>  {
>
> /*************************************************************/
> I can say that the above method is not the best way to fix the issues.
>
> I have notices much these kinds of issues almost 70+ test cases.
> I have tested with systemtap-0.9.5 … systemtap-1.0.
>
> All these are expected failures?
> If not,
> Do we need to fix these issues at SystemTap or Kernel side?
>
> Best regards
> Naresh Kamboju
>

  reply	other threads:[~2009-12-08  9:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-07 15:36 naresh kamboju
2009-12-08  9:53 ` naresh kamboju [this message]
2009-12-17 17:28   ` Frank Ch. Eigler

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=f5a7b3810912080153n49a88c6l67b02e333745016c@mail.gmail.com \
    --to=naresh.kernel@gmail.com \
    --cc=ananth@in.ibm.com \
    --cc=brolley@redhat.com \
    --cc=dhowells@redhat.com \
    --cc=dsmith@redhat.com \
    --cc=fche@redhat.com \
    --cc=mhiramat@redhat.com \
    --cc=systemtap@sources.redhat.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).