llvm::getKnownAlignment

Try to infer an alignment for the specified pointer.

Synopsis

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

Align
getKnownAlignment(
    Value* V,
    DataLayout const& DL,
    Instruction const* CxtI = nullptr,
    AssumptionCache* AC = nullptr,
    DominatorTree const* DT = nullptr);

Return Value

This struct is a compact representation of a valid (non-zero power of two) alignment. It is suitable for use as static global constants.

Parameters

NameDescription
VLLVM Value Representation
DLA parsed version of the target data layout string in and methods for querying it.
ACA cache of @llvm.assume calls within a function.
DTConcrete subclass of DominatorTreeBase that is used to compute a normal dominator tree.