Lines Matching full:from

43   bool addEdge(uptr from, uptr to) {  in addEdge()  argument
44 check(from, to); in addEdge()
45 return v[from].setBit(to); in addEdge()
49 uptr addEdges(const BV &from, uptr to, uptr added_edges[], in addEdges() argument
52 t1.copyFrom(from); in addEdges()
63 // Returns true if an edge from=>to exist.
65 // and thus can be called from different threads w/o locking.
68 bool hasEdge(uptr from, uptr to) { return v[from].getBit(to); } in hasEdge() argument
70 // Returns true if the edge from=>to was removed.
71 bool removeEdge(uptr from, uptr to) { in removeEdge() argument
72 return v[from].clearBit(to); in removeEdge()
78 for (uptr from = 0; from < size(); from++) { in removeEdgesTo() local
79 if (v[from].setDifference(to)) in removeEdgesTo()
85 // Returns true if at least one edge from=>* was removed.
86 bool removeEdgesFrom(const BV &from) { in removeEdgesFrom() argument
88 t1.copyFrom(from); in removeEdgesFrom()
99 void removeEdgesFrom(uptr from) { in removeEdgesFrom() argument
100 return v[from].clear(); in removeEdgesFrom()
103 bool hasEdge(uptr from, uptr to) const { in hasEdge() argument
104 check(from, to); in hasEdge()
105 return v[from].getBit(to); in hasEdge()
108 // Returns true if there is a path from the node 'from'
110 bool isReachable(uptr from, const BV &targets) { in isReachable() argument
113 to_visit.copyFrom(v[from]); in isReachable()
115 visited.setBit(from); in isReachable()
124 // Finds a path from 'from' to one of the nodes in 'target',
127 uptr findPath(uptr from, const BV &targets, uptr *path, uptr path_size) { in findPath() argument
130 path[0] = from; in findPath()
131 if (targets.getBit(from)) in findPath()
135 for (typename BV::Iterator it(v[from]); it.hasNext(); ) { in findPath()
144 uptr findShortestPath(uptr from, const BV &targets, uptr *path, in findShortestPath() argument
147 if (findPath(from, targets, path, p) == p) in findShortestPath()