Skip to content

Commit 8cf042c

Browse files
syvbJoshua Nelson
authored and
Joshua Nelson
committed
Mention unpretty=mir-cfg for debugging MIR
1 parent a9bd2bb commit 8cf042c

File tree

2 files changed

+275
-0
lines changed

2 files changed

+275
-0
lines changed

src/mir/debugging.md

+5
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,11 @@ rustc.main.002-006.NoLandingPads.before.mir
8888
(Here, the `main-promoted[0]` files refer to the MIR for "promoted constants"
8989
that appeared within the `main` function.)
9090

91+
The `-Z unpretty=mir-cfg` flag can be used to create a graphviz MIR
92+
control-flow diagram for the whole crate:
93+
94+
![A control-flow diagram](mir_cfg.svg)
95+
9196
TODO: anything else?
9297

9398
[dataflow state]: ./dataflow.html#graphviz-diagrams

src/mir/mir_cfg.svg

+270
Loading

0 commit comments

Comments
 (0)