[PATCH] D35394: [codeview] Remove TypeServerHandler and PDBTypeServerHandler

Reid Kleckner via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 14 17:29:21 PDT 2017


On Thu, Jul 13, 2017 at 10:43 PM, Zachary Turner via llvm-commits <
llvm-commits at lists.llvm.org> wrote:

> Is the existing model limiting somehow?


I don't think we need CVTypeVisitor to transparently look through type
server PDBs. Realistically, if a client is looking at more than one object
(llvm-readobj can do that too), it's not going to want to visit the same
type server more than once. LLD, for example, wants to load each new type
server PDB, merge its TPI and IPI streams, keep the index maps for both,
and unload the PDB and never load it again. PDBTypeServerHandler does this
now through some complicated logic to skip the type visiting if we've seen
this PDB before, but it seems better to push that logic back up to the
client.

The client should look at the type stream, check if it's a type server,
load up the type server and look at its TPI and IPI streams, and do what it
needs to. I have a patch to do that in LLD, and I'll try to polish it up to
get it out. Seems like it'll happen next week, though.

The current interface also prevents us from implementing the FIXME in
TypeStreamMerger to remove the usage of CVTypeVisitor. We don't need it, we
just have to iterate the array. When I implemented that, I realized I
regressed TypeServerHandling, and decided that removing it first was the
best way forward.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170714/682817ba/attachment.html>


More information about the llvm-commits mailing list