brev8
Reverse bits in bytes
Reverses the order of the bits in every byte of a register.
| This instruction must have data-independent timing when extension Zkt is enabled. |
Execution
XReg input = X[xs1];
XReg output = 0;
for (U32 i = 0; i < xlen(); i = i + 8) {
for (U32 j = 0; j < 8; j = j + 1) {
output[i + (7 - j)] = input[i + j];
}
}
X[xd] = output;