[lld] r282945 - Change for LLVM upstream change r282944.
Rui Ueyama via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 30 13:53:45 PDT 2016
Author: ruiu
Date: Fri Sep 30 15:53:45 2016
New Revision: 282945
URL: http://llvm.org/viewvc/llvm-project?rev=282945&view=rev
Log:
Change for LLVM upstream change r282944.
Modified:
lld/trunk/COFF/PDB.cpp
lld/trunk/test/COFF/pdb.test
Modified: lld/trunk/COFF/PDB.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/COFF/PDB.cpp?rev=282945&r1=282944&r2=282945&view=diff
==============================================================================
--- lld/trunk/COFF/PDB.cpp (original)
+++ lld/trunk/COFF/PDB.cpp Fri Sep 30 15:53:45 2016
@@ -31,20 +31,9 @@ using namespace llvm::support::endian;
static ExitOnError ExitOnErr;
void coff::createPDB(StringRef Path) {
- // Create the superblock.
- msf::SuperBlock SB;
- memcpy(SB.MagicBytes, msf::Magic, sizeof(msf::Magic));
- SB.BlockSize = 4096;
- SB.FreeBlockMapBlock = 2;
- SB.NumBlocks = 10;
- SB.NumDirectoryBytes = 0;
- SB.Unknown1 = 0;
- SB.BlockMapAddr = 9;
-
BumpPtrAllocator Alloc;
pdb::PDBFileBuilder Builder(Alloc);
- ExitOnErr(Builder.initialize(SB));
- ExitOnErr(Builder.getMsfBuilder().setDirectoryBlocksHint({8}));
+ ExitOnErr(Builder.initialize(4096)); // 4096 is blocksize
ExitOnErr(Builder.getMsfBuilder().addStream(1, {4}));
ExitOnErr(Builder.getMsfBuilder().addStream(1, {5}));
Modified: lld/trunk/test/COFF/pdb.test
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/test/COFF/pdb.test?rev=282945&r1=282944&r2=282945&view=diff
==============================================================================
--- lld/trunk/test/COFF/pdb.test (original)
+++ lld/trunk/test/COFF/pdb.test Fri Sep 30 15:53:45 2016
@@ -6,15 +6,15 @@
# CHECK: MSF:
# CHECK-NEXT: SuperBlock:
# CHECK-NEXT: BlockSize: 4096
-# CHECK-NEXT: FreeBlockMap: 2
-# CHECK-NEXT: NumBlocks: 10
+# CHECK-NEXT: FreeBlockMap:
+# CHECK-NEXT: NumBlocks: 8
# CHECK-NEXT: NumDirectoryBytes: 28
# CHECK-NEXT: Unknown1: 0
-# CHECK-NEXT: BlockMapAddr: 9
+# CHECK-NEXT: BlockMapAddr: 3
# CHECK-NEXT: NumDirectoryBlocks: 1
-# CHECK-NEXT: DirectoryBlocks: [ 8 ]
+# CHECK-NEXT: DirectoryBlocks: [ 7 ]
# CHECK-NEXT: NumStreams: 3
-# CHECK-NEXT: FileSize: 40960
+# CHECK-NEXT: FileSize: 32768
# CHECK-NEXT: StreamSizes: [ 1, 48, 56 ]
# CHECK-NEXT: StreamMap:
# CHECK-NEXT: - Stream: [ 4 ]
More information about the llvm-commits
mailing list