linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Masami Hiramatsu <mhiramat@kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
	Ingo Molnar <mingo@kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	John 'Warthog9' Hawley <warthog9@kernel.org>
Subject: Re: [RFC][PATCH] bootconfig/tracing/ktest: Add ktest examples of testing bootconfig
Date: Thu, 17 Jun 2021 09:18:08 -0400	[thread overview]
Message-ID: <20210617091808.659abb1d@gandalf.local.home> (raw)
In-Reply-To: <20210617115921.624c5c0d163de94d29202a83@kernel.org>

On Thu, 17 Jun 2021 11:59:21 +0900
Masami Hiramatsu <mhiramat@kernel.org> wrote:

> > +++ b/tools/testing/ktest/examples/bootconfigs/ftrace.bconf

I'm trying to get this file to work. But I may just drop it completely.


> > @@ -0,0 +1,82 @@
> > +#!/bin/sh  
> 
> This shebang is for the syntax hilighting. Please remove it.
> 
> > +
> > +ftrace {
> > +	options = "sym-addr", "context-info"
> > +	buffer_size = 1MB
> > +}
> > +
> > +ftrace.event {
> > +	# Sample1: Make a histogram for initcall functions
> > +	synthetic.initcall_latency {
> > +                fields = "unsigned long func", "u64 lat"
> > +		hist {
> > +			keys = func.sym, lat
> > +			vals = lat
> > +			sort = lat
> > +		}  
> 
> These event.<GROUP>.<EVENT>.hist block is an experimental syntax (plan A),
> and not implemented yet.
> 
> > +	}
> > +	initcall.initcall_start.hist {
> > +		keys = func
> > +		var.ts0 = common_timestamp.usecs
> > +	}
> > +	initcall.initcall_finish.hist {
> > +		keys = func
> > +		var.lat = common_timestamp.usecs - $ts0
> > +		onmatch {
> > +			event = initcall.initcall_start
> > +			action = "initcall_latency(func, $lat)"
> > +		}
> > +	}  
> 
> So please drop this Sample1.
> 
> > +
> > +	# Sample2: kmalloc() tracing in read(2) syscall
> > +	syscalls.sys_enter_read.enable_event {
> > +		event = kmem.kmalloc
> > +		count = 1
> > +	}
> > +	syscalls.sys_exit_read.disable_event {
> > +		event = kmem.kmalloc
> > +	}
> > +
> > +	# Sample3: Stacktrace at the event
> > +	kmem.kmalloc.stacktrace {
> > +		count = 5
> > +		filter = 'bytes_req >= 65536'
> > +	}
> > +
> > +	# Sample4: Take a snapshot
> > +	block.block_unplug.snapshot {
> > +		count = 1
> > +		filter = nr_rq > 1
> > +	}
> > +
> > +	# Sample5: Trace-on/off
> > +	block.block_plug.traceon {
> > +		filter = nr_rq > 1
> > +	}
> > +	block.block_unplug.traceoff {
> > +		filter = nr_rq > 1
> > +	}

None of the above samples do anything.

I'll see if tracing.bconf does anything with the changes.

-- Steve

> > +
> > +        # Sample6: onmax
> > +	sched.sched_waking {
> > +		enable
> > +		hist {
> > +			keys = pid
> > +			ts1 = common_timestamp.usecs
> > +			filter = 'comm == "cyclictest"'
> > +		}
> > +	}


      parent reply	other threads:[~2021-06-17 13:18 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-16 21:41 [RFC][PATCH] bootconfig/tracing/ktest: Add ktest examples of testing bootconfig Steven Rostedt
2021-06-17  2:59 ` Masami Hiramatsu
2021-06-17 12:47   ` Steven Rostedt
2021-06-17 13:18   ` Steven Rostedt [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=20210617091808.659abb1d@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mhiramat@kernel.org \
    --cc=mingo@kernel.org \
    --cc=warthog9@kernel.org \
    /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 NNTP newsgroup(s).