Rev | Line | |
---|
[9] | 1 | .sect .text; .sect .rom; .sect .data; .sect .bss
|
---|
| 2 | .extern .div_ext
|
---|
| 3 | .sect .text
|
---|
| 4 | .div_ext:
|
---|
| 5 | push ebp
|
---|
| 6 | mov ebp,esp
|
---|
| 7 | sub esp,20
|
---|
| 8 | push esi
|
---|
| 9 | push edi
|
---|
| 10 | mov esi,8(ebp)
|
---|
| 11 | o16 mov -2(ebp),0
|
---|
| 12 | mov edx,12(ebp)
|
---|
| 13 | mov ecx,12(ebp)
|
---|
| 14 | mov ecx,8(ecx)
|
---|
| 15 | or ecx,4(edx)
|
---|
| 16 | jne I1_4
|
---|
| 17 | push 7
|
---|
| 18 | call __fptrp
|
---|
| 19 | pop ecx
|
---|
| 20 | xor edx,edx
|
---|
| 21 | mov 8(esi),edx
|
---|
| 22 | mov 4(esi),edx
|
---|
| 23 | o16 mov 2(esi),16383
|
---|
| 24 | jmp I1_1
|
---|
| 25 | I1_4:
|
---|
| 26 | mov edx,8(esi)
|
---|
| 27 | or edx,4(esi)
|
---|
| 28 | jne I1_7
|
---|
| 29 | o16 mov 2(esi),0
|
---|
| 30 | jmp I1_1
|
---|
| 31 | I1_7:
|
---|
| 32 | lea eax,4(esi)
|
---|
| 33 | push eax
|
---|
| 34 | call .b64_rsft
|
---|
| 35 | pop ecx
|
---|
| 36 | mov edx,12(ebp)
|
---|
| 37 | ! kill edx
|
---|
| 38 | add edx,4
|
---|
| 39 | push edx
|
---|
| 40 | call .b64_rsft
|
---|
| 41 | pop ecx
|
---|
| 42 | movsx eax,2(esi)
|
---|
| 43 | inc eax
|
---|
| 44 | movsx eax,eax
|
---|
| 45 | o16 mov 2(esi),eax
|
---|
| 46 | mov edx,12(ebp)
|
---|
| 47 | ! kill edx
|
---|
| 48 | movsx ebx,2(edx)
|
---|
| 49 | inc ebx
|
---|
| 50 | mov eax,ebx
|
---|
| 51 | movsx eax,eax
|
---|
| 52 | mov edx,12(ebp)
|
---|
| 53 | ! kill edx
|
---|
| 54 | o16 mov 2(edx),eax
|
---|
| 55 | mov edx,12(ebp)
|
---|
| 56 | movsx eax,(edx)
|
---|
| 57 | movsx ebx,(esi)
|
---|
| 58 | xor ebx,eax
|
---|
| 59 | o16 mov (esi),ebx
|
---|
| 60 | movsx eax,2(esi)
|
---|
| 61 | mov edx,12(ebp)
|
---|
| 62 | ! kill edx
|
---|
| 63 | movsx ecx,2(edx)
|
---|
| 64 | sub ecx,eax
|
---|
| 65 | neg ecx
|
---|
| 66 | mov eax,ecx
|
---|
| 67 | movsx eax,eax
|
---|
| 68 | o16 mov 2(esi),eax
|
---|
| 69 | o16 mov -18(ebp),64
|
---|
| 70 | mov -12(ebp),0
|
---|
| 71 | mov -8(ebp),0
|
---|
| 72 | I1_10:
|
---|
| 73 | movzx edx,-18(ebp)
|
---|
| 74 | mov eax,edx
|
---|
| 75 | movsx eax,eax
|
---|
| 76 | dec eax
|
---|
| 77 | o16 mov -18(ebp),eax
|
---|
| 78 | mov eax,edx
|
---|
| 79 | movsx eax,eax
|
---|
| 80 | test eax,eax
|
---|
| 81 | je I1_9
|
---|
| 82 | lea eax,-12(ebp)
|
---|
| 83 | push eax
|
---|
| 84 | call .b64_lsft
|
---|
| 85 | pop ecx
|
---|
| 86 | mov edx,12(ebp)
|
---|
| 87 | mov edx,4(edx)
|
---|
| 88 | cmp 4(esi),edx
|
---|
| 89 | jb I1_14
|
---|
| 90 | mov edx,12(ebp)
|
---|
| 91 | mov edx,4(edx)
|
---|
| 92 | cmp 4(esi),edx
|
---|
| 93 | jne I1_13
|
---|
| 94 | mov edx,12(ebp)
|
---|
| 95 | mov edx,8(edx)
|
---|
| 96 | cmp 8(esi),edx
|
---|
| 97 | jb I1_14
|
---|
| 98 | I1_13:
|
---|
| 99 | inc -8(ebp)
|
---|
| 100 | mov edx,12(ebp)
|
---|
| 101 | mov ecx,8(esi)
|
---|
| 102 | cmp 8(edx),ecx
|
---|
| 103 | jbe I1_18
|
---|
| 104 | mov edx,4(esi)
|
---|
| 105 | sub edx,1
|
---|
| 106 | mov 4(esi),edx
|
---|
| 107 | I1_18:
|
---|
| 108 | mov edx,12(ebp)
|
---|
| 109 | mov ecx,4(esi)
|
---|
| 110 | sub ecx,4(edx)
|
---|
| 111 | mov 4(esi),ecx
|
---|
| 112 | mov edx,12(ebp)
|
---|
| 113 | mov ecx,8(esi)
|
---|
| 114 | sub ecx,8(edx)
|
---|
| 115 | mov 8(esi),ecx
|
---|
| 116 | I1_14:
|
---|
| 117 | mov edi,esi
|
---|
| 118 | add edi,4
|
---|
| 119 | mov edx,(edi)
|
---|
| 120 | or edx,4(edi)
|
---|
| 121 | je I1_21
|
---|
| 122 | mov eax,1
|
---|
| 123 | jmp I1_22
|
---|
| 124 | I1_21:
|
---|
| 125 | xor eax,eax
|
---|
| 126 | I1_22:
|
---|
| 127 | o16 mov -2(ebp),eax
|
---|
| 128 | movzx edx,-2(ebp)
|
---|
| 129 | test edx,edx
|
---|
| 130 | je I1_9
|
---|
| 131 | lea eax,4(esi)
|
---|
| 132 | push eax
|
---|
| 133 | call .b64_lsft
|
---|
| 134 | pop ecx
|
---|
| 135 | jmp I1_10
|
---|
| 136 | I1_9:
|
---|
| 137 | movsx eax,-18(ebp)
|
---|
| 138 | ! kill cc
|
---|
| 139 | test eax,eax
|
---|
| 140 | jle I1_27
|
---|
| 141 | lea edi,-12(ebp)
|
---|
| 142 | movsx eax,-18(ebp)
|
---|
| 143 | cmp eax,31
|
---|
| 144 | jle I1_30
|
---|
| 145 | mov edx,4(edi)
|
---|
| 146 | mov (edi),edx
|
---|
| 147 | movsx eax,-18(ebp)
|
---|
| 148 | sub eax,32
|
---|
| 149 | o16 mov -18(ebp),eax
|
---|
| 150 | mov 4(edi),0
|
---|
| 151 | I1_30:
|
---|
| 152 | cmp (edi),0
|
---|
| 153 | je I1_33
|
---|
| 154 | movsx eax,-18(ebp)
|
---|
| 155 | mov ecx,eax
|
---|
| 156 | mov edx,(edi)
|
---|
| 157 | sal edx,cl
|
---|
| 158 | mov (edi),edx
|
---|
| 159 | I1_33:
|
---|
| 160 | add edi,4
|
---|
| 161 | cmp (edi),0
|
---|
| 162 | je I1_27
|
---|
| 163 | movsx eax,-18(ebp)
|
---|
| 164 | sub eax,32
|
---|
| 165 | neg eax
|
---|
| 166 | mov ecx,eax
|
---|
| 167 | mov edx,(edi)
|
---|
| 168 | shr edx,cl
|
---|
| 169 | or -12(ebp),edx
|
---|
| 170 | movsx eax,-18(ebp)
|
---|
| 171 | mov ecx,eax
|
---|
| 172 | mov edx,(edi)
|
---|
| 173 | sal edx,cl
|
---|
| 174 | mov (edi),edx
|
---|
| 175 | I1_27:
|
---|
| 176 | lea eax,-12(ebp)
|
---|
| 177 | push eax
|
---|
| 178 | lea eax,4(esi)
|
---|
| 179 | push eax
|
---|
| 180 | mov ecx,2
|
---|
| 181 | call .blm
|
---|
| 182 | push esi
|
---|
| 183 | call .nrm_ext
|
---|
| 184 | pop ecx
|
---|
| 185 | movsx eax,2(esi)
|
---|
| 186 | cmp eax,-16382
|
---|
| 187 | jge I1_39
|
---|
| 188 | push 5
|
---|
| 189 | call __fptrp
|
---|
| 190 | pop ecx
|
---|
| 191 | o16 mov 2(esi),-16382
|
---|
| 192 | xor edx,edx
|
---|
| 193 | mov 8(esi),edx
|
---|
| 194 | mov 4(esi),edx
|
---|
| 195 | jmp I1_1
|
---|
| 196 | I1_39:
|
---|
| 197 | movsx eax,2(esi)
|
---|
| 198 | cmp eax,16383
|
---|
| 199 | jl I1_1
|
---|
| 200 | push 4
|
---|
| 201 | call __fptrp
|
---|
| 202 | pop ecx
|
---|
| 203 | o16 mov 2(esi),16383
|
---|
| 204 | xor edx,edx
|
---|
| 205 | mov 8(esi),edx
|
---|
| 206 | mov 4(esi),edx
|
---|
| 207 | I1_1:
|
---|
| 208 | pop edi
|
---|
| 209 | pop esi
|
---|
| 210 | leave
|
---|
| 211 | ret
|
---|
Note:
See
TracBrowser
for help on using the repository browser.