Module flowistry::mir::engine

source ·
Expand description

This module re-implements rustc_mir_dataflow::Engine for performance reasons.

The Engine implementation in rustc optimizes for minimizing memory usage by only materializing results at the start of basic blocks, and recomputing the analysis when visiting results. However, this strategy involves a lot of creation and deletion of the analysis domain.

The information flow analysis has a large domain of size O(|places| * |locations|). Profiling showed that a significant portion of analysis time was just the engine allocating / cloning / dropping the domain, not doing computation. Therefore this engine improves performance but increases memory usage by up-front materializing the domain at every Location.

Structs

Functions