summaryrefslogtreecommitdiff
path: root/include/llvm/CodeGen/AsmPrinter.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-04-04 18:58:53 +0000
committerChris Lattner <sabre@nondot.org>2010-04-04 18:58:53 +0000
commit17fedf216bc10c66e02694854f522cb602097005 (patch)
tree557dd0041b6afde04fbcb7a5c66458b790ca4dd0 /include/llvm/CodeGen/AsmPrinter.h
parent3f53c8398d81065736a784469c9dd5afff85673f (diff)
downloadllvm-17fedf216bc10c66e02694854f522cb602097005.tar.gz
llvm-17fedf216bc10c66e02694854f522cb602097005.tar.bz2
llvm-17fedf216bc10c66e02694854f522cb602097005.tar.xz
more interface cleanup make some helpers static functions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100343 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/CodeGen/AsmPrinter.h')
-rw-r--r--include/llvm/CodeGen/AsmPrinter.h70
1 files changed, 30 insertions, 40 deletions
diff --git a/include/llvm/CodeGen/AsmPrinter.h b/include/llvm/CodeGen/AsmPrinter.h
index 59323a5c1a..2262de8f4a 100644
--- a/include/llvm/CodeGen/AsmPrinter.h
+++ b/include/llvm/CodeGen/AsmPrinter.h
@@ -59,8 +59,7 @@ namespace llvm {
public:
/// DW - If available, this is a pointer to the current dwarf writer.
DwarfWriter *DW;
-
-
+
/// Target machine description.
///
TargetMachine &TM;
@@ -219,6 +218,16 @@ namespace llvm {
assert(0 && "EmitInstruction not implemented");
}
+ virtual void EmitFunctionEntryLabel();
+
+ virtual void EmitMachineConstantPoolValue(MachineConstantPoolValue *MCPV);
+
+ /// isBlockOnlyReachableByFallthough - Return true if the basic block has
+ /// exactly one predecessor and the control transfer mechanism between
+ /// the predecessor and this block is a fall-through.
+ virtual bool
+ isBlockOnlyReachableByFallthrough(const MachineBasicBlock *MBB) const;
+
//===------------------------------------------------------------------===//
// Lowering Routines.
//===------------------------------------------------------------------===//
@@ -276,51 +285,15 @@ namespace llvm {
void EmitBasicBlockStart(const MachineBasicBlock *MBB) const;
- // Data emission.
-
/// EmitGlobalConstant - Print a general LLVM constant to the .s file.
void EmitGlobalConstant(const Constant *CV, unsigned AddrSpace = 0);
- protected:
- virtual void EmitFunctionEntryLabel();
-
- virtual void EmitMachineConstantPoolValue(MachineConstantPoolValue *MCPV);
-
- /// printOffset - This is just convenient handler for printing offsets.
- void printOffset(int64_t Offset, raw_ostream &OS) const;
-
- /// isBlockOnlyReachableByFallthough - Return true if the basic block has
- /// exactly one predecessor and the control transfer mechanism between
- /// the predecessor and this block is a fall-through.
- virtual bool
- isBlockOnlyReachableByFallthrough(const MachineBasicBlock *MBB) const;
-
- private:
- /// EmitImplicitDef - This method emits the specified machine instruction
- /// that is an implicit def.
- void EmitImplicitDef(const MachineInstr *MI) const;
-
- /// EmitKill - This method emits the specified kill machine instruction.
- void EmitKill(const MachineInstr *MI) const;
-
- /// EmitVisibility - This emits visibility information about symbol, if
- /// this is suported by the target.
- void EmitVisibility(MCSymbol *Sym, unsigned Visibility) const;
-
- void EmitLinkage(unsigned Linkage, MCSymbol *GVSym) const;
-
- void EmitJumpTableEntry(const MachineJumpTableInfo *MJTI,
- const MachineBasicBlock *MBB,
- unsigned uid) const;
- void EmitLLVMUsedList(Constant *List);
- void EmitXXStructorList(Constant *List);
- GCMetadataPrinter *GetOrCreateGCPrinter(GCStrategy *C);
-
-
//===------------------------------------------------------------------===//
// Emission Helper Routines.
//===------------------------------------------------------------------===//
public:
+ /// printOffset - This is just convenient handler for printing offsets.
+ void printOffset(int64_t Offset, raw_ostream &OS) const;
/// EmitInt8 - Emit a byte directive and value.
///
@@ -388,6 +361,23 @@ namespace llvm {
/// EmitInlineAsm - This method formats and emits the specified machine
/// instruction that is an inline asm.
void EmitInlineAsm(const MachineInstr *MI) const;
+
+ //===------------------------------------------------------------------===//
+ // Internal Implementation Details
+ //===------------------------------------------------------------------===//
+
+ /// EmitVisibility - This emits visibility information about symbol, if
+ /// this is suported by the target.
+ void EmitVisibility(MCSymbol *Sym, unsigned Visibility) const;
+
+ void EmitLinkage(unsigned Linkage, MCSymbol *GVSym) const;
+
+ void EmitJumpTableEntry(const MachineJumpTableInfo *MJTI,
+ const MachineBasicBlock *MBB,
+ unsigned uid) const;
+ void EmitLLVMUsedList(Constant *List);
+ void EmitXXStructorList(Constant *List);
+ GCMetadataPrinter *GetOrCreateGCPrinter(GCStrategy *C);
};
}