diff options
| author | Chris Lattner <sabre@nondot.org> | 2010-01-19 02:13:06 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2010-01-19 02:13:06 +0000 |
| commit | 63b6b4e7fc5da5205de4875363e8c2110611b35f (patch) | |
| tree | ba2be5f8764b9f1da6e5283c7052b3718561d9e4 | |
| parent | 87edd27219b2b1e80ff485be96b91a733aeb4a32 (diff) | |
| download | external_llvm-63b6b4e7fc5da5205de4875363e8c2110611b35f.zip external_llvm-63b6b4e7fc5da5205de4875363e8c2110611b35f.tar.gz external_llvm-63b6b4e7fc5da5205de4875363e8c2110611b35f.tar.bz2 | |
change an accessor to a predicate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93839 91177308-0d34-0410-b5e6-96231b3b80d8
| -rw-r--r-- | include/llvm/Target/TargetLoweringObjectFile.h | 4 | ||||
| -rw-r--r-- | lib/Target/ARM/AsmPrinter/ARMAsmPrinter.cpp | 4 | ||||
| -rw-r--r-- | lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp | 4 | ||||
| -rw-r--r-- | lib/Target/X86/AsmPrinter/X86AsmPrinter.cpp | 4 |
4 files changed, 8 insertions, 8 deletions
diff --git a/include/llvm/Target/TargetLoweringObjectFile.h b/include/llvm/Target/TargetLoweringObjectFile.h index fec56fa..b8da445 100644 --- a/include/llvm/Target/TargetLoweringObjectFile.h +++ b/include/llvm/Target/TargetLoweringObjectFile.h @@ -315,8 +315,8 @@ public: /// getDataCommonSection - Return the "__DATA,__common" section we put /// zerofill (aka bss) data into. - const MCSection *getDataCommonSection() const { - return DataCommonSection; + bool isDataCommonSection(const MCSection *Section) const { + return Section == DataCommonSection; } /// getLazySymbolPointerSection - Return the section corresponding to diff --git a/lib/Target/ARM/AsmPrinter/ARMAsmPrinter.cpp b/lib/Target/ARM/AsmPrinter/ARMAsmPrinter.cpp index 30f9fec..2ba940b 100644 --- a/lib/Target/ARM/AsmPrinter/ARMAsmPrinter.cpp +++ b/lib/Target/ARM/AsmPrinter/ARMAsmPrinter.cpp @@ -1205,8 +1205,8 @@ void ARMAsmPrinter::PrintGlobalVariable(const GlobalVariable* GVar) { // emission. if (GVKind.isBSS() && MAI->hasMachoZeroFillDirective()) { TargetLoweringObjectFileMachO &TLOFMacho = - static_cast<TargetLoweringObjectFileMachO &>(getObjFileLowering()); - if (TheSection == TLOFMacho.getDataCommonSection()) { + static_cast<TargetLoweringObjectFileMachO &>(getObjFileLowering()); + if (TLOFMacho.isDataCommonSection(TheSection)) { // .globl _foo OutStreamer.EmitSymbolAttribute(GVarSym, MCStreamer::Global); // .zerofill __DATA, __common, _foo, 400, 5 diff --git a/lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp b/lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp index fad1c27..28dd193 100644 --- a/lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp +++ b/lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp @@ -953,8 +953,8 @@ void PPCDarwinAsmPrinter::PrintGlobalVariable(const GlobalVariable *GVar) { // emission. if (GVKind.isBSS() && MAI->hasMachoZeroFillDirective()) { TargetLoweringObjectFileMachO &TLOFMacho = - static_cast<TargetLoweringObjectFileMachO &>(getObjFileLowering()); - if (TheSection == TLOFMacho.getDataCommonSection()) { + static_cast<TargetLoweringObjectFileMachO &>(getObjFileLowering()); + if (TLOFMacho.isDataCommonSection(TheSection)) { // .globl _foo OutStreamer.EmitSymbolAttribute(GVarSym, MCStreamer::Global); // .zerofill __DATA, __common, _foo, 400, 5 diff --git a/lib/Target/X86/AsmPrinter/X86AsmPrinter.cpp b/lib/Target/X86/AsmPrinter/X86AsmPrinter.cpp index 3c290e8..3bf4c4c9 100644 --- a/lib/Target/X86/AsmPrinter/X86AsmPrinter.cpp +++ b/lib/Target/X86/AsmPrinter/X86AsmPrinter.cpp @@ -684,8 +684,8 @@ void X86AsmPrinter::PrintGlobalVariable(const GlobalVariable* GVar) { // emission. if (GVKind.isBSS() && MAI->hasMachoZeroFillDirective()) { TargetLoweringObjectFileMachO &TLOFMacho = - static_cast<TargetLoweringObjectFileMachO &>(getObjFileLowering()); - if (TheSection == TLOFMacho.getDataCommonSection()) { + static_cast<TargetLoweringObjectFileMachO &>(getObjFileLowering()); + if (TLOFMacho.isDataCommonSection(TheSection)) { // .globl _foo OutStreamer.EmitSymbolAttribute(GVarSym, MCStreamer::Global); // .zerofill __DATA, __common, _foo, 400, 5 |
