Skip to content

Commit e3b2af3

Browse files
agockejkoritzinskyhoyosjsAaronRobinsonMSFTMichalStrehovsky
authored
Update runtime repo to use Preview 7 SDK (#72145)
Co-authored-by: Jeremy Koritzinsky <jekoritz@microsoft.com> Co-authored-by: Juan Hoyos <juan.hoyos@microsoft.com> Co-authored-by: Aaron Robinson <arobins@microsoft.com> Co-authored-by: Michal Strehovský <MichalStrehovsky@users.noreply.github.com> Co-authored-by: Jakob Botsch Nielsen <jakob.botsch.nielsen@gmail.com>
1 parent c61ef61 commit e3b2af3

File tree

9 files changed

+50
-23
lines changed

9 files changed

+50
-23
lines changed

eng/Versions.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
<!--
5050
TODO: Remove pinned version once arcade supplies a compiler that enables the repo to compile.
5151
-->
52-
<MicrosoftNetCompilersToolsetVersion>4.4.0-1.22358.14</MicrosoftNetCompilersToolsetVersion>
52+
<MicrosoftNetCompilersToolsetVersion>4.4.0-2.22412.11</MicrosoftNetCompilersToolsetVersion>
5353
<StaticCsVersion>0.2.0</StaticCsVersion>
5454
<!-- SDK dependencies -->
5555
<MicrosoftDotNetApiCompatTaskVersion>7.0.100-rc.1.22402.1</MicrosoftDotNetApiCompatTaskVersion>

eng/testing/linker/SupportFiles/Directory.Build.props

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@
33
<SkipConfigureTrimming>true</SkipConfigureTrimming>
44
<PublishTrimmed>true</PublishTrimmed>
55
<SkipImportRepoLinkerTargets>true</SkipImportRepoLinkerTargets>
6-
<TrimmerDefaultAction>link</TrimmerDefaultAction>
7-
<TrimMode>link</TrimMode>
6+
<TrimMode>full</TrimMode>
87
<TrimmerRemoveSymbols>false</TrimmerRemoveSymbols>
98
<SelfContained>true</SelfContained>
109
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>

eng/testing/tests.singlefile.targets

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
<RunScriptCommand Condition="'$(TargetOS)' == 'windows'">$(AssemblyName).exe</RunScriptCommand>
1212
<RunScriptCommand Condition="'$(TargetOS)' != 'windows'">chmod +rwx $(AssemblyName) &amp;&amp; ./$(AssemblyName)</RunScriptCommand>
1313
</PropertyGroup>
14-
14+
1515
<PropertyGroup Condition="'$(TestNativeAot)' != 'true'">
1616
<PublishSingleFile>true</PublishSingleFile>
1717
<UseAppHost>true</UseAppHost>
@@ -27,11 +27,47 @@
2727
<IlcSdkPath>$(CoreCLRAotSdkDir)</IlcSdkPath>
2828
<IlcFrameworkPath>$(NetCoreAppCurrentTestHostSharedFrameworkPath)</IlcFrameworkPath>
2929
<NoWarn>$(NoWarn);IL3050;IL3051;IL3052;IL3054;IL3055;IL1005;IL3002</NoWarn>
30+
<TrimMode>partial</TrimMode>
3031
<TrimmerSingleWarn>false</TrimmerSingleWarn>
3132
<SuppressTrimAnalysisWarnings>true</SuppressTrimAnalysisWarnings>
3233

3334
<!-- Forced by ILLink targets; we should fix the SDK -->
3435
<SelfContained>true</SelfContained>
36+
37+
<!-- Works around https://github.com/dotnet/runtime/issues/73926 -->
38+
<!-- RequiresUnreferenceCodeAttribute method called -->
39+
<NoWarn>$(NoWarn);IL2026;IL2116</NoWarn>
40+
<!-- Invalid use of DynamicallyAccessedMembersAttribute -->
41+
<NoWarn>$(NoWarn);IL2041;IL2042;IL2043;IL2056</NoWarn>
42+
<!-- Reference to removed attribute type -->
43+
<NoWarn>$(NoWarn);IL2045</NoWarn>
44+
<!-- RequiresUnreferencedCodeAttribute mismatch on virtual override -->
45+
<NoWarn>$(NoWarn);IL2046</NoWarn>
46+
<!-- COM marshalling warning -->
47+
<NoWarn>$(NoWarn);IL2050</NoWarn>
48+
<!-- Reflection intrinsics with unknown arguments -->
49+
<NoWarn>$(NoWarn);IL2032;IL2055;IL2057;IL2058;IL2059;IL2060;IL2061;IL2096</NoWarn>
50+
<!-- Unknown values passed to locations with DynamicallyAccessedMemberTypes -->
51+
<NoWarn>$(NoWarn);IL2062;IL2063;IL2064;IL2065;IL2066</NoWarn>
52+
<!-- Unsatisfied DynamicallyAccessedMembers requirements -->
53+
<NoWarn>$(NoWarn);IL2067;IL2068;IL2069;IL2070;IL2071;IL2072;IL2073;IL2074;IL2075;IL2076;IL2077;IL2078;IL2079;IL2080;IL2081;IL2082;IL2083;IL2084;IL2085;IL2086;IL2087;IL2088;IL2089;IL2090;IL2091</NoWarn>
54+
<!-- DynamicallyAccessedMembersAttribute mismatch on virtual override -->
55+
<NoWarn>$(NoWarn);IL2092;IL2093;IL2094;IL2095</NoWarn>
56+
<!-- DynamicallyAccessedMembersAttribute used on unsupported member -->
57+
<NoWarn>$(NoWarn);IL2097;IL2098;IL2099;IL2106</NoWarn>
58+
<!-- Unknown value passed to Expression.Property -->
59+
<NoWarn>$(NoWarn);IL2103</NoWarn>
60+
<!-- Multiple methods associated with state machine type or user method -->
61+
<NoWarn>$(NoWarn);IL2107;IL2117</NoWarn>
62+
<!-- Unannotated type derived from base type with RequiresUnreferencedCode -->
63+
<NoWarn>$(NoWarn);IL2109</NoWarn>
64+
<!-- Reflection access to members with DynamicallyAccessedMembers requirements -->
65+
<NoWarn>$(NoWarn);IL2110;IL2111;IL2114;IL2115</NoWarn>
66+
<!-- Reflection access to members with RequiresUnreferencedCode -->
67+
<NoWarn>$(NoWarn);IL2112;IL2113</NoWarn>
68+
<!-- Reflection access to compiler-generated code -->
69+
<NoWarn>$(NoWarn);IL2118;IL2119;IL2120</NoWarn>
70+
3571
</PropertyGroup>
3672

3773
<Import Project="$(CoreCLRBuildIntegrationDir)Microsoft.DotNet.ILCompiler.targets" Condition="'$(TestNativeAot)' == 'true'" />

global.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
22
"sdk": {
3-
"version": "7.0.100-preview.5.22307.18",
3+
"version": "7.0.100-preview.7.22377.5",
44
"allowPrerelease": true,
55
"rollForward": "major"
66
},
77
"tools": {
8-
"dotnet": "7.0.100-preview.5.22307.18"
8+
"dotnet": "7.0.100-preview.7.22377.5"
99
},
1010
"msbuild-sdks": {
1111
"Microsoft.DotNet.Arcade.Sdk": "7.0.0-beta.22411.2",

src/coreclr/tools/aot/ILCompiler.TypeSystem.Tests/CoreTestAssembly/Platform.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,7 @@ public sealed class IsByRefLikeAttribute : Attribute
133133

134134
public static class RuntimeFeature
135135
{
136+
public const string ByRefFields = nameof(ByRefFields);
136137
public const string VirtualStaticsInInterfaces = nameof(VirtualStaticsInInterfaces);
137138
}
138139
}

src/coreclr/tools/aot/crossgen2/crossgen2.props

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@
1313
<EnableDefaultEmbeddedResourceItems>false</EnableDefaultEmbeddedResourceItems>
1414
<Configurations>Debug;Release;Checked</Configurations>
1515
<ServerGarbageCollection>true</ServerGarbageCollection>
16-
<!-- Trim all dependent assemblies as though they were all marked IsTrimmable. -->
17-
<TrimmerDefaultAction>link</TrimmerDefaultAction>
1816
</PropertyGroup>
1917

2018
<ItemGroup Label="Embedded Resources">

src/coreclr/tools/dotnet-pgo/Program.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1626,7 +1626,7 @@ void AddToInstrumentationData(int eventClrInstanceId, long methodID, int methodF
16261626
if (data->ProcessId != p.ProcessID)
16271627
continue;
16281628

1629-
Span<LbrEntry32> lbr32 = data->Entries(e.EventDataLength);
1629+
Span<LbrEntry32> lbr32 = LbrTraceEventData32.Entries(ref *data, e.EventDataLength);
16301630
correlator.AttributeSampleToLbrRuns(lbr32);
16311631
}
16321632
else
@@ -1640,7 +1640,7 @@ void AddToInstrumentationData(int eventClrInstanceId, long methodID, int methodF
16401640
if (data->ProcessId != p.ProcessID)
16411641
continue;
16421642

1643-
Span<LbrEntry64> lbr64 = data->Entries(e.EventDataLength);
1643+
Span<LbrEntry64> lbr64 = LbrTraceEventData64.Entries(ref *data, e.EventDataLength);
16441644
correlator.AttributeSampleToLbrRuns(lbr64);
16451645
}
16461646
}

src/coreclr/tools/dotnet-pgo/SPGO/LbrEntry.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@ public unsafe struct LbrTraceEventData32
5555
public LbrOptionFlags Options;
5656
private LbrEntry32 _entries;
5757

58-
public Span<LbrEntry32> Entries(int totalSize)
58+
public static Span<LbrEntry32> Entries(ref LbrTraceEventData32 data, int totalSize)
5959
{
60-
IntPtr entriesOffset = Unsafe.ByteOffset(ref Unsafe.As<LbrTraceEventData32, byte>(ref this), ref Unsafe.As<LbrEntry32, byte>(ref _entries));
61-
return MemoryMarshal.CreateSpan(ref _entries, (totalSize - (int)entriesOffset) / sizeof(LbrEntry32));
60+
IntPtr entriesOffset = Unsafe.ByteOffset(ref Unsafe.As<LbrTraceEventData32, byte>(ref data), ref Unsafe.As<LbrEntry32, byte>(ref data._entries));
61+
return MemoryMarshal.CreateSpan(ref data._entries, (totalSize - (int)entriesOffset) / sizeof(LbrEntry32));
6262
}
6363
}
6464

@@ -71,10 +71,10 @@ public unsafe struct LbrTraceEventData64
7171
public LbrOptionFlags Options;
7272
private LbrEntry64 _entries;
7373

74-
public Span<LbrEntry64> Entries(int totalSize)
74+
public static Span<LbrEntry64> Entries(ref LbrTraceEventData64 data, int totalSize)
7575
{
76-
IntPtr entriesOffset = Unsafe.ByteOffset(ref Unsafe.As<LbrTraceEventData64, byte>(ref this), ref Unsafe.As<LbrEntry64, byte>(ref _entries));
77-
return MemoryMarshal.CreateSpan(ref _entries, (totalSize - (int)entriesOffset) / sizeof(LbrEntry64));
76+
IntPtr entriesOffset = Unsafe.ByteOffset(ref Unsafe.As<LbrTraceEventData64, byte>(ref data), ref Unsafe.As<LbrEntry64, byte>(ref data._entries));
77+
return MemoryMarshal.CreateSpan(ref data._entries, (totalSize - (int)entriesOffset) / sizeof(LbrEntry64));
7878
}
7979
}
8080
}

src/tests/nativeaot/Directory.Build.props

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)