[PATCH] D41734: [DebugInfo][PDB] Fix too many FPM blocks being written in some cases
Colden Cullen via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 4 13:55:21 PST 2018
colden added a comment.
Yeah, that's the callstack I'm seeing. And I'm all for as many asserts as we can add to guarantee safety.
Theoretically it should only add FPM blocks to the end when we've spilled over from the previous FPM's range, right? So unless we remove blocks from the end, there should never just be an FPM at the end.
Maybe I'm misunderstanding, but are new blocks only ever added through getFpmStreamLayout or MSFBuilder::allocateBlocks? If that's the case, theoretically as long as those handle adding 2 FPMs correctly on overflow, we should be in good shape. Or do you think we got an FPM at the end from MSVC?
If it's an MSVC thing, we should be able to fix it by just lopping the last FPMs off at load time. If they're the last blocks in a file, they can't possibly reference anything, and there's not much point in keeping them in memory.
Repository:
rL LLVM
https://reviews.llvm.org/D41734
More information about the llvm-commits
mailing list