Linux Perf
builtin-report.c File Reference
#include "builtin.h"
#include "util/util.h"
#include "util/config.h"
#include "util/annotate.h"
#include "util/color.h"
#include <linux/list.h>
#include <linux/rbtree.h>
#include <linux/err.h>
#include "util/symbol.h"
#include "util/callchain.h"
#include "util/values.h"
#include "perf.h"
#include "util/debug.h"
#include "util/evlist.h"
#include "util/evsel.h"
#include "util/header.h"
#include "util/session.h"
#include "util/tool.h"
#include <subcmd/parse-options.h>
#include <subcmd/exec-cmd.h>
#include "util/parse-events.h"
#include "util/thread.h"
#include "util/sort.h"
#include "util/hist.h"
#include "util/data.h"
#include "arch/common.h"
#include "util/time-utils.h"
#include "util/auxtrace.h"
#include "util/units.h"
#include "util/branch.h"
#include <dlfcn.h>
#include <errno.h>
#include <inttypes.h>
#include <regex.h>
#include <signal.h>
#include <linux/bitmap.h>
#include <linux/stringify.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
#include <linux/mman.h>
Include dependency graph for builtin-report.c:

Go to the source code of this file.

Classes

struct  report
 
struct  task
 

Macros

#define CALLCHAIN_DEFAULT_OPT   "graph,0.5,caller,function,percent"
 

Functions

static int report__config (const char *var, const char *value, void *cb)
 
static int hist_iter__report_callback (struct hist_entry_iter *iter, struct addr_location *al, bool single, void *arg)
 
static int hist_iter__branch_callback (struct hist_entry_iter *iter, struct addr_location *al __maybe_unused, bool single __maybe_unused, void *arg)
 
static void setup_forced_leader (struct report *report, struct perf_evlist *evlist)
 
static int process_feature_event (struct perf_tool *tool, union perf_event *event, struct perf_session *session __maybe_unused)
 
static int process_sample_event (struct perf_tool *tool, union perf_event *event, struct perf_sample *sample, struct perf_evsel *evsel, struct machine *machine)
 
static int process_read_event (struct perf_tool *tool, union perf_event *event, struct perf_sample *sample __maybe_unused, struct perf_evsel *evsel, struct machine *machine __maybe_unused)
 
static int report__setup_sample_type (struct report *rep)
 
static void sig_handler (int sig __maybe_unused)
 
static size_t hists__fprintf_nr_sample_events (struct hists *hists, struct report *rep, const char *evname, FILE *fp)
 
static int perf_evlist__tty_browse_hists (struct perf_evlist *evlist, struct report *rep, const char *help)
 
static void report__warn_kptr_restrict (const struct report *rep)
 
static int report__gtk_browse_hists (struct report *rep, const char *help)
 
static int report__browse_hists (struct report *rep)
 
static int report__collapse_hists (struct report *rep)
 
static void report__output_resort (struct report *rep)
 
static void stats_setup (struct report *rep)
 
static int stats_print (struct report *rep)
 
static void tasks_setup (struct report *rep)
 
static struct tasktasks_list (struct task *task, struct machine *machine)
 
static size_t maps__fprintf_task (struct maps *maps, int indent, FILE *fp)
 
static int map_groups__fprintf_task (struct map_groups *mg, int indent, FILE *fp)
 
static void task__print_level (struct task *task, FILE *fp, int level)
 
static int tasks_print (struct report *rep, FILE *fp)
 
static int __cmd_report (struct report *rep)
 
static int report_parse_callchain_opt (const struct option *opt, const char *arg, int unset)
 
int report_parse_ignore_callees_opt (const struct option *opt __maybe_unused, const char *arg, int unset __maybe_unused)
 
static int parse_branch_mode (const struct option *opt, const char *str __maybe_unused, int unset)
 
static int parse_percent_limit (const struct option *opt, const char *str, int unset __maybe_unused)
 
int cmd_report (int argc, const char **argv)
 

Macro Definition Documentation

◆ CALLCHAIN_DEFAULT_OPT

#define CALLCHAIN_DEFAULT_OPT   "graph,0.5,caller,function,percent"

Function Documentation

◆ __cmd_report()

static int __cmd_report ( struct report rep)
static

Definition at line 796 of file builtin-report.c.

Here is the call graph for this function:

◆ cmd_report()

int cmd_report ( int  argc,
const char **  argv 
)

Definition at line 949 of file builtin-report.c.

Here is the call graph for this function:

◆ hist_iter__branch_callback()

static int hist_iter__branch_callback ( struct hist_entry_iter iter,
struct addr_location *al  __maybe_unused,
bool single  __maybe_unused,
void *  arg 
)
static

Definition at line 165 of file builtin-report.c.

Here is the call graph for this function:

◆ hist_iter__report_callback()

static int hist_iter__report_callback ( struct hist_entry_iter iter,
struct addr_location al,
bool  single,
void *  arg 
)
static

Definition at line 120 of file builtin-report.c.

Here is the call graph for this function:

◆ hists__fprintf_nr_sample_events()

static size_t hists__fprintf_nr_sample_events ( struct hists hists,
struct report rep,
const char *  evname,
FILE *  fp 
)
static

Definition at line 393 of file builtin-report.c.

Here is the call graph for this function:

◆ map_groups__fprintf_task()

static int map_groups__fprintf_task ( struct map_groups mg,
int  indent,
FILE *  fp 
)
static

Definition at line 707 of file builtin-report.c.

Here is the call graph for this function:

◆ maps__fprintf_task()

static size_t maps__fprintf_task ( struct maps maps,
int  indent,
FILE *  fp 
)
static

Definition at line 686 of file builtin-report.c.

◆ parse_branch_mode()

static int parse_branch_mode ( const struct option *  opt,
const char *str  __maybe_unused,
int  unset 
)
static

Definition at line 928 of file builtin-report.c.

◆ parse_percent_limit()

static int parse_percent_limit ( const struct option *  opt,
const char *  str,
int unset  __maybe_unused 
)
static

Definition at line 938 of file builtin-report.c.

◆ perf_evlist__tty_browse_hists()

static int perf_evlist__tty_browse_hists ( struct perf_evlist evlist,
struct report rep,
const char *  help 
)
static

Definition at line 459 of file builtin-report.c.

Here is the call graph for this function:

◆ process_feature_event()

static int process_feature_event ( struct perf_tool tool,
union perf_event event,
struct perf_session *session  __maybe_unused 
)
static

Definition at line 204 of file builtin-report.c.

Here is the call graph for this function:

◆ process_read_event()

static int process_read_event ( struct perf_tool tool,
union perf_event event,
struct perf_sample *sample  __maybe_unused,
struct perf_evsel evsel,
struct machine *machine  __maybe_unused 
)
static

Definition at line 289 of file builtin-report.c.

Here is the call graph for this function:

◆ process_sample_event()

static int process_sample_event ( struct perf_tool tool,
union perf_event event,
struct perf_sample sample,
struct perf_evsel evsel,
struct machine machine 
)
static

Definition at line 227 of file builtin-report.c.

Here is the call graph for this function:

◆ report__browse_hists()

static int report__browse_hists ( struct report rep)
static

Definition at line 545 of file builtin-report.c.

Here is the call graph for this function:

◆ report__collapse_hists()

static int report__collapse_hists ( struct report rep)
static

Definition at line 583 of file builtin-report.c.

Here is the call graph for this function:

◆ report__config()

static int report__config ( const char *  var,
const char *  value,
void *  cb 
)
static

Definition at line 90 of file builtin-report.c.

Here is the call graph for this function:

◆ report__gtk_browse_hists()

static int report__gtk_browse_hists ( struct report rep,
const char *  help 
)
static

Definition at line 530 of file builtin-report.c.

Here is the call graph for this function:

◆ report__output_resort()

static void report__output_resort ( struct report rep)
static

Definition at line 617 of file builtin-report.c.

Here is the call graph for this function:

◆ report__setup_sample_type()

static int report__setup_sample_type ( struct report rep)
static

Definition at line 313 of file builtin-report.c.

Here is the call graph for this function:

◆ report__warn_kptr_restrict()

static void report__warn_kptr_restrict ( const struct report rep)
static

Definition at line 501 of file builtin-report.c.

Here is the call graph for this function:

◆ report_parse_callchain_opt()

static int report_parse_callchain_opt ( const struct option *  opt,
const char *  arg,
int  unset 
)
static

Definition at line 892 of file builtin-report.c.

Here is the call graph for this function:

◆ report_parse_ignore_callees_opt()

int report_parse_ignore_callees_opt ( const struct option *opt  __maybe_unused,
const char *  arg,
int unset  __maybe_unused 
)

Definition at line 910 of file builtin-report.c.

◆ setup_forced_leader()

static void setup_forced_leader ( struct report report,
struct perf_evlist evlist 
)
static

Definition at line 197 of file builtin-report.c.

Here is the call graph for this function:

◆ sig_handler()

static void sig_handler ( int sig  __maybe_unused)
static

Definition at line 388 of file builtin-report.c.

◆ stats_print()

static int stats_print ( struct report rep)
static

Definition at line 636 of file builtin-report.c.

Here is the call graph for this function:

◆ stats_setup()

static void stats_setup ( struct report rep)
static

Definition at line 630 of file builtin-report.c.

Here is the call graph for this function:

◆ task__print_level()

static void task__print_level ( struct task task,
FILE *  fp,
int  level 
)
static

Definition at line 712 of file builtin-report.c.

Here is the call graph for this function:

◆ tasks_list()

static struct task* tasks_list ( struct task task,
struct machine machine 
)
static

Definition at line 664 of file builtin-report.c.

Here is the call graph for this function:

◆ tasks_print()

static int tasks_print ( struct report rep,
FILE *  fp 
)
static

Definition at line 730 of file builtin-report.c.

Here is the call graph for this function:

◆ tasks_setup()

static void tasks_setup ( struct report rep)
static

Definition at line 644 of file builtin-report.c.

Here is the call graph for this function: