Skip to content

JIT: Assertion failed '!"Bad CastToType() in gtFoldExprConst() for a cast from long" #90798

@jakobbotsch

Description

@jakobbotsch
// Generated by Fuzzlyn v1.6 on 2023-08-18 14:29:26
// Run on X64 Windows
// Seed: 8230539981346104025
// Reduced from 106.2 KiB to 0.3 KiB in 00:00:51
// Hits JIT assert in Release:
// Assertion failed '!"Bad CastToType() in gtFoldExprConst() for a cast from long"' in 'Program:Main(Fuzzlyn.ExecutionServer.IRuntime)' during 'Morph - Global' (IL size 43; hash 0xade6b36b; FullOpts)
//
//     File: C:\dev\dotnet\runtime4\src\coreclr\jit\gentree.cpp Line: 15048
//
using System.Runtime.CompilerServices;

public struct S1
{
    public ulong F0;
}

public class Program
{
    public static void Main()
    {
        S1 vr2 = new S1();
        bool vr3 = Unsafe.ReadUnaligned<bool>(ref Unsafe.As<ulong, byte>(ref vr2.F0));
        System.Console.WriteLine(vr3);
    }
}

Metadata

Metadata

Assignees

Labels

area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions