mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Will Hawkins <whh8b@virginia.edu>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: Re: Ftrace vs perf user page fault statistics differences
Date: Tue, 13 Jun 2017 22:13:16 -0400	[thread overview]
Message-ID: <20170613221316.64d46ea5@gandalf.local.home> (raw)
In-Reply-To: <CAE+MWFsBGEqe9bru3b6xWG4sSsT3wyGvfBS7uK80u+eUn9sm-A@mail.gmail.com>

On Tue, 13 Jun 2017 21:27:20 -0400
Will Hawkins <whh8b@virginia.edu> wrote:

> But, while I have your ear, I was wondering if you could direct me to
> where the page_fault_user gathers its information (when tracing) and
> where that information is formatted for printing (in trace-cmd). I'd
> really like to investigate modifying that code so that it provides
> "better" information than
> 
> address=__per_cpu_end ip=__per_cpu_end
> 
> Now that I'm into this, I want to really dig in. If you can give me a
> pointer, that would really help me get started. After that I can
> attempt to make some patches and see where it leads.
> 
> For the x86 architecture, the relevant files seem to be
> 
> mm/fault.c (with the trace_page_fault_entries function)
> 
> and
> 
> include/asm/trace/exceptions.h (where the exception class is built)

Correct.

> 
> What seems odd there is that the exception *should* be responding with
> "better" information -- address is set to the value of the cr2
> register which should contain the address of the faulting instruction.
> Perhaps I just don't understand what the symbol __per_cpu_end means.
> 
> Any information you can shed on this would be really great.

hmm, actually that looks to be translating the ip address into
functions. It shouldn't be doing that, and it doesn't do it for me with
the latest kernel and trace-cmd.

What does it give you in trace-cmd report -R ? The -R will not parse
the printk-fmt of the event format files, and just show raw numbers.

Can you give me the contents of:

 cat /sys/kernel/debug/tracing/exceptions/page_fault_user/format

?

That's how trace-cmd parses it.



> 
> Thanks again for your patience with me! I think that I now understand
> what is going on.


No problem, it's good to be curious.

-- Steve

  reply	other threads:[~2017-06-14  2:13 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-12 20:08 Will Hawkins
     [not found] ` <CAE+MWFuvAtGc0boe3arhnyoVpCpJBOsBTpk8W7Lh6r5PFE-Hmg@mail.gmail.com>
2017-06-13  1:20   ` Steven Rostedt
2017-06-13  2:05     ` Will Hawkins
2017-06-13 13:06       ` Steven Rostedt
2017-06-13 18:02         ` Will Hawkins
2017-06-13 20:04           ` Steven Rostedt
2017-06-14  1:27             ` Will Hawkins
2017-06-14  2:13               ` Steven Rostedt [this message]
2017-06-14 17:47                 ` Will Hawkins
2017-06-14 20:01                   ` Steven Rostedt
2017-06-19 17:13                     ` Will Hawkins
2017-06-19 18:52                       ` Steven Rostedt
2017-06-14  3:04             ` Namhyung Kim
2017-06-14 17:30               ` Will Hawkins
2017-06-14 17:43                 ` Steven Rostedt

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=20170613221316.64d46ea5@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=whh8b@virginia.edu \
    /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

all inboxes | Powered by JetHome®