未验证 提交 c8f9f294 编写于 作者: F Filip Navara 提交者: GitHub

[NativeAOT] Enable CI for macOS x64/arm64 (#75421)

* [NativeAOT] Enable CI for macOS x64/arm64

* Update CppCompilerAndLinker condition

* Enable NativeAOT osx-arm64 build in regular runtime pipeline

* Enable cross-compilation on macOS

* Fix HAVE_SHM_OPEN_THAT_WORKS_WELL_ENOUGH_WITH_MMAP when cross-compiling

* Update OSVersion_ValidVersion_OSX test on NativeAOT

The test tries to validate Environment.OSVersion.Version which works correctly. RuntimeInformation.RuntimeIdentifier, however, doesn't use versioned RIDs when NativeAOT is used.

* Add hack to stop linker from corrupting DWARF CFI, bump darwin version in triple to get compact unwinding tables generated

* Bump ObjWriter packages

* Disable MessageSendTests on NativeAOT
Co-authored-by: NAdeel <3840695+am11@users.noreply.github.com>
Co-authored-by: NJan Kotas <jkotas@microsoft.com>
上级 85ddef11
......@@ -16,69 +16,69 @@
<Uri>https://github.com/dotnet/wcf</Uri>
<Sha>7f504aabb1988e9a093c1e74d8040bd52feb2f01</Sha>
</Dependency>
<Dependency Name="runtime.linux-arm64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22458.3">
<Dependency Name="runtime.linux-arm64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>8688ea2538ef1287c6619d35a26b5750d355cc18</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.linux-x64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22458.3">
<Dependency Name="runtime.linux-x64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>8688ea2538ef1287c6619d35a26b5750d355cc18</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22458.3">
<Dependency Name="runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>8688ea2538ef1287c6619d35a26b5750d355cc18</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.linux-musl-x64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22458.3">
<Dependency Name="runtime.linux-musl-x64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>8688ea2538ef1287c6619d35a26b5750d355cc18</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.win-arm64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22458.3">
<Dependency Name="runtime.win-arm64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>8688ea2538ef1287c6619d35a26b5750d355cc18</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.win-x64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22458.3">
<Dependency Name="runtime.win-x64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>8688ea2538ef1287c6619d35a26b5750d355cc18</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.osx.11.0-arm64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22458.3">
<Dependency Name="runtime.osx.11.0-arm64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>8688ea2538ef1287c6619d35a26b5750d355cc18</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22458.3">
<Dependency Name="runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.ObjWriter" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>8688ea2538ef1287c6619d35a26b5750d355cc18</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.linux-arm64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22431.4">
<Dependency Name="runtime.linux-arm64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>c1304304028d603e34f6803b0740c34441f80d2e</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.linux-x64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22431.4">
<Dependency Name="runtime.linux-x64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>c1304304028d603e34f6803b0740c34441f80d2e</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22431.4">
<Dependency Name="runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>c1304304028d603e34f6803b0740c34441f80d2e</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.linux-musl-x64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22431.4">
<Dependency Name="runtime.linux-musl-x64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>754d13817d834b716d339183e21aac7d2489c496</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.win-arm64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22431.4">
<Dependency Name="runtime.win-arm64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>c1304304028d603e34f6803b0740c34441f80d2e</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.win-x64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22431.4">
<Dependency Name="runtime.win-x64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>c1304304028d603e34f6803b0740c34441f80d2e</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.osx.11.0-arm64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22431.4">
<Dependency Name="runtime.osx.11.0-arm64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>c1304304028d603e34f6803b0740c34441f80d2e</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22431.4">
<Dependency Name="runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.JIT.Tools" Version="1.0.0-alpha.1.22478.1">
<Uri>https://github.com/dotnet/llvm-project</Uri>
<Sha>c1304304028d603e34f6803b0740c34441f80d2e</Sha>
<Sha>2e1187ef495010c65842a001f34c46006d5a01bc</Sha>
</Dependency>
<Dependency Name="System.CommandLine" Version="2.0.0-beta4.22355.1">
<Uri>https://github.com/dotnet/command-line-api</Uri>
......
......@@ -80,14 +80,14 @@
<MicrosoftExtensionsDependencyModelVersion>6.0.0</MicrosoftExtensionsDependencyModelVersion>
<!-- CoreClr dependencies -->
<MicrosoftNETCoreILAsmVersion>8.0.0-alpha.1.22475.4</MicrosoftNETCoreILAsmVersion>
<runtimelinuxarm64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22458.3</runtimelinuxarm64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimelinuxx64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22458.3</runtimelinuxx64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimelinuxmuslarm64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22458.3</runtimelinuxmuslarm64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimelinuxmuslx64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22458.3</runtimelinuxmuslx64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimewinarm64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22458.3</runtimewinarm64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimewinx64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22458.3</runtimewinx64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimeosx110arm64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22458.3</runtimeosx110arm64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimeosx1012x64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22458.3</runtimeosx1012x64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimelinuxarm64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22478.1</runtimelinuxarm64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimelinuxx64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22478.1</runtimelinuxx64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimelinuxmuslarm64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22478.1</runtimelinuxmuslarm64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimelinuxmuslx64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22478.1</runtimelinuxmuslx64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimewinarm64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22478.1</runtimewinarm64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimewinx64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22478.1</runtimewinx64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimeosx110arm64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22478.1</runtimeosx110arm64MicrosoftNETCoreRuntimeObjWriterVersion>
<runtimeosx1012x64MicrosoftNETCoreRuntimeObjWriterVersion>1.0.0-alpha.1.22478.1</runtimeosx1012x64MicrosoftNETCoreRuntimeObjWriterVersion>
<!-- Libraries dependencies -->
<MicrosoftBclAsyncInterfacesVersion>6.0.0</MicrosoftBclAsyncInterfacesVersion>
<MicrosoftBclHashCodeVersion>1.1.1</MicrosoftBclHashCodeVersion>
......@@ -206,13 +206,13 @@
<WixPackageVersion>1.0.0-v3.14.0.5722</WixPackageVersion>
<MonoWorkloadManifestVersion>6.0.0-preview.5.21275.7</MonoWorkloadManifestVersion>
<!-- JIT Tools -->
<runtimelinuxarm64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22431.4</runtimelinuxarm64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimelinuxx64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22431.4</runtimelinuxx64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimelinuxmuslarm64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22431.4</runtimelinuxmuslarm64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimelinuxmuslx64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22431.4</runtimelinuxmuslx64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimewinarm64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22431.4</runtimewinarm64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimewinx64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22431.4</runtimewinx64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimeosx110arm64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22431.4</runtimeosx110arm64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimeosx1012x64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22431.4</runtimeosx1012x64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimelinuxarm64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22478.1</runtimelinuxarm64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimelinuxx64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22478.1</runtimelinuxx64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimelinuxmuslarm64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22478.1</runtimelinuxmuslarm64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimelinuxmuslx64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22478.1</runtimelinuxmuslx64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimewinarm64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22478.1</runtimewinarm64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimewinx64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22478.1</runtimewinx64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimeosx110arm64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22478.1</runtimeosx110arm64MicrosoftNETCoreRuntimeJITToolsVersion>
<runtimeosx1012x64MicrosoftNETCoreRuntimeJITToolsVersion>1.0.0-alpha.1.22478.1</runtimeosx1012x64MicrosoftNETCoreRuntimeJITToolsVersion>
</PropertyGroup>
</Project>
......@@ -64,7 +64,7 @@ if(DARWIN)
set_cache_value(SSCANF_CANNOT_HANDLE_MISSING_EXPONENT_EXITCODE 1)
set_cache_value(SSCANF_SUPPORT_ll_EXITCODE 0)
set_cache_value(UNGETC_NOT_RETURN_EOF_EXITCODE 1)
set_cache_value(HAVE_SHM_OPEN_THAT_WORKS_WELL_ENOUGH_WITH_MMAP_EXITCODE 0)
set_cache_value(HAVE_SHM_OPEN_THAT_WORKS_WELL_ENOUGH_WITH_MMAP_EXITCODE 1)
else()
message(FATAL_ERROR "Arch is ${TARGET_ARCH_NAME}. Only arm64 or x64 is supported for OSX cross build!")
endif()
......
......@@ -84,6 +84,8 @@ jobs:
platforms:
- windows_x64
- windows_arm64
- OSX_x64
- OSX_arm64
- Linux_x64
- Linux_arm64
- Linux_musl_x64
......
......@@ -273,6 +273,7 @@ jobs:
platforms:
- windows_arm64
- Linux_arm64
- OSX_arm64
jobParameters:
testGroup: innerloop
isSingleFile: true
......
......@@ -21,8 +21,8 @@
<PropertyGroup Condition="'$(TestNativeAot)' == 'true'">
<IlcToolsPath>$(CoreCLRILCompilerDir)</IlcToolsPath>
<IlcToolsPath Condition="'$(TargetArchitecture)' != '$(BuildArchitecture)'">$(CoreCLRCrossILCompilerDir)</IlcToolsPath>
<CppCompilerAndLinker Condition="'$(TargetArchitecture)' != '$(BuildArchitecture)' and '$(HostOS)' != 'windows' and '$(RuntimeIdentifier)' == 'linux-musl-arm64'">clang-15</CppCompilerAndLinker>
<CppCompilerAndLinker Condition="'$(TargetArchitecture)' != '$(BuildArchitecture)' and '$(HostOS)' != 'windows' and '$(RuntimeIdentifier)' != 'linux-musl-arm64'">clang-9</CppCompilerAndLinker>
<CppCompilerAndLinker Condition="'$(TargetArchitecture)' != '$(BuildArchitecture)' and '$(HostOS)' == 'linux' and '$(RuntimeIdentifier)' == 'linux-musl-arm64'">clang-15</CppCompilerAndLinker>
<CppCompilerAndLinker Condition="'$(TargetArchitecture)' != '$(BuildArchitecture)' and '$(HostOS)' == 'linux' and '$(RuntimeIdentifier)' != 'linux-musl-arm64'">clang-9</CppCompilerAndLinker>
<SysRoot Condition="'$(TargetArchitecture)' != '$(BuildArchitecture)' and '$(HostOS)' != 'windows'">$(ROOTFS_DIR)</SysRoot>
<IlcBuildTasksPath>$(CoreCLRILCompilerDir)netstandard/ILCompiler.Build.Tasks.dll</IlcBuildTasksPath>
<IlcSdkPath>$(CoreCLRAotSdkDir)</IlcSdkPath>
......
......@@ -23,6 +23,8 @@
<OSHostArch Condition="$([MSBuild]::IsOSPlatform('Windows')) and
$([System.Environment]::GetEnvironmentVariable('PROCESSOR_ARCHITECTURE', EnvironmentVariableTarget.Machine)) == 'ARM64'">arm64</OSHostArch>
<OSHostArch Condition="$([MSBuild]::IsOSPlatform('osx')) and '$(CrossBuild)' == 'true'">x64</OSHostArch>
<IlcHostArch Condition="'$(IlcHostArch)' == ''">$(OSHostArch)</IlcHostArch>
<IlcHostPackageName>runtime.$(OSIdentifier)-$(IlcHostArch).Microsoft.DotNet.ILCompiler</IlcHostPackageName>
......
......@@ -29,11 +29,12 @@ The .NET Foundation licenses this file to you under the MIT license.
<FullRuntimeName Condition="'$(ServerGarbageCollection)' == 'true'">libRuntime.ServerGC</FullRuntimeName>
<CrossCompileRid />
<CrossCompileRid Condition="'$(TargetOS)' != 'OSX' and !$(RuntimeIdentifier.EndsWith('-$(OSHostArch)'))">$(RuntimeIdentifier)</CrossCompileRid>
<CrossCompileRid Condition="!$(RuntimeIdentifier.EndsWith('-$(OSHostArch)'))">$(RuntimeIdentifier)</CrossCompileRid>
<CrossCompileArch />
<CrossCompileArch Condition="$(CrossCompileRid.EndsWith('-x64'))">x86_64</CrossCompileArch>
<CrossCompileArch Condition="$(CrossCompileRid.EndsWith('-arm64'))">aarch64</CrossCompileArch>
<CrossCompileArch Condition="$(CrossCompileRid.EndsWith('-arm64')) and '$(TargetOS)' != 'OSX'">aarch64</CrossCompileArch>
<CrossCompileArch Condition="$(CrossCompileRid.EndsWith('-arm64')) and '$(TargetOS)' == 'OSX'">arm64</CrossCompileArch>
<TargetTriple />
<TargetTriple Condition="'$(CrossCompileArch)' != ''">$(CrossCompileArch)-linux-gnu</TargetTriple>
......@@ -85,7 +86,8 @@ The .NET Foundation licenses this file to you under the MIT license.
<ItemGroup>
<LinkerArg Include="@(NativeLibrary)" />
<LinkerArg Include="--sysroot=$(SysRoot)" Condition="'$(SysRoot)' != ''" />
<LinkerArg Include="--target=$(TargetTriple)" Condition="'$(TargetTriple)' != ''" />
<LinkerArg Include="--target=$(TargetTriple)" Condition="'$(TargetOS)' != 'OSX' and '$(TargetTriple)' != ''" />
<LinkerArg Include="-arch $(CrossCompileArch)" Condition="'$(TargetOS)' == 'OSX' and '$(CrossCompileArch)' != ''" />
<LinkerArg Include="-g" Condition="$(NativeDebugSymbols) == 'true'" />
<LinkerArg Include="-Wl,--strip-debug" Condition="$(NativeDebugSymbols) != 'true' and '$(TargetOS)' != 'OSX'" />
<LinkerArg Include="-Wl,-rpath,'$(IlcRPath)'" />
......
......@@ -713,6 +713,18 @@ public void EmitCFICodes(int offset)
// Internal compiler error
Debug.Assert(false);
}
if (_targetPlatform.OperatingSystem == TargetOS.OSX)
{
// Emit a symbol for beginning of the frame. This is workaround for ld64
// linker bug which would produce DWARF with incorrect pcStart offsets for
// exception handling blocks if there is no symbol present for them.
//
// To make things simple we just reuse blobSymbolName and change `_lsda`
// prefix to `_fram`.
"_fram"u8.CopyTo(blobSymbolName);
EmitSymbolDef(blobSymbolName);
}
}
// Emit individual cfi blob for the given offset
......@@ -1272,7 +1284,7 @@ private static string GetLLVMTripleFromTarget(TargetDetails target)
break;
case TargetOS.OSX:
vendor = "apple";
sys = "darwin";
sys = "darwin16";
abi = "macho";
break;
case TargetOS.WebAssembly:
......
......@@ -186,9 +186,13 @@ public void OSVersion_ValidVersion_OSX()
{
Version version = Environment.OSVersion.Version;
// verify that the Environment.OSVersion.Version matches the current RID
// As of 12.0, only major version numbers are included in the RID
Assert.Contains(version.ToString(1), RuntimeInformation.RuntimeIdentifier);
// NativeAOT hard-codes the runtime identifier at build time
if (!PlatformDetection.IsNativeAot)
{
// verify that the Environment.OSVersion.Version matches the current RID
// As of 12.0, only major version numbers are included in the RID
Assert.Contains(version.ToString(1), RuntimeInformation.RuntimeIdentifier);
}
Assert.True(version.Minor >= 0, "OSVersion Minor should be non-negative");
Assert.True(version.Build >= 0, "OSVersion Build should be non-negative");
......
......@@ -16,6 +16,7 @@ namespace System.Runtime.InteropServices.Tests
{
[PlatformSpecific(TestPlatforms.OSX)]
[SkipOnMono("Not currently implemented on Mono")]
[ConditionalClass(typeof(PlatformDetection), nameof(PlatformDetection.IsNotNativeAot))] // https://github.com/dotnet/runtimelab/issues/155
public unsafe class MessageSendTests
{
private static int s_count = 1;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册