Changes for 64bit gcc
authorAnand Shukla <ashukla@cs.uiuc.edu>
Tue, 25 Jun 2002 21:43:28 +0000 (21:43 +0000)
committerAnand Shukla <ashukla@cs.uiuc.edu>
Tue, 25 Jun 2002 21:43:28 +0000 (21:43 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2797 91177308-0d34-0410-b5e6-96231b3b80d8

tools/as/as.cpp
tools/llvm-as/as.cpp
tools/llvm-as/llvm-as.cpp
tools/opt/Makefile
tools/opt/opt.cpp

index 594feb8dd8366d36eb708079c48fe3a220286765..4ee329661ffb2c456a226dc68ae139ccf0e2467d 100644 (file)
@@ -6,7 +6,7 @@
 //   as [options]      - Read LLVM assembly from stdin, write bytecode to stdout
 //   as [options] x.ll - Read LLVM assembly from the x.ll file, write bytecode
 //                       to the x.bc file.
-//
+// 
 //===------------------------------------------------------------------------===
 
 #include "llvm/Module.h"
@@ -16,6 +16,8 @@
 #include "Support/Signals.h"
 #include <fstream>
 #include <memory>
+#include <iostream>
+using std::cerr;
 
 cl::String InputFilename ("", "Parse <arg> file, compile to bytecode", 0, "-");
 cl::String OutputFilename("o", "Override output filename", cl::NoFlags, "");
@@ -25,7 +27,7 @@ cl::Flag   DumpAsm       ("d", "Print assembly as parsed", cl::Hidden, false);
 int main(int argc, char **argv) {
   cl::ParseCommandLineOptions(argc, argv, " llvm .ll -> .bc assembler\n");
 
-  ostream *Out = 0;
+  std::ostream *Out = 0;
   try {
     // Parse the file now...
     std::auto_ptr<Module> M(ParseAssemblyFile(InputFilename));
@@ -47,7 +49,7 @@ int main(int argc, char **argv) {
     } else {
       if (InputFilename == "-") {
        OutputFilename = "-";
-       Out = &cout;
+       Out = &std::cout;
       } else {
        std::string IFN = InputFilename;
        int Len = IFN.length();
@@ -80,11 +82,11 @@ int main(int argc, char **argv) {
    
     WriteBytecodeToFile(M.get(), *Out);
   } catch (const ParseException &E) {
-    cerr << E.getMessage() << endl;
+    cerr << E.getMessage() << std::endl;
     return 1;
   }
 
-  if (Out != &cout) delete Out;
+  if (Out != &std::cout) delete Out;
   return 0;
 }
 
index 594feb8dd8366d36eb708079c48fe3a220286765..4ee329661ffb2c456a226dc68ae139ccf0e2467d 100644 (file)
@@ -6,7 +6,7 @@
 //   as [options]      - Read LLVM assembly from stdin, write bytecode to stdout
 //   as [options] x.ll - Read LLVM assembly from the x.ll file, write bytecode
 //                       to the x.bc file.
-//
+// 
 //===------------------------------------------------------------------------===
 
 #include "llvm/Module.h"
@@ -16,6 +16,8 @@
 #include "Support/Signals.h"
 #include <fstream>
 #include <memory>
+#include <iostream>
+using std::cerr;
 
 cl::String InputFilename ("", "Parse <arg> file, compile to bytecode", 0, "-");
 cl::String OutputFilename("o", "Override output filename", cl::NoFlags, "");
@@ -25,7 +27,7 @@ cl::Flag   DumpAsm       ("d", "Print assembly as parsed", cl::Hidden, false);
 int main(int argc, char **argv) {
   cl::ParseCommandLineOptions(argc, argv, " llvm .ll -> .bc assembler\n");
 
-  ostream *Out = 0;
+  std::ostream *Out = 0;
   try {
     // Parse the file now...
     std::auto_ptr<Module> M(ParseAssemblyFile(InputFilename));
@@ -47,7 +49,7 @@ int main(int argc, char **argv) {
     } else {
       if (InputFilename == "-") {
        OutputFilename = "-";
-       Out = &cout;
+       Out = &std::cout;
       } else {
        std::string IFN = InputFilename;
        int Len = IFN.length();
@@ -80,11 +82,11 @@ int main(int argc, char **argv) {
    
     WriteBytecodeToFile(M.get(), *Out);
   } catch (const ParseException &E) {
-    cerr << E.getMessage() << endl;
+    cerr << E.getMessage() << std::endl;
     return 1;
   }
 
-  if (Out != &cout) delete Out;
+  if (Out != &std::cout) delete Out;
   return 0;
 }
 
index 594feb8dd8366d36eb708079c48fe3a220286765..4ee329661ffb2c456a226dc68ae139ccf0e2467d 100644 (file)
@@ -6,7 +6,7 @@
 //   as [options]      - Read LLVM assembly from stdin, write bytecode to stdout
 //   as [options] x.ll - Read LLVM assembly from the x.ll file, write bytecode
 //                       to the x.bc file.
-//
+// 
 //===------------------------------------------------------------------------===
 
 #include "llvm/Module.h"
@@ -16,6 +16,8 @@
 #include "Support/Signals.h"
 #include <fstream>
 #include <memory>
+#include <iostream>
+using std::cerr;
 
 cl::String InputFilename ("", "Parse <arg> file, compile to bytecode", 0, "-");
 cl::String OutputFilename("o", "Override output filename", cl::NoFlags, "");
@@ -25,7 +27,7 @@ cl::Flag   DumpAsm       ("d", "Print assembly as parsed", cl::Hidden, false);
 int main(int argc, char **argv) {
   cl::ParseCommandLineOptions(argc, argv, " llvm .ll -> .bc assembler\n");
 
-  ostream *Out = 0;
+  std::ostream *Out = 0;
   try {
     // Parse the file now...
     std::auto_ptr<Module> M(ParseAssemblyFile(InputFilename));
@@ -47,7 +49,7 @@ int main(int argc, char **argv) {
     } else {
       if (InputFilename == "-") {
        OutputFilename = "-";
-       Out = &cout;
+       Out = &std::cout;
       } else {
        std::string IFN = InputFilename;
        int Len = IFN.length();
@@ -80,11 +82,11 @@ int main(int argc, char **argv) {
    
     WriteBytecodeToFile(M.get(), *Out);
   } catch (const ParseException &E) {
-    cerr << E.getMessage() << endl;
+    cerr << E.getMessage() << std::endl;
     return 1;
   }
 
-  if (Out != &cout) delete Out;
+  if (Out != &std::cout) delete Out;
   return 0;
 }
 
index cfe97d77cd72460cefd7440186bbd4bceb86557b..989bc642bd61b4e2fc488da3ba2ada2f4d649a5a 100644 (file)
@@ -1,7 +1,15 @@
 LEVEL = ../..
 TOOLNAME = opt
-USEDLIBS = bcreader bcwriter instrument profpaths scalaropts \
+
+#USEDLIBS = bcreader bcwriter profpaths \
+#           analysis transforms vmcore support
+
+
+USEDLIBS = bcreader bcwriter instrument profpaths \
            ipo ipa datastructure transforms target analysis transformutils vmcore support
 
+#USEDLIBS = bcreader bcwriter instrument profpaths scalaropts \
+#           ipo ipa datastructure transforms target analysis transformutils vmcore support
+
 include $(LEVEL)/Makefile.common
 
index 228e545e5eb259f007ad0e4f9d72635c14b2c48a..ce2db65dd08b66d679603dfd7114a45918f55460 100644 (file)
@@ -30,6 +30,9 @@
 #include "Support/Signals.h"
 #include <fstream>
 #include <memory>
+#include <iostream>
+
+using std::cerr;
 
 // FIXME: This should be parameterizable eventually for different target
 // types...
@@ -100,7 +103,6 @@ struct {
   { trace      , createTraceValuesPassForBasicBlocks },
   { tracem     , createTraceValuesPassForFunction    },
   { paths      , createProfilePathsPass              },
-
   { print      , createPrintFunctionPass },
   { printm     , createPrintModulePass   },
   { verify     , createVerifierPass      },