Remove the 'printname' argument to WriteAsOperand. It is always true, and
authorChris Lattner <sabre@nondot.org>
Wed, 6 Dec 2006 06:16:21 +0000 (06:16 +0000)
committerChris Lattner <sabre@nondot.org>
Wed, 6 Dec 2006 06:16:21 +0000 (06:16 +0000)
passing false would make the asmprinter fail anyway.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32264 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Assembly/Writer.h
lib/Analysis/AliasAnalysisCounter.cpp
lib/Analysis/AliasAnalysisEvaluator.cpp
lib/Analysis/CFGPrinter.cpp
lib/Analysis/DataStructure/Printer.cpp
lib/Analysis/Trace.cpp
lib/Transforms/Scalar/Reassociate.cpp
lib/VMCore/Verifier.cpp

index 9ddb45e1cdf3dfa7ab4a46a829960ed2269d4c58..45c9513c54f512f310be63f9f863f5877701cb8e 100644 (file)
@@ -38,7 +38,7 @@ std::ostream &WriteTypeSymbolic(std::ostream &, const Type *, const Module *M);
 // pointer is printed symbolically.
 //
 std::ostream &WriteAsOperand(std::ostream &, const Value *, bool PrintTy = true,
-                             bool PrintName = true, const Module *Context = 0);
+                             const Module *Context = 0);
 
 } // End llvm namespace
 
index 6412dbbad669d053fe67dc137c5db6d8078ea9e8..d563c13c10b8d50ede7d0d9fe92862e6df1ed163 100644 (file)
@@ -135,9 +135,9 @@ AliasAnalysisCounter::alias(const Value *V1, unsigned V1Size,
   if (PrintAll || (PrintAllFailures && R == MayAlias)) {
     llvm_cerr << AliasString << ":\t";
     llvm_cerr << "[" << V1Size << "B] ";
-    WriteAsOperand(std::cerr, V1, true, true, M) << ", ";
+    WriteAsOperand(std::cerr, V1, true, M) << ", ";
     llvm_cerr << "[" << V2Size << "B] ";
-    WriteAsOperand(std::cerr, V2, true, true, M) << "\n";
+    WriteAsOperand(std::cerr, V2, true, M) << "\n";
   }
 
   return R;
@@ -159,7 +159,7 @@ AliasAnalysisCounter::getModRefInfo(CallSite CS, Value *P, unsigned Size) {
   if (PrintAll || (PrintAllFailures && R == ModRef)) {
     llvm_cerr << MRString << ":  Ptr: ";
     llvm_cerr << "[" << Size << "B] ";
-    WriteAsOperand(std::cerr, P, true, true, M);
+    WriteAsOperand(std::cerr, P, true, M);
     llvm_cerr << "\t<->" << *CS.getInstruction();
   }
   return R;
index 946a2ddc9ce61f18c728f4768c376126f0804b0a..d64394a879647712119770474854f4db438555a0 100644 (file)
@@ -80,8 +80,8 @@ static inline void PrintResults(const char *Msg, bool P, Value *V1, Value *V2,
                                 Module *M) {
   if (P) {
     llvm_cerr << "  " << Msg << ":\t";
-    WriteAsOperand(std::cerr, V1, true, true, M) << ", ";
-    WriteAsOperand(std::cerr, V2, true, true, M) << "\n";
+    WriteAsOperand(std::cerr, V1, true, M) << ", ";
+    WriteAsOperand(std::cerr, V2, true, M) << "\n";
   }
 }
 
@@ -90,7 +90,7 @@ PrintModRefResults(const char *Msg, bool P, Instruction *I, Value *Ptr,
                    Module *M) {
   if (P) {
     llvm_cerr << "  " << Msg << ":  Ptr: ";
-    WriteAsOperand(std::cerr, Ptr, true, true, M);
+    WriteAsOperand(std::cerr, Ptr, true, M);
     llvm_cerr << "\t<->" << *I;
   }
 }
index 3f6846e1f6ea0070681fbfa8a13b5147fd767687..bfc71c6686c98a7a3352c085d7e24f3fcd58317a 100644 (file)
@@ -50,12 +50,12 @@ struct DOTGraphTraits<const Function*> : public DefaultDOTGraphTraits {
 
     std::ostringstream Out;
     if (CFGOnly) {
-      WriteAsOperand(Out, Node, false, true);
+      WriteAsOperand(Out, Node, false);
       return Out.str();
     }
 
     if (Node->getName().empty()) {
-      WriteAsOperand(Out, Node, false, true);
+      WriteAsOperand(Out, Node, false);
       Out << ":";
     }
 
index ef3ed755559c238a3061c0bb45ed1208d9ec2a92..af358bfbb33ab4f3d96525954f7a429ce4007cc2 100644 (file)
@@ -81,7 +81,7 @@ static std::string getCaption(const DSNode *N, const DSGraph *G) {
   if (G) GlobalECs = &G->getGlobalECs();
 
   for (unsigned i = 0, e = N->getGlobalsList().size(); i != e; ++i) {
-    WriteAsOperand(OS, N->getGlobalsList()[i], false, true, M);
+    WriteAsOperand(OS, N->getGlobalsList()[i], false, M);
 
     // Figure out how many globals are equivalent to this one.
     if (GlobalECs) {
@@ -157,7 +157,7 @@ struct DOTGraphTraits<const DSGraph*> : public DefaultDOTGraphTraits {
     for (DSGraph::ScalarMapTy::const_iterator I = VM.begin(); I != VM.end();++I)
       if (!isa<GlobalValue>(I->first)) {
         std::stringstream OS;
-        WriteAsOperand(OS, I->first, false, true, CurMod);
+        WriteAsOperand(OS, I->first, false, CurMod);
         GW.emitSimpleNode(I->first, "", OS.str());
 
         // Add edge from return node to real destination
index 91c7ffa779976637848701a2ee97768ee9a36deb..d0457557c8e9b29cc1c9423f964930adcbfbdc41 100644 (file)
@@ -38,7 +38,7 @@ void Trace::print(llvm_ostream &O) const {
   for (const_iterator i = begin(), e = end(); i != e; ++i) {
     O << "; ";
     if (O.stream())
-      WriteAsOperand(*O.stream(), *i, true, true, getModule());
+      WriteAsOperand(*O.stream(), *i, true, getModule());
     O << "\n";
   }
   O << "; Trace parent function: \n" << *F;
index 2df52ae0efe9d29f3431206919767fde1eecac16..b0637ba3e5a2eba1e94c48f590eb89d6f33936be 100644 (file)
@@ -60,7 +60,7 @@ static void PrintOps(Instruction *I, const std::vector<ValueEntry> &Ops) {
   std::cerr << Instruction::getOpcodeName(I->getOpcode()) << " "
   << *Ops[0].Op->getType();
   for (unsigned i = 0, e = Ops.size(); i != e; ++i)
-    WriteAsOperand(std::cerr << " ", Ops[i].Op, false, true, M)
+    WriteAsOperand(std::cerr << " ", Ops[i].Op, false, M)
       << "," << Ops[i].Rank;
 }
   
index f1e14a64bc6e1373cc9354bdcea6dae09fde15cd..4e43a0cf072076254d519a2d86eedf34b2d8c7d0 100644 (file)
@@ -218,7 +218,7 @@ namespace {  // Anonymous namespace for class
       if (isa<Instruction>(V)) {
         msgs << *V;
       } else {
-        WriteAsOperand (msgs, V, true, true, Mod);
+        WriteAsOperand(msgs, V, true, Mod);
         msgs << "\n";
       }
     }