llvm::canRenameComdatFunc

Return true if Comdat function F can safely share renamed counters.

Synopsis

Declared in <llvm/ProfileData/InstrProf.h>

bool
canRenameComdatFunc(
    Function const& F,
    bool CheckAddressTaken = false);

Description

Instances of the same Comdat may have different control flow and therefore cannot always share one counter variable.

Return Value

True if F can safely share renamed Comdat counters.

Parameters

NameDescription
FFunction being considered for Comdat renaming.
CheckAddressTakenIf true, reject address-taken functions.