proc

package
v0.0.0-...-f8ea316 Latest Latest
Warning

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

Go to latest
Published: Feb 14, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindPerfMapNStgid

func FindPerfMapNStgid(pid int) int

func FindPerfMapPath

func FindPerfMapPath(pid int) string

func HostPath

func HostPath(paths ...string) string

func HostProcPath

func HostProcPath(paths ...string) string

func HostProcRoot

func HostProcRoot(pid int) string

func IsPerfMap

func IsPerfMap(path string) bool

func IsVDSO

func IsVDSO(name string) bool

func IsValidPerfMap

func IsValidPerfMap(path string) bool

func ProcPath

func ProcPath(paths ...string) string

func ProcRoot

func ProcRoot(pid int) string

Types

type File

type File struct {
	Dev   uint64
	Inode uint64
	Path  string
}

type Map

type Map struct {
	Pathname   string
	StartAddr  uint64
	EndAddr    uint64
	FileOffset uint
	DevMajor   uint32
	DevMinor   uint32
	Inode      uint64
	InMem      bool
}

func ParseProcMaps

func ParseProcMaps(pid int) ([]*Map, error)

func (*Map) File

func (m *Map) File() File

func (*Map) String

func (m *Map) String() string

type Pid

type Pid int

func (Pid) String

func (p Pid) String() string

type PidInfo

type PidInfo struct {
	Pid       int
	Exe       string
	Comm      string
	StartTime time.Time
}

func (*PidInfo) DeepCopy

func (p *PidInfo) DeepCopy() *PidInfo

func (*PidInfo) String

func (p *PidInfo) String() string

type Stat

type Stat struct {
	// contains filtered or unexported fields
}

func ProcStat

func ProcStat(pid int) (*Stat, error)

func (*Stat) GetRootFD

func (s *Stat) GetRootFD() int

func (*Stat) IsStale

func (s *Stat) IsStale() bool

func (*Stat) PidInfo

func (s *Stat) PidInfo() *PidInfo

func (*Stat) RefreshRoot

func (s *Stat) RefreshRoot() bool

func (*Stat) Reset

func (s *Stat) Reset()

Jump to

Keyboard shortcuts

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