diff options
author | Chris Lattner <sabre@nondot.org> | 2003-06-20 15:49:04 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2003-06-20 15:49:04 +0000 |
commit | 5b836c4a06c584544647d5b013b193510ac5ced5 (patch) | |
tree | e1730d5ec05e58d4264a51d2c4578137b65a874b /tools/llc | |
parent | e3ba95e6b7dddf1160611fd7cd3b432e9366cb34 (diff) | |
download | external_llvm-5b836c4a06c584544647d5b013b193510ac5ced5.zip external_llvm-5b836c4a06c584544647d5b013b193510ac5ced5.tar.gz external_llvm-5b836c4a06c584544647d5b013b193510ac5ced5.tar.bz2 |
Minor cleanups
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6799 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/llc')
-rw-r--r-- | tools/llc/llc.cpp | 32 |
1 files changed, 10 insertions, 22 deletions
diff --git a/tools/llc/llc.cpp b/tools/llc/llc.cpp index d3bb7ee..49371af 100644 --- a/tools/llc/llc.cpp +++ b/tools/llc/llc.cpp @@ -1,6 +1,6 @@ -//===-- llc.cpp - Implement the LLVM Compiler -----------------------------===// +//===-- llc.cpp - Implement the LLVM Native Code Generator ----------------===// // -// This is the llc compiler driver. +// This is the llc code generator. // //===----------------------------------------------------------------------===// @@ -15,11 +15,6 @@ #include "Support/Signals.h" #include <memory> #include <fstream> -#include <cstdio> - -//------------------------------------------------------------------------------ -// Option declarations for LLC. -//------------------------------------------------------------------------------ // General options for llc. Other pass-specific options are specified // within the corresponding llc passes, and target-specific options @@ -58,29 +53,22 @@ GetFileNameRoot(const std::string &InputFilename) } -//===---------------------------------------------------------------------===// -// Function main() -// -// Entry point for the llc compiler. -//===---------------------------------------------------------------------===// - -int -main(int argc, char **argv) -{ +// main - Entry point for the llc compiler. +// +int main(int argc, char **argv) { cl::ParseCommandLineOptions(argc, argv, " llvm system compiler\n"); // Load the module to be compiled... std::auto_ptr<Module> M(ParseBytecodeFile(InputFilename)); - if (M.get() == 0) - { - std::cerr << argv[0] << ": bytecode didn't read correctly.\n"; - return 1; - } + if (M.get() == 0) { + std::cerr << argv[0] << ": bytecode didn't read correctly.\n"; + return 1; + } Module &mod = *M.get(); // Allocate target machine. First, check whether the user has // explicitly specified an architecture to compile for. - unsigned Config = (mod.isLittleEndian() ? TM::LittleEndian : TM::BigEndian) | + unsigned Config = (mod.isLittleEndian() ? TM::LittleEndian : TM::BigEndian)| (mod.has32BitPointers() ? TM::PtrSize32 : TM::PtrSize64); TargetMachine* (*TargetMachineAllocator)(unsigned) = 0; switch (Arch) { |