Commit 53e76d35 authored by Adrian Hunter's avatar Adrian Hunter Committed by Arnaldo Carvalho de Melo

perf tools: Tidy guest option documentation

Move common guest options into include files. Use attribute substitution to
customize an example, using "[verse]" to define the block instead of a
"literal" block which does not permit substitution.
Signed-off-by: default avatarAdrian Hunter <adrian.hunter@intel.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Link: https://lore.kernel.org/r/20220811170411.84154-4-adrian.hunter@intel.comSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent d9ca43c0
include::guestmount.txt[]
--guestkallsyms=<path>::
Guest OS /proc/kallsyms file copy. perf reads it to get guest
kernel symbols. Users copy it out from guest OS.
--guestmodules=<path>::
Guest OS /proc/modules file copy. perf reads it to get guest
kernel module information. Users copy it out from guest OS.
--guestvmlinux=<path>::
Guest OS kernel vmlinux.
--guest-code::
Indicate that guest code can be found in the hypervisor process,
which is a common case for KVM test programs.
--guestmount=<path>::
Guest OS root file system mount directory. Users mount guest OS
root directories under <path> by a specific filesystem access method,
typically, sshfs.
For example, start 2 guest OS, one's pid is 8888 and the other's is 9999:
[verse]
$ mkdir \~/guestmount
$ cd \~/guestmount
$ sshfs -o allow_other,direct_io -p 5551 localhost:/ 8888/
$ sshfs -o allow_other,direct_io -p 5552 localhost:/ 9999/
$ perf {GMEXAMPLECMD} --guestmount=~/guestmount {GMEXAMPLESUBCMD}
...@@ -102,17 +102,9 @@ include::itrace.txt[] ...@@ -102,17 +102,9 @@ include::itrace.txt[]
should be used, and also --buildid-all and --switch-events may be should be used, and also --buildid-all and --switch-events may be
useful. useful.
--guestmount=<path>:: :GMEXAMPLECMD: inject
Guest OS root file system mount directory. Users mount guest OS :GMEXAMPLESUBCMD:
root directories under <path> by a specific filesystem access method, include::guestmount.txt[]
typically, sshfs.
For example, start 2 guest OS, one's pid is 8888 and the other's is 9999:
[verse]
$ mkdir \~/guestmount
$ cd \~/guestmount
$ sshfs -o allow_other,direct_io -p 5551 localhost:/ 8888/
$ sshfs -o allow_other,direct_io -p 5552 localhost:/ 9999/
$ perf inject --guestmount=~/guestmount
SEE ALSO SEE ALSO
-------- --------
......
...@@ -77,26 +77,11 @@ OPTIONS ...@@ -77,26 +77,11 @@ OPTIONS
Collect host side performance profile. Collect host side performance profile.
--guest:: --guest::
Collect guest side performance profile. Collect guest side performance profile.
--guestmount=<path>::
Guest os root file system mount directory. Users mounts guest os :GMEXAMPLECMD: kvm --host --guest
root directories under <path> by a specific filesystem access method, :GMEXAMPLESUBCMD: top
typically, sshfs. For example, start 2 guest os. The one's pid is 8888 include::guest-files.txt[]
and the other's is 9999.
#mkdir ~/guestmount; cd ~/guestmount
#sshfs -o allow_other,direct_io -p 5551 localhost:/ 8888/
#sshfs -o allow_other,direct_io -p 5552 localhost:/ 9999/
#perf kvm --host --guest --guestmount=~/guestmount top
--guestkallsyms=<path>::
Guest os /proc/kallsyms file copy. 'perf' kvm' reads it to get guest
kernel symbols. Users copy it out from guest os.
--guestmodules=<path>::
Guest os /proc/modules file copy. 'perf' kvm' reads it to get guest
kernel module information. Users copy it out from guest os.
--guestvmlinux=<path>::
Guest os kernel vmlinux.
--guest-code::
Indicate that guest code can be found in the hypervisor process,
which is a common case for KVM test programs.
-v:: -v::
--verbose:: --verbose::
Be more verbose (show counter open errors, etc). Be more verbose (show counter open errors, etc).
......
...@@ -487,29 +487,6 @@ include::itrace.txt[] ...@@ -487,29 +487,6 @@ include::itrace.txt[]
For itrace only show specified functions and their callees for For itrace only show specified functions and their callees for
itrace. Multiple functions can be separated by comma. itrace. Multiple functions can be separated by comma.
--guestmount=<path>::
Guest OS root file system mount directory. Users mount guest OS
root directories under <path> by a specific filesystem access method,
typically, sshfs.
For example, start 2 guest OS, one's pid is 8888 and the other's is 9999:
[verse]
$ mkdir \~/guestmount
$ cd \~/guestmount
$ sshfs -o allow_other,direct_io -p 5551 localhost:/ 8888/
$ sshfs -o allow_other,direct_io -p 5552 localhost:/ 9999/
$ perf script --guestmount=~/guestmount
--guestkallsyms=<path>::
Guest OS /proc/kallsyms file copy. perf reads it to get guest
kernel symbols. Users copy it out from guest OS.
--guestmodules=<path>::
Guest OS /proc/modules file copy. perf reads it to get guest
kernel module information. Users copy it out from guest OS.
--guestvmlinux=<path>::
Guest OS kernel vmlinux.
--switch-on EVENT_NAME:: --switch-on EVENT_NAME::
Only consider events after this event is found. Only consider events after this event is found.
...@@ -530,9 +507,9 @@ include::itrace.txt[] ...@@ -530,9 +507,9 @@ include::itrace.txt[]
The known limitations include exception handing such as The known limitations include exception handing such as
setjmp/longjmp will have calls/returns not match. setjmp/longjmp will have calls/returns not match.
--guest-code:: :GMEXAMPLECMD: script
Indicate that guest code can be found in the hypervisor process, :GMEXAMPLESUBCMD:
which is a common case for KVM test programs. include::guest-files.txt[]
SEE ALSO SEE ALSO
-------- --------
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment