[PATCH] D94621: [clang-tidy] add concurrency-async-fs

Vasily Kulikov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jan 14 04:55:19 PST 2021


segoon added a comment.

njames93, the purpose is to flag it indeed. This approach was found valueable in Yandex.Taxi, as it is very easy to forget that you're in a coroutine and may not use blocking API. The bug does affect performance (e.g. all coroutine threads wait for fs), it cannot be found by functional tests (as it is not a functional invariant violation) and may be rather tricky to debug (as the performance harm depends on many things like IO limits, page cache size, current load, etc.). It can be caught during code review, but it suffers from human errors. Rather than playing catch-me-if-you-can games, the check can be automated. As C/C++ standard libraries contain quite many blocking functions and C++20 gains official coroutine support, I find it valuable for the C++ community to have an already compiled list of such blocking functions and the check that uses it.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D94621/new/

https://reviews.llvm.org/D94621



More information about the cfe-commits mailing list