CodeQL library for C/C++
Search

Class Compilation

An invocation of the compiler. Note that more than one file may be compiled per invocation. For example, this command compiles three source files:

gcc -c f1.c f2.c f3.c

Three things happen to each file during a compilation:

  1. The file is compiled by a real compiler, such as gcc or VC.
  2. The file is parsed by the CodeQL C++ front-end.
  3. The parsed representation is converted to database tables by the CodeQL extractor.

This class provides CPU and elapsed time information for steps 2 and 3, but not for step 1.

Import path

import cpp

Direct supertypes

Known direct subtypes

    Predicates

    getAFileCompiled

    Gets a file compiled during this invocation.

    getAnArgument

    Gets an argument passed to the extractor on this invocation.

    getArgument

    Gets the ith argument passed to the extractor on this invocation.

    getExtractorCpuSeconds

    Gets the amount of CPU time spent processing file number i in the extractor.

    getExtractorElapsedSeconds

    Gets the amount of elapsed time while processing file number i in the extractor.

    getFileCompiled

    Gets the ith file compiled during this invocation

    getFrontendCpuSeconds

    Gets the amount of CPU time spent processing file number i in the C++ front-end.

    getFrontendElapsedSeconds

    Gets the amount of elapsed time while processing file number i in the C++ front-end.

    getTotalCpuSeconds

    Gets the total amount of CPU time spent processing all the files in the front-end and extractor.

    getTotalElapsedSeconds

    Gets the total amount of elapsed time while processing all the files in the front-end and extractor.

    normalTermination

    Holds if the extractor terminated normally. Terminating with an exit code indicating that an error occurred is considered normal termination, but crashing due to something like a segfault is not.

    toString

    Gets a textual representation of this element.