ArcsinX wrote:

The idea of distributing a pre-build index among users is really cool and looks 
very promising to me.

1) I see that in your patch we don't map paths inside compile command of 
shards. I think this can be a problem, because we need to reindex a source file 
if it's compile command changes. I.e. compile_commands.json on local user 
environment already has `local` paths, but pre-build index has `remote` paths 
in compilate commands inside the index and we don't apply path mappings to 
these paths.

2) We perform path mappings at every index loading and keep the index data with 
`remote` paths, but seems a user needs an index data with his local paths 
(without any plans to send modified index back). Thus, maybe instead of adding 
such path-mapping functionality into clangd tool, we need a tool, which can 
take pre-build index as input and provide index with local paths as output (and 
this output can be used by clangd)? After 
https://github.com/llvm/llvm-project/pull/175209 is merged, we can create 
clangd background index without starting clangd. So, after that we can add 
path-mapping ability into a tool which can read files in RIFF format (maybe 
dexp?). @justincady WDYT?

https://github.com/llvm/llvm-project/pull/180285
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to