summaryrefslogtreecommitdiffstats
path: root/library/cpp/yt/rseq/rseq.cpp
diff options
context:
space:
mode:
authorYDBot <[email protected]>2026-07-01 16:23:57 +0000
committerYDBot <[email protected]>2026-07-01 16:23:57 +0000
commite9b445a7f111ee5ba5c58672d767833df25ba262 (patch)
tree1b8bdb84d3fd994ff3ac60e36c30f93fbfce1243 /library/cpp/yt/rseq/rseq.cpp
parent1cfcce4de55cd075cfba845abf02c1554f141e01 (diff)
parentc98b5dbfe575ba628d7c3427854e7bd26030eb2c (diff)
Merge pull request #44637 from ydb-platform/merge-rightlib-260626-1120
Diffstat (limited to 'library/cpp/yt/rseq/rseq.cpp')
-rw-r--r--library/cpp/yt/rseq/rseq.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/library/cpp/yt/rseq/rseq.cpp b/library/cpp/yt/rseq/rseq.cpp
index f8321cbb0bf..12b5a291d8d 100644
--- a/library/cpp/yt/rseq/rseq.cpp
+++ b/library/cpp/yt/rseq/rseq.cpp
@@ -133,7 +133,7 @@ YT_STATIC_INITIALIZER({
// the static TLS block, incl. tcmalloc) rather than a dlopen'd module's dynamically allocated
// TLS, where the offset is valid only on the thread that computed it. Compares addresses
// without dereferencing the suspect offset, so it is safe even when the offset is bogus. See
-// IsPerCpuFastPathSafe.
+// IsPerCpuFastPathSupported.
YT_PREVENT_TLS_CACHING bool ValidateFastPathOnFreshThread()
{
if (OwnsRegistration) {
@@ -177,7 +177,7 @@ YT_PREVENT_TLS_CACHING bool EnsureCurrentThreadRegistered()
return ReadField<int>(CpuIdFieldOffset) >= 0;
}
-bool IsPerCpuFastPathSafe()
+bool IsPerCpuFastPathSupported()
{
// Decided once, lazily, on a freshly spawned thread (the check is meaningful only off the
// thread that computed the offset) and cached -- cost is one thread spawn at first use.
@@ -205,14 +205,12 @@ bool IsPerCpuFastPathSafe()
#else // YT_RSEQ_AVAILABLE
-#include "per_cpu.h"
-
namespace NYT::NRseq {
////////////////////////////////////////////////////////////////////////////////
// No rseq fast path on this platform; hot sensors use the atomic fallback.
-bool IsPerCpuFastPathSafe()
+bool IsPerCpuFastPathSupported()
{
return false;
}