.globl F(rijndael_rcon)
///--------------------------------------------------------------------------
+/// Local utilities.
+
+// Magic constants for shuffling.
+#define ROTL 0x93
+#define ROT2 0x4e
+#define ROTR 0x39
+
+///--------------------------------------------------------------------------
/// Main code.
.arch .aes
// open-coding the whole thing. It's much easier to leave that as
// zero and XOR in the round constant by hand.
9: movd xmm0, eax
- pshufd xmm0, xmm0, 0x39
+ pshufd xmm0, xmm0, ROTR
aeskeygenassist xmm1, xmm0, 0
- pshufd xmm1, xmm1, 0x93
+ pshufd xmm1, xmm1, ROTL
movd eax, xmm1
xor eax, [esi]
xor al, [ecx]
cmp ebx, 7
jb 0f
movd xmm0, eax
- pshufd xmm0, xmm0, 0x93
+ pshufd xmm0, xmm0, ROTL
aeskeygenassist xmm1, xmm0, 0
movd eax, xmm1
0: xor eax, [esi]