setupLLVMOptimizationRemarks overloads
Declared in <llvm/IR/LLVMRemarkStreamer.h>
Set up optimization remarks that output to a file. The LLVMRemarkFileHandle manages the lifetime of the underlying ToolOutputFile to ensure finalizeLLVMOptimizationRemarks() is called before the file is destroyed or released from the handle. The handle must be kept alive until all remarks were emitted through the remark streamer.
Expected<LLVMRemarkFileHandle>
setupLLVMOptimizationRemarks(
LLVMContext& Context,
StringRef RemarksFilename,
StringRef RemarksPasses,
StringRef RemarksFormat,
bool RemarksWithHotness,
std::optional<uint64_t> RemarksHotnessThreshold = 0);
» more...
Set up optimization remarks that output directly to a raw_ostream. OS is managed by the caller and must be open for writing until finalizeLLVMOptimizationRemarks() is called.
Error
setupLLVMOptimizationRemarks(
LLVMContext& Context,
raw_ostream& OS,
StringRef RemarksPasses,
StringRef RemarksFormat,
bool RemarksWithHotness,
std::optional<uint64_t> RemarksHotnessThreshold = 0);
» more...