Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add set of attributes that can be trimmed on NAOT #88718

Merged
merged 1 commit into from
Jul 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<linker>

<!-- Internal implementation details that are always fine to strip -->
<assembly fullname="System.Private.CoreLib">
<type fullname="System.Runtime.CompilerServices.IntrinsicAttribute">
<attribute internal="RemoveAttributeInstances" />
</type>
<type fullname="System.Runtime.CompilerServices.ForceDictionaryLookupsAttribute">
<attribute internal="RemoveAttributeInstances" />
</type>
<type fullname="System.Runtime.CompilerServices.EagerStaticClassConstructionAttribute">
<attribute internal="RemoveAttributeInstances" />
</type>
</assembly>

<assembly fullname="*">
<!-- Internal attributes shared as implementation, so they could be in any assembly -->
<type fullname="System.Runtime.Versioning.NonVersionableAttribute">
<attribute internal="RemoveAttributeInstances" />
</type>
</assembly>

<!-- Public attributes that need to be interpreted by the compiler, fine to strip afterwards -->
<assembly fullname="System.Private.CoreLib" feature="System.AggressiveAttributeTrimming" featurevalue="true">
<type fullname="System.Runtime.CompilerServices.DisableRuntimeMarshallingAttribute">
<attribute internal="RemoveAttributeInstances" />
</type>
<type fullname="System.Runtime.CompilerServices.CompilationRelaxationsAttribute">
<attribute internal="RemoveAttributeInstances" />
</type>
<type fullname="System.Runtime.CompilerServices.RuntimeCompatibilityAttribute">
<attribute internal="RemoveAttributeInstances" />
</type>
</assembly>

</linker>
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

<ItemGroup>
<ILLinkSubstitutionsXmls Include="ILLink\ILLink.Substitutions.xml" />
<ILLinkLinkAttributesXmls Include="ILLink\ILLink.LinkAttributes.xml" />
</ItemGroup>
<ItemGroup Condition="'$(TargetsUnix)'=='true'">
<ILLinkSubstitutionsXmls Include="ILLink\ILLink.Substitutions.Unix.xml" />
Expand Down
Loading