Skip to content

Commit eb471db

Browse files
committed
Revert "Change implementation of vld1_dup"
This reverts commit 5f676a5.
1 parent 20ac12e commit eb471db

2 files changed

Lines changed: 9 additions & 9 deletions

File tree

crates/core_arch/src/arm_shared/neon/generated.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17912,8 +17912,8 @@ pub fn vhsubq_u32(a: uint32x4_t, b: uint32x4_t) -> uint32x4_t {
1791217912
#[unstable(feature = "stdarch_neon_f16", issue = "136306")]
1791317913
#[cfg(not(target_arch = "arm64ec"))]
1791417914
pub unsafe fn vld1_dup_f16(ptr: *const f16) -> float16x4_t {
17915-
let x = vld1_lane_f16::<0>(ptr, transmute(f16x4::splat(0.0)));
17916-
vdup_lane_f16::<0>(x)
17915+
let x: float16x4_t = vld1_lane_f16::<0>(ptr, transmute(f16x4::splat(0.0)));
17916+
simd_shuffle!(x, x, [0, 0, 0, 0])
1791717917
}
1791817918
#[doc = "Load one single-element structure and replicate to all lanes of one register"]
1791917919
#[doc = "[Arm's documentation](https://developer.arm.com/architectures/instruction-sets/intrinsics/vld1q_dup_f16)"]
@@ -17931,8 +17931,8 @@ pub unsafe fn vld1_dup_f16(ptr: *const f16) -> float16x4_t {
1793117931
#[unstable(feature = "stdarch_neon_f16", issue = "136306")]
1793217932
#[cfg(not(target_arch = "arm64ec"))]
1793317933
pub unsafe fn vld1q_dup_f16(ptr: *const f16) -> float16x8_t {
17934-
let x = vld1q_lane_f16::<0>(ptr, transmute(f16x8::splat(0.0)));
17935-
vdupq_laneq_f16::<0>(x)
17934+
let x: float16x8_t = vld1q_lane_f16::<0>(ptr, transmute(f16x8::splat(0.0)));
17935+
simd_shuffle!(x, x, [0, 0, 0, 0, 0, 0, 0, 0])
1793617936
}
1793717937
#[doc = "Load one single-element structure and Replicate to all lanes (of one register)."]
1793817938
#[doc = "[Arm's documentation](https://developer.arm.com/architectures/instruction-sets/intrinsics/vld1_dup_f32)"]

crates/stdarch-gen-arm/spec/neon/arm_shared.spec.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2850,7 +2850,7 @@ intrinsics:
28502850
- FnCall: [static_assert_uimm_bits!, [LANE, '{type[3]}']]
28512851
- FnCall: [simd_insert!, [src, "LANE as u32", "*ptr"]]
28522852

2853-
- name: "vld1{neon_type[1].dup_nox}"
2853+
- name: "vld1{type[2]}_{neon_type[1]}"
28542854
doc: "Load one single-element structure and replicate to all lanes of one register"
28552855
arguments: ["ptr: {type[0]}"]
28562856
return_type: "{neon_type[1]}"
@@ -2864,11 +2864,11 @@ intrinsics:
28642864
safety:
28652865
unsafe: [neon]
28662866
types:
2867-
- ["*const f16", float16x4_t, '_lane', 'f16x4']
2868-
- ["*const f16", float16x8_t, 'q_laneq', 'f16x8']
2867+
- ["*const f16", float16x4_t, '_dup', 'f16x4', "[0, 0, 0, 0]"]
2868+
- ["*const f16", float16x8_t, 'q_dup', 'f16x8', "[0, 0, 0, 0, 0, 0, 0, 0]"]
28692869
compose:
2870-
- Let: [x, {FnCall: ["vld1{neon_type[1].lane_nox}", [ptr, {FnCall: [transmute, ["{type[3]}::splat(0.0)"]]}], [0]]}]
2871-
- FnCall: ['vdup{type[2]}_{neon_type[1]}', [x], [0]]
2870+
- Let: [x, "{neon_type[1]}", "vld1{neon_type[1].lane_nox}::<0>(ptr, transmute({type[3]}::splat(0.0)))"]
2871+
- FnCall: [simd_shuffle!, [x, x, "{type[4]}"]]
28722872

28732873

28742874
- name: "vld2{neon_type[1].nox}"

0 commit comments

Comments
 (0)