[PATCH] D47935: [clangd] Boost completion score according to file proximity.

Eric Liu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Jun 8 07:45:00 PDT 2018


ioeric added a comment.

Here are some numbers by completing "clang::^" 40 times (with result limit 1000 instead of 100).

Timing in `CodeCompleteFlow::measureResults`

  Before: Avg: 1811 us Med: 1792 us 
  After: Avg: 2714 us Med: 2689 us

As a reference, a full CodeCompleteFlow (with 1000 candidates) takes ~70 ms (using LLVM's yaml index).

So, with the current limit of 100 results, the increase for measureResults should be roughly 0.18ms -> 0.27ms, which I think is reasonable.


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D47935





More information about the cfe-commits mailing list