Rollup merge of #139990 - jswrenn:no-nfas, r=tmiasko

transmutability: remove NFA intermediate representation

Prior to this commit, the transmutability analysis used an intermediate NFA representation of type layout. We then determinized this representation into a DFA, upon which we ran the core transmutability analysis. Unfortunately, determinizing NFAs is expensive. In this commit, we avoid NFAs entirely by observing that Rust `union`s are the only source of nondeterminism and that it is comparatively cheap to compute the DFA union of DFAs.

We also implement Graphviz DOT debug formatting of DFAs.

Fixes rust-lang/project-safe-transmute#23
Fixes rust-lang/project-safe-transmute#24

r? ``@compiler-errors``
This commit is contained in:
Chris Denton 2025-04-20 13:02:49 +00:00 committed by GitHub
commit 869d74f797
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

Diff Content Not Available