@@ -189,3 +189,48 @@ There are 3 possible fixes for this:
189
189
scip-clang will automatically use fewer workers if possible,
190
190
but will print a warning when it does so.
191
191
This warning can be suppressed by explicitly passing ` --jobs N ` .
192
+
193
+ ## Skipped compilation database entries
194
+
195
+ After completing indexing, scip-clang will print output like the following:
196
+
197
+ ```
198
+ Finished indexing 100 translation units in 40.2s (indexing: 38.0s, merging: 2.2s, num errored TUs: 0).
199
+ Skipped: 30 compilation database entries (non main file extension: 30, not found on disk: 0).
200
+ ```
201
+
202
+ Here, some entries are skipped because
203
+ scip-clang only looks at compilation database entries corresponding to
204
+ translation units (i.e. C, C++ or CUDA implementation files).
205
+ If a compilation database contains other entries,
206
+ for example, related to some code generation step or header files,
207
+ those are skipped.
208
+
209
+ Generally, this should not be a cause for concern,
210
+ as some compilation database generation tools
211
+ generate superfluous entries in the compilation database
212
+ which are not useful from an indexing perspective.
213
+
214
+ For example, here is the list of file extensions with counts
215
+ for scip-clang's own compilation database.
216
+
217
+ ```
218
+ $ jq '.[].file' compile_commands.json | awk -F'/' '{print $(NF)}' | sed -E 's/"//g' | sed -E 's/.+\./\./g' | sort | uniq -c
219
+ 27 .c
220
+ 225 .cc
221
+ 1956 .cpp
222
+ 6 .def
223
+ 3375 .h
224
+ 6081 .hpp
225
+ 175 .inc
226
+ 104 .ipp
227
+ 2 .pl
228
+ ```
229
+
230
+ Out of these, scip-clang will only create indexing jobs
231
+ for the entries for ` .c ` , ` .cc ` and ` .cpp ` files.
232
+ For header files, it is OK
233
+ to skip processing the corresponding compilation database entries
234
+ as the header file will be indexed
235
+ when they are included by a translation unit
236
+ (either directly or via some other header file).
0 commit comments