diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2014-01-24 02:18:40 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2014-01-24 02:18:40 +0000 |
commit | 5950c6fa48fe607e253afab421fa286f5f8e44bf (patch) | |
tree | d29e95e219e4d0c71a9b9b2ddbc4ba3edb2b8453 | |
parent | 42e23de4dbbf5bca6883d07dc0cc3f4ac40ca4f0 (diff) | |
download | llvm-5950c6fa48fe607e253afab421fa286f5f8e44bf.tar.gz llvm-5950c6fa48fe607e253afab421fa286f5f8e44bf.tar.bz2 llvm-5950c6fa48fe607e253afab421fa286f5f8e44bf.tar.xz |
Inline functions that are only called once.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@199965 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | include/llvm/MC/MCELFStreamer.h | 4 | ||||
-rw-r--r-- | lib/MC/MCELFStreamer.cpp | 25 |
2 files changed, 8 insertions, 21 deletions
diff --git a/include/llvm/MC/MCELFStreamer.h b/include/llvm/MC/MCELFStreamer.h index c9ec720b9b..c24119c330 100644 --- a/include/llvm/MC/MCELFStreamer.h +++ b/include/llvm/MC/MCELFStreamer.h @@ -106,10 +106,6 @@ private: std::vector<LocalCommon> LocalCommons; SmallPtrSet<MCSymbol *, 16> BindingExplicitlySet; - - void SetSectionData(); - void SetSectionText(); - void SetSectionBss(); }; MCELFStreamer *createARMELFStreamer(MCContext &Context, MCAsmBackend &TAB, diff --git a/lib/MC/MCELFStreamer.cpp b/lib/MC/MCELFStreamer.cpp index 47ac181346..d2c2395a7c 100644 --- a/lib/MC/MCELFStreamer.cpp +++ b/lib/MC/MCELFStreamer.cpp @@ -35,31 +35,22 @@ using namespace llvm; -inline void MCELFStreamer::SetSectionData() { - SwitchSection(getContext().getObjectFileInfo()->getDataSection()); - EmitCodeAlignment(4, 0); +MCELFStreamer::~MCELFStreamer() { } -inline void MCELFStreamer::SetSectionText() { +void MCELFStreamer::InitSections() { + // This emulates the same behavior of GNU as. This makes it easier + // to compare the output as the major sections are in the same order. SwitchSection(getContext().getObjectFileInfo()->getTextSection()); EmitCodeAlignment(4, 0); -} -inline void MCELFStreamer::SetSectionBss() { - SwitchSection(getContext().getObjectFileInfo()->getBSSSection()); + SwitchSection(getContext().getObjectFileInfo()->getDataSection()); EmitCodeAlignment(4, 0); -} -MCELFStreamer::~MCELFStreamer() { -} + SwitchSection(getContext().getObjectFileInfo()->getBSSSection()); + EmitCodeAlignment(4, 0); -void MCELFStreamer::InitSections() { - // This emulates the same behavior of GNU as. This makes it easier - // to compare the output as the major sections are in the same order. - SetSectionText(); - SetSectionData(); - SetSectionBss(); - SetSectionText(); + SwitchSection(getContext().getObjectFileInfo()->getTextSection()); } void MCELFStreamer::EmitLabel(MCSymbol *Symbol) { |