-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
IntelliSense experiences "Program terminated with signal SIGKILL, Killed." #11003
Comments
I am also getting a similar error while working with |
@EmbeddedBacon I've reproed this issue several times with 1.16.0 (i.e. probably the same cause as 1.15.4). I'm not sure what triggers/causes it yet though. It only seems to repro in certain situations. @karan-k-deepr Your issue sounds different. There is no freeze involved, just the cpptools process is exiting when it shouldn't. |
Mr. @sean-mcmanus , I have often wonder if the sigkill is related to the project size. The entire project size is 15 GB, including the .git directory which is 4.4 GB. The project also includes a number of project header files for specific hardware controllers. The total for these project header files for the "specific hardware controllers" totals 4.5 GB. When looking at the little cylinder icon at the bottom of VS Code that shows the current progress of "Parsing working place files", it will generally get stuck around 6-9% from what I can tell. If I look in the output window for C/C++ tools it always seems stuck "tag parsing file:" while parsing one of the header files in the "specific hardware controllers" directory. In #10636 you have already helped a lot trying to diagnose this issue. We even capture CPU and memory usage which didn't show high activity or large amounts of RAM usage. Question, I have looked through the documentation and Stack Overflow, but is there a way to exclude directories from being parsed? If there is any test or data captures you would like me to perform I will be more than willing to perform them. Thanks, sir. |
The issue I seemed to be hitting was only with 1.16.0 and caused by our thread pool not increasing in size. If you're reproing the bug with 1.15.4, that might be a different root cause bug. After that is fixed, I'll have to see if I still repro the same issue or not. |
@sean-mcmanus , is there a potential fix on the pre-release branch that I can try? yes, I have been seeing this issue for many release now, not just 1.15.4. Currently, I have VSCode configured to use the pre-release branch. |
@EmbeddedBacon Good news -- we believed we figured out the cause of the issue affecting 1.15.4 (and other older/newer versions). It should be available once 1.16.1 is released (we're still working on other changes for it). |
Mr. @sean-mcmanus , Fantastic!!!! Great work by the team |
Fixed in pre-release 1.16.1 https://github.com/microsoft/vscode-cpptools/releases/tag/v1.16.1. |
Been testing pre-release 1.16.1 for the past hour. Here are the notes so far
Prior to pre-release 1.16.1 the "Go to definition" would work at times. Hovering over a symbols some times would result in tooltip showing information for that symbol. So far I haven't seen either of these with this pre-release. Also, in the output window for c/cpp there was some activity showing progress of tag parsing head files. When switching from one source file to another these events are seen LSP: cpptools/textEditorSelectionChange |
I don't think this was answered yet. You can use the |
Hi @EmbeddedBacon .
The IPCH is used by the IntelliSense process. Clearing it would cause IntelliSense to start up a bit slower per file, as IPCH would need to be regenerated (per file). Workspace parsing and the Outline are not technically IntelliSense operations. However, there is a known bug that when an initial IntelliSense update takes a long time, some operations may block synchronously waiting for it to complete. I suspect that is what you were seeing in the snippet of log you posted. The logging of receipt and cancellation of the LSP message occurs in a dedicated thread. But the main thread that processes that work queue may be stalled on a synchronous wait. For the other anomalous behaviors, could you open a new issue (or multiple), with log output leading up to the repro behavior? It seems like something may have happened earlier, such as the database being fully reset and needing to repopulate, which might partially explain the other behaviors you're seeing. Also, you might be able to get some useful information by attaching a debugger to cpptools and grabbing stacks while it seems to be failing to process certain operations. |
Mr. @Colengms , thanks for the reply. I understand about deleting the cache, but I have had to do that from time to time, especially after updating this extension. Even after 3-4 hours of VS Code being open there still wasn't any change in the status regarding any of the items I listed above. I say this release isn't doing as well as before. I can create new reports and I will do that tomorrow. |
Question: So upon launching VS Code today which the instance is using remote to Fedora system. I see this in the c/cpp log window.
In the past I would see additional log messages with "tag parsing file:" but nothing after this point. I am not sure if this is okay or not. Just going off past experience. Seeing the log entry about "populating include completion cache I checked that folder to see what was there and this is what I see mrhicks in systemX in .cache/vscode-cpptools/ipch 🕙 13:35:40 λ l 🕙 13:35:52 λ l Only going based upon filenames, was only two source files parsed then? |
Hi @EmbeddedBacon . There are two major components of the C/C++ Extension: The tag parser (or browse database), and IntelliSense. The tag parser is syntactic/lexical. It scans for known keywords and constructs, but knows very little about user-defined types. IntelliSense is semantic. IntelliSense involves a C++ compiler front-end that actually attempts to compile an open file and provides features based on that understanding of the code. The IPCH files are related to the semantic IntelliSense pass. Only after opening a source/header file, and an IntelliSense pass successfully run, is an IPCH generated for that file. (Actually, headers will resolve to a source file, so there may be fewer than 1:1 per file).
The fact that tag parsing stalls at this file is worrisome. This could indicate that some internal error is occurring, such as an infinite loop, while parsing that header. Could you try running the "Reset IntelliSense Database" command? (The name of that command is perhaps misleading, as the browse database is not technically related to IntelliSense parsing/compiling). If the issue persists, you might try excluding that file using |
Instead of adding more comments related to tag parsing here, going to create a new report. Though, a "Reset IntelliSense Database" was issued, but stalled at a header file. Granted, these are hardware descriptor header files that are about 213MB in size. |
@Colengms , how do I determine the status of IntelliSense more so than what is presented here |
If Parsing Workspace is "paused" and IntelliSense is "updating", usually that means your |
Closing this issue, based on the original SIGKILL repro having been addressed. |
Environment
Bug Summary and Steps to Reproduce
Bug Summary: The language server that is running on the remote machine is restarting many times during coding sessions. The log in VS Code shows "[Error - 12:59:30 PM] The language server crashed. Restarting...". Attaching the debugger yields the a log entry of "Program terminated with signal SIGKILL, Killed."
Based upon comments supplied and followed from #10636, the following values were changed and currently set to: C_Cpp.intelliSenseMaxMemory = 65536, C_Cpp.intelliSenseCacheSize = 5120, and C_Cpp.intelliSenseMemoryLimit = 16384
At one time C_Cpp.intelliSenseCacheSize was set to zero, but that didn't seem to help either.
Steps to reproduce:
Configuration and Logs
Other Extensions
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: