diff options
author | Eugene Zelenko <eugene.zelenko@gmail.com> | 2016-05-25 01:18:36 +0000 |
---|---|---|
committer | Eugene Zelenko <eugene.zelenko@gmail.com> | 2016-05-25 01:18:36 +0000 |
commit | 2b8e41705e26f2eba369037ef6f7ba83a47cdf4e (patch) | |
tree | 7af0429860e618a3dbdd78a7656ec92df33ec28b /llvm/examples/BrainF/BrainFDriver.cpp | |
parent | 4c994ee42b8a959d9067746519dddc359eca9b5a (diff) | |
download | bcm5719-llvm-2b8e41705e26f2eba369037ef6f7ba83a47cdf4e.tar.gz bcm5719-llvm-2b8e41705e26f2eba369037ef6f7ba83a47cdf4e.zip |
Fix some Include What You Use warnings in examples; other minor fixes.
Differential revision: http://reviews.llvm.org/D20607
llvm-svn: 270645
Diffstat (limited to 'llvm/examples/BrainF/BrainFDriver.cpp')
-rw-r--r-- | llvm/examples/BrainF/BrainFDriver.cpp | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/llvm/examples/BrainF/BrainFDriver.cpp b/llvm/examples/BrainF/BrainFDriver.cpp index b484d758ff0..d19427add87 100644 --- a/llvm/examples/BrainF/BrainFDriver.cpp +++ b/llvm/examples/BrainF/BrainFDriver.cpp @@ -1,11 +1,11 @@ -//===-- BrainFDriver.cpp - BrainF compiler driver -----------------------===// +//===-- BrainFDriver.cpp - BrainF compiler driver -------------------------===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // -//===--------------------------------------------------------------------===// +//===----------------------------------------------------------------------===// // // This program converts the BrainF language into LLVM assembly, // which it can then run using the JIT or output as BitCode. @@ -22,21 +22,37 @@ // // lli prog.bf.bc #Run generated BitCode // -//===--------------------------------------------------------------------===// +//===----------------------------------------------------------------------===// #include "BrainF.h" +#include "llvm/ADT/APInt.h" #include "llvm/Bitcode/ReaderWriter.h" #include "llvm/ExecutionEngine/ExecutionEngine.h" #include "llvm/ExecutionEngine/GenericValue.h" +#include "llvm/IR/BasicBlock.h" #include "llvm/IR/Constants.h" +#include "llvm/IR/DerivedTypes.h" +#include "llvm/IR/Function.h" +#include "llvm/IR/Instructions.h" +#include "llvm/IR/LLVMContext.h" +#include "llvm/IR/Module.h" +#include "llvm/IR/Value.h" #include "llvm/IR/Verifier.h" +#include "llvm/Support/Casting.h" #include "llvm/Support/CommandLine.h" #include "llvm/Support/FileSystem.h" #include "llvm/Support/ManagedStatic.h" #include "llvm/Support/TargetSelect.h" #include "llvm/Support/raw_ostream.h" +#include <algorithm> +#include <cstdlib> #include <fstream> #include <iostream> +#include <memory> +#include <string> +#include <system_error> +#include <vector> + using namespace llvm; //Command line options @@ -53,7 +69,6 @@ ArrayBoundsChecking("abc", cl::desc("Enable array bounds checking")); static cl::opt<bool> JIT("jit", cl::desc("Run program Just-In-Time")); - //Add main function so can be fully compiled void addMainFunction(Module *mod) { //define i32 @main(i32 %argc, i8 **%argv) |