-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
[release/8.0] Delete the RequiresPreviewFeaturesAttribute from RefreshMemoryLimit #91688
[release/8.0] Delete the RequiresPreviewFeaturesAttribute from RefreshMemoryLimit #91688
Conversation
Note regarding the This serves as a reminder for when your PR is modifying a ref *.cs file and adding/modifying public APIs, please make sure the API implementation in the src *.cs file is documented with triple slash comments, so the PR reviewers can sign off that change. |
Tagging subscribers to this area: @dotnet/area-system-runtime Issue Detailsnull
|
8aab152
to
e23f90b
Compare
Are there tests somewhere for GC.RefreshMemoryLimit()? I'm not seeing any. |
If we turn on |
It calls the managed method, or the underlying functionality? If I were to change the managed method to nop or throw accidentally, what test would fail? And if the answer is "none", that's ok? |
You are right, if someone nop the method, no test will detect that failure. From a risk perspective, it is so much easier for a GC dev to forget hard limit could be changed and therefore write incompatible code than someone nop the managed method, that's why testing has been focused there. There are some glue code at the qcall layer that won't be exercised without a test calling from the managed side as well. I think there is value to add a managed test, let me add one. |
@cshung can you please fill out the servicing template from the PR description and get an M2 approval when this is ready to merge? |
e23f90b
to
bf805b3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
approved. this can be merged when ready
Backport of #91622 to release/8.0
Customer Impact
This is to enable the RefreshMemoryLimit feature so that it won't require the
RequiresPreviewFeaturesAttribute
. This is going to be used by Amazon Lambda here.Testing
The internal working is tested by enabling the
COMMITTED_BYTES_SHADOW
feature switch - the switch will trigger a call toRefreshMemoryLimit
for each GC, and it was run as part of the GC exit criteria run.The managed part of the method is not currently tested, work is in progress to provide some coverage through #91833.
Risk
The API is already public, this change does not add any more risk for customers who will call it regardless of the existence of a warning or not.