Call Graph
CallGraph dataclass
CallGraph(mt: ir.Method)
Bases: Printable
Call graph for a given ir.Method
.
This class implements the kirin.graph.Graph
protocol.
Pretty Printing
This object is pretty printable via .print()
method.
Source code in src/kirin/analysis/callgraph.py
25 26 27 28 |
|
backedges class-attribute
instance-attribute
backedges: dict[Method, set[Method]] = {}
Mapping from symbol names to backedges.
get_edges
get_edges() -> Iterable[tuple[ir.Method, ir.Method]]
Get the edges of the call graph.
Source code in src/kirin/analysis/callgraph.py
41 42 43 44 45 |
|
get_neighbors
get_neighbors(node: ir.Method) -> Iterable[ir.Method]
Get the neighbors of a node in the call graph.
Source code in src/kirin/analysis/callgraph.py
37 38 39 |
|
get_nodes
get_nodes() -> Iterable[ir.Method]
Get the nodes of the call graph.
Source code in src/kirin/analysis/callgraph.py
47 48 49 |
|