[llvm] r261757 - [ThinLTO] Add missing breaks when parsing summaries (NFC)

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 24 09:57:28 PST 2016


Author: tejohnson
Date: Wed Feb 24 11:57:28 2016
New Revision: 261757

URL: http://llvm.org/viewvc/llvm-project?rev=261757&view=rev
Log:
[ThinLTO] Add missing breaks when parsing summaries (NFC)

This wasn't causing a correctness issue, but was causing extra duplicate
entries to be added to the SummaryMap.

Modified:
    llvm/trunk/lib/Bitcode/Reader/BitcodeReader.cpp

Modified: llvm/trunk/lib/Bitcode/Reader/BitcodeReader.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Bitcode/Reader/BitcodeReader.cpp?rev=261757&r1=261756&r2=261757&view=diff
==============================================================================
--- llvm/trunk/lib/Bitcode/Reader/BitcodeReader.cpp (original)
+++ llvm/trunk/lib/Bitcode/Reader/BitcodeReader.cpp Wed Feb 24 11:57:28 2016
@@ -5643,6 +5643,7 @@ std::error_code FunctionIndexBitcodeRead
       FS->setModulePath(
           TheIndex->addModulePath(Buffer->getBufferIdentifier(), 0));
       SummaryMap[ValueID] = std::move(FS);
+      break;
     }
     // FS_COMBINED_ENTRY: [modid, linkage, instcount]
     case bitc::FS_CODE_COMBINED_ENTRY: {
@@ -5654,6 +5655,7 @@ std::error_code FunctionIndexBitcodeRead
       FS->setFunctionLinkage(getDecodedLinkage(RawLinkage));
       FS->setModulePath(ModuleIdMap[ModuleId]);
       SummaryMap[CurRecordBit] = std::move(FS);
+      break;
     }
     }
   }




More information about the llvm-commits mailing list