summaryrefslogtreecommitdiff
path: root/include/llvm/CodeGen/AsmPrinter.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-01-28 01:28:58 +0000
committerChris Lattner <sabre@nondot.org>2010-01-28 01:28:58 +0000
commitd49fe1b6bc4615684c2ec71140a21e9c4cd69ce3 (patch)
tree8cd572db61902f22106a3378d405a4d9be3ff03a /include/llvm/CodeGen/AsmPrinter.h
parentbec487767c3e0a376eed7c37773c88d6fcc8e4d9 (diff)
downloadllvm-d49fe1b6bc4615684c2ec71140a21e9c4cd69ce3.tar.gz
llvm-d49fe1b6bc4615684c2ec71140a21e9c4cd69ce3.tar.bz2
llvm-d49fe1b6bc4615684c2ec71140a21e9c4cd69ce3.tar.xz
Give AsmPrinter the most common expected implementation of
runOnMachineFunction, and switch PPC to use EmitFunctionBody. The two ppc asmprinters now don't heave to define runOnMachineFunction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@94722 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/CodeGen/AsmPrinter.h')
-rw-r--r--include/llvm/CodeGen/AsmPrinter.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/llvm/CodeGen/AsmPrinter.h b/include/llvm/CodeGen/AsmPrinter.h
index 1970e63efe..487c5422c3 100644
--- a/include/llvm/CodeGen/AsmPrinter.h
+++ b/include/llvm/CodeGen/AsmPrinter.h
@@ -207,6 +207,15 @@ namespace llvm {
unsigned AsmVariant,
const char *ExtraCode);
+ /// runOnMachineFunction - Emit the specified function out to the
+ /// OutStreamer.
+ virtual bool runOnMachineFunction(MachineFunction &MF) {
+ SetupMachineFunction(MF);
+ EmitFunctionHeader();
+ EmitFunctionBody();
+ return false;
+ }
+
/// SetupMachineFunction - This should be called when a new MachineFunction
/// is being processed from runOnMachineFunction.
void SetupMachineFunction(MachineFunction &MF);