Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 2c521d5

Browse files
Add images of graphs
1 parent b08f051 commit 2c521d5

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

‎src/img/region-graphviz.png

33.7 KB
Loading[フレーム]

‎src/img/scc-graphviz.png

42 KB
Loading[フレーム]

‎src/mir/dataflow.md

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -219,18 +219,23 @@ the example below:
219219

220220
### Region Constraint Graphs and Their Strongly Connected Components
221221

222+
![A graph showing a small number of regions with their outlives relations](../img/region-graphviz.png)
223+
222224
With `-Z dump-mir-graphviz=yes`, you will also get Graphviz files for the outlives constraints
223225
of the MIR bodies you asked for, as well as the strongly connected components (SCCs) on them.
224-
They are available as
226+
They are available as
225227
`mir_dump/rs-file-name.function-name.-------.nll.0.regioncx.all.dot` and
226228
`mir_dump/rs-file-name.function-name.-------.nll.0.regioncx.scc.dot` respectively. For both
227229
graphs, named region variables will be shown with their external name (such as `'static`)
228230
shown in parenthesis. For region inference variables in universes other than the root universe,
229-
they will be shown as `/U13` (for universe 13). In the region graph, edges are labelled with
230-
the MIR locations where the relationship holds.
231+
they will be shown as `/U13` (for universe 13). In the region graph, edges are labelled with
232+
the MIR locations where the relationship holds, or `All` if it's everywhere.
233+
234+
![A graph showing a small number of strongly connected components on the region-outlives-graph above](../img/scc-graphviz.png)
231235

232-
**Note:** there are implicit edges from `'static` to every region, but those are not rendered
233-
in the region graph to avoid clutter. They *do* however show up in the SCC graph.
236+
**Note:** There are implicit edges from `'static` to every region, but those are not rendered
237+
in the region graph to avoid clutter. They _do_ however show up in the SCC graph. This is why there are outgoing edges from SCC(5) in the SCC graph above
238+
that do not seem to have corresponding edges in the region outlives graph above.
234239

235240
["gen-kill" problems]: https://en.wikipedia.org/wiki/Data-flow_analysis#Bit_vector_problems
236241
[*Static Program Analysis*]: https://cs.au.dk/~amoeller/spa/

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /