Skip to content

SVE: Match, NoMatch#125163

Open
dhartglassMSFT wants to merge 3 commits intodotnet:mainfrom
dhartglassMSFT:arm_match
Open

SVE: Match, NoMatch#125163
dhartglassMSFT wants to merge 3 commits intodotnet:mainfrom
dhartglassMSFT:arm_match

Conversation

@dhartglassMSFT
Copy link
Contributor

@dhartglassMSFT dhartglassMSFT commented Mar 4, 2026

Partially contributes to #94021

  /// T: sbyte, short, byte, ushort
  public static unsafe Vector<T> Match(Vector<T> mask, Vector<T> left, Vector<T> right); // MATCH

  /// T: sbyte, short, byte, ushort
  public static unsafe Vector<T> NoMatch(Vector<T> mask, Vector<T> left, Vector<T> right); // NMATCH

@dotnet-policy-service
Copy link
Contributor

Tagging subscribers to this area: @dotnet/area-system-runtime-intrinsics
See info in area-owners.md if you want to be subscribed.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds initial support for the Arm64 SVE2 Match / NoMatch intrinsics (and corresponding tests) to the runtime/JIT and the HWIntrinsic test generator.

Changes:

  • Introduces new SVE2 intrinsics Match and NoMatch for byte/sbyte/short/ushort.
  • Extends SVE2 test generation to cover the new intrinsics.
  • Adds managed test helper implementations for expected results.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/tests/JIT/HardwareIntrinsics/Arm/Shared/Helpers.cs Adds Match/NoMatch helper logic for expected-value computation (but this file is generated).
src/tests/Common/GenerateHWIntrinsicTests/Arm/Sve2Tests.cs Adds generator entries to produce tests for Match/NoMatch.
src/libraries/System.Runtime.Intrinsics/ref/System.Runtime.Intrinsics.cs Adds the public ref declarations for Match/NoMatch.
src/libraries/System.Private.CoreLib/src/System/Runtime/Intrinsics/Arm/Sve2.cs Adds the SVE2 API surface for Match/NoMatch.
src/libraries/System.Private.CoreLib/src/System/Runtime/Intrinsics/Arm/Sve2.PlatformNotSupported.cs Adds PNSE stubs for Match/NoMatch when SVE2 isn’t supported.
src/coreclr/jit/hwintrinsiclistarm64sve.h Registers the new SVE2 intrinsics with the JIT intrinsic table.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants