Skip to content

Commit b704d19

Browse files
Zainullin DamirZainullin Damir
authored andcommitted
++
1 parent d2665db commit b704d19

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

include/ipfixprobe/outputPlugin/outputStorage/backoffScheme.hpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,10 @@ class BackoffScheme {
1919
bool backoff() noexcept
2020
{
2121
if (m_waitCounter < m_shortWaitThreshold) {
22-
for (volatile const auto _ : std::views::iota(0, 10'000)) {}
22+
for (const auto _ : std::views::iota(0, 10'000)) {
23+
asm volatile("pause" ::: "memory");
24+
}
25+
2326
} else if (m_waitCounter < m_longWaitThreshold) {
2427
std::this_thread::yield();
2528
} else {

0 commit comments

Comments
 (0)