Hi Serhei,

On Tue, Oct 15, 2024 at 11:29 AM Serhei Makarov <ser...@serhei.io> wrote:
> 
> Since we obtain diagnostics about unwind method, another logical place
> to show them is in eu-stack.
> 
> This requires an additional pseudo-unwind type DWFL_UNWOUND_INLINE to
> clarify what happens with entries for inlined functions (which
> eu-stacktrace does not display) based on the same Dwfl_Frame.
> 
> * libdwfl/libdwfl.h (Dwfl_Unwound_Source): Add DWFL_UNWOUND_INLINE.
> * libdwfl/dwfl_frame.c (dwfl_unwound_source_str):
>   Handle DWFL_UNWOUND_INLINE.
> * src/stack.c (show_unwound_source): New global variable.
>   (struct frame): Add unwound_source field.
>   (frame_callback): Copy over unwound_source from Dwfl_Frame.
>   (print_frame): Take unwound_source argument and print it.
>   (print_inline_frames): Take unwound_source argument and pass it on,
>   except for subsequent frames where DWFL_UNWOUND_INLINE is assumed.
>   (print_frames): Take unwound_source field from struct frame and pass
>   it on.
>   (parse_opt): Add --cfi-type,-c option to set show_unwound_source.
>   (main): Ditto.
> * tests/run-stack-i-test.sh: Add testcase for --cfi-type.
> 
> Signed-off-by: Serhei Makarov <ser...@serhei.io>

This patch LGTM.

Aaron

Reply via email to