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: Invalid result with Avx2.BlendVariable #125431
// Generated by Fuzzlyn v3.3 on 2026-03-09 16:27:56// Run on X64 Linux// Seed: 14993291497765132425-vectort,vector128,vector256,x86aes,x86avx,x86avx2,x86bmi1,x86bmi1x64,x86bmi2,x86bmi2x64,x86fma,x86lzcnt,x86lzcntx64,x86pclmulqdq,x86pclmulqdqv256,x86popcnt,x86popcntx64,x86sse,x86ssex64,x86sse2,x86sse2x64,x86sse3,x86sse41,x86sse41x64,x86sse42,x86sse42x64,x86ssse3,x86x86base// Reduced from 393.1 KiB to 0.7 KiB in 00:07:29// Debug: Prints 1 line(s)// Release: Prints 0 line(s)usingSystem.Numerics;usingSystem.Runtime.Intrinsics;usingSystem.Runtime.Intrinsics.X86;publicclassProgram{publicstaticVector<ulong>s_12;publicstaticbyte[]s_27;publicstaticVector256<byte>[,]s_53;publicstaticvoidMain(){Vector256<byte>vr18=Vector256.Create<byte>(0);varvr19=Vector256.Create<byte>(0);varvr20=M43(vr19,refs_27);varvr21=Vector256.CreateScalar(vr20);Vector256<byte>vr24=s_53[0,0];vr18=Avx2.BlendVariable(vr21,vr24,vr18);M43(vr18,refs_27);}publicstaticbyteM43(Vector256<byte>arg1,refbyte[]arg2){System.Console.WriteLine(s_12);returnarg2[0];}}
/home/ryujit/dev/runtime/artifacts/tests/coreclr/linux.x64.Debug/Tests/Core_Root/corerun ./bin/Debug/net11.0/test.dll
<0, 0, 0, 0>
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
at Program.M43(Vector256`1 arg1, Byte[]& arg2) in /home/ryujit/dev/test/Program.cs:line 30
at Program.Main() in /home/ryujit/dev/test/Program.cs:line 20
at System.Environment.CallEntryPoint(IntPtr entryPoint, String[]* pArgument, Int32* pReturnValue, Boolean captureException, Exception* pException)
Aborted (core dumped)
~/dev/test$ /home/ryujit/dev/runtime/artifacts/tests/coreclr/linux.x64.Debug/Tests/Core_Root/corerun ./bin/Release/net11.0/test.dll
<0, 0, 0, 0>
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
at Program.M43(Vector256`1 arg1, Byte[]& arg2) in /home/ryujit/dev/test/Program.cs:line 30
at Program.Main() in /home/ryujit/dev/test/Program.cs:line 19
at System.Environment.CallEntryPoint(IntPtr entryPoint, String[]* pArgument, Int32* pReturnValue, Boolean captureException, Exception* pException)
Aborted (core dumped)
I'm not able reproduce the expected behavior, both Release and Debug generate the print, but the error seems to be s_27 never initialized, not sure if I missed any step.
/home/ryujit/dev/runtime/artifacts/tests/coreclr/linux.x64.Debug/Tests/Core_Root/corerun ./bin/Debug/net11.0/test.dll
<0, 0, 0, 0>
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
at Program.M43(Vector256`1 arg1, Byte[]& arg2) in /home/ryujit/dev/test/Program.cs:line 30
at Program.Main() in /home/ryujit/dev/test/Program.cs:line 20
at System.Environment.CallEntryPoint(IntPtr entryPoint, String[]* pArgument, Int32* pReturnValue, Boolean captureException, Exception* pException)
Aborted (core dumped)
~/dev/test$ /home/ryujit/dev/runtime/artifacts/tests/coreclr/linux.x64.Debug/Tests/Core_Root/corerun ./bin/Release/net11.0/test.dll
<0, 0, 0, 0>
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
at Program.M43(Vector256`1 arg1, Byte[]& arg2) in /home/ryujit/dev/test/Program.cs:line 30
at Program.Main() in /home/ryujit/dev/test/Program.cs:line 19
at System.Environment.CallEntryPoint(IntPtr entryPoint, String[]* pArgument, Int32* pReturnValue, Boolean captureException, Exception* pException)
Aborted (core dumped)
I'm not able reproduce the expected behavior, both Release and Debug generate the print, but the error seems to be s_27 never initialized, not sure if I missed any step.
@tannergooding Thanks for picking this up. I apologize for missing this report and not responding in a timely manner. I appreciate the investigation and the work you've done, the bug as you pointed out is coming from that blend got folded during morph and the side effect of the operands got incorrectly handled. Again thanks for the work, please feel free to reassign this issue and close this issue.
Activity
dotnet-policy-service commentedon Mar 11, 2026
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch
See info in area-owners.md if you want to be subscribed.
JulieLeeMSFT commentedon Mar 13, 2026
@anthonycanino, can your team please take a look?
Ruihan-Yin commentedon Apr 17, 2026
I'm not able reproduce the expected behavior, both Release and Debug generate the print, but the error seems to be
s_27never initialized, not sure if I missed any step.jakobbotsch commentedon Apr 17, 2026
Did you remember to disable tiered compilation?
tannergooding commentedon Apr 20, 2026
I can repro with
DOTNET_TieredCompilation=0. The original repro shows it was run on an AVX2 machine but it also repros on an AVX512 machine.Ruihan-Yin commentedon Jul 20, 2026
@tannergooding Thanks for picking this up. I apologize for missing this report and not responding in a timely manner. I appreciate the investigation and the work you've done, the bug as you pointed out is coming from that
blendgot folded during morph and the side effect of the operands got incorrectly handled. Again thanks for the work, please feel free to reassign this issue and close this issue.Fix side-effect reordering when folding constant-zero-mask BlendVaria…
tannergooding commentedon Jul 21, 2026
No worries, things get missed in the hundreds to thousands of notifications that flow through.
I had already been looking in the area and was overall familiar with what needed to be done.