Cleanup, no functionality change
authorAnton Korobeynikov <asl@math.spbu.ru>
Wed, 24 Sep 2008 22:16:33 +0000 (22:16 +0000)
committerAnton Korobeynikov <asl@math.spbu.ru>
Wed, 24 Sep 2008 22:16:33 +0000 (22:16 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56576 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/DarwinTargetAsmInfo.cpp
lib/Target/ELFTargetAsmInfo.cpp

index 6a53b6b25a5f70cae1d53a56a3e35023403f1d78..81a33420717d2e2df4e46010c7ddf6fe6791d6b4 100644 (file)
@@ -82,7 +82,7 @@ DarwinTargetAsmInfo::SelectSectionForGlobal(const GlobalValue *GV) const {
     if (isWeak)
       return TextCoalSection;
     else
-      return getTextSection();
+      return TextSection;
    case SectionKind::Data:
    case SectionKind::ThreadData:
    case SectionKind::BSS:
@@ -90,7 +90,7 @@ DarwinTargetAsmInfo::SelectSectionForGlobal(const GlobalValue *GV) const {
     if (cast<GlobalVariable>(GV)->isConstant())
       return (isWeak ? ConstDataCoalSection : ConstDataSection);
     else
-      return (isWeak ? DataCoalSection : getDataSection());
+      return (isWeak ? DataCoalSection : DataSection);
    case SectionKind::ROData:
     return (isWeak ? ConstDataCoalSection :
             (isNonStatic ? ConstDataSection : getReadOnlySection_()));
index df4e43d0aae34d381e52d1d1c4821c3c89d5366a..784d9cdbc522bc63ab1ecf7371b2615c7f0d75ac 100644 (file)
@@ -47,7 +47,7 @@ ELFTargetAsmInfo::SelectSectionForGlobal(const GlobalValue *GV) const {
      case Function::InternalLinkage:
      case Function::DLLExportLinkage:
      case Function::ExternalLinkage:
-      return getTextSection();
+      return TextSection;
      case Function::WeakLinkage:
      case Function::LinkOnceLinkage:
       std::string Name = UniqueSectionForGlobal(GV, Kind);
@@ -63,7 +63,7 @@ ELFTargetAsmInfo::SelectSectionForGlobal(const GlobalValue *GV) const {
       switch (Kind) {
        case SectionKind::Data:
        case SectionKind::SmallData:
-        return getDataSection();
+        return DataSection;
        case SectionKind::BSS:
        case SectionKind::SmallBSS:
         // ELF targets usually have BSS sections