Linux Perf
trace-event-parse.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include "../perf.h"
#include "debug.h"
#include "trace-event.h"
#include "sane_ctype.h"
Include dependency graph for trace-event-parse.c:

Go to the source code of this file.

Classes

struct  flag
 

Functions

static int get_common_field (struct scripting_context *context, int *offset, int *size, const char *type)
 
int common_lock_depth (struct scripting_context *context)
 
int common_flags (struct scripting_context *context)
 
int common_pc (struct scripting_context *context)
 
unsigned long long raw_field_value (struct event_format *event, const char *name, void *data)
 
unsigned long long read_size (struct event_format *event, void *ptr, int size)
 
void event_format__fprintf (struct event_format *event, int cpu, void *data, int size, FILE *fp)
 
void event_format__print (struct event_format *event, int cpu, void *data, int size)
 
void parse_ftrace_printk (struct pevent *pevent, char *file, unsigned int size __maybe_unused)
 
void parse_saved_cmdline (struct pevent *pevent, char *file, unsigned int size __maybe_unused)
 
int parse_ftrace_file (struct pevent *pevent, char *buf, unsigned long size)
 
int parse_event_file (struct pevent *pevent, char *buf, unsigned long size, char *sys)
 
struct event_format * trace_find_next_event (struct pevent *pevent, struct event_format *event)
 
unsigned long long eval_flag (const char *flag)
 

Variables

static const struct flag flags []
 

Function Documentation

◆ common_flags()

int common_flags ( struct scripting_context context)

Definition at line 68 of file trace-event-parse.c.

Here is the call graph for this function:

◆ common_lock_depth()

int common_lock_depth ( struct scripting_context context)

Definition at line 54 of file trace-event-parse.c.

Here is the call graph for this function:

◆ common_pc()

int common_pc ( struct scripting_context context)

Definition at line 82 of file trace-event-parse.c.

Here is the call graph for this function:

◆ eval_flag()

unsigned long long eval_flag ( const char *  flag)

Definition at line 240 of file trace-event-parse.c.

◆ event_format__fprintf()

void event_format__fprintf ( struct event_format *  event,
int  cpu,
void *  data,
int  size,
FILE *  fp 
)

Definition at line 116 of file trace-event-parse.c.

Here is the call graph for this function:

◆ event_format__print()

void event_format__print ( struct event_format *  event,
int  cpu,
void *  data,
int  size 
)

Definition at line 133 of file trace-event-parse.c.

Here is the call graph for this function:

◆ get_common_field()

static int get_common_field ( struct scripting_context context,
int *  offset,
int *  size,
const char *  type 
)
static

Definition at line 32 of file trace-event-parse.c.

◆ parse_event_file()

int parse_event_file ( struct pevent *  pevent,
char *  buf,
unsigned long  size,
char *  sys 
)

Definition at line 186 of file trace-event-parse.c.

◆ parse_ftrace_file()

int parse_ftrace_file ( struct pevent *  pevent,
char *  buf,
unsigned long  size 
)

Definition at line 181 of file trace-event-parse.c.

◆ parse_ftrace_printk()

void parse_ftrace_printk ( struct pevent *  pevent,
char *  file,
unsigned int size  __maybe_unused 
)

Definition at line 139 of file trace-event-parse.c.

◆ parse_saved_cmdline()

void parse_saved_cmdline ( struct pevent *  pevent,
char *  file,
unsigned int size  __maybe_unused 
)

Definition at line 164 of file trace-event-parse.c.

Here is the call graph for this function:

◆ raw_field_value()

unsigned long long raw_field_value ( struct event_format *  event,
const char *  name,
void *  data 
)

Definition at line 97 of file trace-event-parse.c.

◆ read_size()

unsigned long long read_size ( struct event_format *  event,
void *  ptr,
int  size 
)

Definition at line 111 of file trace-event-parse.c.

◆ trace_find_next_event()

struct event_format* trace_find_next_event ( struct pevent *  pevent,
struct event_format *  event 
)

Definition at line 192 of file trace-event-parse.c.

Variable Documentation

◆ flags

const struct flag flags[]
static
Initial value:
= {
{ "HI_SOFTIRQ", 0 },
{ "TIMER_SOFTIRQ", 1 },
{ "NET_TX_SOFTIRQ", 2 },
{ "NET_RX_SOFTIRQ", 3 },
{ "BLOCK_SOFTIRQ", 4 },
{ "IRQ_POLL_SOFTIRQ", 5 },
{ "TASKLET_SOFTIRQ", 6 },
{ "SCHED_SOFTIRQ", 7 },
{ "HRTIMER_SOFTIRQ", 8 },
{ "RCU_SOFTIRQ", 9 },
{ "HRTIMER_NORESTART", 0 },
{ "HRTIMER_RESTART", 1 },
}

Definition at line 224 of file trace-event-parse.c.