Skip to content

vector.constanti

← vector dialect

Materialize a non-empty all-static fixed-width integer vector from ordered literal lanes. Values use logical row-major lane order, and their count must match the result shape. Uniform literals canonicalize to vector.splati; target legalization expands remaining literals through the shared scalar construction path.

Operation contract

Property Value
Semantic phase executable
Traits Pure, ConstantLike

Signature

Kind Name Type Cardinality Description
Result result vector required —
Attribute values i64_array required Ordered integer lanes.

Verification constraints

  • HasAllStaticVector(result)
  • HasIntegerElement(result)

Examples

%v = vector.constanti [1, -2, 3, 4] : vector<2x2xi16>