Commit 7977fed9 authored by Ingo Molnar's avatar Ingo Molnar
Browse files

Merge tag 'perf-urgent-for-mingo-5.6-20200228' of...

Merge tag 'perf-urgent-for-mingo-5.6-20200228' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux

 into perf/urgent

Pull perf/urgent fixes from Arnaldo Carvalho de Melo:

perf annotate:

  Ravi Bangoria:

  - Fix segfault with source toggle.

  - Fix --show-total-period and --show-nr-samples for tui/stdio2.

  - Fix handling of settings in ~/.perfconfig versus the ones passed
    in the command line

  - Re-render title bar after switching back from script browser.

  - Fix options man page, document some missing ones.

perf probe:

  He Zhe:

  - Check return value of strlist__add() for -ENOMEM.

tools UAPI:

  Arnaldo Carvalho de Melo:

  - Sync x86's msr-index.h copy with the kernel sources.

  - Update tools's copy of x86's kvm.h headers.

Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
parents 4c45945a e0560ba6
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -512,6 +512,8 @@
#define MSR_K7_HWCR			0xc0010015
#define MSR_K7_HWCR_SMMLOCK_BIT		0
#define MSR_K7_HWCR_SMMLOCK		BIT_ULL(MSR_K7_HWCR_SMMLOCK_BIT)
#define MSR_K7_HWCR_IRPERF_EN_BIT	30
#define MSR_K7_HWCR_IRPERF_EN		BIT_ULL(MSR_K7_HWCR_IRPERF_EN_BIT)
#define MSR_K7_FID_VID_CTL		0xc0010041
#define MSR_K7_FID_VID_STATUS		0xc0010042

+1 −0
Original line number Diff line number Diff line
@@ -390,6 +390,7 @@ struct kvm_sync_regs {
#define KVM_STATE_NESTED_GUEST_MODE	0x00000001
#define KVM_STATE_NESTED_RUN_PENDING	0x00000002
#define KVM_STATE_NESTED_EVMCS		0x00000004
#define KVM_STATE_NESTED_MTF_PENDING	0x00000008

#define KVM_STATE_NESTED_SMM_GUEST_MODE	0x00000001
#define KVM_STATE_NESTED_SMM_VMXON	0x00000002
+73 −1
Original line number Diff line number Diff line
@@ -239,7 +239,6 @@ buildid.*::
		set buildid.dir to /dev/null. The default is $HOME/.debug

annotate.*::
	These options work only for TUI.
	These are in control of addresses, jump function, source code
	in lines of assembly code from a specific program.

@@ -269,6 +268,8 @@ annotate.*::
		│        mov    (%rdi),%rdx
		│              return n;

		This option works with tui, stdio2 browsers.

        annotate.use_offset::
		Basing on a first address of a loaded function, offset can be used.
		Instead of using original addresses of assembly code,
@@ -287,6 +288,8 @@ annotate.*::

		             368:│  mov    0x8(%r14),%rdi

		This option works with tui, stdio2 browsers.

	annotate.jump_arrows::
		There can be jump instruction among assembly code.
		Depending on a boolean value of jump_arrows,
@@ -306,6 +309,8 @@ annotate.*::
		│1330:   mov    %r15,%r10
		│1333:   cmp    %r15,%r14

		This option works with tui browser.

        annotate.show_linenr::
		When showing source code if this option is 'true',
		line numbers are printed as below.
@@ -325,6 +330,8 @@ annotate.*::
		│                     array++;
		│             }

		This option works with tui, stdio2 browsers.

        annotate.show_nr_jumps::
		Let's see a part of assembly code.

@@ -335,6 +342,8 @@ annotate.*::

		│1 1382:   movb   $0x1,-0x270(%rbp)

		This option works with tui, stdio2 browsers.

        annotate.show_total_period::
		To compare two records on an instruction base, with this option
		provided, display total number of samples that belong to a line
@@ -348,11 +357,30 @@ annotate.*::

		99.93 │      mov    %eax,%eax

		This option works with tui, stdio2, stdio browsers.

	annotate.show_nr_samples::
		By default perf annotate shows percentage of samples. This option
		can be used to print absolute number of samples. Ex, when set as
		false:

		Percent│
		 74.03 │      mov    %fs:0x28,%rax

		When set as true:

		Samples│
		     6 │      mov    %fs:0x28,%rax

		This option works with tui, stdio2, stdio browsers.

	annotate.offset_level::
		Default is '1', meaning just jump targets will have offsets show right beside
		the instruction. When set to '2' 'call' instructions will also have its offsets
		shown, 3 or higher will show offsets for all instructions.

		This option works with tui, stdio2 browsers.

hist.*::
	hist.percentage::
		This option control the way to calculate overhead of filtered entries -
@@ -490,6 +518,12 @@ top.*::
		column by default.
		The default is 'true'.

	top.call-graph::
		This is identical to 'call-graph.record-mode', except it is
		applicable only for 'top' subcommand. This option ONLY setup
		the unwind method. To enable 'perf top' to actually use it,
		the command line option -g must be specified.

man.*::
	man.viewer::
		This option can assign a tool to view manual pages when 'help'
@@ -517,6 +551,16 @@ record.*::
		But if this option is 'no-cache', it will not update the build-id cache.
		'skip' skips post-processing and does not update the cache.

	record.call-graph::
		This is identical to 'call-graph.record-mode', except it is
		applicable only for 'record' subcommand. This option ONLY setup
		the unwind method. To enable 'perf record' to actually use it,
		the command line option -g must be specified.

	record.aio::
		Use 'n' control blocks in asynchronous (Posix AIO) trace writing
		mode ('n' default: 1, max: 4).

diff.*::
	diff.order::
		This option sets the number of columns to sort the result.
@@ -566,6 +610,11 @@ trace.*::
		"libbeauty", the default, to use the same argument beautifiers used in the
		strace-like sys_enter+sys_exit lines.

ftrace.*::
	ftrace.tracer::
		Can be used to select the default tracer. Possible values are
		'function' and 'function_graph'.

llvm.*::
	llvm.clang-path::
		Path to clang. If omit, search it from $PATH.
@@ -610,6 +659,29 @@ scripts.*::
	The script gets the same options passed as a full perf script,
	in particular -i perfdata file, --cpu, --tid

convert.*::

	convert.queue-size::
		Limit the size of ordered_events queue, so we could control
		allocation size of perf data files without proper finished
		round events.

intel-pt.*::

	intel-pt.cache-divisor::

	intel-pt.mispred-all::
		If set, Intel PT decoder will set the mispred flag on all
		branches.

auxtrace.*::

	auxtrace.dumpdir::
		s390 only. The directory to save the auxiliary trace buffer
		can be changed using this option. Ex, auxtrace.dumpdir=/tmp.
		If the directory does not exist or has the wrong file type,
		the current directory is used.

SEE ALSO
--------
linkperf:perf[1]
+2 −2
Original line number Diff line number Diff line
@@ -566,6 +566,8 @@ int cmd_annotate(int argc, const char **argv)
	if (ret < 0)
		return ret;

	annotation_config__init(&annotate.opts);

	argc = parse_options(argc, argv, options, annotate_usage, 0);
	if (argc) {
		/*
@@ -605,8 +607,6 @@ int cmd_annotate(int argc, const char **argv)
	if (ret < 0)
		goto out_delete;

	annotation_config__init();

	symbol_conf.try_vmlinux_path = true;

	ret = symbol__init(&annotate.session->header.env);
+4 −2
Original line number Diff line number Diff line
@@ -449,7 +449,8 @@ static int perf_del_probe_events(struct strfilter *filter)
		ret = probe_file__del_strlist(kfd, klist);
		if (ret < 0)
			goto error;
	}
	} else if (ret == -ENOMEM)
		goto error;

	ret2 = probe_file__get_events(ufd, filter, ulist);
	if (ret2 == 0) {
@@ -459,7 +460,8 @@ static int perf_del_probe_events(struct strfilter *filter)
		ret2 = probe_file__del_strlist(ufd, ulist);
		if (ret2 < 0)
			goto error;
	}
	} else if (ret2 == -ENOMEM)
		goto error;

	if (ret == -ENOENT && ret2 == -ENOENT)
		pr_warning("\"%s\" does not hit any event.\n", str);
Loading