internal-tinyjambu-avr.S 4.91 KB
Newer Older
Rhys Weatherley committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471
#if defined(__AVR__)
#include <avr/io.h>
/* Automatically generated - do not edit */

	.text
.global tiny_jambu_permutation
	.type tiny_jambu_permutation, @function
tiny_jambu_permutation:
	push r28
	push r29
	push r2
	push r3
	push r4
	push r5
	push r6
	push r7
	push r8
	push r9
	push r10
	push r11
	push r12
	push r13
	push r14
	push r15
	push r16
	push r17
	movw r26,r24
	movw r30,r22
.L__stack_usage = 18
	ld r22,X+
	ld r23,X+
	ld r28,X+
	ld r29,X+
	ld r2,X+
	ld r3,X+
	ld r4,X+
	ld r5,X+
	ld r6,X+
	ld r7,X+
	ld r8,X+
	ld r9,X+
	ld r10,X+
	ld r11,X+
	ld r12,X+
	ld r13,X+
	lsl r20
	lsl r20
	mov r19,r1
19:
	movw r24,r4
	movw r16,r6
	mov r15,r3
	lsl r15
	rol r24
	rol r25
	rol r16
	rol r17
	eor r22,r24
	eor r23,r25
	eor r28,r16
	eor r29,r17
	mov r14,r7
	mov r15,r8
	mov r24,r9
	mov r25,r10
	mov r0,r6
	lsl r0
	rol r14
	rol r15
	rol r24
	rol r25
	lsl r0
	rol r14
	rol r15
	rol r24
	rol r25
	mov r16,r9
	mov r0,r8
	mov r17,r10
	mov r21,r11
	lsl r0
	rol r16
	rol r17
	rol r21
	lsl r0
	rol r16
	rol r17
	rol r21
	lsl r0
	rol r16
	rol r17
	rol r21
	and r14,r16
	and r15,r17
	and r24,r21
	mov r16,r11
	mov r17,r12
	lsl r16
	rol r17
	lsl r16
	rol r17
	lsl r16
	rol r17
	and r25,r17
	com r14
	com r15
	com r24
	com r25
	eor r22,r14
	eor r23,r15
	eor r28,r24
	eor r29,r25
	movw r24,r10
	movw r16,r12
	mov r15,r9
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	eor r22,r15
	eor r23,r24
	eor r28,r25
	eor r29,r16
	ld r14,Z+
	ld r15,Z+
	ld r24,Z+
	ld r25,Z+
	eor r22,r14
	eor r23,r15
	eor r28,r24
	eor r29,r25
	movw r24,r8
	movw r16,r10
	mov r15,r7
	lsl r15
	rol r24
	rol r25
	rol r16
	rol r17
	eor r2,r24
	eor r3,r25
	eor r4,r16
	eor r5,r17
	mov r14,r11
	mov r15,r12
	mov r24,r13
	mov r25,r22
	mov r0,r10
	lsl r0
	rol r14
	rol r15
	rol r24
	rol r25
	lsl r0
	rol r14
	rol r15
	rol r24
	rol r25
	mov r16,r13
	mov r0,r12
	mov r17,r22
	mov r21,r23
	lsl r0
	rol r16
	rol r17
	rol r21
	lsl r0
	rol r16
	rol r17
	rol r21
	lsl r0
	rol r16
	rol r17
	rol r21
	and r14,r16
	and r15,r17
	and r24,r21
	mov r16,r23
	mov r17,r28
	lsl r16
	rol r17
	lsl r16
	rol r17
	lsl r16
	rol r17
	and r25,r17
	com r14
	com r15
	com r24
	com r25
	eor r2,r14
	eor r3,r15
	eor r4,r24
	eor r5,r25
	movw r24,r22
	movw r16,r28
	mov r15,r13
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	eor r2,r15
	eor r3,r24
	eor r4,r25
	eor r5,r16
	ld r14,Z+
	ld r15,Z+
	ld r24,Z+
	ld r25,Z+
	eor r2,r14
	eor r3,r15
	eor r4,r24
	eor r5,r25
	movw r24,r12
	movw r16,r22
	mov r15,r11
	lsl r15
	rol r24
	rol r25
	rol r16
	rol r17
	eor r6,r24
	eor r7,r25
	eor r8,r16
	eor r9,r17
	mov r14,r23
	mov r15,r28
	mov r24,r29
	mov r25,r2
	mov r0,r22
	lsl r0
	rol r14
	rol r15
	rol r24
	rol r25
	lsl r0
	rol r14
	rol r15
	rol r24
	rol r25
	mov r16,r29
	mov r0,r28
	mov r17,r2
	mov r21,r3
	lsl r0
	rol r16
	rol r17
	rol r21
	lsl r0
	rol r16
	rol r17
	rol r21
	lsl r0
	rol r16
	rol r17
	rol r21
	and r14,r16
	and r15,r17
	and r24,r21
	mov r16,r3
	mov r17,r4
	lsl r16
	rol r17
	lsl r16
	rol r17
	lsl r16
	rol r17
	and r25,r17
	com r14
	com r15
	com r24
	com r25
	eor r6,r14
	eor r7,r15
	eor r8,r24
	eor r9,r25
	movw r24,r2
	movw r16,r4
	mov r15,r29
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	eor r6,r15
	eor r7,r24
	eor r8,r25
	eor r9,r16
	ld r14,Z+
	ld r15,Z+
	ld r24,Z+
	ld r25,Z+
	eor r6,r14
	eor r7,r15
	eor r8,r24
	eor r9,r25
	movw r24,r28
	movw r16,r2
	mov r15,r23
	lsl r15
	rol r24
	rol r25
	rol r16
	rol r17
	eor r10,r24
	eor r11,r25
	eor r12,r16
	eor r13,r17
	mov r14,r3
	mov r15,r4
	mov r24,r5
	mov r25,r6
	mov r0,r2
	lsl r0
	rol r14
	rol r15
	rol r24
	rol r25
	lsl r0
	rol r14
	rol r15
	rol r24
	rol r25
	mov r16,r5
	mov r0,r4
	mov r17,r6
	mov r21,r7
	lsl r0
	rol r16
	rol r17
	rol r21
	lsl r0
	rol r16
	rol r17
	rol r21
	lsl r0
	rol r16
	rol r17
	rol r21
	and r14,r16
	and r15,r17
	and r24,r21
	mov r16,r7
	mov r17,r8
	lsl r16
	rol r17
	lsl r16
	rol r17
	lsl r16
	rol r17
	and r25,r17
	com r14
	com r15
	com r24
	com r25
	eor r10,r14
	eor r11,r15
	eor r12,r24
	eor r13,r25
	movw r24,r6
	movw r16,r8
	mov r15,r5
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	lsr r17
	ror r16
	ror r25
	ror r24
	ror r15
	eor r10,r15
	eor r11,r24
	eor r12,r25
	eor r13,r16
	ld r14,Z+
	ld r15,Z+
	ld r24,Z+
	ld r25,Z+
	eor r10,r14
	eor r11,r15
	eor r12,r24
	eor r13,r25
	dec r18
	breq 401f
	subi r19,240
	cp r19,r20
	breq 5396f
	rjmp 19b
5396:
	sub r30,r20
	sbc r31,r1
	mov r19,r1
	rjmp 19b
401:
	st -X,r13
	st -X,r12
	st -X,r11
	st -X,r10
	st -X,r9
	st -X,r8
	st -X,r7
	st -X,r6
	st -X,r5
	st -X,r4
	st -X,r3
	st -X,r2
	st -X,r29
	st -X,r28
	st -X,r23
	st -X,r22
	pop r17
	pop r16
	pop r15
	pop r14
	pop r13
	pop r12
	pop r11
	pop r10
	pop r9
	pop r8
	pop r7
	pop r6
	pop r5
	pop r4
	pop r3
	pop r2
	pop r29
	pop r28
	ret
	.size tiny_jambu_permutation, .-tiny_jambu_permutation

#endif