Skip to content

Optimize byte validity representation #25

@jswrenn

Description

@jswrenn

In rust-lang/rust#139990, we had to reduce the size of the types under test in tests/ui/transmutability/maybeuninit.rs to accommodate a performance regression that stems from the unwieldy representation of u8 as a DFA with 255 edges. Consequently, the DFA of ExplicitlyPadded, in that UI test (which is only four bytes wide), is formidable:

Image

It might be possible to instead represent edges as bit sets, thereby condensing the above graph into just a few edges. Once this optimization is made, the tests in tests/ui/transmutability/maybeuninit.rs should be restored back to their original size.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions