summaryrefslogtreecommitdiffstats
path: root/util/system
Commit message (Collapse)AuthorAgeFilesLines
* Add _rtos_ define for ZEPHYR OSalexeykurzov2026-06-111-0/+3
| | | | commit_hash:2b003cee1e28b9216664d7069aa988a3b6d22eca
* Fix and enhance documentation comments in utilakhropov2026-06-051-1/+1
| | | | commit_hash:e121f7c48f58baff0e3690d60194525c2bfca083
* Fix Y_INITIALIZED for c++11vadim-xd2026-05-261-1/+2
| | | | commit_hash:55c566b519b626cfbe7b1aca8b15fed2993b9ed8
* Add Y_INITIALIZED (silencer for bugprone-use-after-move)vadim-xd2026-05-252-0/+34
| | | | commit_hash:e683c92bdbc059b1f08f9a6239e9348849914e84
* Introduce rtos based platforms defines for rtos platformsflarembo2026-04-181-0/+3
| | | | commit_hash:c975063237fb34a806e97350909d01bafb549bd9
* Move ClearEnv and IterateEnv to utilvadim-xd2026-04-053-4/+154
| | | | commit_hash:c42da6c8b3d8e0c63f1cf4457c245bbd97025cc2
* Remove duplicate error code in SetEnvvadim-xd2026-04-041-8/+1
| | | | commit_hash:c1b6cb467db42c6601a058c456ea118cafe571f2
* Attributes for coroutine return typesrraed2026-02-181-0/+46
| | | | commit_hash:14705eb46ebc07f5bdb3fd77df6d1cbe23720351
* Allwinner riscv64 toolchainxiwra2026-02-101-2/+2
| | | | | for allwinner c906 core on FreeRTOS platform commit_hash:94fe40602b06baea8e740d5e746980b1ca0dfc33
* TString::contains + tests, TStringBuf::contains tests, macro to enable EBOpechatnov2026-01-131-0/+13
| | | | commit_hash:221422cb861ba9db0ce508ea1114d3d44a5e37c7
* implement Y_NO_UNIQUE_ADDRESS using msvc::no_unique_address on windowsswarmer2026-01-121-0/+2
| | | | | MSVC and clang-cl implements the C++20 `[[no_unique_address]]` feature via a specific, non-standard attribute: `[[msvc::no_unique_address]]`. commit_hash:975835261fcf805bfe65b51fb43852f71ff67edd
* support the [[msvc::lifetimebound]] attributeswarmer2025-12-231-0/+2
| | | | commit_hash:24de2d823f1fc408bad6a4297e05810dc0d9624c
* Y_LIFETIME_BOUND documentation: add info about constructors and member ↵akhropov2025-12-221-2/+10
| | | | | | functions, add a link to CLang documentation. commit_hash:0d4feb10ff7975b833e61a93d6474b5f4e5ad94e
* Fix backtrace print in assertmag1str02025-10-141-2/+10
| | | | commit_hash:1bc8f82703745c9c7e06f2239735548ccd65997c
* Add a description explaining the rationale for the SIZEOF_ definitionsakhropov2025-10-081-0/+3
| | | | commit_hash:cd223dae0a4b3919808abb2d312f7e9936665424
* Use 'size' instead of 'ysize'.akhropov2025-10-071-1/+1
| | | | commit_hash:2992608384ed9b84c3f523bd2225a7ece2eeb9fc
* 16-bit platforms are not supported anymore.akhropov2025-10-061-1/+1
| | | | commit_hash:b336c8247b40aa5c43fcf82c154a7d4fdd08e9a5
* Correct "@throws" descriptionsakhropov2025-10-051-17/+18
| | | | commit_hash:5421bf011ff73356a4adf0b73eeff9ab7e6cb6db
* Fix return value description of GetEnvakhropov2025-10-051-1/+1
| | | | commit_hash:afbe8d7cf5642658803f7377b92c59b332ac2a46
* Mention all functionsakhropov2025-10-051-4/+4
| | | | commit_hash:87dfa7bd1279801c976ae3d9dc025eb0a4492ddf
* Fix in docs: UNUSED -> Y_UNUSEDakhropov2025-10-051-1/+1
| | | | commit_hash:82a20efd47b7df97b99e63d7fd9d79e7e93a7817
* Dont scan stacknechda2025-10-021-18/+0
| | | | | Remove stack scaning commit_hash:bf23dab42b2595d34beaba1f571e38763a222300
* Consistency: Make TFakeMutex move-only, explicitly declare TMutex as move-onlyakhropov2025-10-011-4/+2
| | | | commit_hash:11d3f50cee3ad3dd179d52280ddcb8ea225719ec
* Scan stack for args in darwin dbgnechda2025-09-261-27/+18
| | | | | Use va_args for extract stack-args commit_hash:db85572af5ed95ebea715b918986d2932e044733
* feat util: fix ThreadSanitizer reported data raceantoshkka2025-09-251-8/+13
| | | | | | | | | | | | | ``` WARNING: ThreadSanitizer: data race (pid=123179) Read of size 8 at 0x0000065aad98 by thread T14: #0 NSystemInfo::CachedNumberOfCpus() util/system/info.cpp:241:10 (taxi-uservices-userver-core-tests+0x4155bba) #1 engine::(anonymous namespace)::TaskProcessorThreadStartedHook() userver/core/src/engine/task/task_processor.cpp:100:15 (taxi-uservices-userver-core-tests+0x5306bc8) #2 engine::TaskProcessor::PrepareWorkerThread(unsigned long) userver/core/src/engine/task/task_processor.cpp:347:5 (taxi-uservices-userver-core-tests+0x5306bc8) ``` The change on a hot path is equivalent to the previously compiler generated x86 code (just a `load` instruction). On other platforms this could actually fix a data race. commit_hash:acb1fe1b8f3075cc27b18aab4f1bd0b88292c270
* Looking for the return address more persistentlynechda2025-09-241-3/+28
| | | | commit_hash:dafe73fcca759e0bf13ca38bdd4e320c8d85c7b6
* Use 'size_t' instead of 'yint' that is not known in utilakhropov2025-09-211-1/+1
| | | | commit_hash:c2fb7faa6674ce1b0d6a2d3cd2f0ef45a461ea0d
* fix bug in GetMemInfo on freebsdtldr2025-08-291-0/+4
| | | | commit_hash:47d410520be641eaa93ab44b92da8a095e72d301
* TTempFile should be move-only. Implement proper move semantics.akhropov2025-08-152-5/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | #### Реализация move-семантики для TTempFile и оптимизация передачи параметров 📝 - 🔄 **Сделал TTempFile move-only классом**: - Удалили копирующий конструктор и оператор присванивания - Добавили перемещающий конструктор и оператор с noexcept - Изменили хранение имени файла в TMaybe для безопасного перемещения - Добавили явное удаление временного файла в операторе перемещения - 🏗 **Оптимизировали передачу параметров в различных классах**: - Заменили передачу объектов по значению/константной ссылке на перемещение (std::move) - Основные изменения коснулись параметров среды (envParams) и аргументов процессов - ✨ **Улучшили обработку временных файлов**: - Убрали лишнее поле TTempFile из TSmallEnvParams - Вектор временных файлов теперь корректно хранится и обрабатывается через move-семантику - 📝 **Прочие улучшения**: - Исправлены контексты вызовов, где используется временная файловая система - Оптимизированы аргументы запуска процессов через std::move - Добавлено перемещение для аргументов стандартных потоков ввода-вывода --- **Оценить качество описания можно [здесь](https://nda.ya.ru/t/_MxIaV0Q7FnCMG** <a href="https://nda.ya.ru/t/qa0kX64r7DqvtN"><font size="2">Autodescription by Code Assistant</font></a> commit_hash:474bcbb9db8c7dc14d7aa204991ecdb4611e8e87
* TIntrusivePtr is not needed hereakhropov2025-08-112-3/+2
| | | | commit_hash:54b9e74039cd4f86cc8ab610b27005a5199af4f9
* Fix grammar, better wording and fix the version of the standardakhropov2025-08-111-2/+2
| | | | commit_hash:af06eeb383729e2b7ce1254d0a24f68b126591fe
* Fix typomikailbag2025-08-061-1/+1
| | | | | This fixes a typo caught by GameRoMan in https://github.com/yandex/perforator/pull/51 commit_hash:0fba8e46bed70f3afbd3f4a5a473be24c67e8f2f
* Y_HAS_CPP_ATTRIBUTE macroswarmer2025-08-051-43/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The new macro `Y_HAS_CPP_ATTRIBUTE` simplifies the check for C++ attribute support by handling nested `#if defined(__has_cpp_attribute)` checks. Before: ```cpp #if defined(__has_cpp_attribute) #if __has_cpp_attribute(attribute_name) // use #else // fallback #endif #else // fallback #endif ``` After: ```cpp #if Y_HAS_CPP_ATTRIBUTE(attribute_name) // use #else // fallback #endif ``` The new macro also allows checking C++ attributes when compiling C code without raising errors related to different tokenization rules in these languages. Of course, such a test always returns `0` when compiling source code in C. Also, rename `Y_HAVE_ATTRIBUTE` to `Y_HAS_ATTRIBUTE` for consistency. commit_hash:9c12fe5d0e6a570d7f11910704c0a9b05d100434
* Add Y_LIFETIME_CAPTURE_BY macromikhnenko2025-08-041-0/+18
| | | | commit_hash:3151ac4c7e3a3f787cd3936b642f516242f6d47c
* removed bad hardcoded constantsalmpac2025-08-041-1/+1
| | | | | changed bad code commit_hash:8053651f4c77622c3e55a5d169d7798e6a2c912d
* Make TShellCommand move-onlyakhropov2025-07-311-1/+1
| | | | commit_hash:5dc8e46003b70c95c2aaf80e8772e2de6f5d7e54
* compile util/system/defaults.c with a C compilerswarmer2025-07-313-0/+4
| | | | commit_hash:490ce843e0fa3ad97bc6865d6b8fb8a79678d469
* Revert commit rXXXXXX, Y_HAS_CPP_ATTRIBUTE macroswarmer2025-07-241-40/+29
| | | | | This implementation breaks GCC when compiling plain C code: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114007 commit_hash:963bf8890ce591a67c84996a2bd3411442cba58e
* Y_HAS_CPP_ATTRIBUTE macroswarmer2025-07-241-29/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | The new macro `Y_HAS_CPP_ATTRIBUTE` simplifies the check for C++ attribute support by handling nested `#if defined(__has_cpp_attribute)` checks. Before: ```cpp #if defined(__has_cpp_attribute) #if __has_cpp_attribute(attribute_name) // use #else // fallback #endif #else // fallback #endif ``` After: ```cpp #if Y_HAS_CPP_ATTRIBUTE(attribute_name) // use #else // fallback #endif ``` Also, rename `Y_HAVE_ATTRIBUTE` to `Y_HAS_ATTRIBUTE` for consistency. commit_hash:7994e363e1c7632e0451891862d406d19ca24863
* port util to freebsd, againpg2025-07-103-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ``` [pg@arc ~]$ ./util-ut <----- TSaveLoadTest [exec] TSaveLoadTest::TestSaveLoad... [good] TSaveLoadTest::TestSaveLoad [exec] TSaveLoadTest::TestSaveLoadEmptyStruct... [good] TSaveLoadTest::TestSaveLoadEmptyStruct [exec] TSaveLoadTest::TestNewStyle... [good] TSaveLoadTest::TestNewStyle [exec] TSaveLoadTest::TestNewNewStyle... [good] TSaveLoadTest::TestNewNewStyle [exec] TSaveLoadTest::TestList... [good] TSaveLoadTest::TestList [exec] TSaveLoadTest::TestTuple... [good] TSaveLoadTest::TestTuple [exec] TSaveLoadTest::TestVariant... [good] TSaveLoadTest::TestVariant [exec] TSaveLoadTest::TestOptional... [good] TSaveLoadTest::TestOptional [exec] TSaveLoadTest::TestInheritNonVirtualClass... [good] TSaveLoadTest::TestInheritNonVirtualClass [exec] TSaveLoadTest::TestInheritVirtualClass... [good] TSaveLoadTest::TestInheritVirtualClass -----> TSaveLoadTest -> ok: 10 [DONE] ok: 10 [pg@arc ~]$ uname -a FreeBSD arc.freebsd.devtools 14.2-RELEASE-p1 FreeBSD 14.2-RELEASE-p1 GENERIC amd64 [pg@arc ~]$ ``` commit_hash:229d8aa6c8ccce1376d152a833fe8bf7c5faa3bd
* Fix Y_NO_UNIQUE_ADDRESSludaludaed2025-07-091-2/+0
| | | | | Fix commit_hash:3ceec269bc1e9f318949493b79d1536db72d8a11
* Add Y_NO_UNIQUE_ADDRESSludaludaed2025-07-091-0/+30
| | | | | Add Y_NO_UNIQUE_ADDRESS commit_hash:ef4b0719294a6019a0b5802769cb2a15c2dd1b64
* Check that bytes consist of 8 bitsakhropov2025-06-171-0/+4
| | | | commit_hash:9eaf085276f1f93768b8b0e5ec92a53bf0db86a8
* adding the required includes, which were previously only available ↵swarmer2025-05-301-0/+1
| | | | | | transitively via the JOIN_SRCS macro commit_hash:9769490daa4d0e88eaf1b4147ccc961be6031d04
* Fix and improve documentation commentsakhropov2025-05-181-26/+26
| | | | commit_hash:f542118888ac27e5c731c6da1de70b30e2a082e9
* Remove SSE*_ENABLED defines and use predefined compiler macros insteadthegeorg2025-05-171-12/+12
| | | | commit_hash:38a7fed85214a0b939bdd770ba2244ff0f195f63
* util: Reduce the number of string allocation within the TypeName<T> functionswarmer2025-04-261-8/+12
| | | | | Don't copy a `const char *` into a temporary `TString`, only to convert it back to a `const char *`. commit_hash:f291a94106900ceae8ae830f20716cb35f8aab2d
* Intermediate changesrobot-piglet2025-04-111-1/+6
| | | | commit_hash:2b7b64700156a1d0ddea136ff1c94469867108fe
* Fix circular #include between util/system/file.h and util/system/flock.hthegeorg2025-04-011-1/+0
| | | | commit_hash:8174b7a8774277eccfa7768caeabde7f2c52b5bc
* spinlock: move unlock operations into the TSpinLockBase classswarmer2025-03-201-16/+8
| | | | commit_hash:97d3f3aa633aa9376f38930ef3b6bdb5e784bb97