summaryrefslogtreecommitdiffstats
path: root/library/cpp/actors/core/defs.h
diff options
context:
space:
mode:
authorddoarn <[email protected]>2022-02-10 16:49:52 +0300
committerDaniil Cherednik <[email protected]>2022-02-10 16:49:52 +0300
commit0783fe3f48d91a3b741ce2ea32b11fbfc1637e7e (patch)
tree6d6a79d83e5003eaf4d45cac346113c1137cb886 /library/cpp/actors/core/defs.h
parent9541fc30d6f0877db9ff199a16f7fc2505d46a5c (diff)
Restoring authorship annotation for <[email protected]>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/actors/core/defs.h')
-rw-r--r--library/cpp/actors/core/defs.h42
1 files changed, 21 insertions, 21 deletions
diff --git a/library/cpp/actors/core/defs.h b/library/cpp/actors/core/defs.h
index 980b7d767bc..34ddee397ee 100644
--- a/library/cpp/actors/core/defs.h
+++ b/library/cpp/actors/core/defs.h
@@ -1,18 +1,18 @@
-#pragma once
-
-// unique tag to fix pragma once gcc glueing: ./library/actorlib/core/defs.h
-
+#pragma once
+
+// unique tag to fix pragma once gcc glueing: ./library/actorlib/core/defs.h
+
#include <library/cpp/actors/util/defs.h>
#include <util/generic/hash.h>
#include <util/string/printf.h>
-
+
// Enables collection of
// event send/receive counts
// activation time histograms
// event processing time histograms
#define ACTORSLIB_COLLECT_EXEC_STATS
-namespace NActors {
+namespace NActors {
using TPoolId = ui8;
using TPoolsMask = ui64;
static constexpr TPoolId PoolBits = 6;
@@ -37,19 +37,19 @@ namespace NActors {
using TThreadId = ui64;
static constexpr TThreadId UnknownThreadId = ui64(-1);
- struct TMailboxType {
- enum EType {
+ struct TMailboxType {
+ enum EType {
Inherited = -1, // inherit mailbox from parent
- Simple = 0, // simplest queue under producer lock. fastest in no-contention case
- Revolving = 1, // somewhat outdated, tries to be wait-free. replaced by ReadAsFilled
- HTSwap = 2, // other simple lf queue, suggested for low-contention case
- ReadAsFilled = 3, // wait-free queue, suggested for high-contention or latency critical
- TinyReadAsFilled = 4, // same as 3 but with lower overhead
- //Inplace;
- //Direct;
- //Virtual
- };
- };
+ Simple = 0, // simplest queue under producer lock. fastest in no-contention case
+ Revolving = 1, // somewhat outdated, tries to be wait-free. replaced by ReadAsFilled
+ HTSwap = 2, // other simple lf queue, suggested for low-contention case
+ ReadAsFilled = 3, // wait-free queue, suggested for high-contention or latency critical
+ TinyReadAsFilled = 4, // same as 3 but with lower overhead
+ //Inplace;
+ //Direct;
+ //Virtual
+ };
+ };
struct TScopeId : std::pair<ui64, ui64> {
using TBase = std::pair<ui64, ui64>;
@@ -61,9 +61,9 @@ namespace NActors {
return Sprintf("<%" PRIu64 ":%" PRIu64 ">", scopeId.first, scopeId.second);
}
-}
-
+}
+
template<>
struct hash<NActors::TScopeId> : hash<std::pair<ui64, ui64>> {};
-class TAffinity;
+class TAffinity;