-
Notifications
You must be signed in to change notification settings - Fork 5.4k
ARM64 intrinsic support for Vector64.Create() and Vector128.Create() #35590
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
kunalspathak
merged 15 commits into
dotnet:master
from
kunalspathak:create-scalar-multiple
May 5, 2020
Merged
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
4ad1eee
Make Vector64.Create() that takes multiple arguments use ARM64 intrinsic
kunalspathak 523e67e
Make Vector128.Create() that takes multiple arguments use ARM64 intri…
kunalspathak ba09d5e
Intrinsify Vector64.Create() that takes single argument
kunalspathak 6d62318
Intrinsify Vector64.Create() that takes single argument
kunalspathak 3d60b7a
Fix edge case where int.MaxValue was failing if used as immediate
kunalspathak 660d721
Addressed review comments
kunalspathak 1b9c421
added unit test
kunalspathak dae7537
fix the return type of emitDecodeByteShiftedImm
kunalspathak 76cc65e
merge conflicts fixup
kunalspathak 6f59efc
moved the assert at right location
kunalspathak 4707161
Bug fixes
kunalspathak dbc8dde
formatting
kunalspathak 0c51436
Added test coverage
kunalspathak 0a99bf3
Trimmed the test IL code
kunalspathak 0382dea
Add required return in the test
kunalspathak 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
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
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
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
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
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
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
92 changes: 92 additions & 0 deletions
92
src/coreclr/tests/src/JIT/Regression/JitBlue/GitHub_35821/GitHub_35821.il
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,92 @@ | ||
| // Licensed to the .NET Foundation under one or more agreements. | ||
| // The .NET Foundation licenses this file to you under the MIT license. | ||
| // See the LICENSE file in the project root for more information. | ||
| // Metadata version: v4.0.30319 | ||
| .assembly extern System.Runtime | ||
| { | ||
| .publickeytoken = (B0 3F 5F 7F 11 D5 0A 3A ) // .?_....: | ||
| .ver 5:0:0:0 | ||
| } | ||
| .assembly extern System.Runtime.Intrinsics | ||
| { | ||
| .publickeytoken = (CC 7B 13 FF CD 2D DD 51 ) // .{...-.Q | ||
| .ver 5:0:0:0 | ||
| } | ||
| .assembly projs { } | ||
| .module projs.dll | ||
| // MVID: {379016DB-73C2-41D4-9E5F-5B727BC70E2C} | ||
| .custom instance void [System.Runtime]System.Security.UnverifiableCodeAttribute::.ctor() = ( 01 00 00 00 ) | ||
| .imagebase 0x00400000 | ||
| .file alignment 0x00000200 | ||
| .stackreserve 0x00100000 | ||
| .subsystem 0x0003 // WINDOWS_CUI | ||
| .corflags 0x00000001 // ILONLY | ||
| // Image base: 0x00000293F3DD0000 | ||
|
|
||
|
|
||
| // =============== CLASS MEMBERS DECLARATION =================== | ||
| // This bug was found when passing Vector64<long> to a method such that | ||
| // the vector is on the evaluation stack. C# sometimes assign it the vector64 | ||
| // to local variable before passing it to method. In such cases, the bug | ||
| // doesn't repro. | ||
| .class public auto ansi sealed beforefieldinit projs.GitHub_35821 | ||
| extends [System.Runtime]System.Object | ||
| { | ||
| .method private hidebysig static int32 | ||
| Main(string[] args) cil managed | ||
| { | ||
| .entrypoint | ||
| // Code size 48 (0x30) | ||
| .maxstack 8 | ||
| IL_0000: ldc.i4.s 23 | ||
| IL_0002: conv.i8 | ||
| IL_0003: call valuetype [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64`1<uint64> [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64::Create(uint64) | ||
| IL_0008: call void projs.GitHub_35821::Test1(valuetype [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64`1<uint64>) | ||
| IL_000d: ldc.i4.s 23 | ||
| IL_000f: conv.i8 | ||
| IL_0010: call valuetype [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64`1<int64> [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64::Create(int64) | ||
| IL_0015: call void projs.GitHub_35821::Test2(valuetype [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64`1<int64>) | ||
| IL_001a: ldc.r8 23. | ||
| IL_0023: call valuetype [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64`1<float64> [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64::Create(float64) | ||
| IL_0028: call void projs.GitHub_35821::Test3(valuetype [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64`1<float64>) | ||
| IL_002d: ldc.i4.s 100 | ||
| IL_002f: ret | ||
| } // end of method GitHub_35821::Main | ||
|
|
||
| .method public hidebysig static void Test1(valuetype [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64`1<uint64> data) cil managed noinlining | ||
| { | ||
| // Code size 1 (0x1) | ||
| .maxstack 8 | ||
| IL_0000: ret | ||
| } // end of method GitHub_35821::Test1 | ||
|
|
||
| .method public hidebysig static void Test2(valuetype [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64`1<int64> data) cil managed noinlining | ||
| { | ||
| // Code size 1 (0x1) | ||
| .maxstack 8 | ||
| IL_0000: ret | ||
| } // end of method GitHub_35821::Test2 | ||
|
|
||
| .method public hidebysig static void Test3(valuetype [System.Runtime.Intrinsics]System.Runtime.Intrinsics.Vector64`1<float64> data) cil managed noinlining | ||
| { | ||
| // Code size 1 (0x1) | ||
| .maxstack 8 | ||
| IL_0000: ret | ||
| } // end of method GitHub_35821::Test3 | ||
|
|
||
| .method public hidebysig specialname rtspecialname | ||
| instance void .ctor() cil managed | ||
| { | ||
| // Code size 7 (0x7) | ||
| .maxstack 8 | ||
| IL_0000: ldarg.0 | ||
| IL_0001: call instance void [System.Runtime]System.Object::.ctor() | ||
| IL_0006: ret | ||
| } // end of method GitHub_35821::.ctor | ||
|
|
||
| } // end of class projs.GitHub_35821 | ||
|
|
||
|
|
||
| // ============================================================= | ||
|
|
||
| // *********** DISASSEMBLY COMPLETE *********************** |
12 changes: 12 additions & 0 deletions
12
src/coreclr/tests/src/JIT/Regression/JitBlue/GitHub_35821/GitHub_35821.ilproj
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,12 @@ | ||
| <Project Sdk="Microsoft.NET.Sdk.IL"> | ||
| <PropertyGroup> | ||
| <OutputType>Exe</OutputType> | ||
| </PropertyGroup> | ||
| <PropertyGroup> | ||
| <DebugType>None</DebugType> | ||
| <Optimize>True</Optimize> | ||
| </PropertyGroup> | ||
| <ItemGroup> | ||
| <Compile Include="$(MSBuildProjectName).il" /> | ||
| </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.
Uh oh!
There was an error while loading. Please reload this page.