Ensure we consistently broadcast the result of simd dot product#105888
Ensure we consistently broadcast the result of simd dot product#105888tannergooding merged 1 commit intodotnet:mainfrom
Conversation
| #if defined(TARGET_XARCH) | ||
| if ((simdSize == 8) && !compOpportunisticallyDependsOn(InstructionSet_SSE41)) | ||
| { | ||
| // When SSE4.1 isn't supported then Vector2 only needs a single horizontal add | ||
| // which means the result isn't broadcast across the entire vector and we can't | ||
| // optimize | ||
| break; | ||
| } | ||
| #endif // TARGET_XARCH |
There was a problem hiding this comment.
This code was incorrect, as we expect that broadcast should always be occurring.
The lowering logic was doing the right thing already for SSE2 and SSE41+ machines, but not for SSE3 or SSSE3 machines where HorizontalAdd exists
|
/azp run runtime-coreclr jitstress-isas-x86 |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
This is going to need backport to .NET 8 since its a customer reported codegen issue. |
140333e to
3381d6a
Compare
|
CC. @dotnet/jit-contrib, this is ready for review JitStress failures are unrelated and fixed by #105889, I've updated the branch and restarted CI so it can pass cleanly now that the fix has been merged (force pushed so this remains trivial to backport). |
|
/azp run runtime-coreclr jitstress-isas-x86 |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
CC. @dotnet/jit-contrib, this is ready for review and resolves #99391. It likely needs backport after merge. (just repinging now that the weekend is over) |
|
/backport to release/8.0-staging |
|
Started backporting to release/8.0-staging: https://github.com/dotnet/runtime/actions/runs/10270776439 |
|
@tannergooding backporting to release/8.0-staging failed, the patch most likely resulted in conflicts: $ git am --3way --ignore-whitespace --keep-non-patch changes.patch
Applying: Ensure we consistently broadcast the result of simd dot product
Using index info to reconstruct a base tree...
M src/coreclr/jit/lowerxarch.cpp
M src/coreclr/jit/morph.cpp
Falling back to patching base and 3-way merge...
Auto-merging src/coreclr/jit/morph.cpp
CONFLICT (content): Merge conflict in src/coreclr/jit/morph.cpp
Auto-merging src/coreclr/jit/lowerxarch.cpp
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
hint: When you have resolved this problem, run "git am --continue".
hint: If you prefer to skip this patch, run "git am --skip" instead.
hint: To restore the original branch and stop patching, run "git am --abort".
hint: Disable this message with "git config advice.mergeConflict false"
Patch failed at 0001 Ensure we consistently broadcast the result of simd dot product
Error: The process '/usr/bin/git' failed with exit code 128Please backport manually! |
|
@tannergooding an error occurred while backporting to release/8.0-staging, please check the run log for details! Error: git am failed, most likely due to a merge conflict. |
This resolves #99391