Returns true if function F is suggested to be size‐optimized based on the profile.

Synopsis

Declared in <llvm/Transforms/Utils/SizeOpts.h>

bool
shouldOptimizeForSize(
    Function const* F,
    ProfileSummaryInfo* PSI,
    BlockFrequencyInfo* BFI,
    PGSOQueryType QueryType = PGSOQueryType::Other);

Return Value

True if F should be optimized for size.

Parameters

Name

Description

F

The function to consider for size optimization.

PSI

Profile summary information used to classify hot/cold code.

BFI

Block frequency information for F.

QueryType

The caller context of this size‐optimization query.

Created with MrDocs