]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
perf tools: Use just forward declarations for struct thread where possible
authorArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 20 Apr 2017 00:34:35 +0000 (21:34 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 24 Apr 2017 16:43:35 +0000 (13:43 -0300)
Removing various instances of unnecessary includes, reducing the maze of
header dependencies.

Link: http://lkml.kernel.org/n/tip-hwu6eyuok9pc57alookyzmsf@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
15 files changed:
tools/perf/arch/arm/util/unwind-libdw.c
tools/perf/arch/x86/util/unwind-libdw.c
tools/perf/builtin-c2c.c
tools/perf/builtin-inject.c
tools/perf/builtin-mem.c
tools/perf/builtin-timechart.c
tools/perf/ui/browsers/hists.c
tools/perf/ui/stdio/hist.c
tools/perf/util/build-id.c
tools/perf/util/hist.c
tools/perf/util/session.c
tools/perf/util/session.h
tools/perf/util/sort.c
tools/perf/util/sort.h
tools/perf/util/unwind-libdw.h

index b4176c60117a58b8dc8a4adf7a181576a542f7b0..bacfa00fca398ed59c1caa901cfe77d0e510f8b1 100644 (file)
@@ -1,6 +1,7 @@
 #include <elfutils/libdwfl.h>
 #include "../../util/unwind-libdw.h"
 #include "../../util/perf_regs.h"
+#include "../../util/event.h"
 
 bool libdw__arch_set_initial_registers(Dwfl_Thread *thread, void *arg)
 {
index c4b72176ca8361b024fbab0905422bca1a9657b0..38dc9bb2a7c90a7ee8cf8c5aca9078fecc546743 100644 (file)
@@ -1,6 +1,7 @@
 #include <elfutils/libdwfl.h>
 #include "../../util/unwind-libdw.h"
 #include "../../util/perf_regs.h"
+#include "../../util/event.h"
 
 bool libdw__arch_set_initial_registers(Dwfl_Thread *thread, void *arg)
 {
index a14be1cd3d70f0fe42c20c0b083cdab455ae7459..e33b4acece90aca126a50a91321bbd0cd3a533aa 100644 (file)
@@ -32,6 +32,7 @@
 #include <asm/bug.h>
 #include "ui/browsers/hists.h"
 #include "evlist.h"
+#include "thread.h"
 
 struct c2c_hists {
        struct hists            hists;
index 8bd791cca008252300c33118effad8af7c0a2f7a..ea8db38eedd10a987534da2c81a1ca83cbb2109f 100644 (file)
@@ -18,6 +18,7 @@
 #include "util/data.h"
 #include "util/auxtrace.h"
 #include "util/jit.h"
+#include "util/thread.h"
 
 #include <subcmd/parse-options.h>
 
index 2e5be1d63af6e7eefc5f5ec0ff05dc4802ac52cf..e001c02907937792d373f5245be0e6489b3e5210 100644 (file)
@@ -12,6 +12,7 @@
 #include "util/data.h"
 #include "util/mem-events.h"
 #include "util/debug.h"
+#include "util/symbol.h"
 
 #define MEM_OPERATION_LOAD     0x1
 #define MEM_OPERATION_STORE    0x2
index 38e2c437b7b311366916fb728d0750ef38ed78e4..4e2e61695986350a93b04b322712267068974e9e 100644 (file)
@@ -29,6 +29,7 @@
 #include <linux/rbtree.h>
 #include <linux/time64.h>
 #include "util/symbol.h"
+#include "util/thread.h"
 #include "util/callchain.h"
 
 #include "perf.h"
index 1b12a69740b31cc11d4877cd3006b2105460e819..69f4570bd4f941bee8a67fc48741994ce41a127e 100644 (file)
@@ -14,6 +14,7 @@
 #include "../../util/sort.h"
 #include "../../util/util.h"
 #include "../../util/top.h"
+#include "../../util/thread.h"
 #include "../../arch/common.h"
 
 #include "../browsers/hists.h"
index 5565105c9688d6e2323836144332407dac052892..42e432bd2eb4b59a1f15f6af69c788c66a62f1af 100644 (file)
@@ -6,6 +6,7 @@
 #include "../../util/evsel.h"
 #include "../../util/srcline.h"
 #include "../../util/string2.h"
+#include "../../util/thread.h"
 #include "../../util/sane_ctype.h"
 
 static size_t callchain__fprintf_left_margin(FILE *fp, int left_margin)
index 687b5add4bde3cb087cf976470001ee89ca6ee1d..168cc49654e7a4b18f69d177e29373f8a13e3471 100644 (file)
@@ -15,6 +15,7 @@
 #include "build-id.h"
 #include "event.h"
 #include "symbol.h"
+#include "thread.h"
 #include <linux/kernel.h>
 #include "debug.h"
 #include "session.h"
index 2944458b9edf90ebb985250bd144fd620f147f6f..cf0186a088c17f90c2357f1694af2241addf4eef 100644 (file)
@@ -9,6 +9,7 @@
 #include "evsel.h"
 #include "annotate.h"
 #include "srcline.h"
+#include "thread.h"
 #include "ui/progress.h"
 #include <errno.h>
 #include <math.h>
index 19d993f2a30565f1e7ce9521b22e15ad9af78cf6..3041c6b9819152cdd8ad5e856c735d2c7073d903 100644 (file)
@@ -19,6 +19,7 @@
 #include "perf_regs.h"
 #include "asm/bug.h"
 #include "auxtrace.h"
+#include "thread.h"
 #include "thread-stack.h"
 #include "stat.h"
 
index 1ffae42f76a1117eb9140ebf0e1a132aed2d657a..47b5e7dbcb18d420ea526508d0fbe0e1e3da7234 100644 (file)
@@ -5,8 +5,6 @@
 #include "event.h"
 #include "header.h"
 #include "machine.h"
-#include "symbol.h"
-#include "thread.h"
 #include "data.h"
 #include "ordered-events.h"
 #include <linux/kernel.h>
@@ -14,6 +12,7 @@
 #include <linux/perf_event.h>
 
 struct ip_callchain;
+struct symbol;
 struct thread;
 
 struct auxtrace;
index fe4fd7b5f8e0d3a44feb5a3efa39b1fef2411710..5762ae4e9e912e30dc158ee293c503373d80cc1f 100644 (file)
@@ -6,6 +6,7 @@
 #include "hist.h"
 #include "comm.h"
 #include "symbol.h"
+#include "thread.h"
 #include "evsel.h"
 #include "evlist.h"
 #include "strlist.h"
index 8bcec05ee578933395e7cbae800c50f343402e8b..b7c75597e18fd226c190e8fbb81ef610690f8541 100644 (file)
@@ -21,7 +21,8 @@
 #include "parse-events.h"
 #include "hist.h"
 #include "srcline.h"
-#include "thread.h"
+
+struct thread;
 
 extern regex_t parent_regex;
 extern const char *sort_order;
index 58328669ed16a7af3b475bb569b73310a48678df..4a2b269a7b3be24e766d892d475075984639b4cc 100644 (file)
@@ -2,10 +2,12 @@
 #define __PERF_UNWIND_LIBDW_H
 
 #include <elfutils/libdwfl.h>
-#include "event.h"
-#include "thread.h"
 #include "unwind.h"
 
+struct machine;
+struct perf_sample;
+struct thread;
+
 bool libdw__arch_set_initial_registers(Dwfl_Thread *thread, void *arg);
 
 struct unwind_info {