aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/Target/ELFTargetAsmInfo.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/Target/ELFTargetAsmInfo.cpp b/lib/Target/ELFTargetAsmInfo.cpp
index 3d24c023c6..6bf7fd693b 100644
--- a/lib/Target/ELFTargetAsmInfo.cpp
+++ b/lib/Target/ELFTargetAsmInfo.cpp
@@ -58,11 +58,11 @@ ELFTargetAsmInfo::SectionKindForGlobal(const GlobalValue *GV) const {
bool isConstant = GVar->isConstant();
unsigned Reloc = RelocBehaviour();
if (Reloc != Reloc::None && C->ContainsRelocations(Reloc))
- return (C->ContainsRelocations(Reloc::Local) ?
+ return (C->ContainsRelocations(Reloc::Global) ?
(isConstant ?
- SectionKind::DataRelROLocal : SectionKind::DataRelLocal) :
+ SectionKind::DataRelRO : SectionKind::DataRel) :
(isConstant ?
- SectionKind::DataRelRO : SectionKind::DataRel));
+ SectionKind::DataRelROLocal : SectionKind::DataRelLocal));
}
return Kind;