diff options
author | Zachary Turner <zturner@google.com> | 2016-07-22 15:46:46 +0000 |
---|---|---|
committer | Zachary Turner <zturner@google.com> | 2016-07-22 15:46:46 +0000 |
commit | b383d628dffb30b4ac63c346ca4a21a980bdfdd0 (patch) | |
tree | fb740db73c91b7a8c070d1c861747f001b56a6fb /llvm/lib/DebugInfo/PDB/Raw/ModInfo.cpp | |
parent | d218c261247edb8b44132fcff3588a67494effb6 (diff) | |
download | llvm-b383d628dffb30b4ac63c346ca4a21a980bdfdd0.zip llvm-b383d628dffb30b4ac63c346ca4a21a980bdfdd0.tar.gz llvm-b383d628dffb30b4ac63c346ca4a21a980bdfdd0.tar.bz2 |
[pdb] Move file layout header structs to RawTypes.h
This facilitates code reuse between the builder classes and the
"frozen" read only versions of the classes used for parsing
existing PDB files.
llvm-svn: 276427
Diffstat (limited to 'llvm/lib/DebugInfo/PDB/Raw/ModInfo.cpp')
-rw-r--r-- | llvm/lib/DebugInfo/PDB/Raw/ModInfo.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/llvm/lib/DebugInfo/PDB/Raw/ModInfo.cpp b/llvm/lib/DebugInfo/PDB/Raw/ModInfo.cpp index 538fe22..9d0a0ae 100644 --- a/llvm/lib/DebugInfo/PDB/Raw/ModInfo.cpp +++ b/llvm/lib/DebugInfo/PDB/Raw/ModInfo.cpp @@ -39,10 +39,13 @@ Error ModInfo::initialize(codeview::StreamRef Stream, ModInfo &Info) { return Error::success(); } -bool ModInfo::hasECInfo() const { return (Layout->Flags & HasECFlagMask) != 0; } +bool ModInfo::hasECInfo() const { + return (Layout->Flags & ModInfoFlags::HasECFlagMask) != 0; +} uint16_t ModInfo::getTypeServerIndex() const { - return (Layout->Flags & TypeServerIndexMask) >> TypeServerIndexShift; + return (Layout->Flags & ModInfoFlags::TypeServerIndexMask) >> + ModInfoFlags::TypeServerIndexShift; } uint16_t ModInfo::getModuleStreamIndex() const { return Layout->ModDiStream; } @@ -72,7 +75,7 @@ StringRef ModInfo::getObjFileName() const { return ObjFileName; } uint32_t ModInfo::getRecordLength() const { uint32_t M = ModuleName.str().size() + 1; uint32_t O = ObjFileName.str().size() + 1; - uint32_t Size = sizeof(FileLayout) + M + O; + uint32_t Size = sizeof(ModuleInfoHeader) + M + O; Size = llvm::alignTo(Size, 4); return Size; } |