EventPipeBufferList has a potential leak under EventPipeBufferManager::DeAllocateBuffers(), and a potential race condition where WriteEvent may set the flag to indicate a buffer is in use when another thread is trying to free the buffers after checking that they aren't in use. So we should probably protect that flag with a lock to prevent this.
Some background info (comment from Noah):
dotnet/coreclr#21817 (comment)