Skip to content

VS Code hangs with the renderer at 100% CPU when indexing large new project #58

Open

Description

@umanwizard

The reason seems to be that since the default config places the cquery cache in the project directory, VSCode tries to watch all the files in the cache as cquery adds them. Changing the cache directory to be outside of the workspace fixes the issue.

Activity

  1. bdeeming commented on Nov 18, 2018

    @bdeeming

    I have observed this too (on Linux). The help text in the settings is misleading:

    Cquery: Cache Directory
    Absolute path to the directory that the cached index will be stored in. Try to have this directory on an SSD. If not explicitly set, this will be automatically populated with the extension cache directory.

    If left unconfigured it lands in the .vscode/cquery_cached_index directory within the workspace, not the extension cache directory (which would be good).

    Cache directories are project-wide, so this should be configured in the workspace settings so multiple indexes do not clash.

    Not directly related to the issue at hand, but this appears to be out of date also. My cache directory appears to automatically put subdirectories within my cache directory that are derived from the workspace path, so there are no clashes when configured in the user settings (a good thing, but this statement should probably be removed/updated).

  2. changed the title [-]VS Code hangs with the renderer at 100% CPU when indexing large new project on macOS[/-] [+]VS Code hangs with the renderer at 100% CPU when indexing large new project[/+] on Nov 18, 2018
  3. umanwizard commented on Nov 18, 2018

    @umanwizard
    Author

    I have taken "on macOS" out of the title since other people are reproducing this on Linux.

  4. bdeeming commented on Nov 21, 2018

    @bdeeming

    One more observation: It appears that when leaving the setting blank in User Settings, it automatically populates "cquery.cacheDirectory": "${workspaceFolder}/.vscode/cquery_cached_index/" into the Workspace Settings file. You can delete the added line, then save it, and then it puts it straight back again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions