linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Song Liu <songliubraving@fb.com>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: Peter Zijlstra <peterz@infradead.org>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	Kernel Team <Kernel-team@fb.com>, Ingo Molnar <mingo@redhat.com>,
	Arnaldo Carvalho de Melo <acme@redhat.com>,
	"Masami Hiramatsu" <mhiramat@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	"Jiri Olsa" <jolsa@redhat.com>,
	Namhyung Kim <namhyung@kernel.org>,
	Alexey Budankov <alexey.budankov@linux.intel.com>
Subject: Re: [RFC] perf/core: allow ftrace for functions in kernel/event/core.c
Date: Tue, 26 May 2020 22:09:51 +0000	[thread overview]
Message-ID: <196BAA45-AD7A-4DAE-A4C8-CED3DF2C6E17@fb.com> (raw)
In-Reply-To: <20200526180437.45aed950@gandalf.local.home>



> On May 26, 2020, at 3:04 PM, Steven Rostedt <rostedt@goodmis.org> wrote:
> 
> On Tue, 26 May 2020 23:54:15 +0200
> Peter Zijlstra <peterz@infradead.org> wrote:
> 
>> On Tue, May 26, 2020 at 09:46:29PM +0000, Song Liu wrote:
>>> 
>>> 
>>>> On May 26, 2020, at 2:39 PM, Peter Zijlstra <peterz@infradead.org> wrote:
>>>> 
>>>> On Tue, May 26, 2020 at 02:28:26PM -0700, Song Liu wrote:  
>>>>> It is useful to trace functions in kernel/event/core.c. Allow ftrace for
>>>>> them by removing $(CC_FLAGS_FTRACE) from Makefile.  
>>>> 
>>>> Did you try using the ftrace event with perf with this on?  
>>> 
>>> I have tried a few things, like 
>>> 
>>>  perf stat -e probe:perf_read -I 1000
>>>  perf record -e probe:__x64_sys_perf_event_open -aR
>>> 
>>> They all work fine. 
>>> 
>>> Do you have some tricky functions that we should double check?  
>> 
>> I've no idea what probe: does. iirc there's something like
>> ftrace:function that is like regular function tracing.
>> 
>> At some point using that made the kernel really sick due to recursion
>> between ftrace and perf. Quite possibly that's been fixed, dunno.
> 
> In the early days there was a lot of issues with recursions, but I added a
> lot of recursion protection since then. I'll give this patch a spin and see
> if I can make it crash.

Thanks! 

Song

  parent reply	other threads:[~2020-05-26 22:10 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20200526212826.4097888-1-songliubraving@fb.com>
2020-05-26 21:39 ` [RFC] perf/core: allow ftrace for functions in kernel/event/core.c Peter Zijlstra
2020-05-26 21:46   ` Song Liu
2020-05-26 21:54     ` Peter Zijlstra
2020-05-26 22:04       ` Steven Rostedt
2020-05-26 22:05         ` Steven Rostedt
2020-05-26 22:09         ` Song Liu [this message]
2020-06-05 21:58         ` Song Liu
2020-06-05 22:02           ` Steven Rostedt
2020-06-15 18:27             ` Song Liu
2021-09-24 17:15             ` Song Liu
2020-05-26 22:08       ` Song Liu
2020-05-27  5:40     ` Masami Hiramatsu
2020-05-27 18:40       ` Song Liu

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=196BAA45-AD7A-4DAE-A4C8-CED3DF2C6E17@fb.com \
    --to=songliubraving@fb.com \
    --cc=Kernel-team@fb.com \
    --cc=acme@redhat.com \
    --cc=alexey.budankov@linux.intel.com \
    --cc=jolsa@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mhiramat@kernel.org \
    --cc=mingo@redhat.com \
    --cc=namhyung@kernel.org \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.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).