Mjolnir Core
Core functionality of the Mjolnir API

◆ exchange()

void exchange ( T_RegisterType &  reg_0,
T_RegisterType &  reg_1 
)
inlinenoexcept

Exchange two elements selected by indices between two registers.

The passed registers are modified during the operation. Note that the exchange is significantly slower if the exchanged elements are not inside the same lane.

Template Parameters
t_index_0Selects the element of reg_0 that should be exchanged
t_index_1Selects the element of reg_1 that should be exchanged
T_RegisterTypeThe register type
Parameters
[in,out]reg_0First register
[in,out]reg_1Second register