Rollup merge of #131551 - taiki-e:ppc-asm-vreg-inout, r=Amanieu
Support input/output in vector registers of PowerPC inline assembly This extends currently clobber-only vector registers (`vreg`) support to allow passing `#[repr(simd)]` types as input/output. | Architecture | Register class | Target feature | Allowed types | | ------------ | -------------- | -------------- | -------------- | | PowerPC | `vreg` | `altivec` | `i8x16`, `i16x8`, `i32x4`, `f32x4` | | PowerPC | `vreg` | `vsx` | `f32`, `f64`, `i64x2`, `f64x2` | In addition to floats and `core::simd` types listed above, `core::arch` types and custom `#[repr(simd)]` types of the same size and type are also allowed. All allowed types and relevant target features are currently unstable. r? `@Amanieu` `@rustbot` label +O-PowerPC +A-inline-assembly
This commit is contained in:
commit
1aa01927d3
12 changed files with 703 additions and 352 deletions
|
@ -51,7 +51,11 @@ impl PowerPCInlineAsmRegClass {
|
|||
}
|
||||
}
|
||||
Self::freg => types! { _: F32, F64; },
|
||||
Self::vreg => &[],
|
||||
// FIXME: vsx also supports integers?: https://github.com/rust-lang/rust/pull/131551#discussion_r1862535963
|
||||
Self::vreg => types! {
|
||||
altivec: VecI8(16), VecI16(8), VecI32(4), VecF32(4);
|
||||
vsx: F32, F64, VecI64(2), VecF64(2);
|
||||
},
|
||||
Self::cr | Self::xer => &[],
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue