[swift-lldb-dev] Issues with LLDB and modules
Dmitry Shevchenko
dmishe at google.com
Wed Sep 14 11:17:07 CDT 2016
Added a functional test project on a bug here
https://bugs.swift.org/browse/SR-2637
Hopefully this makes things a bit more clear.
On Mon, Sep 12, 2016 at 12:13 PM Dmitry Shevchenko <dmishe at google.com>
wrote:
> My apologies, the url should read http://bazel.io.
>
>
> On Fri, Sep 9, 2016 at 2:04 PM Dmitry Shevchenko <dmishe at google.com>
> wrote:
>
> Hello, I would like to ask a couple of implementation questions about LLDB
> and Swift.
>
> We are building swift in a custom build system (bazel.org) where we try
> to use Swift static libraries to compose our programs. In other words, we
> build multiple Swift targets into a pair of (.a, .switfmodule) and then
> link static libraries together into the final executable.
>
> It works pretty well, but there are issues when it comes to debugging.
> Ideally, we would like to debug with and without dSYM to speedup
> compilations.
>
> From reading SwiftASTContext.cpp, it looks like LLDB needs to load the
> corresponding .swiftmodule to work.
> It does so by looking at the AST tag in the symbol table of the
> executable.
> Is this correct, or is there another way that LLDB can find the module?
>
> Additionally, there can only be one such tag, since LLDB reads the first
> one it finds and stops.
> However, if a program is composed from multiple modules, it's not possible
> to tell the debugger to load them all. For example, if the app is written
> mostly in ObjC, but has multiple helper Swift libraries where each has its
> own module, and those modules do not import each other (so there's no clear
> way to say what is the "main" module), how would we tell LLDB to load all
> of them?
>
> Thank you!
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-lldb-dev/attachments/20160914/360386ed/attachment.html>
More information about the swift-lldb-dev
mailing list