Skip to content

Commit

Permalink
Reduce unnecessary combined_limit writes
Browse files Browse the repository at this point in the history
  • Loading branch information
noahfalk committed Jul 19, 2024
1 parent f7e610c commit 62d93bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/coreclr/nativeaot/Runtime/gcenv.ee.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ void GCToEEInterface::GcEnumAllocContexts(enum_alloc_context_func* fn, void* par
// combined_limit up-to-date. Note that the GC has multiple threads running this enumeration concurrently
// with no synchronization. If you need to change this code think carefully about how that concurrency
// may affect the results.
if (ac->alloc_limit == 0)
if (ac->alloc_limit == 0 && palloc_context->combined_limit != 0)
{
palloc_context->combined_limit = 0;
}
Expand Down

0 comments on commit 62d93bb

Please sign in to comment.