[Lldb-commits] [PATCH] D17363: Add SymbolFilePDB with basic support for line tables.

Greg Clayton via lldb-commits lldb-commits at lists.llvm.org
Wed Mar 2 13:01:05 PST 2016


clayborg requested changes to this revision.
clayborg added a comment.
This revision now requires changes to proceed.

As long as you don't mind your last line entry potentially being really large because it isn't terminated?

  (lldb) target create D:\src\llvm\tools\lldb\unittests\SymbolFile\PDB\Inputs\test-pdb.exe
  Current executable set to 'D:\src\llvm\tools\lldb\unittests\SymbolFile\PDB\Inputs\test-pdb.exe' (i686).
  (lldb) target modules dump line-table test-pdb.cpp
  Line table for d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb.cpp in `test-pdb.exe
  0x00401040: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb.cpp:7
  0x00401043: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb.cpp:8
  0x00401045: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb.cpp:9
  0x00401050: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb.cpp:13
  0x00401054: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb.cpp:14
  0x00401070: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb.cpp:15
  0x00401080: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb-nested.h:5
  0x00401083: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb-nested.h:6
  0x00401089: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb-nested.h:7
  0x00401090: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb.h:9
  0x00401093: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb.h:10
  0x004010a2: d:\src\llvm\tools\lldb\unittests\symbolfile\pdb\inputs\test-pdb.h:11

How large is the last line entry going to be? It isn't capped at all. You at least need a termination entry for the last entry before this can go in. You probably just need to find the function for file address 0x004010a2 and get the end address of the function and use that to terminate.


http://reviews.llvm.org/D17363





More information about the lldb-commits mailing list