-
Hello, I am using VS-Code (C/C++ extension version 1.5.1) for remote C++ programming (via SSH) on a HPC cluster running RHEL (7.9) using GCC 8.4. IntelliSense indexing is very slow on the RHEL cluster. I tried a different HPC cluster running CentOS (7.8) and IntelliSense indexing was slow there too. In both cases the small flame (:fire:) icon shows up on the bottom and stays there for about 6 minutes. Then the indexing starts (I have enabled However, the same operations run very fast (in less than a minute) on Ubuntu and Fedora Linux servers (same GCC 8.4 compiler). So there is some setup, albeit consistent, on the two HPC servers that cause IntelliSense to run slowly. Unfortunately, there isn't sufficient information in the logs (even in Of course, limiting the number of files to index definitely helps. Here is my // Temporary settings to help reduce the number of headers to make IntelliSense somewhat tolerable
{
"remote.autoForwardPortsSource": "output",
"C_Cpp.default.cppStandard": "c++17",
"C_Cpp.default.systemIncludePath": [ "/usr/include/*",
"/usr/local/gnu/8.4.0/**",
"/usr/local/boost/gnu/8.4/mvapich2/2.3/1.72.0/**",
"/opt/mvapich2/gnu/8.4/2.3.3/**",
"${workspaceFolder}/**",
],
} I am wondering if there are any suggestions or tips that I can explore to improve IntelliSense performance? I will have 100s of users trying to use this on the cluster very soon. Thank you, in advance, for any help/troubleshooting tips. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Summary: It was disk I/O that was slowing things downAfter much struggle and spending hours trying to
That led me to explore the possibility of using a local disk for storing the So in summary, the performance of IntelliSense is heavily dependent on the underlying disk. If you are using any kind of network-attached storage, then IntelliSense is going to be very slow. |
Beta Was this translation helpful? Give feedback.
-
A simpler/better solution is to set up the {
"C_Cpp.default.compilerPath": "/opt/mvapich2/gnu/8.4/2.3.3/bin/mpicxx",
"C_Cpp.default.cppStandard": "c++17",
"C_Cpp.commentContinuationPatterns": [
"/**"
],
"C_Cpp.default.browse.databaseFilename": "/tmp/${USER}/cpp-vscode.db"
} |
Beta Was this translation helpful? Give feedback.
Summary: It was disk I/O that was slowing things down
After much struggle and spending hours trying to
strace
and analyze thecpptols
binary, I ranperf
and it hinted hotspots with__libc_lseek64
andsqlite3VdbeExec
etc. That led me to think maybe the issue was with the mounts --ext4
mounts)nfs4
orgpfs
mounts)That led me to explore the possibility of using a local disk for storing the
~/.vscode-server
directory. Unfortunately, there isn't a clean option in theVS-Code
UI to specify an install directory …