funcinfo

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2026 License: Apache-2.0 Imports: 4 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	EncodedRecordSize       = 28
	EncodedPCLineRecordSize = 24

	RecordFlagWrapper  uint32 = 1
	EncodedLineWrapper        = uint32(1 << 31)
	EncodedLineMask           = EncodedLineWrapper - 1
)
View Source
const DefaultPCPageShift = 12

Variables

This section is empty.

Functions

func HashString

func HashString(s string) uint32

func LookupPC

func LookupPC(entries []uint64, index PCIndex, pc uint64) int

Types

type EncodedPCLineRecord

type EncodedPCLineRecord struct {
	ID       uint64
	Func     uint32
	FileRoot uint32
	FileName uint32
	Line     uint32
}

type EncodedRecord

type EncodedRecord struct {
	SymbolPkg  uint32
	SymbolName uint32
	NamePkg    uint32
	NameName   uint32
	FileRoot   uint32
	FileName   uint32
	Line       uint32
}

type PCIndex

type PCIndex struct {
	PageShift uint
	Base      uint64
	Pages     []uint32
}

func BuildPCIndex

func BuildPCIndex(entries []uint64) PCIndex

func BuildPCIndexWithShift

func BuildPCIndexWithShift(entries []uint64, shift uint) PCIndex

type PCLineRecord

type PCLineRecord struct {
	ID     uint64
	Symbol string
	File   string
	Line   uint32
	Column uint32
}

type Record

type Record struct {
	Symbol string
	Name   string
	File   string
	Line   uint32
	Column uint32
	Flags  uint32
}

type Table

type Table struct {
	Records       []EncodedRecord
	PCLines       []EncodedPCLineRecord
	StringOffsets []uint32
	Strings       []byte
	Hash          []uint16
}

func Encode

func Encode(records []Record) (Table, error)

func EncodeWithPCLines

func EncodeWithPCLines(records []Record, pcLines []PCLineRecord) (Table, error)

func (Table) File

func (t Table) File(rec EncodedRecord) string

func (Table) LookupSymbol

func (t Table) LookupSymbol(symbol string) (int, bool)

func (Table) Name

func (t Table) Name(rec EncodedRecord) string

func (Table) PCLineFile

func (t Table) PCLineFile(rec EncodedPCLineRecord) string

func (Table) SizeBytes

func (t Table) SizeBytes() int

func (Table) String

func (t Table) String(id uint32) string

func (Table) Symbol

func (t Table) Symbol(rec EncodedRecord) string

Jump to

Keyboard shortcuts

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