ΒΆbool wouldInstructionBeTriviallyDeadOnUnusedPaths(
    llvm::Instruction* I,
    const llvm::TargetLibraryInfo* TLI = nullptr)

Description

Return true if the result produced by the instruction has no side effects on any paths other than where it is used. This is less conservative than wouldInstructionBeTriviallyDead which is based on the assumption that the use count will be 0. An example usage of this API is for identifying instructions that can be sunk down to use(s).

Declared at: llvm/include/llvm/Transforms/Utils/Local.h:87

Parameters

llvm::Instruction* I
const llvm::TargetLibraryInfo* TLI = nullptr