Linux Perf
kvm-stat.c File Reference
#include <errno.h>
#include "../../util/kvm-stat.h"
#include <asm/sie.h>
Include dependency graph for kvm-stat.c:

Go to the source code of this file.

Functions

 define_exit_reasons_table (sie_exit_reasons, sie_intercept_code)
 
 define_exit_reasons_table (sie_icpt_insn_codes, icpt_insn_codes)
 
 define_exit_reasons_table (sie_sigp_order_codes, sigp_order_codes)
 
 define_exit_reasons_table (sie_diagnose_codes, diagnose_codes)
 
 define_exit_reasons_table (sie_icpt_prog_codes, icpt_prog_codes)
 
static void event_icpt_insn_get_key (struct perf_evsel *evsel, struct perf_sample *sample, struct event_key *key)
 
static void event_sigp_get_key (struct perf_evsel *evsel, struct perf_sample *sample, struct event_key *key)
 
static void event_diag_get_key (struct perf_evsel *evsel, struct perf_sample *sample, struct event_key *key)
 
static void event_icpt_prog_get_key (struct perf_evsel *evsel, struct perf_sample *sample, struct event_key *key)
 
int cpu_isa_init (struct perf_kvm_stat *kvm, const char *cpuid)
 

Variables

const char * vcpu_id_str = "id"
 
const int decode_str_len = 40
 
const char * kvm_exit_reason = "icptcode"
 
const char * kvm_entry_trace = "kvm:kvm_s390_sie_enter"
 
const char * kvm_exit_trace = "kvm:kvm_s390_sie_exit"
 
static struct child_event_ops child_events []
 
static struct kvm_events_ops exit_events
 
const char * kvm_events_tp []
 
struct kvm_reg_events_ops kvm_reg_events_ops []
 
const char *const kvm_skip_events []
 

Function Documentation

◆ cpu_isa_init()

int cpu_isa_init ( struct perf_kvm_stat kvm,
const char *  cpuid 
)

Definition at line 103 of file kvm-stat.c.

◆ define_exit_reasons_table() [1/5]

define_exit_reasons_table ( sie_exit_reasons  ,
sie_intercept_code   
)

◆ define_exit_reasons_table() [2/5]

define_exit_reasons_table ( sie_icpt_insn_codes  ,
icpt_insn_codes   
)

◆ define_exit_reasons_table() [3/5]

define_exit_reasons_table ( sie_sigp_order_codes  ,
sigp_order_codes   
)

◆ define_exit_reasons_table() [4/5]

define_exit_reasons_table ( sie_diagnose_codes  ,
diagnose_codes   
)

◆ define_exit_reasons_table() [5/5]

define_exit_reasons_table ( sie_icpt_prog_codes  ,
icpt_prog_codes   
)

◆ event_diag_get_key()

static void event_diag_get_key ( struct perf_evsel evsel,
struct perf_sample sample,
struct event_key key 
)
static

Definition at line 47 of file kvm-stat.c.

Here is the call graph for this function:

◆ event_icpt_insn_get_key()

static void event_icpt_insn_get_key ( struct perf_evsel evsel,
struct perf_sample sample,
struct event_key key 
)
static

Definition at line 28 of file kvm-stat.c.

Here is the call graph for this function:

◆ event_icpt_prog_get_key()

static void event_icpt_prog_get_key ( struct perf_evsel evsel,
struct perf_sample sample,
struct event_key key 
)
static

Definition at line 55 of file kvm-stat.c.

Here is the call graph for this function:

◆ event_sigp_get_key()

static void event_sigp_get_key ( struct perf_evsel evsel,
struct perf_sample sample,
struct event_key key 
)
static

Definition at line 39 of file kvm-stat.c.

Here is the call graph for this function:

Variable Documentation

◆ child_events

struct child_event_ops child_events[]
static
Initial value:
= {
{ .name = "kvm:kvm_s390_intercept_instruction",
{ .name = "kvm:kvm_s390_handle_sigp",
.get_key = event_sigp_get_key },
{ .name = "kvm:kvm_s390_handle_diag",
.get_key = event_diag_get_key },
{ .name = "kvm:kvm_s390_intercept_prog",
{ NULL, NULL },
}
static void event_icpt_prog_get_key(struct perf_evsel *evsel, struct perf_sample *sample, struct event_key *key)
Definition: kvm-stat.c:55
static void event_sigp_get_key(struct perf_evsel *evsel, struct perf_sample *sample, struct event_key *key)
Definition: kvm-stat.c:39
static void event_icpt_insn_get_key(struct perf_evsel *evsel, struct perf_sample *sample, struct event_key *key)
Definition: kvm-stat.c:28
static void event_diag_get_key(struct perf_evsel *evsel, struct perf_sample *sample, struct event_key *key)
Definition: kvm-stat.c:47

Definition at line 63 of file kvm-stat.c.

◆ decode_str_len

const int decode_str_len = 40

Definition at line 23 of file kvm-stat.c.

◆ exit_events

struct kvm_events_ops exit_events
static
Initial value:
= {
.is_begin_event = exit_event_begin,
.is_end_event = exit_event_end,
.child_ops = child_events,
.decode_key = exit_event_decode_key,
.name = "VM-EXIT"
}
static struct child_event_ops child_events[]
Definition: kvm-stat.c:63
bool exit_event_begin(struct perf_evsel *evsel, struct perf_sample *sample, struct event_key *key)
void exit_event_decode_key(struct perf_kvm_stat *kvm, struct event_key *key, char *decode)
bool exit_event_end(struct perf_evsel *evsel, struct perf_sample *sample, struct event_key *key)

Definition at line 75 of file kvm-stat.c.

◆ kvm_entry_trace

const char* kvm_entry_trace = "kvm:kvm_s390_sie_enter"

Definition at line 25 of file kvm-stat.c.

◆ kvm_events_tp

const char* kvm_events_tp[]
Initial value:
= {
"kvm:kvm_s390_sie_enter",
"kvm:kvm_s390_sie_exit",
"kvm:kvm_s390_intercept_instruction",
"kvm:kvm_s390_handle_sigp",
"kvm:kvm_s390_handle_diag",
"kvm:kvm_s390_intercept_prog",
NULL,
}

Definition at line 83 of file kvm-stat.c.

◆ kvm_exit_reason

const char* kvm_exit_reason = "icptcode"

Definition at line 24 of file kvm-stat.c.

◆ kvm_exit_trace

const char* kvm_exit_trace = "kvm:kvm_s390_sie_exit"

Definition at line 26 of file kvm-stat.c.

◆ kvm_reg_events_ops

Initial value:
= {
{ .name = "vmexit", .ops = &exit_events },
{ NULL, NULL },
}
static struct kvm_events_ops exit_events
Definition: kvm-stat.c:75

Definition at line 93 of file kvm-stat.c.

◆ kvm_skip_events

const char* const kvm_skip_events[]
Initial value:
= {
"Wait state",
NULL,
}

Definition at line 98 of file kvm-stat.c.

◆ vcpu_id_str

const char* vcpu_id_str = "id"

Definition at line 22 of file kvm-stat.c.