aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbabenko <babenko@yandex-team.com>2024-10-08 17:56:26 +0300
committerbabenko <babenko@yandex-team.com>2024-10-08 18:10:36 +0300
commitdf546929f65b5f89997eeb0f48d1665c07877b4b (patch)
tree4b921df263efff25932e43482e7e18a3795d102d
parentd17ef5729f3885185bdb7aa459fc4d3bada0c94d (diff)
downloadydb-df546929f65b5f89997eeb0f48d1665c07877b4b.tar.gz
YT-23050: Hazard pointers must not depend on logging
commit_hash:7c833b68ce964fed7a64782fdba37f45f6b0e6be
-rw-r--r--yt/yt/core/misc/hazard_ptr.cpp16
-rw-r--r--yt/yt/core/misc/hazard_ptr.h2
2 files changed, 0 insertions, 18 deletions
diff --git a/yt/yt/core/misc/hazard_ptr.cpp b/yt/yt/core/misc/hazard_ptr.cpp
index ce78cbccf2..ec288eddd9 100644
--- a/yt/yt/core/misc/hazard_ptr.cpp
+++ b/yt/yt/core/misc/hazard_ptr.cpp
@@ -1,7 +1,5 @@
#include "hazard_ptr.h"
-#include "private.h"
-
#include <yt/yt/core/misc/singleton.h>
#include <yt/yt/core/misc/proc.h>
#include <yt/yt/core/misc/ring_queue.h>
@@ -25,10 +23,6 @@ using namespace NConcurrency;
////////////////////////////////////////////////////////////////////////////////
-static constexpr auto& Logger = LockFreeLogger;
-
-////////////////////////////////////////////////////////////////////////////////
-
namespace NDetail {
////////////////////////////////////////////////////////////////////////////////
@@ -325,16 +319,6 @@ bool THazardPointerManager::DoReclaimHazardPointers(THazardThreadState* threadSt
retireList.push(item);
});
- YT_LOG_TRACE_IF(
- !protectedPointers.empty(),
- "Scanning hazard pointers (Candidates: %v, Protected: %v)",
- MakeFormattableView(TRingQueueIterableWrapper(retireList), [&] (auto* builder, auto item) {
- builder->AppendFormat("%v", TTaggedPtr<void>::Unpack(item.PackedPtr).Ptr);
- }),
- MakeFormattableView(protectedPointers, [&] (auto* builder, auto ptr) {
- builder->AppendFormat("%v", ptr);
- }));
-
size_t pushedCount = 0;
auto popCount = retireList.size();
while (popCount-- > 0) {
diff --git a/yt/yt/core/misc/hazard_ptr.h b/yt/yt/core/misc/hazard_ptr.h
index f6a3bf58ca..40202bbf44 100644
--- a/yt/yt/core/misc/hazard_ptr.h
+++ b/yt/yt/core/misc/hazard_ptr.h
@@ -4,8 +4,6 @@
#include <yt/yt/core/concurrency/scheduler_api.h>
-#include <library/cpp/yt/logging/logger.h>
-
#include <atomic>
namespace NYT {