DiagnosticHandlerFunction DiagnosticHandler = nullptr);
/// Check if the given bitcode buffer contains a function summary block.
- bool hasFunctionSummary(MemoryBufferRef Buffer, LLVMContext &Context,
+ bool hasFunctionSummary(MemoryBufferRef Buffer,
DiagnosticHandlerFunction DiagnosticHandler);
/// Parse the specified bitcode buffer, returning the function info index.
/// the index. Otherwise skip the function summary section, and only create
/// an index object with a map from function name to function summary offset.
/// The index is used to perform lazy function summary reading later.
- ErrorOr<std::unique_ptr<FunctionInfoIndex>>
- getFunctionInfoIndex(MemoryBufferRef Buffer, LLVMContext &Context,
- DiagnosticHandlerFunction DiagnosticHandler,
- const Module *ExportingModule = nullptr,
- bool IsLazy = false);
+ ErrorOr<std::unique_ptr<FunctionInfoIndex>> getFunctionInfoIndex(
+ MemoryBufferRef Buffer, DiagnosticHandlerFunction DiagnosticHandler,
+ const Module *ExportingModule = nullptr, bool IsLazy = false);
/// This method supports lazy reading of function summary data from the
/// combined index during function importing. When reading the combined index
/// Then this method is called for each function considered for importing,
/// to parse the summary information for the given function name into
/// the index.
- std::error_code
- readFunctionSummary(MemoryBufferRef Buffer, LLVMContext &Context,
- DiagnosticHandlerFunction DiagnosticHandler,
- StringRef FunctionName,
- std::unique_ptr<FunctionInfoIndex> Index);
+ std::error_code readFunctionSummary(
+ MemoryBufferRef Buffer, DiagnosticHandlerFunction DiagnosticHandler,
+ StringRef FunctionName, std::unique_ptr<FunctionInfoIndex> Index);
/// \brief Write the specified module to the specified raw output stream.
///