LLDB  mainline
Classes | Functions
PerfContextSwitchDecoder.cpp File Reference
#include "PerfContextSwitchDecoder.h"
Include dependency graph for PerfContextSwitchDecoder.cpp:

Go to the source code of this file.

Classes

struct  perf_event_header
 
struct  PerfContextSwitchRecord
 Record found in the perf_event context switch traces. More...
 
struct  ContextSwitchRecord
 Record produced after parsing the raw context switch trace produce by perf_event. More...
 

Macros

#define PERF_RECORD_MISC_SWITCH_OUT   (1 << 13)
 Copied from <linux/perf_event.h> to avoid depending on perf_event.h on non-linux platforms. More...
 
#define PERF_RECORD_LOST   2
 
#define PERF_RECORD_THROTTLE   5
 
#define PERF_RECORD_UNTHROTTLE   6
 
#define PERF_RECORD_LOST_SAMPLES   13
 
#define PERF_RECORD_SWITCH_CPU_WIDE   15
 
#define PERF_RECORD_MAX   19
 

Functions

static Error RecoverExecutionsFromConsecutiveRecords (cpu_id_t cpu_id, const LinuxPerfZeroTscConversion &tsc_conversion, const ContextSwitchRecord &current_record, const Optional< ContextSwitchRecord > &prev_record, std::function< void(const ThreadContinuousExecution &execution)> on_new_execution)
 

Macro Definition Documentation

◆ PERF_RECORD_LOST

#define PERF_RECORD_LOST   2

Definition at line 20 of file PerfContextSwitchDecoder.cpp.

◆ PERF_RECORD_LOST_SAMPLES

#define PERF_RECORD_LOST_SAMPLES   13

Definition at line 23 of file PerfContextSwitchDecoder.cpp.

◆ PERF_RECORD_MAX

#define PERF_RECORD_MAX   19

Definition at line 25 of file PerfContextSwitchDecoder.cpp.

◆ PERF_RECORD_MISC_SWITCH_OUT

#define PERF_RECORD_MISC_SWITCH_OUT   (1 << 13)

Copied from <linux/perf_event.h> to avoid depending on perf_event.h on non-linux platforms.

Definition at line 18 of file PerfContextSwitchDecoder.cpp.

◆ PERF_RECORD_SWITCH_CPU_WIDE

#define PERF_RECORD_SWITCH_CPU_WIDE   15

Definition at line 24 of file PerfContextSwitchDecoder.cpp.

◆ PERF_RECORD_THROTTLE

#define PERF_RECORD_THROTTLE   5

Definition at line 21 of file PerfContextSwitchDecoder.cpp.

◆ PERF_RECORD_UNTHROTTLE

#define PERF_RECORD_UNTHROTTLE   6

Definition at line 22 of file PerfContextSwitchDecoder.cpp.

Function Documentation

◆ RecoverExecutionsFromConsecutiveRecords()

static Error RecoverExecutionsFromConsecutiveRecords ( cpu_id_t  cpu_id,
const LinuxPerfZeroTscConversion tsc_conversion,
const ContextSwitchRecord current_record,
const Optional< ContextSwitchRecord > &  prev_record,
std::function< void(const ThreadContinuousExecution &execution)>  on_new_execution 
)
static