[all-commits] [llvm/llvm-project] 4a46ea: [lldb] Show coro_frame in `std::coroutine_handle` ...

Adrian Vogelsgesang via All-commits all-commits at lists.llvm.org
Wed Jun 11 05:10:16 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 4a46ead8fb5b57e69bcd1c72ebd7dd8eaf09fa9c
      https://github.com/llvm/llvm-project/commit/4a46ead8fb5b57e69bcd1c72ebd7dd8eaf09fa9c
  Author: Adrian Vogelsgesang <avogelsgesang at salesforce.com>
  Date:   2025-06-11 (Wed, 11 Jun 2025)

  Changed paths:
    M lldb/include/lldb/DataFormatters/TypeSynthetic.h
    M lldb/source/DataFormatters/TypeSynthetic.cpp
    M lldb/source/Plugins/Language/CPlusPlus/Coroutines.cpp
    M lldb/source/Plugins/Language/CPlusPlus/Coroutines.h
    M lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/coroutine_handle/TestCoroutineHandle.py

  Log Message:
  -----------
  [lldb] Show coro_frame in `std::coroutine_handle` pretty printer (#141516)

This commit adjusts the pretty printer for `std::coroutine_handle` based
on recent personal experiences with debugging C++20 coroutines:

1. It adds the `coro_frame` member. This member exposes the complete
   coroutine frame contents, including the suspension point id and all
   internal variables which the compiler decided to persist into the
   coroutine frame. While this data is highly compiler-specific, inspecting
   it can help identify the internal state of suspended coroutines.
2. It includes the `promise` and `coro_frame` members, even if
   devirtualization failed and we could not infer the promise type / the
   coro_frame type. Having them available as `void*` pointers can still be
   useful to identify, e.g., which two coroutine handles have the same
   frame / promise pointers.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list