Skip to content

JIT: Assertion failed 'IS_ALIGNED(addr, byteSize)' during 'Emit code'  #105624

@jakobbotsch

Description

@jakobbotsch
// Generated by Fuzzlyn v2.1 on 2024-07-28 20:12:47
// Run on X64 Linux
// Seed: 10470319919864604789-vectort,vector128,vector256,x86aes,x86avx,x86avx2,x86avx512bw,x86avx512bwvl,x86avx512cd,x86avx512cdvl,x86avx512dq,x86avx512dqvl,x86avx512f,x86avx512fvl,x86avx512fx64,x86bmi1,x86bmi1x64,x86bmi2,x86bmi2x64,x86fma,x86lzcnt,x86lzcntx64,x86pclmulqdq,x86popcnt,x86popcntx64,x86sse,x86ssex64,x86sse2,x86sse2x64,x86sse3,x86sse41,x86sse41x64,x86sse42,x86sse42x64,x86ssse3,x86x86base
// Reduced from 21.8 KiB to 0.7 KiB in 00:01:56
// Hits JIT assert in Release:
// Assertion failed 'IS_ALIGNED(addr, byteSize)' in 'Program:Main(Fuzzlyn.ExecutionServer.IRuntime)' during 'Emit code' (IL size 31; hash 0xade6b36b; FullOpts)
// 
//     File: /__w/1/s/src/coreclr/jit/emitxarch.cpp Line: 14543
// 
using System;
using System.Runtime.CompilerServices;
using System.Numerics;
using System.Runtime.Intrinsics;
using System.Runtime.Intrinsics.X86;

public class Program
{
    public static float s_8;
    public static void Main(Fuzzlyn.ExecutionServer.IRuntime rt)
    {
        var vr10 = Vector128.CreateScalar(4294967295U);
        var vr9 = Avx512F.VL.ConvertToVector256Double(vr10);
        var vr1 = Avx.MoveMask(vr9);
        M6(ref s_8, vr1);
    }

    public static void M5()
    {
        var vr8 = Vector128.CreateScalar(4294967295U);
    }

    public static float M6(ref float arg3, double arg9)
    {
        for (int var0 = 0; var0 < 0; var0++)
        {
        }

        return arg3++;
    }
}

The reducer seemingly was not able to make this into a standalone program. I've attached an SPMI collection captured on 0912e94 that reproduces the problem.
CA2A3F23.zip

cc @dotnet/jit-contrib

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