VMMLA

BFloat16 floating-point matrix multiply-accumulate. This instruction multiplies the 2x4 matrix of BF16 values in the first 128-bit source vector by the 4x2 BF16 matrix in the second 128-bit source vector. The resulting 2x2 single-precision matrix product is then added destructively to the 2x2 single-precision matrix in the 128-bit destination vector. This is equivalent to performing a 4-way dot product per destination element. The instruction does not update the FPSCR exception status.


Note

Arm expects that the VMMLA instruction will deliver a peak BF16 multiply throughput that is at least as high as can be achieved using two VDOT instructions, with a goal that it should have significantly higher throughput.


It has encodings from the following instruction sets: A32 ( A1 ) and T32 ( T1 ) .

A1
(FEAT_AA32BF16)

313029282726252423222120191817161514131211109876543210
111111000D00VnVd1100N1M0Vm

Encoding for the A1 variant

VMMLA{<q>}.BF16 <Qd>, <Qn>, <Qm>

Decode for this encoding

if !IsFeatureImplemented(FEAT_AA32BF16) then UNDEFINED; if Vd<0> == '1' || Vn<0> == '1' || Vm<0> == '1' then UNDEFINED; constant integer d = UInt(D:Vd); constant integer n = UInt(N:Vn); constant integer m = UInt(M:Vm); constant integer regs = 2;

T1
(FEAT_AA32BF16)

15141312111098765432101514131211109876543210
111111000D00VnVd1100N1M0Vm

Encoding for the T1 variant

VMMLA{<q>}.BF16 <Qd>, <Qn>, <Qm>

Decode for this encoding

if InITBlock() then UNPREDICTABLE; if !IsFeatureImplemented(FEAT_AA32BF16) then UNDEFINED; if Vd<0> == '1' || Vn<0> == '1' || Vm<0> == '1' then UNDEFINED; constant integer d = UInt(D:Vd); constant integer n = UInt(N:Vn); constant integer m = UInt(M:Vm); constant integer regs = 2;

Assembler Symbols

<q>

See Standard assembler syntax fields.

<Qd>

Is the 128-bit name of the SIMD&FP destination register, encoded in the "D:Vd" field as <Qd>*2.

<Qn>

Is the 128-bit name of the first SIMD&FP source register, encoded in the "N:Vn" field as <Qn>*2.

<Qm>

Is the 128-bit name of the second SIMD&FP source register, encoded in the "M:Vm" field as <Qm>*2.

Operation

CheckAdvSIMDEnabled(); constant bits(128) op1 = Q[n>>1]; constant bits(128) op2 = Q[m>>1]; constant bits(128) acc = Q[d>>1]; constant FPCR_Type fpcr = EffectiveFPCR(); Q[d>>1] = BFMatMulAdd(acc, op1, op2, fpcr);


Internal version only: isa v01_32, pseudocode v2024-12_rel ; Build timestamp: 2024-12-16T10:54

Copyright © 2010-2024 Arm Limited or its affiliates. All rights reserved. This document is Non-Confidential.