[llvm-commits] CVS: llvm/tools/llc/Makefile llc.cpp

Chris Lattner sabre at nondot.org
Sun May 6 02:32:33 PDT 2007



Changes in directory llvm/tools/llc:

Makefile updated: 1.91 -> 1.92
llc.cpp updated: 1.147 -> 1.148
---
Log message:

switch tools to bitcode from bytecode


---
Diffs of the changes:  (+9 -17)

 Makefile |    2 +-
 llc.cpp  |   24 ++++++++----------------
 2 files changed, 9 insertions(+), 17 deletions(-)


Index: llvm/tools/llc/Makefile
diff -u llvm/tools/llc/Makefile:1.91 llvm/tools/llc/Makefile:1.92
--- llvm/tools/llc/Makefile:1.91	Sat May  5 23:55:19 2007
+++ llvm/tools/llc/Makefile	Sun May  6 04:32:02 2007
@@ -15,7 +15,7 @@
 # early so we can set up LINK_COMPONENTS before including Makefile.rules
 include $(LEVEL)/Makefile.config
 
-LINK_COMPONENTS := $(TARGETS_TO_BUILD) bcreader bitreader
+LINK_COMPONENTS := $(TARGETS_TO_BUILD) bitreader
 
 include $(LLVM_SRC_ROOT)/Makefile.rules
 


Index: llvm/tools/llc/llc.cpp
diff -u llvm/tools/llc/llc.cpp:1.147 llvm/tools/llc/llc.cpp:1.148
--- llvm/tools/llc/llc.cpp:1.147	Sun May  6 00:47:36 2007
+++ llvm/tools/llc/llc.cpp	Sun May  6 04:32:02 2007
@@ -14,7 +14,6 @@
 //===----------------------------------------------------------------------===//
 
 #include "llvm/Bitcode/ReaderWriter.h"
-#include "llvm/Bytecode/Reader.h"
 #include "llvm/CodeGen/FileWriters.h"
 #include "llvm/CodeGen/LinkAllCodegenComponents.h"
 #include "llvm/Target/SubtargetFeature.h"
@@ -23,10 +22,10 @@
 #include "llvm/Target/TargetMachineRegistry.h"
 #include "llvm/Transforms/Scalar.h"
 #include "llvm/Module.h"
+#include "llvm/ModuleProvider.h"
 #include "llvm/PassManager.h"
 #include "llvm/Pass.h"
 #include "llvm/Support/CommandLine.h"
-#include "llvm/Support/Compressor.h"
 #include "llvm/Support/ManagedStatic.h"
 #include "llvm/Support/MemoryBuffer.h"
 #include "llvm/Support/PluginLoader.h"
@@ -40,9 +39,6 @@
 #include <memory>
 using namespace llvm;
 
-cl::opt<bool> Bitcode("bitcode");
-
-
 // General options for llc.  Other pass-specific options are specified
 // within the corresponding llc passes, and target-specific options
 // and back-end code generation options are specified with the target machine.
@@ -183,17 +179,13 @@
   std::string ErrorMessage;
   std::auto_ptr<Module> M;
   
-  if (Bitcode) {
-    std::auto_ptr<MemoryBuffer> Buffer(
-        MemoryBuffer::getFileOrSTDIN(&InputFilename[0], InputFilename.size()));
-    if (Buffer.get())
-      M.reset(ParseBitcodeFile(Buffer.get(), &ErrorMessage));
-    else
-      ErrorMessage = "Error reading file '" + InputFilename + "'";
-  } else {
-    M.reset(ParseBytecodeFile(InputFilename, 
-                              Compressor::decompressToNewBuffer,
-                              &ErrorMessage));
+  {
+  std::auto_ptr<MemoryBuffer> Buffer(
+       MemoryBuffer::getFileOrSTDIN(&InputFilename[0], InputFilename.size()));
+  if (Buffer.get())
+    M.reset(ParseBitcodeFile(Buffer.get(), &ErrorMessage));
+  else
+    ErrorMessage = "Error reading file '" + InputFilename + "'";
   }
   if (M.get() == 0) {
     std::cerr << argv[0] << ": bytecode didn't read correctly.\n";






More information about the llvm-commits mailing list