aboutsummaryrefslogtreecommitdiffstats
path: root/library
diff options
context:
space:
mode:
authorkhlebnikov <khlebnikov@yandex-team.ru>2022-02-10 16:50:08 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:50:08 +0300
commit6cffcf9a14a1dd07278bd534c7cca706ec2827b3 (patch)
tree48eb57e1d9fd00d624ca68bb3418c3c041d1b096 /library
parent1977f1c7bcb225f59f789f5f8735e03eb0c87e1c (diff)
downloadydb-6cffcf9a14a1dd07278bd534c7cca706ec2827b3.tar.gz
Restoring authorship annotation for <khlebnikov@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library')
-rw-r--r--library/cpp/coroutine/engine/cont_poller.cpp2
-rw-r--r--library/cpp/coroutine/engine/impl.cpp50
-rw-r--r--library/cpp/coroutine/engine/impl.h4
-rw-r--r--library/cpp/coroutine/engine/network.cpp2
-rw-r--r--library/python/ya.make2
5 files changed, 30 insertions, 30 deletions
diff --git a/library/cpp/coroutine/engine/cont_poller.cpp b/library/cpp/coroutine/engine/cont_poller.cpp
index 76593d4e9b..d0fea23e97 100644
--- a/library/cpp/coroutine/engine/cont_poller.cpp
+++ b/library/cpp/coroutine/engine/cont_poller.cpp
@@ -12,7 +12,7 @@ namespace NCoro {
}
cont->Executor()->ScheduleIoWait(event);
- cont->Switch();
+ cont->Switch();
if (cont->Cancelled()) {
return ECANCELED;
diff --git a/library/cpp/coroutine/engine/impl.cpp b/library/cpp/coroutine/engine/impl.cpp
index 7ae6f74051..a75923e606 100644
--- a/library/cpp/coroutine/engine/impl.cpp
+++ b/library/cpp/coroutine/engine/impl.cpp
@@ -51,7 +51,7 @@ bool TCont::Join(TCont* c, TInstant deadLine) noexcept {
c->Cancel();
do {
- Switch();
+ Switch();
} while (!ev.Empty());
}
@@ -68,10 +68,10 @@ int TCont::SleepD(TInstant deadline) noexcept {
return ExecuteEvent(&event);
}
-void TCont::Switch() noexcept {
- Executor()->RunScheduler();
-}
-
+void TCont::Switch() noexcept {
+ Executor()->RunScheduler();
+}
+
void TCont::Yield() noexcept {
if (SleepD(TInstant::Zero())) {
ReScheduleAndSwitch();
@@ -80,7 +80,7 @@ void TCont::Yield() noexcept {
void TCont::ReScheduleAndSwitch() noexcept {
ReSchedule();
- Switch();
+ Switch();
}
void TCont::Terminate() {
@@ -300,8 +300,8 @@ void TContExecutor::RunScheduler() noexcept {
try {
TContExecutor* const prev = ThisThreadExecutor();
ThisThreadExecutor() = this;
- TCont* caller = Current_;
- TExceptionSafeContext* context = caller ? caller->Trampoline_.Context() : &SchedContext_;
+ TCont* caller = Current_;
+ TExceptionSafeContext* context = caller ? caller->Trampoline_.Context() : &SchedContext_;
Y_DEFER {
ThisThreadExecutor() = prev;
};
@@ -309,17 +309,17 @@ void TContExecutor::RunScheduler() noexcept {
while (true) {
if (ScheduleCallback_ && Current_) {
ScheduleCallback_->OnUnschedule(*this);
- }
-
- WaitForIO();
- DeleteScheduled();
+ }
+
+ WaitForIO();
+ DeleteScheduled();
Ready_.Append(ReadyNext_);
if (Ready_.Empty()) {
- Current_ = nullptr;
- if (caller) {
- context->SwitchTo(&SchedContext_);
- }
+ Current_ = nullptr;
+ if (caller) {
+ context->SwitchTo(&SchedContext_);
+ }
break;
}
@@ -328,21 +328,21 @@ void TContExecutor::RunScheduler() noexcept {
if (ScheduleCallback_) {
ScheduleCallback_->OnSchedule(*this, *cont);
}
-
- Current_ = cont;
- cont->Scheduled_ = false;
- if (cont == caller) {
- break;
+
+ Current_ = cont;
+ cont->Scheduled_ = false;
+ if (cont == caller) {
+ break;
}
- context->SwitchTo(cont->Trampoline_.Context());
+ context->SwitchTo(cont->Trampoline_.Context());
if (Paused_) {
Paused_ = false;
Current_ = nullptr;
break;
}
- if (caller) {
- break;
- }
+ if (caller) {
+ break;
+ }
}
} catch (...) {
TBackTrace::FromCurrentException().PrintTo(Cerr);
diff --git a/library/cpp/coroutine/engine/impl.h b/library/cpp/coroutine/engine/impl.h
index 283a96ecf1..b07f8aafbf 100644
--- a/library/cpp/coroutine/engine/impl.h
+++ b/library/cpp/coroutine/engine/impl.h
@@ -99,8 +99,8 @@ public:
void ReSchedule() noexcept;
- void Switch() noexcept;
-
+ void Switch() noexcept;
+
void SwitchTo(TExceptionSafeContext* ctx) {
Trampoline_.SwitchTo(ctx);
}
diff --git a/library/cpp/coroutine/engine/network.cpp b/library/cpp/coroutine/engine/network.cpp
index 85b647d210..389c1ea298 100644
--- a/library/cpp/coroutine/engine/network.cpp
+++ b/library/cpp/coroutine/engine/network.cpp
@@ -51,7 +51,7 @@ namespace NCoro {
for (auto i : xrange(nfds)) {
cont->Executor()->ScheduleIoWait(events.Data() + i);
}
- cont->Switch();
+ cont->Switch();
if (cont->Cancelled()) {
return ECANCELED;
diff --git a/library/python/ya.make b/library/python/ya.make
index 2e1eb6e0e1..da8461683c 100644
--- a/library/python/ya.make
+++ b/library/python/ya.make
@@ -172,7 +172,7 @@ RECURSE(
solomon
spack
spyt
- ssh_client
+ ssh_client
ssh_sign
startrek_python_client
startrek_python_client/tests_int