aboutsummaryrefslogtreecommitdiff
path: root/src/zenstore/gc.cpp
diff options
context:
space:
mode:
authorStefan Boberg <[email protected]>2023-05-16 13:34:08 +0200
committerGitHub <[email protected]>2023-05-16 13:34:08 +0200
commit4c518511ccf35c79284bde3dd10860b9bb52b6a0 (patch)
tree05f58d276ee82564832a2c9c078d3b1b6809d3cb /src/zenstore/gc.cpp
parentMoved EnableVTMode function into zencore (#311) (diff)
downloadzen-4c518511ccf35c79284bde3dd10860b9bb52b6a0.tar.xz
zen-4c518511ccf35c79284bde3dd10860b9bb52b6a0.zip
Additional trace instrumentation (#312)
* added trace instrumentation to upstreamcache * added asio trace instrumentation * added trace annotations for project store * added trace annotations for BlockStore * added trace annotations for HttpClient * added trace annotations for CAS/GC
Diffstat (limited to 'src/zenstore/gc.cpp')
-rw-r--r--src/zenstore/gc.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/zenstore/gc.cpp b/src/zenstore/gc.cpp
index 2d7e0e02f..dc19a9a35 100644
--- a/src/zenstore/gc.cpp
+++ b/src/zenstore/gc.cpp
@@ -14,6 +14,7 @@
#include <zencore/testing.h>
#include <zencore/testutils.h>
#include <zencore/timer.h>
+#include <zencore/trace.h>
#include <zenstore/cidstore.h>
#include "cas.h"
@@ -379,6 +380,8 @@ GcManager::RemoveGcStorage(GcStorage* Storage)
void
GcManager::CollectGarbage(GcContext& GcCtx)
{
+ ZEN_TRACE_CPU("Gc::CollectGarbage");
+
RwLock::SharedLockScope _(m_Lock);
// First gather reference set
@@ -415,6 +418,8 @@ GcManager::CollectGarbage(GcContext& GcCtx)
GcStorageSize
GcManager::TotalStorageSize() const
{
+ ZEN_TRACE_CPU("Gc::TotalStorageSize");
+
RwLock::SharedLockScope _(m_Lock);
GcStorageSize TotalSize;