Return true if V is known to be a power of two when defined.

Synopsis

Declared in <llvm/Analysis/ValueTracking.h>

bool
isKnownToBeAPowerOfTwo(
    Value const* V,
    bool OrZero,
    SimplifyQuery const& Q,
    unsigned int Depth = 0);

Return Value

True if V is a power of two when defined (or zero if OrZero).

Parameters

Name

Description

V

Value to test for being a power of two.

OrZero

Also accept zero as a successful result.

Q

Simplify query providing context for the analysis.

Depth

Current recursion depth for this query.

Created with MrDocs