| OLD | NEW |
| 1 OPTION» DOTNAME | 1 default»rel |
| 2 .text$» SEGMENT ALIGN(256) 'CODE' | 2 %define XMMWORD |
| 3 %define YMMWORD |
| 4 %define ZMMWORD |
| 5 section».text code align=64 |
| 3 | 6 |
| 4 PUBLIC» OPENSSL_ia32_cpuid | 7 |
| 8 global» OPENSSL_ia32_cpuid |
| 5 | 9 |
| 6 ALIGN 16 | 10 ALIGN 16 |
| 7 OPENSSL_ia32_cpuid» PROC PUBLIC | 11 OPENSSL_ia32_cpuid: |
| 8 » mov» QWORD PTR[8+rsp],rdi» ;WIN64 prologue | 12 » mov» QWORD[8+rsp],rdi» ;WIN64 prologue |
| 9 » mov» QWORD PTR[16+rsp],rsi | 13 » mov» QWORD[16+rsp],rsi |
| 10 mov rax,rsp | 14 mov rax,rsp |
| 11 $L$SEH_begin_OPENSSL_ia32_cpuid:: | 15 $L$SEH_begin_OPENSSL_ia32_cpuid: |
| 12 mov rdi,rcx | 16 mov rdi,rcx |
| 13 | 17 |
| 14 | 18 |
| 15 | 19 |
| 16 | 20 |
| 17 mov rdi,rcx | 21 mov rdi,rcx |
| 18 mov r8,rbx | 22 mov r8,rbx |
| 19 | 23 |
| 20 xor eax,eax | 24 xor eax,eax |
| 21 » mov» DWORD PTR[8+rdi],eax | 25 » mov» DWORD[8+rdi],eax |
| 22 cpuid | 26 cpuid |
| 23 mov r11d,eax | 27 mov r11d,eax |
| 24 | 28 |
| 25 xor eax,eax | 29 xor eax,eax |
| 26 » cmp» ebx,0756e6547h | 30 » cmp» ebx,0x756e6547 |
| 27 setne al | 31 setne al |
| 28 mov r9d,eax | 32 mov r9d,eax |
| 29 » cmp» edx,049656e69h | 33 » cmp» edx,0x49656e69 |
| 30 setne al | 34 setne al |
| 31 or r9d,eax | 35 or r9d,eax |
| 32 » cmp» ecx,06c65746eh | 36 » cmp» ecx,0x6c65746e |
| 33 setne al | 37 setne al |
| 34 or r9d,eax | 38 or r9d,eax |
| 35 » jz» $L$intel | 39 » jz» NEAR $L$intel |
| 36 | 40 |
| 37 » cmp» ebx,068747541h | 41 » cmp» ebx,0x68747541 |
| 38 setne al | 42 setne al |
| 39 mov r10d,eax | 43 mov r10d,eax |
| 40 » cmp» edx,069746E65h | 44 » cmp» edx,0x69746E65 |
| 41 setne al | 45 setne al |
| 42 or r10d,eax | 46 or r10d,eax |
| 43 » cmp» ecx,0444D4163h | 47 » cmp» ecx,0x444D4163 |
| 44 setne al | 48 setne al |
| 45 or r10d,eax | 49 or r10d,eax |
| 46 » jnz» $L$intel | 50 » jnz» NEAR $L$intel |
| 47 | 51 |
| 48 | 52 |
| 49 | 53 |
| 50 | 54 |
| 51 » mov» eax,080000000h | 55 » mov» eax,0x80000000 |
| 52 cpuid | 56 cpuid |
| 53 | 57 |
| 54 | 58 |
| 55 » cmp» eax,080000001h | 59 » cmp» eax,0x80000001 |
| 56 » jb» $L$intel | 60 » jb» NEAR $L$intel |
| 57 mov r10d,eax | 61 mov r10d,eax |
| 58 » mov» eax,080000001h | 62 » mov» eax,0x80000001 |
| 59 cpuid | 63 cpuid |
| 60 | 64 |
| 61 | 65 |
| 62 or r9d,ecx | 66 or r9d,ecx |
| 63 » and» r9d,000000801h | 67 » and» r9d,0x00000801 |
| 64 | 68 |
| 65 » cmp» r10d,080000008h | 69 » cmp» r10d,0x80000008 |
| 66 » jb» $L$intel | 70 » jb» NEAR $L$intel |
| 67 | 71 |
| 68 » mov» eax,080000008h | 72 » mov» eax,0x80000008 |
| 69 cpuid | 73 cpuid |
| 70 | 74 |
| 71 movzx r10,cl | 75 movzx r10,cl |
| 72 inc r10 | 76 inc r10 |
| 73 | 77 |
| 74 mov eax,1 | 78 mov eax,1 |
| 75 cpuid | 79 cpuid |
| 76 | 80 |
| 77 bt edx,28 | 81 bt edx,28 |
| 78 » jnc» $L$generic | 82 » jnc» NEAR $L$generic |
| 79 shr ebx,16 | 83 shr ebx,16 |
| 80 cmp bl,r10b | 84 cmp bl,r10b |
| 81 » ja» $L$generic | 85 » ja» NEAR $L$generic |
| 82 » and» edx,0efffffffh | 86 » and» edx,0xefffffff |
| 83 » jmp» $L$generic | 87 » jmp» NEAR $L$generic |
| 84 | 88 |
| 85 $L$intel:: | 89 $L$intel: |
| 86 cmp r11d,4 | 90 cmp r11d,4 |
| 87 mov r10d,-1 | 91 mov r10d,-1 |
| 88 » jb» $L$nocacheinfo | 92 » jb» NEAR $L$nocacheinfo |
| 89 | 93 |
| 90 mov eax,4 | 94 mov eax,4 |
| 91 mov ecx,0 | 95 mov ecx,0 |
| 92 cpuid | 96 cpuid |
| 93 mov r10d,eax | 97 mov r10d,eax |
| 94 shr r10d,14 | 98 shr r10d,14 |
| 95 » and» r10d,0fffh | 99 » and» r10d,0xfff |
| 96 | 100 |
| 97 cmp r11d,7 | 101 cmp r11d,7 |
| 98 » jb» $L$nocacheinfo | 102 » jb» NEAR $L$nocacheinfo |
| 99 | 103 |
| 100 mov eax,7 | 104 mov eax,7 |
| 101 xor ecx,ecx | 105 xor ecx,ecx |
| 102 cpuid | 106 cpuid |
| 103 » mov» DWORD PTR[8+rdi],ebx | 107 » mov» DWORD[8+rdi],ebx |
| 104 | 108 |
| 105 $L$nocacheinfo:: | 109 $L$nocacheinfo: |
| 106 mov eax,1 | 110 mov eax,1 |
| 107 cpuid | 111 cpuid |
| 108 | 112 |
| 109 » and» edx,0bfefffffh | 113 » and» edx,0xbfefffff |
| 110 cmp r9d,0 | 114 cmp r9d,0 |
| 111 » jne» $L$notintel | 115 » jne» NEAR $L$notintel |
| 112 » or» edx,040000000h | 116 » or» edx,0x40000000 |
| 113 and ah,15 | 117 and ah,15 |
| 114 cmp ah,15 | 118 cmp ah,15 |
| 115 » jne» $L$notintel | 119 » jne» NEAR $L$notintel |
| 116 » or» edx,000100000h | 120 » or» edx,0x00100000 |
| 117 $L$notintel:: | 121 $L$notintel: |
| 118 bt edx,28 | 122 bt edx,28 |
| 119 » jnc» $L$generic | 123 » jnc» NEAR $L$generic |
| 120 » and» edx,0efffffffh | 124 » and» edx,0xefffffff |
| 121 cmp r10d,0 | 125 cmp r10d,0 |
| 122 » je» $L$generic | 126 » je» NEAR $L$generic |
| 123 | 127 |
| 124 » or» edx,010000000h | 128 » or» edx,0x10000000 |
| 125 shr ebx,16 | 129 shr ebx,16 |
| 126 cmp bl,1 | 130 cmp bl,1 |
| 127 » ja» $L$generic | 131 » ja» NEAR $L$generic |
| 128 » and» edx,0efffffffh | 132 » and» edx,0xefffffff |
| 129 $L$generic:: | 133 $L$generic: |
| 130 » and» r9d,000000800h | 134 » and» r9d,0x00000800 |
| 131 » and» ecx,0fffff7ffh | 135 » and» ecx,0xfffff7ff |
| 132 or r9d,ecx | 136 or r9d,ecx |
| 133 | 137 |
| 134 mov r10d,edx | 138 mov r10d,edx |
| 135 bt r9d,27 | 139 bt r9d,27 |
| 136 » jnc» $L$clear_avx | 140 » jnc» NEAR $L$clear_avx |
| 137 xor ecx,ecx | 141 xor ecx,ecx |
| 138 DB» 00fh,001h,0d0h | 142 DB» 0x0f,0x01,0xd0 |
| 139 and eax,6 | 143 and eax,6 |
| 140 cmp eax,6 | 144 cmp eax,6 |
| 141 » je» $L$done | 145 » je» NEAR $L$done |
| 142 $L$clear_avx:: | 146 $L$clear_avx: |
| 143 » mov» eax,0efffe7ffh | 147 » mov» eax,0xefffe7ff |
| 144 and r9d,eax | 148 and r9d,eax |
| 145 » and» DWORD PTR[8+rdi],0ffffffdfh | 149 » and» DWORD[8+rdi],0xffffffdf |
| 146 $L$done:: | 150 $L$done: |
| 147 » mov» DWORD PTR[4+rdi],r9d | 151 » mov» DWORD[4+rdi],r9d |
| 148 » mov» DWORD PTR[rdi],r10d | 152 » mov» DWORD[rdi],r10d |
| 149 mov rbx,r8 | 153 mov rbx,r8 |
| 150 » mov» rdi,QWORD PTR[8+rsp]» ;WIN64 epilogue | 154 » mov» rdi,QWORD[8+rsp]» ;WIN64 epilogue |
| 151 » mov» rsi,QWORD PTR[16+rsp] | 155 » mov» rsi,QWORD[16+rsp] |
| 152 DB 0F3h,0C3h ;repret | 156 DB 0F3h,0C3h ;repret |
| 153 $L$SEH_end_OPENSSL_ia32_cpuid:: | 157 $L$SEH_end_OPENSSL_ia32_cpuid: |
| 154 OPENSSL_ia32_cpuid» ENDP | |
| 155 | 158 |
| 156 | |
| 157 .text$ ENDS | |
| 158 END | |
| OLD | NEW |