开启ms-vscode.cpptools(C/C++ for Visual Studio Code)之后,后台的cpptools疯狂占内存,10G、20G、60G没有上限,直到系统卡到连鼠标都动不了。
但是不开启这个插件就会在“大纲”不能显示函数列表。
网上有很多教程,但是能找到的、经我试了都不行。
以下经试验没效果,(搜索配置项并修改):
x Follow Symlinks 去掉勾选
x git.enabled: false
x git.autorefresh: false
x workspaceParsingPriority: low
x files.watcherExclude: !**/*.{cpp,h}
x 使用cgroup限制进程内存
以下试了有效,(搜索配置项并修改)
@ext:ms-vscode.cpptools memory
各项设定 1024
@ext:ms-vscode.cpptools cpu
检查各项
还做了以下配置,不确定是否生效:
C_Cpp › Vcpkg: Enabled, 去掉勾选