binary

package
v0.0.1-rc9 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadShepherd

func LoadShepherd() (*ebpf.CollectionSpec, error)

LoadShepherd returns the embedded CollectionSpec for Shepherd.

func LoadShepherdObjects

func LoadShepherdObjects(obj interface{}, opts *ebpf.CollectionOptions) error

LoadShepherdObjects loads Shepherd and converts it into a struct.

The following types are suitable as obj argument:

*ShepherdObjects
*ShepherdPrograms
*ShepherdMaps

See ebpf.CollectionSpec.LoadAndAssign documentation for details.

Types

type ShepherdMapSpecs

type ShepherdMapSpecs struct {
	LastSample  *ebpf.MapSpec `ebpf:"last_sample"`
	SchedEvents *ebpf.MapSpec `ebpf:"sched_events"`
	WakeupTimes *ebpf.MapSpec `ebpf:"wakeup_times"`
}

ShepherdMapSpecs contains maps before they are loaded into the kernel.

It can be passed ebpf.CollectionSpec.Assign.

type ShepherdMaps

type ShepherdMaps struct {
	LastSample  *ebpf.Map `ebpf:"last_sample"`
	SchedEvents *ebpf.Map `ebpf:"sched_events"`
	WakeupTimes *ebpf.Map `ebpf:"wakeup_times"`
}

ShepherdMaps contains all maps after they have been loaded into the kernel.

It can be passed to LoadShepherdObjects or ebpf.CollectionSpec.LoadAndAssign.

func (*ShepherdMaps) Close

func (m *ShepherdMaps) Close() error

type ShepherdObjects

type ShepherdObjects struct {
	ShepherdPrograms
	ShepherdMaps
	ShepherdVariables
}

ShepherdObjects contains all objects after they have been loaded into the kernel.

It can be passed to LoadShepherdObjects or ebpf.CollectionSpec.LoadAndAssign.

func (*ShepherdObjects) Close

func (o *ShepherdObjects) Close() error

type ShepherdProgramSpecs

type ShepherdProgramSpecs struct {
	SchedSwitch    *ebpf.ProgramSpec `ebpf:"sched_switch"`
	SchedWakeup    *ebpf.ProgramSpec `ebpf:"sched_wakeup"`
	SchedWakeupNew *ebpf.ProgramSpec `ebpf:"sched_wakeup_new"`
}

ShepherdProgramSpecs contains programs before they are loaded into the kernel.

It can be passed ebpf.CollectionSpec.Assign.

type ShepherdPrograms

type ShepherdPrograms struct {
	SchedSwitch    *ebpf.Program `ebpf:"sched_switch"`
	SchedWakeup    *ebpf.Program `ebpf:"sched_wakeup"`
	SchedWakeupNew *ebpf.Program `ebpf:"sched_wakeup_new"`
}

ShepherdPrograms contains all programs after they have been loaded into the kernel.

It can be passed to LoadShepherdObjects or ebpf.CollectionSpec.LoadAndAssign.

func (*ShepherdPrograms) Close

func (p *ShepherdPrograms) Close() error

type ShepherdSchedLatencyT

type ShepherdSchedLatencyT struct {
	Pid           uint32
	Tid           uint32
	DelayNs       uint64
	Ts            uint64
	PreemptedPid  uint32
	PreemptedComm [16]int8
	IsPreempt     uint64
	Comm          [16]int8
}

type ShepherdSpecs

ShepherdSpecs contains maps and programs before they are loaded into the kernel.

It can be passed ebpf.CollectionSpec.Assign.

type ShepherdVariableSpecs

type ShepherdVariableSpecs struct {
	UnusedSchedLatencyT *ebpf.VariableSpec `ebpf:"unused_sched_latency_t"`
}

ShepherdVariableSpecs contains global variables before they are loaded into the kernel.

It can be passed ebpf.CollectionSpec.Assign.

type ShepherdVariables

type ShepherdVariables struct {
	UnusedSchedLatencyT *ebpf.Variable `ebpf:"unused_sched_latency_t"`
}

ShepherdVariables contains all global variables after they have been loaded into the kernel.

It can be passed to LoadShepherdObjects or ebpf.CollectionSpec.LoadAndAssign.

Jump to

Keyboard shortcuts

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