rustc-dev-guide icon indicating copy to clipboard operation
rustc-dev-guide copied to clipboard

Elaborate on dataflow outputs for region constraints

Open amandasystems opened this issue 1 year ago • 6 comments

amandasystems avatar Apr 30 '24 10:04 amandasystems

I see Zed snuck in some Markdown normalisation too while it was at it. Sorry about that, let me know if that's inexcusable and I will revert those changes.

amandasystems avatar Apr 30 '24 10:04 amandasystems

I will revert those changes

Please do yes, if it's not too hard. It will make review easier.

I'll take a closer look when I have more time, but I noted a couple of things:

  • "With -Z dump-mir-graphviz=yes, you will also get Graphviz files for the outlives constraints" is that the case? Did you maybe mean -Zdump-mir=nll?
  • I don't think these visualizations are from MIR dataflow, so the new paragraph may need to be moved to somewhere more related to borrowck

lqd avatar May 01 '24 15:05 lqd

Please do yes, if it's not too hard. It will make review easier.

Done!

"With -Z dump-mir-graphviz=yes, you will also get Graphviz files for the outlives constraints" is that the case? Did you maybe mean -Zdump-mir=nll?

Huh! Apparently, -Z dump-mir=fn is enough to get those. I assumed it wouldn't drop graphviz files without the Graphviz option, but apparently it does! dump-mir=nll also works and now I'm worried it will dump different graphs.

I don't think these visualizations are from MIR dataflow, so the new paragraph may need to be moved to somewhere more related to borrowck

That's probably true; this should be in the borrowck chapter, maybe? Do you have a suggestion off the top of your head or should I go digging?

amandasystems avatar May 02 '24 09:05 amandasystems

Not from the top of my head but I will look for one -- but yeah I agree this should be in the borrowck chapter most likely.

lqd avatar May 02 '24 20:05 lqd