linux-perf-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Leo Yan <leo.yan@arm.com>
To: Graham Woodward <graham.woodward@arm.com>
Cc: acme@kernel.org, namhyung@kernel.org, mark.rutland@arm.com,
	jolsa@kernel.org, irogers@google.com, james.clark@linaro.org,
	mike.leach@linaro.org, leo.yan@linux.dev,
	linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org, nd@arm.com
Subject: Re: [PATCH v1 0/4] perf arm-spe: Allow synthesizing of branch
Date: Fri, 25 Oct 2024 18:33:30 +0100	[thread overview]
Message-ID: <20241025173330.GD359792@e132581.arm.com> (raw)
In-Reply-To: <20241025143009.25419-1-graham.woodward@arm.com>

On Fri, Oct 25, 2024 at 03:30:05PM +0100, Graham Woodward wrote:
> 
> Currently the --itrace=b will only show branch-misses but this change
> allows perf to synthesize branches as well.
> 
> The change also incorporates the ability to display the target
> addresses when specifying the addr field if the instruction is a branch.

Tested for this series:

  # perf record -e arm_spe_0/branch_filter=1,load_filter=1/u \
      -- ./false_sharing.exe 1

  # perf script --itrace=i10ib  -F,+addr,+flags
    false_sharing.e  880532 [005] 1852579.389533:          1                                    branch:   jmp                       ffff91beb224     ffff91beb220 __GI___tunables_init+0x40 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389538:          1                                    branch:   jmp                       ffff91bec318     ffff91bec314 _dl_next_ld_env_entry+0x24 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389620:          1                                    branch:   jmp                       ffff91be0f14     ffff91be0f10 _dl_new_object+0x168 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389802:          1                                    branch:   jmp                       ffff91be2cf0     ffff91be2cec _dl_map_object_deps+0x3f4 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389802:         10                              instructions:   jmp                       ffff91be2cf0     ffff91be2cec _dl_map_object_deps+0x3f4 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389824:          1                                    branch:   br miss                   ffff91bee4e4     ffff91bee4e0 strcmp+0xa0 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389849:          1                                    branch:   jmp                       ffff91be1868     ffff91be1880 _dl_relocate_object+0x4a8 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389858:          1                                    branch:   jmp                       ffff91be1868     ffff91be1880 _dl_relocate_object+0x4a8 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389861:          1                                    branch:   jmp                       ffff91be1c20     ffff91be1bcc _dl_relocate_object+0x7f4 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389875:         10                              instructions:                                        0     ffff91bdfe38 _dl_lookup_symbol_x+0x58 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389876:          1                                    branch:   jmp                       ffff91bdf3a8     ffff91bdf434 do_lookup_x+0x114 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389879:          1                                    branch:   jmp                       ffff91be18ec     ffff91be18e8 _dl_relocate_object+0x510 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389886:          1                                    branch:   jmp                       ffff91bee440     ffff91bdf2dc check_match+0x154 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389890:          1                                    branch:   jmp                       ffff91bdfed4     ffff91bdfed0 _dl_lookup_symbol_x+0xf0 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389893:         10                              instructions:                                        0     ffff91be1974 _dl_relocate_object+0x59c (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389894:          1                                    branch:   jmp                       ffff91bdf3f4     ffff91bdf3f0 do_lookup_x+0xd0 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)
    false_sharing.e  880532 [005] 1852579.389906:          1                                    branch:   jmp                       ffff91bdfea4     ffff91bdfe90 _dl_lookup_symbol_x+0xb0 (/usr/lib/aarch64-linux-gnu/ld-2.31.so)

  # perf test "Check Arm SPE"
  114: Check Arm SPE trace data recording and synthesized samples      : Ok
  115: Check Arm SPE doesn't hang when there are forks                 : Ok

Tested-by: Leo Yan <leo.yan@arm.com>

  parent reply	other threads:[~2024-10-25 17:33 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-25 14:30 [PATCH v1 0/4] perf arm-spe: Allow synthesizing of branch Graham Woodward
2024-10-25 14:30 ` [PATCH v1 1/4] perf arm-spe: Set sample.addr to target address for instruction sample Graham Woodward
2024-10-25 14:30 ` [PATCH v1 2/4] perf arm-spe: Use ARM_SPE_OP_BRANCH_ERET when synthesizing branches Graham Woodward
2024-10-25 14:30 ` [PATCH v1 3/4] perf arm-spe: Correctly set sample flags Graham Woodward
2024-10-25 14:30 ` [PATCH v1 4/4] perf arm-spe: Update --itrace help text Graham Woodward
2024-10-25 17:33 ` Leo Yan [this message]
2024-10-28  8:34 ` [PATCH v1 0/4] perf arm-spe: Allow synthesizing of branch James Clark
2024-10-28 16:40 ` Namhyung Kim
2024-10-29 17:03   ` Leo Yan
2024-10-29 23:09     ` Namhyung Kim
2024-10-30  9:33       ` Leo Yan
2024-10-30 21:30 ` Namhyung Kim

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=20241025173330.GD359792@e132581.arm.com \
    --to=leo.yan@arm.com \
    --cc=acme@kernel.org \
    --cc=graham.woodward@arm.com \
    --cc=irogers@google.com \
    --cc=james.clark@linaro.org \
    --cc=jolsa@kernel.org \
    --cc=leo.yan@linux.dev \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mike.leach@linaro.org \
    --cc=namhyung@kernel.org \
    --cc=nd@arm.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 NNTP newsgroup(s).