1/* $FreeBSD$ */ 2/* Do not modify. This file is auto-generated from x86cpuid.pl. */ 3#ifdef PIC 4.text 5.globl OPENSSL_ia32_cpuid 6.type OPENSSL_ia32_cpuid,@function 7.align 16 8OPENSSL_ia32_cpuid: 9.L_OPENSSL_ia32_cpuid_begin: 10 pushl %ebp 11 pushl %ebx 12 pushl %esi 13 pushl %edi 14 xorl %edx,%edx 15 pushfl 16 popl %eax 17 movl %eax,%ecx 18 xorl $2097152,%eax 19 pushl %eax 20 popfl 21 pushfl 22 popl %eax 23 xorl %eax,%ecx 24 xorl %eax,%eax 25 movl 20(%esp),%esi 26 movl %eax,8(%esi) 27 btl $21,%ecx 28 jnc .L000nocpuid 29 .byte 0x0f,0xa2 30 movl %eax,%edi 31 xorl %eax,%eax 32 cmpl $1970169159,%ebx 33 setne %al 34 movl %eax,%ebp 35 cmpl $1231384169,%edx 36 setne %al 37 orl %eax,%ebp 38 cmpl $1818588270,%ecx 39 setne %al 40 orl %eax,%ebp 41 jz .L001intel 42 cmpl $1752462657,%ebx 43 setne %al 44 movl %eax,%esi 45 cmpl $1769238117,%edx 46 setne %al 47 orl %eax,%esi 48 cmpl $1145913699,%ecx 49 setne %al 50 orl %eax,%esi 51 jnz .L001intel 52 movl $2147483648,%eax 53 .byte 0x0f,0xa2 54 cmpl $2147483649,%eax 55 jb .L001intel 56 movl %eax,%esi 57 movl $2147483649,%eax 58 .byte 0x0f,0xa2 59 orl %ecx,%ebp 60 andl $2049,%ebp 61 cmpl $2147483656,%esi 62 jb .L001intel 63 movl $2147483656,%eax 64 .byte 0x0f,0xa2 65 movzbl %cl,%esi 66 incl %esi 67 movl $1,%eax 68 xorl %ecx,%ecx 69 .byte 0x0f,0xa2 70 btl $28,%edx 71 jnc .L002generic 72 shrl $16,%ebx 73 andl $255,%ebx 74 cmpl %esi,%ebx 75 ja .L002generic 76 andl $4026531839,%edx 77 jmp .L002generic 78.L001intel: 79 cmpl $4,%edi 80 movl $-1,%esi 81 jb .L003nocacheinfo 82 movl $4,%eax 83 movl $0,%ecx 84 .byte 0x0f,0xa2 85 movl %eax,%esi 86 shrl $14,%esi 87 andl $4095,%esi 88.L003nocacheinfo: 89 movl $1,%eax 90 xorl %ecx,%ecx 91 .byte 0x0f,0xa2 92 andl $3220176895,%edx 93 cmpl $0,%ebp 94 jne .L004notintel 95 orl $1073741824,%edx 96 andb $15,%ah 97 cmpb $15,%ah 98 jne .L004notintel 99 orl $1048576,%edx 100.L004notintel: 101 btl $28,%edx 102 jnc .L002generic 103 andl $4026531839,%edx 104 cmpl $0,%esi 105 je .L002generic 106 orl $268435456,%edx 107 shrl $16,%ebx 108 cmpb $1,%bl 109 ja .L002generic 110 andl $4026531839,%edx 111.L002generic: 112 andl $2048,%ebp 113 andl $4294965247,%ecx 114 movl %edx,%esi 115 orl %ecx,%ebp 116 cmpl $7,%edi 117 movl 20(%esp),%edi 118 jb .L005no_extended_info 119 movl $7,%eax 120 xorl %ecx,%ecx 121 .byte 0x0f,0xa2 122 movl %ebx,8(%edi) 123.L005no_extended_info: 124 btl $27,%ebp 125 jnc .L006clear_avx 126 xorl %ecx,%ecx 127.byte 15,1,208 128 andl $6,%eax 129 cmpl $6,%eax 130 je .L007done 131 cmpl $2,%eax 132 je .L006clear_avx 133.L008clear_xmm: 134 andl $4261412861,%ebp 135 andl $4278190079,%esi 136.L006clear_avx: 137 andl $4026525695,%ebp 138 andl $4294967263,8(%edi) 139.L007done: 140 movl %esi,%eax 141 movl %ebp,%edx 142.L000nocpuid: 143 popl %edi 144 popl %esi 145 popl %ebx 146 popl %ebp 147 ret 148.size OPENSSL_ia32_cpuid,.-.L_OPENSSL_ia32_cpuid_begin 149.globl OPENSSL_rdtsc 150.type OPENSSL_rdtsc,@function 151.align 16 152OPENSSL_rdtsc: 153.L_OPENSSL_rdtsc_begin: 154 xorl %eax,%eax 155 xorl %edx,%edx 156 call .L009PIC_me_up 157.L009PIC_me_up: 158 popl %ecx 159 leal OPENSSL_ia32cap_P-.L009PIC_me_up(%ecx),%ecx 160 btl $4,(%ecx) 161 jnc .L010notsc 162 .byte 0x0f,0x31 163.L010notsc: 164 ret 165.size OPENSSL_rdtsc,.-.L_OPENSSL_rdtsc_begin 166.globl OPENSSL_instrument_halt 167.type OPENSSL_instrument_halt,@function 168.align 16 169OPENSSL_instrument_halt: 170.L_OPENSSL_instrument_halt_begin: 171 call .L011PIC_me_up 172.L011PIC_me_up: 173 popl %ecx 174 leal OPENSSL_ia32cap_P-.L011PIC_me_up(%ecx),%ecx 175 btl $4,(%ecx) 176 jnc .L012nohalt 177.long 2421723150 178 andl $3,%eax 179 jnz .L012nohalt 180 pushfl 181 popl %eax 182 btl $9,%eax 183 jnc .L012nohalt 184 .byte 0x0f,0x31 185 pushl %edx 186 pushl %eax 187 hlt 188 .byte 0x0f,0x31 189 subl (%esp),%eax 190 sbbl 4(%esp),%edx 191 addl $8,%esp 192 ret 193.L012nohalt: 194 xorl %eax,%eax 195 xorl %edx,%edx 196 ret 197.size OPENSSL_instrument_halt,.-.L_OPENSSL_instrument_halt_begin 198.globl OPENSSL_far_spin 199.type OPENSSL_far_spin,@function 200.align 16 201OPENSSL_far_spin: 202.L_OPENSSL_far_spin_begin: 203 pushfl 204 popl %eax 205 btl $9,%eax 206 jnc .L013nospin 207 movl 4(%esp),%eax 208 movl 8(%esp),%ecx 209.long 2430111262 210 xorl %eax,%eax 211 movl (%ecx),%edx 212 jmp .L014spin 213.align 16 214.L014spin: 215 incl %eax 216 cmpl (%ecx),%edx 217 je .L014spin 218.long 529567888 219 ret 220.L013nospin: 221 xorl %eax,%eax 222 xorl %edx,%edx 223 ret 224.size OPENSSL_far_spin,.-.L_OPENSSL_far_spin_begin 225.globl OPENSSL_wipe_cpu 226.type OPENSSL_wipe_cpu,@function 227.align 16 228OPENSSL_wipe_cpu: 229.L_OPENSSL_wipe_cpu_begin: 230 xorl %eax,%eax 231 xorl %edx,%edx 232 call .L015PIC_me_up 233.L015PIC_me_up: 234 popl %ecx 235 leal OPENSSL_ia32cap_P-.L015PIC_me_up(%ecx),%ecx 236 movl (%ecx),%ecx 237 btl $1,(%ecx) 238 jnc .L016no_x87 239 andl $83886080,%ecx 240 cmpl $83886080,%ecx 241 jne .L017no_sse2 242 pxor %xmm0,%xmm0 243 pxor %xmm1,%xmm1 244 pxor %xmm2,%xmm2 245 pxor %xmm3,%xmm3 246 pxor %xmm4,%xmm4 247 pxor %xmm5,%xmm5 248 pxor %xmm6,%xmm6 249 pxor %xmm7,%xmm7 250.L017no_sse2: 251.long 4007259865,4007259865,4007259865,4007259865,2430851995 252.L016no_x87: 253 leal 4(%esp),%eax 254 ret 255.size OPENSSL_wipe_cpu,.-.L_OPENSSL_wipe_cpu_begin 256.globl OPENSSL_atomic_add 257.type OPENSSL_atomic_add,@function 258.align 16 259OPENSSL_atomic_add: 260.L_OPENSSL_atomic_add_begin: 261 movl 4(%esp),%edx 262 movl 8(%esp),%ecx 263 pushl %ebx 264 nop 265 movl (%edx),%eax 266.L018spin: 267 leal (%eax,%ecx,1),%ebx 268 nop 269.long 447811568 270 jne .L018spin 271 movl %ebx,%eax 272 popl %ebx 273 ret 274.size OPENSSL_atomic_add,.-.L_OPENSSL_atomic_add_begin 275.globl OPENSSL_cleanse 276.type OPENSSL_cleanse,@function 277.align 16 278OPENSSL_cleanse: 279.L_OPENSSL_cleanse_begin: 280 movl 4(%esp),%edx 281 movl 8(%esp),%ecx 282 xorl %eax,%eax 283 cmpl $7,%ecx 284 jae .L019lot 285 cmpl $0,%ecx 286 je .L020ret 287.L021little: 288 movb %al,(%edx) 289 subl $1,%ecx 290 leal 1(%edx),%edx 291 jnz .L021little 292.L020ret: 293 ret 294.align 16 295.L019lot: 296 testl $3,%edx 297 jz .L022aligned 298 movb %al,(%edx) 299 leal -1(%ecx),%ecx 300 leal 1(%edx),%edx 301 jmp .L019lot 302.L022aligned: 303 movl %eax,(%edx) 304 leal -4(%ecx),%ecx 305 testl $-4,%ecx 306 leal 4(%edx),%edx 307 jnz .L022aligned 308 cmpl $0,%ecx 309 jne .L021little 310 ret 311.size OPENSSL_cleanse,.-.L_OPENSSL_cleanse_begin 312.globl CRYPTO_memcmp 313.type CRYPTO_memcmp,@function 314.align 16 315CRYPTO_memcmp: 316.L_CRYPTO_memcmp_begin: 317 pushl %esi 318 pushl %edi 319 movl 12(%esp),%esi 320 movl 16(%esp),%edi 321 movl 20(%esp),%ecx 322 xorl %eax,%eax 323 xorl %edx,%edx 324 cmpl $0,%ecx 325 je .L023no_data 326.L024loop: 327 movb (%esi),%dl 328 leal 1(%esi),%esi 329 xorb (%edi),%dl 330 leal 1(%edi),%edi 331 orb %dl,%al 332 decl %ecx 333 jnz .L024loop 334 negl %eax 335 shrl $31,%eax 336.L023no_data: 337 popl %edi 338 popl %esi 339 ret 340.size CRYPTO_memcmp,.-.L_CRYPTO_memcmp_begin 341.globl OPENSSL_instrument_bus 342.type OPENSSL_instrument_bus,@function 343.align 16 344OPENSSL_instrument_bus: 345.L_OPENSSL_instrument_bus_begin: 346 pushl %ebp 347 pushl %ebx 348 pushl %esi 349 pushl %edi 350 movl $0,%eax 351 call .L025PIC_me_up 352.L025PIC_me_up: 353 popl %edx 354 leal OPENSSL_ia32cap_P-.L025PIC_me_up(%edx),%edx 355 btl $4,(%edx) 356 jnc .L026nogo 357 btl $19,(%edx) 358 jnc .L026nogo 359 movl 20(%esp),%edi 360 movl 24(%esp),%ecx 361 .byte 0x0f,0x31 362 movl %eax,%esi 363 movl $0,%ebx 364 clflush (%edi) 365.byte 240 366 addl %ebx,(%edi) 367 jmp .L027loop 368.align 16 369.L027loop: 370 .byte 0x0f,0x31 371 movl %eax,%edx 372 subl %esi,%eax 373 movl %edx,%esi 374 movl %eax,%ebx 375 clflush (%edi) 376.byte 240 377 addl %eax,(%edi) 378 leal 4(%edi),%edi 379 subl $1,%ecx 380 jnz .L027loop 381 movl 24(%esp),%eax 382.L026nogo: 383 popl %edi 384 popl %esi 385 popl %ebx 386 popl %ebp 387 ret 388.size OPENSSL_instrument_bus,.-.L_OPENSSL_instrument_bus_begin 389.globl OPENSSL_instrument_bus2 390.type OPENSSL_instrument_bus2,@function 391.align 16 392OPENSSL_instrument_bus2: 393.L_OPENSSL_instrument_bus2_begin: 394 pushl %ebp 395 pushl %ebx 396 pushl %esi 397 pushl %edi 398 movl $0,%eax 399 call .L028PIC_me_up 400.L028PIC_me_up: 401 popl %edx 402 leal OPENSSL_ia32cap_P-.L028PIC_me_up(%edx),%edx 403 btl $4,(%edx) 404 jnc .L029nogo 405 btl $19,(%edx) 406 jnc .L029nogo 407 movl 20(%esp),%edi 408 movl 24(%esp),%ecx 409 movl 28(%esp),%ebp 410 .byte 0x0f,0x31 411 movl %eax,%esi 412 movl $0,%ebx 413 clflush (%edi) 414.byte 240 415 addl %ebx,(%edi) 416 .byte 0x0f,0x31 417 movl %eax,%edx 418 subl %esi,%eax 419 movl %edx,%esi 420 movl %eax,%ebx 421 jmp .L030loop2 422.align 16 423.L030loop2: 424 clflush (%edi) 425.byte 240 426 addl %eax,(%edi) 427 subl $1,%ebp 428 jz .L031done2 429 .byte 0x0f,0x31 430 movl %eax,%edx 431 subl %esi,%eax 432 movl %edx,%esi 433 cmpl %ebx,%eax 434 movl %eax,%ebx 435 movl $0,%edx 436 setne %dl 437 subl %edx,%ecx 438 leal (%edi,%edx,4),%edi 439 jnz .L030loop2 440.L031done2: 441 movl 24(%esp),%eax 442 subl %ecx,%eax 443.L029nogo: 444 popl %edi 445 popl %esi 446 popl %ebx 447 popl %ebp 448 ret 449.size OPENSSL_instrument_bus2,.-.L_OPENSSL_instrument_bus2_begin 450.globl OPENSSL_ia32_rdrand_bytes 451.type OPENSSL_ia32_rdrand_bytes,@function 452.align 16 453OPENSSL_ia32_rdrand_bytes: 454.L_OPENSSL_ia32_rdrand_bytes_begin: 455 pushl %edi 456 pushl %ebx 457 xorl %eax,%eax 458 movl 12(%esp),%edi 459 movl 16(%esp),%ebx 460 cmpl $0,%ebx 461 je .L032done 462 movl $8,%ecx 463.L033loop: 464.byte 15,199,242 465 jc .L034break 466 loop .L033loop 467 jmp .L032done 468.align 16 469.L034break: 470 cmpl $4,%ebx 471 jb .L035tail 472 movl %edx,(%edi) 473 leal 4(%edi),%edi 474 addl $4,%eax 475 subl $4,%ebx 476 jz .L032done 477 movl $8,%ecx 478 jmp .L033loop 479.align 16 480.L035tail: 481 movb %dl,(%edi) 482 leal 1(%edi),%edi 483 incl %eax 484 shrl $8,%edx 485 decl %ebx 486 jnz .L035tail 487.L032done: 488 xorl %edx,%edx 489 popl %ebx 490 popl %edi 491 ret 492.size OPENSSL_ia32_rdrand_bytes,.-.L_OPENSSL_ia32_rdrand_bytes_begin 493.globl OPENSSL_ia32_rdseed_bytes 494.type OPENSSL_ia32_rdseed_bytes,@function 495.align 16 496OPENSSL_ia32_rdseed_bytes: 497.L_OPENSSL_ia32_rdseed_bytes_begin: 498 pushl %edi 499 pushl %ebx 500 xorl %eax,%eax 501 movl 12(%esp),%edi 502 movl 16(%esp),%ebx 503 cmpl $0,%ebx 504 je .L036done 505 movl $8,%ecx 506.L037loop: 507.byte 15,199,250 508 jc .L038break 509 loop .L037loop 510 jmp .L036done 511.align 16 512.L038break: 513 cmpl $4,%ebx 514 jb .L039tail 515 movl %edx,(%edi) 516 leal 4(%edi),%edi 517 addl $4,%eax 518 subl $4,%ebx 519 jz .L036done 520 movl $8,%ecx 521 jmp .L037loop 522.align 16 523.L039tail: 524 movb %dl,(%edi) 525 leal 1(%edi),%edi 526 incl %eax 527 shrl $8,%edx 528 decl %ebx 529 jnz .L039tail 530.L036done: 531 xorl %edx,%edx 532 popl %ebx 533 popl %edi 534 ret 535.size OPENSSL_ia32_rdseed_bytes,.-.L_OPENSSL_ia32_rdseed_bytes_begin 536.hidden OPENSSL_cpuid_setup 537.hidden OPENSSL_ia32cap_P 538.comm OPENSSL_ia32cap_P,16,4 539.section .init 540 call OPENSSL_cpuid_setup 541#else 542.text 543.globl OPENSSL_ia32_cpuid 544.type OPENSSL_ia32_cpuid,@function 545.align 16 546OPENSSL_ia32_cpuid: 547.L_OPENSSL_ia32_cpuid_begin: 548 pushl %ebp 549 pushl %ebx 550 pushl %esi 551 pushl %edi 552 xorl %edx,%edx 553 pushfl 554 popl %eax 555 movl %eax,%ecx 556 xorl $2097152,%eax 557 pushl %eax 558 popfl 559 pushfl 560 popl %eax 561 xorl %eax,%ecx 562 xorl %eax,%eax 563 movl 20(%esp),%esi 564 movl %eax,8(%esi) 565 btl $21,%ecx 566 jnc .L000nocpuid 567 .byte 0x0f,0xa2 568 movl %eax,%edi 569 xorl %eax,%eax 570 cmpl $1970169159,%ebx 571 setne %al 572 movl %eax,%ebp 573 cmpl $1231384169,%edx 574 setne %al 575 orl %eax,%ebp 576 cmpl $1818588270,%ecx 577 setne %al 578 orl %eax,%ebp 579 jz .L001intel 580 cmpl $1752462657,%ebx 581 setne %al 582 movl %eax,%esi 583 cmpl $1769238117,%edx 584 setne %al 585 orl %eax,%esi 586 cmpl $1145913699,%ecx 587 setne %al 588 orl %eax,%esi 589 jnz .L001intel 590 movl $2147483648,%eax 591 .byte 0x0f,0xa2 592 cmpl $2147483649,%eax 593 jb .L001intel 594 movl %eax,%esi 595 movl $2147483649,%eax 596 .byte 0x0f,0xa2 597 orl %ecx,%ebp 598 andl $2049,%ebp 599 cmpl $2147483656,%esi 600 jb .L001intel 601 movl $2147483656,%eax 602 .byte 0x0f,0xa2 603 movzbl %cl,%esi 604 incl %esi 605 movl $1,%eax 606 xorl %ecx,%ecx 607 .byte 0x0f,0xa2 608 btl $28,%edx 609 jnc .L002generic 610 shrl $16,%ebx 611 andl $255,%ebx 612 cmpl %esi,%ebx 613 ja .L002generic 614 andl $4026531839,%edx 615 jmp .L002generic 616.L001intel: 617 cmpl $4,%edi 618 movl $-1,%esi 619 jb .L003nocacheinfo 620 movl $4,%eax 621 movl $0,%ecx 622 .byte 0x0f,0xa2 623 movl %eax,%esi 624 shrl $14,%esi 625 andl $4095,%esi 626.L003nocacheinfo: 627 movl $1,%eax 628 xorl %ecx,%ecx 629 .byte 0x0f,0xa2 630 andl $3220176895,%edx 631 cmpl $0,%ebp 632 jne .L004notintel 633 orl $1073741824,%edx 634 andb $15,%ah 635 cmpb $15,%ah 636 jne .L004notintel 637 orl $1048576,%edx 638.L004notintel: 639 btl $28,%edx 640 jnc .L002generic 641 andl $4026531839,%edx 642 cmpl $0,%esi 643 je .L002generic 644 orl $268435456,%edx 645 shrl $16,%ebx 646 cmpb $1,%bl 647 ja .L002generic 648 andl $4026531839,%edx 649.L002generic: 650 andl $2048,%ebp 651 andl $4294965247,%ecx 652 movl %edx,%esi 653 orl %ecx,%ebp 654 cmpl $7,%edi 655 movl 20(%esp),%edi 656 jb .L005no_extended_info 657 movl $7,%eax 658 xorl %ecx,%ecx 659 .byte 0x0f,0xa2 660 movl %ebx,8(%edi) 661.L005no_extended_info: 662 btl $27,%ebp 663 jnc .L006clear_avx 664 xorl %ecx,%ecx 665.byte 15,1,208 666 andl $6,%eax 667 cmpl $6,%eax 668 je .L007done 669 cmpl $2,%eax 670 je .L006clear_avx 671.L008clear_xmm: 672 andl $4261412861,%ebp 673 andl $4278190079,%esi 674.L006clear_avx: 675 andl $4026525695,%ebp 676 andl $4294967263,8(%edi) 677.L007done: 678 movl %esi,%eax 679 movl %ebp,%edx 680.L000nocpuid: 681 popl %edi 682 popl %esi 683 popl %ebx 684 popl %ebp 685 ret 686.size OPENSSL_ia32_cpuid,.-.L_OPENSSL_ia32_cpuid_begin 687.globl OPENSSL_rdtsc 688.type OPENSSL_rdtsc,@function 689.align 16 690OPENSSL_rdtsc: 691.L_OPENSSL_rdtsc_begin: 692 xorl %eax,%eax 693 xorl %edx,%edx 694 leal OPENSSL_ia32cap_P,%ecx 695 btl $4,(%ecx) 696 jnc .L009notsc 697 .byte 0x0f,0x31 698.L009notsc: 699 ret 700.size OPENSSL_rdtsc,.-.L_OPENSSL_rdtsc_begin 701.globl OPENSSL_instrument_halt 702.type OPENSSL_instrument_halt,@function 703.align 16 704OPENSSL_instrument_halt: 705.L_OPENSSL_instrument_halt_begin: 706 leal OPENSSL_ia32cap_P,%ecx 707 btl $4,(%ecx) 708 jnc .L010nohalt 709.long 2421723150 710 andl $3,%eax 711 jnz .L010nohalt 712 pushfl 713 popl %eax 714 btl $9,%eax 715 jnc .L010nohalt 716 .byte 0x0f,0x31 717 pushl %edx 718 pushl %eax 719 hlt 720 .byte 0x0f,0x31 721 subl (%esp),%eax 722 sbbl 4(%esp),%edx 723 addl $8,%esp 724 ret 725.L010nohalt: 726 xorl %eax,%eax 727 xorl %edx,%edx 728 ret 729.size OPENSSL_instrument_halt,.-.L_OPENSSL_instrument_halt_begin 730.globl OPENSSL_far_spin 731.type OPENSSL_far_spin,@function 732.align 16 733OPENSSL_far_spin: 734.L_OPENSSL_far_spin_begin: 735 pushfl 736 popl %eax 737 btl $9,%eax 738 jnc .L011nospin 739 movl 4(%esp),%eax 740 movl 8(%esp),%ecx 741.long 2430111262 742 xorl %eax,%eax 743 movl (%ecx),%edx 744 jmp .L012spin 745.align 16 746.L012spin: 747 incl %eax 748 cmpl (%ecx),%edx 749 je .L012spin 750.long 529567888 751 ret 752.L011nospin: 753 xorl %eax,%eax 754 xorl %edx,%edx 755 ret 756.size OPENSSL_far_spin,.-.L_OPENSSL_far_spin_begin 757.globl OPENSSL_wipe_cpu 758.type OPENSSL_wipe_cpu,@function 759.align 16 760OPENSSL_wipe_cpu: 761.L_OPENSSL_wipe_cpu_begin: 762 xorl %eax,%eax 763 xorl %edx,%edx 764 leal OPENSSL_ia32cap_P,%ecx 765 movl (%ecx),%ecx 766 btl $1,(%ecx) 767 jnc .L013no_x87 768 andl $83886080,%ecx 769 cmpl $83886080,%ecx 770 jne .L014no_sse2 771 pxor %xmm0,%xmm0 772 pxor %xmm1,%xmm1 773 pxor %xmm2,%xmm2 774 pxor %xmm3,%xmm3 775 pxor %xmm4,%xmm4 776 pxor %xmm5,%xmm5 777 pxor %xmm6,%xmm6 778 pxor %xmm7,%xmm7 779.L014no_sse2: 780.long 4007259865,4007259865,4007259865,4007259865,2430851995 781.L013no_x87: 782 leal 4(%esp),%eax 783 ret 784.size OPENSSL_wipe_cpu,.-.L_OPENSSL_wipe_cpu_begin 785.globl OPENSSL_atomic_add 786.type OPENSSL_atomic_add,@function 787.align 16 788OPENSSL_atomic_add: 789.L_OPENSSL_atomic_add_begin: 790 movl 4(%esp),%edx 791 movl 8(%esp),%ecx 792 pushl %ebx 793 nop 794 movl (%edx),%eax 795.L015spin: 796 leal (%eax,%ecx,1),%ebx 797 nop 798.long 447811568 799 jne .L015spin 800 movl %ebx,%eax 801 popl %ebx 802 ret 803.size OPENSSL_atomic_add,.-.L_OPENSSL_atomic_add_begin 804.globl OPENSSL_cleanse 805.type OPENSSL_cleanse,@function 806.align 16 807OPENSSL_cleanse: 808.L_OPENSSL_cleanse_begin: 809 movl 4(%esp),%edx 810 movl 8(%esp),%ecx 811 xorl %eax,%eax 812 cmpl $7,%ecx 813 jae .L016lot 814 cmpl $0,%ecx 815 je .L017ret 816.L018little: 817 movb %al,(%edx) 818 subl $1,%ecx 819 leal 1(%edx),%edx 820 jnz .L018little 821.L017ret: 822 ret 823.align 16 824.L016lot: 825 testl $3,%edx 826 jz .L019aligned 827 movb %al,(%edx) 828 leal -1(%ecx),%ecx 829 leal 1(%edx),%edx 830 jmp .L016lot 831.L019aligned: 832 movl %eax,(%edx) 833 leal -4(%ecx),%ecx 834 testl $-4,%ecx 835 leal 4(%edx),%edx 836 jnz .L019aligned 837 cmpl $0,%ecx 838 jne .L018little 839 ret 840.size OPENSSL_cleanse,.-.L_OPENSSL_cleanse_begin 841.globl CRYPTO_memcmp 842.type CRYPTO_memcmp,@function 843.align 16 844CRYPTO_memcmp: 845.L_CRYPTO_memcmp_begin: 846 pushl %esi 847 pushl %edi 848 movl 12(%esp),%esi 849 movl 16(%esp),%edi 850 movl 20(%esp),%ecx 851 xorl %eax,%eax 852 xorl %edx,%edx 853 cmpl $0,%ecx 854 je .L020no_data 855.L021loop: 856 movb (%esi),%dl 857 leal 1(%esi),%esi 858 xorb (%edi),%dl 859 leal 1(%edi),%edi 860 orb %dl,%al 861 decl %ecx 862 jnz .L021loop 863 negl %eax 864 shrl $31,%eax 865.L020no_data: 866 popl %edi 867 popl %esi 868 ret 869.size CRYPTO_memcmp,.-.L_CRYPTO_memcmp_begin 870.globl OPENSSL_instrument_bus 871.type OPENSSL_instrument_bus,@function 872.align 16 873OPENSSL_instrument_bus: 874.L_OPENSSL_instrument_bus_begin: 875 pushl %ebp 876 pushl %ebx 877 pushl %esi 878 pushl %edi 879 movl $0,%eax 880 leal OPENSSL_ia32cap_P,%edx 881 btl $4,(%edx) 882 jnc .L022nogo 883 btl $19,(%edx) 884 jnc .L022nogo 885 movl 20(%esp),%edi 886 movl 24(%esp),%ecx 887 .byte 0x0f,0x31 888 movl %eax,%esi 889 movl $0,%ebx 890 clflush (%edi) 891.byte 240 892 addl %ebx,(%edi) 893 jmp .L023loop 894.align 16 895.L023loop: 896 .byte 0x0f,0x31 897 movl %eax,%edx 898 subl %esi,%eax 899 movl %edx,%esi 900 movl %eax,%ebx 901 clflush (%edi) 902.byte 240 903 addl %eax,(%edi) 904 leal 4(%edi),%edi 905 subl $1,%ecx 906 jnz .L023loop 907 movl 24(%esp),%eax 908.L022nogo: 909 popl %edi 910 popl %esi 911 popl %ebx 912 popl %ebp 913 ret 914.size OPENSSL_instrument_bus,.-.L_OPENSSL_instrument_bus_begin 915.globl OPENSSL_instrument_bus2 916.type OPENSSL_instrument_bus2,@function 917.align 16 918OPENSSL_instrument_bus2: 919.L_OPENSSL_instrument_bus2_begin: 920 pushl %ebp 921 pushl %ebx 922 pushl %esi 923 pushl %edi 924 movl $0,%eax 925 leal OPENSSL_ia32cap_P,%edx 926 btl $4,(%edx) 927 jnc .L024nogo 928 btl $19,(%edx) 929 jnc .L024nogo 930 movl 20(%esp),%edi 931 movl 24(%esp),%ecx 932 movl 28(%esp),%ebp 933 .byte 0x0f,0x31 934 movl %eax,%esi 935 movl $0,%ebx 936 clflush (%edi) 937.byte 240 938 addl %ebx,(%edi) 939 .byte 0x0f,0x31 940 movl %eax,%edx 941 subl %esi,%eax 942 movl %edx,%esi 943 movl %eax,%ebx 944 jmp .L025loop2 945.align 16 946.L025loop2: 947 clflush (%edi) 948.byte 240 949 addl %eax,(%edi) 950 subl $1,%ebp 951 jz .L026done2 952 .byte 0x0f,0x31 953 movl %eax,%edx 954 subl %esi,%eax 955 movl %edx,%esi 956 cmpl %ebx,%eax 957 movl %eax,%ebx 958 movl $0,%edx 959 setne %dl 960 subl %edx,%ecx 961 leal (%edi,%edx,4),%edi 962 jnz .L025loop2 963.L026done2: 964 movl 24(%esp),%eax 965 subl %ecx,%eax 966.L024nogo: 967 popl %edi 968 popl %esi 969 popl %ebx 970 popl %ebp 971 ret 972.size OPENSSL_instrument_bus2,.-.L_OPENSSL_instrument_bus2_begin 973.globl OPENSSL_ia32_rdrand_bytes 974.type OPENSSL_ia32_rdrand_bytes,@function 975.align 16 976OPENSSL_ia32_rdrand_bytes: 977.L_OPENSSL_ia32_rdrand_bytes_begin: 978 pushl %edi 979 pushl %ebx 980 xorl %eax,%eax 981 movl 12(%esp),%edi 982 movl 16(%esp),%ebx 983 cmpl $0,%ebx 984 je .L027done 985 movl $8,%ecx 986.L028loop: 987.byte 15,199,242 988 jc .L029break 989 loop .L028loop 990 jmp .L027done 991.align 16 992.L029break: 993 cmpl $4,%ebx 994 jb .L030tail 995 movl %edx,(%edi) 996 leal 4(%edi),%edi 997 addl $4,%eax 998 subl $4,%ebx 999 jz .L027done 1000 movl $8,%ecx 1001 jmp .L028loop 1002.align 16 1003.L030tail: 1004 movb %dl,(%edi) 1005 leal 1(%edi),%edi 1006 incl %eax 1007 shrl $8,%edx 1008 decl %ebx 1009 jnz .L030tail 1010.L027done: 1011 xorl %edx,%edx 1012 popl %ebx 1013 popl %edi 1014 ret 1015.size OPENSSL_ia32_rdrand_bytes,.-.L_OPENSSL_ia32_rdrand_bytes_begin 1016.globl OPENSSL_ia32_rdseed_bytes 1017.type OPENSSL_ia32_rdseed_bytes,@function 1018.align 16 1019OPENSSL_ia32_rdseed_bytes: 1020.L_OPENSSL_ia32_rdseed_bytes_begin: 1021 pushl %edi 1022 pushl %ebx 1023 xorl %eax,%eax 1024 movl 12(%esp),%edi 1025 movl 16(%esp),%ebx 1026 cmpl $0,%ebx 1027 je .L031done 1028 movl $8,%ecx 1029.L032loop: 1030.byte 15,199,250 1031 jc .L033break 1032 loop .L032loop 1033 jmp .L031done 1034.align 16 1035.L033break: 1036 cmpl $4,%ebx 1037 jb .L034tail 1038 movl %edx,(%edi) 1039 leal 4(%edi),%edi 1040 addl $4,%eax 1041 subl $4,%ebx 1042 jz .L031done 1043 movl $8,%ecx 1044 jmp .L032loop 1045.align 16 1046.L034tail: 1047 movb %dl,(%edi) 1048 leal 1(%edi),%edi 1049 incl %eax 1050 shrl $8,%edx 1051 decl %ebx 1052 jnz .L034tail 1053.L031done: 1054 xorl %edx,%edx 1055 popl %ebx 1056 popl %edi 1057 ret 1058.size OPENSSL_ia32_rdseed_bytes,.-.L_OPENSSL_ia32_rdseed_bytes_begin 1059.hidden OPENSSL_cpuid_setup 1060.hidden OPENSSL_ia32cap_P 1061.comm OPENSSL_ia32cap_P,16,4 1062.section .init 1063 call OPENSSL_cpuid_setup 1064#endif 1065