[PATCH] D32506: Rename some PDB classes

Zachary Turner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 25 14:45:55 PDT 2017


zturner created this revision.
Herald added subscribers: aprantl, mgorny.

There is no functional change here, just renames.

In the DBI stream, there is an embedded array of structs (1) that list the modules contributing to the PDB, with a reference to a separate stream in the PDB (2) for more details.  Each of those streams mentioned in (2) is further subdivided into smaller substreams (3) that contain various types of data.

(1) is called `ModInfo`
(2) is called `ModStream`
(3) is called `ModuleSubstream`

While seemingly intuitive, these have been a source of endless confusion for me.  Is the `ModuleSubstream` in the DBI stream or the `ModStream`?  Does the `ModInfo` contain the symbol data or is that somewhere else?

I decided to rename these.  The new names are longer, but hopefully more descriptive.  The mapping from old to new is:

`ModInfo` -> `DbiModuleDescriptor`   (by prefixing with `Dbi`, we re-iterate that it's part of the DBI stream, and by including the word "descriptor", we emphasize that there's only minimal metadata here)

`ModStream` -> `ModuleDebugStream` (by including the word debug, we reinforce that this is where all the debug info details are).

`ModuleSubstream` -> `ModuleDebugFragment` (by saying "fragment" instead of "substream", we emphasize that a `ModuleDebugStream` is built up from a collection of many fragments, and there is nothing else of importance in one of these streams besides the list of fragments.)


https://reviews.llvm.org/D32506

Files:
  llvm/include/llvm/DebugInfo/CodeView/CodeView.h
  llvm/include/llvm/DebugInfo/CodeView/ModuleDebugFragment.h
  llvm/include/llvm/DebugInfo/CodeView/ModuleDebugFragmentVisitor.h
  llvm/include/llvm/DebugInfo/CodeView/ModuleSubstream.h
  llvm/include/llvm/DebugInfo/CodeView/ModuleSubstreamVisitor.h
  llvm/include/llvm/DebugInfo/PDB/Native/DbiModuleDescriptor.h
  llvm/include/llvm/DebugInfo/PDB/Native/DbiModuleDescriptorBuilder.h
  llvm/include/llvm/DebugInfo/PDB/Native/DbiStream.h
  llvm/include/llvm/DebugInfo/PDB/Native/DbiStreamBuilder.h
  llvm/include/llvm/DebugInfo/PDB/Native/ModInfo.h
  llvm/include/llvm/DebugInfo/PDB/Native/ModInfoBuilder.h
  llvm/include/llvm/DebugInfo/PDB/Native/ModStream.h
  llvm/include/llvm/DebugInfo/PDB/Native/ModuleDebugStream.h
  llvm/include/llvm/DebugInfo/PDB/Native/NativeCompilandSymbol.h
  llvm/include/llvm/DebugInfo/PDB/Native/NativeEnumModules.h
  llvm/include/llvm/DebugInfo/PDB/Native/RawTypes.h
  llvm/include/llvm/DebugInfo/Symbolize/Symbolize.h
  llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
  llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.h
  llvm/lib/DebugInfo/CodeView/CMakeLists.txt
  llvm/lib/DebugInfo/CodeView/EnumTables.cpp
  llvm/lib/DebugInfo/CodeView/ModuleDebugFragment.cpp
  llvm/lib/DebugInfo/CodeView/ModuleDebugFragmentVisitor.cpp
  llvm/lib/DebugInfo/CodeView/ModuleSubstream.cpp
  llvm/lib/DebugInfo/CodeView/ModuleSubstreamVisitor.cpp
  llvm/lib/DebugInfo/PDB/CMakeLists.txt
  llvm/lib/DebugInfo/PDB/Native/DbiModuleDescriptor.cpp
  llvm/lib/DebugInfo/PDB/Native/DbiModuleDescriptorBuilder.cpp
  llvm/lib/DebugInfo/PDB/Native/DbiStream.cpp
  llvm/lib/DebugInfo/PDB/Native/DbiStreamBuilder.cpp
  llvm/lib/DebugInfo/PDB/Native/ModInfo.cpp
  llvm/lib/DebugInfo/PDB/Native/ModInfoBuilder.cpp
  llvm/lib/DebugInfo/PDB/Native/ModStream.cpp
  llvm/lib/DebugInfo/PDB/Native/ModuleDebugStream.cpp
  llvm/lib/DebugInfo/Symbolize/Symbolize.cpp
  llvm/lib/MC/MCCodeView.cpp
  llvm/tools/llvm-pdbdump/LLVMOutputStyle.cpp
  llvm/tools/llvm-pdbdump/StreamUtil.cpp
  llvm/tools/llvm-pdbdump/YAMLOutputStyle.cpp
  llvm/tools/llvm-pdbdump/YAMLOutputStyle.h
  llvm/tools/llvm-pdbdump/fuzzer/llvm-pdbdump-fuzzer.cpp
  llvm/tools/llvm-pdbdump/llvm-pdbdump.cpp
  llvm/tools/llvm-readobj/COFFDumper.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D32506.96636.patch
Type: text/x-patch
Size: 98051 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170425/305985fb/attachment.bin>


More information about the llvm-commits mailing list