Skip to content

Commit

Permalink
Add back ReverseElementBits intrinsic.
Browse files Browse the repository at this point in the history
  • Loading branch information
vargaz committed Apr 30, 2022
1 parent 13fdf21 commit 75492da
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/mono/mono/mini/llvm-intrinsics.h
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,7 @@ INTRINS_OVR(WASM_ANYTRUE_V2, wasm_anytrue, Wasm, sse_i8_t)
#if defined(TARGET_ARM64)
INTRINS_OVR(BITREVERSE_I32, bitreverse, Generic, LLVMInt32Type ())
INTRINS_OVR(BITREVERSE_I64, bitreverse, Generic, LLVMInt64Type ())
INTRINS_OVR_TAG(BITREVERSE, bitreverse, Generic, V64 | V128 | I1 | I2 | I4 | I8)
INTRINS(AARCH64_CRC32B, aarch64_crc32b, Arm64)
INTRINS(AARCH64_CRC32H, aarch64_crc32h, Arm64)
INTRINS(AARCH64_CRC32W, aarch64_crc32w, Arm64)
Expand Down Expand Up @@ -399,6 +400,10 @@ INTRINS_OVR_TAG(AARCH64_ADV_SIMD_FRSQRTE, aarch64_neon_frsqrte, Arm64, Scalar |
INTRINS_OVR_TAG(AARCH64_ADV_SIMD_FRSQRTS, aarch64_neon_frsqrts, Arm64, Scalar | V64 | V128 | R4 | R8)
INTRINS_OVR_TAG(AARCH64_ADV_SIMD_FRECPS, aarch64_neon_frecps, Arm64, Scalar | V64 | V128 | R4 | R8)

#if LLVM_API_VERSION < 1400
INTRINS_OVR_TAG(AARCH64_ADV_SIMD_RBIT, aarch64_neon_rbit, Arm64, V64 | V128 | I1)
#endif

INTRINS_OVR_TAG(AARCH64_ADV_SIMD_FRINTA, round, Generic, Scalar | V64 | V128 | R4 | R8)
#if LLVM_API_VERSION < 1400
INTRINS_OVR_TAG(AARCH64_ADV_SIMD_FRINTN, aarch64_neon_frintn, Arm64, Scalar | V64 | V128 | R4 | R8)
Expand Down
5 changes: 5 additions & 0 deletions src/mono/mono/mini/simd-intrinsics.c
Original file line number Diff line number Diff line change
Expand Up @@ -2517,6 +2517,11 @@ static SimdIntrinsic advsimd_methods [] = {
{SN_ReverseElement16, OP_ARM64_REVN, 16},
{SN_ReverseElement32, OP_ARM64_REVN, 32},
{SN_ReverseElement8, OP_ARM64_REVN, 8},
#if LLVM_API_VERSION >= 1400
{SN_ReverseElementBits, OP_XOP_OVR_X_X, INTRINS_BITREVERSE},
#else
{SN_ReverseElementBits, OP_XOP_OVR_X_X, INTRINS_AARCH64_ADV_SIMD_RBIT},
#endif
{SN_RoundAwayFromZero, OP_XOP_OVR_X_X, INTRINS_AARCH64_ADV_SIMD_FRINTA},
{SN_RoundAwayFromZeroScalar, OP_XOP_OVR_SCALAR_X_X, INTRINS_AARCH64_ADV_SIMD_FRINTA},
#if LLVM_API_VERSION >= 1400
Expand Down

0 comments on commit 75492da

Please sign in to comment.