Kenny Root | b849459 | 2015-09-25 02:29:14 +0000 | [diff] [blame] | 1 | #if defined(__arm__) |
| 2 | #include <openssl/arm_arch.h> |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 3 | |
| 4 | .text |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 5 | #if defined(__thumb2__) |
| 6 | .syntax unified |
| 7 | .thumb |
| 8 | #else |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 9 | .code 32 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 10 | #endif |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 11 | |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 12 | .globl sha1_block_data_order |
David Benjamin | 4969cc9 | 2016-04-22 15:02:23 -0400 | [diff] [blame] | 13 | .hidden sha1_block_data_order |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 14 | .type sha1_block_data_order,%function |
| 15 | |
| 16 | .align 5 |
| 17 | sha1_block_data_order: |
| 18 | #if __ARM_MAX_ARCH__>=7 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 19 | .Lsha1_block: |
| 20 | adr r3,.Lsha1_block |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 21 | ldr r12,.LOPENSSL_armcap |
| 22 | ldr r12,[r3,r12] @ OPENSSL_armcap_P |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 23 | #ifdef __APPLE__ |
| 24 | ldr r12,[r12] |
| 25 | #endif |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 26 | tst r12,#ARMV8_SHA1 |
| 27 | bne .LARMv8 |
| 28 | tst r12,#ARMV7_NEON |
| 29 | bne .LNEON |
| 30 | #endif |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 31 | stmdb sp!,{r4,r5,r6,r7,r8,r9,r10,r11,r12,lr} |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 32 | add r2,r1,r2,lsl#6 @ r2 to point at the end of r1 |
| 33 | ldmia r0,{r3,r4,r5,r6,r7} |
| 34 | .Lloop: |
| 35 | ldr r8,.LK_00_19 |
| 36 | mov r14,sp |
| 37 | sub sp,sp,#15*4 |
| 38 | mov r5,r5,ror#30 |
| 39 | mov r6,r6,ror#30 |
| 40 | mov r7,r7,ror#30 @ [6] |
| 41 | .L_00_15: |
| 42 | #if __ARM_ARCH__<7 |
| 43 | ldrb r10,[r1,#2] |
| 44 | ldrb r9,[r1,#3] |
| 45 | ldrb r11,[r1,#1] |
| 46 | add r7,r8,r7,ror#2 @ E+=K_00_19 |
| 47 | ldrb r12,[r1],#4 |
| 48 | orr r9,r9,r10,lsl#8 |
| 49 | eor r10,r5,r6 @ F_xx_xx |
| 50 | orr r9,r9,r11,lsl#16 |
| 51 | add r7,r7,r3,ror#27 @ E+=ROR(A,27) |
| 52 | orr r9,r9,r12,lsl#24 |
| 53 | #else |
| 54 | ldr r9,[r1],#4 @ handles unaligned |
| 55 | add r7,r8,r7,ror#2 @ E+=K_00_19 |
| 56 | eor r10,r5,r6 @ F_xx_xx |
| 57 | add r7,r7,r3,ror#27 @ E+=ROR(A,27) |
| 58 | #ifdef __ARMEL__ |
| 59 | rev r9,r9 @ byte swap |
| 60 | #endif |
| 61 | #endif |
| 62 | and r10,r4,r10,ror#2 |
| 63 | add r7,r7,r9 @ E+=X[i] |
| 64 | eor r10,r10,r6,ror#2 @ F_00_19(B,C,D) |
| 65 | str r9,[r14,#-4]! |
| 66 | add r7,r7,r10 @ E+=F_00_19(B,C,D) |
| 67 | #if __ARM_ARCH__<7 |
| 68 | ldrb r10,[r1,#2] |
| 69 | ldrb r9,[r1,#3] |
| 70 | ldrb r11,[r1,#1] |
| 71 | add r6,r8,r6,ror#2 @ E+=K_00_19 |
| 72 | ldrb r12,[r1],#4 |
| 73 | orr r9,r9,r10,lsl#8 |
| 74 | eor r10,r4,r5 @ F_xx_xx |
| 75 | orr r9,r9,r11,lsl#16 |
| 76 | add r6,r6,r7,ror#27 @ E+=ROR(A,27) |
| 77 | orr r9,r9,r12,lsl#24 |
| 78 | #else |
| 79 | ldr r9,[r1],#4 @ handles unaligned |
| 80 | add r6,r8,r6,ror#2 @ E+=K_00_19 |
| 81 | eor r10,r4,r5 @ F_xx_xx |
| 82 | add r6,r6,r7,ror#27 @ E+=ROR(A,27) |
| 83 | #ifdef __ARMEL__ |
| 84 | rev r9,r9 @ byte swap |
| 85 | #endif |
| 86 | #endif |
| 87 | and r10,r3,r10,ror#2 |
| 88 | add r6,r6,r9 @ E+=X[i] |
| 89 | eor r10,r10,r5,ror#2 @ F_00_19(B,C,D) |
| 90 | str r9,[r14,#-4]! |
| 91 | add r6,r6,r10 @ E+=F_00_19(B,C,D) |
| 92 | #if __ARM_ARCH__<7 |
| 93 | ldrb r10,[r1,#2] |
| 94 | ldrb r9,[r1,#3] |
| 95 | ldrb r11,[r1,#1] |
| 96 | add r5,r8,r5,ror#2 @ E+=K_00_19 |
| 97 | ldrb r12,[r1],#4 |
| 98 | orr r9,r9,r10,lsl#8 |
| 99 | eor r10,r3,r4 @ F_xx_xx |
| 100 | orr r9,r9,r11,lsl#16 |
| 101 | add r5,r5,r6,ror#27 @ E+=ROR(A,27) |
| 102 | orr r9,r9,r12,lsl#24 |
| 103 | #else |
| 104 | ldr r9,[r1],#4 @ handles unaligned |
| 105 | add r5,r8,r5,ror#2 @ E+=K_00_19 |
| 106 | eor r10,r3,r4 @ F_xx_xx |
| 107 | add r5,r5,r6,ror#27 @ E+=ROR(A,27) |
| 108 | #ifdef __ARMEL__ |
| 109 | rev r9,r9 @ byte swap |
| 110 | #endif |
| 111 | #endif |
| 112 | and r10,r7,r10,ror#2 |
| 113 | add r5,r5,r9 @ E+=X[i] |
| 114 | eor r10,r10,r4,ror#2 @ F_00_19(B,C,D) |
| 115 | str r9,[r14,#-4]! |
| 116 | add r5,r5,r10 @ E+=F_00_19(B,C,D) |
| 117 | #if __ARM_ARCH__<7 |
| 118 | ldrb r10,[r1,#2] |
| 119 | ldrb r9,[r1,#3] |
| 120 | ldrb r11,[r1,#1] |
| 121 | add r4,r8,r4,ror#2 @ E+=K_00_19 |
| 122 | ldrb r12,[r1],#4 |
| 123 | orr r9,r9,r10,lsl#8 |
| 124 | eor r10,r7,r3 @ F_xx_xx |
| 125 | orr r9,r9,r11,lsl#16 |
| 126 | add r4,r4,r5,ror#27 @ E+=ROR(A,27) |
| 127 | orr r9,r9,r12,lsl#24 |
| 128 | #else |
| 129 | ldr r9,[r1],#4 @ handles unaligned |
| 130 | add r4,r8,r4,ror#2 @ E+=K_00_19 |
| 131 | eor r10,r7,r3 @ F_xx_xx |
| 132 | add r4,r4,r5,ror#27 @ E+=ROR(A,27) |
| 133 | #ifdef __ARMEL__ |
| 134 | rev r9,r9 @ byte swap |
| 135 | #endif |
| 136 | #endif |
| 137 | and r10,r6,r10,ror#2 |
| 138 | add r4,r4,r9 @ E+=X[i] |
| 139 | eor r10,r10,r3,ror#2 @ F_00_19(B,C,D) |
| 140 | str r9,[r14,#-4]! |
| 141 | add r4,r4,r10 @ E+=F_00_19(B,C,D) |
| 142 | #if __ARM_ARCH__<7 |
| 143 | ldrb r10,[r1,#2] |
| 144 | ldrb r9,[r1,#3] |
| 145 | ldrb r11,[r1,#1] |
| 146 | add r3,r8,r3,ror#2 @ E+=K_00_19 |
| 147 | ldrb r12,[r1],#4 |
| 148 | orr r9,r9,r10,lsl#8 |
| 149 | eor r10,r6,r7 @ F_xx_xx |
| 150 | orr r9,r9,r11,lsl#16 |
| 151 | add r3,r3,r4,ror#27 @ E+=ROR(A,27) |
| 152 | orr r9,r9,r12,lsl#24 |
| 153 | #else |
| 154 | ldr r9,[r1],#4 @ handles unaligned |
| 155 | add r3,r8,r3,ror#2 @ E+=K_00_19 |
| 156 | eor r10,r6,r7 @ F_xx_xx |
| 157 | add r3,r3,r4,ror#27 @ E+=ROR(A,27) |
| 158 | #ifdef __ARMEL__ |
| 159 | rev r9,r9 @ byte swap |
| 160 | #endif |
| 161 | #endif |
| 162 | and r10,r5,r10,ror#2 |
| 163 | add r3,r3,r9 @ E+=X[i] |
| 164 | eor r10,r10,r7,ror#2 @ F_00_19(B,C,D) |
| 165 | str r9,[r14,#-4]! |
| 166 | add r3,r3,r10 @ E+=F_00_19(B,C,D) |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 167 | #if defined(__thumb2__) |
| 168 | mov r12,sp |
| 169 | teq r14,r12 |
| 170 | #else |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 171 | teq r14,sp |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 172 | #endif |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 173 | bne .L_00_15 @ [((11+4)*5+2)*3] |
| 174 | sub sp,sp,#25*4 |
| 175 | #if __ARM_ARCH__<7 |
| 176 | ldrb r10,[r1,#2] |
| 177 | ldrb r9,[r1,#3] |
| 178 | ldrb r11,[r1,#1] |
| 179 | add r7,r8,r7,ror#2 @ E+=K_00_19 |
| 180 | ldrb r12,[r1],#4 |
| 181 | orr r9,r9,r10,lsl#8 |
| 182 | eor r10,r5,r6 @ F_xx_xx |
| 183 | orr r9,r9,r11,lsl#16 |
| 184 | add r7,r7,r3,ror#27 @ E+=ROR(A,27) |
| 185 | orr r9,r9,r12,lsl#24 |
| 186 | #else |
| 187 | ldr r9,[r1],#4 @ handles unaligned |
| 188 | add r7,r8,r7,ror#2 @ E+=K_00_19 |
| 189 | eor r10,r5,r6 @ F_xx_xx |
| 190 | add r7,r7,r3,ror#27 @ E+=ROR(A,27) |
| 191 | #ifdef __ARMEL__ |
| 192 | rev r9,r9 @ byte swap |
| 193 | #endif |
| 194 | #endif |
| 195 | and r10,r4,r10,ror#2 |
| 196 | add r7,r7,r9 @ E+=X[i] |
| 197 | eor r10,r10,r6,ror#2 @ F_00_19(B,C,D) |
| 198 | str r9,[r14,#-4]! |
| 199 | add r7,r7,r10 @ E+=F_00_19(B,C,D) |
| 200 | ldr r9,[r14,#15*4] |
| 201 | ldr r10,[r14,#13*4] |
| 202 | ldr r11,[r14,#7*4] |
| 203 | add r6,r8,r6,ror#2 @ E+=K_xx_xx |
| 204 | ldr r12,[r14,#2*4] |
| 205 | eor r9,r9,r10 |
| 206 | eor r11,r11,r12 @ 1 cycle stall |
| 207 | eor r10,r4,r5 @ F_xx_xx |
| 208 | mov r9,r9,ror#31 |
| 209 | add r6,r6,r7,ror#27 @ E+=ROR(A,27) |
| 210 | eor r9,r9,r11,ror#31 |
| 211 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 212 | and r10,r3,r10,ror#2 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 213 | @ F_xx_xx |
| 214 | add r6,r6,r9 @ E+=X[i] |
| 215 | eor r10,r10,r5,ror#2 @ F_00_19(B,C,D) |
| 216 | add r6,r6,r10 @ E+=F_00_19(B,C,D) |
| 217 | ldr r9,[r14,#15*4] |
| 218 | ldr r10,[r14,#13*4] |
| 219 | ldr r11,[r14,#7*4] |
| 220 | add r5,r8,r5,ror#2 @ E+=K_xx_xx |
| 221 | ldr r12,[r14,#2*4] |
| 222 | eor r9,r9,r10 |
| 223 | eor r11,r11,r12 @ 1 cycle stall |
| 224 | eor r10,r3,r4 @ F_xx_xx |
| 225 | mov r9,r9,ror#31 |
| 226 | add r5,r5,r6,ror#27 @ E+=ROR(A,27) |
| 227 | eor r9,r9,r11,ror#31 |
| 228 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 229 | and r10,r7,r10,ror#2 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 230 | @ F_xx_xx |
| 231 | add r5,r5,r9 @ E+=X[i] |
| 232 | eor r10,r10,r4,ror#2 @ F_00_19(B,C,D) |
| 233 | add r5,r5,r10 @ E+=F_00_19(B,C,D) |
| 234 | ldr r9,[r14,#15*4] |
| 235 | ldr r10,[r14,#13*4] |
| 236 | ldr r11,[r14,#7*4] |
| 237 | add r4,r8,r4,ror#2 @ E+=K_xx_xx |
| 238 | ldr r12,[r14,#2*4] |
| 239 | eor r9,r9,r10 |
| 240 | eor r11,r11,r12 @ 1 cycle stall |
| 241 | eor r10,r7,r3 @ F_xx_xx |
| 242 | mov r9,r9,ror#31 |
| 243 | add r4,r4,r5,ror#27 @ E+=ROR(A,27) |
| 244 | eor r9,r9,r11,ror#31 |
| 245 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 246 | and r10,r6,r10,ror#2 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 247 | @ F_xx_xx |
| 248 | add r4,r4,r9 @ E+=X[i] |
| 249 | eor r10,r10,r3,ror#2 @ F_00_19(B,C,D) |
| 250 | add r4,r4,r10 @ E+=F_00_19(B,C,D) |
| 251 | ldr r9,[r14,#15*4] |
| 252 | ldr r10,[r14,#13*4] |
| 253 | ldr r11,[r14,#7*4] |
| 254 | add r3,r8,r3,ror#2 @ E+=K_xx_xx |
| 255 | ldr r12,[r14,#2*4] |
| 256 | eor r9,r9,r10 |
| 257 | eor r11,r11,r12 @ 1 cycle stall |
| 258 | eor r10,r6,r7 @ F_xx_xx |
| 259 | mov r9,r9,ror#31 |
| 260 | add r3,r3,r4,ror#27 @ E+=ROR(A,27) |
| 261 | eor r9,r9,r11,ror#31 |
| 262 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 263 | and r10,r5,r10,ror#2 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 264 | @ F_xx_xx |
| 265 | add r3,r3,r9 @ E+=X[i] |
| 266 | eor r10,r10,r7,ror#2 @ F_00_19(B,C,D) |
| 267 | add r3,r3,r10 @ E+=F_00_19(B,C,D) |
| 268 | |
| 269 | ldr r8,.LK_20_39 @ [+15+16*4] |
| 270 | cmn sp,#0 @ [+3], clear carry to denote 20_39 |
| 271 | .L_20_39_or_60_79: |
| 272 | ldr r9,[r14,#15*4] |
| 273 | ldr r10,[r14,#13*4] |
| 274 | ldr r11,[r14,#7*4] |
| 275 | add r7,r8,r7,ror#2 @ E+=K_xx_xx |
| 276 | ldr r12,[r14,#2*4] |
| 277 | eor r9,r9,r10 |
| 278 | eor r11,r11,r12 @ 1 cycle stall |
| 279 | eor r10,r5,r6 @ F_xx_xx |
| 280 | mov r9,r9,ror#31 |
| 281 | add r7,r7,r3,ror#27 @ E+=ROR(A,27) |
| 282 | eor r9,r9,r11,ror#31 |
| 283 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 284 | eor r10,r4,r10,ror#2 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 285 | @ F_xx_xx |
| 286 | add r7,r7,r9 @ E+=X[i] |
| 287 | add r7,r7,r10 @ E+=F_20_39(B,C,D) |
| 288 | ldr r9,[r14,#15*4] |
| 289 | ldr r10,[r14,#13*4] |
| 290 | ldr r11,[r14,#7*4] |
| 291 | add r6,r8,r6,ror#2 @ E+=K_xx_xx |
| 292 | ldr r12,[r14,#2*4] |
| 293 | eor r9,r9,r10 |
| 294 | eor r11,r11,r12 @ 1 cycle stall |
| 295 | eor r10,r4,r5 @ F_xx_xx |
| 296 | mov r9,r9,ror#31 |
| 297 | add r6,r6,r7,ror#27 @ E+=ROR(A,27) |
| 298 | eor r9,r9,r11,ror#31 |
| 299 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 300 | eor r10,r3,r10,ror#2 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 301 | @ F_xx_xx |
| 302 | add r6,r6,r9 @ E+=X[i] |
| 303 | add r6,r6,r10 @ E+=F_20_39(B,C,D) |
| 304 | ldr r9,[r14,#15*4] |
| 305 | ldr r10,[r14,#13*4] |
| 306 | ldr r11,[r14,#7*4] |
| 307 | add r5,r8,r5,ror#2 @ E+=K_xx_xx |
| 308 | ldr r12,[r14,#2*4] |
| 309 | eor r9,r9,r10 |
| 310 | eor r11,r11,r12 @ 1 cycle stall |
| 311 | eor r10,r3,r4 @ F_xx_xx |
| 312 | mov r9,r9,ror#31 |
| 313 | add r5,r5,r6,ror#27 @ E+=ROR(A,27) |
| 314 | eor r9,r9,r11,ror#31 |
| 315 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 316 | eor r10,r7,r10,ror#2 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 317 | @ F_xx_xx |
| 318 | add r5,r5,r9 @ E+=X[i] |
| 319 | add r5,r5,r10 @ E+=F_20_39(B,C,D) |
| 320 | ldr r9,[r14,#15*4] |
| 321 | ldr r10,[r14,#13*4] |
| 322 | ldr r11,[r14,#7*4] |
| 323 | add r4,r8,r4,ror#2 @ E+=K_xx_xx |
| 324 | ldr r12,[r14,#2*4] |
| 325 | eor r9,r9,r10 |
| 326 | eor r11,r11,r12 @ 1 cycle stall |
| 327 | eor r10,r7,r3 @ F_xx_xx |
| 328 | mov r9,r9,ror#31 |
| 329 | add r4,r4,r5,ror#27 @ E+=ROR(A,27) |
| 330 | eor r9,r9,r11,ror#31 |
| 331 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 332 | eor r10,r6,r10,ror#2 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 333 | @ F_xx_xx |
| 334 | add r4,r4,r9 @ E+=X[i] |
| 335 | add r4,r4,r10 @ E+=F_20_39(B,C,D) |
| 336 | ldr r9,[r14,#15*4] |
| 337 | ldr r10,[r14,#13*4] |
| 338 | ldr r11,[r14,#7*4] |
| 339 | add r3,r8,r3,ror#2 @ E+=K_xx_xx |
| 340 | ldr r12,[r14,#2*4] |
| 341 | eor r9,r9,r10 |
| 342 | eor r11,r11,r12 @ 1 cycle stall |
| 343 | eor r10,r6,r7 @ F_xx_xx |
| 344 | mov r9,r9,ror#31 |
| 345 | add r3,r3,r4,ror#27 @ E+=ROR(A,27) |
| 346 | eor r9,r9,r11,ror#31 |
| 347 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 348 | eor r10,r5,r10,ror#2 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 349 | @ F_xx_xx |
| 350 | add r3,r3,r9 @ E+=X[i] |
| 351 | add r3,r3,r10 @ E+=F_20_39(B,C,D) |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 352 | #if defined(__thumb2__) |
| 353 | mov r12,sp |
| 354 | teq r14,r12 |
| 355 | #else |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 356 | teq r14,sp @ preserve carry |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 357 | #endif |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 358 | bne .L_20_39_or_60_79 @ [+((12+3)*5+2)*4] |
| 359 | bcs .L_done @ [+((12+3)*5+2)*4], spare 300 bytes |
| 360 | |
| 361 | ldr r8,.LK_40_59 |
| 362 | sub sp,sp,#20*4 @ [+2] |
| 363 | .L_40_59: |
| 364 | ldr r9,[r14,#15*4] |
| 365 | ldr r10,[r14,#13*4] |
| 366 | ldr r11,[r14,#7*4] |
| 367 | add r7,r8,r7,ror#2 @ E+=K_xx_xx |
| 368 | ldr r12,[r14,#2*4] |
| 369 | eor r9,r9,r10 |
| 370 | eor r11,r11,r12 @ 1 cycle stall |
| 371 | eor r10,r5,r6 @ F_xx_xx |
| 372 | mov r9,r9,ror#31 |
| 373 | add r7,r7,r3,ror#27 @ E+=ROR(A,27) |
| 374 | eor r9,r9,r11,ror#31 |
| 375 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 376 | and r10,r4,r10,ror#2 @ F_xx_xx |
| 377 | and r11,r5,r6 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 378 | add r7,r7,r9 @ E+=X[i] |
| 379 | add r7,r7,r10 @ E+=F_40_59(B,C,D) |
| 380 | add r7,r7,r11,ror#2 |
| 381 | ldr r9,[r14,#15*4] |
| 382 | ldr r10,[r14,#13*4] |
| 383 | ldr r11,[r14,#7*4] |
| 384 | add r6,r8,r6,ror#2 @ E+=K_xx_xx |
| 385 | ldr r12,[r14,#2*4] |
| 386 | eor r9,r9,r10 |
| 387 | eor r11,r11,r12 @ 1 cycle stall |
| 388 | eor r10,r4,r5 @ F_xx_xx |
| 389 | mov r9,r9,ror#31 |
| 390 | add r6,r6,r7,ror#27 @ E+=ROR(A,27) |
| 391 | eor r9,r9,r11,ror#31 |
| 392 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 393 | and r10,r3,r10,ror#2 @ F_xx_xx |
| 394 | and r11,r4,r5 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 395 | add r6,r6,r9 @ E+=X[i] |
| 396 | add r6,r6,r10 @ E+=F_40_59(B,C,D) |
| 397 | add r6,r6,r11,ror#2 |
| 398 | ldr r9,[r14,#15*4] |
| 399 | ldr r10,[r14,#13*4] |
| 400 | ldr r11,[r14,#7*4] |
| 401 | add r5,r8,r5,ror#2 @ E+=K_xx_xx |
| 402 | ldr r12,[r14,#2*4] |
| 403 | eor r9,r9,r10 |
| 404 | eor r11,r11,r12 @ 1 cycle stall |
| 405 | eor r10,r3,r4 @ F_xx_xx |
| 406 | mov r9,r9,ror#31 |
| 407 | add r5,r5,r6,ror#27 @ E+=ROR(A,27) |
| 408 | eor r9,r9,r11,ror#31 |
| 409 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 410 | and r10,r7,r10,ror#2 @ F_xx_xx |
| 411 | and r11,r3,r4 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 412 | add r5,r5,r9 @ E+=X[i] |
| 413 | add r5,r5,r10 @ E+=F_40_59(B,C,D) |
| 414 | add r5,r5,r11,ror#2 |
| 415 | ldr r9,[r14,#15*4] |
| 416 | ldr r10,[r14,#13*4] |
| 417 | ldr r11,[r14,#7*4] |
| 418 | add r4,r8,r4,ror#2 @ E+=K_xx_xx |
| 419 | ldr r12,[r14,#2*4] |
| 420 | eor r9,r9,r10 |
| 421 | eor r11,r11,r12 @ 1 cycle stall |
| 422 | eor r10,r7,r3 @ F_xx_xx |
| 423 | mov r9,r9,ror#31 |
| 424 | add r4,r4,r5,ror#27 @ E+=ROR(A,27) |
| 425 | eor r9,r9,r11,ror#31 |
| 426 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 427 | and r10,r6,r10,ror#2 @ F_xx_xx |
| 428 | and r11,r7,r3 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 429 | add r4,r4,r9 @ E+=X[i] |
| 430 | add r4,r4,r10 @ E+=F_40_59(B,C,D) |
| 431 | add r4,r4,r11,ror#2 |
| 432 | ldr r9,[r14,#15*4] |
| 433 | ldr r10,[r14,#13*4] |
| 434 | ldr r11,[r14,#7*4] |
| 435 | add r3,r8,r3,ror#2 @ E+=K_xx_xx |
| 436 | ldr r12,[r14,#2*4] |
| 437 | eor r9,r9,r10 |
| 438 | eor r11,r11,r12 @ 1 cycle stall |
| 439 | eor r10,r6,r7 @ F_xx_xx |
| 440 | mov r9,r9,ror#31 |
| 441 | add r3,r3,r4,ror#27 @ E+=ROR(A,27) |
| 442 | eor r9,r9,r11,ror#31 |
| 443 | str r9,[r14,#-4]! |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 444 | and r10,r5,r10,ror#2 @ F_xx_xx |
| 445 | and r11,r6,r7 @ F_xx_xx |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 446 | add r3,r3,r9 @ E+=X[i] |
| 447 | add r3,r3,r10 @ E+=F_40_59(B,C,D) |
| 448 | add r3,r3,r11,ror#2 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 449 | #if defined(__thumb2__) |
| 450 | mov r12,sp |
| 451 | teq r14,r12 |
| 452 | #else |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 453 | teq r14,sp |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 454 | #endif |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 455 | bne .L_40_59 @ [+((12+5)*5+2)*4] |
| 456 | |
| 457 | ldr r8,.LK_60_79 |
| 458 | sub sp,sp,#20*4 |
| 459 | cmp sp,#0 @ set carry to denote 60_79 |
| 460 | b .L_20_39_or_60_79 @ [+4], spare 300 bytes |
| 461 | .L_done: |
| 462 | add sp,sp,#80*4 @ "deallocate" stack frame |
| 463 | ldmia r0,{r8,r9,r10,r11,r12} |
| 464 | add r3,r8,r3 |
| 465 | add r4,r9,r4 |
| 466 | add r5,r10,r5,ror#2 |
| 467 | add r6,r11,r6,ror#2 |
| 468 | add r7,r12,r7,ror#2 |
| 469 | stmia r0,{r3,r4,r5,r6,r7} |
| 470 | teq r1,r2 |
| 471 | bne .Lloop @ [+18], total 1307 |
| 472 | |
| 473 | #if __ARM_ARCH__>=5 |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 474 | ldmia sp!,{r4,r5,r6,r7,r8,r9,r10,r11,r12,pc} |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 475 | #else |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 476 | ldmia sp!,{r4,r5,r6,r7,r8,r9,r10,r11,r12,lr} |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 477 | tst lr,#1 |
| 478 | moveq pc,lr @ be binary compatible with V4, yet |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 479 | .word 0xe12fff1e @ interoperable with Thumb ISA:-) |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 480 | #endif |
| 481 | .size sha1_block_data_order,.-sha1_block_data_order |
| 482 | |
| 483 | .align 5 |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 484 | .LK_00_19:.word 0x5a827999 |
| 485 | .LK_20_39:.word 0x6ed9eba1 |
| 486 | .LK_40_59:.word 0x8f1bbcdc |
| 487 | .LK_60_79:.word 0xca62c1d6 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 488 | #if __ARM_MAX_ARCH__>=7 |
| 489 | .LOPENSSL_armcap: |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 490 | .word OPENSSL_armcap_P-.Lsha1_block |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 491 | #endif |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 492 | .byte 83,72,65,49,32,98,108,111,99,107,32,116,114,97,110,115,102,111,114,109,32,102,111,114,32,65,82,77,118,52,47,78,69,79,78,47,65,82,77,118,56,44,32,67,82,89,80,84,79,71,65,77,83,32,98,121,32,60,97,112,112,114,111,64,111,112,101,110,115,115,108,46,111,114,103,62,0 |
| 493 | .align 2 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 494 | .align 5 |
| 495 | #if __ARM_MAX_ARCH__>=7 |
| 496 | .arch armv7-a |
| 497 | .fpu neon |
| 498 | |
| 499 | .type sha1_block_data_order_neon,%function |
| 500 | .align 4 |
| 501 | sha1_block_data_order_neon: |
| 502 | .LNEON: |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 503 | stmdb sp!,{r4,r5,r6,r7,r8,r9,r10,r11,r12,lr} |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 504 | add r2,r1,r2,lsl#6 @ r2 to point at the end of r1 |
| 505 | @ dmb @ errata #451034 on early Cortex A8 |
| 506 | @ vstmdb sp!,{d8-d15} @ ABI specification says so |
| 507 | mov r14,sp |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 508 | sub r12,sp,#64 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 509 | adr r8,.LK_00_19 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 510 | bic r12,r12,#15 @ align for 128-bit stores |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 511 | |
| 512 | ldmia r0,{r3,r4,r5,r6,r7} @ load context |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 513 | mov sp,r12 @ alloca |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 514 | |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 515 | vld1.8 {q0,q1},[r1]! @ handles unaligned |
| 516 | veor q15,q15,q15 |
| 517 | vld1.8 {q2,q3},[r1]! |
| 518 | vld1.32 {d28[],d29[]},[r8,:32]! @ load K_00_19 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 519 | vrev32.8 q0,q0 @ yes, even on |
| 520 | vrev32.8 q1,q1 @ big-endian... |
| 521 | vrev32.8 q2,q2 |
| 522 | vadd.i32 q8,q0,q14 |
| 523 | vrev32.8 q3,q3 |
| 524 | vadd.i32 q9,q1,q14 |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 525 | vst1.32 {q8},[r12,:128]! |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 526 | vadd.i32 q10,q2,q14 |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 527 | vst1.32 {q9},[r12,:128]! |
| 528 | vst1.32 {q10},[r12,:128]! |
| 529 | ldr r9,[sp] @ big RAW stall |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 530 | |
| 531 | .Loop_neon: |
| 532 | vext.8 q8,q0,q1,#8 |
| 533 | bic r10,r6,r4 |
| 534 | add r7,r7,r9 |
| 535 | and r11,r5,r4 |
| 536 | vadd.i32 q13,q3,q14 |
| 537 | ldr r9,[sp,#4] |
| 538 | add r7,r7,r3,ror#27 |
| 539 | vext.8 q12,q3,q15,#4 |
| 540 | eor r11,r11,r10 |
| 541 | mov r4,r4,ror#2 |
| 542 | add r7,r7,r11 |
| 543 | veor q8,q8,q0 |
| 544 | bic r10,r5,r3 |
| 545 | add r6,r6,r9 |
| 546 | veor q12,q12,q2 |
| 547 | and r11,r4,r3 |
| 548 | ldr r9,[sp,#8] |
| 549 | veor q12,q12,q8 |
| 550 | add r6,r6,r7,ror#27 |
| 551 | eor r11,r11,r10 |
| 552 | vst1.32 {q13},[r12,:128]! |
| 553 | sub r12,r12,#64 |
| 554 | mov r3,r3,ror#2 |
| 555 | add r6,r6,r11 |
| 556 | vext.8 q13,q15,q12,#4 |
| 557 | bic r10,r4,r7 |
| 558 | add r5,r5,r9 |
| 559 | vadd.i32 q8,q12,q12 |
| 560 | and r11,r3,r7 |
| 561 | ldr r9,[sp,#12] |
| 562 | vsri.32 q8,q12,#31 |
| 563 | add r5,r5,r6,ror#27 |
| 564 | eor r11,r11,r10 |
| 565 | mov r7,r7,ror#2 |
| 566 | vshr.u32 q12,q13,#30 |
| 567 | add r5,r5,r11 |
| 568 | bic r10,r3,r6 |
| 569 | vshl.u32 q13,q13,#2 |
| 570 | add r4,r4,r9 |
| 571 | and r11,r7,r6 |
| 572 | veor q8,q8,q12 |
| 573 | ldr r9,[sp,#16] |
| 574 | add r4,r4,r5,ror#27 |
| 575 | veor q8,q8,q13 |
| 576 | eor r11,r11,r10 |
| 577 | mov r6,r6,ror#2 |
| 578 | add r4,r4,r11 |
| 579 | vext.8 q9,q1,q2,#8 |
| 580 | bic r10,r7,r5 |
| 581 | add r3,r3,r9 |
| 582 | and r11,r6,r5 |
| 583 | vadd.i32 q13,q8,q14 |
| 584 | ldr r9,[sp,#20] |
| 585 | vld1.32 {d28[],d29[]},[r8,:32]! |
| 586 | add r3,r3,r4,ror#27 |
| 587 | vext.8 q12,q8,q15,#4 |
| 588 | eor r11,r11,r10 |
| 589 | mov r5,r5,ror#2 |
| 590 | add r3,r3,r11 |
| 591 | veor q9,q9,q1 |
| 592 | bic r10,r6,r4 |
| 593 | add r7,r7,r9 |
| 594 | veor q12,q12,q3 |
| 595 | and r11,r5,r4 |
| 596 | ldr r9,[sp,#24] |
| 597 | veor q12,q12,q9 |
| 598 | add r7,r7,r3,ror#27 |
| 599 | eor r11,r11,r10 |
| 600 | vst1.32 {q13},[r12,:128]! |
| 601 | mov r4,r4,ror#2 |
| 602 | add r7,r7,r11 |
| 603 | vext.8 q13,q15,q12,#4 |
| 604 | bic r10,r5,r3 |
| 605 | add r6,r6,r9 |
| 606 | vadd.i32 q9,q12,q12 |
| 607 | and r11,r4,r3 |
| 608 | ldr r9,[sp,#28] |
| 609 | vsri.32 q9,q12,#31 |
| 610 | add r6,r6,r7,ror#27 |
| 611 | eor r11,r11,r10 |
| 612 | mov r3,r3,ror#2 |
| 613 | vshr.u32 q12,q13,#30 |
| 614 | add r6,r6,r11 |
| 615 | bic r10,r4,r7 |
| 616 | vshl.u32 q13,q13,#2 |
| 617 | add r5,r5,r9 |
| 618 | and r11,r3,r7 |
| 619 | veor q9,q9,q12 |
| 620 | ldr r9,[sp,#32] |
| 621 | add r5,r5,r6,ror#27 |
| 622 | veor q9,q9,q13 |
| 623 | eor r11,r11,r10 |
| 624 | mov r7,r7,ror#2 |
| 625 | add r5,r5,r11 |
| 626 | vext.8 q10,q2,q3,#8 |
| 627 | bic r10,r3,r6 |
| 628 | add r4,r4,r9 |
| 629 | and r11,r7,r6 |
| 630 | vadd.i32 q13,q9,q14 |
| 631 | ldr r9,[sp,#36] |
| 632 | add r4,r4,r5,ror#27 |
| 633 | vext.8 q12,q9,q15,#4 |
| 634 | eor r11,r11,r10 |
| 635 | mov r6,r6,ror#2 |
| 636 | add r4,r4,r11 |
| 637 | veor q10,q10,q2 |
| 638 | bic r10,r7,r5 |
| 639 | add r3,r3,r9 |
| 640 | veor q12,q12,q8 |
| 641 | and r11,r6,r5 |
| 642 | ldr r9,[sp,#40] |
| 643 | veor q12,q12,q10 |
| 644 | add r3,r3,r4,ror#27 |
| 645 | eor r11,r11,r10 |
| 646 | vst1.32 {q13},[r12,:128]! |
| 647 | mov r5,r5,ror#2 |
| 648 | add r3,r3,r11 |
| 649 | vext.8 q13,q15,q12,#4 |
| 650 | bic r10,r6,r4 |
| 651 | add r7,r7,r9 |
| 652 | vadd.i32 q10,q12,q12 |
| 653 | and r11,r5,r4 |
| 654 | ldr r9,[sp,#44] |
| 655 | vsri.32 q10,q12,#31 |
| 656 | add r7,r7,r3,ror#27 |
| 657 | eor r11,r11,r10 |
| 658 | mov r4,r4,ror#2 |
| 659 | vshr.u32 q12,q13,#30 |
| 660 | add r7,r7,r11 |
| 661 | bic r10,r5,r3 |
| 662 | vshl.u32 q13,q13,#2 |
| 663 | add r6,r6,r9 |
| 664 | and r11,r4,r3 |
| 665 | veor q10,q10,q12 |
| 666 | ldr r9,[sp,#48] |
| 667 | add r6,r6,r7,ror#27 |
| 668 | veor q10,q10,q13 |
| 669 | eor r11,r11,r10 |
| 670 | mov r3,r3,ror#2 |
| 671 | add r6,r6,r11 |
| 672 | vext.8 q11,q3,q8,#8 |
| 673 | bic r10,r4,r7 |
| 674 | add r5,r5,r9 |
| 675 | and r11,r3,r7 |
| 676 | vadd.i32 q13,q10,q14 |
| 677 | ldr r9,[sp,#52] |
| 678 | add r5,r5,r6,ror#27 |
| 679 | vext.8 q12,q10,q15,#4 |
| 680 | eor r11,r11,r10 |
| 681 | mov r7,r7,ror#2 |
| 682 | add r5,r5,r11 |
| 683 | veor q11,q11,q3 |
| 684 | bic r10,r3,r6 |
| 685 | add r4,r4,r9 |
| 686 | veor q12,q12,q9 |
| 687 | and r11,r7,r6 |
| 688 | ldr r9,[sp,#56] |
| 689 | veor q12,q12,q11 |
| 690 | add r4,r4,r5,ror#27 |
| 691 | eor r11,r11,r10 |
| 692 | vst1.32 {q13},[r12,:128]! |
| 693 | mov r6,r6,ror#2 |
| 694 | add r4,r4,r11 |
| 695 | vext.8 q13,q15,q12,#4 |
| 696 | bic r10,r7,r5 |
| 697 | add r3,r3,r9 |
| 698 | vadd.i32 q11,q12,q12 |
| 699 | and r11,r6,r5 |
| 700 | ldr r9,[sp,#60] |
| 701 | vsri.32 q11,q12,#31 |
| 702 | add r3,r3,r4,ror#27 |
| 703 | eor r11,r11,r10 |
| 704 | mov r5,r5,ror#2 |
| 705 | vshr.u32 q12,q13,#30 |
| 706 | add r3,r3,r11 |
| 707 | bic r10,r6,r4 |
| 708 | vshl.u32 q13,q13,#2 |
| 709 | add r7,r7,r9 |
| 710 | and r11,r5,r4 |
| 711 | veor q11,q11,q12 |
| 712 | ldr r9,[sp,#0] |
| 713 | add r7,r7,r3,ror#27 |
| 714 | veor q11,q11,q13 |
| 715 | eor r11,r11,r10 |
| 716 | mov r4,r4,ror#2 |
| 717 | add r7,r7,r11 |
| 718 | vext.8 q12,q10,q11,#8 |
| 719 | bic r10,r5,r3 |
| 720 | add r6,r6,r9 |
| 721 | and r11,r4,r3 |
| 722 | veor q0,q0,q8 |
| 723 | ldr r9,[sp,#4] |
| 724 | add r6,r6,r7,ror#27 |
| 725 | veor q0,q0,q1 |
| 726 | eor r11,r11,r10 |
| 727 | mov r3,r3,ror#2 |
| 728 | vadd.i32 q13,q11,q14 |
| 729 | add r6,r6,r11 |
| 730 | bic r10,r4,r7 |
| 731 | veor q12,q12,q0 |
| 732 | add r5,r5,r9 |
| 733 | and r11,r3,r7 |
| 734 | vshr.u32 q0,q12,#30 |
| 735 | ldr r9,[sp,#8] |
| 736 | add r5,r5,r6,ror#27 |
| 737 | vst1.32 {q13},[r12,:128]! |
| 738 | sub r12,r12,#64 |
| 739 | eor r11,r11,r10 |
| 740 | mov r7,r7,ror#2 |
| 741 | vsli.32 q0,q12,#2 |
| 742 | add r5,r5,r11 |
| 743 | bic r10,r3,r6 |
| 744 | add r4,r4,r9 |
| 745 | and r11,r7,r6 |
| 746 | ldr r9,[sp,#12] |
| 747 | add r4,r4,r5,ror#27 |
| 748 | eor r11,r11,r10 |
| 749 | mov r6,r6,ror#2 |
| 750 | add r4,r4,r11 |
| 751 | bic r10,r7,r5 |
| 752 | add r3,r3,r9 |
| 753 | and r11,r6,r5 |
| 754 | ldr r9,[sp,#16] |
| 755 | add r3,r3,r4,ror#27 |
| 756 | eor r11,r11,r10 |
| 757 | mov r5,r5,ror#2 |
| 758 | add r3,r3,r11 |
| 759 | vext.8 q12,q11,q0,#8 |
| 760 | eor r10,r4,r6 |
| 761 | add r7,r7,r9 |
| 762 | ldr r9,[sp,#20] |
| 763 | veor q1,q1,q9 |
| 764 | eor r11,r10,r5 |
| 765 | add r7,r7,r3,ror#27 |
| 766 | veor q1,q1,q2 |
| 767 | mov r4,r4,ror#2 |
| 768 | add r7,r7,r11 |
| 769 | vadd.i32 q13,q0,q14 |
| 770 | eor r10,r3,r5 |
| 771 | add r6,r6,r9 |
| 772 | veor q12,q12,q1 |
| 773 | ldr r9,[sp,#24] |
| 774 | eor r11,r10,r4 |
| 775 | vshr.u32 q1,q12,#30 |
| 776 | add r6,r6,r7,ror#27 |
| 777 | mov r3,r3,ror#2 |
| 778 | vst1.32 {q13},[r12,:128]! |
| 779 | add r6,r6,r11 |
| 780 | eor r10,r7,r4 |
| 781 | vsli.32 q1,q12,#2 |
| 782 | add r5,r5,r9 |
| 783 | ldr r9,[sp,#28] |
| 784 | eor r11,r10,r3 |
| 785 | add r5,r5,r6,ror#27 |
| 786 | mov r7,r7,ror#2 |
| 787 | add r5,r5,r11 |
| 788 | eor r10,r6,r3 |
| 789 | add r4,r4,r9 |
| 790 | ldr r9,[sp,#32] |
| 791 | eor r11,r10,r7 |
| 792 | add r4,r4,r5,ror#27 |
| 793 | mov r6,r6,ror#2 |
| 794 | add r4,r4,r11 |
| 795 | vext.8 q12,q0,q1,#8 |
| 796 | eor r10,r5,r7 |
| 797 | add r3,r3,r9 |
| 798 | ldr r9,[sp,#36] |
| 799 | veor q2,q2,q10 |
| 800 | eor r11,r10,r6 |
| 801 | add r3,r3,r4,ror#27 |
| 802 | veor q2,q2,q3 |
| 803 | mov r5,r5,ror#2 |
| 804 | add r3,r3,r11 |
| 805 | vadd.i32 q13,q1,q14 |
| 806 | eor r10,r4,r6 |
| 807 | vld1.32 {d28[],d29[]},[r8,:32]! |
| 808 | add r7,r7,r9 |
| 809 | veor q12,q12,q2 |
| 810 | ldr r9,[sp,#40] |
| 811 | eor r11,r10,r5 |
| 812 | vshr.u32 q2,q12,#30 |
| 813 | add r7,r7,r3,ror#27 |
| 814 | mov r4,r4,ror#2 |
| 815 | vst1.32 {q13},[r12,:128]! |
| 816 | add r7,r7,r11 |
| 817 | eor r10,r3,r5 |
| 818 | vsli.32 q2,q12,#2 |
| 819 | add r6,r6,r9 |
| 820 | ldr r9,[sp,#44] |
| 821 | eor r11,r10,r4 |
| 822 | add r6,r6,r7,ror#27 |
| 823 | mov r3,r3,ror#2 |
| 824 | add r6,r6,r11 |
| 825 | eor r10,r7,r4 |
| 826 | add r5,r5,r9 |
| 827 | ldr r9,[sp,#48] |
| 828 | eor r11,r10,r3 |
| 829 | add r5,r5,r6,ror#27 |
| 830 | mov r7,r7,ror#2 |
| 831 | add r5,r5,r11 |
| 832 | vext.8 q12,q1,q2,#8 |
| 833 | eor r10,r6,r3 |
| 834 | add r4,r4,r9 |
| 835 | ldr r9,[sp,#52] |
| 836 | veor q3,q3,q11 |
| 837 | eor r11,r10,r7 |
| 838 | add r4,r4,r5,ror#27 |
| 839 | veor q3,q3,q8 |
| 840 | mov r6,r6,ror#2 |
| 841 | add r4,r4,r11 |
| 842 | vadd.i32 q13,q2,q14 |
| 843 | eor r10,r5,r7 |
| 844 | add r3,r3,r9 |
| 845 | veor q12,q12,q3 |
| 846 | ldr r9,[sp,#56] |
| 847 | eor r11,r10,r6 |
| 848 | vshr.u32 q3,q12,#30 |
| 849 | add r3,r3,r4,ror#27 |
| 850 | mov r5,r5,ror#2 |
| 851 | vst1.32 {q13},[r12,:128]! |
| 852 | add r3,r3,r11 |
| 853 | eor r10,r4,r6 |
| 854 | vsli.32 q3,q12,#2 |
| 855 | add r7,r7,r9 |
| 856 | ldr r9,[sp,#60] |
| 857 | eor r11,r10,r5 |
| 858 | add r7,r7,r3,ror#27 |
| 859 | mov r4,r4,ror#2 |
| 860 | add r7,r7,r11 |
| 861 | eor r10,r3,r5 |
| 862 | add r6,r6,r9 |
| 863 | ldr r9,[sp,#0] |
| 864 | eor r11,r10,r4 |
| 865 | add r6,r6,r7,ror#27 |
| 866 | mov r3,r3,ror#2 |
| 867 | add r6,r6,r11 |
| 868 | vext.8 q12,q2,q3,#8 |
| 869 | eor r10,r7,r4 |
| 870 | add r5,r5,r9 |
| 871 | ldr r9,[sp,#4] |
| 872 | veor q8,q8,q0 |
| 873 | eor r11,r10,r3 |
| 874 | add r5,r5,r6,ror#27 |
| 875 | veor q8,q8,q9 |
| 876 | mov r7,r7,ror#2 |
| 877 | add r5,r5,r11 |
| 878 | vadd.i32 q13,q3,q14 |
| 879 | eor r10,r6,r3 |
| 880 | add r4,r4,r9 |
| 881 | veor q12,q12,q8 |
| 882 | ldr r9,[sp,#8] |
| 883 | eor r11,r10,r7 |
| 884 | vshr.u32 q8,q12,#30 |
| 885 | add r4,r4,r5,ror#27 |
| 886 | mov r6,r6,ror#2 |
| 887 | vst1.32 {q13},[r12,:128]! |
| 888 | sub r12,r12,#64 |
| 889 | add r4,r4,r11 |
| 890 | eor r10,r5,r7 |
| 891 | vsli.32 q8,q12,#2 |
| 892 | add r3,r3,r9 |
| 893 | ldr r9,[sp,#12] |
| 894 | eor r11,r10,r6 |
| 895 | add r3,r3,r4,ror#27 |
| 896 | mov r5,r5,ror#2 |
| 897 | add r3,r3,r11 |
| 898 | eor r10,r4,r6 |
| 899 | add r7,r7,r9 |
| 900 | ldr r9,[sp,#16] |
| 901 | eor r11,r10,r5 |
| 902 | add r7,r7,r3,ror#27 |
| 903 | mov r4,r4,ror#2 |
| 904 | add r7,r7,r11 |
| 905 | vext.8 q12,q3,q8,#8 |
| 906 | eor r10,r3,r5 |
| 907 | add r6,r6,r9 |
| 908 | ldr r9,[sp,#20] |
| 909 | veor q9,q9,q1 |
| 910 | eor r11,r10,r4 |
| 911 | add r6,r6,r7,ror#27 |
| 912 | veor q9,q9,q10 |
| 913 | mov r3,r3,ror#2 |
| 914 | add r6,r6,r11 |
| 915 | vadd.i32 q13,q8,q14 |
| 916 | eor r10,r7,r4 |
| 917 | add r5,r5,r9 |
| 918 | veor q12,q12,q9 |
| 919 | ldr r9,[sp,#24] |
| 920 | eor r11,r10,r3 |
| 921 | vshr.u32 q9,q12,#30 |
| 922 | add r5,r5,r6,ror#27 |
| 923 | mov r7,r7,ror#2 |
| 924 | vst1.32 {q13},[r12,:128]! |
| 925 | add r5,r5,r11 |
| 926 | eor r10,r6,r3 |
| 927 | vsli.32 q9,q12,#2 |
| 928 | add r4,r4,r9 |
| 929 | ldr r9,[sp,#28] |
| 930 | eor r11,r10,r7 |
| 931 | add r4,r4,r5,ror#27 |
| 932 | mov r6,r6,ror#2 |
| 933 | add r4,r4,r11 |
| 934 | eor r10,r5,r7 |
| 935 | add r3,r3,r9 |
| 936 | ldr r9,[sp,#32] |
| 937 | eor r11,r10,r6 |
| 938 | add r3,r3,r4,ror#27 |
| 939 | mov r5,r5,ror#2 |
| 940 | add r3,r3,r11 |
| 941 | vext.8 q12,q8,q9,#8 |
| 942 | add r7,r7,r9 |
| 943 | and r10,r5,r6 |
| 944 | ldr r9,[sp,#36] |
| 945 | veor q10,q10,q2 |
| 946 | add r7,r7,r3,ror#27 |
| 947 | eor r11,r5,r6 |
| 948 | veor q10,q10,q11 |
| 949 | add r7,r7,r10 |
| 950 | and r11,r11,r4 |
| 951 | vadd.i32 q13,q9,q14 |
| 952 | mov r4,r4,ror#2 |
| 953 | add r7,r7,r11 |
| 954 | veor q12,q12,q10 |
| 955 | add r6,r6,r9 |
| 956 | and r10,r4,r5 |
| 957 | vshr.u32 q10,q12,#30 |
| 958 | ldr r9,[sp,#40] |
| 959 | add r6,r6,r7,ror#27 |
| 960 | vst1.32 {q13},[r12,:128]! |
| 961 | eor r11,r4,r5 |
| 962 | add r6,r6,r10 |
| 963 | vsli.32 q10,q12,#2 |
| 964 | and r11,r11,r3 |
| 965 | mov r3,r3,ror#2 |
| 966 | add r6,r6,r11 |
| 967 | add r5,r5,r9 |
| 968 | and r10,r3,r4 |
| 969 | ldr r9,[sp,#44] |
| 970 | add r5,r5,r6,ror#27 |
| 971 | eor r11,r3,r4 |
| 972 | add r5,r5,r10 |
| 973 | and r11,r11,r7 |
| 974 | mov r7,r7,ror#2 |
| 975 | add r5,r5,r11 |
| 976 | add r4,r4,r9 |
| 977 | and r10,r7,r3 |
| 978 | ldr r9,[sp,#48] |
| 979 | add r4,r4,r5,ror#27 |
| 980 | eor r11,r7,r3 |
| 981 | add r4,r4,r10 |
| 982 | and r11,r11,r6 |
| 983 | mov r6,r6,ror#2 |
| 984 | add r4,r4,r11 |
| 985 | vext.8 q12,q9,q10,#8 |
| 986 | add r3,r3,r9 |
| 987 | and r10,r6,r7 |
| 988 | ldr r9,[sp,#52] |
| 989 | veor q11,q11,q3 |
| 990 | add r3,r3,r4,ror#27 |
| 991 | eor r11,r6,r7 |
| 992 | veor q11,q11,q0 |
| 993 | add r3,r3,r10 |
| 994 | and r11,r11,r5 |
| 995 | vadd.i32 q13,q10,q14 |
| 996 | mov r5,r5,ror#2 |
| 997 | vld1.32 {d28[],d29[]},[r8,:32]! |
| 998 | add r3,r3,r11 |
| 999 | veor q12,q12,q11 |
| 1000 | add r7,r7,r9 |
| 1001 | and r10,r5,r6 |
| 1002 | vshr.u32 q11,q12,#30 |
| 1003 | ldr r9,[sp,#56] |
| 1004 | add r7,r7,r3,ror#27 |
| 1005 | vst1.32 {q13},[r12,:128]! |
| 1006 | eor r11,r5,r6 |
| 1007 | add r7,r7,r10 |
| 1008 | vsli.32 q11,q12,#2 |
| 1009 | and r11,r11,r4 |
| 1010 | mov r4,r4,ror#2 |
| 1011 | add r7,r7,r11 |
| 1012 | add r6,r6,r9 |
| 1013 | and r10,r4,r5 |
| 1014 | ldr r9,[sp,#60] |
| 1015 | add r6,r6,r7,ror#27 |
| 1016 | eor r11,r4,r5 |
| 1017 | add r6,r6,r10 |
| 1018 | and r11,r11,r3 |
| 1019 | mov r3,r3,ror#2 |
| 1020 | add r6,r6,r11 |
| 1021 | add r5,r5,r9 |
| 1022 | and r10,r3,r4 |
| 1023 | ldr r9,[sp,#0] |
| 1024 | add r5,r5,r6,ror#27 |
| 1025 | eor r11,r3,r4 |
| 1026 | add r5,r5,r10 |
| 1027 | and r11,r11,r7 |
| 1028 | mov r7,r7,ror#2 |
| 1029 | add r5,r5,r11 |
| 1030 | vext.8 q12,q10,q11,#8 |
| 1031 | add r4,r4,r9 |
| 1032 | and r10,r7,r3 |
| 1033 | ldr r9,[sp,#4] |
| 1034 | veor q0,q0,q8 |
| 1035 | add r4,r4,r5,ror#27 |
| 1036 | eor r11,r7,r3 |
| 1037 | veor q0,q0,q1 |
| 1038 | add r4,r4,r10 |
| 1039 | and r11,r11,r6 |
| 1040 | vadd.i32 q13,q11,q14 |
| 1041 | mov r6,r6,ror#2 |
| 1042 | add r4,r4,r11 |
| 1043 | veor q12,q12,q0 |
| 1044 | add r3,r3,r9 |
| 1045 | and r10,r6,r7 |
| 1046 | vshr.u32 q0,q12,#30 |
| 1047 | ldr r9,[sp,#8] |
| 1048 | add r3,r3,r4,ror#27 |
| 1049 | vst1.32 {q13},[r12,:128]! |
| 1050 | sub r12,r12,#64 |
| 1051 | eor r11,r6,r7 |
| 1052 | add r3,r3,r10 |
| 1053 | vsli.32 q0,q12,#2 |
| 1054 | and r11,r11,r5 |
| 1055 | mov r5,r5,ror#2 |
| 1056 | add r3,r3,r11 |
| 1057 | add r7,r7,r9 |
| 1058 | and r10,r5,r6 |
| 1059 | ldr r9,[sp,#12] |
| 1060 | add r7,r7,r3,ror#27 |
| 1061 | eor r11,r5,r6 |
| 1062 | add r7,r7,r10 |
| 1063 | and r11,r11,r4 |
| 1064 | mov r4,r4,ror#2 |
| 1065 | add r7,r7,r11 |
| 1066 | add r6,r6,r9 |
| 1067 | and r10,r4,r5 |
| 1068 | ldr r9,[sp,#16] |
| 1069 | add r6,r6,r7,ror#27 |
| 1070 | eor r11,r4,r5 |
| 1071 | add r6,r6,r10 |
| 1072 | and r11,r11,r3 |
| 1073 | mov r3,r3,ror#2 |
| 1074 | add r6,r6,r11 |
| 1075 | vext.8 q12,q11,q0,#8 |
| 1076 | add r5,r5,r9 |
| 1077 | and r10,r3,r4 |
| 1078 | ldr r9,[sp,#20] |
| 1079 | veor q1,q1,q9 |
| 1080 | add r5,r5,r6,ror#27 |
| 1081 | eor r11,r3,r4 |
| 1082 | veor q1,q1,q2 |
| 1083 | add r5,r5,r10 |
| 1084 | and r11,r11,r7 |
| 1085 | vadd.i32 q13,q0,q14 |
| 1086 | mov r7,r7,ror#2 |
| 1087 | add r5,r5,r11 |
| 1088 | veor q12,q12,q1 |
| 1089 | add r4,r4,r9 |
| 1090 | and r10,r7,r3 |
| 1091 | vshr.u32 q1,q12,#30 |
| 1092 | ldr r9,[sp,#24] |
| 1093 | add r4,r4,r5,ror#27 |
| 1094 | vst1.32 {q13},[r12,:128]! |
| 1095 | eor r11,r7,r3 |
| 1096 | add r4,r4,r10 |
| 1097 | vsli.32 q1,q12,#2 |
| 1098 | and r11,r11,r6 |
| 1099 | mov r6,r6,ror#2 |
| 1100 | add r4,r4,r11 |
| 1101 | add r3,r3,r9 |
| 1102 | and r10,r6,r7 |
| 1103 | ldr r9,[sp,#28] |
| 1104 | add r3,r3,r4,ror#27 |
| 1105 | eor r11,r6,r7 |
| 1106 | add r3,r3,r10 |
| 1107 | and r11,r11,r5 |
| 1108 | mov r5,r5,ror#2 |
| 1109 | add r3,r3,r11 |
| 1110 | add r7,r7,r9 |
| 1111 | and r10,r5,r6 |
| 1112 | ldr r9,[sp,#32] |
| 1113 | add r7,r7,r3,ror#27 |
| 1114 | eor r11,r5,r6 |
| 1115 | add r7,r7,r10 |
| 1116 | and r11,r11,r4 |
| 1117 | mov r4,r4,ror#2 |
| 1118 | add r7,r7,r11 |
| 1119 | vext.8 q12,q0,q1,#8 |
| 1120 | add r6,r6,r9 |
| 1121 | and r10,r4,r5 |
| 1122 | ldr r9,[sp,#36] |
| 1123 | veor q2,q2,q10 |
| 1124 | add r6,r6,r7,ror#27 |
| 1125 | eor r11,r4,r5 |
| 1126 | veor q2,q2,q3 |
| 1127 | add r6,r6,r10 |
| 1128 | and r11,r11,r3 |
| 1129 | vadd.i32 q13,q1,q14 |
| 1130 | mov r3,r3,ror#2 |
| 1131 | add r6,r6,r11 |
| 1132 | veor q12,q12,q2 |
| 1133 | add r5,r5,r9 |
| 1134 | and r10,r3,r4 |
| 1135 | vshr.u32 q2,q12,#30 |
| 1136 | ldr r9,[sp,#40] |
| 1137 | add r5,r5,r6,ror#27 |
| 1138 | vst1.32 {q13},[r12,:128]! |
| 1139 | eor r11,r3,r4 |
| 1140 | add r5,r5,r10 |
| 1141 | vsli.32 q2,q12,#2 |
| 1142 | and r11,r11,r7 |
| 1143 | mov r7,r7,ror#2 |
| 1144 | add r5,r5,r11 |
| 1145 | add r4,r4,r9 |
| 1146 | and r10,r7,r3 |
| 1147 | ldr r9,[sp,#44] |
| 1148 | add r4,r4,r5,ror#27 |
| 1149 | eor r11,r7,r3 |
| 1150 | add r4,r4,r10 |
| 1151 | and r11,r11,r6 |
| 1152 | mov r6,r6,ror#2 |
| 1153 | add r4,r4,r11 |
| 1154 | add r3,r3,r9 |
| 1155 | and r10,r6,r7 |
| 1156 | ldr r9,[sp,#48] |
| 1157 | add r3,r3,r4,ror#27 |
| 1158 | eor r11,r6,r7 |
| 1159 | add r3,r3,r10 |
| 1160 | and r11,r11,r5 |
| 1161 | mov r5,r5,ror#2 |
| 1162 | add r3,r3,r11 |
| 1163 | vext.8 q12,q1,q2,#8 |
| 1164 | eor r10,r4,r6 |
| 1165 | add r7,r7,r9 |
| 1166 | ldr r9,[sp,#52] |
| 1167 | veor q3,q3,q11 |
| 1168 | eor r11,r10,r5 |
| 1169 | add r7,r7,r3,ror#27 |
| 1170 | veor q3,q3,q8 |
| 1171 | mov r4,r4,ror#2 |
| 1172 | add r7,r7,r11 |
| 1173 | vadd.i32 q13,q2,q14 |
| 1174 | eor r10,r3,r5 |
| 1175 | add r6,r6,r9 |
| 1176 | veor q12,q12,q3 |
| 1177 | ldr r9,[sp,#56] |
| 1178 | eor r11,r10,r4 |
| 1179 | vshr.u32 q3,q12,#30 |
| 1180 | add r6,r6,r7,ror#27 |
| 1181 | mov r3,r3,ror#2 |
| 1182 | vst1.32 {q13},[r12,:128]! |
| 1183 | add r6,r6,r11 |
| 1184 | eor r10,r7,r4 |
| 1185 | vsli.32 q3,q12,#2 |
| 1186 | add r5,r5,r9 |
| 1187 | ldr r9,[sp,#60] |
| 1188 | eor r11,r10,r3 |
| 1189 | add r5,r5,r6,ror#27 |
| 1190 | mov r7,r7,ror#2 |
| 1191 | add r5,r5,r11 |
| 1192 | eor r10,r6,r3 |
| 1193 | add r4,r4,r9 |
| 1194 | ldr r9,[sp,#0] |
| 1195 | eor r11,r10,r7 |
| 1196 | add r4,r4,r5,ror#27 |
| 1197 | mov r6,r6,ror#2 |
| 1198 | add r4,r4,r11 |
| 1199 | vadd.i32 q13,q3,q14 |
| 1200 | eor r10,r5,r7 |
| 1201 | add r3,r3,r9 |
| 1202 | vst1.32 {q13},[r12,:128]! |
| 1203 | sub r12,r12,#64 |
| 1204 | teq r1,r2 |
| 1205 | sub r8,r8,#16 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1206 | it eq |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1207 | subeq r1,r1,#64 |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 1208 | vld1.8 {q0,q1},[r1]! |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1209 | ldr r9,[sp,#4] |
| 1210 | eor r11,r10,r6 |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 1211 | vld1.8 {q2,q3},[r1]! |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1212 | add r3,r3,r4,ror#27 |
| 1213 | mov r5,r5,ror#2 |
| 1214 | vld1.32 {d28[],d29[]},[r8,:32]! |
| 1215 | add r3,r3,r11 |
| 1216 | eor r10,r4,r6 |
| 1217 | vrev32.8 q0,q0 |
| 1218 | add r7,r7,r9 |
| 1219 | ldr r9,[sp,#8] |
| 1220 | eor r11,r10,r5 |
| 1221 | add r7,r7,r3,ror#27 |
| 1222 | mov r4,r4,ror#2 |
| 1223 | add r7,r7,r11 |
| 1224 | eor r10,r3,r5 |
| 1225 | add r6,r6,r9 |
| 1226 | ldr r9,[sp,#12] |
| 1227 | eor r11,r10,r4 |
| 1228 | add r6,r6,r7,ror#27 |
| 1229 | mov r3,r3,ror#2 |
| 1230 | add r6,r6,r11 |
| 1231 | eor r10,r7,r4 |
| 1232 | add r5,r5,r9 |
| 1233 | ldr r9,[sp,#16] |
| 1234 | eor r11,r10,r3 |
| 1235 | add r5,r5,r6,ror#27 |
| 1236 | mov r7,r7,ror#2 |
| 1237 | add r5,r5,r11 |
| 1238 | vrev32.8 q1,q1 |
| 1239 | eor r10,r6,r3 |
| 1240 | add r4,r4,r9 |
| 1241 | vadd.i32 q8,q0,q14 |
| 1242 | ldr r9,[sp,#20] |
| 1243 | eor r11,r10,r7 |
| 1244 | vst1.32 {q8},[r12,:128]! |
| 1245 | add r4,r4,r5,ror#27 |
| 1246 | mov r6,r6,ror#2 |
| 1247 | add r4,r4,r11 |
| 1248 | eor r10,r5,r7 |
| 1249 | add r3,r3,r9 |
| 1250 | ldr r9,[sp,#24] |
| 1251 | eor r11,r10,r6 |
| 1252 | add r3,r3,r4,ror#27 |
| 1253 | mov r5,r5,ror#2 |
| 1254 | add r3,r3,r11 |
| 1255 | eor r10,r4,r6 |
| 1256 | add r7,r7,r9 |
| 1257 | ldr r9,[sp,#28] |
| 1258 | eor r11,r10,r5 |
| 1259 | add r7,r7,r3,ror#27 |
| 1260 | mov r4,r4,ror#2 |
| 1261 | add r7,r7,r11 |
| 1262 | eor r10,r3,r5 |
| 1263 | add r6,r6,r9 |
| 1264 | ldr r9,[sp,#32] |
| 1265 | eor r11,r10,r4 |
| 1266 | add r6,r6,r7,ror#27 |
| 1267 | mov r3,r3,ror#2 |
| 1268 | add r6,r6,r11 |
| 1269 | vrev32.8 q2,q2 |
| 1270 | eor r10,r7,r4 |
| 1271 | add r5,r5,r9 |
| 1272 | vadd.i32 q9,q1,q14 |
| 1273 | ldr r9,[sp,#36] |
| 1274 | eor r11,r10,r3 |
| 1275 | vst1.32 {q9},[r12,:128]! |
| 1276 | add r5,r5,r6,ror#27 |
| 1277 | mov r7,r7,ror#2 |
| 1278 | add r5,r5,r11 |
| 1279 | eor r10,r6,r3 |
| 1280 | add r4,r4,r9 |
| 1281 | ldr r9,[sp,#40] |
| 1282 | eor r11,r10,r7 |
| 1283 | add r4,r4,r5,ror#27 |
| 1284 | mov r6,r6,ror#2 |
| 1285 | add r4,r4,r11 |
| 1286 | eor r10,r5,r7 |
| 1287 | add r3,r3,r9 |
| 1288 | ldr r9,[sp,#44] |
| 1289 | eor r11,r10,r6 |
| 1290 | add r3,r3,r4,ror#27 |
| 1291 | mov r5,r5,ror#2 |
| 1292 | add r3,r3,r11 |
| 1293 | eor r10,r4,r6 |
| 1294 | add r7,r7,r9 |
| 1295 | ldr r9,[sp,#48] |
| 1296 | eor r11,r10,r5 |
| 1297 | add r7,r7,r3,ror#27 |
| 1298 | mov r4,r4,ror#2 |
| 1299 | add r7,r7,r11 |
| 1300 | vrev32.8 q3,q3 |
| 1301 | eor r10,r3,r5 |
| 1302 | add r6,r6,r9 |
| 1303 | vadd.i32 q10,q2,q14 |
| 1304 | ldr r9,[sp,#52] |
| 1305 | eor r11,r10,r4 |
| 1306 | vst1.32 {q10},[r12,:128]! |
| 1307 | add r6,r6,r7,ror#27 |
| 1308 | mov r3,r3,ror#2 |
| 1309 | add r6,r6,r11 |
| 1310 | eor r10,r7,r4 |
| 1311 | add r5,r5,r9 |
| 1312 | ldr r9,[sp,#56] |
| 1313 | eor r11,r10,r3 |
| 1314 | add r5,r5,r6,ror#27 |
| 1315 | mov r7,r7,ror#2 |
| 1316 | add r5,r5,r11 |
| 1317 | eor r10,r6,r3 |
| 1318 | add r4,r4,r9 |
| 1319 | ldr r9,[sp,#60] |
| 1320 | eor r11,r10,r7 |
| 1321 | add r4,r4,r5,ror#27 |
| 1322 | mov r6,r6,ror#2 |
| 1323 | add r4,r4,r11 |
| 1324 | eor r10,r5,r7 |
| 1325 | add r3,r3,r9 |
| 1326 | eor r11,r10,r6 |
| 1327 | add r3,r3,r4,ror#27 |
| 1328 | mov r5,r5,ror#2 |
| 1329 | add r3,r3,r11 |
| 1330 | ldmia r0,{r9,r10,r11,r12} @ accumulate context |
| 1331 | add r3,r3,r9 |
| 1332 | ldr r9,[r0,#16] |
| 1333 | add r4,r4,r10 |
| 1334 | add r5,r5,r11 |
| 1335 | add r6,r6,r12 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1336 | it eq |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1337 | moveq sp,r14 |
| 1338 | add r7,r7,r9 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1339 | it ne |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1340 | ldrne r9,[sp] |
| 1341 | stmia r0,{r3,r4,r5,r6,r7} |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1342 | itt ne |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1343 | addne r12,sp,#3*16 |
| 1344 | bne .Loop_neon |
| 1345 | |
| 1346 | @ vldmia sp!,{d8-d15} |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 1347 | ldmia sp!,{r4,r5,r6,r7,r8,r9,r10,r11,r12,pc} |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1348 | .size sha1_block_data_order_neon,.-sha1_block_data_order_neon |
| 1349 | #endif |
| 1350 | #if __ARM_MAX_ARCH__>=7 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1351 | |
| 1352 | # if defined(__thumb2__) |
| 1353 | # define INST(a,b,c,d) .byte c,d|0xf,a,b |
| 1354 | # else |
| 1355 | # define INST(a,b,c,d) .byte a,b,c,d|0x10 |
| 1356 | # endif |
| 1357 | |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1358 | .type sha1_block_data_order_armv8,%function |
| 1359 | .align 5 |
| 1360 | sha1_block_data_order_armv8: |
| 1361 | .LARMv8: |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 1362 | vstmdb sp!,{d8,d9,d10,d11,d12,d13,d14,d15} @ ABI specification says so |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1363 | |
| 1364 | veor q1,q1,q1 |
| 1365 | adr r3,.LK_00_19 |
| 1366 | vld1.32 {q0},[r0]! |
| 1367 | vld1.32 {d2[0]},[r0] |
| 1368 | sub r0,r0,#16 |
| 1369 | vld1.32 {d16[],d17[]},[r3,:32]! |
| 1370 | vld1.32 {d18[],d19[]},[r3,:32]! |
| 1371 | vld1.32 {d20[],d21[]},[r3,:32]! |
| 1372 | vld1.32 {d22[],d23[]},[r3,:32] |
| 1373 | |
| 1374 | .Loop_v8: |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 1375 | vld1.8 {q4,q5},[r1]! |
| 1376 | vld1.8 {q6,q7},[r1]! |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1377 | vrev32.8 q4,q4 |
| 1378 | vrev32.8 q5,q5 |
| 1379 | |
| 1380 | vadd.i32 q12,q8,q4 |
| 1381 | vrev32.8 q6,q6 |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 1382 | vmov q14,q0 @ offload |
| 1383 | subs r2,r2,#1 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1384 | |
| 1385 | vadd.i32 q13,q8,q5 |
| 1386 | vrev32.8 q7,q7 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1387 | INST(0xc0,0x62,0xb9,0xf3) @ sha1h q3,q0 @ 0 |
| 1388 | INST(0x68,0x0c,0x02,0xe2) @ sha1c q0,q1,q12 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1389 | vadd.i32 q12,q8,q6 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1390 | INST(0x4c,0x8c,0x3a,0xe2) @ sha1su0 q4,q5,q6 |
| 1391 | INST(0xc0,0x42,0xb9,0xf3) @ sha1h q2,q0 @ 1 |
| 1392 | INST(0x6a,0x0c,0x06,0xe2) @ sha1c q0,q3,q13 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1393 | vadd.i32 q13,q8,q7 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1394 | INST(0x8e,0x83,0xba,0xf3) @ sha1su1 q4,q7 |
| 1395 | INST(0x4e,0xac,0x3c,0xe2) @ sha1su0 q5,q6,q7 |
| 1396 | INST(0xc0,0x62,0xb9,0xf3) @ sha1h q3,q0 @ 2 |
| 1397 | INST(0x68,0x0c,0x04,0xe2) @ sha1c q0,q2,q12 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1398 | vadd.i32 q12,q8,q4 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1399 | INST(0x88,0xa3,0xba,0xf3) @ sha1su1 q5,q4 |
| 1400 | INST(0x48,0xcc,0x3e,0xe2) @ sha1su0 q6,q7,q4 |
| 1401 | INST(0xc0,0x42,0xb9,0xf3) @ sha1h q2,q0 @ 3 |
| 1402 | INST(0x6a,0x0c,0x06,0xe2) @ sha1c q0,q3,q13 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1403 | vadd.i32 q13,q9,q5 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1404 | INST(0x8a,0xc3,0xba,0xf3) @ sha1su1 q6,q5 |
| 1405 | INST(0x4a,0xec,0x38,0xe2) @ sha1su0 q7,q4,q5 |
| 1406 | INST(0xc0,0x62,0xb9,0xf3) @ sha1h q3,q0 @ 4 |
| 1407 | INST(0x68,0x0c,0x04,0xe2) @ sha1c q0,q2,q12 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1408 | vadd.i32 q12,q9,q6 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1409 | INST(0x8c,0xe3,0xba,0xf3) @ sha1su1 q7,q6 |
| 1410 | INST(0x4c,0x8c,0x3a,0xe2) @ sha1su0 q4,q5,q6 |
| 1411 | INST(0xc0,0x42,0xb9,0xf3) @ sha1h q2,q0 @ 5 |
| 1412 | INST(0x6a,0x0c,0x16,0xe2) @ sha1p q0,q3,q13 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1413 | vadd.i32 q13,q9,q7 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1414 | INST(0x8e,0x83,0xba,0xf3) @ sha1su1 q4,q7 |
| 1415 | INST(0x4e,0xac,0x3c,0xe2) @ sha1su0 q5,q6,q7 |
| 1416 | INST(0xc0,0x62,0xb9,0xf3) @ sha1h q3,q0 @ 6 |
| 1417 | INST(0x68,0x0c,0x14,0xe2) @ sha1p q0,q2,q12 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1418 | vadd.i32 q12,q9,q4 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1419 | INST(0x88,0xa3,0xba,0xf3) @ sha1su1 q5,q4 |
| 1420 | INST(0x48,0xcc,0x3e,0xe2) @ sha1su0 q6,q7,q4 |
| 1421 | INST(0xc0,0x42,0xb9,0xf3) @ sha1h q2,q0 @ 7 |
| 1422 | INST(0x6a,0x0c,0x16,0xe2) @ sha1p q0,q3,q13 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1423 | vadd.i32 q13,q9,q5 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1424 | INST(0x8a,0xc3,0xba,0xf3) @ sha1su1 q6,q5 |
| 1425 | INST(0x4a,0xec,0x38,0xe2) @ sha1su0 q7,q4,q5 |
| 1426 | INST(0xc0,0x62,0xb9,0xf3) @ sha1h q3,q0 @ 8 |
| 1427 | INST(0x68,0x0c,0x14,0xe2) @ sha1p q0,q2,q12 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1428 | vadd.i32 q12,q10,q6 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1429 | INST(0x8c,0xe3,0xba,0xf3) @ sha1su1 q7,q6 |
| 1430 | INST(0x4c,0x8c,0x3a,0xe2) @ sha1su0 q4,q5,q6 |
| 1431 | INST(0xc0,0x42,0xb9,0xf3) @ sha1h q2,q0 @ 9 |
| 1432 | INST(0x6a,0x0c,0x16,0xe2) @ sha1p q0,q3,q13 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1433 | vadd.i32 q13,q10,q7 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1434 | INST(0x8e,0x83,0xba,0xf3) @ sha1su1 q4,q7 |
| 1435 | INST(0x4e,0xac,0x3c,0xe2) @ sha1su0 q5,q6,q7 |
| 1436 | INST(0xc0,0x62,0xb9,0xf3) @ sha1h q3,q0 @ 10 |
| 1437 | INST(0x68,0x0c,0x24,0xe2) @ sha1m q0,q2,q12 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1438 | vadd.i32 q12,q10,q4 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1439 | INST(0x88,0xa3,0xba,0xf3) @ sha1su1 q5,q4 |
| 1440 | INST(0x48,0xcc,0x3e,0xe2) @ sha1su0 q6,q7,q4 |
| 1441 | INST(0xc0,0x42,0xb9,0xf3) @ sha1h q2,q0 @ 11 |
| 1442 | INST(0x6a,0x0c,0x26,0xe2) @ sha1m q0,q3,q13 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1443 | vadd.i32 q13,q10,q5 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1444 | INST(0x8a,0xc3,0xba,0xf3) @ sha1su1 q6,q5 |
| 1445 | INST(0x4a,0xec,0x38,0xe2) @ sha1su0 q7,q4,q5 |
| 1446 | INST(0xc0,0x62,0xb9,0xf3) @ sha1h q3,q0 @ 12 |
| 1447 | INST(0x68,0x0c,0x24,0xe2) @ sha1m q0,q2,q12 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1448 | vadd.i32 q12,q10,q6 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1449 | INST(0x8c,0xe3,0xba,0xf3) @ sha1su1 q7,q6 |
| 1450 | INST(0x4c,0x8c,0x3a,0xe2) @ sha1su0 q4,q5,q6 |
| 1451 | INST(0xc0,0x42,0xb9,0xf3) @ sha1h q2,q0 @ 13 |
| 1452 | INST(0x6a,0x0c,0x26,0xe2) @ sha1m q0,q3,q13 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1453 | vadd.i32 q13,q11,q7 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1454 | INST(0x8e,0x83,0xba,0xf3) @ sha1su1 q4,q7 |
| 1455 | INST(0x4e,0xac,0x3c,0xe2) @ sha1su0 q5,q6,q7 |
| 1456 | INST(0xc0,0x62,0xb9,0xf3) @ sha1h q3,q0 @ 14 |
| 1457 | INST(0x68,0x0c,0x24,0xe2) @ sha1m q0,q2,q12 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1458 | vadd.i32 q12,q11,q4 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1459 | INST(0x88,0xa3,0xba,0xf3) @ sha1su1 q5,q4 |
| 1460 | INST(0x48,0xcc,0x3e,0xe2) @ sha1su0 q6,q7,q4 |
| 1461 | INST(0xc0,0x42,0xb9,0xf3) @ sha1h q2,q0 @ 15 |
| 1462 | INST(0x6a,0x0c,0x16,0xe2) @ sha1p q0,q3,q13 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1463 | vadd.i32 q13,q11,q5 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1464 | INST(0x8a,0xc3,0xba,0xf3) @ sha1su1 q6,q5 |
| 1465 | INST(0x4a,0xec,0x38,0xe2) @ sha1su0 q7,q4,q5 |
| 1466 | INST(0xc0,0x62,0xb9,0xf3) @ sha1h q3,q0 @ 16 |
| 1467 | INST(0x68,0x0c,0x14,0xe2) @ sha1p q0,q2,q12 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1468 | vadd.i32 q12,q11,q6 |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1469 | INST(0x8c,0xe3,0xba,0xf3) @ sha1su1 q7,q6 |
| 1470 | INST(0xc0,0x42,0xb9,0xf3) @ sha1h q2,q0 @ 17 |
| 1471 | INST(0x6a,0x0c,0x16,0xe2) @ sha1p q0,q3,q13 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1472 | vadd.i32 q13,q11,q7 |
| 1473 | |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1474 | INST(0xc0,0x62,0xb9,0xf3) @ sha1h q3,q0 @ 18 |
| 1475 | INST(0x68,0x0c,0x14,0xe2) @ sha1p q0,q2,q12 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1476 | |
Robert Sloan | 8ff0355 | 2017-06-14 12:40:58 -0700 | [diff] [blame^] | 1477 | INST(0xc0,0x42,0xb9,0xf3) @ sha1h q2,q0 @ 19 |
| 1478 | INST(0x6a,0x0c,0x16,0xe2) @ sha1p q0,q3,q13 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1479 | |
| 1480 | vadd.i32 q1,q1,q2 |
| 1481 | vadd.i32 q0,q0,q14 |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 1482 | bne .Loop_v8 |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1483 | |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 1484 | vst1.32 {q0},[r0]! |
| 1485 | vst1.32 {d2[0]},[r0] |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1486 | |
Adam Langley | e9ada86 | 2015-05-11 17:20:37 -0700 | [diff] [blame] | 1487 | vldmia sp!,{d8,d9,d10,d11,d12,d13,d14,d15} |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1488 | bx lr @ bx lr |
| 1489 | .size sha1_block_data_order_armv8,.-sha1_block_data_order_armv8 |
| 1490 | #endif |
| 1491 | #if __ARM_MAX_ARCH__>=7 |
| 1492 | .comm OPENSSL_armcap_P,4,4 |
Adam Langley | 13066f1 | 2015-02-13 14:47:35 -0800 | [diff] [blame] | 1493 | .hidden OPENSSL_armcap_P |
Adam Langley | d9e397b | 2015-01-22 14:27:53 -0800 | [diff] [blame] | 1494 | #endif |
David Benjamin | 4969cc9 | 2016-04-22 15:02:23 -0400 | [diff] [blame] | 1495 | #endif |