10 #ifndef LLVM_CLANG_CODEGEN_CODEGENACTION_H
11 #define LLVM_CLANG_CODEGEN_CODEGENACTION_H
22 class BackendConsumer;
32 std::unique_ptr<llvm::Module>
Module;
47 std::unique_ptr<llvm::Module> TheModule;
51 llvm::LLVMContext *VMContext;
54 std::unique_ptr<llvm::Module> loadModule(llvm::MemoryBufferRef MBRef);
60 CodeGenAction(
unsigned _Act, llvm::LLVMContext *_VMContext =
nullptr);
65 StringRef InFile)
override;
85 virtual void anchor();
91 virtual void anchor();
97 virtual void anchor();
103 virtual void anchor();
109 virtual void anchor();
115 virtual void anchor();
bool hasIRSupport() const override
Does this action support use with IR files?
void EndSourceFileAction() override
Callback at the end of processing a single input.
void ExecuteAction() override
Callback to run the program action, using the initialized compiler instance.
Describes a module or submodule.
BackendConsumer * BEConsumer
EmitLLVMAction(llvm::LLVMContext *_VMContext=nullptr)
~CodeGenAction() override
CodeGenAction(unsigned _Act, llvm::LLVMContext *_VMContext=nullptr)
Create a new code generation action.
EmitObjAction(llvm::LLVMContext *_VMContext=nullptr)
EmitBCAction(llvm::LLVMContext *_VMContext=nullptr)
EmitCodeGenOnlyAction(llvm::LLVMContext *_VMContext=nullptr)
CompilerInstance - Helper class for managing a single instance of the Clang compiler.
Abstract base class to use for AST consumer-based frontend actions.
EmitLLVMOnlyAction(llvm::LLVMContext *_VMContext=nullptr)
std::unique_ptr< llvm::Module > takeModule()
Take the generated LLVM module, for use after the action has been run.
std::unique_ptr< ASTConsumer > CreateASTConsumer(CompilerInstance &CI, StringRef InFile) override
Create the AST consumer object for this action, if supported.
EmitAssemblyAction(llvm::LLVMContext *_VMContext=nullptr)
llvm::LLVMContext * takeLLVMContext()
Take the LLVM context used by this action.
Defines the clang::FrontendAction interface and various convenience abstract classes (clang::ASTFront...