MCPcopy Create free account
hub / github.com/GANGE666/xVMP / getSingleModule

Function getSingleModule

src/lib/Bitcode/Reader/BitcodeReader.cpp:6021–6030  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6019}
6020
6021static Expected<BitcodeModule> getSingleModule(MemoryBufferRef Buffer) {
6022 Expected<std::vector<BitcodeModule>> MsOrErr = getBitcodeModuleList(Buffer);
6023 if (!MsOrErr)
6024 return MsOrErr.takeError();
6025
6026 if (MsOrErr->size() != 1)
6027 return error("Expected a single module");
6028
6029 return (*MsOrErr)[0];
6030}
6031
6032Expected<std::unique_ptr<Module>>
6033llvm::getLazyBitcodeModule(MemoryBufferRef Buffer, LLVMContext &Context,

Callers 5

getLazyBitcodeModuleMethod · 0.85
parseBitcodeFileMethod · 0.85
getModuleSummaryIndexMethod · 0.85
getBitcodeLTOInfoMethod · 0.85

Calls 3

errorFunction · 0.70
takeErrorMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected