diff options
| author | Zachary Turner <zturner@google.com> | 2018-04-16 18:17:13 +0000 |
|---|---|---|
| committer | Zachary Turner <zturner@google.com> | 2018-04-16 18:17:13 +0000 |
| commit | e3fe6698559f80a79286980e6b2a4c291c5e7585 (patch) | |
| tree | 80781bd61dd85b41bf11063fa02a0e260af27f2b /llvm/lib | |
| parent | 60c7e0d58762b69591e52c4aaebda592712cb000 (diff) | |
| download | bcm5719-llvm-e3fe6698559f80a79286980e6b2a4c291c5e7585.tar.gz bcm5719-llvm-e3fe6698559f80a79286980e6b2a4c291c5e7585.zip | |
Resubmit "Fix some incorrect fields in our generated PDBs."
This fixes the failing tests. They simply hadn't been updated
to match the new output resulting from this patch.
llvm-svn: 330145
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/DebugInfo/PDB/Native/DbiStreamBuilder.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/llvm/lib/DebugInfo/PDB/Native/DbiStreamBuilder.cpp b/llvm/lib/DebugInfo/PDB/Native/DbiStreamBuilder.cpp index f17e0815ccf..52886d566e7 100644 --- a/llvm/lib/DebugInfo/PDB/Native/DbiStreamBuilder.cpp +++ b/llvm/lib/DebugInfo/PDB/Native/DbiStreamBuilder.cpp @@ -37,6 +37,14 @@ void DbiStreamBuilder::setAge(uint32_t A) { Age = A; } void DbiStreamBuilder::setBuildNumber(uint16_t B) { BuildNumber = B; } +void DbiStreamBuilder::setBuildNumber(uint8_t Major, uint8_t Minor) { + BuildNumber = (uint16_t(Major) << DbiBuildNo::BuildMajorShift) & + DbiBuildNo::BuildMajorMask; + BuildNumber |= (uint16_t(Minor) << DbiBuildNo::BuildMinorShift) & + DbiBuildNo::BuildMinorMask; + BuildNumber |= DbiBuildNo::NewVersionFormatMask; +} + void DbiStreamBuilder::setPdbDllVersion(uint16_t V) { PdbDllVersion = V; } void DbiStreamBuilder::setPdbDllRbld(uint16_t R) { PdbDllRbld = R; } @@ -251,7 +259,7 @@ Error DbiStreamBuilder::finalize() { H->TypeServerSize = 0; H->SymRecordStreamIndex = SymRecordStreamIndex; H->PublicSymbolStreamIndex = PublicsStreamIndex; - H->MFCTypeServerIndex = kInvalidStreamIndex; + H->MFCTypeServerIndex = 0; // Not sure what this is, but link.exe writes 0. H->GlobalSymbolStreamIndex = GlobalsStreamIndex; Header = H; |

