Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
adc18cd
Install clrinterpreter into the sharedFramework to include it in the …
kotlarmilos Jul 3, 2025
d7e4900
Use static clrinterpreter on iOS
kotlarmilos Jul 9, 2025
3c9069b
Fix build errors
kotlarmilos Jul 10, 2025
7ee3bb5
Add functional test
kotlarmilos Jul 10, 2025
cb0724a
Fix build errors
kotlarmilos Jul 10, 2025
6c0b4bf
Build smoke tests
kotlarmilos Jul 10, 2025
b9bb96e
Update executable name placeholder in runtime-coreclr.m
kotlarmilos Jul 11, 2025
56da69b
Set environment variables to interp method
kotlarmilos Jul 14, 2025
7b17711
Set AdditionalXHarnessArguments
kotlarmilos Jul 14, 2025
df02fb9
Set xharness env variables in helix
kotlarmilos Jul 15, 2025
d0fe680
Add support for interpreter methods in AppleAppBuilder
kotlarmilos Jul 15, 2025
311cd87
Add InterpreterMethods property to AppleBuild.targets
kotlarmilos Jul 16, 2025
29d68bf
Update build configuration to Debug and fix condition
kotlarmilos Jul 16, 2025
ca3c0f3
Add environment variables DOTNET_InterpMode and DOTNET_ReadyToRun
kotlarmilos Jul 16, 2025
af5e600
Refactor AppleAppBuilder to support environment variables
kotlarmilos Jul 17, 2025
ecf5b80
Fix condition
kotlarmilos Jul 17, 2025
c8aa690
Update PlatformManifestFileEntry conditions to use RuntimeConfiguration
kotlarmilos Jul 18, 2025
07cee16
Test build without PlatformManifestFileEntry
kotlarmilos Jul 18, 2025
67f7bf2
Add PlatformManifestFileEntry for clrinterpreter
kotlarmilos Jul 18, 2025
733badb
Update FEATURE_INTERPRETER logic to use uppercase build type for Debu…
kotlarmilos Jul 21, 2025
556b295
Update PlatformManifestFileEntry for clrinterpreter
kotlarmilos Jul 21, 2025
19f76ee
Support optional installation of clr components
kotlarmilos Jul 21, 2025
f4c369c
Move functional test to extra-platforms
kotlarmilos Jul 23, 2025
d59deac
Remove condition and clean up CMakeLists
kotlarmilos Jul 23, 2025
169c7cc
Remove condition from iossimulator job
kotlarmilos Jul 24, 2025
1cb8589
Merge branch 'main' into feature/clr-interp-build-ios
kotlarmilos Jul 24, 2025
a7aabb6
Remove redundant JIT static variable from coreclr cmake configuration
kotlarmilos Jul 24, 2025
d5b32d6
Fix build
kotlarmilos Jul 24, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 10 additions & 4 deletions eng/native/functions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -548,11 +548,11 @@ function(install_static_library targetName destination component)
endif()
endfunction()

# install_clr(TARGETS targetName [targetName2 ...] [DESTINATIONS destination [destination2 ...]] [COMPONENT componentName])
# install_clr(TARGETS targetName [targetName2 ...] [DESTINATIONS destination [destination2 ...]] [COMPONENT componentName] [OPTIONAL])
function(install_clr)
set(multiValueArgs TARGETS DESTINATIONS)
set(singleValueArgs COMPONENT)
set(options "")
set(options OPTIONAL)
cmake_parse_arguments(INSTALL_CLR "${options}" "${singleValueArgs}" "${multiValueArgs}" ${ARGV})

if ("${INSTALL_CLR_TARGETS}" STREQUAL "")
Expand Down Expand Up @@ -587,12 +587,18 @@ function(install_clr)
get_symbol_file_name(${targetName} symbolFile)
endif()

if (${INSTALL_CLR_OPTIONAL})
set(INSTALL_CLR_OPTIONAL "OPTIONAL")
else()
set(INSTALL_CLR_OPTIONAL "")
endif()

foreach(destination ${destinations})
# We don't need to install the export libraries for our DLLs
# since they won't be directly linked against.
install(PROGRAMS $<TARGET_FILE:${targetName}> DESTINATION ${destination} COMPONENT ${INSTALL_CLR_COMPONENT})
install(PROGRAMS $<TARGET_FILE:${targetName}> DESTINATION ${destination} COMPONENT ${INSTALL_CLR_COMPONENT} ${INSTALL_CLR_OPTIONAL})
if (NOT "${symbolFile}" STREQUAL "")
install_symbol_file(${symbolFile} ${destination} COMPONENT ${INSTALL_CLR_COMPONENT})
install_symbol_file(${symbolFile} ${destination} COMPONENT ${INSTALL_CLR_COMPONENT} ${INSTALL_CLR_OPTIONAL})
endif()

if(CLR_CMAKE_PGO_INSTRUMENT)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,3 +133,37 @@ jobs:
testBuildArgs: tree nativeaot/SmokeTests /p:BuildNativeAOTRuntimePack=true
testRunNamePrefixSuffix: NativeAOT_$(_BuildConfig)
buildAllTestsAsStandalone: true

#
# iOS simulator
# Build the whole product using CoreCLR and run functional tests
#
- template: /eng/pipelines/common/platform-matrix.yml
parameters:
jobTemplate: /eng/pipelines/common/global-build-job.yml
helixQueuesTemplate: /eng/pipelines/libraries/helix-queues-setup.yml
buildConfig: checked
runtimeFlavor: coreclr
isExtraPlatformsBuild: ${{ parameters.isExtraPlatformsBuild }}
isiOSLikeSimulatorOnlyBuild: ${{ parameters.isiOSLikeSimulatorOnlyBuild }}
platforms:
- iossimulator_arm64
variables:
# map dependencies variables to local variables
- name: librariesContainsChange
value: $[ stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_libraries.containsChange'] ]
- name: coreclrContainsChange
value: $[ stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_coreclr.containsChange'] ]
- name: illinkContainsChange
value: $[ stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_tools_illink.containsChange'] ]
jobParameters:
testGroup: innerloop
nameSuffix: AllSubsets_CoreCLR
buildArgs: -s clr+clr.runtime+libs+packs+libs.tests -c $(_BuildConfig) /p:ArchiveTests=true /p:DevTeamProvisioning=- /p:RunAOTCompilation=false /p:UseMonoRuntime=false /p:MonoForceInterpreter=false /p:RunSmokeTestsOnly=true
timeoutInMinutes: 120
# extra steps, run tests
postBuildSteps:
- template: /eng/pipelines/libraries/helix.yml
parameters:
creator: dotnet-bot
testRunNamePrefixSuffix: CoreCLR_$(_BuildConfig)
4 changes: 4 additions & 0 deletions src/coreclr/clrfeatures.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ if (NOT CLR_CMAKE_TARGET_ARCH_WASM)
set(FEATURE_JIT 1)
endif()

if (CLR_CMAKE_TARGET_ARCH_WASM OR CLR_CMAKE_TARGET_MACCATALYST OR CLR_CMAKE_TARGET_IOS OR CLR_CMAKE_TARGET_TVOS)
set(FEATURE_STATICALLY_LINKED 1)
endif()

if(CLR_CMAKE_TARGET_TIZEN_LINUX)
set(FEATURE_GDBJIT_LANGID_CS 1)
endif()
Expand Down
11 changes: 8 additions & 3 deletions src/coreclr/dlls/mscoree/coreclr/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -173,8 +173,13 @@ if(FEATURE_PERFTRACING)
endif(CLR_CMAKE_TARGET_LINUX)
endif(FEATURE_PERFTRACING)

if(FEATURE_STATICALLY_LINKED)
set(CLRJIT_STATIC clrjit_static)
if (FEATURE_STATICALLY_LINKED)
if (FEATURE_JIT)
set(CLRJIT_STATIC clrjit_static gcinfo)
endif(FEATURE_JIT)
if (FEATURE_INTERPRETER)
set(CLRINTERPRETER_STATIC clrinterpreter)
endif(FEATURE_INTERPRETER)
endif(FEATURE_STATICALLY_LINKED)

if(FEATURE_JIT)
Expand All @@ -192,7 +197,7 @@ if (CLR_CMAKE_TARGET_OSX)
endif()

if(NOT CLR_CMAKE_HOST_ARCH_WASM)
target_link_libraries(coreclr PUBLIC ${CORECLR_LIBRARIES} ${CLRJIT_STATIC} cee_wks_core cee_wks ${FOUNDATION})
target_link_libraries(coreclr PUBLIC ${CORECLR_LIBRARIES} ${CLRJIT_STATIC} ${CLRINTERPRETER_STATIC} cee_wks_core cee_wks ${FOUNDATION})
endif(NOT CLR_CMAKE_HOST_ARCH_WASM)

target_link_libraries(coreclr_static PUBLIC ${CORECLR_LIBRARIES} cee_wks_core ${CORECLR_STATIC_CLRJIT_STATIC} ${CEE_WKS_STATIC} ${FOUNDATION})
Expand Down
6 changes: 4 additions & 2 deletions src/coreclr/interpreter/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,16 @@ else()
add_custom_target(interpreter_exports DEPENDS ${EXPORTS_FILE})
endif()

if(CLR_CMAKE_TARGET_BROWSER)
if(FEATURE_STATICALLY_LINKED AND NOT FEATURE_JIT)
set(LIBRARY_TYPE STATIC)
else()
set(LIBRARY_TYPE SHARED)
endif()

add_library_clr(clrinterpreter ${LIBRARY_TYPE} ${INTERPRETER_SOURCES})

set_target_properties(clrinterpreter PROPERTIES EXCLUDE_FROM_ALL $<NOT:${FEATURE_INTERPRETER}>)

add_dependencies(clrinterpreter interpreter_exports)

if(NOT CLR_CMAKE_HOST_WIN32)
Expand All @@ -63,4 +65,4 @@ target_link_libraries(clrinterpreter

set_property(TARGET clrinterpreter APPEND_STRING PROPERTY LINK_DEPENDS ${EXPORTS_FILE})

install_clr(TARGETS clrinterpreter DESTINATIONS . COMPONENT runtime)
install_clr(TARGETS clrinterpreter DESTINATIONS . sharedFramework COMPONENT runtime OPTIONAL)
4 changes: 0 additions & 4 deletions src/coreclr/vm/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,6 @@ endif(FEATURE_PERFTRACING)
add_compile_definitions($<${FEATURE_CORECLR_CACHED_INTERFACE_DISPATCH}:FEATURE_CACHED_INTERFACE_DISPATCH>)
add_compile_definitions($<${FEATURE_CORECLR_VIRTUAL_STUB_DISPATCH}:FEATURE_VIRTUAL_STUB_DISPATCH>)

if(CLR_CMAKE_TARGET_ARCH_WASM)
add_compile_definitions(FEATURE_STATICALLY_LINKED)
endif()

set(VM_SOURCES_DAC_AND_WKS_COMMON
appdomain.cpp
array.cpp
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,8 @@
<PlatformManifestFileEntry Condition="'$(PgoInstrument)' != ''" Include="clrjit.pgd" IsNative="true" />
<PlatformManifestFileEntry Include="libclrjit.so" IsNative="true" />
<PlatformManifestFileEntry Include="libclrjit.dylib" IsNative="true" />
<PlatformManifestFileEntry Condition="('$(RuntimeConfiguration)' == 'Debug' or '$(RuntimeConfiguration)' == 'Checked') and ('$(TargetArchitecture)' == 'x64' or '$(TargetArchitecture)' == 'arm64')" Include="libclrinterpreter.so" IsNative="true" />
<PlatformManifestFileEntry Condition="('$(RuntimeConfiguration)' == 'Debug' or '$(RuntimeConfiguration)' == 'Checked') and ('$(TargetArchitecture)' == 'x64' or '$(TargetArchitecture)' == 'arm64')" Include="libclrinterpreter.dylib" IsNative="true" />
<PlatformManifestFileEntry Include="mscordaccore.dll" IsNative="true" />
<PlatformManifestFileEntry Include="libmscordaccore.so" IsNative="true" />
<PlatformManifestFileEntry Include="libmscordaccore.dylib" IsNative="true" />
Expand Down
11 changes: 10 additions & 1 deletion src/libraries/tests.proj
Original file line number Diff line number Diff line change
Expand Up @@ -340,6 +340,10 @@
<ProjectExclusions Include="$(RepoRoot)/src/tests/FunctionalTests/iOS/Device/LibraryMode/iOS.Device.LibraryMode.Test.csproj" />
</ItemGroup>

<ItemGroup Condition="('$(TargetOS)' == 'iossimulator' or '$(TargetOS)' == 'tvossimulator') and '$(RuntimeFlavor)' == 'Mono' and '$(RunDisablediOSTests)' != 'true'">
<ProjectExclusions Include="$(RepoRoot)\src\tests\FunctionalTests\iOS\Simulator\CoreCLR.Interpreter\*.Test.csproj" />
</ItemGroup>

<ItemGroup Condition="'$(TargetOS)' == 'browser' and '$(RunDisabledWasmTests)' != 'true' and '$(RunAOTCompilation)' != 'true'">
</ItemGroup>

Expand Down Expand Up @@ -607,6 +611,11 @@
<SmokeTestProject Include="$(RepoRoot)\src\tests\FunctionalTests\Android\Device_Emulator\JIT\*.Test.csproj"/>
</ItemGroup>

<ItemGroup Condition="('$(TargetOS)' == 'iossimulator' or '$(TargetOS)' == 'tvossimulator') and '$(RuntimeFlavor)' == 'CoreCLR'">
<SmokeTestProject Remove="@(SmokeTestProject)" />
<SmokeTestProject Include="$(RepoRoot)\src\tests\FunctionalTests\iOS\Simulator\CoreCLR.Interpreter\*.Test.csproj"/>
</ItemGroup>

<!--
There is a decent number of hidden tests that fail with TestReadyToRun, and
it's proven to be a neverending task to flush all of them at once. So, we will
Expand Down Expand Up @@ -689,7 +698,7 @@
<ProjectReference Include="$(MSBuildThisFileDirectory)System.IO.Hashing\tests\System.IO.Hashing.Tests.csproj" />
</ItemGroup>

<ItemGroup Condition="'$(ArchiveTests)' == 'true' and '$(RunSmokeTestsOnly)' != 'true' and '$(RunGrpcTestsOnly)' != 'true' and '$(TargetOS)' == 'iossimulator'">
<ItemGroup Condition="'$(ArchiveTests)' == 'true' and '$(RunSmokeTestsOnly)' != 'true' and '$(RunGrpcTestsOnly)' != 'true' and '$(TargetOS)' == 'iossimulator' and '$(RuntimeFlavor)' == 'Mono'">
<ProjectReference Include="$(RepoRoot)\src\tests\FunctionalTests\iOS\Simulator\**\*.Test.csproj"
Exclude="@(ProjectExclusions)"
BuildInParallel="false" />
Expand Down
1 change: 1 addition & 0 deletions src/mono/msbuild/apple/build/AppleBuild.targets
Original file line number Diff line number Diff line change
Expand Up @@ -322,6 +322,7 @@
EnableAppSandbox="$(EnableAppSandbox)"
ExcludeFromAppDir="@(_ExcludeFromAppDir)"
ExtraLinkerArguments="@(ExtraAppLinkerArgs)"
EnvironmentVariables="@(EnvironmentVariables)"
ForceAOT="$(RunAOTCompilation)"
ForceInterpreter="$(MonoForceInterpreter)"
GenerateCMakeProject="$(GenerateCMakeProject)"
Expand Down
15 changes: 13 additions & 2 deletions src/tasks/AppleAppBuilder/AppleAppBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,11 @@ public string TargetOS
[Required]
public ITaskItem[] Assemblies { get; set; } = Array.Empty<ITaskItem>();

/// <summary>
/// The set of environment variables
/// </summary>
public ITaskItem[] EnvironmentVariables { get; set; } = Array.Empty<ITaskItem>();

/// <summary>
/// Additional linker arguments that apply to the app being built
/// </summary>
Expand Down Expand Up @@ -315,6 +320,12 @@ public override bool Execute()
assemblerFilesToLink.Add(nativeDependency);
}

List<string> environmentVariables = new List<string>();
foreach (ITaskItem item in EnvironmentVariables)
{
environmentVariables.Add(item.ItemSpec);
}

List<string> extraLinkerArgs = new List<string>();
foreach (ITaskItem item in ExtraLinkerArguments)
{
Expand All @@ -339,7 +350,7 @@ public override bool Execute()
if (GenerateXcodeProject)
{
XcodeProjectPath = generator.GenerateXCode(ProjectName, MainLibraryFileName, assemblerFiles, assemblerDataFiles, assemblerFilesToLink, extraLinkerArgs, excludes,
AppDir, binDir, MonoRuntimeHeaders, !shouldStaticLink, UseConsoleUITemplate, ForceAOT, ForceInterpreter, InvariantGlobalization, HybridGlobalization, Optimized, EnableRuntimeLogging, EnableAppSandbox, DiagnosticPorts, RuntimeComponents, NativeMainSource, targetRuntime, IsLibraryMode);
AppDir, binDir, MonoRuntimeHeaders, !shouldStaticLink, UseConsoleUITemplate, ForceAOT, ForceInterpreter, InvariantGlobalization, HybridGlobalization, Optimized, EnableRuntimeLogging, EnableAppSandbox, DiagnosticPorts, RuntimeComponents, environmentVariables, NativeMainSource, targetRuntime, IsLibraryMode);

if (BuildAppBundle)
{
Expand All @@ -365,7 +376,7 @@ public override bool Execute()
else if (GenerateCMakeProject)
{
generator.GenerateCMake(ProjectName, MainLibraryFileName, assemblerFiles, assemblerDataFiles, assemblerFilesToLink, extraLinkerArgs, excludes,
AppDir, binDir, MonoRuntimeHeaders, !shouldStaticLink, UseConsoleUITemplate, ForceAOT, ForceInterpreter, InvariantGlobalization, HybridGlobalization, Optimized, EnableRuntimeLogging, EnableAppSandbox, DiagnosticPorts, RuntimeComponents, NativeMainSource, targetRuntime, IsLibraryMode);
AppDir, binDir, MonoRuntimeHeaders, !shouldStaticLink, UseConsoleUITemplate, ForceAOT, ForceInterpreter, InvariantGlobalization, HybridGlobalization, Optimized, EnableRuntimeLogging, EnableAppSandbox, DiagnosticPorts, RuntimeComponents, environmentVariables, NativeMainSource, targetRuntime, IsLibraryMode);
}

return true;
Expand Down
6 changes: 4 additions & 2 deletions src/tasks/AppleAppBuilder/Templates/runtime-coreclr.m
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@
setenv ("DOTNET_DiagnosticPorts", DIAGNOSTIC_PORTS, true);
#endif

%EnvVariables%

char **managed_argv;
int argi = get_managed_args (&managed_argv);

Expand All @@ -112,7 +114,7 @@
res = snprintf (icu_dat_path, sizeof (icu_dat_path) - 1, "%s/%s", bundle, "icudt.dat");
#endif
assert (res > 0);

char pinvoke_override_addr [16];
sprintf (pinvoke_override_addr, "%p", &pinvoke_override);

Expand All @@ -136,7 +138,7 @@
#endif
};

const char* executable = "Program.dll";
const char* executable = "%EntryPointLibName%";
const char *executablePath = [[[[NSBundle mainBundle] executableURL] path] UTF8String];
unsigned int coreclr_domainId = 0;
void *coreclr_handle = NULL;
Expand Down
27 changes: 21 additions & 6 deletions src/tasks/AppleAppBuilder/Xcode.cs
Original file line number Diff line number Diff line change
Expand Up @@ -189,11 +189,12 @@ public string GenerateXCode(
bool enableAppSandbox,
string? diagnosticPorts,
IEnumerable<string> runtimeComponents,
IEnumerable<string> environmentVariables,
string? nativeMainSource = null,
TargetRuntime targetRuntime = TargetRuntime.MonoVM,
bool isLibraryMode = false)
{
var cmakeDirectoryPath = GenerateCMake(projectName, entryPointLib, asmFiles, asmDataFiles, asmLinkFiles, extraLinkerArgs, excludes, workspace, binDir, monoInclude, preferDylibs, useConsoleUiTemplate, forceAOT, forceInterpreter, invariantGlobalization, hybridGlobalization, optimized, enableRuntimeLogging, enableAppSandbox, diagnosticPorts, runtimeComponents, nativeMainSource, targetRuntime, isLibraryMode);
var cmakeDirectoryPath = GenerateCMake(projectName, entryPointLib, asmFiles, asmDataFiles, asmLinkFiles, extraLinkerArgs, excludes, workspace, binDir, monoInclude, preferDylibs, useConsoleUiTemplate, forceAOT, forceInterpreter, invariantGlobalization, hybridGlobalization, optimized, enableRuntimeLogging, enableAppSandbox, diagnosticPorts, runtimeComponents, environmentVariables, nativeMainSource, targetRuntime, isLibraryMode);
CreateXcodeProject(projectName, cmakeDirectoryPath);
return Path.Combine(binDir, projectName, projectName + ".xcodeproj");
}
Expand Down Expand Up @@ -262,6 +263,7 @@ public string GenerateCMake(
bool enableAppSandbox,
string? diagnosticPorts,
IEnumerable<string> runtimeComponents,
IEnumerable<string> environmentVariables,
string? nativeMainSource = null,
TargetRuntime targetRuntime = TargetRuntime.MonoVM,
bool isLibraryMode = false)
Expand Down Expand Up @@ -545,11 +547,23 @@ public string GenerateCMake(

File.WriteAllText(Path.Combine(binDir, "CMakeLists.txt"), cmakeLists);

if (needEntitlements) {
string envVariables = string.Empty;
foreach (var item in environmentVariables)
{
var split = item.Split('=');
if (split.Length == 2)
{
envVariables += $"\t\tsetenv (\"{split[0].Trim()}\", \"{split[1].Trim()}\", true);\n";
}
}

if (needEntitlements)
{
var ent = new StringBuilder();
foreach ((var key, var value) in entitlements) {
ent.AppendLine ($"<key>{key}</key>");
ent.AppendLine (value);
foreach ((var key, var value) in entitlements)
{
ent.AppendLine($"<key>{key}</key>");
ent.AppendLine(value);
}
string entitlementsTemplate = Utils.GetEmbeddedResource("app.entitlements.template");
File.WriteAllText(Path.Combine(binDir, "app.entitlements"), entitlementsTemplate.Replace("%Entitlements%", ent.ToString()));
Expand Down Expand Up @@ -597,7 +611,8 @@ public string GenerateCMake(
File.WriteAllText(Path.Combine(binDir, "runtime.m"),
Utils.GetEmbeddedResource("runtime-coreclr.m")
.Replace("//%APPLE_RUNTIME_IDENTIFIER%", RuntimeIdentifier)
.Replace("%EntryPointLibName%", Path.GetFileName(entryPointLib)));
.Replace("%EntryPointLibName%", Path.GetFileName(entryPointLib))
.Replace("%EnvVariables%", envVariables));
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using System;
using System.Threading;
using System.Threading.Tasks;
using System.Runtime.InteropServices;
using System.Runtime.CompilerServices;

public static class Program
{
[DllImport("__Internal")]
public static extern void mono_ios_set_summary(string value);

public static async Task<int> Main(string[] args)
{
mono_ios_set_summary($"Starting functional test");
int result = RunInterpreter();
Console.WriteLine("Done!");
await Task.Delay(5000);

return result;
}

[MethodImpl(MethodImplOptions.NoInlining)]
public unsafe static int RunInterpreter()
{
return 42;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<UseMonoRuntime>false</UseMonoRuntime>
<MonoForceInterpreter>false</MonoForceInterpreter>
<RunAOTCompilation>false</RunAOTCompilation>
<TestRuntime>true</TestRuntime>
<TargetFramework>$(NetCoreAppCurrent)</TargetFramework>
<TargetOS Condition="'$(TargetOS)' == ''">iossimulator</TargetOS>
<MainLibraryFileName>iOS.Simulator.CoreCLR.Interpreter.Test.dll</MainLibraryFileName>
<IncludesTestRunner>false</IncludesTestRunner>
<ExpectedExitCode>42</ExpectedExitCode>
</PropertyGroup>

<ItemGroup>
<EnvironmentVariables Include="DOTNET_Interpreter=RunInterpreter" />
<EnvironmentVariables Include="DOTNET_InterpDump=RunInterpreter" />
<EnvironmentVariables Include="DOTNET_ReadyToRun=0" />
</ItemGroup>

<ItemGroup>
<Compile Include="Program.cs" />
</ItemGroup>
</Project>
Loading