[Lldb-commits] [PATCH] D56595: SymbolFileBreakpad: Add line table support

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Jan 11 05:08:33 PST 2019

labath created this revision.
labath added reviewers: clayborg, zturner, lemo, markmentovai.

This patch teaches SymbolFileBreakpad to parse the line information in
breakpad files and present it to lldb.

The trickiest question here was what kind of "compile units" to present
to lldb, as there really isn't enough information in breakpad files to
correctly reconstruct those.

The two options I considered were:

- have the entire file be one compile unit
- have one compile unit for each FILE record

The drawbacks of the first approach are that the compile unit created
this way will be huge, and there isn't a good way to name it (I decided
to name it after the object file).

The second approach will create mostly correct compile units for cpp
files, but it will still be wrong for headers. However, the biggest
drawback here seemed to be the fact that this can cause a compile unit
to change mid-function (for example when a function from another file is
inlined or another file is #included into a function). While I don't
know of any specific thing that would break in this case, it does sound
like a thing that we should avoid.

So, in the end, I chose the first approach, because it results in
simpler code, and having one compile unit doesn't seem so bad,
particularly as the second approach wouldn't result in correct compile
units either.



-------------- next part --------------
A non-text attachment was scrubbed...
Name: D56595.181252.patch
Type: text/x-patch
Size: 11519 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20190111/8611b680/attachment-0001.bin>

More information about the lldb-commits mailing list