Skip to content

Special-case @cache for functions that return Bool #728

@AayushSabharwal

Description

@AayushSabharwal

Instead of storing cached entries in a Dict mapping arguments to true or false, we can just store two sets - one for inputs where the result is true and the other for false. A function that is biased toward true would clear the false cache less often, improving cache hit rate.

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