[PATCH] D113995: [clangd] Dex Trigrams: Improve query trigram generation
Sam McCall via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Dec 7 05:17:01 PST 2021
sammccall accepted this revision.
sammccall added a comment.
This revision is now accepted and ready to land.
Sorry about the delay!
================
Comment at: clang-tools-extra/clangd/index/dex/Trigram.cpp:46
// not available then 0 is stored.
- std::vector<std::array<unsigned, 3>> Next(LowercaseIdentifier.size());
+ llvm::SmallVector<std::array<unsigned, 2>> Next(LowercaseIdentifier.size());
unsigned NextTail = 0, NextHead = 0;
----------------
the default size of this vector is 6 - if we care about the optimization we probably want to double it or so?
(Roles above is fine, it's 40)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D113995/new/
https://reviews.llvm.org/D113995
More information about the cfe-commits
mailing list