Skip to content

Commit

Permalink
Delete the RequiresPreviewFeaturesAttribute from RefreshMemoryLimit (d…
Browse files Browse the repository at this point in the history
  • Loading branch information
cshung committed Sep 13, 2023
1 parent 0f3d1ed commit bf805b3
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 6 deletions.
3 changes: 0 additions & 3 deletions src/coreclr/System.Private.CoreLib/src/System/GC.CoreCLR.cs
Original file line number Diff line number Diff line change
Expand Up @@ -899,13 +899,10 @@ internal enum RefreshMemoryStatus
///
/// This API will only handle configs that could be handled when the runtime is loaded, for example, for configs that don't have any effects on 32-bit systems (like the GCHeapHardLimit* ones), this API will not handle it.
///
/// As of now, this API is feature preview only and subject to changes as necessary.
///
/// <exception cref="InvalidOperationException">If the hard limit is too low. This can happen if the heap hard limit that the refresh will set, either because of new AppData settings or implied by the container memory limit changes, is lower than what is already committed.</exception>
/// <exception cref="InvalidOperationException">If the hard limit is invalid. This can happen, for example, with negative heap hard limit percentages.</exception>
///
/// </summary>
[RequiresPreviewFeatures("RefreshMemoryLimit is in preview.")]
public static void RefreshMemoryLimit()
{
ulong heapHardLimit = (AppContext.GetData("GCHeapHardLimit") as ulong?) ?? ulong.MaxValue;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -869,7 +869,6 @@ public static TimeSpan GetTotalPauseDuration()
return new TimeSpan(RuntimeImports.RhGetTotalPauseDuration());
}

[System.Runtime.Versioning.RequiresPreviewFeaturesAttribute("RefreshMemoryLimit is in preview.")]
public static void RefreshMemoryLimit()
{
ulong heapHardLimit = (AppContext.GetData("GCHeapHardLimit") as ulong?) ?? ulong.MaxValue;
Expand Down
1 change: 0 additions & 1 deletion src/libraries/System.Runtime/ref/System.Runtime.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2722,7 +2722,6 @@ public static void SuppressFinalize(object obj) { }
public static void WaitForPendingFinalizers() { }
public static TimeSpan GetTotalPauseDuration() { throw null; }
public static System.Collections.Generic.IReadOnlyDictionary<string, object> GetConfigurationVariables() { throw null; }
[System.Runtime.Versioning.RequiresPreviewFeaturesAttribute("RefreshMemoryLimit is in preview.")]
public static void RefreshMemoryLimit() { throw null; }
}

Expand Down
1 change: 0 additions & 1 deletion src/mono/System.Private.CoreLib/src/System/GC.Mono.cs
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,6 @@ public static System.Collections.Generic.IReadOnlyDictionary<string, object> Get
return new System.Collections.Generic.Dictionary<string, object>();
}

[System.Runtime.Versioning.RequiresPreviewFeaturesAttribute("RefreshMemoryLimit is in preview.")]
public static void RefreshMemoryLimit()
{
throw new PlatformNotSupportedException();
Expand Down

0 comments on commit bf805b3

Please sign in to comment.