Skip to content
This repository has been archived by the owner on Jan 23, 2023. It is now read-only.

Implement LeadingSignCount,LeadingZeroCount,PopCount #27568

Merged
merged 4 commits into from Nov 3, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/jit/hwintrinsiclistarm64.h
Expand Up @@ -52,8 +52,11 @@ HARDWARE_INTRINSIC(AdvSimd, Abs, -
HARDWARE_INTRINSIC(AdvSimd, AbsScalar, -1, 8, 1, {INS_invalid, INS_invalid, INS_invalid, INS_invalid, INS_invalid, INS_invalid, INS_invalid, INS_invalid, INS_fabs, INS_fabs}, HW_Category_SIMDScalar, HW_Flag_NoContainment)
HARDWARE_INTRINSIC(AdvSimd, Add, -1, -1, 2, {INS_add, INS_add, INS_add, INS_add, INS_add, INS_add, INS_add, INS_add, INS_fadd, INS_invalid}, HW_Category_SimpleSIMD, HW_Flag_NoContainment|HW_Flag_Commutative|HW_Flag_UnfixedSIMDSize)
HARDWARE_INTRINSIC(AdvSimd, AddScalar, -1, 8, 2, {INS_add, INS_add, INS_add, INS_add, INS_add, INS_add, INS_add, INS_add, INS_fadd, INS_fadd}, HW_Category_SIMDScalar, HW_Flag_NoContainment|HW_Flag_Commutative)
HARDWARE_INTRINSIC(AdvSimd, LeadingSignCount, -1, -1, 1, {INS_cls, INS_invalid, INS_cls, INS_invalid, INS_cls, INS_invalid, INS_invalid, INS_invalid, INS_invalid, INS_invalid}, HW_Category_SimpleSIMD, HW_Flag_NoContainment|HW_Flag_UnfixedSIMDSize)
HARDWARE_INTRINSIC(AdvSimd, LeadingZeroCount, -1, -1, 1, {INS_clz, INS_clz, INS_clz, INS_clz, INS_clz, INS_clz, INS_invalid, INS_invalid, INS_invalid, INS_invalid}, HW_Category_SimpleSIMD, HW_Flag_NoContainment|HW_Flag_UnfixedSIMDSize)
HARDWARE_INTRINSIC(AdvSimd, LoadVector64, -1, 8, 1, {INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1}, HW_Category_MemoryLoad, HW_Flag_NoRMWSemantics)
HARDWARE_INTRINSIC(AdvSimd, LoadVector128, -1, 16, 1, {INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1, INS_ld1}, HW_Category_MemoryLoad, HW_Flag_NoRMWSemantics)
HARDWARE_INTRINSIC(AdvSimd, PopCount, -1, -1, 1, {INS_cnt, INS_cnt, INS_invalid, INS_invalid, INS_invalid, INS_invalid, INS_invalid, INS_invalid, INS_invalid, INS_invalid}, HW_Category_SimpleSIMD, HW_Flag_NoContainment|HW_Flag_UnfixedSIMDSize)

// ***************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************
// ISA Function name ival SIMD size NumArg instructions Category Flags
Expand Down
Expand Up @@ -11,6 +11,7 @@
<Compile Include="Abs.Vector128.Double.cs" />
<Compile Include="Abs.Vector128.UInt64.cs" />
<Compile Include="Program.AdvSimd.Arm64.cs" />
<Compile Include="..\Shared\Helpers.cs" />
<Compile Include="..\Shared\Program.cs" />
</ItemGroup>
</Project>
Expand Up @@ -11,6 +11,7 @@
<Compile Include="Abs.Vector128.Double.cs" />
<Compile Include="Abs.Vector128.UInt64.cs" />
<Compile Include="Program.AdvSimd.Arm64.cs" />
<Compile Include="..\Shared\Helpers.cs" />
<Compile Include="..\Shared\Program.cs" />
</ItemGroup>
</Project>
23 changes: 23 additions & 0 deletions tests/src/JIT/HardwareIntrinsics/Arm/AdvSimd/AdvSimd_r.csproj
Expand Up @@ -34,6 +34,24 @@
<Compile Include="Add.Vector128.UInt32.cs" />
<Compile Include="Add.Vector128.UInt64.cs" />
<Compile Include="AddScalar.Vector64.Single.cs" />
<Compile Include="LeadingSignCount.Vector64.Int16.cs" />
<Compile Include="LeadingSignCount.Vector64.Int32.cs" />
<Compile Include="LeadingSignCount.Vector64.SByte.cs" />
<Compile Include="LeadingSignCount.Vector128.Int16.cs" />
<Compile Include="LeadingSignCount.Vector128.Int32.cs" />
<Compile Include="LeadingSignCount.Vector128.SByte.cs" />
<Compile Include="LeadingZeroCount.Vector64.Byte.cs" />
<Compile Include="LeadingZeroCount.Vector64.Int16.cs" />
<Compile Include="LeadingZeroCount.Vector64.Int32.cs" />
<Compile Include="LeadingZeroCount.Vector64.SByte.cs" />
<Compile Include="LeadingZeroCount.Vector64.UInt16.cs" />
<Compile Include="LeadingZeroCount.Vector64.UInt32.cs" />
<Compile Include="LeadingZeroCount.Vector128.Byte.cs" />
<Compile Include="LeadingZeroCount.Vector128.Int16.cs" />
<Compile Include="LeadingZeroCount.Vector128.Int32.cs" />
<Compile Include="LeadingZeroCount.Vector128.SByte.cs" />
<Compile Include="LeadingZeroCount.Vector128.UInt16.cs" />
<Compile Include="LeadingZeroCount.Vector128.UInt32.cs" />
<Compile Include="LoadVector64.Byte.cs" />
<Compile Include="LoadVector64.Int16.cs" />
<Compile Include="LoadVector64.Int32.cs" />
Expand All @@ -51,7 +69,12 @@
<Compile Include="LoadVector128.UInt16.cs" />
<Compile Include="LoadVector128.UInt32.cs" />
<Compile Include="LoadVector128.UInt64.cs" />
<Compile Include="PopCount.Vector64.Byte.cs" />
<Compile Include="PopCount.Vector64.SByte.cs" />
<Compile Include="PopCount.Vector128.Byte.cs" />
<Compile Include="PopCount.Vector128.SByte.cs" />
<Compile Include="Program.AdvSimd.cs" />
<Compile Include="..\Shared\Helpers.cs" />
<Compile Include="..\Shared\Program.cs" />
</ItemGroup>
</Project>
23 changes: 23 additions & 0 deletions tests/src/JIT/HardwareIntrinsics/Arm/AdvSimd/AdvSimd_ro.csproj
Expand Up @@ -34,6 +34,24 @@
<Compile Include="Add.Vector128.UInt32.cs" />
<Compile Include="Add.Vector128.UInt64.cs" />
<Compile Include="AddScalar.Vector64.Single.cs" />
<Compile Include="LeadingSignCount.Vector64.Int16.cs" />
<Compile Include="LeadingSignCount.Vector64.Int32.cs" />
<Compile Include="LeadingSignCount.Vector64.SByte.cs" />
<Compile Include="LeadingSignCount.Vector128.Int16.cs" />
<Compile Include="LeadingSignCount.Vector128.Int32.cs" />
<Compile Include="LeadingSignCount.Vector128.SByte.cs" />
<Compile Include="LeadingZeroCount.Vector64.Byte.cs" />
<Compile Include="LeadingZeroCount.Vector64.Int16.cs" />
<Compile Include="LeadingZeroCount.Vector64.Int32.cs" />
<Compile Include="LeadingZeroCount.Vector64.SByte.cs" />
<Compile Include="LeadingZeroCount.Vector64.UInt16.cs" />
<Compile Include="LeadingZeroCount.Vector64.UInt32.cs" />
<Compile Include="LeadingZeroCount.Vector128.Byte.cs" />
<Compile Include="LeadingZeroCount.Vector128.Int16.cs" />
<Compile Include="LeadingZeroCount.Vector128.Int32.cs" />
<Compile Include="LeadingZeroCount.Vector128.SByte.cs" />
<Compile Include="LeadingZeroCount.Vector128.UInt16.cs" />
<Compile Include="LeadingZeroCount.Vector128.UInt32.cs" />
<Compile Include="LoadVector64.Byte.cs" />
<Compile Include="LoadVector64.Int16.cs" />
<Compile Include="LoadVector64.Int32.cs" />
Expand All @@ -51,7 +69,12 @@
<Compile Include="LoadVector128.UInt16.cs" />
<Compile Include="LoadVector128.UInt32.cs" />
<Compile Include="LoadVector128.UInt64.cs" />
<Compile Include="PopCount.Vector64.Byte.cs" />
<Compile Include="PopCount.Vector64.SByte.cs" />
<Compile Include="PopCount.Vector128.Byte.cs" />
<Compile Include="PopCount.Vector128.SByte.cs" />
<Compile Include="Program.AdvSimd.cs" />
<Compile Include="..\Shared\Helpers.cs" />
<Compile Include="..\Shared\Program.cs" />
</ItemGroup>
</Project>