Skip to content

Commit

Permalink
Add summary of the current state and future plans
Browse files Browse the repository at this point in the history
  • Loading branch information
ecstatic-morse committed Sep 18, 2019
1 parent 08aff1a commit a7f5252
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions src/librustc_mir/dataflow/generic.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,21 @@
//! Dataflow analysis with arbitrary transfer functions.
//!
//! This module is a work in progress. You should instead use `BitDenotation` in
//! `librustc_mir/dataflow/mod.rs` and encode your transfer function as a [gen/kill set][gk]. In
//! doing so, your analysis will run faster and you will be able to generate graphviz diagrams for
//! debugging with no extra effort. The interface in this module is intended only for dataflow
//! problems that cannot be expressed using gen/kill sets.
//!
//! FIXME(ecstaticmorse): In the long term, the plan is to preserve the existing `BitDenotation`
//! interface, but make `Engine` and `ResultsCursor` the canonical way to perform and inspect a
//! dataflow analysis. This requires porting the graphviz debugging logic to this module, deciding
//! on a way to handle the `before` methods in `BitDenotation` and creating an adapter so that
//! gen-kill problems can still be evaluated efficiently. See the discussion in [#64566][] for more
//! information.
//!
//! [gk]: https://en.wikipedia.org/wiki/Data-flow_analysis#Bit_vector_problems
//! [#64566]: https://github.com/rust-lang/rust/pull/64566

use std::cmp::Ordering;
use std::ops;

Expand Down

0 comments on commit a7f5252

Please sign in to comment.