[PATCH] D145377: [LLDB] Show sub type of signals for ELF core files

David Spickett via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 6 07:02:31 PST 2023


DavidSpickett planned changes to this revision.
DavidSpickett added inline comments.


================
Comment at: lldb/source/Plugins/Process/elf-core/ThreadElfCore.cpp:230
+
+  siginfo_t info;
+  info.si_signo = m_signo;
----------------
labath wrote:
> I think this won't work on Windows (no siginfo_t type, nor constants to decode it) -- and it may return garbage on other platforms if they use different constants.
> 
> If I may suggest an alternative implementation:
> - Implement ThreadElfCore::GetSiginfo to return (verbatim) copy of the siginfo_t from the core file
> - Implement a generic stop info description calculation (on platform class) function
> 
> Besides the stop description, this should also make the `thread siginfo` command work, and we can consider removing the lldb-server-based stop info computation logic, since this impl should cover both live and post-portem use cases.
Yes, of course.

I'll try what you suggested.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D145377



More information about the llvm-commits mailing list