Skip to content

Commit

Permalink
Make EmitFunctionHeader a private helper.
Browse files Browse the repository at this point in the history
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@232481 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
espindola committed Mar 17, 2015
1 parent 42c951a commit b80d90e
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 11 deletions.
7 changes: 3 additions & 4 deletions include/llvm/CodeGen/AsmPrinter.h
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,6 @@ class AsmPrinter : public MachineFunctionPass {
/// Emit the specified function out to the OutStreamer.
bool runOnMachineFunction(MachineFunction &MF) override {
SetupMachineFunction(MF);
EmitFunctionHeader();
EmitFunctionBody();
return false;
}
Expand All @@ -211,9 +210,6 @@ class AsmPrinter : public MachineFunctionPass {
/// runOnMachineFunction.
void SetupMachineFunction(MachineFunction &MF);

/// This method emits the header for the current function.
void EmitFunctionHeader();

/// This method emits the body and trailer for a function.
void EmitFunctionBody();

Expand Down Expand Up @@ -504,6 +500,9 @@ class AsmPrinter : public MachineFunctionPass {
mutable unsigned Counter;
mutable unsigned SetCounter;

/// This method emits the header for the current function.
void EmitFunctionHeader();

/// Emit a blob of inline asm to the output streamer.
void
EmitInlineAsm(StringRef Str, const MCSubtargetInfo &STI,
Expand Down
2 changes: 2 additions & 0 deletions lib/CodeGen/AsmPrinter/AsmPrinter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -782,6 +782,8 @@ void AsmPrinter::emitFrameAlloc(const MachineInstr &MI) {
/// EmitFunctionBody - This method emits the body and trailer for a
/// function.
void AsmPrinter::EmitFunctionBody() {
EmitFunctionHeader();

// Emit target-specific gunk before the function body.
EmitFunctionBodyStart();

Expand Down
3 changes: 0 additions & 3 deletions lib/Target/ARM/ARMAsmPrinter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -120,9 +120,6 @@ bool ARMAsmPrinter::runOnMachineFunction(MachineFunction &MF) {
OutStreamer.EndCOFFSymbolDef();
}

// Have common code print out the function header with linkage info etc.
EmitFunctionHeader();

// Emit the rest of the function body.
EmitFunctionBody();

Expand Down
1 change: 0 additions & 1 deletion lib/Target/R600/AMDGPUAsmPrinter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,6 @@ bool AMDGPUAsmPrinter::runOnMachineFunction(MachineFunction &MF) {
HexLines.clear();
DisasmLineMaxLen = 0;

EmitFunctionHeader();
EmitFunctionBody();

if (isVerbose()) {
Expand Down
3 changes: 0 additions & 3 deletions lib/Target/X86/X86AsmPrinter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,6 @@ bool X86AsmPrinter::runOnMachineFunction(MachineFunction &MF) {
OutStreamer.EndCOFFSymbolDef();
}

// Have common code print out the function header with linkage info etc.
EmitFunctionHeader();

// Emit the rest of the function body.
EmitFunctionBody();

Expand Down

0 comments on commit b80d90e

Please sign in to comment.