Returns the largest unsigned integer less than or equal to Value and is Skew mod Align. Align must be non‐zero. Guaranteed to never overflow.

Synopsis

Declared in <llvm/Support/MathExtras.h>

template<
    typename U,
    typename V,
    typename W = uint8_t,
    typename T = common_uint<common_uint<U, V>, W>>
constexpr
T
alignDown(
    U Value,
    V Align,
    W Skew = 0);

Return Value

The largest value at most Value that is Skew modulo Align.

Parameters

Name

Description

Value

Value to align downward.

Align

Alignment multiple; must be non‐zero.

Skew

Optional offset within the alignment period.

Created with MrDocs