Skip to content

Hardware intrinsic throw ArgumentOutOfRangeException with IMM parameter name #10982

Open
@fiigii

Description

@fiigii

Now, some hardware intrinsic can throw ArgumentOutOfRangeException from the IMM arguments.

 Avx.Compare(Avx.SetZeroVector256<float>(), Avx.SetZeroVector256<float>(), (FloatComparisonMode)100);
Unhandled Exception: System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values.
   at System.Runtime.Intrinsics.X86.Avx.Compare(Vector256`1 left, Vector256`1 right, FloatComparisonMode mode)
   at SseTest.Program.Main(String[] args) in D:\workspace\tests\testIntrinsic\Program.cs:line 14

We may need to bring the IMM parameter name in the exception object.

Logged from the conversation dotnet/coreclr#19392 (comment)

@tannergooding @CarolEidt

category:implementation
theme:hardware-intrinsics
skill-level:beginner
cost:small

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMIenhancementProduct code improvement that does NOT require public API changes/additionshelp wanted[up-for-grabs] Good issue for external contributors

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions