about summary refs log tree commit diff
path: root/src/test/debuginfo/enum-thinlto.rs
diff options
context:
space:
mode:
authorDylan MacKenzie <ecstaticmorse@gmail.com>2020-05-06 11:38:59 -0700
committerDylan MacKenzie <ecstaticmorse@gmail.com>2020-05-19 17:50:05 -0700
commitfc964c5317f52e6ca7d8e62cc976d2b920a32a15 (patch)
tree650a0ec96070b523451b0900afd925124da222b5 /src/test/debuginfo/enum-thinlto.rs
parentdaea09cf91fdf50c03500784d0f1612db42afd2b (diff)
downloadrust-fc964c5317f52e6ca7d8e62cc976d2b920a32a15.tar.gz
rust-fc964c5317f52e6ca7d8e62cc976d2b920a32a15.zip
Clean up generator live locals analysis
Instead of using a bespoke dataflow analysis, `MaybeRequiresStorage`,
for computing locals that need to be stored across yield points and that
have conflicting storage, use a combination of simple, generally
applicable dataflow analyses. In this case, the formula for locals
that are live at a yield point is:

    live_across_yield := (live & init) | (!movable & borrowed)

and the formula for locals that require storage (and thus may conflict
with others) at a given point is:

    requires_storage := init | borrowed

`init` is `MaybeInitializedLocals`, a direct equivalent of
`MaybeInitializedPlaces` that works only on whole `Local`s. `borrowed`
and `live` are the pre-existing `MaybeBorrowedLocals` and
`MaybeLiveLocals` analyses respectively.
Diffstat (limited to 'src/test/debuginfo/enum-thinlto.rs')
0 files changed, 0 insertions, 0 deletions