ccls icon indicating copy to clipboard operation
ccls copied to clipboard

High CPU and RAM usage when navigating linux kernel sources

Open yangxingwu opened this issue 3 years ago • 1 comments

Observed behavior

ccls uses a extremely high CPU and RAM (nearly about 2GB) and killed by out-of-memory.

Expected behavior

limit the mount of available memory.

Steps to reproduce

  1. git clone --depth 1 git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
  2. cd linux
  3. open a file

System information

  • ccls version: installed by nvim-lsp-installer
  • clang version 13.0.0 (https://github.com/llvm/llvm-project/ 24c8eaec9467b2aaf70b0db33a4e4dd415139a50)
  • OS: Ubuntu 22.04 LTS
  • Editor: neovim
  • Language client (and version): neovim v0.7.0

yangxingwu avatar Jun 15 '22 09:06 yangxingwu

I have noticed the same while loading and navigating the llvm project. It looks like ccls executes multiple threads and all of the try to access/write to /tmp/ccls.logs, which spice the CPU percentage to 100%.

stelro avatar Jun 25 '22 11:06 stelro