we already know the sectionkind when invoking SelectSectionForGlobal,
pass it in instead of recomputing it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76990 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Target/ELFTargetAsmInfo.cpp b/lib/Target/ELFTargetAsmInfo.cpp
index 6ab9efb..40b7662 100644
--- a/lib/Target/ELFTargetAsmInfo.cpp
+++ b/lib/Target/ELFTargetAsmInfo.cpp
@@ -74,9 +74,8 @@
 }
 
 const Section*
-ELFTargetAsmInfo::SelectSectionForGlobal(const GlobalValue *GV) const {
-  SectionKind::Kind Kind = SectionKindForGlobal(GV);
-
+ELFTargetAsmInfo::SelectSectionForGlobal(const GlobalValue *GV,
+                                         SectionKind::Kind Kind) const {
   if (const Function *F = dyn_cast<Function>(GV)) {
     switch (F->getLinkage()) {
     default: llvm_unreachable("Unknown linkage type!");