Messages in this thread | | | From | Namhyung Kim <> | Subject | [RFC 0/2] perf session: Separate struct machines from session | Date | Thu, 28 May 2015 11:39:02 +0900 |
| |
Hi Arnaldo,
This is what I have now for the earlier discussion [1]. I just used machines__new/delete functions directly whenever a session is created/deleted. As it touches many callsites, and it needs bit more caring about the error path, you may want to split the first patch for each command. In any case, pleaes let me know what do you think.
Note that this patchset bases on my (slightely modified) previous multi-thread patchset so will not be applied to the current perf/core. I'll rebase and send out after we conclude how to deal with it.
Thanks, Namhyung
[1] https://lkml.org/lkml/2015/5/19/1062
Namhyung Kim (2): perf tools: Introduce machines__new/delete() perf session: Separate struct machines from session
tools/perf/builtin-annotate.c | 7 ++++++- tools/perf/builtin-buildid-cache.c | 14 ++++++++++++-- tools/perf/builtin-buildid-list.c | 16 +++++++++++++--- tools/perf/builtin-diff.c | 16 ++++++++++++++-- tools/perf/builtin-evlist.c | 18 +++++++++++++++--- tools/perf/builtin-inject.c | 5 +++++ tools/perf/builtin-kmem.c | 14 +++++++++----- tools/perf/builtin-kvm.c | 14 +++++++++++++- tools/perf/builtin-lock.c | 7 ++++++- tools/perf/builtin-mem.c | 12 +++++++++--- tools/perf/builtin-record.c | 14 ++++++++++---- tools/perf/builtin-report.c | 13 ++++++++++--- tools/perf/builtin-sched.c | 8 +++++++- tools/perf/builtin-script.c | 32 ++++++++++++++++++++++++-------- tools/perf/builtin-timechart.c | 12 +++++++++--- tools/perf/builtin-top.c | 23 ++++++++++++++++------- tools/perf/builtin-trace.c | 10 ++++++++-- tools/perf/util/build-id.c | 16 ++++++++-------- tools/perf/util/data-convert-bt.c | 8 +++++++- tools/perf/util/intel-bts.c | 2 +- tools/perf/util/intel-pt.c | 2 +- tools/perf/util/machine.c | 15 +++++++++++++++ tools/perf/util/machine.h | 3 +++ tools/perf/util/session.c | 30 +++++++++++++++--------------- tools/perf/util/session.h | 6 +++--- tools/perf/util/tool.h | 2 ++ 26 files changed, 241 insertions(+), 78 deletions(-)
-- 2.4.1
| |