#define polyMul polyMulStage1; polyMulStage2; polyMulStage3; polyMulReduceStage
#define polyMulAVX2 polyMulStage1_AVX2; polyMulStage2_AVX2; polyMulStage3_AVX2; polyMulReduceStage
// ----------------------------------------------------------------------------
-TEXT polyHashADInternal(SB), NOSPLIT, $0
+TEXT polyHashADInternal<>(SB), NOSPLIT, $0
// adp points to beginning of additional data
// itr2 holds ad length
XORQ acc0, acc0
// Hash AAD
MOVQ ad_len+80(FP), itr2
- CALL polyHashADInternal(SB)
+ CALL polyHashADInternal<>(SB)
openSSEMainLoop:
CMPQ inl, $256
// Hash
MOVQ ad_len+80(FP), itr2
- CALL polyHashADInternal(SB)
+ CALL polyHashADInternal<>(SB)
openSSE128Open:
CMPQ inl, $16
// Hash AD + first 64 bytes
MOVQ ad_len+80(FP), itr2
- CALL polyHashADInternal(SB)
+ CALL polyHashADInternal<>(SB)
XORQ itr1, itr1
openAVX2InitialHash64:
openAVX2ShortOpen:
// Hash
MOVQ ad_len+80(FP), itr2
- CALL polyHashADInternal(SB)
+ CALL polyHashADInternal<>(SB)
openAVX2ShortOpenLoop:
CMPQ inl, $32
// Hash AAD
MOVQ ad_len+80(FP), itr2
- CALL polyHashADInternal(SB)
+ CALL polyHashADInternal<>(SB)
MOVOU (0*16)(inp), A0; MOVOU (1*16)(inp), B0; MOVOU (2*16)(inp), C0; MOVOU (3*16)(inp), D0
PXOR A0, A1; PXOR B0, B1; PXOR C0, C1; PXOR D0, D1
// Hash
MOVQ ad_len+80(FP), itr2
- CALL polyHashADInternal(SB)
+ CALL polyHashADInternal<>(SB)
XORQ itr1, itr1
sealSSE128SealHash:
// Hash AD
MOVQ ad_len+80(FP), itr2
- CALL polyHashADInternal(SB)
+ CALL polyHashADInternal<>(SB)
// Can store at least 320 bytes
VPXOR (0*32)(inp), AA0, AA0
sealAVX2ShortSeal:
// Hash aad
MOVQ ad_len+80(FP), itr2
- CALL polyHashADInternal(SB)
+ CALL polyHashADInternal<>(SB)
XORQ itr1, itr1
sealAVX2SealHash: