Skip to content

[Mono] [GC] Fix TotalBytesAllocated and reenable test#20427

Merged
lambdageek merged 1 commit intomono:masterfrom
monojenkins:sync-pr-42388-from-runtime
Sep 24, 2020
Merged

[Mono] [GC] Fix TotalBytesAllocated and reenable test#20427
lambdageek merged 1 commit intomono:masterfrom
monojenkins:sync-pr-42388-from-runtime

Conversation

@monojenkins
Copy link
Contributor

@monojenkins monojenkins commented Sep 23, 2020

!! This PR is a copy of dotnet/runtime#42388, please do not edit or review it in this repo !!
Do not automatically approve this PR:

* Consider how the changes affect configurations in this repo,
* Check effects on files that are not mirrored,
* Identify test cases that may be needed in this repo.

!! Merge the PR only after the original PR is merged !!



TotalBytesAllocated was sometimes not monotonically increasing on Mono. The reason was that when a thread was detached, we were not counting bytes allocated in its thread local allocation buffer. So, under the right circumstances the bytes would be counted while the thread is attached, but then get lost when the thread detached.

Fixes: dotnet/runtime#2280

Trying to see if this test still fails in CI; this is a draft PR with it enabled to test.
@lambdageek lambdageek marked this pull request as ready for review September 24, 2020 17:36
@lambdageek lambdageek changed the title [Draft] [Test] Reenable TotalBytesAllocated test on Mono [Mono] [GC] Fix TotalBytesAllocated and reenable test Sep 24, 2020
@lambdageek
Copy link
Member

OSX failure is unrelated

@lambdageek lambdageek merged commit e029440 into mono:master Sep 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

GCExtendedTests.GetTotalAllocatedBytes failed on Mono on Ubuntu in CI

3 participants