-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Fixing the InstructionSetDesc implications #86486
Merged
tannergooding
merged 28 commits into
dotnet:main
from
tannergooding:prefer-vector-width-4
Jun 2, 2023
Merged
Changes from 19 commits
Commits
Show all changes
28 commits
Select commit
Hold shift + click to select a range
d5e1c77
Fixing the InstructionSetDesc implications
tannergooding 2cf307d
Merge remote-tracking branch 'dotnet/main' into prefer-vector-width-4
tannergooding 8e518a6
Adding more NAOT smoke tests covering the missed instruction sets
tannergooding 5e4eb47
Simplify the HasInstructionSet(Avx512F) check in compSetProcessor
tannergooding 89b5aff
Fixing the NAOT smoke tests
tannergooding e4831f2
Fixing some stale comments
tannergooding a3fc57d
Fixing build failure
tannergooding 25843cb
Ensure the X86Serialize test lambda returns a bool
tannergooding 83cdd19
Fixing build failure
tannergooding 38c0005
Merge remote-tracking branch 'dotnet/main' into prefer-vector-width-4
tannergooding c4e9163
Ensure AVX2 isn't opportunistically supported and that dynamic checks…
tannergooding 3f771fd
Ensure Avx512Vbmi has [Intrinsic] on the right members
tannergooding c549949
Fix the secondary isIsaSupported check to be properly opportunistic f…
tannergooding 569d624
Ensure vpermb is covered
tannergooding 8b464fa
Allow opportunistic AvxVnni when Avx2 is opted into
tannergooding 49ec14d
Don't expect opportunistic Avx2 or AvxVnni in the smoke tests
tannergooding e7d7146
Ensure Avx2.X64 checks ExpectedAvx2, not ExpectedAvx
tannergooding 209938b
Merge remote-tracking branch 'dotnet/main' into prefer-vector-width-4
tannergooding ba1316e
Change the filter the AVX512 NAOT smoke test on OSX
tannergooding 2468ef2
Merge remote-tracking branch 'dotnet/main' into prefer-vector-width-4
tannergooding 86ed734
Updating the CPUID test to cover new ISAs and correctly validate the …
tannergooding 53e7858
Add two more NAOT smoke tests which cover explicit ISA exclusion
tannergooding 2447b21
Add additional CpuId validation covering R2R scenarios using various …
tannergooding e9f8b88
Ensure new R2R tests actually use R2R
tannergooding da584c5
Don't try to expose an invalid --instruction-set combination
tannergooding 67f309b
Ensure xarch r2r tests only run on xarch
tannergooding 0c69dbd
Don't compare manufacturer name of CPUID 0x00000000 to 0x80000000
tannergooding 5c47316
Filter out the CPUID test on Mono and account for AVX-512 being unsup…
tannergooding 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 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 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 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 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 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 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
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.
Could you explain what change is happening here? I don't see a description of what we're changing around NativeAOT behavior in the change description.
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.
There was an existing bug here that was surfaced if crossgen/naot targeted
avx
but notavx2
For most cases, the ISA initially checked and tracked as part of
isIsaSupported
is the same as what is tracked by theInstructionSetDesc
However, for
Vector256
in particular we have the case where the implication is onAvx
and we will accelerate some APIs when onlyAvx
is supported. But, we only wantIsHardwareAccelerated
to reporttrue
whenAvx2
is also supported.We were then ending up in a scenario where we'd end up failing to handle
IsHardwareAccelerated
for the recursive case whenavx
was supported butavx2
was not becauseisIsaSupported
(AVX
) would betrue
and then we'd fail thecompExactlyDependsOn
check forAVX2
and then returnNI_IsSupported_Dynamic
, which was incorrect sinceavx2
was not opportunistic.This fixes that so we now ensure that we only go down the true/dynamic path if the compiler could support
AVX2
at all.