[PATCH] D31636: [PDB] Emit index/offset pairs for TPI and IPI streams

Reid Kleckner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 3 18:34:28 PDT 2017


rnk created this revision.

This lets PDB readers lookup type record data by type index in O(log n)
time. It also enables makes `cvdump -t` work on PDBs produced by LLD.
cvdump will not dump a PDB that doesn't have an index-to-offset table.

The table is sorted by type index, and has an entry every 8KB. Looking
up a type record by index is a binary search of this table, followed by
a scan of at most 8KB.


https://reviews.llvm.org/D31636

Files:
  lld/test/COFF/pdb.test
  llvm/include/llvm/DebugInfo/PDB/Native/TpiStreamBuilder.h
  llvm/lib/DebugInfo/PDB/Native/TpiStream.cpp
  llvm/lib/DebugInfo/PDB/Native/TpiStreamBuilder.cpp
  llvm/test/DebugInfo/PDB/pdb-yaml-types.test

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D31636.93982.patch
Type: text/x-patch
Size: 18564 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170404/57714ffe/attachment.bin>


More information about the llvm-commits mailing list