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] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 5 Nov 2014 10:58:28 +0100
From:	Stephane Eranian <eranian@...gle.com>
To:	Peter Zijlstra <peterz@...radead.org>
Cc:	Kan Liang <kan.liang@...el.com>,
	LKML <linux-kernel@...r.kernel.org>,
	"mingo@...hat.com" <mingo@...hat.com>,
	Paul Mackerras <paulus@...ba.org>,
	Arnaldo Carvalho de Melo <acme@...nel.org>,
	Jiri Olsa <jolsa@...hat.com>,
	"ak@...ux.intel.com" <ak@...ux.intel.com>
Subject: Re: [PATCH V7 13/17] perf, x86: enable LBR callstack when recording callchain

On Wed, Nov 5, 2014 at 10:21 AM, Peter Zijlstra <peterz@...radead.org> wrote:
> On Tue, Nov 04, 2014 at 09:56:09PM -0500, Kan Liang wrote:
>> From: Yan, Zheng <zheng.z.yan@...el.com>
>>
>> Only enable LBR callstack when user requires fp callgraph. The feature
>> is not available when PERF_SAMPLE_BRANCH_STACK or PERF_SAMPLE_STACK_USER
>> is required.
>> Also, this feature only affects how to get user callchain. The kernel
>> callchain is always got by frame pointers.
>
> Since FP callchains should not change, this doesn't appear to make any
> sense either.

If I recall earlier discussion, the FP callchain are not changed. On
HSW, when requesting
fp at the user level only, then the kernel automatically tries to use
the LBR callstack mode.
Advantage is that the user app does not require frame-pointer or dwarf
debug info to get
correct callchains with perf record. The downside is that LBR
callstack does not work in
certain callchain corner cases.

The reason why using LBR call stack mode is restricted to user level
only is because of
a bug in the LBR call stack hardware which forces the kernel to drop
LBR_FREEZE_PMI.
In other words ,the LBR does not stop on counter overflow, thus it
will be wiped out by
execution of kernel code leading to the PMU interrupt handler.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ