lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZuBcgRi8ERab0WNG@x1>
Date: Tue, 10 Sep 2024 11:49:37 -0300
From: Arnaldo Carvalho de Melo <acme@...nel.org>
To: Namhyung Kim <namhyung@...nel.org>
Cc: Ian Rogers <irogers@...gle.com>, Kan Liang <kan.liang@...ux.intel.com>,
	Jiri Olsa <jolsa@...nel.org>,
	Adrian Hunter <adrian.hunter@...el.com>,
	Peter Zijlstra <peterz@...radead.org>,
	Ingo Molnar <mingo@...nel.org>, LKML <linux-kernel@...r.kernel.org>,
	linux-perf-users@...r.kernel.org
Subject: Re: [PATCH 1/2] perf annotate: Treat 'call' instruction as stack
 operation

On Mon, Sep 09, 2024 at 02:42:50PM -0700, Namhyung Kim wrote:
> I found some portion of mem-store events sampled on CALL instruction
> which has no memory access.  But it actually saves a return address
> into stack.  It should be considered as a stack operation like RET
> instruction.

Thanks, applied to perf-tools-next,

- Arnaldo
 
> Signed-off-by: Namhyung Kim <namhyung@...nel.org>
> ---
>  tools/perf/util/annotate.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/tools/perf/util/annotate.c b/tools/perf/util/annotate.c
> index 4990c70b1794d7a9..1a347a711dcf5c62 100644
> --- a/tools/perf/util/annotate.c
> +++ b/tools/perf/util/annotate.c
> @@ -2474,6 +2474,7 @@ static bool is_stack_operation(struct arch *arch, struct disasm_line *dl)
>  	if (arch__is(arch, "x86")) {
>  		if (!strncmp(dl->ins.name, "push", 4) ||
>  		    !strncmp(dl->ins.name, "pop", 3) ||
> +		    !strncmp(dl->ins.name, "call", 4) ||
>  		    !strncmp(dl->ins.name, "ret", 3))
>  			return true;
>  	}
> -- 
> 2.46.0.598.g6f2099f65c-goog

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ