Lines Matching +full:2 +full:w
14 # General Public License (GPL) Version 2, available from the file
76 WK_SIZE = 2*8
84 # WK_2(t) points to 1 of 2 qwords at frame.WK depending on t being odd/even
98 # W[t]+K[t] (stack frame)
99 #define WK_2(i) 8*((i%2))+frame_WK(%rsp)
125 add WK_2(idx), T1 # W[t] + K[t] from message scheduler
129 add h_64, T1 # T1 = CH(e,f,g) + W[t] + K[t] + h
131 add tmp0, T1 # T1 = CH(e,f,g) + W[t] + K[t] + S1(e)
151 # Compute rounds t-2 and t-1
154 # Two rounds are computed based on the values for K[t-2]+W[t-2] and
155 # K[t-1]+W[t-1] which were previously stored at WK_2 by the message
162 # Eg. XMM2=W[t-2] really means XMM2={W[t-2]|W[t-1]}
170 idx = \rnd -2
171 movdqa W_t(idx), %xmm2 # XMM2 = W[t-2]
174 movdqa %xmm2, %xmm0 # XMM0 = W[t-2]
179 movdqu W_t(idx), %xmm5 # XMM5 = W[t-15]
182 movdqa %xmm5, %xmm3 # XMM3 = W[t-15]
185 psrlq $61-19, %xmm0 # XMM0 = W[t-2] >> 42
188 psrlq $(8-7), %xmm3 # XMM3 = W[t-15] >> 1
191 pxor %xmm2, %xmm0 # XMM0 = (W[t-2] >> 42) ^ W[t-2]
194 pxor %xmm5, %xmm3 # XMM3 = (W[t-15] >> 1) ^ W[t-15]
197 psrlq $(19-6), %xmm0 # XMM0 = ((W[t-2]>>42)^W[t-2])>>13
200 psrlq $(7-1), %xmm3 # XMM3 = ((W[t-15]>>1)^W[t-15])>>6
203 pxor %xmm2, %xmm0 # XMM0 = (((W[t-2]>>42)^W[t-2])>>13)^W[t-2]
206 pxor %xmm5, %xmm3 # XMM3 = (((W[t-15]>>1)^W[t-15])>>6)^W[t-15]
209 psrlq $6, %xmm0 # XMM0 = ((((W[t-2]>>42)^W[t-2])>>13)^W[t-2])>>6
212 psrlq $1, %xmm3 # XMM3 = (((W[t-15]>>1)^W[t-15])>>6)^W[t-15]>>1
215 movdqa %xmm2, %xmm1 # XMM1 = W[t-2]
218 movdqa %xmm5, %xmm4 # XMM4 = W[t-15]
221 psllq $(64-19)-(64-61) , %xmm1 # XMM1 = W[t-2] << 42
225 psllq $(64-1)-(64-8), %xmm4 # XMM4 = W[t-15] << 7
228 pxor %xmm2, %xmm1 # XMM1 = (W[t-2] << 42)^W[t-2]
231 pxor %xmm5, %xmm4 # XMM4 = (W[t-15]<<7)^W[t-15]
234 psllq $(64-61), %xmm1 # XMM1 = ((W[t-2] << 42)^W[t-2])<<3
237 psllq $(64-8), %xmm4 # XMM4 = ((W[t-15]<<7)^W[t-15])<<56
240 pxor %xmm1, %xmm0 # XMM0 = s1(W[t-2])
244 movdqu W_t(idx), %xmm1 # XMM1 = W[t-7]
246 pxor %xmm4, %xmm3 # XMM3 = s0(W[t-15])
248 paddq %xmm3, %xmm0 # XMM0 = s1(W[t-2]) + s0(W[t-15])
251 paddq W_t(idx), %xmm0 # XMM0 = s1(W[t-2]) + s0(W[t-15]) + W[t-16]
253 paddq %xmm1, %xmm0 # XMM0 = s1(W[t-2]) + W[t-7] + s0(W[t-15]) + W[t-16]
257 paddq K_t(\rnd), %xmm0 # Compute W[t]+K[t]
260 movdqa %xmm0, WK_2(idx) # Store W[t]+K[t] for next rounds
296 mov DIGEST(2), c_64
304 .rept 80/2 + 1
305 # (80 rounds) / (2 rounds/iteration) + (1 iteration)
307 .if t < 2
308 # BSWAP 2 QWORDS
313 paddq K_t(t), %xmm0 # Compute W[t]+K[t]
316 # BSWAP 2 QWORDS# Compute 2 Rounds
319 SHA512_Round t-2 # Round t-2
321 paddq K_t(t), %xmm0 # Compute W[t]+K[t]
323 movdqa %xmm0, WK_2(t) # Store W[t]+K[t] into WK
325 # Schedule 2 QWORDS# Compute 2 Rounds
328 # Compute 2 Rounds
329 SHA512_Round t-2
332 t = t+2
338 add c_64, DIGEST(2)