clang
19.0.0git
|
Use the CC1 tool callback when available, to avoid creating a new process. More...
#include "clang/Driver/Job.h"
Public Member Functions | |
CC1Command (const Action &Source, const Tool &Creator, ResponseFileSupport ResponseSupport, const char *Executable, const llvm::opt::ArgStringList &Arguments, ArrayRef< InputInfo > Inputs, ArrayRef< InputInfo > Outputs=std::nullopt, const char *PrependArg=nullptr) | |
void | Print (llvm::raw_ostream &OS, const char *Terminator, bool Quote, CrashReportInfo *CrashInfo=nullptr) const override |
int | Execute (ArrayRef< std::optional< StringRef >> Redirects, std::string *ErrMsg, bool *ExecutionFailed) const override |
void | setEnvironment (llvm::ArrayRef< const char * > NewEnvironment) override |
Sets the environment to be used by the new process. More... | |
Public Member Functions inherited from clang::driver::Command | |
Command (const Action &Source, const Tool &Creator, ResponseFileSupport ResponseSupport, const char *Executable, const llvm::opt::ArgStringList &Arguments, ArrayRef< InputInfo > Inputs, ArrayRef< InputInfo > Outputs=std::nullopt, const char *PrependArg=nullptr) | |
Command (const Command &)=default | |
virtual | ~Command ()=default |
void | addDiagForErrorCode (int ErrorCode, StringRef CustomDiag) |
Store a custom driver diagnostic message upon a particular error code returned by the command. More... | |
void | addExitForErrorCode (int ErrorCode, bool Exit) |
Store if the compilation should exit upon a particular error code returned by the command. More... | |
StringRef | getDiagForErrorCode (int ErrorCode) const |
Get the custom driver diagnostic message for a particular error code if such was stored. More... | |
bool | getWillExitForErrorCode (int ErrorCode) const |
Will the tool exit when a particular error code is encountered. More... | |
const Action & | getSource () const |
getSource - Return the Action which caused the creation of this job. More... | |
const Tool & | getCreator () const |
getCreator - Return the Tool which caused the creation of this job. More... | |
const ResponseFileSupport & | getResponseFileSupport () |
Returns the kind of response file supported by the current invocation. More... | |
void | setResponseFile (const char *FileName) |
Set to pass arguments via a response file when launching the command. More... | |
void | setInputFileList (llvm::opt::ArgStringList List) |
Set an input file list, necessary if you specified an RF_FileList response file support. More... | |
void | setRedirectFiles (const std::vector< std::optional< std::string >> &Redirects) |
void | replaceArguments (llvm::opt::ArgStringList List) |
void | replaceExecutable (const char *Exe) |
const char * | getExecutable () const |
const llvm::opt::ArgStringList & | getArguments () const |
const std::vector< InputInfo > & | getInputInfos () const |
const std::vector< std::string > & | getOutputFilenames () const |
std::optional< llvm::sys::ProcessStatistics > | getProcessStatistics () const |
Additional Inherited Members | |
Public Types inherited from clang::driver::Command | |
using | ErrorCodeDiagMapTy = llvm::DenseMap< int, std::string > |
using | ErrorCodeExitMapTy = llvm::DenseMap< int, bool > |
Public Attributes inherited from clang::driver::Command | |
bool | PrintInputFilenames = false |
Whether to print the input filenames when executing. More... | |
bool | InProcess = false |
Whether the command will be executed in this process or not. More... | |
Protected Member Functions inherited from clang::driver::Command | |
void | PrintFileNames () const |
Optionally print the filenames to be compiled. More... | |
Use the CC1 tool callback when available, to avoid creating a new process.
CC1Command::CC1Command | ( | const Action & | Source, |
const Tool & | Creator, | ||
ResponseFileSupport | ResponseSupport, | ||
const char * | Executable, | ||
const llvm::opt::ArgStringList & | Arguments, | ||
ArrayRef< InputInfo > | Inputs, | ||
ArrayRef< InputInfo > | Outputs = std::nullopt , |
||
const char * | PrependArg = nullptr |
||
) |
Definition at line 414 of file Job.cpp.
References clang::driver::Command::InProcess.
|
overridevirtual |
Reimplemented from clang::driver::Command.
Definition at line 432 of file Job.cpp.
References clang::driver::Command::Execute(), clang::driver::Command::getArguments(), clang::driver::Command::getCreator(), clang::driver::ToolChain::getDriver(), clang::driver::Command::getExecutable(), clang::driver::Tool::getToolChain(), clang::driver::Command::InProcess, and clang::driver::Command::PrintFileNames().
|
overridevirtual |
Reimplemented from clang::driver::Command.
Definition at line 425 of file Job.cpp.
References clang::driver::Command::InProcess, and clang::driver::Command::Print().
|
overridevirtual |
Sets the environment to be used by the new process.
NewEnvironment | An array of environment variables. |
Reimplemented from clang::driver::Command.