Skip to content

Miri doesn't respect target-feature in doc tests #3869

Closed
@Kixunil

Description

@Kixunil

When code under miri reaches a function annotated with #[target_feature(enable = "...")] in doc tests miri throws an error saying "calling a function that requires unavailable target features" despite this being in the if block that checks the features using is_x86_feature_enabled! and despite having -C target-feature=... on the command line. The same issue is not present in non-doc tests and the same code works fine.

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