Documentation
¶
Index ¶
- Constants
- func LoadProfile() (*ebpf.CollectionSpec, error)
- func LoadProfileObjects(obj interface{}, opts *ebpf.CollectionOptions) error
- type PidOp
- type ProfileBssArg
- type ProfileMapSpecs
- type ProfileMaps
- type ProfileObjects
- type ProfileProgramSpecs
- type ProfilePrograms
- type ProfileSampleKey
- type ProfileSpecs
- type ProfilingType
- type SampleKeyFlag
Constants ¶
const MapNamePIDs = "pids"
Variables ¶
This section is empty.
Functions ¶
func LoadProfile ¶
func LoadProfile() (*ebpf.CollectionSpec, error)
LoadProfile returns the embedded CollectionSpec for Profile.
func LoadProfileObjects ¶
func LoadProfileObjects(obj interface{}, opts *ebpf.CollectionOptions) error
LoadProfileObjects loads Profile and converts it into a struct.
The following types are suitable as obj argument:
*ProfileObjects *ProfilePrograms *ProfileMaps
See ebpf.CollectionSpec.LoadAndAssign documentation for details.
Types ¶
type ProfileBssArg ¶ added in v0.6.1
type ProfileMapSpecs ¶
type ProfileMapSpecs struct {
Args *ebpf.MapSpec `ebpf:"args"`
Counts *ebpf.MapSpec `ebpf:"counts"`
Stacks *ebpf.MapSpec `ebpf:"stacks"`
}
ProfileMapSpecs contains maps before they are loaded into the kernel.
It can be passed ebpf.CollectionSpec.Assign.
type ProfileMaps ¶
type ProfileMaps struct {
Args *ebpf.Map `ebpf:"args"`
Counts *ebpf.Map `ebpf:"counts"`
Stacks *ebpf.Map `ebpf:"stacks"`
}
ProfileMaps contains all maps after they have been loaded into the kernel.
It can be passed to LoadProfileObjects or ebpf.CollectionSpec.LoadAndAssign.
func (*ProfileMaps) Close ¶
func (m *ProfileMaps) Close() error
type ProfileObjects ¶
type ProfileObjects struct {
ProfilePrograms
ProfileMaps
}
ProfileObjects contains all objects after they have been loaded into the kernel.
It can be passed to LoadProfileObjects or ebpf.CollectionSpec.LoadAndAssign.
func (*ProfileObjects) Close ¶
func (o *ProfileObjects) Close() error
type ProfileProgramSpecs ¶
type ProfileProgramSpecs struct {
DoPerfEvent *ebpf.ProgramSpec `ebpf:"do_perf_event"`
}
ProfileSpecs contains programs before they are loaded into the kernel.
It can be passed ebpf.CollectionSpec.Assign.
type ProfilePrograms ¶
ProfilePrograms contains all programs after they have been loaded into the kernel.
It can be passed to LoadProfileObjects or ebpf.CollectionSpec.LoadAndAssign.
func (*ProfilePrograms) Close ¶
func (p *ProfilePrograms) Close() error
type ProfileSampleKey ¶
type ProfileSpecs ¶
type ProfileSpecs struct {
ProfileProgramSpecs
ProfileMapSpecs
}
ProfileSpecs contains maps and programs before they are loaded into the kernel.
It can be passed ebpf.CollectionSpec.Assign.
type ProfilingType ¶
type ProfilingType uint8
var ( ProfilingTypeUnknown ProfilingType = 1 ProfilingTypeFramepointers ProfilingType = 2 ProfilingTypePython ProfilingType = 3 ProfilingTypeError ProfilingType = 4 )
type SampleKeyFlag ¶
type SampleKeyFlag uint32
var ( SampleKeyFlagPythonStack SampleKeyFlag = 1 SampleKeyFlagStackTruncated SampleKeyFlag = 2 )