Eliminate EventPipeBuffer::Close()
authorAndrew Au <andrewau@microsoft.com>
Wed, 27 Mar 2019 00:38:27 +0000 (17:38 -0700)
committerAndrew Au <cshung@gmail.com>
Wed, 27 Mar 2019 16:07:38 +0000 (09:07 -0700)
src/vm/eventpipebuffer.cpp
src/vm/eventpipebuffer.h

index 31646be..887fbc0 100644 (file)
@@ -133,22 +133,6 @@ LARGE_INTEGER EventPipeBuffer::GetMostRecentTimeStamp() const
     return m_mostRecentTimeStamp;
 }
 
-void EventPipeBuffer::Clear()
-{
-    CONTRACTL
-    {
-        NOTHROW;
-        GC_TRIGGERS;
-        MODE_ANY;
-    }
-    CONTRACTL_END;
-
-    memset(m_pBuffer, 0, (size_t)(m_pLimit - m_pBuffer));
-    m_pCurrent = GetNextAlignedAddress(m_pBuffer);
-    m_mostRecentTimeStamp.QuadPart = 0;
-    m_pLastPoppedEvent = NULL;
-}
-
 EventPipeEventInstance* EventPipeBuffer::GetNext(EventPipeEventInstance *pEvent, LARGE_INTEGER beforeTimeStamp)
 {
     CONTRACTL
index 7b20883..c717d89 100644 (file)
@@ -103,9 +103,6 @@ public:
     // Get the timestamp of the most recent event in the buffer.
     LARGE_INTEGER GetMostRecentTimeStamp() const;
 
-    // Clear the buffer.
-    void Clear();
-
     // Get the next event from the buffer as long as it is before the specified timestamp.
     // Input of NULL gets the first event.
     EventPipeEventInstance* GetNext(EventPipeEventInstance *pEvent, LARGE_INTEGER beforeTimeStamp);