20 Apr, 2014
1 commit
-
Every event in the perf-kvm has a 'stats' structure, which contains
max/min/average/etc times of handling this event.
The problem is that the 'perf-kvm stat report' command always shows
that 'min time' is 0us for every event. Example:# perf kvm stat report
Analyze events for all VCPUs:
VM-EXIT Samples Samples% Time% Min Time Max Time Avg time
[..]
0xB2 MSCH 12 0.07% 0.00% 0us 8us 7.31us ( +- 2.11% )
0xB2 CHSC 12 0.07% 0.00% 0us 18us 9.39us ( +- 9.49% )
0xB2 STPX 8 0.05% 0.00% 0us 2us 1.88us ( +- 7.18% )
0xB2 STSI 7 0.04% 0.00% 0us 44us 16.49us ( +- 38.20% )
[..]This happens because the 'stats' structure is not initialized and
stats->min equals to 0. Lets initialize the structure for every
event after its allocation using init_stats() function. This initializes
stats->min to -1 and makes 'Min time' statistics counting work:# perf kvm stat report
Analyze events for all VCPUs:
VM-EXIT Samples Samples% Time% Min Time Max Time Avg time
[..]
0xB2 MSCH 12 0.07% 0.00% 6us 8us 7.31us ( +- 2.11% )
0xB2 CHSC 12 0.07% 0.00% 7us 18us 9.39us ( +- 9.49% )
0xB2 STPX 8 0.05% 0.00% 1us 2us 1.88us ( +- 7.18% )
0xB2 STSI 7 0.04% 0.00% 1us 44us 16.49us ( +- 38.20% )
[..]Signed-off-by: Alexander Yarygin
Signed-off-by: Christian Borntraeger
Reviewed-by: David Ahern
Link: http://lkml.kernel.org/r/1397053319-2130-3-git-send-email-borntraeger@de.ibm.com
[ Fixing the perf examples changelog output ]
Signed-off-by: Jiri Olsa
15 Mar, 2014
1 commit
-
Introduce
$ perf kvm --list-cmds
to dump a raw list of commands for use by the completion script. In
order to do this, introduce parse_options_subcommand() for handling
subcommands as a special case in the parse-options machinery.Signed-off-by: Ramkumar Ramachandra
Acked-by: David Ahern
Acked-by: Jiri Olsa
Cc: David Ahern
Link: http://lkml.kernel.org/r/1393896396-10427-1-git-send-email-artagnon@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo
13 Jan, 2014
2 commits
-
For the common evsel list traversal, so that it becomes more compact.
Use the opportunity to start ditching the 'perf_' from 'perf_evlist__',
as discussed, as the whole conversion touches a lot of places, lets do
it piecemeal when we have the chance due to other work, like in this
case.Cc: Adrian Hunter
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-qnkx7dzm2h6m6uptkfk03ni6@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
Instead of requiring tools to do an extra destructor call just before
calling perf_evlist__delete.Cc: Adrian Hunter
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-0jd2ptzyikxb5wp7inzz2ah2@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo
27 Dec, 2013
1 commit
-
Its perfectly fine to call free(NULL), so no need to clutter the source
code with all those superfluous testing.Cc: Adrian Hunter
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-uux5wpvevlerd42gqer13e7n@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo
20 Dec, 2013
1 commit
-
Reduce typing, functions use class__method convention, so unlikely to
clash with other libraries.This actually was discussed in the "Link:" referenced message below.
Cc: Adrian Hunter
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/20131112113427.GA4053@ghostprotocols.net
Signed-off-by: Arnaldo Carvalho de Melo
17 Dec, 2013
1 commit
-
Move debugfs.* to api/fs/. We have a common tools/lib/api/ place where
the Makefile lives and then we place the headers in subdirs.For example, all the fs-related stuff goes to tools/lib/api/fs/ from
which we get libapikfs.a (acme got almost the naming he wanted :-)) and
we link it into the tools which need it - in this case perf and
tools/vm/page-types.acme:
"Looking at the implementation, I think some tools can even link
directly to the .o files, avoiding the .a file altogether.But that is just an optimization/finer granularity tools/lib/
cherrypicking that toolers can make use of."Fixup documentation cleaning target while at it.
Signed-off-by: Borislav Petkov
Acked-by: Ingo Molnar
Cc: Adrian Hunter
Cc: Andi Kleen
Cc: Arjan van de Ven
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Pekka Enberg
Cc: Peter Zijlstra
Cc: Robert Richter
Cc: Stanislav Fomichev
Cc: Stephane Eranian
Cc: Steven Rostedt
Link: http://lkml.kernel.org/r/1386605664-24041-2-git-send-email-bp@alien8.de
Signed-off-by: Arnaldo Carvalho de Melo
10 Dec, 2013
3 commits
-
The code in builtin-kvm.c to generate filename for perf-kvm is useful to
other command such as builtin-diff.This patch move the related code form builtin-kvm.c to util/util.c and
wrap them in a function named get_filename_for_perf_kvm.Signed-off-by: Dongsheng Yang
Link: http://lkml.kernel.org/r/5e09a5c47e8a495e888cbdc65a6fafb2c950f529.1386368672.git.yangds.fnst@cn.fujitsu.com
Signed-off-by: Arnaldo Carvalho de Melo -
When we use perf kvm record-report, there is a bug in report subcommand.
Example:
# perf kvm stat record -a sleep 1
[ perf record: Woken up 1 times to write data ]
[ perf record: Captured and wrote 0.678 MB perf.data.guest (~29641 samples) ]
# perf kvm stat report
failed to open perf.data: No such file or directory (try 'perf record' first)
Initializing perf session failedThis bug was introduced by f5fc14124.
+ struct perf_data_file file = {
+ .path = input_name,
+ .mode = PERF_DATA_MODE_READ,
+ };kvm->tool = eops;
- kvm->session = perf_session__new(kvm->file_name, O_RDONLY, 0, false,
- &kvm->tool);
+ kvm->session = perf_session__new(&file, false, &kvm->tool);It changed the path from kvm->file_name to input_name, this patch change the path back to
'kvm->file_name', then it works well.Verification:
# perf kvm stat record -a sleep 1
[ perf record: Woken up 1 times to write data ]
[ perf record: Captured and wrote 0.807 MB perf.data.guest (~35264 samples) ]
# perf kvm stat reportAnalyze events for all VCPUs:
VM-EXIT Samples Samples% Time% Min Time Max Time Avg time
EPT_VIOLATION 200 32.79% 1.25% 0us 12064us 62.35us ( +- 96.74% )
EPT_MISCONFIG 134 21.97% 0.21% 0us 35us 15.25us ( +- 4.14% )
EXCEPTION_NMI 96 15.74% 0.02% 0us 11us 1.95us ( +- 9.81% )
APIC_ACCESS 79 12.95% 0.02% 0us 13us 2.94us ( +- 11.20% )
HLT 65 10.66% 98.47% 0us 16706us 15084.86us ( +- 1.89% )
IO_INSTRUCTION 27 4.43% 0.02% 0us 29us 6.42us ( +- 15.53% )
EXTERNAL_INTERRUPT 5 0.82% 0.01% 0us 77us 23.65us ( +- 57.90% )
TPR_BELOW_THRESHOLD 4 0.66% 0.00% 0us 1us 1.22us ( +- 4.36% )Total Samples:610, Total events handled time:995745.54us.
Signed-off-by: Dongsheng Yang
Link: http://lkml.kernel.org/r/1386632823-17539-1-git-send-email-yangds.fnst@cn.fujitsu.com
Signed-off-by: Arnaldo Carvalho de Melo -
As there is no -v option for perf kvm, the all debug message for perf
kvm will nerver be printed out to user.Example:
# perf kvm --guestmount /tmp/guestmount/ record -a
Not enough memory for reading perf file headerIt is confusing message for newbies such as me. With this patch applied,
we can use -v option to get the detail.Example:
# perf kvm --guestmount /tmp/guestmount/ record -a -v
Can't access file /tmp/guestmount//15069/proc/kallsyms
Not enough memory for reading perf file headerSigned-off-by: Dongsheng Yang
Cc: David Ahern
Link: http://lkml.kernel.org/r/1386609311-23889-1-git-send-email-yangds.fnst@cn.fujitsu.com
Signed-off-by: Arnaldo Carvalho de Melo
13 Nov, 2013
1 commit
-
Getting unwieldly long, for this app domain should be descriptive enough
and the use of __ to separate the class from the method names should
help with avoiding clashes with other code bases.Reported-by: David Ahern
Suggested-by: Ingo Molnar
Cc: Adrian Hunter
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/20131112113427.GA4053@ghostprotocols.net
Signed-off-by: Arnaldo Carvalho de Melo
12 Nov, 2013
3 commits
-
Several tools (top, kvm) don't need to be called back to process each of
the syntheiszed records, instead relying on the machine__process_event
function to change the per machine data structures that represent
threads and mmaps, so provide a way to ask for this common idiom.Cc: Adrian Hunter
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-pusqibp8n3c4ynegd1frn4zd@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
Further simplifications to be done on following patch, as most tools
don't use the callback, using instead just the canned
machine__process_event one.Cc: Adrian Hunter
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-r1m0vuuj3cat4bampno9yc8d@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo -
When perf_event_attr.mmap_data is set the kernel will generate
PERF_RECORD_MMAP events when non-exec (data, SysV mem) mmaps are
created, so we need to synthesize from /proc/pid/maps for existing
threads, as we do for exec mmaps.Right now just 'perf record' does it, but any other tool that uses
perf_event__synthesize_thread(s|map) can request it.Reported-by: Don Zickus
Tested-by: Don Zickus
Cc: Adrian Hunter
Cc: Bill Gray
Cc: David Ahern
Cc: Don Zickus
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Joe Mario
Cc: Mike Galbraith
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Richard Fowles
Cc: Stephane Eranian
Link: http://lkml.kernel.org/n/tip-ihwzraikx23ian9txinogvv2@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo
05 Nov, 2013
1 commit
-
If the OS does not have timerfd support (e.g., older OS'es like RHEL5)
disable perf kvm stat live.Signed-off-by: David Ahern
Reviewed-by: Jiri Olsa
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1383064996-20933-2-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo
29 Oct, 2013
2 commits
-
Conflicts:
tools/perf/builtin-record.c
tools/perf/builtin-top.c
tools/perf/util/hist.h -
The tail position of the event buffer should only be modified after
actually use that event.If not the event buffer could be invalid before use, and segment fault
occurs when invoking perf top -G.Signed-off-by: Zhouyi Zhou
Cc: David Ahern
Cc: Zhouyi Zhou
Link: http://lkml.kernel.org/r/1382600613-32177-1-git-send-email-zhouzhouyi@gmail.com
[ Simplified the logic using exit gotos and renamed write_tail method to mmap_consume ]
Signed-off-by: Arnaldo Carvalho de Melo
22 Oct, 2013
1 commit
-
This patch is adding 'struct perf_data_file' object as a placeholder for
all attributes regarding perf.data file handling. Changing
perf_session__new to take it as an argument.The rest of the functionality will be added later to keep this change
simple enough, because all the places using perf_session are changed
now.Signed-off-by: Jiri Olsa
Acked-by: Namhyung Kim
Cc: Adrian Hunter
Cc: Andi Kleen
Cc: Corey Ashford
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1381847254-28809-2-git-send-email-jolsa@redhat.com
Signed-off-by: Arnaldo Carvalho de Melo
09 Oct, 2013
1 commit
-
Move the check of the mmap_pages value to the options parsing time, so
we could rely on this value on other parts of code.Related changes come in the next patches.
Also changes perf_evlist::mmap_len to proper size_t type.
Signed-off-by: Jiri Olsa
Cc: Andi Kleen
Cc: Corey Ashford
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Link: http://lkml.kernel.org/r/1378031796-17892-2-git-send-email-jolsa@redhat.com
Signed-off-by: Arnaldo Carvalho de Melo
10 Sep, 2013
1 commit
-
Manipulating the sample_type of an evsel requires the use of:
perf_evsel__set_sample_bit()
and perf_evsel__reset_sample_bit()Signed-off-by: Adrian Hunter
Tested-by: David Ahern
Acked-by: David Ahern
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1378496412-2424-3-git-send-email-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo
29 Aug, 2013
1 commit
-
Add a new parameter for 'pid' to machine__findnew_thread().
Change callers to pass 'pid' when it is known.Note that callers sometimes want to find the main thread
which has the memory maps. The main thread has tid == pid
so the usage in that case is:machine__findnew_thread(machine, pid, pid)
whereas the usage to find the specific thread is:
machine__findnew_thread(machine, pid, tid)
Signed-off-by: Adrian Hunter
Acked-by: David Ahern
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Link: http://lkml.kernel.org/r/1377591794-30553-2-git-send-email-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo
17 Aug, 2013
1 commit
-
4a4d371a missed builtin-kvm in the cleanup to remove the force option
to cmd_record.Signed-off-by: David Ahern
Cc: Jiri Olsa
Link: http://lkml.kernel.org/r/1376512573-85012-1-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo
12 Aug, 2013
1 commit
-
This is useful to spot high latency blips. It is normal for HLT reasons
to have long exit times, so strip those from the duration check.v2: changed threshold to duration per acme's request
Signed-off-by: David Ahern
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Peter Zijlstra
Cc: Runzhen Wang
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1375926999-75129-1-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo
08 Aug, 2013
4 commits
-
Add an option to analyze a specific VM within a data file. This allows
the collection of kvm events for all VMs and then analyze data for each
VM (or set of VMs) individually.Signed-off-by: David Ahern
Reviewed-by: Xiao Guangrong
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Peter Zijlstra
Cc: Runzhen Wang
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1375753297-69645-6-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo -
Add max and min times for exit events.
v2: address Xiao's comment to use get_event function for pulling max and
min from stats struct similar to mean and countSigned-off-by: David Ahern
Reviewed-by: Xiao Guangrong
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Peter Zijlstra
Cc: Runzhen Wang
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1375753297-69645-4-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo -
perf kvm stat currently requires back to back record and report commands
to see stats. e.g,.perf kvm stat record -p $pid -- sleep 1
perf kvm stat reportThis is inconvenvient for on box monitoring of a VM. This patch
introduces a 'live' mode that in effect combines the record plus report
into one command. e.g., to monitor a single VM:perf kvm stat live -p $pid
or all VMs:
perf kvm stat live
Same stats options for the record+report path work with the live mode.
Display rate defaults to 1 second and can be changed using the -d
option.v4:
- address comments from Xiao -- verify_vcpu check should not look at
processors on line for the host, prune configurable options.
- set attr->{mmap,comm,task} to 0 - don't need task events so trim events
we have to deal with
- better control of time for queue event flushing to reduce frequency of
"Timestamp below last timeslice flush" failures.v3:
updated to use existing tracepoint parsing codev2:
removed ABSTIME arg from timerfd_settime as mentioned by Namhyung
only call perf_kvm__handle_stdin when poll returns activity.Signed-off-by: David Ahern
Reviewed-by: Xiao Guangrong
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Peter Zijlstra
Cc: Runzhen Wang
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1375753297-69645-3-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo -
Needed by kvm live command. Make record_args a local while we are
messing with the args.Signed-off-by: David Ahern
Reviewed-by: Xiao Guangrong
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Peter Zijlstra
Cc: Runzhen Wang
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1375473947-64285-5-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo
28 May, 2013
1 commit
-
Save previous pointer and free on failure.
Signed-off-by: David Ahern
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Jiri Olsa
Cc: Namhyung Kim
Cc: Peter Zijlstra
Cc: Runzhen Wang
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1369527896-3650-7-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo
16 Mar, 2013
1 commit
-
This introduces the tools/lib/lk library, that will gradually have the
routines that now are used in tools/perf/ and other tools and that can
be shared.Start by carving out debugfs routines for general use.
Signed-off-by: Borislav Petkov
Cc: Ingo Molnar
Cc: Steven Rostedt
Link: http://lkml.kernel.org/r/1361374353-30385-5-git-send-email-bp@alien8.de
[ committer note: Add tools/lib/lk/ to perf's MANIFEST so that its tarballs continue to build ]
Signed-off-by: Arnaldo Carvalho de Melo
25 Jan, 2013
1 commit
-
The 3786063 commit:
perf kvm: Rename perf_kvm to perf_kvm_stat
Moved the file_name from inside a local struct var that initialized some
of its members, thus zero initializing the not explicitely initialized
variables, one of which was 'file_name', to a standalone local variable,
but forgot to initialize it explicitely to NULL, so it then got some
undefined value, causing a segfault in strdup when it wasn't, by luck,
zero.Fix it by explicitely initializing it to NULL.
Cc: David Ahern
Cc: Frederic Weisbecker
Cc: Jiri Olsa
Cc: Mike Galbraith
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/n/tip-qo2jevp1bdcnh8khzdazs17s@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo
08 Dec, 2012
1 commit
-
Conflicts:
tools/perf/Makefile
tools/perf/builtin-test.c
tools/perf/perf.h
tools/perf/tests/parse-events.c
tools/perf/util/evsel.hSigned-off-by: Ingo Molnar
24 Nov, 2012
2 commits
-
Now, 'perf kvm stat' is only supported on x86, let its code depend on
(__x86_64__ || __i386__) to fix building it on other architectures.Reviewed-by: David Howells
Signed-off-by: Xiao Guangrong
Cc: Borislav Petkov
Cc: David Ahern
Cc: David Howells
Cc: Dong Hao
Cc: Ingo Molnar
Cc: Josh Boyer
Cc: Linus Torvalds
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Runzhen Wang
Cc: Thomas Gleixner
Cc: linux-arch@vger.kernel.org
Cc: x86@kernel.org
Link: http://lkml.kernel.org/r/50A9EB89.70901@linux.vnet.ibm.com
Signed-off-by: Arnaldo Carvalho de Melo -
Then let it only be used in 'perf kvm stat'.
Preparatory patch to stop trying to build parts of this tool that for
now are only supported on x86.Signed-off-by: Xiao Guangrong
Cc: Borislav Petkov
Cc: David Ahern
Cc: David Howells
Cc: Dong Hao
Cc: Ingo Molnar
Cc: Josh Boyer
Cc: Linus Torvalds
Cc: Namhyung Kim
Cc: Paul Mackerras
Cc: Runzhen Wang
Cc: Thomas Gleixner
Cc: linux-arch@vger.kernel.org
Cc: x86@kernel.org
Link: http://lkml.kernel.org/r/50A488DD.6090106@linux.vnet.ibm.com
Signed-off-by: Arnaldo Carvalho de Melo
20 Nov, 2012
1 commit
-
Make perf build for x86 once the UAPI disintegration patches for that arch
have been applied by adding the appropriate -I flags - in the right order -
and then converting some #includes that use ../.. notation to find main kernel
headerfiles to use and instead.Note that -Iarch/foo/include/uapi is present _before_ -Iarch/foo/include.
This makes sure we get the userspace version of the pt_regs struct. Ideally,
we wouldn't have the latter -I flag at all, but unfortunately we want
asm/svm.h and asm/vmx.h in builtin-kvm.c and these aren't part of the UAPI -
at least not for x86. I wonder if the bits outside of the __KERNEL__ guards
*should* be transferred there.I note also that perf seems to do its dependency handling manually by listing
all the header files it might want to use in LIB_H in the Makefile. Can this
be changed to use -MD?Note that to do make this work, we need to export and UAPI disintegrate
linux/hw_breakpoint.h, which I think should've been exported previously so that
perf can access the bits. We have to do this in the same patch to maintain
bisectability.Signed-off-by: David Howells
09 Oct, 2012
4 commits
-
Multi-line statements should have braces. Improves readability.
Signed-off-by: David Ahern
Cc: Dong Hao
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Peter Zijlstra
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1349716656-48165-9-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo -
remove cast and use proper type in format.
Signed-off-by: David Ahern
Cc: Dong Hao
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Peter Zijlstra
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1349716656-48165-11-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo -
Not needed after changing i to unsigned int.
Signed-off-by: David Ahern
Cc: Dong Hao
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Peter Zijlstra
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1349716656-48165-7-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo -
Minimizing processing overhead for each sample - which becomes important
for the upcoming live mode when it has to deal with 100+k events per
second.Signed-off-by: David Ahern
Cc: Dong Hao
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Peter Zijlstra
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1349716656-48165-12-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo
03 Oct, 2012
1 commit
-
Cleans up the builtin-kvm code in preparation for the live mode. No
functional changes; only code movement.Signed-off-by: David Ahern
Cc: Dong Hao
Cc: Ingo Molnar
Cc: Runzhen Wang
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1349237393-86006-1-git-send-email-dsahern@gmail.com
Signed-off-by: Arnaldo Carvalho de Melo
24 Sep, 2012
1 commit
-
We have processed and saved cpuid information to perf_session_env so
reuse it for get_cpu_isa().Signed-off-by: Namhyung Kim
Cc: David Ahern
Cc: Dong Hao
Cc: Ingo Molnar
Cc: Paul Mackerras
Cc: Peter Zijlstra
Cc: Stephane Eranian
Cc: Xiao Guangrong
Link: http://lkml.kernel.org/r/1348474503-15070-6-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo