ThreadsVisPrivate.mesa
Copyright Ó 1992 by Xerox Corporation. All rights reserved.
Weiser, March 13, 1993 9:36 am PST
Chauser, December 3, 1992 4:19 pm PST
DIRECTORY GGSlice, Rope;
ThreadsVisPrivate: CEDAR DEFINITIONS
~ BEGIN
ROPE: TYPE ~ Rope.ROPE;
ST: TYPE ~ LIST OF REF;
StackEntry: TYPE ~ REF StackEntryRep;
StackEntryRep: TYPE ~ RECORD [name: ROPE, id: CARD];
WorkItem: TYPE ~ REF WorkItemRep;
WorkItemRep: TYPE ~ RECORD [toDo: LIST OF REF ANY, doneAlready: LIST OF REF ANY];
ThreadFacts: TYPE ~ REF ThreadFactsRep;
ThreadFactsRep: TYPE ~ RECORD [
tlist: LIST OF Thread, -- all the threads
tree: REF, -- the head of the original tree of all stacks
stackTable: REF, -- CardTab mapping ID's in the stack to the stack itself
stackList: LIST OF REF ANY -- actually LIST OF REF, one for each unique stack
];
Thread: TYPE ~ REF ThreadRep;
ThreadRep: TYPE ~ RECORD [
tree: REF,
idList: REF, -- CardTab containing all the ID's of every stack entry
elist: LIST OF Event,
name: ROPE,
alias: ROPE,
nameTable: REF -- SymTab containing all the names appearing on the stack
];
EventFacts: TYPE ~ REF EventFactsRep;
EventFactsRep: TYPE ~ RECORD [
elist: LIST OF Event,
eventTable: REF, -- CardTab from event ID to Event
min, max: CARD, -- minimum and maximum times that events occured
nameTable: REF -- SymTab from name to list of events with that name
];
Event: TYPE ~ REF EventRep;
EventRep: TYPE ~ RECORD [ id: CARD, type: ATOM, time: CARD, node: CARD, wakeTime: CARD, wakeEvent: CARD, xstartpos, xendpos, ypos: CARD, drawn: BOOL];
Queue: TYPE ~ REF QueueRep;
PicLevel: TYPE ~ { background, execute, ready, uncertainSleep, wait, unknownThread, event, foreground };
QueueRep: TYPE ~ ARRAY PicLevel OF LIST OF GGSlice.Slice;
FrontBackType: TYPE = {front, back};
STName: PROC [st: ST] RETURNS [ROPE];
STChildren: PROC [st: ST] RETURNS [LIST OF REF];
ReadTreeFromFile: PUBLIC PROC [fileName: ROPE, throwAwayUnix: BOOL] RETURNS [threadFacts: ThreadsVisPrivate.ThreadFacts, eventFacts: ThreadsVisPrivate.EventFacts, commentText: ROPE];
END.