summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2001-07-20 19:14:01 +0000
committerChris Lattner <sabre@nondot.org>2001-07-20 19:14:01 +0000
commit64a234bc26e8e9f240757134d17f2111bfe2ec80 (patch)
treeca39bdf91f04d9f3ab95d246dde1c44beb26d541
parent85b1f151134a51c3481837ee49cff24505c0c54e (diff)
downloadbcm5719-llvm-64a234bc26e8e9f240757134d17f2111bfe2ec80.tar.gz
bcm5719-llvm-64a234bc26e8e9f240757134d17f2111bfe2ec80.zip
New function: WriteAsOperand.
llvm-svn: 210
-rw-r--r--llvm/include/llvm/Assembly/Writer.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/llvm/include/llvm/Assembly/Writer.h b/llvm/include/llvm/Assembly/Writer.h
index da247f6b51e..0fbb695a63d 100644
--- a/llvm/include/llvm/Assembly/Writer.h
+++ b/llvm/include/llvm/Assembly/Writer.h
@@ -23,6 +23,7 @@ class Module;
class Method;
class BasicBlock;
class Instruction;
+class SlotCalculator;
// The only interface defined by this file... convert the internal
// representation of an object into an ascii bytestream that the parser can
@@ -34,6 +35,14 @@ void WriteToAssembly(const BasicBlock *BB, ostream &o);
void WriteToAssembly(const Instruction *In, ostream &o);
void WriteToAssembly(const ConstPoolVal *V, ostream &o);
+// WriteAsOperand - Write the name of the specified value out to the specified
+// ostream. This can be useful when you just want to print int %reg126, not the
+// whole instruction that generated it.
+//
+ostream &WriteAsOperand(ostream &o, const Value *V, bool PrintType = true,
+ bool PrintName = true, SlotCalculator *Table = 0);
+
+
// WriteToVCG - Dump the specified structure to a VCG file. If method is
// dumped, then the file named is created. If a module is to be written, a
// family of files with a common base name is created, with a method name
OpenPOWER on IntegriCloud