Skip to content

Commit 75492da

Browse files
committed
Add back ReverseElementBits intrinsic.
1 parent 13fdf21 commit 75492da

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

src/mono/mono/mini/llvm-intrinsics.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -261,6 +261,7 @@ INTRINS_OVR(WASM_ANYTRUE_V2, wasm_anytrue, Wasm, sse_i8_t)
261261
#if defined(TARGET_ARM64)
262262
INTRINS_OVR(BITREVERSE_I32, bitreverse, Generic, LLVMInt32Type ())
263263
INTRINS_OVR(BITREVERSE_I64, bitreverse, Generic, LLVMInt64Type ())
264+
INTRINS_OVR_TAG(BITREVERSE, bitreverse, Generic, V64 | V128 | I1 | I2 | I4 | I8)
264265
INTRINS(AARCH64_CRC32B, aarch64_crc32b, Arm64)
265266
INTRINS(AARCH64_CRC32H, aarch64_crc32h, Arm64)
266267
INTRINS(AARCH64_CRC32W, aarch64_crc32w, Arm64)
@@ -399,6 +400,10 @@ INTRINS_OVR_TAG(AARCH64_ADV_SIMD_FRSQRTE, aarch64_neon_frsqrte, Arm64, Scalar |
399400
INTRINS_OVR_TAG(AARCH64_ADV_SIMD_FRSQRTS, aarch64_neon_frsqrts, Arm64, Scalar | V64 | V128 | R4 | R8)
400401
INTRINS_OVR_TAG(AARCH64_ADV_SIMD_FRECPS, aarch64_neon_frecps, Arm64, Scalar | V64 | V128 | R4 | R8)
401402

403+
#if LLVM_API_VERSION < 1400
404+
INTRINS_OVR_TAG(AARCH64_ADV_SIMD_RBIT, aarch64_neon_rbit, Arm64, V64 | V128 | I1)
405+
#endif
406+
402407
INTRINS_OVR_TAG(AARCH64_ADV_SIMD_FRINTA, round, Generic, Scalar | V64 | V128 | R4 | R8)
403408
#if LLVM_API_VERSION < 1400
404409
INTRINS_OVR_TAG(AARCH64_ADV_SIMD_FRINTN, aarch64_neon_frintn, Arm64, Scalar | V64 | V128 | R4 | R8)

src/mono/mono/mini/simd-intrinsics.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2517,6 +2517,11 @@ static SimdIntrinsic advsimd_methods [] = {
25172517
{SN_ReverseElement16, OP_ARM64_REVN, 16},
25182518
{SN_ReverseElement32, OP_ARM64_REVN, 32},
25192519
{SN_ReverseElement8, OP_ARM64_REVN, 8},
2520+
#if LLVM_API_VERSION >= 1400
2521+
{SN_ReverseElementBits, OP_XOP_OVR_X_X, INTRINS_BITREVERSE},
2522+
#else
2523+
{SN_ReverseElementBits, OP_XOP_OVR_X_X, INTRINS_AARCH64_ADV_SIMD_RBIT},
2524+
#endif
25202525
{SN_RoundAwayFromZero, OP_XOP_OVR_X_X, INTRINS_AARCH64_ADV_SIMD_FRINTA},
25212526
{SN_RoundAwayFromZeroScalar, OP_XOP_OVR_SCALAR_X_X, INTRINS_AARCH64_ADV_SIMD_FRINTA},
25222527
#if LLVM_API_VERSION >= 1400

0 commit comments

Comments
 (0)