Skip to content

Commit 060ce34

Browse files
committed
Updated comment from feedback.
1 parent 31f280d commit 060ce34

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

src/BenchmarkDotNet/Engines/Engine.cs

+2-1
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,8 @@ private ClockSpan Measure(Action<long> action, long invokeCount)
230230
// #1542
231231
// We put the current thread to sleep so tiered jit can kick in, compile its stuff,
232232
// and NOT allocate anything on the background thread when we are measuring allocations.
233-
// This is only an issue on netcoreapp3.0 to net6.0. Tiered jit allocations were fixed in net7.0,
233+
// This is only an issue on netcoreapp3.0 to net6.0. Tiered jit allocations were "fixed" in net7.0
234+
// (maybe not completely eliminated forever, but at least reduced to a point where measurements are much more stable),
234235
// and netcoreapp2.X uses only GetAllocatedBytesForCurrentThread which doesn't capture the tiered jit allocations.
235236
Thread.Sleep(TimeSpan.FromMilliseconds(500));
236237
}

tests/BenchmarkDotNet.IntegrationTests/MemoryDiagnoserTests.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ namespace BenchmarkDotNet.IntegrationTests
2929
public class MemoryDiagnoserTests
3030
{
3131
// TODO: re-enable allocating tests after https://github.com/dotnet/runtime/issues/101536 is fixed.
32-
private const string AllocatingSkipReason = "System.Runtime.InteropServices.RuntimeInformation allocates during GC collect";
32+
private const string AllocatingSkipReason = "GC collect causes allocations on finalizer thread";
3333

3434
private readonly ITestOutputHelper output;
3535

0 commit comments

Comments
 (0)