You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
JIT: (bug) AvxVnni.V512.MultiplyWideningAndAdd folded into BlendVariable loses the merge operand #133753
usingSystem;usingSystem.Runtime.CompilerServices;usingSystem.Runtime.Intrinsics;usingSystem.Runtime.Intrinsics.X86;publicstaticclassProgram{[MethodImpl(MethodImplOptions.NoInlining)]publicstaticVector512<int>Test(Vector512<int>fallback,Vector512<int>addend,Vector512<byte>left,Vector512<sbyte>right,Vector512<int>a,Vector512<int>b){Vector512<int>mask=Avx512F.CompareEqual(a,b);returnAvx512F.BlendVariable(fallback,AvxVnni.V512.MultiplyWideningAndAdd(addend,left,right),mask);}publicstaticvoidMain(){if(!AvxVnni.V512.IsSupported){Console.WriteLine("unsupported");return;}Console.WriteLine(Test(Vector512.Create(7),// fallbackVector512.Create(5),// addend (left*right == 0, so the product is 5)Vector512<byte>.Zero,Vector512<sbyte>.Zero,Vector512.Create(1),Vector512.Create(0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1)));}}
Expected
<7, 5, 7, 5, 7, 5, 7, 5, 7, 5, 7, 5, 7, 5, 7, 5>
Actual
<5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5>
Notes
Repros under DOTNET_TieredCompilation=0; DOTNET_JitMinOpts=1 prints the expected value. MultiplyWideningAndAddSaturate behaves the same way.
Activity
dotnet-policy-service commentedon Sep 11, 2026
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch
See info in area-owners.md if you want to be subscribed.
MihuBot commentedon Sep 11, 2026
I'm a bot. Here are possible related and/or duplicate issues (I may be wrong):
Avx2.BlendVariable#125431EgorBo commentedon Sep 18, 2026
Affected SDK versions:
Fix VNNI blend merge operand preservation (#134364)
[release/11.0] Fix VNNI blend merge operand preservation (#134420)