Home | History | Annotate | Download | only in clang-interpreter

Lines Matching full:llvm

3 //                     The LLVM Compiler Infrastructure
19 #include "llvm/ADT/SmallString.h"
20 #include "llvm/ExecutionEngine/ExecutionEngine.h"
21 #include "llvm/ExecutionEngine/JIT.h"
22 #include "llvm/IR/Module.h"
23 #include "llvm/Support/FileSystem.h"
24 #include "llvm/Support/Host.h"
25 #include "llvm/Support/ManagedStatic.h"
26 #include "llvm/Support/Path.h"
27 #include "llvm/Support/TargetSelect.h"
28 #include "llvm/Support/raw_ostream.h"
42 return llvm::sys::fs::getMainExecutable(Argv0, MainAddr);
45 static int Execute(llvm::Module *Mod, char * const *envp) {
46 llvm::InitializeNativeTarget();
49 std::unique_ptr<llvm::ExecutionEngine> EE(
50 llvm::ExecutionEngine::create(Mod, /*ForceInterpreter*/ false, &Error));
52 llvm::errs() << "unable to make execution engine: " << Error << "\n";
56 llvm::Function *EntryFn = Mod->getFunction("main");
58 llvm::errs() << "'main' function not found in module.\n";
74 new TextDiagnosticPrinter(llvm::errs(), &*DiagOpts);
78 Driver TheDriver(Path, llvm::sys::getProcessTriple(), Diags);
98 llvm::raw_svector_ostream OS(Msg);
105 if (llvm::StringRef(Cmd->getCreator().getName()) != "clang") {
121 llvm::errs() << "clang invocation:\n";
122 Jobs.Print(llvm::errs(), "\n", true);
123 llvm::errs() << "\n";
143 // Create and execute the frontend to generate an LLVM bitcode module.
149 if (llvm::Module *Module = Act->takeModule())
154 llvm::llvm_shutdown();