diff options
| author | robot-piglet <[email protected]> | 2024-10-31 20:00:10 +0300 |
|---|---|---|
| committer | robot-piglet <[email protected]> | 2024-10-31 20:12:12 +0300 |
| commit | 50ec97d0fe87ff4cec74a265341391c465a5db9d (patch) | |
| tree | 7136549e5a762cb7334655e1708f07438b456f1d /library/cpp | |
| parent | 6c9f2f9532a9812c29ae9f3ed08ad266b93993c0 (diff) | |
Intermediate changes
commit_hash:6c7ea26efb0f57227eee0726fe43fe72e05f8f33
Diffstat (limited to 'library/cpp')
| -rw-r--r-- | library/cpp/yt/stockpile/stockpile_linux.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/library/cpp/yt/stockpile/stockpile_linux.cpp b/library/cpp/yt/stockpile/stockpile_linux.cpp index 0cf5ea0a8bb..dafb4e9e8c8 100644 --- a/library/cpp/yt/stockpile/stockpile_linux.cpp +++ b/library/cpp/yt/stockpile/stockpile_linux.cpp @@ -24,7 +24,7 @@ namespace { void RunWithFixedBreaks(i64 bufferSize, TDuration period) { - auto returnCode = ::madvise(nullptr, bufferSize, MADV_STOCKPILE); + auto returnCode = -::madvise(nullptr, bufferSize, MADV_STOCKPILE); YT_LOG_DEBUG_IF(returnCode, "System call \"madvise\" returned %v", strerror(returnCode)); Sleep(period); } @@ -32,7 +32,7 @@ void RunWithFixedBreaks(i64 bufferSize, TDuration period) void RunWithCappedLoad(i64 bufferSize, TDuration period) { auto started = GetApproximateCpuInstant(); - auto returnCode = ::madvise(nullptr, bufferSize, MADV_STOCKPILE); + auto returnCode = -::madvise(nullptr, bufferSize, MADV_STOCKPILE); YT_LOG_DEBUG_IF(returnCode, "System call \"madvise\" returned %v", strerror(returnCode)); auto duration = CpuDurationToDuration(GetApproximateCpuInstant() - started); @@ -47,7 +47,7 @@ std::pair<i64, TDuration> RunWithBackoffs( const TStockpileOptions& options, i64 pageSize) { - int returnCode = ::madvise(nullptr, adjustedBufferSize, MADV_STOCKPILE); + int returnCode = -::madvise(nullptr, adjustedBufferSize, MADV_STOCKPILE); YT_LOG_DEBUG_IF(returnCode, "System call \"madvise\" returned %v", strerror(returnCode)); switch(returnCode) { |
