Skip to content

Commit

Permalink
Auto merge of rust-lang#121516 - RalfJung:platform-intrinsics-begone,…
Browse files Browse the repository at this point in the history
… r=oli-obk

remove platform-intrinsics ABI; make SIMD intrinsics be regular intrinsics

`@Amanieu` `@workingjubilee` I don't think there is any reason these need to be "special"? The [original RFC](https://rust-lang.github.io/rfcs/1199-simd-infrastructure.html) indicated eventually making them stable, but I think that is no longer the plan, so seems to me like we can clean this up a bit.

Blocked on rust-lang/stdarch#1538, rust-lang#121542.
  • Loading branch information
bors committed Feb 26, 2024
2 parents fcb86c8 + 08e4eaf commit df6d031
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions example/float-minmax-pass.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,14 @@

// Test that the simd_f{min,max} intrinsics produce the correct results.

#![feature(repr_simd, platform_intrinsics)]
#![feature(repr_simd, core_intrinsics)]
#![allow(non_camel_case_types)]

#[repr(simd)]
#[derive(Copy, Clone, PartialEq, Debug)]
struct f32x4(pub f32, pub f32, pub f32, pub f32);

extern "platform-intrinsic" {
fn simd_fmin<T>(x: T, y: T) -> T;
fn simd_fmax<T>(x: T, y: T) -> T;
}
use std::intrinsics::simd::*;

fn main() {
let x = f32x4(1.0, 2.0, 3.0, 4.0);
Expand Down

0 comments on commit df6d031

Please sign in to comment.