Home | History | Annotate | Download | only in trace

Lines Matching refs:Event

19 // Event describes one event in the trace.
20 type Event struct {
25 P int // P on which the event happened (can be one of TimerP, NetpollP, SyscallP)
26 G uint64 // G on which the event happened
29 Args [3]uint64 // event-type-specific arguments
30 // linked event (can be nil), depends on event type:
35 // for GoStart: the associated GoEnd, GoBlock or other blocking event
37 // for GoBlock and other blocking events: the unblock event
41 Link *Event
61 func Parse(r io.Reader) ([]*Event, error) {
89 // It does not care about specific event types and argument meaning.
104 // Read event type and number of arguments (1 byte).
127 // If narg == 3, the first value is length of the event in bytes.
143 return nil, fmt.Errorf("event has wrong length at offset 0x%x: want %v, got %v", off0, evLen, off-off1)
152 // It does analyze and verify per-event-type arguments.
153 func parseEvents(rawEvents []rawEvent) (events []*Event, err error) {
161 err = fmt.Errorf("unknown event type %v at offset 0x%x", raw.typ, raw.off)
166 err = fmt.Errorf("missing description for event type %v", raw.typ)
228 e := &Event{Off: raw.off, Type: raw.typ, P: lastP, G: lastG}
276 err = fmt.Errorf("no EvFrequency event")
300 func removeFutile(events []*Event) ([]*Event, error) {
305 // That is, we can see a futile wakeup event w/o the actual wakeup before it.
311 wakeup []*Event // wakeup sequence (subject for removal)
314 futile := make(map[*Event]bool)
319 g.wakeup = []*Event{ev}
351 // time stamps that do not respect actual event ordering.
354 // postProcessTrace does inter-event verification and information restoration.
357 // blocked before an unblock event).
358 func postProcessTrace(events []*Event) error {
367 ev *Event
368 evStart *Event
369 evCreate *Event
374 evScan *Event
375 evSweep *Event
381 var evGC *Event
383 checkRunning := func(p pdesc, g gdesc, ev *Event, allowG0 bool) error {
584 Event, bin string) error {
675 type eventList []*Event
690 func Print(events []*Event) {
701 // Event types in the trace.