[clang] [docs][coroutines] Revamp "Debugging C++ coroutines" (PR #142651)
Jan Finis via cfe-commits
cfe-commits at lists.llvm.org
Tue Jun 3 11:58:43 PDT 2025
================
@@ -8,470 +8,966 @@ Debugging C++ Coroutines
Introduction
============
-For performance and other architectural reasons, the C++ Coroutines feature in
-the Clang compiler is implemented in two parts of the compiler. Semantic
-analysis is performed in Clang, and Coroutine construction and optimization
-takes place in the LLVM middle-end.
+Coroutines in C++ were introduced in C++20, and their user experience for
+debugging them can still be challenging. This document guides you how to most
+efficiently debug coroutines and how to navigate existing shortcomings in
+debuggers and compilers.
+
+Coroutines are generally used either as generators or for asynchronous
+programming. In this document, we will discuss both use cases. Even if you are
+using coroutines for asynchronous programming, you should still read the
+generators section, as it will introduce foundational debugging techniques also
+applicable to the debugging of asynchronous programming.
+
+Both compilers (clang, gcc, ...) and debuggers (lldb, gdb, ...) are
+still improving their support for coroutines. As such, we recommend to use the
----------------
JFinis wrote:
```suggestion
still improving their support for coroutines. As such, we recommend using the
```
https://github.com/llvm/llvm-project/pull/142651
More information about the cfe-commits
mailing list