Skip to content

win/x64: Assertion failed 'false && "found use of a node that is not in the LIR sequence"' during 'Lowering nodeinfo'  #108613

@kunalspathak

Description

@kunalspathak
// Found by Antigen
// Reduced from 55.21 KB to 2.77 KB.


using System;
using System.Collections.Generic;
using System.Runtime.CompilerServices;
using System.Runtime.Intrinsics;
using System.Runtime.Intrinsics.Arm;
using System.Runtime.Intrinsics.X86;
using System.Numerics;
public class TestClass
{
    public struct S1
    {
    }
    public struct S2
    {
    }
    static ulong s_ulong_17 = 2;
    static Vector256<ulong> s_v256_ulong_36 = Vector256.CreateScalar((ulong)3);
    static Vector512<uint> s_v512_uint_44 = Vector512<uint>.Zero;
    static Vector<double> s_v_double_58 = Vector.Create(0.05357142857142857);
    static Vector2 s_v2_59 = Vector2.UnitX;
    static S1 s_s1_62 = new S1();
    static S2 s_s2_63 = new S2();
    ulong ulong_77 = 0;
    Vector128<int> v128_int_83 = Vector128.CreateScalar(2);
    Vector512<uint> v512_uint_104 = Vector512.Create((uint)2, 3, 3, 57, 57, 57, 5, 2, 0, 2, 57, 57, 57, 2, 5, 2);
    Vector<ulong> v_ulong_116 = Vector.Create((ulong)5);
    Vector2 v2_119 = Vector2.Zero;
    private static List<string> toPrint = new List<string>();
    public ulong Method1(sbyte p_sbyte_124, S2 p_s2_125, ref Vector<double> p_v_double_126, short p_short_127, Vector2 p_v2_128, ref Vector256<ulong> p_v256_ulong_129, Vector2 p_v2_130, Vector<ulong> p_v_ulong_131, out S1 p_s1_132)
    {
        unchecked
        {
            int int_139 = -1;
            while (15>=4)
            {
                switch (Vector128.GetElement(v128_int_83, 15&4))
                {
                    case 0:
                    {
                        break;
                    }
                    default:
                    {
                        v512_uint_104 *= v512_uint_104 += s_v512_uint_44 -= Vector512<uint>.Zero ^ s_v512_uint_44- (v512_uint_104 += v512_uint_104)& Vector512.AndNot(Vector512.Equals(v512_uint_104, v512_uint_104), Vector512.Equals(v512_uint_104, v512_uint_104)) ^ (v512_uint_104 += s_v512_uint_44 += s_v512_uint_44 ^ v512_uint_104)& (s_v512_uint_44 += Vector512.IsZero(v512_uint_104 - v512_uint_104| Vector512.ShiftLeft(s_v512_uint_44, int_139)));
                        break;
                    }
                }
            }
            return s_ulong_17 ^= ulong_77;
        }
    }
    public void Method0()
    {
        unchecked
        {
            short short_224 = -1;
            s_ulong_17 = Method1(15+4, s_s2_63, ref s_v_double_58, short_224 |= 15<<4, Vector2.Reflect(s_v2_59 - Vector2.UnitX- s_v2_59, s_v2_59 += s_v2_59 *= v2_119) + s_v2_59 - Vector2.UnitX- s_v2_59- (v2_119 *= 15-4)- s_v2_59, ref s_v256_ulong_36, Vector2.Multiply(15+4, s_v2_59), v_ulong_116, out s_s1_62);
            return;
        }
    }
    public static void Main(string[] args)
{}
    public static int Antigen()
    {
        new TestClass().Method0();
        return string.Join(Environment.NewLine, toPrint).GetHashCode();
    }
}
/*
Environment:

set DOTNET_JitELTHookEnabled=1
set DOTNET_TieredCompilation=0
set DOTNET_PreferredVectorBitWidth=512
set DOTNET_EnablePCLMULQDQ=1
set DOTNET_JitThrowOnAssertionFailure=1
set DOTNET_LegacyExceptionHandling=1

Debug: 0
Specified argument was out of the range of valid values.
Release: 0
JIT assert failed:
Assertion failed 'false && "found use of a node that is not in the LIR sequence"' in 'TestClass:Method1(byte,TestClass+S2,byref,short,System.Numerics.Vector2,byref,System.Numerics.Vector2,System.Numerics.Vector`1[ulong],byref):ulong:this' during 'Lowering nodeinfo' (IL size 280; hash 0xcd43e1bd; FullOpts)

    File: D:\a\_work\1\s\src\coreclr\jit\lir.cpp Line: 1687


*/

Metadata

Metadata

Assignees

Labels

area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMIin-prThere is an active PR which will close this issue when it is merged

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions