Documentation
¶
Overview ¶
Package callerlocation avoids redundant compiler-generated location records.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Tracker ¶
type Tracker struct {
// contains filtered or unexported fields
}
Tracker follows append-only IR emission. Its zero value is ready to use. A different block, location or intervening call requires a fresh record.
func (*Tracker) Checkpoint ¶
Checkpoint includes the newly emitted record in the checked prefix.
func (*Tracker) Repeated ¶
func (t *Tracker) Repeated(block llvm.BasicBlock, last llvm.Value, location Location, debug llvm.DebugLoc) bool
Repeated checks only the instructions appended since the last checkpoint. It always advances the checkpoint to last, regardless of the result. Linear scanning requires a live checkpoint at or before last in this block; reset the tracker after IR rewrites. Reaching the block head returns false. Calls (including inline assembly) and terminators are conservative barriers.