[PATCH] D109923: [Support] Convert BinaryStream class zoo to 64-bit offsets

Nico Weber via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 16 13:52:42 PDT 2021


thakis created this revision.
thakis added reviewers: rnk, hans.
Herald added subscribers: dexonsmith, hiraditya.
thakis requested review of this revision.
Herald added a project: LLVM.

Most PDB fields are 32-bit, but in terms of MSF blocks, which are 4 kiB by default.

So PDB files can be a bit larger than 4 GiB, and much larger if you create them with a block size > 4 kiB.

This is a first (necessary, but by far not not sufficient) step towards supporting such PDB files.
Now we don't truncate in-memory file offsets (which are in terms of bytes, not in terms of blocks).


https://reviews.llvm.org/D109923

Files:
  llvm/include/llvm/DebugInfo/MSF/MappedBlockStream.h
  llvm/include/llvm/Support/BinaryByteStream.h
  llvm/include/llvm/Support/BinaryItemStream.h
  llvm/include/llvm/Support/BinaryStream.h
  llvm/include/llvm/Support/BinaryStreamReader.h
  llvm/include/llvm/Support/BinaryStreamRef.h
  llvm/include/llvm/Support/BinaryStreamWriter.h
  llvm/lib/DebugInfo/MSF/MappedBlockStream.cpp
  llvm/lib/DebugInfo/PDB/Native/NativeEnumInjectedSources.cpp
  llvm/lib/Support/BinaryStreamReader.cpp
  llvm/lib/Support/BinaryStreamRef.cpp
  llvm/lib/Support/BinaryStreamWriter.cpp
  llvm/tools/llvm-pdbutil/LinePrinter.cpp
  llvm/tools/llvm-pdbutil/LinePrinter.h
  llvm/unittests/DebugInfo/MSF/MappedBlockStreamTest.cpp
  llvm/unittests/Support/BinaryStreamTest.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D109923.373060.patch
Type: text/x-patch
Size: 51685 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210916/b376c237/attachment.bin>


More information about the llvm-commits mailing list