perf-top.txt 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179
  1. perf-top(1)
  2. ===========
  3. NAME
  4. ----
  5. perf-top - System profiling tool.
  6. SYNOPSIS
  7. --------
  8. [verse]
  9. 'perf top' [-e <EVENT> | --event=EVENT] [<options>]
  10. DESCRIPTION
  11. -----------
  12. This command generates and displays a performance counter profile in real time.
  13. OPTIONS
  14. -------
  15. -a::
  16. --all-cpus::
  17. System-wide collection. (default)
  18. -c <count>::
  19. --count=<count>::
  20. Event period to sample.
  21. -C <cpu-list>::
  22. --cpu=<cpu>::
  23. Monitor only on the list of CPUs provided. Multiple CPUs can be provided as a
  24. comma-separated list with no space: 0,1. Ranges of CPUs are specified with -: 0-2.
  25. Default is to monitor all CPUS.
  26. -d <seconds>::
  27. --delay=<seconds>::
  28. Number of seconds to delay between refreshes.
  29. -e <event>::
  30. --event=<event>::
  31. Select the PMU event. Selection can be a symbolic event name
  32. (use 'perf list' to list all events) or a raw PMU
  33. event (eventsel+umask) in the form of rNNN where NNN is a
  34. hexadecimal event descriptor.
  35. -E <entries>::
  36. --entries=<entries>::
  37. Display this many functions.
  38. -f <count>::
  39. --count-filter=<count>::
  40. Only display functions with more events than this.
  41. -g::
  42. --group::
  43. Put the counters into a counter group.
  44. -F <freq>::
  45. --freq=<freq>::
  46. Profile at this frequency.
  47. -i::
  48. --inherit::
  49. Child tasks inherit counters, only makes sens with -p option.
  50. -k <path>::
  51. --vmlinux=<path>::
  52. Path to vmlinux. Required for annotation functionality.
  53. -m <pages>::
  54. --mmap-pages=<pages>::
  55. Number of mmapped data pages.
  56. -p <pid>::
  57. --pid=<pid>::
  58. Profile events on existing Process ID.
  59. -t <tid>::
  60. --tid=<tid>::
  61. Profile events on existing thread ID.
  62. -r <priority>::
  63. --realtime=<priority>::
  64. Collect data with this RT SCHED_FIFO priority.
  65. -s <symbol>::
  66. --sym-annotate=<symbol>::
  67. Annotate this symbol.
  68. -K::
  69. --hide_kernel_symbols::
  70. Hide kernel symbols.
  71. -U::
  72. --hide_user_symbols::
  73. Hide user symbols.
  74. -D::
  75. --dump-symtab::
  76. Dump the symbol table used for profiling.
  77. -v::
  78. --verbose::
  79. Be more verbose (show counter open errors, etc).
  80. -z::
  81. --zero::
  82. Zero history across display updates.
  83. -s::
  84. --sort::
  85. Sort by key(s): pid, comm, dso, symbol, parent
  86. -n::
  87. --show-nr-samples::
  88. Show a column with the number of samples.
  89. --show-total-period::
  90. Show a column with the sum of periods.
  91. --dsos::
  92. Only consider symbols in these dsos.
  93. --comms::
  94. Only consider symbols in these comms.
  95. --symbols::
  96. Only consider these symbols.
  97. -G [type,min,order]::
  98. --call-graph::
  99. Display call chains using type, min percent threshold and order.
  100. type can be either:
  101. - flat: single column, linear exposure of call chains.
  102. - graph: use a graph tree, displaying absolute overhead rates.
  103. - fractal: like graph, but displays relative rates. Each branch of
  104. the tree is considered as a new profiled object.
  105. order can be either:
  106. - callee: callee based call graph.
  107. - caller: inverted caller based call graph.
  108. Default: fractal,0.5,callee.
  109. INTERACTIVE PROMPTING KEYS
  110. --------------------------
  111. [d]::
  112. Display refresh delay.
  113. [e]::
  114. Number of entries to display.
  115. [E]::
  116. Event to display when multiple counters are active.
  117. [f]::
  118. Profile display filter (>= hit count).
  119. [F]::
  120. Annotation display filter (>= % of total).
  121. [s]::
  122. Annotate symbol.
  123. [S]::
  124. Stop annotation, return to full profile display.
  125. [z]::
  126. Toggle event count zeroing across display updates.
  127. [qQ]::
  128. Quit.
  129. Pressing any unmapped key displays a menu, and prompts for input.
  130. SEE ALSO
  131. --------
  132. linkperf:perf-stat[1], linkperf:perf-list[1]