Skip to content

Commit 0215f9a

Browse files
eduardosmAmanieu
authored andcommitted
Remove unneeded transmutes in ARM code, except generated tests
1 parent ae0a3e6 commit 0215f9a

File tree

5 files changed

+166
-236
lines changed

5 files changed

+166
-236
lines changed

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

+24-24
Original file line numberDiff line numberDiff line change
@@ -7671,7 +7671,7 @@ pub unsafe fn vst2q_s64(a: *mut i64, b: int64x2x2_t) {
76717671
#[cfg_attr(test, assert_instr(st2))]
76727672
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
76737673
pub unsafe fn vst2q_u64(a: *mut u64, b: uint64x2x2_t) {
7674-
transmute(vst2q_s64(transmute(a), transmute(b)))
7674+
vst2q_s64(transmute(a), transmute(b))
76757675
}
76767676

76777677
/// Store multiple 2-element structures from two registers
@@ -7682,7 +7682,7 @@ pub unsafe fn vst2q_u64(a: *mut u64, b: uint64x2x2_t) {
76827682
#[cfg_attr(test, assert_instr(st2))]
76837683
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
76847684
pub unsafe fn vst2q_p64(a: *mut p64, b: poly64x2x2_t) {
7685-
transmute(vst2q_s64(transmute(a), transmute(b)))
7685+
vst2q_s64(transmute(a), transmute(b))
76867686
}
76877687

76887688
/// Store multiple 2-element structures from two registers
@@ -7781,7 +7781,7 @@ pub unsafe fn vst2q_lane_s64<const LANE: i32>(a: *mut i64, b: int64x2x2_t) {
77817781
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
77827782
pub unsafe fn vst2q_lane_u8<const LANE: i32>(a: *mut u8, b: uint8x16x2_t) {
77837783
static_assert_uimm_bits!(LANE, 4);
7784-
transmute(vst2q_lane_s8::<LANE>(transmute(a), transmute(b)))
7784+
vst2q_lane_s8::<LANE>(transmute(a), transmute(b))
77857785
}
77867786

77877787
/// Store multiple 2-element structures from two registers
@@ -7794,7 +7794,7 @@ pub unsafe fn vst2q_lane_u8<const LANE: i32>(a: *mut u8, b: uint8x16x2_t) {
77947794
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
77957795
pub unsafe fn vst2_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x1x2_t) {
77967796
static_assert!(LANE == 0);
7797-
transmute(vst2_lane_s64::<LANE>(transmute(a), transmute(b)))
7797+
vst2_lane_s64::<LANE>(transmute(a), transmute(b))
77987798
}
77997799

78007800
/// Store multiple 2-element structures from two registers
@@ -7807,7 +7807,7 @@ pub unsafe fn vst2_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x1x2_t) {
78077807
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
78087808
pub unsafe fn vst2q_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x2x2_t) {
78097809
static_assert_uimm_bits!(LANE, 1);
7810-
transmute(vst2q_lane_s64::<LANE>(transmute(a), transmute(b)))
7810+
vst2q_lane_s64::<LANE>(transmute(a), transmute(b))
78117811
}
78127812

78137813
/// Store multiple 2-element structures from two registers
@@ -7820,7 +7820,7 @@ pub unsafe fn vst2q_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x2x2_t) {
78207820
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
78217821
pub unsafe fn vst2q_lane_p8<const LANE: i32>(a: *mut p8, b: poly8x16x2_t) {
78227822
static_assert_uimm_bits!(LANE, 4);
7823-
transmute(vst2q_lane_s8::<LANE>(transmute(a), transmute(b)))
7823+
vst2q_lane_s8::<LANE>(transmute(a), transmute(b))
78247824
}
78257825

78267826
/// Store multiple 2-element structures from two registers
@@ -7833,7 +7833,7 @@ pub unsafe fn vst2q_lane_p8<const LANE: i32>(a: *mut p8, b: poly8x16x2_t) {
78337833
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
78347834
pub unsafe fn vst2_lane_p64<const LANE: i32>(a: *mut p64, b: poly64x1x2_t) {
78357835
static_assert!(LANE == 0);
7836-
transmute(vst2_lane_s64::<LANE>(transmute(a), transmute(b)))
7836+
vst2_lane_s64::<LANE>(transmute(a), transmute(b))
78377837
}
78387838

78397839
/// Store multiple 2-element structures from two registers
@@ -7846,7 +7846,7 @@ pub unsafe fn vst2_lane_p64<const LANE: i32>(a: *mut p64, b: poly64x1x2_t) {
78467846
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
78477847
pub unsafe fn vst2q_lane_p64<const LANE: i32>(a: *mut p64, b: poly64x2x2_t) {
78487848
static_assert_uimm_bits!(LANE, 1);
7849-
transmute(vst2q_lane_s64::<LANE>(transmute(a), transmute(b)))
7849+
vst2q_lane_s64::<LANE>(transmute(a), transmute(b))
78507850
}
78517851

78527852
/// Store multiple 2-element structures from two registers
@@ -7909,7 +7909,7 @@ pub unsafe fn vst3q_s64(a: *mut i64, b: int64x2x3_t) {
79097909
#[cfg_attr(test, assert_instr(st3))]
79107910
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
79117911
pub unsafe fn vst3q_u64(a: *mut u64, b: uint64x2x3_t) {
7912-
transmute(vst3q_s64(transmute(a), transmute(b)))
7912+
vst3q_s64(transmute(a), transmute(b))
79137913
}
79147914

79157915
/// Store multiple 3-element structures from three registers
@@ -7920,7 +7920,7 @@ pub unsafe fn vst3q_u64(a: *mut u64, b: uint64x2x3_t) {
79207920
#[cfg_attr(test, assert_instr(st3))]
79217921
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
79227922
pub unsafe fn vst3q_p64(a: *mut p64, b: poly64x2x3_t) {
7923-
transmute(vst3q_s64(transmute(a), transmute(b)))
7923+
vst3q_s64(transmute(a), transmute(b))
79247924
}
79257925

79267926
/// Store multiple 3-element structures from three registers
@@ -8019,7 +8019,7 @@ pub unsafe fn vst3q_lane_s64<const LANE: i32>(a: *mut i64, b: int64x2x3_t) {
80198019
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
80208020
pub unsafe fn vst3q_lane_u8<const LANE: i32>(a: *mut u8, b: uint8x16x3_t) {
80218021
static_assert_uimm_bits!(LANE, 4);
8022-
transmute(vst3q_lane_s8::<LANE>(transmute(a), transmute(b)))
8022+
vst3q_lane_s8::<LANE>(transmute(a), transmute(b))
80238023
}
80248024

80258025
/// Store multiple 3-element structures from three registers
@@ -8032,7 +8032,7 @@ pub unsafe fn vst3q_lane_u8<const LANE: i32>(a: *mut u8, b: uint8x16x3_t) {
80328032
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
80338033
pub unsafe fn vst3_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x1x3_t) {
80348034
static_assert!(LANE == 0);
8035-
transmute(vst3_lane_s64::<LANE>(transmute(a), transmute(b)))
8035+
vst3_lane_s64::<LANE>(transmute(a), transmute(b))
80368036
}
80378037

80388038
/// Store multiple 3-element structures from three registers
@@ -8045,7 +8045,7 @@ pub unsafe fn vst3_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x1x3_t) {
80458045
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
80468046
pub unsafe fn vst3q_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x2x3_t) {
80478047
static_assert_uimm_bits!(LANE, 1);
8048-
transmute(vst3q_lane_s64::<LANE>(transmute(a), transmute(b)))
8048+
vst3q_lane_s64::<LANE>(transmute(a), transmute(b))
80498049
}
80508050

80518051
/// Store multiple 3-element structures from three registers
@@ -8058,7 +8058,7 @@ pub unsafe fn vst3q_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x2x3_t) {
80588058
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
80598059
pub unsafe fn vst3q_lane_p8<const LANE: i32>(a: *mut p8, b: poly8x16x3_t) {
80608060
static_assert_uimm_bits!(LANE, 4);
8061-
transmute(vst3q_lane_s8::<LANE>(transmute(a), transmute(b)))
8061+
vst3q_lane_s8::<LANE>(transmute(a), transmute(b))
80628062
}
80638063

80648064
/// Store multiple 3-element structures from three registers
@@ -8071,7 +8071,7 @@ pub unsafe fn vst3q_lane_p8<const LANE: i32>(a: *mut p8, b: poly8x16x3_t) {
80718071
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
80728072
pub unsafe fn vst3_lane_p64<const LANE: i32>(a: *mut p64, b: poly64x1x3_t) {
80738073
static_assert!(LANE == 0);
8074-
transmute(vst3_lane_s64::<LANE>(transmute(a), transmute(b)))
8074+
vst3_lane_s64::<LANE>(transmute(a), transmute(b))
80758075
}
80768076

80778077
/// Store multiple 3-element structures from three registers
@@ -8084,7 +8084,7 @@ pub unsafe fn vst3_lane_p64<const LANE: i32>(a: *mut p64, b: poly64x1x3_t) {
80848084
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
80858085
pub unsafe fn vst3q_lane_p64<const LANE: i32>(a: *mut p64, b: poly64x2x3_t) {
80868086
static_assert_uimm_bits!(LANE, 1);
8087-
transmute(vst3q_lane_s64::<LANE>(transmute(a), transmute(b)))
8087+
vst3q_lane_s64::<LANE>(transmute(a), transmute(b))
80888088
}
80898089

80908090
/// Store multiple 3-element structures from three registers
@@ -8147,7 +8147,7 @@ pub unsafe fn vst4q_s64(a: *mut i64, b: int64x2x4_t) {
81478147
#[cfg_attr(test, assert_instr(st4))]
81488148
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
81498149
pub unsafe fn vst4q_u64(a: *mut u64, b: uint64x2x4_t) {
8150-
transmute(vst4q_s64(transmute(a), transmute(b)))
8150+
vst4q_s64(transmute(a), transmute(b))
81518151
}
81528152

81538153
/// Store multiple 4-element structures from four registers
@@ -8158,7 +8158,7 @@ pub unsafe fn vst4q_u64(a: *mut u64, b: uint64x2x4_t) {
81588158
#[cfg_attr(test, assert_instr(st4))]
81598159
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
81608160
pub unsafe fn vst4q_p64(a: *mut p64, b: poly64x2x4_t) {
8161-
transmute(vst4q_s64(transmute(a), transmute(b)))
8161+
vst4q_s64(transmute(a), transmute(b))
81628162
}
81638163

81648164
/// Store multiple 4-element structures from four registers
@@ -8257,7 +8257,7 @@ pub unsafe fn vst4q_lane_s64<const LANE: i32>(a: *mut i64, b: int64x2x4_t) {
82578257
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
82588258
pub unsafe fn vst4q_lane_u8<const LANE: i32>(a: *mut u8, b: uint8x16x4_t) {
82598259
static_assert_uimm_bits!(LANE, 4);
8260-
transmute(vst4q_lane_s8::<LANE>(transmute(a), transmute(b)))
8260+
vst4q_lane_s8::<LANE>(transmute(a), transmute(b))
82618261
}
82628262

82638263
/// Store multiple 4-element structures from four registers
@@ -8270,7 +8270,7 @@ pub unsafe fn vst4q_lane_u8<const LANE: i32>(a: *mut u8, b: uint8x16x4_t) {
82708270
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
82718271
pub unsafe fn vst4_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x1x4_t) {
82728272
static_assert!(LANE == 0);
8273-
transmute(vst4_lane_s64::<LANE>(transmute(a), transmute(b)))
8273+
vst4_lane_s64::<LANE>(transmute(a), transmute(b))
82748274
}
82758275

82768276
/// Store multiple 4-element structures from four registers
@@ -8283,7 +8283,7 @@ pub unsafe fn vst4_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x1x4_t) {
82838283
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
82848284
pub unsafe fn vst4q_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x2x4_t) {
82858285
static_assert_uimm_bits!(LANE, 1);
8286-
transmute(vst4q_lane_s64::<LANE>(transmute(a), transmute(b)))
8286+
vst4q_lane_s64::<LANE>(transmute(a), transmute(b))
82878287
}
82888288

82898289
/// Store multiple 4-element structures from four registers
@@ -8296,7 +8296,7 @@ pub unsafe fn vst4q_lane_u64<const LANE: i32>(a: *mut u64, b: uint64x2x4_t) {
82968296
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
82978297
pub unsafe fn vst4q_lane_p8<const LANE: i32>(a: *mut p8, b: poly8x16x4_t) {
82988298
static_assert_uimm_bits!(LANE, 4);
8299-
transmute(vst4q_lane_s8::<LANE>(transmute(a), transmute(b)))
8299+
vst4q_lane_s8::<LANE>(transmute(a), transmute(b))
83008300
}
83018301

83028302
/// Store multiple 4-element structures from four registers
@@ -8309,7 +8309,7 @@ pub unsafe fn vst4q_lane_p8<const LANE: i32>(a: *mut p8, b: poly8x16x4_t) {
83098309
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
83108310
pub unsafe fn vst4_lane_p64<const LANE: i32>(a: *mut p64, b: poly64x1x4_t) {
83118311
static_assert!(LANE == 0);
8312-
transmute(vst4_lane_s64::<LANE>(transmute(a), transmute(b)))
8312+
vst4_lane_s64::<LANE>(transmute(a), transmute(b))
83138313
}
83148314

83158315
/// Store multiple 4-element structures from four registers
@@ -8322,7 +8322,7 @@ pub unsafe fn vst4_lane_p64<const LANE: i32>(a: *mut p64, b: poly64x1x4_t) {
83228322
#[stable(feature = "neon_intrinsics", since = "1.59.0")]
83238323
pub unsafe fn vst4q_lane_p64<const LANE: i32>(a: *mut p64, b: poly64x2x4_t) {
83248324
static_assert_uimm_bits!(LANE, 1);
8325-
transmute(vst4q_lane_s64::<LANE>(transmute(a), transmute(b)))
8325+
vst4q_lane_s64::<LANE>(transmute(a), transmute(b))
83268326
}
83278327

83288328
/// Store multiple 4-element structures from four registers

0 commit comments

Comments
 (0)