Skip to content

Commit e0920d1

Browse files
MSDN-WhiteKnightsdmaclea
authored andcommitted
Update AssemblyLoadContext.xml (#2833)
- Fix AssemblyLoadContext.LoadUnmanagedDll return value. IntPtr is a value type and can't be null. - Add missing property descriptions.
1 parent 453ea9e commit e0920d1

File tree

1 file changed

+27
-11
lines changed

1 file changed

+27
-11
lines changed

xml/System.Runtime.Loader/AssemblyLoadContext.xml

Lines changed: 27 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -730,12 +730,12 @@ Each <xref:System.Runtime.Loader.AssemblyLoadContext> can load only:
730730
<Docs>
731731
<param name="unmanagedDllName">Name of the unmanaged library. Typically this is the filename without its path or extensions. </param>
732732
<summary>Allows derived class to load an unmanaged library by name.</summary>
733-
<returns>A handle to the loaded library, or <see langword="null" />.</returns>
733+
<returns>A handle to the loaded library, or <see cref="F:System.IntPtr.Zero" />.</returns>
734734
<remarks>
735735
<format type="text/markdown"><![CDATA[
736736
737737
## Remarks
738-
The default implementation always return `null`. When `null` is returned, the runtime loads the library with its default policy.
738+
The default implementation always returns <xref:System.IntPtr.Zero?displayProperty=nameWithType>. When <xref:System.IntPtr.Zero?displayProperty=nameWithType> is returned, the runtime loads the library with its default policy.
739739
740740
This virtual method can be overridden to customize the unmanaged library search algorithm. When overridden the name can be used to identify the library. The loaded library does not need to match the requested name, but can be transformed as needed. This could include adjusting the name for platform specific naming.
741741
@@ -893,9 +893,17 @@ This event is raised if the native library cannot be resolved by the default res
893893
<Parameter Name="directoryPath" Type="System.String" />
894894
</Parameters>
895895
<Docs>
896-
<param name="directoryPath">To be added.</param>
897-
<summary>To be added.</summary>
898-
<remarks>To be added.</remarks>
896+
<param name="directoryPath">The full path to the directory where the optimization profiles are stored.</param>
897+
<summary>Sets the root path where the optimization profiles for this load context are stored.</summary>
898+
<remarks>
899+
<format type="text/markdown"><![CDATA[
900+
901+
## Remarks
902+
903+
The profile optimization improves the startup performance of the load context on multicore computers by performing background compilation of methods that are likely to be executed, based on profiles created during previous compilations. For more information, see <xref:System.Runtime.ProfileOptimization>.
904+
905+
]]></format>
906+
</remarks>
899907
</Docs>
900908
</Member>
901909
<Member MemberName="StartProfileOptimization">
@@ -924,9 +932,17 @@ This event is raised if the native library cannot be resolved by the default res
924932
<Parameter Name="profile" Type="System.String" />
925933
</Parameters>
926934
<Docs>
927-
<param name="profile">To be added.</param>
928-
<summary>To be added.</summary>
929-
<remarks>To be added.</remarks>
935+
<param name="profile">The name of the optimization profile.</param>
936+
<summary>Starts the profile optimization for the specified profile.</summary>
937+
<remarks>
938+
<format type="text/markdown"><![CDATA[
939+
940+
## Remarks
941+
942+
The profile optimization improves the startup performance of the load context on multicore computers by performing background compilation of methods that are likely to be executed, based on profiles created during previous compilations. For more information, see <xref:System.Runtime.ProfileOptimization>.
943+
944+
]]></format>
945+
</remarks>
930946
</Docs>
931947
</Member>
932948
<Member MemberName="ToString">
@@ -946,8 +962,8 @@ This event is raised if the native library cannot be resolved by the default res
946962
</ReturnValue>
947963
<Parameters />
948964
<Docs>
949-
<summary>To be added.</summary>
950-
<returns>To be added.</returns>
965+
<summary>Returns the string representation of this load context.</summary>
966+
<returns>The string representation of this load context.</returns>
951967
<remarks>To be added.</remarks>
952968
</Docs>
953969
</Member>
@@ -1011,4 +1027,4 @@ This event is raised if the native library cannot be resolved by the default res
10111027
</Docs>
10121028
</Member>
10131029
</Members>
1014-
</Type>
1030+
</Type>

0 commit comments

Comments
 (0)