Home / Function/ computeDominatorTree() — react Function Reference

computeDominatorTree() — react Function Reference

Architecture documentation for the computeDominatorTree() function in Dominator.ts from the react codebase.

Entity Profile

Dependency Diagram

graph TD
  e28bcdab_2c48_d52f_7a36_ef26ead72639["computeDominatorTree()"]
  b02a9daf_aca4_b66a_9b9b_0b739a8ca4aa["Dominator.ts"]
  e28bcdab_2c48_d52f_7a36_ef26ead72639 -->|defined in| b02a9daf_aca4_b66a_9b9b_0b739a8ca4aa
  3785beb3_b04c_c433_176d_59b84fc0bbb7["buildGraph()"]
  e28bcdab_2c48_d52f_7a36_ef26ead72639 -->|calls| 3785beb3_b04c_c433_176d_59b84fc0bbb7
  9817c1db_b7a8_e8dc_1ed4_f224e36002e9["computeImmediateDominators()"]
  e28bcdab_2c48_d52f_7a36_ef26ead72639 -->|calls| 9817c1db_b7a8_e8dc_1ed4_f224e36002e9
  style e28bcdab_2c48_d52f_7a36_ef26ead72639 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

compiler/packages/babel-plugin-react-compiler/src/HIR/Dominator.ts lines 21–25

export function computeDominatorTree(fn: HIRFunction): Dominator<BlockId> {
  const graph = buildGraph(fn);
  const nodes = computeImmediateDominators(graph);
  return new Dominator(graph.entry, nodes);
}

Subdomains

Frequently Asked Questions

What does computeDominatorTree() do?
computeDominatorTree() is a function in the react codebase, defined in compiler/packages/babel-plugin-react-compiler/src/HIR/Dominator.ts.
Where is computeDominatorTree() defined?
computeDominatorTree() is defined in compiler/packages/babel-plugin-react-compiler/src/HIR/Dominator.ts at line 21.
What does computeDominatorTree() call?
computeDominatorTree() calls 2 function(s): buildGraph, computeImmediateDominators.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free