-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Fix assertions related to combining cmn (extended-register)
(#113337)
#113376
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
12755c1
Fix assertions related to combining `cmn (extended-register)` (#113337)
snickolls-arm 4e6d417
Fix test and address code review comments
snickolls-arm ee62a3a
Fix tests for other architectures
snickolls-arm 1f900f0
Restrict containment to integer->integer casts, and prevent containin…
snickolls-arm 6079bb4
Formatting
snickolls-arm 4e51d8b
Merge branch 'main' into fix-113337
snickolls-arm 7bcb67c
Remove check for IsContainableMemoryOp
snickolls-arm 83ebe28
Fix interaction with CCMP optimization
snickolls-arm File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
78 changes: 78 additions & 0 deletions
78
src/tests/JIT/Regression/JitBlue/Runtime_113337/Runtime_113337.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
|
||
using System; | ||
using System.Numerics; | ||
using System.Runtime.Intrinsics; | ||
using System.Runtime.Intrinsics.Arm; | ||
using System.Runtime.CompilerServices; | ||
using Xunit; | ||
|
||
#pragma warning disable SYSLIB5003 // Allow experimental SVE | ||
|
||
public class Runtime_113337 | ||
{ | ||
static sbyte[] s_7; | ||
|
||
[MethodImpl(MethodImplOptions.NoInlining)] | ||
static void issue1() | ||
{ | ||
try | ||
{ | ||
var vr9 = Vector64.Create<float>(0); | ||
if ((2147483647 == (-(int)AdvSimd.Extract(vr9, 1)))) | ||
{ | ||
s_7 = s_7; | ||
} | ||
} | ||
catch (PlatformNotSupportedException e) | ||
{ | ||
} | ||
} | ||
|
||
static int[][] s_2; | ||
static bool s_3; | ||
|
||
[MethodImpl(MethodImplOptions.NoInlining)] | ||
static void issue2() | ||
{ | ||
try | ||
{ | ||
s_3 ^= (2021486855 != (-(long)s_2[0][0])); | ||
} | ||
catch (NullReferenceException e) | ||
{ | ||
} | ||
} | ||
|
||
static Vector<ulong>[] s_4; | ||
[MethodImpl(MethodImplOptions.NoInlining)] | ||
static void issue3() | ||
{ | ||
try | ||
{ | ||
var vr3 = Vector.Create<short>(1); | ||
var vr4 = (short)0; | ||
var vr5 = Vector128.CreateScalar(vr4).AsVector(); | ||
if ((Sve.TestFirstTrue(vr3, vr5) | (3268100580U != (-(uint)Sve.SaturatingDecrementBy16BitElementCount(0, 1))))) | ||
{ | ||
s_4[0] = s_4[0]; | ||
} | ||
} | ||
catch (PlatformNotSupportedException e) | ||
{ | ||
} | ||
catch (NullReferenceException e) | ||
{ | ||
} | ||
} | ||
|
||
[Fact] | ||
public static void TestEntryPoint() | ||
{ | ||
// Checking for successful compilation | ||
issue1(); | ||
issue2(); | ||
issue3(); | ||
} | ||
} |
8 changes: 8 additions & 0 deletions
8
src/tests/JIT/Regression/JitBlue/Runtime_113337/Runtime_113337.csproj
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
<PropertyGroup> | ||
<Optimize>True</Optimize> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Compile Include="$(MSBuildProjectName).cs" /> | ||
</ItemGroup> | ||
</Project> |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This nullptr check is unnecessary (we already checked for
CmpCompare
above, all of those are binops). But let's not wait for another round of CI here.