bpf

package
v0.7.10 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 15, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type Exporter

type Exporter interface {
	HardwareCountersEnabled() bool
	Detach()
	CollectProcesses() ([]ProcessBPFMetrics, error)
	CollectCPUFreq() (map[int32]uint64, error)
	GetEnabledBPFHWCounters() []string
	GetEnabledBPFSWCounters() []string
}

func NewExporter

func NewExporter() (Exporter, error)

func NewMockExporter

func NewMockExporter(hardwareCountersEnabled bool) Exporter

type ProcessBPFMetrics

type ProcessBPFMetrics struct {
	CGroupID       uint64
	ThreadPID      uint64 /* thread id */
	PID            uint64 /* TGID of the threads, i.e. user space pid */
	ProcessRunTime uint64 /* in ms */
	TaskClockTime  uint64 /* in ms */
	CPUCycles      uint64
	CPUInstr       uint64
	CacheMisses    uint64
	PageCacheHit   uint64
	VecNR          [config.MaxIRQ]uint16 // irq counter, 10 is the max number of irq vectors
	Command        [16]byte
}

must be in sync with bpf program

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL