From f2fe0141cab7e761c456b9f8a12bbe401cb50278 Mon Sep 17 00:00:00 2001 From: Steven Wu Date: Mon, 29 Feb 2016 19:40:10 +0000 Subject: Rename embedded bitcode section in MachO Summary: Rename the section embeds bitcode from ".llvmbc,.llvmbc" to "__LLVM,__bitcode". The new name matches MachO section naming convention. Reviewers: rafael, pcc Subscribers: davide, llvm-commits, joker.eph Differential Revision: http://reviews.llvm.org/D17388 llvm-svn: 262245 --- llvm/lib/Object/FunctionIndexObjectFile.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'llvm/lib/Object/FunctionIndexObjectFile.cpp') diff --git a/llvm/lib/Object/FunctionIndexObjectFile.cpp b/llvm/lib/Object/FunctionIndexObjectFile.cpp index fe111de..927fd14 100644 --- a/llvm/lib/Object/FunctionIndexObjectFile.cpp +++ b/llvm/lib/Object/FunctionIndexObjectFile.cpp @@ -35,10 +35,7 @@ std::unique_ptr FunctionIndexObjectFile::takeIndex() { ErrorOr FunctionIndexObjectFile::findBitcodeInObject(const ObjectFile &Obj) { for (const SectionRef &Sec : Obj.sections()) { - StringRef SecName; - if (std::error_code EC = Sec.getName(SecName)) - return EC; - if (SecName == ".llvmbc") { + if (Sec.isBitcode()) { StringRef SecContents; if (std::error_code EC = Sec.getContents(SecContents)) return EC; -- cgit v1.1