| 98 | std::string CallGraphNode::ToString() const { return computation_->name(); } |
| 99 | |
| 100 | void CallGraphNode::AddCallerCallSite(const CallSite& caller_callsite) { |
| 101 | caller_callsites_.push_back(caller_callsite); |
| 102 | HloComputation* caller = caller_callsite.instruction()->parent(); |
| 103 | if (!ContainsKey(caller_set_, caller)) { |
| 104 | callers_.push_back(caller); |
| 105 | caller_set_.insert(caller); |
| 106 | } |
| 107 | } |
| 108 | |
| 109 | void CallGraphNode::AddCallSiteForInstruction(HloInstruction* instruction) { |
| 110 | CHECK_EQ(instruction->parent(), computation()); |
no test coverage detected