-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Closed
Labels
area-ReadyToRun-coreclrbacklog-cleanup-candidateAn inactive issue that has been marked for automated closure.An inactive issue that has been marked for automated closure.no-recent-activity
Milestone
Description
Running crossgen on the below code results in following messages
ReadyToRun: JIT helper not supported: CORINFO_HELP_INITCLASS
ReadyToRun: JIT helper not supported: CORINFO_HELP_INITINSTCLASS
Infrastructure to support this has been added to RyuJIT with dotnet/coreclr#7842, but this is currently excluded with eeGetEEInfo()->targetAbi == CORINFO_CORERT_ABI because only CoreRT knows how to generate the helper.
using System;
class Gen1<T> where T: class
{
static Gen1()
{
}
public static string Get1()
{
return ("Hello" as T) as string;
}
public static string Get2<U>()
{
return ("Hello" as T) as string;
}
}
class Gen2<T> where T: class
{
public static string GetFromClassParam()
{
return (Gen1<T>.Get1() as T) as string;
}
public static string GetFromMethodParam()
{
return (Gen1<T>.Get2<T>() as T) as string;
}
}
internal class Program
{
private static int Main()
{
return Gen2<string>.GetFromClassParam().Length + Gen2<string>.GetFromMethodParam().Length;
}
}Metadata
Metadata
Assignees
Labels
area-ReadyToRun-coreclrbacklog-cleanup-candidateAn inactive issue that has been marked for automated closure.An inactive issue that has been marked for automated closure.no-recent-activity