microsoft / microsoft/vscode-cpptools

rapid "IntelliSense process crash detected" for multiple crash types like request completion, update intellisence, etc.

Open
#11,753 16 comments 0 reactions 1 assignee View on GitHub

@sean-mcmanus is already working on this.

Since Dec 5, 2023.

Language Service reliability
Dominant language
TypeScript
Stars
6.2k
Forks
1.7k
Avg merge
14h 46m
Merged PRs (30d)
61

Description

Environment
  • Microsoft Windows [Version 10.0.22631.2715]
  • VS Code Version: Version: 1.84.2 (system setup)
  • C/C++ Extension Version: v1.18.5
Summary

The last 2-3 days, the intellisense features are severely degraded. I suspect my code (or that of libraries) from this week has exposed a bug in some part of Intellisense. As I add more code (often c++20 and Eigen), I feel like it is continuing to degrade. As of now (Saturday), completion usually does not work. Meaning, when I have a var or class and I type the . or :: then nothing appears. Last week...I got completion lists of types, members, etc.

Now...nothing except for crashes and the cpptools window noticing the crash

IntelliSense process crash detected: handle_update_intellisense
IntelliSense process crash detected: handle_quick_info
IntelliSense process crash detected: handle_completion
...and more
Repro
  1. Have code that has classes in namespaces, or members in the classes.
  2. Type myclass:: and wait for the completion

I know you want a minimal repro. I am unable to dedicate the tremendous resources needed to explore my entire codebase for how it would cause Intellisense to crash. I get the value in having bunch of cpp files to see it yourself, just not gonna happen with my scenario.

Result

Nothing happens. No completion list appears.

Expected

A list of members in the class, a list of functions, etc.

Configuration and Logs
I have no separate cpp-prop.json file. my settings are in settings.json

"C_Cpp.default.configurationProvider": "ms-vscode.cmake-tools",
    "C_Cpp.default.intelliSenseMode": "msvc-x64",
    "C_Cpp.default.cStandard": "c11",
    "C_Cpp.default.cppStandard": "c++20",
    "C_Cpp.default.compileCommands": "${workspaceFolder}/build/compile_commands.json",
    "C_Cpp.default.includePath": [
        "${workspaceFolder}/build"
    ],
    "C_Cpp.default.defines": [
        "RC_INVOKED"
    ],
    "C_Cpp.vcpkg.enabled": true,
    "C_Cpp.codeAnalysis.clangTidy.enabled": false,
    "C_Cpp.codeAnalysis.clangTidy.args": [
        "--extra-arg=-ferror-limit=1",
    ],
Other Extensions

I have 30 extensions active, 3 of which are the cpp tools pack. Another 4 or 5 are the msft remotes. and so on. I will not be disabling 27 extensions at this time. I do not remember add/removing any extensions this week. But extensions might have updated themselves in-place.

I did disable copilot hoping that was the cause. However, was not. With copilot disabled I reproduced the symptoms and crashes.

Additional context

The symbols downloaded, and I attached to cpptools-srv. Often, the attach quietly ends. I'm trying to repro the crash...and then...I'm unexpectedly not attached anymore. If I were to guess, something is not a "crash/assert" and is causing the cpp-srv to exit. Which naturally ends the attach. Looks like https://github.com/microsoft/vscode-cpptools/issues/6151 wasn't completely fixed. Also...your instructions at https://github.com/microsoft/vscode-cpptools/wiki/Attaching-debugger-to-cpptools-or-cpptools%E2%80%90srv link to that now closed/fixed bug...time to update the instructions ;-)

I had to repeatedly attach over and over and finally got a crash that caused the debugger to halt.
But there is nothing interesting in the call stack. I see no symbolic info...

cpptools-srv.exe!00000001403d8203() (Unknown Source:0)
cpptools-srv.exe!00000001403d9b9c() (Unknown Source:0)
cpptools-srv.exe!000000014039a18e() (Unknown Source:0)
cpptools-srv.exe!00000001403cc6e8() (Unknown Source:0)
cpptools-srv.exe!00000001403d9d4e() (Unknown Source:0)
cpptools-srv.exe!00000001403da057() (Unknown Source:0)
cpptools-srv.exe!000000014039f038() (Unknown Source:0)
cpptools-srv.exe!00000001403cca2a() (Unknown Source:0)
cpptools-srv.exe!00000001403d9d4e() (Unknown Source:0)
cpptools-srv.exe!00000001403da057() (Unknown Source:0)
cpptools-srv.exe!00000001403a70bc() (Unknown Source:0)
cpptools-srv.exe!00000001403ccab7() (Unknown Source:0)
cpptools-srv.exe!00000001403cd407() (Unknown Source:0)
cpptools-srv.exe!000000014015e653() (Unknown Source:0)
cpptools-srv.exe!0000000140161ffe() (Unknown Source:0)
cpptools-srv.exe!00000001401626ee() (Unknown Source:0)
cpptools-srv.exe!00000001402efbce() (Unknown Source:0)
cpptools-srv.exe!00000001402f09b4() (Unknown Source:0)
cpptools-srv.exe!00000001402f1594() (Unknown Source:0)
cpptools-srv.exe!00000001402f4c07() (Unknown Source:0)
cpptools-srv.exe!00000001402f3520() (Unknown Source:0)
cpptools-srv.exe!00000001402f2126() (Unknown Source:0)
cpptools-srv.exe!0000000140160985() (Unknown Source:0)
cpptools-srv.exe!00000001403cb643() (Unknown Source:0)
cpptools-srv.exe!00000001403cc510() (Unknown Source:0)
cpptools-srv.exe!00000001403d9d4e() (Unknown Source:0)
cpptools-srv.exe!00000001403da057() (Unknown Source:0)
cpptools-srv.exe!000000014039f038() (Unknown Source:0)
cpptools-srv.exe!00000001403cca2a() (Unknown Source:0)
cpptools-srv.exe!00000001403cd407() (Unknown Source:0)
cpptools-srv.exe!000000014015e653() (Unknown Source:0)
cpptools-srv.exe!00000001403fdb0d() (Unknown Source:0)
cpptools-srv.exe!0000000140178116() (Unknown Source:0)
cpptools-srv.exe!0000000140245bfe() (Unknown Source:0)
cpptools-srv.exe!0000000140247823() (Unknown Source:0)
cpptools-srv.exe!000000014024d4cc() (Unknown Source:0)
cpptools-srv.exe!000000014025315f() (Unknown Source:0)
cpptools-srv.exe!000000014036bfad() (Unknown Source:0)
cpptools-srv.exe!0000000140391477() (Unknown Source:0)
cpptools-srv.exe!00000001403b94eb() (Unknown Source:0)
cpptools-srv.exe!0000000140361c18() (Unknown Source:0)
cpptools-srv.exe!000000014036201c() (Unknown Source:0)
cpptools-srv.exe!0000000140362ce9() (Unknown Source:0)
cpptools-srv.exe!000000014036bdf2() (Unknown Source:0)
cpptools-srv.exe!0000000140391477() (Unknown Source:0)
cpptools-srv.exe!00000001403b94eb() (Unknown Source:0)
cpptools-srv.exe!00000001403ba42d() (Unknown Source:0)
cpptools-srv.exe!00000001405d89f3() (Unknown Source:0)
cpptools-srv.exe!00000001405de82d() (Unknown Source:0)
cpptools-srv.exe!00000001405df3c1() (Unknown Source:0)
cpptools-srv.exe!00000001405dd917() (Unknown Source:0)
cpptools-srv.exe!00000001405d5e5f() (Unknown Source:0)
cpptools-srv.exe!00000001405dd934() (Unknown Source:0)
cpptools-srv.exe!00000001405df3c1() (Unknown Source:0)
cpptools-srv.exe!000000014046d74f() (Unknown Source:0)
cpptools-srv.exe!000000014046fc58() (Unknown Source:0)
cpptools-srv.exe!00000001401e343b() (Unknown Source:0)
cpptools-srv.exe!00000001401ec00c() (Unknown Source:0)
cpptools-srv.exe!00000001401ecb38() (Unknown Source:0)
cpptools-srv.exe!00000001401def66() (Unknown Source:0)
cpptools-srv.exe!00000001401deef6() (Unknown Source:0)
cpptools-srv.exe!00000001401e9f04() (Unknown Source:0)
cpptools-srv.exe!00000001401eb942() (Unknown Source:0)
cpptools-srv.exe!00000001401ecb38() (Unknown Source:0)
cpptools-srv.exe!000000014019c629() (Unknown Source:0)
cpptools-srv.exe!000000014019b254() (Unknown Source:0)
cpptools-srv.exe!000000014019a6ff() (Unknown Source:0)
cpptools-srv.exe!00000001404d68bb() (Unknown Source:0)
cpptools-srv.exe!00000001405ff249() (Unknown Source:0)
cpptools-srv.exe!000000014054ad59() (Unknown Source:0)
cpptools-srv.exe!000000014053c300() (Unknown Source:0)
cpptools-srv.exe!000000014053c664() (Unknown Source:0)
cpptools-srv.exe!00000001400c5f38() (Unknown Source:0)
cpptools-srv.exe!00000001407e26db() (Unknown Source:0)
cpptools-srv.exe!00000001408f214a() (Unknown Source:0)
kernel32.dll!BaseThreadInitThunk() (Unknown Source:0)
ntdll.dll!RtlUserThreadStart() (Unknown Source:0)

One time I saw two cpptools-srv processes listed.

The debug console has more interesting info. ITs a lot. Often complaining

<- (E) {"seq":1012,"type":"event","event":"output","body":{"category":"stdout","output":"WER/CrashAPI:2693: ERROR Invalid args, too  big block\n"}}
WER/CrashAPI:2693: ERROR Invalid args, too  big block`

debug-console.txt

Here is another crash and the debugger halted. Again the call stack has only addresses, no symbols. Are you sure your current extensions's live code has matching symbols on the server?

cpptools-srv.exe!00000001403d8203() (Unknown Source:0)
cpptools-srv.exe!00000001403d9b9c() (Unknown Source:0)
cpptools-srv.exe!000000014039a18e() (Unknown Source:0)
cpptools-srv.exe!00000001403cc6e8() (Unknown Source:0)
cpptools-srv.exe!00000001403d9d4e() (Unknown Source:0)
cpptools-srv.exe!00000001403da057() (Unknown Source:0)
cpptools-srv.exe!000000014039f038() (Unknown Source:0)
cpptools-srv.exe!00000001403cca2a() (Unknown Source:0)
cpptools-srv.exe!00000001403d9d4e() (Unknown Source:0)
cpptools-srv.exe!00000001403da057() (Unknown Source:0)
cpptools-srv.exe!00000001403a70bc() (Unknown Source:0)
cpptools-srv.exe!00000001403ccab7() (Unknown Source:0)
cpptools-srv.exe!00000001403cd407() (Unknown Source:0)
cpptools-srv.exe!000000014015e653() (Unknown Source:0)
cpptools-srv.exe!0000000140161ffe() (Unknown Source:0)
cpptools-srv.exe!00000001401626ee() (Unknown Source:0)
cpptools-srv.exe!00000001402efbce() (Unknown Source:0)
cpptools-srv.exe!00000001402f09b4() (Unknown Source:0)
cpptools-srv.exe!00000001402f1594() (Unknown Source:0)
cpptools-srv.exe!00000001402f4c07() (Unknown Source:0)

and in the debug console shows a access violation in srv Exception thrown at 0x00000001403D8203 in cpptools-srv.exe: 0xC0000005: Access violation writing location 0x000000000000000C

<- (E) {"seq":23056,"type":"event","event":"output","body":{"category":"stdout","output":"WER/CrashAPI:2693: ERROR Invalid args, too  big block\n"}}
WER/CrashAPI:2693: ERROR Invalid args, too  big block
<- (E) {"seq":23058,"type":"event","event":"output","body":{"category":"stdout","output":"WER/CrashAPI:2693: ERROR Invalid args, too  big block\n"}}
WER/CrashAPI:2693: ERROR Invalid args, too  big block
<- (E) {"seq":23060,"type":"event","event":"output","body":{"category":"stdout","output":"WER/CrashAPI:2693: ERROR Invalid args, too  big block\n"}}
WER/CrashAPI:2693: ERROR Invalid args, too  big block
<- (E) {"seq":23062,"type":"event","event":"output","body":{"category":"stdout","output":"WER/CrashAPI:2693: ERROR Invalid args, too  big block\n"}}
WER/CrashAPI:2693: ERROR Invalid args, too  big block
<- (E) {"seq":23064,"type":"event","event":"output","body":{"category":"console","output":"Exception thrown at 0x00000001403D8203 in cpptools-srv.exe: 0xC0000005: Access violation writing location 0x000000000000000C.\n"}}
Exception thrown at 0x00000001403D8203 in cpptools-srv.exe: 0xC0000005: Access violation writing location 0x000000000000000C.
<- (E) {"seq":23066,"type":"event","event":"stopped","body":{"reason":"exception","threadId":29020,"text":"Unhandled exception at 0x00000001403D8203 in cpptools-srv.exe: 0xC0000005: Access violation writing location 0x000000000000000C.","allThreadsStopped":true}}
-> (C) {"command":"threads","type":"request","seq":13}
<- (R) {"seq":23069,"type":"response","request_seq":13,"success":true,"command":"threads","body":{"threads":[{"id":4472,"name":"Main Thread"},{"id":22932,"name":"cpptools-srv.exe thread"},{"id":26208,"name":"cpptools-srv.exe thread"},{"id":23620,"name":"cpptools-srv.exe thread"},{"id":26284,"name":"cpptools-srv.exe thread"},{"id":1880,"name":"cpptools-srv.exe thread"},{"id":25128,"name":"cpptools-srv.exe thread"},{"id":7608,"name":"cpptools-srv.exe thread"},{"id":27564,"name":"cpptools-srv.exe thread"},{"id":26824,"name":"cpptools-srv.exe thread"},{"id":29624,"name":"cpptools-srv.exe thread"},{"id":18524,"name":"cpptools-srv.exe thread"},{"id":11120,"name":"cpptools-srv.exe thread"},{"id":21296,"name":"cpptools-srv.exe thread"},{"id":29168,"name":"cpptools-srv.exe thread"},{"id":27168,"name":"cpptools-srv.exe thread"},{"id":18692,"name":"cpptools-srv.exe thread"},{"id":15768,"name":"cpptools-srv.exe thread"},{"id":24368,"name":"ntdll.dll!TppWorkerThread\u001E()"},{"id":924,"name":"ntdll.dll!TppWorkerThread\u001E()"},{"id":27212,"name":"cpptools-srv.exe thread"},{"id":12088,"name":"cpptools-srv.exe thread"},{"id":5640,"name":"cpptools-srv.exe thread"},{"id":24992,"name":"cpptools-srv.exe thread"},{"id":26796,"name":"cpptools-srv.exe thread"},{"id":29020,"name":"cpptools-srv.exe thread"},{"id":3916,"name":"ntdll.dll!TppWorkerThread\u001E()"}]}}
-> (C) {"command":"stackTrace","arguments":{"threadId":29020,"startFrame":0,"levels":20},"type":"request","seq":14}
<- (R) {"seq":23072,"type":"response","request_seq":14,"success":true,"command":"stackTrace","body":{"stackFrames":[{"id":1000,"name":"cpptools-srv.exe!00000001403d8203()","line":0,"column":0,"instructionPointerReference":"0x00000001403D8203","moduleId":1000},{"id":1001,"name":"cpptools-srv.exe!00000001403d9b9c()","line":0,"column":0,"instructionPointerReference":"0x00000001403D9B9C","moduleId":1000},{"id":1002,"name":"cpptools-srv.exe!000000014039a18e()","line":0,"column":0,"instructionPointerReference":"0x000000014039A18E","moduleId":1000},{"id":1003,"name":"cpptools-srv.exe!00000001403cc6e8()","line":0,"column":0,"instructionPointerReference":"0x00000001403CC6E8","moduleId":1000},{"id":1004,"name":"cpptools-srv.exe!00000001403d9d4e()","line":0,"column":0,"instructionPointerReference":"0x00000001403D9D4E","moduleId":1000},{"id":1005,"name":"cpptools-srv.exe!00000001403da057()","line":0,"column":0,"instructionPointerReference":"0x00000001403DA057","moduleId":1000},{"id":1006,"name":"cpptools-srv.exe!000000014039f038()","line":0,"column":0,"instructionPointerReference":"0x000000014039F038","moduleId":1000},{"id":1007,"name":"cpptools-srv.exe!00000001403cca2a()","line":0,"column":0,"instructionPointerReference":"0x00000001403CCA2A","moduleId":1000},{"id":1008,"name":"cpptools-srv.exe!00000001403d9d4e()","line":0,"column":0,"instructionPointerReference":"0x00000001403D9D4E","moduleId":1000},{"id":1009,"name":"cpptools-srv.exe!00000001403da057()","line":0,"column":0,"instructionPointerReference":"0x00000001403DA057","moduleId":1000},{"id":1010,"name":"cpptools-srv.exe!00000001403a70bc()","line":0,"column":0,"instructionPointerReference":"0x00000001403A70BC","moduleId":1000},{"id":1011,"name":"cpptools-srv.exe!00000001403ccab7()","line":0,"column":0,"instructionPointerReference":"0x00000001403CCAB7","moduleId":1000},{"id":1012,"name":"cpptools-srv.exe!00000001403cd407()","line":0,"column":0,"instructionPointerReference":"0x00000001403CD407","moduleId":1000},{"id":1013,"name":"cpptools-srv.exe!000000014015e653()","line":0,"column":0,"instructionPointerReference":"0x000000014015E653","moduleId":1000},{"id":1014,"name":"cpptools-srv.exe!0000000140161ffe()","line":0,"column":0,"instructionPointerReference":"0x0000000140161FFE","moduleId":1000},{"id":1015,"name":"cpptools-srv.exe!00000001401626ee()","line":0,"column":0,"instructionPointerReference":"0x00000001401626EE","moduleId":1000},{"id":1016,"name":"cpptools-srv.exe!00000001402efbce()","line":0,"column":0,"instructionPointerReference":"0x00000001402EFBCE","moduleId":1000},{"id":1017,"name":"cpptools-srv.exe!00000001402f09b4()","line":0,"column":0,"instructionPointerReference":"0x00000001402F09B4","moduleId":1000},{"id":1018,"name":"cpptools-srv.exe!00000001402f1594()","line":0,"column":0,"instructionPointerReference":"0x00000001402F1594","moduleId":1000},{"id":1019,"name":"cpptools-srv.exe!00000001402f4c07()","line":0,"column":0,"instructionPointerReference":"0x00000001402F4C07","moduleId":1000}],"totalFrames":77}}

I enabled DEBUG logging for cpp. In the c++ output window, is much private information. Though I saw the same errors at the top of this bug like IntelliSense process crash detected: handle_update_intellisense as well as many times Resetting IntelliSense server: Here is that log with the filepaths redacted, defines removed, etc.
cpp-log.log

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.