Skip to content

#[target_feature(enable="...")] does not enable use of feature-specific registers  #89289

Closed

Description

On x86 the following does not compile:

#![feature(asm)]

#[target_feature(enable="avx")]
pub unsafe fn foo() {
    let mut x = 0;
    asm!("vmovaps {}, {}", lateout(ymm_reg) x, in(ymm_reg) x);
}

ubt it does compile with -Ctarget-feature=+avx specified. Both should work?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Labels

F-asm`#![feature(asm)]` (not `llvm_asm`)

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions