llvm::LLVMRemarkFileHandle

RAII handle that manages the lifetime of the ToolOutputFile used to output remarks. On destruction (or when calling releaseFile()), this handle ensures that the optimization remarks are finalized and the RemarkStreamer is correctly deregistered from the LLVMContext.

Synopsis

Declared in <llvm/IR/LLVMRemarkStreamer.h>

class LLVMRemarkFileHandle final

Member Functions

NameDescription
LLVMRemarkFileHandle [constructor]Constructors
finalize
get
operator* Dereference operator
operator-> Member access operator
releaseFile Finalize remark emission and release the underlying ToolOutputFile.
operator bool Conversion to bool

Non-Member Functions

NameDescription
setupLLVMOptimizationRemarksSet 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.
lto::setupLLVMOptimizationRemarksSetup optimization remarks.