Techniques for graph data structure management
First Claim
1. A data structure having a plurality of nodes, wherein each node includes a current set of variables for defining a state of the node and at least one last-in, first-out stack for storing pointers to prior sets of variables for the node and wherein the state of the data structure is defined by the states of the nodes.
2 Assignments
0 Petitions
Accused Products
Abstract
Techniques for graph data structure management. In one aspect, a data structure includes a plurality of nodes connected by edges. A node of the data structure includes a current set of variables for defining a state of the node and at least one last-in, first-out stack for storing pointers to prior sets of variables for the node. The state of the node may be saved by adding a pointer to at least one of the stacks at the node. The state of the node may be restored by removing the pointer from the stack and restoring the node variables to those indicated by the pointer. A first counter associated with a stack at the node may store a number of pending saves at the node, while a second counter may store a number of saves to be propagated to descendents of the node. A state of the data structure may be saved by traversing other nodes of the data structure and adding pointers or incrementing counters at the nodes.
79 Citations
36 Claims
- 1. A data structure having a plurality of nodes, wherein each node includes a current set of variables for defining a state of the node and at least one last-in, first-out stack for storing pointers to prior sets of variables for the node and wherein the state of the data structure is defined by the states of the nodes.
- 13. A method for saving a state of a node in a data structure having a plurality of nodes, wherein the node includes a current set of variables for defining a state of the node, at least one last-in, first-out stack for storing pointers to prior sets of variables for the node, the method comprising adding a pointer to at least one of the stacks.
- 31. A method for saving a data structure state, the data structure having a plurality of nodes, wherein each node includes a current set of variables for defining a state of the node, at least one last-in, first-out stack for storing pointers to prior sets of variables for the node and a counter associated with each stack, the method comprising traversing the data structure and, at each node, incrementing the counter.
-
33. A method for restoring a data structure state, the data structure having a plurality of nodes, wherein each node includes a current set of variables for defining a state of the node, at least one last-in, first-out stack for storing pointers to prior sets of variables for the node and a counter associated with each stack, the method comprising traversing the data structure and, at each node, decrementing the counter if the counter is non-zero and, otherwise, removing a pointer from the stack and restoring the set of variables to those indicated by the pointer.
-
34. A method for discarding a data structure state, the data structure having a plurality of nodes connected by edges, wherein each node includes a current set of variables for defining a state of the node, at least one last-in, first-out stack for storing pointers to prior sets of variables for the node and a counter associated with each stack, the method comprising traversing the data structure and, at each node, decrementing the counter if the counter is non-zero and, otherwise, removing a pointer from the stack and discarding the pointer.
- 35. A program storage medium readable by a machine, tangibly embodying a program of instructions executable by the machine to perform method steps for saving a data structure state, the data structure having a plurality of nodes, wherein each node includes a current set of variables for defining a state of the node, at least one last-in, first-out stack for storing pointers to prior sets of variables for the node and a counter associated with each stack, said method steps including traversing the data structure and, at each node, incrementing the counter.
Specification