diff options
| author | Mehwish Nagda <nagda@cs.uiuc.edu> | 2002-07-15 23:58:21 +0000 |
|---|---|---|
| committer | Mehwish Nagda <nagda@cs.uiuc.edu> | 2002-07-15 23:58:21 +0000 |
| commit | 382f286ae7a9138fc379b193ae9b00309a4bf686 (patch) | |
| tree | a1014b4d16a0159136c4b57957ca226a3cd23b65 /llvm/lib/Target | |
| parent | bbe64808db56e1da671699cfde4ff6323deba60a (diff) | |
| download | bcm5719-llvm-382f286ae7a9138fc379b193ae9b00309a4bf686.tar.gz bcm5719-llvm-382f286ae7a9138fc379b193ae9b00309a4bf686.zip | |
Added the Mapping Pass to out put Mapping Info to .s file
llvm-svn: 2913
Diffstat (limited to 'llvm/lib/Target')
| -rw-r--r-- | llvm/lib/Target/Sparc/Sparc.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/llvm/lib/Target/Sparc/Sparc.cpp b/llvm/lib/Target/Sparc/Sparc.cpp index be6e9f4670d..a3dd8c88351 100644 --- a/llvm/lib/Target/Sparc/Sparc.cpp +++ b/llvm/lib/Target/Sparc/Sparc.cpp @@ -12,6 +12,7 @@ #include "llvm/CodeGen/MachineCodeForInstruction.h" #include "llvm/CodeGen/MachineCodeForMethod.h" #include "llvm/CodeGen/RegisterAllocation.h" +#include "llvm/CodeGen/MappingInfo.h" #include "llvm/Function.h" #include "llvm/BasicBlock.h" #include "llvm/PassManager.h" @@ -156,6 +157,7 @@ public: } }; + struct FreeMachineCodeForFunction : public FunctionPass { const char *getPassName() const { return "Sparc FreeMachineCodeForFunction"; } @@ -175,8 +177,6 @@ struct FreeMachineCodeForFunction : public FunctionPass { } }; - - // addPassesToEmitAssembly - This method controls the entire code generation // process for the ultra sparc. // @@ -196,7 +196,9 @@ void UltraSparc::addPassesToEmitAssembly(PassManager &PM, std::ostream &Out) { //PM.add(new RemoveRedundantOps()); // operations with %g0, NOP, etc. PM.add(createPrologEpilogCodeInserter(*this)); - + + PM.add(MappingInfoForFunction(Out)); + // Output assembly language to the .s file. Assembly emission is split into // two parts: Function output and Global value output. This is because // function output is pipelined with all of the rest of code generation stuff, @@ -212,3 +214,4 @@ void UltraSparc::addPassesToEmitAssembly(PassManager &PM, std::ostream &Out) { // Emit bytecode to the sparc assembly file into its special section next PM.add(getEmitBytecodeToAsmPass(Out)); } + |

