[all-commits] [llvm/llvm-project] 60b90b: [lldb][DynamicLoader] Fix lldb unable to stop at _...

Zequan Wu via All-commits all-commits at lists.llvm.org
Wed Apr 17 13:09:59 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 60b90b523323f8196a9e4a68b1f33358624c09eb
      https://github.com/llvm/llvm-project/commit/60b90b523323f8196a9e4a68b1f33358624c09eb
  Author: Zequan Wu <zequanwu at google.com>
  Date:   2024-04-17 (Wed, 17 Apr 2024)

  Changed paths:
    M lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp
    M lldb/test/API/functionalities/breakpoint/breakpoint_command/TestBreakpointCommand.py

  Log Message:
  -----------
  [lldb][DynamicLoader] Fix lldb unable to stop at _dl_debug_state if user set it before the process launched. (#88792)

If user sets a breakpoint at `_dl_debug_state` before the process
launched, the breakpoint is not resolved yet. When lldb loads dynamic
loader module, it's created with `Target::GetOrCreateModule` which
notifies any pending breakpoint to resolve. However, the module's
sections are not loaded at this time. They are loaded after returned
from
[Target::GetOrCreateModule](https://github.com/llvm/llvm-project/blob/0287a5cc4e2a5ded1ae2e4079f91052e6a6b8d9b/lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp#L574-L577).
This change fixes it by manually resolving breakpoints after creating
dynamic loader module.



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