All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCHSET 00/16] perf top: Add multi-thread support (v1)
@ 2015-12-10  7:53 Namhyung Kim
  2015-12-10  7:53 ` [PATCH/RFC 01/16] perf top: Delete half-processed hist entries when exit Namhyung Kim
                   ` (16 more replies)
  0 siblings, 17 replies; 55+ messages in thread
From: Namhyung Kim @ 2015-12-10  7:53 UTC (permalink / raw)
  To: Arnaldo Carvalho de Melo
  Cc: Ingo Molnar, Peter Zijlstra, Jiri Olsa, LKML, David Ahern,
	Frederic Weisbecker, Andi Kleen, Stephane Eranian, Adrian Hunter

Hello,

This patchset if an attempt to support multi-threading in perf top.
In fact, perf top already run on two threads - a worker thread and a
display thread.  However processing all samples with a single thread
in a large machine can have scalability problems.

This patchset extends it to have multiple worker threads to process
samples concurrently.  Users can control the number of threads using
 --num-thread option.  And there's a collector thread for passing hist
entries from worker threads to the display thread.

This basically has same concept of my previous work with perf report
multi-thread support [1].  I decided to work on perf top first, since
it requires smaller changes.  If this work finishes with a good
result, I'll apply it to perf report as well, and continue to work on
it.  So please test (especially on large machines) and give feedbacks. :)

First 6 patches are fixes and cleanups which can be applied separately.
Rest implements multi-thread support and improves it.

You can get it from 'perf/top-threaded-v1' branch in my tree

  git://git.kernel.org/pub/scm/linux/kernel/git/namhyung/linux-perf.git

Any comments are welcome!
Thanks,
Namhyung


[1] https://lkml.org/lkml/2015/10/2/16


Namhyung Kim (16):
  perf top: Delete half-processed hist entries when exit
  perf top: Fix and cleanup perf_top__record_precise_ip()
  perf top: Factor out warnings about kernel addresses and symbols
  perf top: Factor out warnings in perf_top__record_precise_ip()
  perf top: Show warning messages in the display thread
  perf top: Get rid of access to hists->lock in perf_top__record_precise_ip()
  perf hists: Pass hists struct to hist_entry_iter struct
  perf tools: Export a couple of hist functions
  perf tools: Update hist entry's hists pointer
  perf hist: Add events_stats__add() and hists__add_stats()
  perf top: Implement basic parallel processing
  perf tools: Reduce lock contention when processing events
  perf top: Protect the seen list using mutex
  perf top: Separate struct perf_top_stats
  perf top: Add --num-thread option
  perf tools: Skip dso front cache for multi-threaded lookup

 tools/perf/builtin-report.c       |   1 +
 tools/perf/builtin-top.c          | 491 +++++++++++++++++++++++++++++---------
 tools/perf/tests/hists_cumulate.c |   1 +
 tools/perf/tests/hists_filter.c   |   1 +
 tools/perf/tests/hists_output.c   |   1 +
 tools/perf/util/event.c           |   7 +-
 tools/perf/util/hist.c            |  98 ++++++--
 tools/perf/util/hist.h            |  12 +
 tools/perf/util/machine.c         |  19 +-
 tools/perf/util/symbol.c          |   3 +-
 tools/perf/util/symbol.h          |   3 +-
 tools/perf/util/top.c             |  18 +-
 tools/perf/util/top.h             |  14 +-
 13 files changed, 514 insertions(+), 155 deletions(-)

-- 
2.6.2


^ permalink raw reply	[flat|nested] 55+ messages in thread

end of thread, other threads:[~2015-12-15  2:09 UTC | newest]

Thread overview: 55+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-10  7:53 [PATCHSET 00/16] perf top: Add multi-thread support (v1) Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 01/16] perf top: Delete half-processed hist entries when exit Namhyung Kim
2015-12-10  9:55   ` 平松雅巳 / HIRAMATU,MASAMI
2015-12-10 18:57     ` Arnaldo Carvalho de Melo
2015-12-14  8:15   ` [tip:perf/core] " tip-bot for Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 02/16] perf top: Fix and cleanup perf_top__record_precise_ip() Namhyung Kim
2015-12-10 19:04   ` Arnaldo Carvalho de Melo
2015-12-11  2:27     ` Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 03/16] perf top: Factor out warnings about kernel addresses and symbols Namhyung Kim
2015-12-10 19:07   ` Arnaldo Carvalho de Melo
2015-12-14  1:44     ` Namhyung Kim
2015-12-14  2:02       ` Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 04/16] perf top: Factor out warnings in perf_top__record_precise_ip() Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 05/16] perf top: Show warning messages in the display thread Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 06/16] perf top: Get rid of access to hists->lock in perf_top__record_precise_ip() Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 07/16] perf hists: Pass hists struct to hist_entry_iter struct Namhyung Kim
2015-12-13 23:15   ` Jiri Olsa
2015-12-14  1:45     ` Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 08/16] perf tools: Export a couple of hist functions Namhyung Kim
2015-12-13 23:17   ` Jiri Olsa
2015-12-10  7:53 ` [PATCH/RFC 09/16] perf tools: Update hist entry's hists pointer Namhyung Kim
2015-12-13 23:23   ` Jiri Olsa
2015-12-13 23:28     ` Jiri Olsa
2015-12-14  1:51       ` Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 10/16] perf hist: Add events_stats__add() and hists__add_stats() Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 11/16] perf top: Implement basic parallel processing Namhyung Kim
2015-12-14  9:23   ` Jiri Olsa
2015-12-14  9:35     ` Jiri Olsa
2015-12-15  2:08       ` Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 12/16] perf tools: Reduce lock contention when processing events Namhyung Kim
2015-12-14  8:43   ` Jiri Olsa
2015-12-15  2:03     ` Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 13/16] perf top: Protect the seen list using mutex Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 14/16] perf top: Separate struct perf_top_stats Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 15/16] perf top: Add --num-thread option Namhyung Kim
2015-12-10  7:53 ` [PATCH/RFC 16/16] perf tools: Skip dso front cache for multi-threaded lookup Namhyung Kim
2015-12-10  8:01 ` [PATCHSET 00/16] perf top: Add multi-thread support (v1) Ingo Molnar
2015-12-10  8:49   ` Namhyung Kim
2015-12-11  8:11     ` Ingo Molnar
2015-12-11 15:01       ` David Ahern
2015-12-14  1:12         ` Namhyung Kim
2015-12-14  9:26         ` Peter Zijlstra
2015-12-14  9:38           ` Ingo Molnar
2015-12-14 14:55             ` David Ahern
2015-12-14 16:26               ` Arnaldo Carvalho de Melo
2015-12-14 16:41                 ` Peter Zijlstra
2015-12-14 17:52                   ` Arnaldo Carvalho de Melo
2015-12-14 16:38             ` Namhyung Kim
2015-12-14 16:56               ` Peter Zijlstra
2015-12-14 17:11                 ` Namhyung Kim
2015-12-14 14:46           ` David Ahern
2015-12-14 17:06             ` Namhyung Kim
2015-12-14 17:54               ` Arnaldo Carvalho de Melo
2015-12-14 16:25           ` Namhyung Kim
2015-12-14 16:44             ` Peter Zijlstra

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.