ioeric added inline comments.
================ Comment at: clangd/index/Merge.cpp:69 + else + B.insert(mergeSymbol(*Sym, S, &Scratch)); + }); ---------------- sammccall wrote: > This could also just be callback(mergeSymbol(...)), if we keep track of the > IDs we've emitted. > This way the slab would only have symbols from the dynamic index. > > This could be just: > - before the static lookup, make a copy `RemainingIDs = Req.IDs` > - in the static callback, remove the id from RemainingIDs > - after the static lookup, loop through RemainingIDs, look up symbol in > dynamic slab, emit > > This avoids: > - copying the static index results (which tend to be more numerous) > - build() on the slab builder, which isn't cheap Good idea. Thanks! Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D44305 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits