All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ian Rogers <irogers@google.com>
To: Timo Paulssen <timo@wakelift.de>
Cc: linux-perf-users@vger.kernel.org
Subject: Re: Make jitted assembly code available for annotation in "perf report"?
Date: Thu, 9 Sep 2021 12:18:41 -0700	[thread overview]
Message-ID: <CAP-5=fVes7=aLS3GM15zxyjRpAJXtkqbxPUtYqHeXRy74Zz_xw@mail.gmail.com> (raw)
In-Reply-To: <cdf5252d-76af-9fb5-522f-206572b21807@wakelift.de>

On Thu, Sep 9, 2021 at 12:09 PM Timo Paulssen <timo@wakelift.de> wrote:
>
> Hello perf users and devs,
>
> I'm a contributor to the MoarVM project, which is the interpreter and
> jit runtime that powers the Rakudo compiler of the Raku language, which
> you may have heard of back when it was still called Perl 6.
>
> We already output a file `/tmp/perf-%d.map` that contains the start and
> end addresses of jit-generated symbols, but I don't know how to tell
> perf where to look for the binary. Our current code will dump each
> compiled piece of code to a folder with an incrementing number. The perf
> report frontend will in its current implementation answer the request to
> annotate a function by just running objdump against the perf-%d.map
> file, which unsurprisingly doesn't work.
>
> I would be glad to hear suggestions, especially ones that don't require
> me to generate a full elf file or similar to hold the symbols.

Hi Timo,

Did you look into jitdump? It requires the perf.data file be processed
by perf inject, see the -j option in:
https://man7.org/linux/man-pages/man1/perf-inject.1.html

An example JIT agent is provided for JVMTI:
https://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git/tree/tools/perf/jvmti?h=perf/core

Thanks,
Ian

> Thanks in advance
>    - Timo
>

      reply	other threads:[~2021-09-09 19:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-09 19:02 Make jitted assembly code available for annotation in "perf report"? Timo Paulssen
2021-09-09 19:18 ` Ian Rogers [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='CAP-5=fVes7=aLS3GM15zxyjRpAJXtkqbxPUtYqHeXRy74Zz_xw@mail.gmail.com' \
    --to=irogers@google.com \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=timo@wakelift.de \
    /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.