client/game/llr.dll/lifted-0000.c (416936B)
1 #define RECOMP_GENERATED_CODE 2 #include "recomp_types.h" 3 #include <math.h> 4 #include <stdio.h> 5 #include <stdlib.h> 6 #include <string.h> 7 8 void sub_38001000(void) { 9 int _fpu_cmp = 0; 10 uint32_t _cf = 0; 11 int _df = 1; 12 uint32_t _flag_k = FK_NONE; 13 uint32_t _flag_a = 0, _flag_b = 0; 14 uint32_t _itail_tgt = 0; 15 RECOMP_REGS_LOCALS 16 RECOMP_ENTER(0x38001000u); 17 18 L_38001000: 19 RECOMP_ICALL(0x38001010u); /* 0x38001000: call 0x38001010 */ /* not lifted */ 20 RECOMP_FLAGS_IN(); 21 goto L_38001020; /* 0x38001005: jmp 0x38001020 */ 22 L_38001020: 23 PUSH32(esp, 0x38001030u); /* 0x38001020: push 0x38001030 */ 24 RECOMP_ICALL(0x3804B54Cu); /* 0x38001025: call 0x3804b54c */ /* not lifted */ 25 RECOMP_FLAGS_IN(); 26 ecx = POP32_VAL(esp); /* 0x3800102A: pop ecx */ 27 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800102B: ret */ 28 RECOMP_REGS_OUT(); 29 } 30 31 void sub_38001010(void) { 32 int _fpu_cmp = 0; 33 uint32_t _cf = 0; 34 int _df = 1; 35 uint32_t _flag_k = FK_NONE; 36 uint32_t _flag_a = 0, _flag_b = 0; 37 uint32_t _itail_tgt = 0; 38 RECOMP_REGS_LOCALS 39 RECOMP_ENTER(0x38001010u); 40 41 L_38001010: 42 ecx = 0x3806E99Eu; /* 0x38001010: mov ecx, 0x3806e99e */ 43 L_38001015: 44 { _itail_tgt = (uint32_t)(MEM32(0x3804E060)); goto _ljump; } 45 { RECOMP_REGS_OUT(); return; } /* end of function */ 46 _ljump: 47 switch (_itail_tgt) { 48 case 0x38001010u: goto L_38001010; 49 case 0x38001015u: goto L_38001015; 50 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 51 } 52 RECOMP_REGS_OUT(); 53 } 54 55 void sub_38001020(void) { 56 int _fpu_cmp = 0; 57 uint32_t _cf = 0; 58 int _df = 1; 59 uint32_t _flag_k = FK_NONE; 60 uint32_t _flag_a = 0, _flag_b = 0; 61 uint32_t _itail_tgt = 0; 62 RECOMP_REGS_LOCALS 63 RECOMP_ENTER(0x38001020u); 64 65 L_38001020: 66 PUSH32(esp, 0x38001030u); /* 0x38001020: push 0x38001030 */ 67 RECOMP_ICALL(0x3804B54Cu); /* 0x38001025: call 0x3804b54c */ /* not lifted */ 68 RECOMP_FLAGS_IN(); 69 ecx = POP32_VAL(esp); /* 0x3800102A: pop ecx */ 70 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800102B: ret */ 71 RECOMP_REGS_OUT(); 72 } 73 74 void sub_38001030(void) { 75 int _fpu_cmp = 0; 76 uint32_t _cf = 0; 77 int _df = 1; 78 uint32_t _flag_k = FK_NONE; 79 uint32_t _flag_a = 0, _flag_b = 0; 80 uint32_t _itail_tgt = 0; 81 RECOMP_REGS_LOCALS 82 RECOMP_ENTER(0x38001030u); 83 84 L_38001030: 85 ecx = 0x3806E99Eu; /* 0x38001030: mov ecx, 0x3806e99e */ 86 L_38001035: 87 { _itail_tgt = (uint32_t)(MEM32(0x3804E064)); goto _ljump; } 88 { RECOMP_REGS_OUT(); return; } /* end of function */ 89 _ljump: 90 switch (_itail_tgt) { 91 case 0x38001030u: goto L_38001030; 92 case 0x38001035u: goto L_38001035; 93 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 94 } 95 RECOMP_REGS_OUT(); 96 } 97 98 void sub_38001040(void) { 99 int _fpu_cmp = 0; 100 uint32_t _cf = 0; 101 int _df = 1; 102 uint32_t _flag_k = FK_NONE; 103 uint32_t _flag_a = 0, _flag_b = 0; 104 uint32_t _itail_tgt = 0; 105 RECOMP_REGS_LOCALS 106 RECOMP_ENTER(0x38001040u); 107 108 L_38001040: 109 RECOMP_ICALL(0x38001050u); /* 0x38001040: call 0x38001050 */ /* not lifted */ 110 RECOMP_FLAGS_IN(); 111 goto L_38001060; /* 0x38001045: jmp 0x38001060 */ 112 L_38001060: 113 PUSH32(esp, 0x38001070u); /* 0x38001060: push 0x38001070 */ 114 RECOMP_ICALL(0x3804B54Cu); /* 0x38001065: call 0x3804b54c */ /* not lifted */ 115 RECOMP_FLAGS_IN(); 116 ecx = POP32_VAL(esp); /* 0x3800106A: pop ecx */ 117 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800106B: ret */ 118 RECOMP_REGS_OUT(); 119 } 120 121 void sub_38001050(void) { 122 int _fpu_cmp = 0; 123 uint32_t _cf = 0; 124 int _df = 1; 125 uint32_t _flag_k = FK_NONE; 126 uint32_t _flag_a = 0, _flag_b = 0; 127 uint32_t _itail_tgt = 0; 128 RECOMP_REGS_LOCALS 129 RECOMP_ENTER(0x38001050u); 130 131 L_38001050: 132 ecx = 0x3806E99Du; /* 0x38001050: mov ecx, 0x3806e99d */ 133 L_38001055: 134 { _itail_tgt = (uint32_t)(MEM32(0x3804E068)); goto _ljump; } 135 { RECOMP_REGS_OUT(); return; } /* end of function */ 136 _ljump: 137 switch (_itail_tgt) { 138 case 0x38001050u: goto L_38001050; 139 case 0x38001055u: goto L_38001055; 140 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 141 } 142 RECOMP_REGS_OUT(); 143 } 144 145 void sub_38001060(void) { 146 int _fpu_cmp = 0; 147 uint32_t _cf = 0; 148 int _df = 1; 149 uint32_t _flag_k = FK_NONE; 150 uint32_t _flag_a = 0, _flag_b = 0; 151 uint32_t _itail_tgt = 0; 152 RECOMP_REGS_LOCALS 153 RECOMP_ENTER(0x38001060u); 154 155 L_38001060: 156 PUSH32(esp, 0x38001070u); /* 0x38001060: push 0x38001070 */ 157 RECOMP_ICALL(0x3804B54Cu); /* 0x38001065: call 0x3804b54c */ /* not lifted */ 158 RECOMP_FLAGS_IN(); 159 ecx = POP32_VAL(esp); /* 0x3800106A: pop ecx */ 160 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800106B: ret */ 161 RECOMP_REGS_OUT(); 162 } 163 164 void sub_38001070(void) { 165 int _fpu_cmp = 0; 166 uint32_t _cf = 0; 167 int _df = 1; 168 uint32_t _flag_k = FK_NONE; 169 uint32_t _flag_a = 0, _flag_b = 0; 170 uint32_t _itail_tgt = 0; 171 RECOMP_REGS_LOCALS 172 RECOMP_ENTER(0x38001070u); 173 174 L_38001070: 175 ecx = 0x3806E99Du; /* 0x38001070: mov ecx, 0x3806e99d */ 176 L_38001075: 177 { _itail_tgt = (uint32_t)(MEM32(0x3804E06C)); goto _ljump; } 178 { RECOMP_REGS_OUT(); return; } /* end of function */ 179 _ljump: 180 switch (_itail_tgt) { 181 case 0x38001070u: goto L_38001070; 182 case 0x38001075u: goto L_38001075; 183 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 184 } 185 RECOMP_REGS_OUT(); 186 } 187 188 void sub_38001080(void) { 189 int _fpu_cmp = 0; 190 uint32_t _cf = 0; 191 int _df = 1; 192 uint32_t _flag_k = FK_NONE; 193 uint32_t _flag_a = 0, _flag_b = 0; 194 uint32_t _itail_tgt = 0; 195 RECOMP_REGS_LOCALS 196 RECOMP_ENTER(0x38001080u); 197 198 L_38001080: 199 PUSH32(esp, ebp); /* 0x38001080: push ebp */ 200 ebp = esp; /* 0x38001081: mov ebp, esp */ 201 eax = MEM32(ebp + 0x8); /* 0x38001083: mov eax, dword ptr [ebp + 8] */ 202 MEM32(ecx + 0x134) = eax; /* 0x38001086: mov dword ptr [ecx + 0x134], eax */ 203 ebp = POP32_VAL(esp); /* 0x3800108C: pop ebp */ 204 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800108D: ret 4 */ 205 RECOMP_REGS_OUT(); 206 } 207 208 void sub_38001090(void) { 209 int _fpu_cmp = 0; 210 uint32_t _cf = 0; 211 int _df = 1; 212 uint32_t _flag_k = FK_NONE; 213 uint32_t _flag_a = 0, _flag_b = 0; 214 uint32_t _itail_tgt = 0; 215 RECOMP_REGS_LOCALS 216 RECOMP_ENTER(0x38001090u); 217 218 L_38001090: 219 PUSH32(esp, ebp); /* 0x38001090: push ebp */ 220 ebp = esp; /* 0x38001091: mov ebp, esp */ 221 SET_LO8(eax, MEM8(ebp + 0x8)); /* 0x38001093: mov al, byte ptr [ebp + 8] */ 222 MEM8(ecx + 0x1C4) = (uint8_t)(LO8(eax)); /* 0x38001096: mov byte ptr [ecx + 0x1c4], al */ 223 ebp = POP32_VAL(esp); /* 0x3800109C: pop ebp */ 224 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800109D: ret 4 */ 225 RECOMP_REGS_OUT(); 226 } 227 228 void sub_380010A0(void) { 229 int _fpu_cmp = 0; 230 uint32_t _cf = 0; 231 int _df = 1; 232 uint32_t _flag_k = FK_NONE; 233 uint32_t _flag_a = 0, _flag_b = 0; 234 uint32_t _itail_tgt = 0; 235 RECOMP_REGS_LOCALS 236 RECOMP_ENTER(0x380010A0u); 237 238 L_380010A0: 239 SET_LO8(eax, MEM8(ecx + 0x1C5)); /* 0x380010A0: mov al, byte ptr [ecx + 0x1c5] */ 240 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380010A6: ret */ 241 RECOMP_REGS_OUT(); 242 } 243 244 void sub_380010B0(void) { 245 int _fpu_cmp = 0; 246 uint32_t _cf = 0; 247 int _df = 1; 248 uint32_t _flag_k = FK_NONE; 249 uint32_t _flag_a = 0, _flag_b = 0; 250 uint32_t _itail_tgt = 0; 251 RECOMP_REGS_LOCALS 252 RECOMP_ENTER(0x380010B0u); 253 254 L_380010B0: 255 eax = ecx + 0x15C; /* 0x380010B0: lea eax, [ecx + 0x15c] */ 256 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380010B6: ret */ 257 RECOMP_REGS_OUT(); 258 } 259 260 void sub_380010C0(void) { 261 int _fpu_cmp = 0; 262 uint32_t _cf = 0; 263 int _df = 1; 264 uint32_t _flag_k = FK_NONE; 265 uint32_t _flag_a = 0, _flag_b = 0; 266 uint32_t _itail_tgt = 0; 267 RECOMP_REGS_LOCALS 268 RECOMP_ENTER(0x380010C0u); 269 270 L_380010C0: 271 fp_push(*(float*)&MEM32(ecx + 0x194)); /* 0x380010C0: fld dword ptr [ecx + 0x194] */ 272 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380010C6: ret */ 273 RECOMP_REGS_OUT(); 274 } 275 276 void sub_380010D0(void) { 277 int _fpu_cmp = 0; 278 uint32_t _cf = 0; 279 int _df = 1; 280 uint32_t _flag_k = FK_NONE; 281 uint32_t _flag_a = 0, _flag_b = 0; 282 uint32_t _itail_tgt = 0; 283 RECOMP_REGS_LOCALS 284 RECOMP_ENTER(0x380010D0u); 285 286 L_380010D0: 287 eax = ecx; /* 0x380010D0: mov eax, ecx */ 288 MEM32(eax) = 0x3804E7C4u; /* 0x380010D2: mov dword ptr [eax], 0x3804e7c4 */ 289 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380010D8: ret */ 290 RECOMP_REGS_OUT(); 291 } 292 293 void sub_380010E0(void) { 294 int _fpu_cmp = 0; 295 uint32_t _cf = 0; 296 int _df = 1; 297 uint32_t _flag_k = FK_NONE; 298 uint32_t _flag_a = 0, _flag_b = 0; 299 uint32_t _itail_tgt = 0; 300 RECOMP_REGS_LOCALS 301 RECOMP_ENTER(0x380010E0u); 302 303 L_380010E0: 304 eax = ecx; /* 0x380010E0: mov eax, ecx */ 305 MEM32(eax) = 0x3804E7C4u; /* 0x380010E2: mov dword ptr [eax], 0x3804e7c4 */ 306 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380010E8: ret 4 */ 307 RECOMP_REGS_OUT(); 308 } 309 310 void sub_380010F0(void) { 311 int _fpu_cmp = 0; 312 uint32_t _cf = 0; 313 int _df = 1; 314 uint32_t _flag_k = FK_NONE; 315 uint32_t _flag_a = 0, _flag_b = 0; 316 uint32_t _itail_tgt = 0; 317 RECOMP_REGS_LOCALS 318 RECOMP_ENTER(0x380010F0u); 319 320 L_380010F0: 321 eax = ecx; /* 0x380010F0: mov eax, ecx */ 322 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380010F2: ret 4 */ 323 RECOMP_REGS_OUT(); 324 } 325 326 void sub_38001100(void) { 327 int _fpu_cmp = 0; 328 uint32_t _cf = 0; 329 int _df = 1; 330 uint32_t _flag_k = FK_NONE; 331 uint32_t _flag_a = 0, _flag_b = 0; 332 uint32_t _itail_tgt = 0; 333 RECOMP_REGS_LOCALS 334 RECOMP_ENTER(0x38001100u); 335 336 L_38001100: 337 edx = MEM32(ecx + 0x4); /* 0x38001100: mov edx, dword ptr [ecx + 4] */ 338 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 339 eax = 0; /* 0x38001103: xor eax, eax */ 340 _cf = 0; 341 _flag_k = FK_TEST; 342 /* test edx, edx */ /* 0x38001105: test edx, edx */ 343 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx); 344 _cf = 0; 345 _flag_k = FK_TEST; 346 SET_LO8(eax, (TEST_NZ(_flag_a, _flag_b)) ? 1 : 0); /* 0x38001107: setne al */ 347 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800110A: ret */ 348 RECOMP_REGS_OUT(); 349 } 350 351 void sub_38001110(void) { 352 int _fpu_cmp = 0; 353 uint32_t _cf = 0; 354 int _df = 1; 355 uint32_t _flag_k = FK_NONE; 356 uint32_t _flag_a = 0, _flag_b = 0; 357 uint32_t _itail_tgt = 0; 358 RECOMP_REGS_LOCALS 359 RECOMP_ENTER(0x38001110u); 360 361 L_38001110: 362 PUSH32(esp, ebp); /* 0x38001110: push ebp */ 363 ebp = esp; /* 0x38001111: mov ebp, esp */ 364 eax = ecx; /* 0x38001113: mov eax, ecx */ 365 ecx = MEM32(ebp + 0x8); /* 0x38001115: mov ecx, dword ptr [ebp + 8] */ 366 MEM32(eax) = 0x3804E7C4u; /* 0x38001118: mov dword ptr [eax], 0x3804e7c4 */ 367 edx = MEM32(ecx + 0x4); /* 0x3800111E: mov edx, dword ptr [ecx + 4] */ 368 MEM32(eax + 0x4) = edx; /* 0x38001121: mov dword ptr [eax + 4], edx */ 369 MEM32(eax) = 0x3804E7D4u; /* 0x38001124: mov dword ptr [eax], 0x3804e7d4 */ 370 ebp = POP32_VAL(esp); /* 0x3800112A: pop ebp */ 371 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800112B: ret 4 */ 372 RECOMP_REGS_OUT(); 373 } 374 375 void sub_38001130(void) { 376 int _fpu_cmp = 0; 377 uint32_t _cf = 0; 378 int _df = 1; 379 uint32_t _flag_k = FK_NONE; 380 uint32_t _flag_a = 0, _flag_b = 0; 381 uint32_t _itail_tgt = 0; 382 RECOMP_REGS_LOCALS 383 RECOMP_ENTER(0x38001130u); 384 385 L_38001130: 386 PUSH32(esp, ebp); /* 0x38001130: push ebp */ 387 ebp = esp; /* 0x38001131: mov ebp, esp */ 388 eax = ecx; /* 0x38001133: mov eax, ecx */ 389 ecx = MEM32(ebp + 0x8); /* 0x38001135: mov ecx, dword ptr [ebp + 8] */ 390 edx = MEM32(ecx + 0x4); /* 0x38001138: mov edx, dword ptr [ecx + 4] */ 391 MEM32(eax + 0x4) = edx; /* 0x3800113B: mov dword ptr [eax + 4], edx */ 392 ebp = POP32_VAL(esp); /* 0x3800113E: pop ebp */ 393 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800113F: ret 4 */ 394 RECOMP_REGS_OUT(); 395 } 396 397 void sub_38001150(void) { 398 int _fpu_cmp = 0; 399 uint32_t _cf = 0; 400 int _df = 1; 401 uint32_t _flag_k = FK_NONE; 402 uint32_t _flag_a = 0, _flag_b = 0; 403 uint32_t _itail_tgt = 0; 404 RECOMP_REGS_LOCALS 405 RECOMP_ENTER(0x38001150u); 406 407 L_38001150: 408 PUSH32(esp, ebp); /* 0x38001150: push ebp */ 409 ebp = esp; /* 0x38001151: mov ebp, esp */ 410 PUSH32(esp, ebx); /* 0x38001153: push ebx */ 411 SET_LO8(ebx, MEM8(ebp + 0x8)); /* 0x38001154: mov bl, byte ptr [ebp + 8] */ 412 /* test LO8(ebx), 2 */ /* 0x38001157: test bl, 2 */ 413 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(2) << 24; 414 _cf = 0; 415 _flag_k = FK_NARROW(FK_TEST, 24); 416 PUSH32(esp, esi); /* 0x3800115A: push esi */ 417 esi = ecx; /* 0x3800115B: mov esi, ecx */ 418 if (TEST_Z(_flag_a, _flag_b)) goto L_3800118B; /* 0x3800115D: je 0x3800118b */ 419 L_3800115F: 420 eax = MEM32(esi + (-0x4)); /* 0x3800115F: mov eax, dword ptr [esi - 4] */ 421 PUSH32(esp, edi); /* 0x38001162: push edi */ 422 PUSH32(esp, 0x3801E660u); /* 0x38001163: push 0x3801e660 */ 423 edi = esi + (-0x4); /* 0x38001168: lea edi, [esi - 4] */ 424 PUSH32(esp, eax); /* 0x3800116B: push eax */ 425 PUSH32(esp, 8); /* 0x3800116C: push 8 */ 426 PUSH32(esp, esi); /* 0x3800116E: push esi */ 427 RECOMP_ICALL(0x3804B582u); /* 0x3800116F: call 0x3804b582 */ /* not lifted */ 428 RECOMP_FLAGS_IN(); 429 /* test LO8(ebx), 1 */ /* 0x38001174: test bl, 1 */ 430 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(1) << 24; 431 _cf = 0; 432 _flag_k = FK_NARROW(FK_TEST, 24); 433 if (TEST_Z(_flag_a, _flag_b)) goto L_38001182; /* 0x38001177: je 0x38001182 */ 434 L_38001179: 435 PUSH32(esp, edi); /* 0x38001179: push edi */ 436 RECOMP_ICALL(0x3804B4F6u); /* 0x3800117A: call 0x3804b4f6 */ /* not lifted */ 437 RECOMP_FLAGS_IN(); 438 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 439 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 440 esp = esp + 4; /* 0x3800117F: add esp, 4 */ 441 _flag_k = FK_ADD; 442 L_38001182: 443 eax = edi; /* 0x38001182: mov eax, edi */ 444 edi = POP32_VAL(esp); /* 0x38001184: pop edi */ 445 esi = POP32_VAL(esp); /* 0x38001185: pop esi */ 446 ebx = POP32_VAL(esp); /* 0x38001186: pop ebx */ 447 ebp = POP32_VAL(esp); /* 0x38001187: pop ebp */ 448 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001188: ret 4 */ 449 L_3800118B: 450 ecx = esi; /* 0x3800118B: mov ecx, esi */ 451 RECOMP_ICALL(0x3801E660u); /* 0x3800118D: call 0x3801e660 */ /* not lifted */ 452 RECOMP_FLAGS_IN(); 453 /* test LO8(ebx), 1 */ /* 0x38001192: test bl, 1 */ 454 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(1) << 24; 455 _cf = 0; 456 _flag_k = FK_NARROW(FK_TEST, 24); 457 if (TEST_Z(_flag_a, _flag_b)) goto L_380011A0; /* 0x38001195: je 0x380011a0 */ 458 L_38001197: 459 PUSH32(esp, esi); /* 0x38001197: push esi */ 460 RECOMP_ICALL(0x3804B4F6u); /* 0x38001198: call 0x3804b4f6 */ /* not lifted */ 461 RECOMP_FLAGS_IN(); 462 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 463 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 464 esp = esp + 4; /* 0x3800119D: add esp, 4 */ 465 _flag_k = FK_ADD; 466 L_380011A0: 467 eax = esi; /* 0x380011A0: mov eax, esi */ 468 esi = POP32_VAL(esp); /* 0x380011A2: pop esi */ 469 ebx = POP32_VAL(esp); /* 0x380011A3: pop ebx */ 470 ebp = POP32_VAL(esp); /* 0x380011A4: pop ebp */ 471 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380011A5: ret 4 */ 472 RECOMP_REGS_OUT(); 473 } 474 475 void sub_380011B0(void) { 476 int _fpu_cmp = 0; 477 uint32_t _cf = 0; 478 int _df = 1; 479 uint32_t _flag_k = FK_NONE; 480 uint32_t _flag_a = 0, _flag_b = 0; 481 uint32_t _itail_tgt = 0; 482 RECOMP_REGS_LOCALS 483 RECOMP_ENTER(0x380011B0u); 484 485 L_380011B0: 486 _flag_a = (uint32_t)(MEM32(ecx + 0x18)); _flag_b = (uint32_t)(1); 487 MEM32(ecx + 0x18) = MEM32(ecx + 0x18) + 1; /* 0x380011B0: inc dword ptr [ecx + 0x18] */ 488 _flag_k = FK_INC; 489 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380011B3: ret */ 490 RECOMP_REGS_OUT(); 491 } 492 493 void sub_380011C0(void) { 494 int _fpu_cmp = 0; 495 uint32_t _cf = 0; 496 int _df = 1; 497 uint32_t _flag_k = FK_NONE; 498 uint32_t _flag_a = 0, _flag_b = 0; 499 uint32_t _itail_tgt = 0; 500 RECOMP_REGS_LOCALS 501 RECOMP_ENTER(0x380011C0u); 502 503 L_380011C0: 504 eax = MEM32(ecx + 0x18); /* 0x380011C0: mov eax, dword ptr [ecx + 0x18] */ 505 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380011C3: ret */ 506 RECOMP_REGS_OUT(); 507 } 508 509 void sub_380011D0(void) { 510 int _fpu_cmp = 0; 511 uint32_t _cf = 0; 512 int _df = 1; 513 uint32_t _flag_k = FK_NONE; 514 uint32_t _flag_a = 0, _flag_b = 0; 515 uint32_t _itail_tgt = 0; 516 RECOMP_REGS_LOCALS 517 RECOMP_ENTER(0x380011D0u); 518 519 L_380011D0: 520 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380011D0: ret 4 */ 521 RECOMP_REGS_OUT(); 522 } 523 524 void sub_380011E0(void) { 525 int _fpu_cmp = 0; 526 uint32_t _cf = 0; 527 int _df = 1; 528 uint32_t _flag_k = FK_NONE; 529 uint32_t _flag_a = 0, _flag_b = 0; 530 uint32_t _itail_tgt = 0; 531 RECOMP_REGS_LOCALS 532 RECOMP_ENTER(0x380011E0u); 533 534 L_380011E0: 535 PUSH32(esp, ebp); /* 0x380011E0: push ebp */ 536 ebp = esp; /* 0x380011E1: mov ebp, esp */ 537 PUSH32(esp, 0xFFFFFFFFu); /* 0x380011E3: push -1 */ 538 PUSH32(esp, 0x3804B901u); /* 0x380011E5: push 0x3804b901 */ 539 eax = MEM32(FS_BASE + (0)); /* 0x380011EA: mov eax, dword ptr fs:[0] */ 540 PUSH32(esp, eax); /* 0x380011F0: push eax */ 541 MEM32(FS_BASE + (0)) = esp; /* 0x380011F1: mov dword ptr fs:[0], esp */ 542 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu); 543 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 544 esp = esp - 0xCu; /* 0x380011F8: sub esp, 0xc */ 545 _flag_k = FK_CMP; 546 PUSH32(esp, ebx); /* 0x380011FB: push ebx */ 547 ebx = ecx; /* 0x380011FC: mov ebx, ecx */ 548 PUSH32(esp, esi); /* 0x380011FE: push esi */ 549 esi = MEM32(ebp + 0x8); /* 0x380011FF: mov esi, dword ptr [ebp + 8] */ 550 MEM32(ebx) = 0x3804E7C4u; /* 0x38001202: mov dword ptr [ebx], 0x3804e7c4 */ 551 SET_LO8(eax, MEM8(esi + 0x4)); /* 0x38001208: mov al, byte ptr [esi + 4] */ 552 MEM8(ebx + 0x4) = (uint8_t)(LO8(eax)); /* 0x3800120B: mov byte ptr [ebx + 4], al */ 553 ecx = MEM32(esi + 0x8); /* 0x3800120E: mov ecx, dword ptr [esi + 8] */ 554 /* test ecx, ecx */ /* 0x38001211: test ecx, ecx */ 555 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx); 556 _cf = 0; 557 _flag_k = FK_TEST; 558 PUSH32(esp, edi); /* 0x38001213: push edi */ 559 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800121A; /* 0x38001214: jne 0x3800121a */ 560 L_38001216: 561 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 562 eax = 0; /* 0x38001216: xor eax, eax */ 563 _cf = 0; 564 _flag_k = FK_TEST; 565 goto L_38001222; /* 0x38001218: jmp 0x38001222 */ 566 L_3800121A: 567 eax = MEM32(esi + 0xC); /* 0x3800121A: mov eax, dword ptr [esi + 0xc] */ 568 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx); 569 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 570 eax = eax - ecx; /* 0x3800121D: sub eax, ecx */ 571 _flag_k = FK_CMP; 572 if (3u) _cf = (((eax) >> 2) & 1u); /* 0x3800121F: sar eax, 3 */ 573 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 574 eax = (uint32_t)((int32_t)eax >> 3u); 575 L_38001222: 576 /* test eax, eax */ /* 0x38001222: test eax, eax */ 577 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 578 _cf = 0; 579 _flag_k = FK_TEST; 580 if (TEST_NS(_flag_a, _flag_b)) goto L_38001228; /* 0x38001224: jge 0x38001228 */ 581 L_38001226: 582 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 583 eax = 0; /* 0x38001226: xor eax, eax */ 584 _cf = 0; 585 _flag_k = FK_TEST; 586 L_38001228: 587 ecx = eax * 8; /* 0x38001228: lea ecx, [eax*8] */ 588 PUSH32(esp, ecx); /* 0x3800122F: push ecx */ 589 RECOMP_ICALL(0x3804B676u); /* 0x38001230: call 0x3804b676 */ /* not lifted */ 590 RECOMP_FLAGS_IN(); 591 MEM32(ebx + 0x8) = eax; /* 0x38001235: mov dword ptr [ebx + 8], eax */ 592 ecx = MEM32(esi + 0xC); /* 0x38001238: mov ecx, dword ptr [esi + 0xc] */ 593 edi = MEM32(esi + 0x8); /* 0x3800123B: mov edi, dword ptr [esi + 8] */ 594 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 595 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 596 esp = esp + 4; /* 0x3800123E: add esp, 4 */ 597 _flag_k = FK_ADD; 598 /* cmp edi, ecx */ /* 0x38001241: cmp edi, ecx */ 599 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx); 600 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 601 _flag_k = FK_CMP; 602 esi = eax; /* 0x38001243: mov esi, eax */ 603 MEM32(ebp + (-0x10)) = ecx; /* 0x38001245: mov dword ptr [ebp - 0x10], ecx */ 604 MEM32(ebp + (-0x14)) = esi; /* 0x38001248: mov dword ptr [ebp - 0x14], esi */ 605 if (CMP_EQ(_flag_a, _flag_b)) goto L_3800127A; /* 0x3800124B: je 0x3800127a */ 606 L_3800124D: 607 MEM32(ebp + (-0x18)) = esi; /* 0x3800124D: mov dword ptr [ebp - 0x18], esi */ 608 /* test esi, esi */ /* 0x38001250: test esi, esi */ 609 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi); 610 _cf = 0; 611 _flag_k = FK_TEST; 612 MEM32(ebp + (-0x4)) = 0; /* 0x38001252: mov dword ptr [ebp - 4], 0 */ 613 if (TEST_Z(_flag_a, _flag_b)) goto L_38001266; /* 0x38001259: je 0x38001266 */ 614 L_3800125B: 615 PUSH32(esp, edi); /* 0x3800125B: push edi */ 616 ecx = esi; /* 0x3800125C: mov ecx, esi */ 617 RECOMP_ICALL(0x3801E560u); /* 0x3800125E: call 0x3801e560 */ /* not lifted */ 618 RECOMP_FLAGS_IN(); 619 ecx = MEM32(ebp + (-0x10)); /* 0x38001263: mov ecx, dword ptr [ebp - 0x10] */ 620 L_38001266: 621 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 622 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 623 esi = esi + 8; /* 0x38001266: add esi, 8 */ 624 _flag_k = FK_ADD; 625 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(8); 626 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 627 edi = edi + 8; /* 0x38001269: add edi, 8 */ 628 _flag_k = FK_ADD; 629 /* cmp edi, ecx */ /* 0x3800126C: cmp edi, ecx */ 630 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx); 631 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 632 _flag_k = FK_CMP; 633 MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3800126E: mov dword ptr [ebp - 4], 0xffffffff */ 634 MEM32(ebp + (-0x14)) = esi; /* 0x38001275: mov dword ptr [ebp - 0x14], esi */ 635 RECOMP_BACKEDGE(); 636 if (CMP_NE(_flag_a, _flag_b)) goto L_3800124D; /* 0x38001278: jne 0x3800124d */ 637 L_3800127A: 638 eax = MEM32(ebp + 0x8); /* 0x3800127A: mov eax, dword ptr [ebp + 8] */ 639 ecx = MEM32(ebp + (-0xC)); /* 0x3800127D: mov ecx, dword ptr [ebp - 0xc] */ 640 MEM32(ebx + 0xC) = esi; /* 0x38001280: mov dword ptr [ebx + 0xc], esi */ 641 MEM32(ebx + 0x10) = esi; /* 0x38001283: mov dword ptr [ebx + 0x10], esi */ 642 SET_LO8(edx, MEM8(eax + 0x14)); /* 0x38001286: mov dl, byte ptr [eax + 0x14] */ 643 MEM8(ebx + 0x14) = (uint8_t)(LO8(edx)); /* 0x38001289: mov byte ptr [ebx + 0x14], dl */ 644 eax = MEM32(eax + 0x18); /* 0x3800128C: mov eax, dword ptr [eax + 0x18] */ 645 edi = POP32_VAL(esp); /* 0x3800128F: pop edi */ 646 MEM32(ebx + 0x18) = eax; /* 0x38001290: mov dword ptr [ebx + 0x18], eax */ 647 MEM32(ebx) = 0x3804E7E8u; /* 0x38001293: mov dword ptr [ebx], 0x3804e7e8 */ 648 esi = POP32_VAL(esp); /* 0x38001299: pop esi */ 649 eax = ebx; /* 0x3800129A: mov eax, ebx */ 650 ebx = POP32_VAL(esp); /* 0x3800129C: pop ebx */ 651 MEM32(FS_BASE + (0)) = ecx; /* 0x3800129D: mov dword ptr fs:[0], ecx */ 652 esp = ebp; /* 0x380012A4: mov esp, ebp */ 653 ebp = POP32_VAL(esp); /* 0x380012A6: pop ebp */ 654 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380012A7: ret 4 */ 655 RECOMP_REGS_OUT(); 656 } 657 658 void sub_380012B0(void) { 659 int _fpu_cmp = 0; 660 uint32_t _cf = 0; 661 int _df = 1; 662 uint32_t _flag_k = FK_NONE; 663 uint32_t _flag_a = 0, _flag_b = 0; 664 uint32_t _itail_tgt = 0; 665 RECOMP_REGS_LOCALS 666 RECOMP_ENTER(0x380012B0u); 667 668 L_380012B0: 669 PUSH32(esp, ebp); /* 0x380012B0: push ebp */ 670 ebp = esp; /* 0x380012B1: mov ebp, esp */ 671 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8); 672 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 673 esp = esp - 8; /* 0x380012B3: sub esp, 8 */ 674 _flag_k = FK_CMP; 675 PUSH32(esp, ebx); /* 0x380012B6: push ebx */ 676 eax = ecx; /* 0x380012B7: mov eax, ecx */ 677 ecx = MEM32(ebp + 0x8); /* 0x380012B9: mov ecx, dword ptr [ebp + 8] */ 678 PUSH32(esp, esi); /* 0x380012BC: push esi */ 679 PUSH32(esp, edi); /* 0x380012BD: push edi */ 680 edi = ecx + 0x4; /* 0x380012BE: lea edi, [ecx + 4] */ 681 ecx = eax + 0x4; /* 0x380012C1: lea ecx, [eax + 4] */ 682 /* cmp ecx, edi */ /* 0x380012C4: cmp ecx, edi */ 683 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi); 684 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 685 _flag_k = FK_CMP; 686 MEM32(ebp + (-0x4)) = eax; /* 0x380012C6: mov dword ptr [ebp - 4], eax */ 687 if (CMP_EQ(_flag_a, _flag_b)) goto L_380014A5; /* 0x380012C9: je 0x380014a5 */ 688 L_380012CF: 689 esi = MEM32(edi + 0x4); /* 0x380012CF: mov esi, dword ptr [edi + 4] */ 690 /* test esi, esi */ /* 0x380012D2: test esi, esi */ 691 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi); 692 _cf = 0; 693 _flag_k = FK_TEST; 694 if (TEST_NZ(_flag_a, _flag_b)) goto L_380012DA; /* 0x380012D4: jne 0x380012da */ 695 L_380012D6: 696 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 697 ebx = 0; /* 0x380012D6: xor ebx, ebx */ 698 _cf = 0; 699 _flag_k = FK_TEST; 700 goto L_380012E2; /* 0x380012D8: jmp 0x380012e2 */ 701 L_380012DA: 702 ebx = MEM32(edi + 0x8); /* 0x380012DA: mov ebx, dword ptr [edi + 8] */ 703 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(esi); 704 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 705 ebx = ebx - esi; /* 0x380012DD: sub ebx, esi */ 706 _flag_k = FK_CMP; 707 if (3u) _cf = (((ebx) >> 2) & 1u); /* 0x380012DF: sar ebx, 3 */ 708 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ebx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 709 ebx = (uint32_t)((int32_t)ebx >> 3u); 710 L_380012E2: 711 eax = MEM32(ecx + 0x4); /* 0x380012E2: mov eax, dword ptr [ecx + 4] */ 712 /* test eax, eax */ /* 0x380012E5: test eax, eax */ 713 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 714 _cf = 0; 715 _flag_k = FK_TEST; 716 if (TEST_NZ(_flag_a, _flag_b)) goto L_380012ED; /* 0x380012E7: jne 0x380012ed */ 717 L_380012E9: 718 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 719 edx = 0; /* 0x380012E9: xor edx, edx */ 720 _cf = 0; 721 _flag_k = FK_TEST; 722 goto L_380012F5; /* 0x380012EB: jmp 0x380012f5 */ 723 L_380012ED: 724 edx = MEM32(ecx + 0x8); /* 0x380012ED: mov edx, dword ptr [ecx + 8] */ 725 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax); 726 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 727 edx = edx - eax; /* 0x380012F0: sub edx, eax */ 728 _flag_k = FK_CMP; 729 if (3u) _cf = (((edx) >> 2) & 1u); /* 0x380012F2: sar edx, 3 */ 730 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 731 edx = (uint32_t)((int32_t)edx >> 3u); 732 L_380012F5: 733 /* cmp ebx, edx */ /* 0x380012F5: cmp ebx, edx */ 734 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(edx); 735 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 736 _flag_k = FK_CMP; 737 if (CMP_A(_flag_a, _flag_b)) goto L_38001372; /* 0x380012F7: ja 0x38001372 */ 738 L_380012F9: 739 ebx = MEM32(edi + 0x8); /* 0x380012F9: mov ebx, dword ptr [edi + 8] */ 740 /* cmp esi, ebx */ /* 0x380012FC: cmp esi, ebx */ 741 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx); 742 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 743 _flag_k = FK_CMP; 744 edi = eax; /* 0x380012FE: mov edi, eax */ 745 if (CMP_EQ(_flag_a, _flag_b)) goto L_38001314; /* 0x38001300: je 0x38001314 */ 746 L_38001302: 747 PUSH32(esp, esi); /* 0x38001302: push esi */ 748 ecx = edi; /* 0x38001303: mov ecx, edi */ 749 RECOMP_ICALL(0x3801E590u); /* 0x38001305: call 0x3801e590 */ /* not lifted */ 750 RECOMP_FLAGS_IN(); 751 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 752 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 753 esi = esi + 8; /* 0x3800130A: add esi, 8 */ 754 _flag_k = FK_ADD; 755 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(8); 756 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 757 edi = edi + 8; /* 0x3800130D: add edi, 8 */ 758 _flag_k = FK_ADD; 759 /* cmp esi, ebx */ /* 0x38001310: cmp esi, ebx */ 760 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx); 761 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 762 _flag_k = FK_CMP; 763 RECOMP_BACKEDGE(); 764 if (CMP_NE(_flag_a, _flag_b)) goto L_38001302; /* 0x38001312: jne 0x38001302 */ 765 L_38001314: 766 edx = MEM32(ebp + (-0x4)); /* 0x38001314: mov edx, dword ptr [ebp - 4] */ 767 ebx = MEM32(edx + 0xC); /* 0x38001317: mov ebx, dword ptr [edx + 0xc] */ 768 /* cmp edi, ebx */ /* 0x3800131A: cmp edi, ebx */ 769 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx); 770 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 771 _flag_k = FK_CMP; 772 eax = edx + 0x4; /* 0x3800131C: lea eax, [edx + 4] */ 773 esi = edi; /* 0x3800131F: mov esi, edi */ 774 if (CMP_EQ(_flag_a, _flag_b)) goto L_38001333; /* 0x38001321: je 0x38001333 */ 775 L_38001323: 776 eax = MEM32(esi); /* 0x38001323: mov eax, dword ptr [esi] */ 777 PUSH32(esp, 0); /* 0x38001325: push 0 */ 778 ecx = esi; /* 0x38001327: mov ecx, esi */ 779 RECOMP_ICALL(MEM32(eax + 0xC)); /* 0x38001329: call dword ptr [eax + 0xc] */ 780 RECOMP_FLAGS_IN(); 781 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 782 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 783 esi = esi + 8; /* 0x3800132C: add esi, 8 */ 784 _flag_k = FK_ADD; 785 /* cmp esi, ebx */ /* 0x3800132F: cmp esi, ebx */ 786 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx); 787 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 788 _flag_k = FK_CMP; 789 RECOMP_BACKEDGE(); 790 if (CMP_NE(_flag_a, _flag_b)) goto L_38001323; /* 0x38001331: jne 0x38001323 */ 791 L_38001333: 792 ecx = MEM32(ebp + 0x8); /* 0x38001333: mov ecx, dword ptr [ebp + 8] */ 793 eax = ecx + 0x4; /* 0x38001336: lea eax, [ecx + 4] */ 794 ecx = MEM32(eax + 0x4); /* 0x38001339: mov ecx, dword ptr [eax + 4] */ 795 /* test ecx, ecx */ /* 0x3800133C: test ecx, ecx */ 796 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx); 797 _cf = 0; 798 _flag_k = FK_TEST; 799 if (TEST_NZ(_flag_a, _flag_b)) goto L_38001356; /* 0x3800133E: jne 0x38001356 */ 800 L_38001340: 801 edx = MEM32(ebp + (-0x4)); /* 0x38001340: mov edx, dword ptr [ebp - 4] */ 802 ecx = edx + 0x4; /* 0x38001343: lea ecx, [edx + 4] */ 803 edx = MEM32(ecx + 0x4); /* 0x38001346: mov edx, dword ptr [ecx + 4] */ 804 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 805 eax = 0; /* 0x38001349: xor eax, eax */ 806 _cf = 0; 807 _flag_k = FK_TEST; 808 eax = edx + eax * 8; /* 0x3800134B: lea eax, [edx + eax*8] */ 809 MEM32(ecx + 0x8) = eax; /* 0x3800134E: mov dword ptr [ecx + 8], eax */ 810 goto L_380014A2; /* 0x38001351: jmp 0x380014a2 */ 811 L_38001356: 812 eax = MEM32(eax + 0x8); /* 0x38001356: mov eax, dword ptr [eax + 8] */ 813 edx = MEM32(ebp + (-0x4)); /* 0x38001359: mov edx, dword ptr [ebp - 4] */ 814 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx); 815 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 816 eax = eax - ecx; /* 0x3800135C: sub eax, ecx */ 817 _flag_k = FK_CMP; 818 ecx = edx + 0x4; /* 0x3800135E: lea ecx, [edx + 4] */ 819 edx = MEM32(ecx + 0x4); /* 0x38001361: mov edx, dword ptr [ecx + 4] */ 820 if (3u) _cf = (((eax) >> 2) & 1u); /* 0x38001364: sar eax, 3 */ 821 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 822 eax = (uint32_t)((int32_t)eax >> 3u); 823 eax = edx + eax * 8; /* 0x38001367: lea eax, [edx + eax*8] */ 824 MEM32(ecx + 0x8) = eax; /* 0x3800136A: mov dword ptr [ecx + 8], eax */ 825 goto L_380014A2; /* 0x3800136D: jmp 0x380014a2 */ 826 L_38001372: 827 /* test esi, esi */ /* 0x38001372: test esi, esi */ 828 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi); 829 _cf = 0; 830 _flag_k = FK_TEST; 831 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800137A; /* 0x38001374: jne 0x3800137a */ 832 L_38001376: 833 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 834 edi = 0; /* 0x38001376: xor edi, edi */ 835 _cf = 0; 836 _flag_k = FK_TEST; 837 goto L_38001382; /* 0x38001378: jmp 0x38001382 */ 838 L_3800137A: 839 edi = MEM32(edi + 0x8); /* 0x3800137A: mov edi, dword ptr [edi + 8] */ 840 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(esi); 841 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 842 edi = edi - esi; /* 0x3800137D: sub edi, esi */ 843 _flag_k = FK_CMP; 844 if (3u) _cf = (((edi) >> 2) & 1u); /* 0x3800137F: sar edi, 3 */ 845 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edi >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 846 edi = (uint32_t)((int32_t)edi >> 3u); 847 L_38001382: 848 /* test eax, eax */ /* 0x38001382: test eax, eax */ 849 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 850 _cf = 0; 851 _flag_k = FK_TEST; 852 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800138A; /* 0x38001384: jne 0x3800138a */ 853 L_38001386: 854 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 855 edx = 0; /* 0x38001386: xor edx, edx */ 856 _cf = 0; 857 _flag_k = FK_TEST; 858 goto L_38001392; /* 0x38001388: jmp 0x38001392 */ 859 L_3800138A: 860 edx = MEM32(ecx + 0xC); /* 0x3800138A: mov edx, dword ptr [ecx + 0xc] */ 861 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax); 862 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 863 edx = edx - eax; /* 0x3800138D: sub edx, eax */ 864 _flag_k = FK_CMP; 865 if (3u) _cf = (((edx) >> 2) & 1u); /* 0x3800138F: sar edx, 3 */ 866 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 867 edx = (uint32_t)((int32_t)edx >> 3u); 868 L_38001392: 869 /* cmp edi, edx */ /* 0x38001392: cmp edi, edx */ 870 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edx); 871 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 872 _flag_k = FK_CMP; 873 if (CMP_A(_flag_a, _flag_b)) goto L_38001433; /* 0x38001394: ja 0x38001433 */ 874 L_3800139A: 875 /* test eax, eax */ /* 0x3800139A: test eax, eax */ 876 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 877 _cf = 0; 878 _flag_k = FK_TEST; 879 if (TEST_NZ(_flag_a, _flag_b)) goto L_380013A2; /* 0x3800139C: jne 0x380013a2 */ 880 L_3800139E: 881 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 882 ecx = 0; /* 0x3800139E: xor ecx, ecx */ 883 _cf = 0; 884 _flag_k = FK_TEST; 885 goto L_380013AA; /* 0x380013A0: jmp 0x380013aa */ 886 L_380013A2: 887 ecx = MEM32(ecx + 0x8); /* 0x380013A2: mov ecx, dword ptr [ecx + 8] */ 888 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax); 889 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 890 ecx = ecx - eax; /* 0x380013A5: sub ecx, eax */ 891 _flag_k = FK_CMP; 892 if (3u) _cf = (((ecx) >> 2) & 1u); /* 0x380013A7: sar ecx, 3 */ 893 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 894 ecx = (uint32_t)((int32_t)ecx >> 3u); 895 L_380013AA: 896 edi = esi + ecx * 8; /* 0x380013AA: lea edi, [esi + ecx*8] */ 897 /* cmp esi, edi */ /* 0x380013AD: cmp esi, edi */ 898 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edi); 899 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 900 _flag_k = FK_CMP; 901 ebx = eax; /* 0x380013AF: mov ebx, eax */ 902 if (CMP_EQ(_flag_a, _flag_b)) goto L_380013C5; /* 0x380013B1: je 0x380013c5 */ 903 L_380013B3: 904 PUSH32(esp, esi); /* 0x380013B3: push esi */ 905 ecx = ebx; /* 0x380013B4: mov ecx, ebx */ 906 RECOMP_ICALL(0x3801E590u); /* 0x380013B6: call 0x3801e590 */ /* not lifted */ 907 RECOMP_FLAGS_IN(); 908 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 909 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 910 esi = esi + 8; /* 0x380013BB: add esi, 8 */ 911 _flag_k = FK_ADD; 912 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(8); 913 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 914 ebx = ebx + 8; /* 0x380013BE: add ebx, 8 */ 915 _flag_k = FK_ADD; 916 /* cmp esi, edi */ /* 0x380013C1: cmp esi, edi */ 917 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edi); 918 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 919 _flag_k = FK_CMP; 920 RECOMP_BACKEDGE(); 921 if (CMP_NE(_flag_a, _flag_b)) goto L_380013B3; /* 0x380013C3: jne 0x380013b3 */ 922 L_380013C5: 923 ecx = MEM32(ebp + 0x8); /* 0x380013C5: mov ecx, dword ptr [ebp + 8] */ 924 edx = MEM32(ebp + (-0x4)); /* 0x380013C8: mov edx, dword ptr [ebp - 4] */ 925 ebx = MEM32(edx + 0xC); /* 0x380013CB: mov ebx, dword ptr [edx + 0xc] */ 926 eax = ecx + 0x4; /* 0x380013CE: lea eax, [ecx + 4] */ 927 eax = MEM32(eax + 0x8); /* 0x380013D1: mov eax, dword ptr [eax + 8] */ 928 /* cmp edi, eax */ /* 0x380013D4: cmp edi, eax */ 929 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax); 930 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 931 _flag_k = FK_CMP; 932 ecx = edx + 0x4; /* 0x380013D6: lea ecx, [edx + 4] */ 933 MEM32(ebp + (-0x8)) = eax; /* 0x380013D9: mov dword ptr [ebp - 8], eax */ 934 esi = edi; /* 0x380013DC: mov esi, edi */ 935 if (CMP_EQ(_flag_a, _flag_b)) goto L_380013F7; /* 0x380013DE: je 0x380013f7 */ 936 L_380013E0: 937 PUSH32(esp, esi); /* 0x380013E0: push esi */ 938 PUSH32(esp, ebx); /* 0x380013E1: push ebx */ 939 RECOMP_ICALL(0x38004460u); /* 0x380013E2: call 0x38004460 */ /* not lifted */ 940 RECOMP_FLAGS_IN(); 941 eax = MEM32(ebp + (-0x8)); /* 0x380013E7: mov eax, dword ptr [ebp - 8] */ 942 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 943 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 944 esi = esi + 8; /* 0x380013EA: add esi, 8 */ 945 _flag_k = FK_ADD; 946 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8); 947 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 948 esp = esp + 8; /* 0x380013ED: add esp, 8 */ 949 _flag_k = FK_ADD; 950 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(8); 951 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 952 ebx = ebx + 8; /* 0x380013F0: add ebx, 8 */ 953 _flag_k = FK_ADD; 954 /* cmp esi, eax */ /* 0x380013F3: cmp esi, eax */ 955 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax); 956 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 957 _flag_k = FK_CMP; 958 RECOMP_BACKEDGE(); 959 if (CMP_NE(_flag_a, _flag_b)) goto L_380013E0; /* 0x380013F5: jne 0x380013e0 */ 960 L_380013F7: 961 eax = MEM32(ebp + 0x8); /* 0x380013F7: mov eax, dword ptr [ebp + 8] */ 962 ecx = MEM32(eax + 0x8); /* 0x380013FA: mov ecx, dword ptr [eax + 8] */ 963 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4); 964 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 965 eax = eax + 4; /* 0x380013FD: add eax, 4 */ 966 _flag_k = FK_ADD; 967 /* test ecx, ecx */ /* 0x38001400: test ecx, ecx */ 968 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx); 969 _cf = 0; 970 _flag_k = FK_TEST; 971 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800141A; /* 0x38001402: jne 0x3800141a */ 972 L_38001404: 973 ecx = MEM32(ebp + (-0x4)); /* 0x38001404: mov ecx, dword ptr [ebp - 4] */ 974 edx = MEM32(ecx + 0x8); /* 0x38001407: mov edx, dword ptr [ecx + 8] */ 975 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 976 eax = 0; /* 0x3800140A: xor eax, eax */ 977 _cf = 0; 978 _flag_k = FK_TEST; 979 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4); 980 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 981 ecx = ecx + 4; /* 0x3800140C: add ecx, 4 */ 982 _flag_k = FK_ADD; 983 eax = edx + eax * 8; /* 0x3800140F: lea eax, [edx + eax*8] */ 984 MEM32(ecx + 0x8) = eax; /* 0x38001412: mov dword ptr [ecx + 8], eax */ 985 goto L_380014A2; /* 0x38001415: jmp 0x380014a2 */ 986 L_3800141A: 987 eax = MEM32(eax + 0x8); /* 0x3800141A: mov eax, dword ptr [eax + 8] */ 988 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx); 989 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 990 eax = eax - ecx; /* 0x3800141D: sub eax, ecx */ 991 _flag_k = FK_CMP; 992 ecx = MEM32(ebp + (-0x4)); /* 0x3800141F: mov ecx, dword ptr [ebp - 4] */ 993 edx = MEM32(ecx + 0x8); /* 0x38001422: mov edx, dword ptr [ecx + 8] */ 994 if (3u) _cf = (((eax) >> 2) & 1u); /* 0x38001425: sar eax, 3 */ 995 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 996 eax = (uint32_t)((int32_t)eax >> 3u); 997 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4); 998 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 999 ecx = ecx + 4; /* 0x38001428: add ecx, 4 */ 1000 _flag_k = FK_ADD; 1001 eax = edx + eax * 8; /* 0x3800142B: lea eax, [edx + eax*8] */ 1002 MEM32(ecx + 0x8) = eax; /* 0x3800142E: mov dword ptr [ecx + 8], eax */ 1003 goto L_380014A2; /* 0x38001431: jmp 0x380014a2 */ 1004 L_38001433: 1005 edi = MEM32(ecx + 0x8); /* 0x38001433: mov edi, dword ptr [ecx + 8] */ 1006 esi = eax; /* 0x38001436: mov esi, eax */ 1007 /* cmp esi, edi */ /* 0x38001438: cmp esi, edi */ 1008 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edi); 1009 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1010 _flag_k = FK_CMP; 1011 if (CMP_EQ(_flag_a, _flag_b)) goto L_3800144C; /* 0x3800143A: je 0x3800144c */ 1012 L_3800143C: 1013 edx = MEM32(esi); /* 0x3800143C: mov edx, dword ptr [esi] */ 1014 PUSH32(esp, 0); /* 0x3800143E: push 0 */ 1015 ecx = esi; /* 0x38001440: mov ecx, esi */ 1016 RECOMP_ICALL(MEM32(edx + 0xC)); /* 0x38001442: call dword ptr [edx + 0xc] */ 1017 RECOMP_FLAGS_IN(); 1018 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 1019 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1020 esi = esi + 8; /* 0x38001445: add esi, 8 */ 1021 _flag_k = FK_ADD; 1022 /* cmp esi, edi */ /* 0x38001448: cmp esi, edi */ 1023 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edi); 1024 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1025 _flag_k = FK_CMP; 1026 RECOMP_BACKEDGE(); 1027 if (CMP_NE(_flag_a, _flag_b)) goto L_3800143C; /* 0x3800144A: jne 0x3800143c */ 1028 L_3800144C: 1029 eax = MEM32(ebp + (-0x4)); /* 0x3800144C: mov eax, dword ptr [ebp - 4] */ 1030 ecx = MEM32(eax + 0x8); /* 0x3800144F: mov ecx, dword ptr [eax + 8] */ 1031 esi = eax + 0x4; /* 0x38001452: lea esi, [eax + 4] */ 1032 PUSH32(esp, ecx); /* 0x38001455: push ecx */ 1033 RECOMP_ICALL(0x3804B4F6u); /* 0x38001456: call 0x3804b4f6 */ /* not lifted */ 1034 RECOMP_FLAGS_IN(); 1035 edx = MEM32(ebp + 0x8); /* 0x3800145B: mov edx, dword ptr [ebp + 8] */ 1036 ecx = MEM32(edx + 0x8); /* 0x3800145E: mov ecx, dword ptr [edx + 8] */ 1037 edi = edx + 0x4; /* 0x38001461: lea edi, [edx + 4] */ 1038 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 1039 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1040 esp = esp + 4; /* 0x38001464: add esp, 4 */ 1041 _flag_k = FK_ADD; 1042 /* test ecx, ecx */ /* 0x38001467: test ecx, ecx */ 1043 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx); 1044 _cf = 0; 1045 _flag_k = FK_TEST; 1046 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800146F; /* 0x38001469: jne 0x3800146f */ 1047 L_3800146B: 1048 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1049 eax = 0; /* 0x3800146B: xor eax, eax */ 1050 _cf = 0; 1051 _flag_k = FK_TEST; 1052 goto L_38001477; /* 0x3800146D: jmp 0x38001477 */ 1053 L_3800146F: 1054 eax = MEM32(edi + 0x8); /* 0x3800146F: mov eax, dword ptr [edi + 8] */ 1055 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx); 1056 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1057 eax = eax - ecx; /* 0x38001472: sub eax, ecx */ 1058 _flag_k = FK_CMP; 1059 if (3u) _cf = (((eax) >> 2) & 1u); /* 0x38001474: sar eax, 3 */ 1060 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1061 eax = (uint32_t)((int32_t)eax >> 3u); 1062 L_38001477: 1063 /* test eax, eax */ /* 0x38001477: test eax, eax */ 1064 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 1065 _cf = 0; 1066 _flag_k = FK_TEST; 1067 if (TEST_NS(_flag_a, _flag_b)) goto L_3800147D; /* 0x38001479: jge 0x3800147d */ 1068 L_3800147B: 1069 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1070 eax = 0; /* 0x3800147B: xor eax, eax */ 1071 _cf = 0; 1072 _flag_k = FK_TEST; 1073 L_3800147D: 1074 if (3u) _cf = (((eax) >> 29) & 1u); /* 0x3800147D: shl eax, 3 */ 1075 if (3u) { _flag_a = recomp_flags_pack((eax << 3u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1076 eax = eax << 3u; /* 0x3800147D: shl eax, 3 */ 1077 PUSH32(esp, eax); /* 0x38001480: push eax */ 1078 RECOMP_ICALL(0x3804B676u); /* 0x38001481: call 0x3804b676 */ /* not lifted */ 1079 RECOMP_FLAGS_IN(); 1080 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 1081 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1082 esp = esp + 4; /* 0x38001486: add esp, 4 */ 1083 _flag_k = FK_ADD; 1084 MEM32(esi + 0x4) = eax; /* 0x38001489: mov dword ptr [esi + 4], eax */ 1085 ecx = MEM32(edi + 0x8); /* 0x3800148C: mov ecx, dword ptr [edi + 8] */ 1086 edx = MEM32(edi + 0x4); /* 0x3800148F: mov edx, dword ptr [edi + 4] */ 1087 PUSH32(esp, eax); /* 0x38001492: push eax */ 1088 PUSH32(esp, ecx); /* 0x38001493: push ecx */ 1089 PUSH32(esp, edx); /* 0x38001494: push edx */ 1090 ecx = esi; /* 0x38001495: mov ecx, esi */ 1091 RECOMP_ICALL(0x38004420u); /* 0x38001497: call 0x38004420 */ /* not lifted */ 1092 RECOMP_FLAGS_IN(); 1093 MEM32(esi + 0x8) = eax; /* 0x3800149C: mov dword ptr [esi + 8], eax */ 1094 MEM32(esi + 0xC) = eax; /* 0x3800149F: mov dword ptr [esi + 0xc], eax */ 1095 L_380014A2: 1096 eax = MEM32(ebp + (-0x4)); /* 0x380014A2: mov eax, dword ptr [ebp - 4] */ 1097 L_380014A5: 1098 ecx = MEM32(ebp + 0x8); /* 0x380014A5: mov ecx, dword ptr [ebp + 8] */ 1099 SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x380014A8: mov dl, byte ptr [ecx + 0x14] */ 1100 edi = POP32_VAL(esp); /* 0x380014AB: pop edi */ 1101 MEM8(eax + 0x14) = (uint8_t)(LO8(edx)); /* 0x380014AC: mov byte ptr [eax + 0x14], dl */ 1102 ecx = MEM32(ecx + 0x18); /* 0x380014AF: mov ecx, dword ptr [ecx + 0x18] */ 1103 esi = POP32_VAL(esp); /* 0x380014B2: pop esi */ 1104 MEM32(eax + 0x18) = ecx; /* 0x380014B3: mov dword ptr [eax + 0x18], ecx */ 1105 ebx = POP32_VAL(esp); /* 0x380014B6: pop ebx */ 1106 esp = ebp; /* 0x380014B7: mov esp, ebp */ 1107 ebp = POP32_VAL(esp); /* 0x380014B9: pop ebp */ 1108 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380014BA: ret 4 */ 1109 RECOMP_REGS_OUT(); 1110 } 1111 1112 void sub_380014A2(void) { 1113 int _fpu_cmp = 0; 1114 uint32_t _cf = 0; 1115 int _df = 1; 1116 uint32_t _flag_k = FK_NONE; 1117 uint32_t _flag_a = 0, _flag_b = 0; 1118 uint32_t _itail_tgt = 0; 1119 RECOMP_REGS_LOCALS 1120 RECOMP_ENTER(0x380014A2u); 1121 1122 L_380014A2: 1123 eax = MEM32(ebp + (-0x4)); /* 0x380014A2: mov eax, dword ptr [ebp - 4] */ 1124 ecx = MEM32(ebp + 0x8); /* 0x380014A5: mov ecx, dword ptr [ebp + 8] */ 1125 SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x380014A8: mov dl, byte ptr [ecx + 0x14] */ 1126 edi = POP32_VAL(esp); /* 0x380014AB: pop edi */ 1127 MEM8(eax + 0x14) = (uint8_t)(LO8(edx)); /* 0x380014AC: mov byte ptr [eax + 0x14], dl */ 1128 ecx = MEM32(ecx + 0x18); /* 0x380014AF: mov ecx, dword ptr [ecx + 0x18] */ 1129 esi = POP32_VAL(esp); /* 0x380014B2: pop esi */ 1130 MEM32(eax + 0x18) = ecx; /* 0x380014B3: mov dword ptr [eax + 0x18], ecx */ 1131 ebx = POP32_VAL(esp); /* 0x380014B6: pop ebx */ 1132 esp = ebp; /* 0x380014B7: mov esp, ebp */ 1133 ebp = POP32_VAL(esp); /* 0x380014B9: pop ebp */ 1134 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380014BA: ret 4 */ 1135 RECOMP_REGS_OUT(); 1136 } 1137 1138 void sub_380014C0(void) { 1139 int _fpu_cmp = 0; 1140 uint32_t _cf = 0; 1141 int _df = 1; 1142 uint32_t _flag_k = FK_NONE; 1143 uint32_t _flag_a = 0, _flag_b = 0; 1144 uint32_t _itail_tgt = 0; 1145 RECOMP_REGS_LOCALS 1146 RECOMP_ENTER(0x380014C0u); 1147 1148 L_380014C0: 1149 PUSH32(esp, ebp); /* 0x380014C0: push ebp */ 1150 ebp = esp; /* 0x380014C1: mov ebp, esp */ 1151 PUSH32(esp, ebx); /* 0x380014C3: push ebx */ 1152 SET_LO8(ebx, MEM8(ebp + 0x8)); /* 0x380014C4: mov bl, byte ptr [ebp + 8] */ 1153 /* test LO8(ebx), 2 */ /* 0x380014C7: test bl, 2 */ 1154 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(2) << 24; 1155 _cf = 0; 1156 _flag_k = FK_NARROW(FK_TEST, 24); 1157 PUSH32(esp, esi); /* 0x380014CA: push esi */ 1158 esi = ecx; /* 0x380014CB: mov esi, ecx */ 1159 if (TEST_Z(_flag_a, _flag_b)) goto L_380014FB; /* 0x380014CD: je 0x380014fb */ 1160 L_380014CF: 1161 eax = MEM32(esi + (-0x4)); /* 0x380014CF: mov eax, dword ptr [esi - 4] */ 1162 PUSH32(esp, edi); /* 0x380014D2: push edi */ 1163 PUSH32(esp, 0x3801E150u); /* 0x380014D3: push 0x3801e150 */ 1164 edi = esi + (-0x4); /* 0x380014D8: lea edi, [esi - 4] */ 1165 PUSH32(esp, eax); /* 0x380014DB: push eax */ 1166 PUSH32(esp, 0x1Cu); /* 0x380014DC: push 0x1c */ 1167 PUSH32(esp, esi); /* 0x380014DE: push esi */ 1168 RECOMP_ICALL(0x3804B582u); /* 0x380014DF: call 0x3804b582 */ /* not lifted */ 1169 RECOMP_FLAGS_IN(); 1170 /* test LO8(ebx), 1 */ /* 0x380014E4: test bl, 1 */ 1171 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(1) << 24; 1172 _cf = 0; 1173 _flag_k = FK_NARROW(FK_TEST, 24); 1174 if (TEST_Z(_flag_a, _flag_b)) goto L_380014F2; /* 0x380014E7: je 0x380014f2 */ 1175 L_380014E9: 1176 PUSH32(esp, edi); /* 0x380014E9: push edi */ 1177 RECOMP_ICALL(0x3804B4F6u); /* 0x380014EA: call 0x3804b4f6 */ /* not lifted */ 1178 RECOMP_FLAGS_IN(); 1179 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 1180 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1181 esp = esp + 4; /* 0x380014EF: add esp, 4 */ 1182 _flag_k = FK_ADD; 1183 L_380014F2: 1184 eax = edi; /* 0x380014F2: mov eax, edi */ 1185 edi = POP32_VAL(esp); /* 0x380014F4: pop edi */ 1186 esi = POP32_VAL(esp); /* 0x380014F5: pop esi */ 1187 ebx = POP32_VAL(esp); /* 0x380014F6: pop ebx */ 1188 ebp = POP32_VAL(esp); /* 0x380014F7: pop ebp */ 1189 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380014F8: ret 4 */ 1190 L_380014FB: 1191 ecx = esi; /* 0x380014FB: mov ecx, esi */ 1192 RECOMP_ICALL(0x3801E150u); /* 0x380014FD: call 0x3801e150 */ /* not lifted */ 1193 RECOMP_FLAGS_IN(); 1194 /* test LO8(ebx), 1 */ /* 0x38001502: test bl, 1 */ 1195 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(1) << 24; 1196 _cf = 0; 1197 _flag_k = FK_NARROW(FK_TEST, 24); 1198 if (TEST_Z(_flag_a, _flag_b)) goto L_38001510; /* 0x38001505: je 0x38001510 */ 1199 L_38001507: 1200 PUSH32(esp, esi); /* 0x38001507: push esi */ 1201 RECOMP_ICALL(0x3804B4F6u); /* 0x38001508: call 0x3804b4f6 */ /* not lifted */ 1202 RECOMP_FLAGS_IN(); 1203 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 1204 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1205 esp = esp + 4; /* 0x3800150D: add esp, 4 */ 1206 _flag_k = FK_ADD; 1207 L_38001510: 1208 eax = esi; /* 0x38001510: mov eax, esi */ 1209 esi = POP32_VAL(esp); /* 0x38001512: pop esi */ 1210 ebx = POP32_VAL(esp); /* 0x38001513: pop ebx */ 1211 ebp = POP32_VAL(esp); /* 0x38001514: pop ebp */ 1212 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001515: ret 4 */ 1213 RECOMP_REGS_OUT(); 1214 } 1215 1216 void sub_38001520(void) { 1217 int _fpu_cmp = 0; 1218 uint32_t _cf = 0; 1219 int _df = 1; 1220 uint32_t _flag_k = FK_NONE; 1221 uint32_t _flag_a = 0, _flag_b = 0; 1222 uint32_t _itail_tgt = 0; 1223 RECOMP_REGS_LOCALS 1224 RECOMP_ENTER(0x38001520u); 1225 1226 L_38001520: 1227 PUSH32(esp, ebp); /* 0x38001520: push ebp */ 1228 ebp = esp; /* 0x38001521: mov ebp, esp */ 1229 eax = ecx; /* 0x38001523: mov eax, ecx */ 1230 ecx = MEM32(ebp + 0x8); /* 0x38001525: mov ecx, dword ptr [ebp + 8] */ 1231 edx = MEM32(ecx + 0x4); /* 0x38001528: mov edx, dword ptr [ecx + 4] */ 1232 MEM32(eax + 0x4) = edx; /* 0x3800152B: mov dword ptr [eax + 4], edx */ 1233 MEM32(eax) = 0x3804E800u; /* 0x3800152E: mov dword ptr [eax], 0x3804e800 */ 1234 ebp = POP32_VAL(esp); /* 0x38001534: pop ebp */ 1235 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001535: ret 4 */ 1236 RECOMP_REGS_OUT(); 1237 } 1238 1239 void sub_38001540(void) { 1240 int _fpu_cmp = 0; 1241 uint32_t _cf = 0; 1242 int _df = 1; 1243 uint32_t _flag_k = FK_NONE; 1244 uint32_t _flag_a = 0, _flag_b = 0; 1245 uint32_t _itail_tgt = 0; 1246 RECOMP_REGS_LOCALS 1247 RECOMP_ENTER(0x38001540u); 1248 1249 L_38001540: 1250 eax = MEM32(ecx + 0x1C); /* 0x38001540: mov eax, dword ptr [ecx + 0x1c] */ 1251 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001543: ret */ 1252 RECOMP_REGS_OUT(); 1253 } 1254 1255 void sub_38001550(void) { 1256 int _fpu_cmp = 0; 1257 uint32_t _cf = 0; 1258 int _df = 1; 1259 uint32_t _flag_k = FK_NONE; 1260 uint32_t _flag_a = 0, _flag_b = 0; 1261 uint32_t _itail_tgt = 0; 1262 RECOMP_REGS_LOCALS 1263 RECOMP_ENTER(0x38001550u); 1264 1265 L_38001550: 1266 edx = MEM32(ecx + 0x1C); /* 0x38001550: mov edx, dword ptr [ecx + 0x1c] */ 1267 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1268 eax = 0; /* 0x38001553: xor eax, eax */ 1269 _cf = 0; 1270 _flag_k = FK_TEST; 1271 /* test edx, edx */ /* 0x38001555: test edx, edx */ 1272 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx); 1273 _cf = 0; 1274 _flag_k = FK_TEST; 1275 SET_LO8(eax, (TEST_NZ(_flag_a, _flag_b)) ? 1 : 0); /* 0x38001557: setne al */ 1276 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800155A: ret */ 1277 RECOMP_REGS_OUT(); 1278 } 1279 1280 void sub_38001560(void) { 1281 int _fpu_cmp = 0; 1282 uint32_t _cf = 0; 1283 int _df = 1; 1284 uint32_t _flag_k = FK_NONE; 1285 uint32_t _flag_a = 0, _flag_b = 0; 1286 uint32_t _itail_tgt = 0; 1287 RECOMP_REGS_LOCALS 1288 RECOMP_ENTER(0x38001560u); 1289 1290 L_38001560: 1291 PUSH32(esp, ebp); /* 0x38001560: push ebp */ 1292 ebp = esp; /* 0x38001561: mov ebp, esp */ 1293 PUSH32(esp, 0xFFFFFFFFu); /* 0x38001563: push -1 */ 1294 PUSH32(esp, 0x3804B921u); /* 0x38001565: push 0x3804b921 */ 1295 eax = MEM32(FS_BASE + (0)); /* 0x3800156A: mov eax, dword ptr fs:[0] */ 1296 PUSH32(esp, eax); /* 0x38001570: push eax */ 1297 MEM32(FS_BASE + (0)) = esp; /* 0x38001571: mov dword ptr fs:[0], esp */ 1298 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu); 1299 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1300 esp = esp - 0xCu; /* 0x38001578: sub esp, 0xc */ 1301 _flag_k = FK_CMP; 1302 PUSH32(esp, ebx); /* 0x3800157B: push ebx */ 1303 ebx = ecx; /* 0x3800157C: mov ebx, ecx */ 1304 PUSH32(esp, esi); /* 0x3800157E: push esi */ 1305 esi = MEM32(ebp + 0x8); /* 0x3800157F: mov esi, dword ptr [ebp + 8] */ 1306 MEM32(ebx) = 0x3804E7C4u; /* 0x38001582: mov dword ptr [ebx], 0x3804e7c4 */ 1307 SET_LO8(eax, MEM8(esi + 0x4)); /* 0x38001588: mov al, byte ptr [esi + 4] */ 1308 MEM8(ebx + 0x4) = (uint8_t)(LO8(eax)); /* 0x3800158B: mov byte ptr [ebx + 4], al */ 1309 ecx = MEM32(esi + 0x8); /* 0x3800158E: mov ecx, dword ptr [esi + 8] */ 1310 /* test ecx, ecx */ /* 0x38001591: test ecx, ecx */ 1311 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx); 1312 _cf = 0; 1313 _flag_k = FK_TEST; 1314 PUSH32(esp, edi); /* 0x38001593: push edi */ 1315 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800159A; /* 0x38001594: jne 0x3800159a */ 1316 L_38001596: 1317 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1318 eax = 0; /* 0x38001596: xor eax, eax */ 1319 _cf = 0; 1320 _flag_k = FK_TEST; 1321 goto L_380015A2; /* 0x38001598: jmp 0x380015a2 */ 1322 L_3800159A: 1323 eax = MEM32(esi + 0xC); /* 0x3800159A: mov eax, dword ptr [esi + 0xc] */ 1324 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx); 1325 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1326 eax = eax - ecx; /* 0x3800159D: sub eax, ecx */ 1327 _flag_k = FK_CMP; 1328 if (3u) _cf = (((eax) >> 2) & 1u); /* 0x3800159F: sar eax, 3 */ 1329 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1330 eax = (uint32_t)((int32_t)eax >> 3u); 1331 L_380015A2: 1332 /* test eax, eax */ /* 0x380015A2: test eax, eax */ 1333 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 1334 _cf = 0; 1335 _flag_k = FK_TEST; 1336 if (TEST_NS(_flag_a, _flag_b)) goto L_380015A8; /* 0x380015A4: jge 0x380015a8 */ 1337 L_380015A6: 1338 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1339 eax = 0; /* 0x380015A6: xor eax, eax */ 1340 _cf = 0; 1341 _flag_k = FK_TEST; 1342 L_380015A8: 1343 ecx = eax * 8; /* 0x380015A8: lea ecx, [eax*8] */ 1344 PUSH32(esp, ecx); /* 0x380015AF: push ecx */ 1345 RECOMP_ICALL(0x3804B676u); /* 0x380015B0: call 0x3804b676 */ /* not lifted */ 1346 RECOMP_FLAGS_IN(); 1347 MEM32(ebx + 0x8) = eax; /* 0x380015B5: mov dword ptr [ebx + 8], eax */ 1348 ecx = MEM32(esi + 0xC); /* 0x380015B8: mov ecx, dword ptr [esi + 0xc] */ 1349 edi = MEM32(esi + 0x8); /* 0x380015BB: mov edi, dword ptr [esi + 8] */ 1350 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 1351 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1352 esp = esp + 4; /* 0x380015BE: add esp, 4 */ 1353 _flag_k = FK_ADD; 1354 /* cmp edi, ecx */ /* 0x380015C1: cmp edi, ecx */ 1355 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx); 1356 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1357 _flag_k = FK_CMP; 1358 esi = eax; /* 0x380015C3: mov esi, eax */ 1359 MEM32(ebp + (-0x10)) = ecx; /* 0x380015C5: mov dword ptr [ebp - 0x10], ecx */ 1360 MEM32(ebp + (-0x14)) = esi; /* 0x380015C8: mov dword ptr [ebp - 0x14], esi */ 1361 if (CMP_EQ(_flag_a, _flag_b)) goto L_380015FA; /* 0x380015CB: je 0x380015fa */ 1362 L_380015CD: 1363 MEM32(ebp + (-0x18)) = esi; /* 0x380015CD: mov dword ptr [ebp - 0x18], esi */ 1364 /* test esi, esi */ /* 0x380015D0: test esi, esi */ 1365 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi); 1366 _cf = 0; 1367 _flag_k = FK_TEST; 1368 MEM32(ebp + (-0x4)) = 0; /* 0x380015D2: mov dword ptr [ebp - 4], 0 */ 1369 if (TEST_Z(_flag_a, _flag_b)) goto L_380015E6; /* 0x380015D9: je 0x380015e6 */ 1370 L_380015DB: 1371 PUSH32(esp, edi); /* 0x380015DB: push edi */ 1372 ecx = esi; /* 0x380015DC: mov ecx, esi */ 1373 RECOMP_ICALL(0x3801E560u); /* 0x380015DE: call 0x3801e560 */ /* not lifted */ 1374 RECOMP_FLAGS_IN(); 1375 ecx = MEM32(ebp + (-0x10)); /* 0x380015E3: mov ecx, dword ptr [ebp - 0x10] */ 1376 L_380015E6: 1377 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 1378 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1379 esi = esi + 8; /* 0x380015E6: add esi, 8 */ 1380 _flag_k = FK_ADD; 1381 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(8); 1382 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1383 edi = edi + 8; /* 0x380015E9: add edi, 8 */ 1384 _flag_k = FK_ADD; 1385 /* cmp edi, ecx */ /* 0x380015EC: cmp edi, ecx */ 1386 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx); 1387 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1388 _flag_k = FK_CMP; 1389 MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x380015EE: mov dword ptr [ebp - 4], 0xffffffff */ 1390 MEM32(ebp + (-0x14)) = esi; /* 0x380015F5: mov dword ptr [ebp - 0x14], esi */ 1391 RECOMP_BACKEDGE(); 1392 if (CMP_NE(_flag_a, _flag_b)) goto L_380015CD; /* 0x380015F8: jne 0x380015cd */ 1393 L_380015FA: 1394 eax = MEM32(ebp + 0x8); /* 0x380015FA: mov eax, dword ptr [ebp + 8] */ 1395 MEM32(ebx + 0xC) = esi; /* 0x380015FD: mov dword ptr [ebx + 0xc], esi */ 1396 MEM32(ebx + 0x10) = esi; /* 0x38001600: mov dword ptr [ebx + 0x10], esi */ 1397 SET_LO8(edx, MEM8(eax + 0x14)); /* 0x38001603: mov dl, byte ptr [eax + 0x14] */ 1398 MEM8(ebx + 0x14) = (uint8_t)(LO8(edx)); /* 0x38001606: mov byte ptr [ebx + 0x14], dl */ 1399 ecx = MEM32(eax + 0x18); /* 0x38001609: mov ecx, dword ptr [eax + 0x18] */ 1400 MEM32(ebx + 0x18) = ecx; /* 0x3800160C: mov dword ptr [ebx + 0x18], ecx */ 1401 ecx = MEM32(ebp + (-0xC)); /* 0x3800160F: mov ecx, dword ptr [ebp - 0xc] */ 1402 MEM32(ebx) = 0x3804E7E8u; /* 0x38001612: mov dword ptr [ebx], 0x3804e7e8 */ 1403 edx = MEM32(eax + 0x1C); /* 0x38001618: mov edx, dword ptr [eax + 0x1c] */ 1404 edi = POP32_VAL(esp); /* 0x3800161B: pop edi */ 1405 MEM32(ebx + 0x1C) = edx; /* 0x3800161C: mov dword ptr [ebx + 0x1c], edx */ 1406 MEM32(ebx) = 0x3804E80Cu; /* 0x3800161F: mov dword ptr [ebx], 0x3804e80c */ 1407 esi = POP32_VAL(esp); /* 0x38001625: pop esi */ 1408 eax = ebx; /* 0x38001626: mov eax, ebx */ 1409 ebx = POP32_VAL(esp); /* 0x38001628: pop ebx */ 1410 MEM32(FS_BASE + (0)) = ecx; /* 0x38001629: mov dword ptr fs:[0], ecx */ 1411 esp = ebp; /* 0x38001630: mov esp, ebp */ 1412 ebp = POP32_VAL(esp); /* 0x38001632: pop ebp */ 1413 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001633: ret 4 */ 1414 RECOMP_REGS_OUT(); 1415 } 1416 1417 void sub_38001640(void) { 1418 int _fpu_cmp = 0; 1419 uint32_t _cf = 0; 1420 int _df = 1; 1421 uint32_t _flag_k = FK_NONE; 1422 uint32_t _flag_a = 0, _flag_b = 0; 1423 uint32_t _itail_tgt = 0; 1424 RECOMP_REGS_LOCALS 1425 RECOMP_ENTER(0x38001640u); 1426 1427 L_38001640: 1428 PUSH32(esp, ebp); /* 0x38001640: push ebp */ 1429 ebp = esp; /* 0x38001641: mov ebp, esp */ 1430 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8); 1431 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1432 esp = esp - 8; /* 0x38001643: sub esp, 8 */ 1433 _flag_k = FK_CMP; 1434 eax = MEM32(ebp + 0x8); /* 0x38001646: mov eax, dword ptr [ebp + 8] */ 1435 PUSH32(esp, ebx); /* 0x38001649: push ebx */ 1436 PUSH32(esp, esi); /* 0x3800164A: push esi */ 1437 PUSH32(esp, edi); /* 0x3800164B: push edi */ 1438 edi = eax + 0x4; /* 0x3800164C: lea edi, [eax + 4] */ 1439 ebx = ecx + 0x4; /* 0x3800164F: lea ebx, [ecx + 4] */ 1440 /* cmp ebx, edi */ /* 0x38001652: cmp ebx, edi */ 1441 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(edi); 1442 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1443 _flag_k = FK_CMP; 1444 MEM32(ebp + (-0x8)) = ecx; /* 0x38001654: mov dword ptr [ebp - 8], ecx */ 1445 if (CMP_EQ(_flag_a, _flag_b)) goto L_3800180C; /* 0x38001657: je 0x3800180c */ 1446 L_3800165D: 1447 esi = MEM32(edi + 0x4); /* 0x3800165D: mov esi, dword ptr [edi + 4] */ 1448 /* test esi, esi */ /* 0x38001660: test esi, esi */ 1449 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi); 1450 _cf = 0; 1451 _flag_k = FK_TEST; 1452 if (TEST_NZ(_flag_a, _flag_b)) goto L_38001668; /* 0x38001662: jne 0x38001668 */ 1453 L_38001664: 1454 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1455 edx = 0; /* 0x38001664: xor edx, edx */ 1456 _cf = 0; 1457 _flag_k = FK_TEST; 1458 goto L_38001670; /* 0x38001666: jmp 0x38001670 */ 1459 L_38001668: 1460 edx = MEM32(edi + 0x8); /* 0x38001668: mov edx, dword ptr [edi + 8] */ 1461 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(esi); 1462 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1463 edx = edx - esi; /* 0x3800166B: sub edx, esi */ 1464 _flag_k = FK_CMP; 1465 if (3u) _cf = (((edx) >> 2) & 1u); /* 0x3800166D: sar edx, 3 */ 1466 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1467 edx = (uint32_t)((int32_t)edx >> 3u); 1468 L_38001670: 1469 eax = MEM32(ebx + 0x4); /* 0x38001670: mov eax, dword ptr [ebx + 4] */ 1470 /* test eax, eax */ /* 0x38001673: test eax, eax */ 1471 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 1472 _cf = 0; 1473 _flag_k = FK_TEST; 1474 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800167B; /* 0x38001675: jne 0x3800167b */ 1475 L_38001677: 1476 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1477 ecx = 0; /* 0x38001677: xor ecx, ecx */ 1478 _cf = 0; 1479 _flag_k = FK_TEST; 1480 goto L_38001683; /* 0x38001679: jmp 0x38001683 */ 1481 L_3800167B: 1482 ecx = MEM32(ebx + 0x8); /* 0x3800167B: mov ecx, dword ptr [ebx + 8] */ 1483 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax); 1484 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1485 ecx = ecx - eax; /* 0x3800167E: sub ecx, eax */ 1486 _flag_k = FK_CMP; 1487 if (3u) _cf = (((ecx) >> 2) & 1u); /* 0x38001680: sar ecx, 3 */ 1488 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1489 ecx = (uint32_t)((int32_t)ecx >> 3u); 1490 L_38001683: 1491 /* cmp edx, ecx */ /* 0x38001683: cmp edx, ecx */ 1492 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx); 1493 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1494 _flag_k = FK_CMP; 1495 if (CMP_A(_flag_a, _flag_b)) goto L_380016FA; /* 0x38001685: ja 0x380016fa */ 1496 L_38001687: 1497 ecx = MEM32(edi + 0x8); /* 0x38001687: mov ecx, dword ptr [edi + 8] */ 1498 /* cmp esi, ecx */ /* 0x3800168A: cmp esi, ecx */ 1499 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ecx); 1500 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1501 _flag_k = FK_CMP; 1502 MEM32(ebp + (-0x4)) = ecx; /* 0x3800168C: mov dword ptr [ebp - 4], ecx */ 1503 edi = eax; /* 0x3800168F: mov edi, eax */ 1504 if (CMP_EQ(_flag_a, _flag_b)) goto L_380016A8; /* 0x38001691: je 0x380016a8 */ 1505 L_38001693: 1506 PUSH32(esp, esi); /* 0x38001693: push esi */ 1507 ecx = edi; /* 0x38001694: mov ecx, edi */ 1508 RECOMP_ICALL(0x3801E590u); /* 0x38001696: call 0x3801e590 */ /* not lifted */ 1509 RECOMP_FLAGS_IN(); 1510 eax = MEM32(ebp + (-0x4)); /* 0x3800169B: mov eax, dword ptr [ebp - 4] */ 1511 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 1512 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1513 esi = esi + 8; /* 0x3800169E: add esi, 8 */ 1514 _flag_k = FK_ADD; 1515 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(8); 1516 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1517 edi = edi + 8; /* 0x380016A1: add edi, 8 */ 1518 _flag_k = FK_ADD; 1519 /* cmp esi, eax */ /* 0x380016A4: cmp esi, eax */ 1520 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax); 1521 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1522 _flag_k = FK_CMP; 1523 RECOMP_BACKEDGE(); 1524 if (CMP_NE(_flag_a, _flag_b)) goto L_38001693; /* 0x380016A6: jne 0x38001693 */ 1525 L_380016A8: 1526 eax = MEM32(ebx + 0x8); /* 0x380016A8: mov eax, dword ptr [ebx + 8] */ 1527 /* cmp edi, eax */ /* 0x380016AB: cmp edi, eax */ 1528 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax); 1529 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1530 _flag_k = FK_CMP; 1531 MEM32(ebp + (-0x4)) = eax; /* 0x380016AD: mov dword ptr [ebp - 4], eax */ 1532 esi = edi; /* 0x380016B0: mov esi, edi */ 1533 if (CMP_EQ(_flag_a, _flag_b)) goto L_380016C7; /* 0x380016B2: je 0x380016c7 */ 1534 L_380016B4: 1535 edx = MEM32(esi); /* 0x380016B4: mov edx, dword ptr [esi] */ 1536 PUSH32(esp, 0); /* 0x380016B6: push 0 */ 1537 ecx = esi; /* 0x380016B8: mov ecx, esi */ 1538 RECOMP_ICALL(MEM32(edx + 0xC)); /* 0x380016BA: call dword ptr [edx + 0xc] */ 1539 RECOMP_FLAGS_IN(); 1540 eax = MEM32(ebp + (-0x4)); /* 0x380016BD: mov eax, dword ptr [ebp - 4] */ 1541 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 1542 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1543 esi = esi + 8; /* 0x380016C0: add esi, 8 */ 1544 _flag_k = FK_ADD; 1545 /* cmp esi, eax */ /* 0x380016C3: cmp esi, eax */ 1546 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax); 1547 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1548 _flag_k = FK_CMP; 1549 RECOMP_BACKEDGE(); 1550 if (CMP_NE(_flag_a, _flag_b)) goto L_380016B4; /* 0x380016C5: jne 0x380016b4 */ 1551 L_380016C7: 1552 eax = MEM32(ebp + 0x8); /* 0x380016C7: mov eax, dword ptr [ebp + 8] */ 1553 ecx = MEM32(eax + 0x8); /* 0x380016CA: mov ecx, dword ptr [eax + 8] */ 1554 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4); 1555 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1556 eax = eax + 4; /* 0x380016CD: add eax, 4 */ 1557 _flag_k = FK_ADD; 1558 /* test ecx, ecx */ /* 0x380016D0: test ecx, ecx */ 1559 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx); 1560 _cf = 0; 1561 _flag_k = FK_TEST; 1562 if (TEST_NZ(_flag_a, _flag_b)) goto L_380016E4; /* 0x380016D2: jne 0x380016e4 */ 1563 L_380016D4: 1564 ecx = MEM32(ebx + 0x4); /* 0x380016D4: mov ecx, dword ptr [ebx + 4] */ 1565 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1566 eax = 0; /* 0x380016D7: xor eax, eax */ 1567 _cf = 0; 1568 _flag_k = FK_TEST; 1569 edx = ecx + eax * 8; /* 0x380016D9: lea edx, [ecx + eax*8] */ 1570 MEM32(ebx + 0x8) = edx; /* 0x380016DC: mov dword ptr [ebx + 8], edx */ 1571 goto L_3800180C; /* 0x380016DF: jmp 0x3800180c */ 1572 L_380016E4: 1573 eax = MEM32(eax + 0x8); /* 0x380016E4: mov eax, dword ptr [eax + 8] */ 1574 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx); 1575 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1576 eax = eax - ecx; /* 0x380016E7: sub eax, ecx */ 1577 _flag_k = FK_CMP; 1578 ecx = MEM32(ebx + 0x4); /* 0x380016E9: mov ecx, dword ptr [ebx + 4] */ 1579 if (3u) _cf = (((eax) >> 2) & 1u); /* 0x380016EC: sar eax, 3 */ 1580 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1581 eax = (uint32_t)((int32_t)eax >> 3u); 1582 edx = ecx + eax * 8; /* 0x380016EF: lea edx, [ecx + eax*8] */ 1583 MEM32(ebx + 0x8) = edx; /* 0x380016F2: mov dword ptr [ebx + 8], edx */ 1584 goto L_3800180C; /* 0x380016F5: jmp 0x3800180c */ 1585 L_380016FA: 1586 /* test esi, esi */ /* 0x380016FA: test esi, esi */ 1587 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi); 1588 _cf = 0; 1589 _flag_k = FK_TEST; 1590 if (TEST_NZ(_flag_a, _flag_b)) goto L_38001702; /* 0x380016FC: jne 0x38001702 */ 1591 L_380016FE: 1592 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1593 edi = 0; /* 0x380016FE: xor edi, edi */ 1594 _cf = 0; 1595 _flag_k = FK_TEST; 1596 goto L_3800170A; /* 0x38001700: jmp 0x3800170a */ 1597 L_38001702: 1598 edi = MEM32(edi + 0x8); /* 0x38001702: mov edi, dword ptr [edi + 8] */ 1599 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(esi); 1600 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1601 edi = edi - esi; /* 0x38001705: sub edi, esi */ 1602 _flag_k = FK_CMP; 1603 if (3u) _cf = (((edi) >> 2) & 1u); /* 0x38001707: sar edi, 3 */ 1604 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edi >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1605 edi = (uint32_t)((int32_t)edi >> 3u); 1606 L_3800170A: 1607 /* test eax, eax */ /* 0x3800170A: test eax, eax */ 1608 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 1609 _cf = 0; 1610 _flag_k = FK_TEST; 1611 if (TEST_NZ(_flag_a, _flag_b)) goto L_38001712; /* 0x3800170C: jne 0x38001712 */ 1612 L_3800170E: 1613 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1614 ecx = 0; /* 0x3800170E: xor ecx, ecx */ 1615 _cf = 0; 1616 _flag_k = FK_TEST; 1617 goto L_3800171A; /* 0x38001710: jmp 0x3800171a */ 1618 L_38001712: 1619 ecx = MEM32(ebx + 0xC); /* 0x38001712: mov ecx, dword ptr [ebx + 0xc] */ 1620 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax); 1621 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1622 ecx = ecx - eax; /* 0x38001715: sub ecx, eax */ 1623 _flag_k = FK_CMP; 1624 if (3u) _cf = (((ecx) >> 2) & 1u); /* 0x38001717: sar ecx, 3 */ 1625 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1626 ecx = (uint32_t)((int32_t)ecx >> 3u); 1627 L_3800171A: 1628 /* cmp edi, ecx */ /* 0x3800171A: cmp edi, ecx */ 1629 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx); 1630 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1631 _flag_k = FK_CMP; 1632 if (CMP_A(_flag_a, _flag_b)) goto L_380017AC; /* 0x3800171C: ja 0x380017ac */ 1633 L_38001722: 1634 /* test eax, eax */ /* 0x38001722: test eax, eax */ 1635 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 1636 _cf = 0; 1637 _flag_k = FK_TEST; 1638 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800172A; /* 0x38001724: jne 0x3800172a */ 1639 L_38001726: 1640 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1641 ecx = 0; /* 0x38001726: xor ecx, ecx */ 1642 _cf = 0; 1643 _flag_k = FK_TEST; 1644 goto L_38001732; /* 0x38001728: jmp 0x38001732 */ 1645 L_3800172A: 1646 ecx = MEM32(ebx + 0x8); /* 0x3800172A: mov ecx, dword ptr [ebx + 8] */ 1647 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax); 1648 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1649 ecx = ecx - eax; /* 0x3800172D: sub ecx, eax */ 1650 _flag_k = FK_CMP; 1651 if (3u) _cf = (((ecx) >> 2) & 1u); /* 0x3800172F: sar ecx, 3 */ 1652 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1653 ecx = (uint32_t)((int32_t)ecx >> 3u); 1654 L_38001732: 1655 edi = esi + ecx * 8; /* 0x38001732: lea edi, [esi + ecx*8] */ 1656 /* cmp esi, edi */ /* 0x38001735: cmp esi, edi */ 1657 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edi); 1658 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1659 _flag_k = FK_CMP; 1660 MEM32(ebp + (-0x4)) = eax; /* 0x38001737: mov dword ptr [ebp - 4], eax */ 1661 if (CMP_EQ(_flag_a, _flag_b)) goto L_38001755; /* 0x3800173A: je 0x38001755 */ 1662 L_3800173C: 1663 ecx = MEM32(ebp + (-0x4)); /* 0x3800173C: mov ecx, dword ptr [ebp - 4] */ 1664 PUSH32(esp, esi); /* 0x3800173F: push esi */ 1665 RECOMP_ICALL(0x3801E590u); /* 0x38001740: call 0x3801e590 */ /* not lifted */ 1666 RECOMP_FLAGS_IN(); 1667 edx = MEM32(ebp + (-0x4)); /* 0x38001745: mov edx, dword ptr [ebp - 4] */ 1668 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(8); 1669 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1670 edx = edx + 8; /* 0x38001748: add edx, 8 */ 1671 _flag_k = FK_ADD; 1672 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 1673 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1674 esi = esi + 8; /* 0x3800174B: add esi, 8 */ 1675 _flag_k = FK_ADD; 1676 /* cmp esi, edi */ /* 0x3800174E: cmp esi, edi */ 1677 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edi); 1678 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1679 _flag_k = FK_CMP; 1680 MEM32(ebp + (-0x4)) = edx; /* 0x38001750: mov dword ptr [ebp - 4], edx */ 1681 RECOMP_BACKEDGE(); 1682 if (CMP_NE(_flag_a, _flag_b)) goto L_3800173C; /* 0x38001753: jne 0x3800173c */ 1683 L_38001755: 1684 eax = MEM32(ebp + 0x8); /* 0x38001755: mov eax, dword ptr [ebp + 8] */ 1685 esi = MEM32(ebx + 0x8); /* 0x38001758: mov esi, dword ptr [ebx + 8] */ 1686 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4); 1687 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1688 eax = eax + 4; /* 0x3800175B: add eax, 4 */ 1689 _flag_k = FK_ADD; 1690 eax = MEM32(eax + 0x8); /* 0x3800175E: mov eax, dword ptr [eax + 8] */ 1691 /* cmp edi, eax */ /* 0x38001761: cmp edi, eax */ 1692 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax); 1693 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1694 _flag_k = FK_CMP; 1695 MEM32(ebp + (-0x4)) = eax; /* 0x38001763: mov dword ptr [ebp - 4], eax */ 1696 if (CMP_EQ(_flag_a, _flag_b)) goto L_3800177F; /* 0x38001766: je 0x3800177f */ 1697 L_38001768: 1698 PUSH32(esp, edi); /* 0x38001768: push edi */ 1699 PUSH32(esp, esi); /* 0x38001769: push esi */ 1700 RECOMP_ICALL(0x38004460u); /* 0x3800176A: call 0x38004460 */ /* not lifted */ 1701 RECOMP_FLAGS_IN(); 1702 eax = MEM32(ebp + (-0x4)); /* 0x3800176F: mov eax, dword ptr [ebp - 4] */ 1703 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(8); 1704 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1705 edi = edi + 8; /* 0x38001772: add edi, 8 */ 1706 _flag_k = FK_ADD; 1707 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8); 1708 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1709 esp = esp + 8; /* 0x38001775: add esp, 8 */ 1710 _flag_k = FK_ADD; 1711 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(8); 1712 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1713 esi = esi + 8; /* 0x38001778: add esi, 8 */ 1714 _flag_k = FK_ADD; 1715 /* cmp edi, eax */ /* 0x3800177B: cmp edi, eax */ 1716 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax); 1717 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1718 _flag_k = FK_CMP; 1719 RECOMP_BACKEDGE(); 1720 if (CMP_NE(_flag_a, _flag_b)) goto L_38001768; /* 0x3800177D: jne 0x38001768 */ 1721 L_3800177F: 1722 ecx = MEM32(ebp + 0x8); /* 0x3800177F: mov ecx, dword ptr [ebp + 8] */ 1723 eax = ecx + 0x4; /* 0x38001782: lea eax, [ecx + 4] */ 1724 ecx = MEM32(eax + 0x4); /* 0x38001785: mov ecx, dword ptr [eax + 4] */ 1725 /* test ecx, ecx */ /* 0x38001788: test ecx, ecx */ 1726 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx); 1727 _cf = 0; 1728 _flag_k = FK_TEST; 1729 if (TEST_NZ(_flag_a, _flag_b)) goto L_38001799; /* 0x3800178A: jne 0x38001799 */ 1730 L_3800178C: 1731 edx = MEM32(ebx + 0x4); /* 0x3800178C: mov edx, dword ptr [ebx + 4] */ 1732 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1733 eax = 0; /* 0x3800178F: xor eax, eax */ 1734 _cf = 0; 1735 _flag_k = FK_TEST; 1736 eax = edx + eax * 8; /* 0x38001791: lea eax, [edx + eax*8] */ 1737 MEM32(ebx + 0x8) = eax; /* 0x38001794: mov dword ptr [ebx + 8], eax */ 1738 goto L_3800180C; /* 0x38001797: jmp 0x3800180c */ 1739 L_38001799: 1740 eax = MEM32(eax + 0x8); /* 0x38001799: mov eax, dword ptr [eax + 8] */ 1741 edx = MEM32(ebx + 0x4); /* 0x3800179C: mov edx, dword ptr [ebx + 4] */ 1742 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx); 1743 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1744 eax = eax - ecx; /* 0x3800179F: sub eax, ecx */ 1745 _flag_k = FK_CMP; 1746 if (3u) _cf = (((eax) >> 2) & 1u); /* 0x380017A1: sar eax, 3 */ 1747 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1748 eax = (uint32_t)((int32_t)eax >> 3u); 1749 eax = edx + eax * 8; /* 0x380017A4: lea eax, [edx + eax*8] */ 1750 MEM32(ebx + 0x8) = eax; /* 0x380017A7: mov dword ptr [ebx + 8], eax */ 1751 goto L_3800180C; /* 0x380017AA: jmp 0x3800180c */ 1752 L_380017AC: 1753 ecx = MEM32(ebx + 0x8); /* 0x380017AC: mov ecx, dword ptr [ebx + 8] */ 1754 PUSH32(esp, ecx); /* 0x380017AF: push ecx */ 1755 PUSH32(esp, eax); /* 0x380017B0: push eax */ 1756 ecx = ebx; /* 0x380017B1: mov ecx, ebx */ 1757 RECOMP_ICALL(0x380043F0u); /* 0x380017B3: call 0x380043f0 */ /* not lifted */ 1758 RECOMP_FLAGS_IN(); 1759 edx = MEM32(ebx + 0x4); /* 0x380017B8: mov edx, dword ptr [ebx + 4] */ 1760 PUSH32(esp, edx); /* 0x380017BB: push edx */ 1761 RECOMP_ICALL(0x3804B4F6u); /* 0x380017BC: call 0x3804b4f6 */ /* not lifted */ 1762 RECOMP_FLAGS_IN(); 1763 eax = MEM32(ebp + 0x8); /* 0x380017C1: mov eax, dword ptr [ebp + 8] */ 1764 ecx = MEM32(eax + 0x8); /* 0x380017C4: mov ecx, dword ptr [eax + 8] */ 1765 esi = eax + 0x4; /* 0x380017C7: lea esi, [eax + 4] */ 1766 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 1767 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1768 esp = esp + 4; /* 0x380017CA: add esp, 4 */ 1769 _flag_k = FK_ADD; 1770 /* test ecx, ecx */ /* 0x380017CD: test ecx, ecx */ 1771 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx); 1772 _cf = 0; 1773 _flag_k = FK_TEST; 1774 if (TEST_NZ(_flag_a, _flag_b)) goto L_380017D5; /* 0x380017CF: jne 0x380017d5 */ 1775 L_380017D1: 1776 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1777 eax = 0; /* 0x380017D1: xor eax, eax */ 1778 _cf = 0; 1779 _flag_k = FK_TEST; 1780 goto L_380017DD; /* 0x380017D3: jmp 0x380017dd */ 1781 L_380017D5: 1782 eax = MEM32(esi + 0x8); /* 0x380017D5: mov eax, dword ptr [esi + 8] */ 1783 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx); 1784 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1785 eax = eax - ecx; /* 0x380017D8: sub eax, ecx */ 1786 _flag_k = FK_CMP; 1787 if (3u) _cf = (((eax) >> 2) & 1u); /* 0x380017DA: sar eax, 3 */ 1788 if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 1789 eax = (uint32_t)((int32_t)eax >> 3u); 1790 L_380017DD: 1791 /* test eax, eax */ /* 0x380017DD: test eax, eax */ 1792 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 1793 _cf = 0; 1794 _flag_k = FK_TEST; 1795 if (TEST_NS(_flag_a, _flag_b)) goto L_380017E3; /* 0x380017DF: jge 0x380017e3 */ 1796 L_380017E1: 1797 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1798 eax = 0; /* 0x380017E1: xor eax, eax */ 1799 _cf = 0; 1800 _flag_k = FK_TEST; 1801 L_380017E3: 1802 ecx = eax * 8; /* 0x380017E3: lea ecx, [eax*8] */ 1803 PUSH32(esp, ecx); /* 0x380017EA: push ecx */ 1804 RECOMP_ICALL(0x3804B676u); /* 0x380017EB: call 0x3804b676 */ /* not lifted */ 1805 RECOMP_FLAGS_IN(); 1806 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 1807 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1808 esp = esp + 4; /* 0x380017F0: add esp, 4 */ 1809 _flag_k = FK_ADD; 1810 MEM32(ebx + 0x4) = eax; /* 0x380017F3: mov dword ptr [ebx + 4], eax */ 1811 ecx = MEM32(esi + 0x8); /* 0x380017F6: mov ecx, dword ptr [esi + 8] */ 1812 esi = MEM32(esi + 0x4); /* 0x380017F9: mov esi, dword ptr [esi + 4] */ 1813 PUSH32(esp, eax); /* 0x380017FC: push eax */ 1814 PUSH32(esp, ecx); /* 0x380017FD: push ecx */ 1815 PUSH32(esp, esi); /* 0x380017FE: push esi */ 1816 ecx = ebx; /* 0x380017FF: mov ecx, ebx */ 1817 RECOMP_ICALL(0x38004420u); /* 0x38001801: call 0x38004420 */ /* not lifted */ 1818 RECOMP_FLAGS_IN(); 1819 MEM32(ebx + 0x8) = eax; /* 0x38001806: mov dword ptr [ebx + 8], eax */ 1820 MEM32(ebx + 0xC) = eax; /* 0x38001809: mov dword ptr [ebx + 0xc], eax */ 1821 L_3800180C: 1822 ecx = MEM32(ebp + 0x8); /* 0x3800180C: mov ecx, dword ptr [ebp + 8] */ 1823 SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3800180F: mov dl, byte ptr [ecx + 0x14] */ 1824 eax = MEM32(ebp + (-0x8)); /* 0x38001812: mov eax, dword ptr [ebp - 8] */ 1825 MEM8(eax + 0x14) = (uint8_t)(LO8(edx)); /* 0x38001815: mov byte ptr [eax + 0x14], dl */ 1826 edx = MEM32(ecx + 0x18); /* 0x38001818: mov edx, dword ptr [ecx + 0x18] */ 1827 edi = POP32_VAL(esp); /* 0x3800181B: pop edi */ 1828 MEM32(eax + 0x18) = edx; /* 0x3800181C: mov dword ptr [eax + 0x18], edx */ 1829 ecx = MEM32(ecx + 0x1C); /* 0x3800181F: mov ecx, dword ptr [ecx + 0x1c] */ 1830 esi = POP32_VAL(esp); /* 0x38001822: pop esi */ 1831 MEM32(eax + 0x1C) = ecx; /* 0x38001823: mov dword ptr [eax + 0x1c], ecx */ 1832 ebx = POP32_VAL(esp); /* 0x38001826: pop ebx */ 1833 esp = ebp; /* 0x38001827: mov esp, ebp */ 1834 ebp = POP32_VAL(esp); /* 0x38001829: pop ebp */ 1835 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800182A: ret 4 */ 1836 RECOMP_REGS_OUT(); 1837 } 1838 1839 void sub_3800180C(void) { 1840 int _fpu_cmp = 0; 1841 uint32_t _cf = 0; 1842 int _df = 1; 1843 uint32_t _flag_k = FK_NONE; 1844 uint32_t _flag_a = 0, _flag_b = 0; 1845 uint32_t _itail_tgt = 0; 1846 RECOMP_REGS_LOCALS 1847 RECOMP_ENTER(0x3800180Cu); 1848 1849 L_3800180C: 1850 ecx = MEM32(ebp + 0x8); /* 0x3800180C: mov ecx, dword ptr [ebp + 8] */ 1851 SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3800180F: mov dl, byte ptr [ecx + 0x14] */ 1852 eax = MEM32(ebp + (-0x8)); /* 0x38001812: mov eax, dword ptr [ebp - 8] */ 1853 MEM8(eax + 0x14) = (uint8_t)(LO8(edx)); /* 0x38001815: mov byte ptr [eax + 0x14], dl */ 1854 edx = MEM32(ecx + 0x18); /* 0x38001818: mov edx, dword ptr [ecx + 0x18] */ 1855 edi = POP32_VAL(esp); /* 0x3800181B: pop edi */ 1856 MEM32(eax + 0x18) = edx; /* 0x3800181C: mov dword ptr [eax + 0x18], edx */ 1857 ecx = MEM32(ecx + 0x1C); /* 0x3800181F: mov ecx, dword ptr [ecx + 0x1c] */ 1858 esi = POP32_VAL(esp); /* 0x38001822: pop esi */ 1859 MEM32(eax + 0x1C) = ecx; /* 0x38001823: mov dword ptr [eax + 0x1c], ecx */ 1860 ebx = POP32_VAL(esp); /* 0x38001826: pop ebx */ 1861 esp = ebp; /* 0x38001827: mov esp, ebp */ 1862 ebp = POP32_VAL(esp); /* 0x38001829: pop ebp */ 1863 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800182A: ret 4 */ 1864 RECOMP_REGS_OUT(); 1865 } 1866 1867 void sub_38001830(void) { 1868 int _fpu_cmp = 0; 1869 uint32_t _cf = 0; 1870 int _df = 1; 1871 uint32_t _flag_k = FK_NONE; 1872 uint32_t _flag_a = 0, _flag_b = 0; 1873 uint32_t _itail_tgt = 0; 1874 RECOMP_REGS_LOCALS 1875 RECOMP_ENTER(0x38001830u); 1876 1877 L_38001830: 1878 PUSH32(esp, ebp); /* 0x38001830: push ebp */ 1879 ebp = esp; /* 0x38001831: mov ebp, esp */ 1880 PUSH32(esp, ebx); /* 0x38001833: push ebx */ 1881 SET_LO8(ebx, MEM8(ebp + 0x8)); /* 0x38001834: mov bl, byte ptr [ebp + 8] */ 1882 /* test LO8(ebx), 2 */ /* 0x38001837: test bl, 2 */ 1883 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(2) << 24; 1884 _cf = 0; 1885 _flag_k = FK_NARROW(FK_TEST, 24); 1886 PUSH32(esp, esi); /* 0x3800183A: push esi */ 1887 esi = ecx; /* 0x3800183B: mov esi, ecx */ 1888 if (TEST_Z(_flag_a, _flag_b)) goto L_3800186B; /* 0x3800183D: je 0x3800186b */ 1889 L_3800183F: 1890 eax = MEM32(esi + (-0x4)); /* 0x3800183F: mov eax, dword ptr [esi - 4] */ 1891 PUSH32(esp, edi); /* 0x38001842: push edi */ 1892 PUSH32(esp, 0x3801EAA0u); /* 0x38001843: push 0x3801eaa0 */ 1893 edi = esi + (-0x4); /* 0x38001848: lea edi, [esi - 4] */ 1894 PUSH32(esp, eax); /* 0x3800184B: push eax */ 1895 PUSH32(esp, 0x20u); /* 0x3800184C: push 0x20 */ 1896 PUSH32(esp, esi); /* 0x3800184E: push esi */ 1897 RECOMP_ICALL(0x3804B582u); /* 0x3800184F: call 0x3804b582 */ /* not lifted */ 1898 RECOMP_FLAGS_IN(); 1899 /* test LO8(ebx), 1 */ /* 0x38001854: test bl, 1 */ 1900 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(1) << 24; 1901 _cf = 0; 1902 _flag_k = FK_NARROW(FK_TEST, 24); 1903 if (TEST_Z(_flag_a, _flag_b)) goto L_38001862; /* 0x38001857: je 0x38001862 */ 1904 L_38001859: 1905 PUSH32(esp, edi); /* 0x38001859: push edi */ 1906 RECOMP_ICALL(0x3804B4F6u); /* 0x3800185A: call 0x3804b4f6 */ /* not lifted */ 1907 RECOMP_FLAGS_IN(); 1908 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 1909 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1910 esp = esp + 4; /* 0x3800185F: add esp, 4 */ 1911 _flag_k = FK_ADD; 1912 L_38001862: 1913 eax = edi; /* 0x38001862: mov eax, edi */ 1914 edi = POP32_VAL(esp); /* 0x38001864: pop edi */ 1915 esi = POP32_VAL(esp); /* 0x38001865: pop esi */ 1916 ebx = POP32_VAL(esp); /* 0x38001866: pop ebx */ 1917 ebp = POP32_VAL(esp); /* 0x38001867: pop ebp */ 1918 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001868: ret 4 */ 1919 L_3800186B: 1920 ecx = esi; /* 0x3800186B: mov ecx, esi */ 1921 RECOMP_ICALL(0x3801EAA0u); /* 0x3800186D: call 0x3801eaa0 */ /* not lifted */ 1922 RECOMP_FLAGS_IN(); 1923 /* test LO8(ebx), 1 */ /* 0x38001872: test bl, 1 */ 1924 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(1) << 24; 1925 _cf = 0; 1926 _flag_k = FK_NARROW(FK_TEST, 24); 1927 if (TEST_Z(_flag_a, _flag_b)) goto L_38001880; /* 0x38001875: je 0x38001880 */ 1928 L_38001877: 1929 PUSH32(esp, esi); /* 0x38001877: push esi */ 1930 RECOMP_ICALL(0x3804B4F6u); /* 0x38001878: call 0x3804b4f6 */ /* not lifted */ 1931 RECOMP_FLAGS_IN(); 1932 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 1933 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 1934 esp = esp + 4; /* 0x3800187D: add esp, 4 */ 1935 _flag_k = FK_ADD; 1936 L_38001880: 1937 eax = esi; /* 0x38001880: mov eax, esi */ 1938 esi = POP32_VAL(esp); /* 0x38001882: pop esi */ 1939 ebx = POP32_VAL(esp); /* 0x38001883: pop ebx */ 1940 ebp = POP32_VAL(esp); /* 0x38001884: pop ebp */ 1941 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001885: ret 4 */ 1942 RECOMP_REGS_OUT(); 1943 } 1944 1945 void sub_38001890(void) { 1946 int _fpu_cmp = 0; 1947 uint32_t _cf = 0; 1948 int _df = 1; 1949 uint32_t _flag_k = FK_NONE; 1950 uint32_t _flag_a = 0, _flag_b = 0; 1951 uint32_t _itail_tgt = 0; 1952 RECOMP_REGS_LOCALS 1953 RECOMP_ENTER(0x38001890u); 1954 1955 L_38001890: 1956 PUSH32(esp, ebp); /* 0x38001890: push ebp */ 1957 ebp = esp; /* 0x38001891: mov ebp, esp */ 1958 edx = MEM32(ebp + 0x8); /* 0x38001893: mov edx, dword ptr [ebp + 8] */ 1959 eax = MEM32(ecx); /* 0x38001896: mov eax, dword ptr [ecx] */ 1960 PUSH32(esp, 0x3806EBC0u); /* 0x38001898: push 0x3806ebc0 */ 1961 PUSH32(esp, 0x3806EBB0u); /* 0x3800189D: push 0x3806ebb0 */ 1962 PUSH32(esp, edx); /* 0x380018A2: push edx */ 1963 RECOMP_ICALL(MEM32(eax + 0x1C)); /* 0x380018A3: call dword ptr [eax + 0x1c] */ 1964 RECOMP_FLAGS_IN(); 1965 ebp = POP32_VAL(esp); /* 0x380018A6: pop ebp */ 1966 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380018A7: ret 4 */ 1967 RECOMP_REGS_OUT(); 1968 } 1969 1970 void sub_380018B0(void) { 1971 int _fpu_cmp = 0; 1972 uint32_t _cf = 0; 1973 int _df = 1; 1974 uint32_t _flag_k = FK_NONE; 1975 uint32_t _flag_a = 0, _flag_b = 0; 1976 uint32_t _itail_tgt = 0; 1977 RECOMP_REGS_LOCALS 1978 RECOMP_ENTER(0x380018B0u); 1979 1980 L_380018B0: 1981 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380018B0: ret */ 1982 RECOMP_REGS_OUT(); 1983 } 1984 1985 void sub_380018C0(void) { 1986 int _fpu_cmp = 0; 1987 uint32_t _cf = 0; 1988 int _df = 1; 1989 uint32_t _flag_k = FK_NONE; 1990 uint32_t _flag_a = 0, _flag_b = 0; 1991 uint32_t _itail_tgt = 0; 1992 RECOMP_REGS_LOCALS 1993 RECOMP_ENTER(0x380018C0u); 1994 1995 L_380018C0: 1996 eax = ecx + 0x34; /* 0x380018C0: lea eax, [ecx + 0x34] */ 1997 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380018C3: ret */ 1998 RECOMP_REGS_OUT(); 1999 } 2000 2001 void sub_380018D0(void) { 2002 int _fpu_cmp = 0; 2003 uint32_t _cf = 0; 2004 int _df = 1; 2005 uint32_t _flag_k = FK_NONE; 2006 uint32_t _flag_a = 0, _flag_b = 0; 2007 uint32_t _itail_tgt = 0; 2008 RECOMP_REGS_LOCALS 2009 RECOMP_ENTER(0x380018D0u); 2010 2011 L_380018D0: 2012 eax = MEM32(ecx + 0x78); /* 0x380018D0: mov eax, dword ptr [ecx + 0x78] */ 2013 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380018D3: ret */ 2014 RECOMP_REGS_OUT(); 2015 } 2016 2017 void sub_380018E0(void) { 2018 int _fpu_cmp = 0; 2019 uint32_t _cf = 0; 2020 int _df = 1; 2021 uint32_t _flag_k = FK_NONE; 2022 uint32_t _flag_a = 0, _flag_b = 0; 2023 uint32_t _itail_tgt = 0; 2024 RECOMP_REGS_LOCALS 2025 RECOMP_ENTER(0x380018E0u); 2026 2027 L_380018E0: 2028 eax = ecx + 0x8C; /* 0x380018E0: lea eax, [ecx + 0x8c] */ 2029 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380018E6: ret */ 2030 RECOMP_REGS_OUT(); 2031 } 2032 2033 void sub_380018F0(void) { 2034 int _fpu_cmp = 0; 2035 uint32_t _cf = 0; 2036 int _df = 1; 2037 uint32_t _flag_k = FK_NONE; 2038 uint32_t _flag_a = 0, _flag_b = 0; 2039 uint32_t _itail_tgt = 0; 2040 RECOMP_REGS_LOCALS 2041 RECOMP_ENTER(0x380018F0u); 2042 2043 L_380018F0: 2044 eax = MEM32(ecx + 0x60); /* 0x380018F0: mov eax, dword ptr [ecx + 0x60] */ 2045 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380018F3: ret */ 2046 RECOMP_REGS_OUT(); 2047 } 2048 2049 void sub_38001900(void) { 2050 int _fpu_cmp = 0; 2051 uint32_t _cf = 0; 2052 int _df = 1; 2053 uint32_t _flag_k = FK_NONE; 2054 uint32_t _flag_a = 0, _flag_b = 0; 2055 uint32_t _itail_tgt = 0; 2056 RECOMP_REGS_LOCALS 2057 RECOMP_ENTER(0x38001900u); 2058 2059 L_38001900: 2060 eax = MEM32(ecx + 0x28); /* 0x38001900: mov eax, dword ptr [ecx + 0x28] */ 2061 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001903: ret */ 2062 RECOMP_REGS_OUT(); 2063 } 2064 2065 void sub_38001910(void) { 2066 int _fpu_cmp = 0; 2067 uint32_t _cf = 0; 2068 int _df = 1; 2069 uint32_t _flag_k = FK_NONE; 2070 uint32_t _flag_a = 0, _flag_b = 0; 2071 uint32_t _itail_tgt = 0; 2072 RECOMP_REGS_LOCALS 2073 RECOMP_ENTER(0x38001910u); 2074 2075 L_38001910: 2076 SET_LO8(eax, MEM8(ecx + 0x80)); /* 0x38001910: mov al, byte ptr [ecx + 0x80] */ 2077 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001916: ret */ 2078 RECOMP_REGS_OUT(); 2079 } 2080 2081 void sub_38001920(void) { 2082 int _fpu_cmp = 0; 2083 uint32_t _cf = 0; 2084 int _df = 1; 2085 uint32_t _flag_k = FK_NONE; 2086 uint32_t _flag_a = 0, _flag_b = 0; 2087 uint32_t _itail_tgt = 0; 2088 RECOMP_REGS_LOCALS 2089 RECOMP_ENTER(0x38001920u); 2090 2091 L_38001920: 2092 SET_LO8(edx, MEM8(ecx + 0x94)); /* 0x38001920: mov dl, byte ptr [ecx + 0x94] */ 2093 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 2094 eax = 0; /* 0x38001926: xor eax, eax */ 2095 _cf = 0; 2096 _flag_k = FK_TEST; 2097 /* cmp LO8(edx), 1 */ /* 0x38001928: cmp dl, 1 */ 2098 _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(1) << 24; 2099 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2100 _flag_k = FK_NARROW(FK_CMP, 24); 2101 SET_LO8(eax, (CMP_EQ(_flag_a, _flag_b)) ? 1 : 0); /* 0x3800192B: sete al */ 2102 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800192E: ret */ 2103 RECOMP_REGS_OUT(); 2104 } 2105 2106 void sub_38001930(void) { 2107 int _fpu_cmp = 0; 2108 uint32_t _cf = 0; 2109 int _df = 1; 2110 uint32_t _flag_k = FK_NONE; 2111 uint32_t _flag_a = 0, _flag_b = 0; 2112 uint32_t _itail_tgt = 0; 2113 RECOMP_REGS_LOCALS 2114 RECOMP_ENTER(0x38001930u); 2115 2116 L_38001930: 2117 eax = MEM32(ecx + 0xA0); /* 0x38001930: mov eax, dword ptr [ecx + 0xa0] */ 2118 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001936: ret */ 2119 RECOMP_REGS_OUT(); 2120 } 2121 2122 void sub_38001940(void) { 2123 int _fpu_cmp = 0; 2124 uint32_t _cf = 0; 2125 int _df = 1; 2126 uint32_t _flag_k = FK_NONE; 2127 uint32_t _flag_a = 0, _flag_b = 0; 2128 uint32_t _itail_tgt = 0; 2129 RECOMP_REGS_LOCALS 2130 RECOMP_ENTER(0x38001940u); 2131 2132 L_38001940: 2133 PUSH32(esp, ebp); /* 0x38001940: push ebp */ 2134 ebp = esp; /* 0x38001941: mov ebp, esp */ 2135 eax = MEM32(ebp + 0x8); /* 0x38001943: mov eax, dword ptr [ebp + 8] */ 2136 edx = MEM32(ebp + 0xC); /* 0x38001946: mov edx, dword ptr [ebp + 0xc] */ 2137 MEM32(ecx + 0x8C) = eax; /* 0x38001949: mov dword ptr [ecx + 0x8c], eax */ 2138 MEM32(ecx + 0x90) = edx; /* 0x3800194F: mov dword ptr [ecx + 0x90], edx */ 2139 ebp = POP32_VAL(esp); /* 0x38001955: pop ebp */ 2140 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x38001956: ret 8 */ 2141 RECOMP_REGS_OUT(); 2142 } 2143 2144 void sub_38001960(void) { 2145 int _fpu_cmp = 0; 2146 uint32_t _cf = 0; 2147 int _df = 1; 2148 uint32_t _flag_k = FK_NONE; 2149 uint32_t _flag_a = 0, _flag_b = 0; 2150 uint32_t _itail_tgt = 0; 2151 RECOMP_REGS_LOCALS 2152 RECOMP_ENTER(0x38001960u); 2153 2154 L_38001960: 2155 PUSH32(esp, ebp); /* 0x38001960: push ebp */ 2156 ebp = esp; /* 0x38001961: mov ebp, esp */ 2157 eax = MEM32(ebp + 0x8); /* 0x38001963: mov eax, dword ptr [ebp + 8] */ 2158 edx = MEM32(eax); /* 0x38001966: mov edx, dword ptr [eax] */ 2159 MEM32(ecx + 0x8C) = edx; /* 0x38001968: mov dword ptr [ecx + 0x8c], edx */ 2160 eax = MEM32(eax + 0x4); /* 0x3800196E: mov eax, dword ptr [eax + 4] */ 2161 MEM32(ecx + 0x90) = eax; /* 0x38001971: mov dword ptr [ecx + 0x90], eax */ 2162 ebp = POP32_VAL(esp); /* 0x38001977: pop ebp */ 2163 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001978: ret 4 */ 2164 RECOMP_REGS_OUT(); 2165 } 2166 2167 void sub_38001980(void) { 2168 int _fpu_cmp = 0; 2169 uint32_t _cf = 0; 2170 int _df = 1; 2171 uint32_t _flag_k = FK_NONE; 2172 uint32_t _flag_a = 0, _flag_b = 0; 2173 uint32_t _itail_tgt = 0; 2174 RECOMP_REGS_LOCALS 2175 RECOMP_ENTER(0x38001980u); 2176 2177 L_38001980: 2178 fp_push(*(float*)&MEM32(ecx + 0xD0)); /* 0x38001980: fld dword ptr [ecx + 0xd0] */ 2179 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001986: ret */ 2180 RECOMP_REGS_OUT(); 2181 } 2182 2183 void sub_38001990(void) { 2184 int _fpu_cmp = 0; 2185 uint32_t _cf = 0; 2186 int _df = 1; 2187 uint32_t _flag_k = FK_NONE; 2188 uint32_t _flag_a = 0, _flag_b = 0; 2189 uint32_t _itail_tgt = 0; 2190 RECOMP_REGS_LOCALS 2191 RECOMP_ENTER(0x38001990u); 2192 2193 L_38001990: 2194 PUSH32(esp, ebp); /* 0x38001990: push ebp */ 2195 ebp = esp; /* 0x38001991: mov ebp, esp */ 2196 eax = MEM32(ebp + 0x8); /* 0x38001993: mov eax, dword ptr [ebp + 8] */ 2197 MEM32(ecx + 0xD0) = eax; /* 0x38001996: mov dword ptr [ecx + 0xd0], eax */ 2198 ebp = POP32_VAL(esp); /* 0x3800199C: pop ebp */ 2199 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800199D: ret 4 */ 2200 RECOMP_REGS_OUT(); 2201 } 2202 2203 void sub_380019A0(void) { 2204 int _fpu_cmp = 0; 2205 uint32_t _cf = 0; 2206 int _df = 1; 2207 uint32_t _flag_k = FK_NONE; 2208 uint32_t _flag_a = 0, _flag_b = 0; 2209 uint32_t _itail_tgt = 0; 2210 RECOMP_REGS_LOCALS 2211 RECOMP_ENTER(0x380019A0u); 2212 2213 L_380019A0: 2214 fp_push(*(float*)&MEM32(ecx + 0xCC)); /* 0x380019A0: fld dword ptr [ecx + 0xcc] */ 2215 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380019A6: ret */ 2216 RECOMP_REGS_OUT(); 2217 } 2218 2219 void sub_380019B0(void) { 2220 int _fpu_cmp = 0; 2221 uint32_t _cf = 0; 2222 int _df = 1; 2223 uint32_t _flag_k = FK_NONE; 2224 uint32_t _flag_a = 0, _flag_b = 0; 2225 uint32_t _itail_tgt = 0; 2226 RECOMP_REGS_LOCALS 2227 RECOMP_ENTER(0x380019B0u); 2228 2229 L_380019B0: 2230 PUSH32(esp, ebp); /* 0x380019B0: push ebp */ 2231 ebp = esp; /* 0x380019B1: mov ebp, esp */ 2232 eax = MEM32(ebp + 0x8); /* 0x380019B3: mov eax, dword ptr [ebp + 8] */ 2233 MEM32(ecx + 0xCC) = eax; /* 0x380019B6: mov dword ptr [ecx + 0xcc], eax */ 2234 ebp = POP32_VAL(esp); /* 0x380019BC: pop ebp */ 2235 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380019BD: ret 4 */ 2236 RECOMP_REGS_OUT(); 2237 } 2238 2239 void sub_380019C0(void) { 2240 int _fpu_cmp = 0; 2241 uint32_t _cf = 0; 2242 int _df = 1; 2243 uint32_t _flag_k = FK_NONE; 2244 uint32_t _flag_a = 0, _flag_b = 0; 2245 uint32_t _itail_tgt = 0; 2246 RECOMP_REGS_LOCALS 2247 RECOMP_ENTER(0x380019C0u); 2248 2249 L_380019C0: 2250 eax = MEM32(ecx + 0x104); /* 0x380019C0: mov eax, dword ptr [ecx + 0x104] */ 2251 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380019C6: ret */ 2252 RECOMP_REGS_OUT(); 2253 } 2254 2255 void sub_380019D0(void) { 2256 int _fpu_cmp = 0; 2257 uint32_t _cf = 0; 2258 int _df = 1; 2259 uint32_t _flag_k = FK_NONE; 2260 uint32_t _flag_a = 0, _flag_b = 0; 2261 uint32_t _itail_tgt = 0; 2262 RECOMP_REGS_LOCALS 2263 RECOMP_ENTER(0x380019D0u); 2264 2265 L_380019D0: 2266 PUSH32(esp, ebp); /* 0x380019D0: push ebp */ 2267 ebp = esp; /* 0x380019D1: mov ebp, esp */ 2268 eax = MEM32(ebp + 0x8); /* 0x380019D3: mov eax, dword ptr [ebp + 8] */ 2269 MEM32(ecx + 0x104) = eax; /* 0x380019D6: mov dword ptr [ecx + 0x104], eax */ 2270 ebp = POP32_VAL(esp); /* 0x380019DC: pop ebp */ 2271 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380019DD: ret 4 */ 2272 RECOMP_REGS_OUT(); 2273 } 2274 2275 void sub_380019E0(void) { 2276 int _fpu_cmp = 0; 2277 uint32_t _cf = 0; 2278 int _df = 1; 2279 uint32_t _flag_k = FK_NONE; 2280 uint32_t _flag_a = 0, _flag_b = 0; 2281 uint32_t _itail_tgt = 0; 2282 RECOMP_REGS_LOCALS 2283 RECOMP_ENTER(0x380019E0u); 2284 2285 L_380019E0: 2286 PUSH32(esp, ebp); /* 0x380019E0: push ebp */ 2287 ebp = esp; /* 0x380019E1: mov ebp, esp */ 2288 edx = MEM32(ecx + 0x104); /* 0x380019E3: mov edx, dword ptr [ecx + 0x104] */ 2289 eax = MEM32(ebp + 0x8); /* 0x380019E9: mov eax, dword ptr [ebp + 8] */ 2290 _flag_a = (uint32_t)((edx | eax)); _flag_b = (uint32_t)((edx | eax)); 2291 edx = edx | eax; /* 0x380019EC: or edx, eax */ 2292 _cf = 0; 2293 _flag_k = FK_TEST; 2294 MEM32(ecx + 0x104) = edx; /* 0x380019EE: mov dword ptr [ecx + 0x104], edx */ 2295 ebp = POP32_VAL(esp); /* 0x380019F4: pop ebp */ 2296 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380019F5: ret 4 */ 2297 RECOMP_REGS_OUT(); 2298 } 2299 2300 void sub_38001A00(void) { 2301 int _fpu_cmp = 0; 2302 uint32_t _cf = 0; 2303 int _df = 1; 2304 uint32_t _flag_k = FK_NONE; 2305 uint32_t _flag_a = 0, _flag_b = 0; 2306 uint32_t _itail_tgt = 0; 2307 RECOMP_REGS_LOCALS 2308 RECOMP_ENTER(0x38001A00u); 2309 2310 L_38001A00: 2311 PUSH32(esp, ebp); /* 0x38001A00: push ebp */ 2312 ebp = esp; /* 0x38001A01: mov ebp, esp */ 2313 eax = MEM32(ebp + 0x8); /* 0x38001A03: mov eax, dword ptr [ebp + 8] */ 2314 edx = MEM32(ecx + 0x104); /* 0x38001A06: mov edx, dword ptr [ecx + 0x104] */ 2315 eax = ~eax; /* 0x38001A0C: not eax */ 2316 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax); 2317 edx = edx & eax; /* 0x38001A0E: and edx, eax */ 2318 _cf = 0; 2319 _flag_k = FK_TEST; 2320 MEM32(ecx + 0x104) = edx; /* 0x38001A10: mov dword ptr [ecx + 0x104], edx */ 2321 ebp = POP32_VAL(esp); /* 0x38001A16: pop ebp */ 2322 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001A17: ret 4 */ 2323 RECOMP_REGS_OUT(); 2324 } 2325 2326 void sub_38001A20(void) { 2327 int _fpu_cmp = 0; 2328 uint32_t _cf = 0; 2329 int _df = 1; 2330 uint32_t _flag_k = FK_NONE; 2331 uint32_t _flag_a = 0, _flag_b = 0; 2332 uint32_t _itail_tgt = 0; 2333 RECOMP_REGS_LOCALS 2334 RECOMP_ENTER(0x38001A20u); 2335 2336 L_38001A20: 2337 eax = ecx + 0x110; /* 0x38001A20: lea eax, [ecx + 0x110] */ 2338 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001A26: ret */ 2339 RECOMP_REGS_OUT(); 2340 } 2341 2342 void sub_38001A30(void) { 2343 int _fpu_cmp = 0; 2344 uint32_t _cf = 0; 2345 int _df = 1; 2346 uint32_t _flag_k = FK_NONE; 2347 uint32_t _flag_a = 0, _flag_b = 0; 2348 uint32_t _itail_tgt = 0; 2349 RECOMP_REGS_LOCALS 2350 RECOMP_ENTER(0x38001A30u); 2351 2352 L_38001A30: 2353 fp_push(*(float*)&MEM32(ecx + 0xBC)); /* 0x38001A30: fld dword ptr [ecx + 0xbc] */ 2354 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001A36: ret */ 2355 RECOMP_REGS_OUT(); 2356 } 2357 2358 void sub_38001A40(void) { 2359 int _fpu_cmp = 0; 2360 uint32_t _cf = 0; 2361 int _df = 1; 2362 uint32_t _flag_k = FK_NONE; 2363 uint32_t _flag_a = 0, _flag_b = 0; 2364 uint32_t _itail_tgt = 0; 2365 RECOMP_REGS_LOCALS 2366 RECOMP_ENTER(0x38001A40u); 2367 2368 L_38001A40: 2369 eax = ecx + 0x138; /* 0x38001A40: lea eax, [ecx + 0x138] */ 2370 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001A46: ret */ 2371 RECOMP_REGS_OUT(); 2372 } 2373 2374 void sub_38001A50(void) { 2375 int _fpu_cmp = 0; 2376 uint32_t _cf = 0; 2377 int _df = 1; 2378 uint32_t _flag_k = FK_NONE; 2379 uint32_t _flag_a = 0, _flag_b = 0; 2380 uint32_t _itail_tgt = 0; 2381 RECOMP_REGS_LOCALS 2382 RECOMP_ENTER(0x38001A50u); 2383 2384 L_38001A50: 2385 eax = ecx + 0x144; /* 0x38001A50: lea eax, [ecx + 0x144] */ 2386 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001A56: ret */ 2387 RECOMP_REGS_OUT(); 2388 } 2389 2390 void sub_38001A60(void) { 2391 int _fpu_cmp = 0; 2392 uint32_t _cf = 0; 2393 int _df = 1; 2394 uint32_t _flag_k = FK_NONE; 2395 uint32_t _flag_a = 0, _flag_b = 0; 2396 uint32_t _itail_tgt = 0; 2397 RECOMP_REGS_LOCALS 2398 RECOMP_ENTER(0x38001A60u); 2399 2400 L_38001A60: 2401 PUSH32(esp, ebp); /* 0x38001A60: push ebp */ 2402 ebp = esp; /* 0x38001A61: mov ebp, esp */ 2403 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu); 2404 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2405 esp = esp - 0xCu; /* 0x38001A63: sub esp, 0xc */ 2406 _flag_k = FK_CMP; 2407 eax = ecx + 0x138; /* 0x38001A66: lea eax, [ecx + 0x138] */ 2408 edx = MEM32(eax); /* 0x38001A6C: mov edx, dword ptr [eax] */ 2409 MEM32(ebp + (-0xC)) = edx; /* 0x38001A6E: mov dword ptr [ebp - 0xc], edx */ 2410 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x38001A71: fld dword ptr [ebp - 0xc] */ 2411 _st[0] += (double)*(float*)ADDR(ecx + 0x178); /* 0x38001A74: fadd dword ptr [ecx + 0x178] */ 2412 edx = MEM32(eax + 0x4); /* 0x38001A7A: mov edx, dword ptr [eax + 4] */ 2413 eax = MEM32(eax + 0x8); /* 0x38001A7D: mov eax, dword ptr [eax + 8] */ 2414 MEM32(ebp + (-0x8)) = edx; /* 0x38001A80: mov dword ptr [ebp - 8], edx */ 2415 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x38001A83: fstp dword ptr [ebp - 0xc] */ 2416 edx = MEM32(ebp + (-0xC)); /* 0x38001A86: mov edx, dword ptr [ebp - 0xc] */ 2417 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x38001A89: fld dword ptr [ebp - 8] */ 2418 MEM32(ebp + (-0x4)) = eax; /* 0x38001A8C: mov dword ptr [ebp - 4], eax */ 2419 _st[0] += (double)*(float*)ADDR(ecx + 0x17C); /* 0x38001A8F: fadd dword ptr [ecx + 0x17c] */ 2420 eax = MEM32(ebp + 0x8); /* 0x38001A95: mov eax, dword ptr [ebp + 8] */ 2421 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x38001A98: fstp dword ptr [ebp - 8] */ 2422 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x38001A9B: fld dword ptr [ebp - 4] */ 2423 _st[0] += (double)*(float*)ADDR(ecx + 0x180); /* 0x38001A9E: fadd dword ptr [ecx + 0x180] */ 2424 ecx = eax; /* 0x38001AA4: mov ecx, eax */ 2425 MEM32(ecx) = edx; /* 0x38001AA6: mov dword ptr [ecx], edx */ 2426 edx = MEM32(ebp + (-0x8)); /* 0x38001AA8: mov edx, dword ptr [ebp - 8] */ 2427 MEM32(ecx + 0x4) = edx; /* 0x38001AAB: mov dword ptr [ecx + 4], edx */ 2428 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x38001AAE: fstp dword ptr [ebp - 4] */ 2429 edx = MEM32(ebp + (-0x4)); /* 0x38001AB1: mov edx, dword ptr [ebp - 4] */ 2430 MEM32(ecx + 0x8) = edx; /* 0x38001AB4: mov dword ptr [ecx + 8], edx */ 2431 esp = ebp; /* 0x38001AB7: mov esp, ebp */ 2432 ebp = POP32_VAL(esp); /* 0x38001AB9: pop ebp */ 2433 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001ABA: ret 4 */ 2434 RECOMP_REGS_OUT(); 2435 } 2436 2437 void sub_38001AC0(void) { 2438 int _fpu_cmp = 0; 2439 uint32_t _cf = 0; 2440 int _df = 1; 2441 uint32_t _flag_k = FK_NONE; 2442 uint32_t _flag_a = 0, _flag_b = 0; 2443 uint32_t _itail_tgt = 0; 2444 RECOMP_REGS_LOCALS 2445 RECOMP_ENTER(0x38001AC0u); 2446 2447 L_38001AC0: 2448 fp_push(*(float*)&MEM32(ecx + 0xC0)); /* 0x38001AC0: fld dword ptr [ecx + 0xc0] */ 2449 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001AC6: ret */ 2450 RECOMP_REGS_OUT(); 2451 } 2452 2453 void sub_38001AD0(void) { 2454 int _fpu_cmp = 0; 2455 uint32_t _cf = 0; 2456 int _df = 1; 2457 uint32_t _flag_k = FK_NONE; 2458 uint32_t _flag_a = 0, _flag_b = 0; 2459 uint32_t _itail_tgt = 0; 2460 RECOMP_REGS_LOCALS 2461 RECOMP_ENTER(0x38001AD0u); 2462 2463 L_38001AD0: 2464 eax = MEM32(ecx + 0x1B0); /* 0x38001AD0: mov eax, dword ptr [ecx + 0x1b0] */ 2465 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001AD6: ret */ 2466 RECOMP_REGS_OUT(); 2467 } 2468 2469 void sub_38001AE0(void) { 2470 int _fpu_cmp = 0; 2471 uint32_t _cf = 0; 2472 int _df = 1; 2473 uint32_t _flag_k = FK_NONE; 2474 uint32_t _flag_a = 0, _flag_b = 0; 2475 uint32_t _itail_tgt = 0; 2476 RECOMP_REGS_LOCALS 2477 RECOMP_ENTER(0x38001AE0u); 2478 2479 L_38001AE0: 2480 PUSH32(esp, ebp); /* 0x38001AE0: push ebp */ 2481 ebp = esp; /* 0x38001AE1: mov ebp, esp */ 2482 edx = MEM32(ebp + 0x8); /* 0x38001AE3: mov edx, dword ptr [ebp + 8] */ 2483 PUSH32(esp, esi); /* 0x38001AE6: push esi */ 2484 esi = MEM32(edx); /* 0x38001AE7: mov esi, dword ptr [edx] */ 2485 eax = ecx + 0x178; /* 0x38001AE9: lea eax, [ecx + 0x178] */ 2486 MEM32(eax) = esi; /* 0x38001AEF: mov dword ptr [eax], esi */ 2487 esi = MEM32(edx + 0x4); /* 0x38001AF1: mov esi, dword ptr [edx + 4] */ 2488 MEM32(eax + 0x4) = esi; /* 0x38001AF4: mov dword ptr [eax + 4], esi */ 2489 edx = MEM32(edx + 0x8); /* 0x38001AF7: mov edx, dword ptr [edx + 8] */ 2490 MEM32(eax + 0x8) = edx; /* 0x38001AFA: mov dword ptr [eax + 8], edx */ 2491 RECOMP_ICALL(0x380084F0u); /* 0x38001AFD: call 0x380084f0 */ /* not lifted */ 2492 RECOMP_FLAGS_IN(); 2493 esi = POP32_VAL(esp); /* 0x38001B02: pop esi */ 2494 ebp = POP32_VAL(esp); /* 0x38001B03: pop ebp */ 2495 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001B04: ret 4 */ 2496 RECOMP_REGS_OUT(); 2497 } 2498 2499 void sub_38001B10(void) { 2500 int _fpu_cmp = 0; 2501 uint32_t _cf = 0; 2502 int _df = 1; 2503 uint32_t _flag_k = FK_NONE; 2504 uint32_t _flag_a = 0, _flag_b = 0; 2505 uint32_t _itail_tgt = 0; 2506 RECOMP_REGS_LOCALS 2507 RECOMP_ENTER(0x38001B10u); 2508 2509 L_38001B10: 2510 fp_push(*(float*)&MEM32(ecx + 0xE0)); /* 0x38001B10: fld dword ptr [ecx + 0xe0] */ 2511 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001B16: ret */ 2512 RECOMP_REGS_OUT(); 2513 } 2514 2515 void sub_38001B20(void) { 2516 int _fpu_cmp = 0; 2517 uint32_t _cf = 0; 2518 int _df = 1; 2519 uint32_t _flag_k = FK_NONE; 2520 uint32_t _flag_a = 0, _flag_b = 0; 2521 uint32_t _itail_tgt = 0; 2522 RECOMP_REGS_LOCALS 2523 RECOMP_ENTER(0x38001B20u); 2524 2525 L_38001B20: 2526 _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24; 2527 SET_LO8(eax, 0); /* 0x38001B20: xor al, al */ 2528 _cf = 0; 2529 _flag_k = FK_NARROW(FK_TEST, 24); 2530 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001B22: ret 4 */ 2531 RECOMP_REGS_OUT(); 2532 } 2533 2534 void sub_38001B30(void) { 2535 int _fpu_cmp = 0; 2536 uint32_t _cf = 0; 2537 int _df = 1; 2538 uint32_t _flag_k = FK_NONE; 2539 uint32_t _flag_a = 0, _flag_b = 0; 2540 uint32_t _itail_tgt = 0; 2541 RECOMP_REGS_LOCALS 2542 RECOMP_ENTER(0x38001B30u); 2543 2544 L_38001B30: 2545 MEM8(0x3806CBE8) = (uint8_t)(1); /* 0x38001B30: mov byte ptr [0x3806cbe8], 1 */ 2546 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001B37: ret */ 2547 RECOMP_REGS_OUT(); 2548 } 2549 2550 void sub_38001B40(void) { 2551 int _fpu_cmp = 0; 2552 uint32_t _cf = 0; 2553 int _df = 1; 2554 uint32_t _flag_k = FK_NONE; 2555 uint32_t _flag_a = 0, _flag_b = 0; 2556 uint32_t _itail_tgt = 0; 2557 RECOMP_REGS_LOCALS 2558 RECOMP_ENTER(0x38001B40u); 2559 2560 L_38001B40: 2561 MEM8(0x3806CBE8) = (uint8_t)(0); /* 0x38001B40: mov byte ptr [0x3806cbe8], 0 */ 2562 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001B47: ret */ 2563 RECOMP_REGS_OUT(); 2564 } 2565 2566 void sub_38001B50(void) { 2567 int _fpu_cmp = 0; 2568 uint32_t _cf = 0; 2569 int _df = 1; 2570 uint32_t _flag_k = FK_NONE; 2571 uint32_t _flag_a = 0, _flag_b = 0; 2572 uint32_t _itail_tgt = 0; 2573 RECOMP_REGS_LOCALS 2574 RECOMP_ENTER(0x38001B50u); 2575 2576 L_38001B50: 2577 SET_LO8(eax, MEM8(0x3806CBE8)); /* 0x38001B50: mov al, byte ptr [0x3806cbe8] */ 2578 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001B55: ret */ 2579 RECOMP_REGS_OUT(); 2580 } 2581 2582 void sub_38001B60(void) { 2583 int _fpu_cmp = 0; 2584 uint32_t _cf = 0; 2585 int _df = 1; 2586 uint32_t _flag_k = FK_NONE; 2587 uint32_t _flag_a = 0, _flag_b = 0; 2588 uint32_t _itail_tgt = 0; 2589 RECOMP_REGS_LOCALS 2590 RECOMP_ENTER(0x38001B60u); 2591 2592 L_38001B60: 2593 PUSH32(esp, ebp); /* 0x38001B60: push ebp */ 2594 ebp = esp; /* 0x38001B61: mov ebp, esp */ 2595 PUSH32(esp, 0xFFFFFFFFu); /* 0x38001B63: push -1 */ 2596 PUSH32(esp, 0x3804B938u); /* 0x38001B65: push 0x3804b938 */ 2597 eax = MEM32(FS_BASE + (0)); /* 0x38001B6A: mov eax, dword ptr fs:[0] */ 2598 PUSH32(esp, eax); /* 0x38001B70: push eax */ 2599 MEM32(FS_BASE + (0)) = esp; /* 0x38001B71: mov dword ptr fs:[0], esp */ 2600 PUSH32(esp, ecx); /* 0x38001B78: push ecx */ 2601 PUSH32(esp, esi); /* 0x38001B79: push esi */ 2602 esi = ecx; /* 0x38001B7A: mov esi, ecx */ 2603 MEM32(ebp + (-0x10)) = esi; /* 0x38001B7C: mov dword ptr [ebp - 0x10], esi */ 2604 RECOMP_ICALL(0x380141B0u); /* 0x38001B7F: call 0x380141b0 */ /* not lifted */ 2605 RECOMP_FLAGS_IN(); 2606 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 2607 eax = 0; /* 0x38001B84: xor eax, eax */ 2608 _cf = 0; 2609 _flag_k = FK_TEST; 2610 MEM32(esi + 0x13C) = eax; /* 0x38001B86: mov dword ptr [esi + 0x13c], eax */ 2611 MEM32(esi + 0x140) = eax; /* 0x38001B8C: mov dword ptr [esi + 0x140], eax */ 2612 MEM32(esi + 0x144) = eax; /* 0x38001B92: mov dword ptr [esi + 0x144], eax */ 2613 MEM32(esi + 0x148) = eax; /* 0x38001B98: mov dword ptr [esi + 0x148], eax */ 2614 MEM32(esi + 0x14C) = eax; /* 0x38001B9E: mov dword ptr [esi + 0x14c], eax */ 2615 MEM32(esi + 0x150) = eax; /* 0x38001BA4: mov dword ptr [esi + 0x150], eax */ 2616 MEM32(esi + 0x154) = 0x3F800000u; /* 0x38001BAA: mov dword ptr [esi + 0x154], 0x3f800000 */ 2617 MEM32(esi + 0x15C) = eax; /* 0x38001BB4: mov dword ptr [esi + 0x15c], eax */ 2618 MEM32(esi + 0x160) = eax; /* 0x38001BBA: mov dword ptr [esi + 0x160], eax */ 2619 MEM32(esi + 0x164) = eax; /* 0x38001BC0: mov dword ptr [esi + 0x164], eax */ 2620 MEM32(esi + 0x168) = eax; /* 0x38001BC6: mov dword ptr [esi + 0x168], eax */ 2621 MEM32(esi + 0x16C) = eax; /* 0x38001BCC: mov dword ptr [esi + 0x16c], eax */ 2622 MEM32(esi + 0x170) = eax; /* 0x38001BD2: mov dword ptr [esi + 0x170], eax */ 2623 MEM32(esi + 0x178) = eax; /* 0x38001BD8: mov dword ptr [esi + 0x178], eax */ 2624 MEM32(esi + 0x17C) = eax; /* 0x38001BDE: mov dword ptr [esi + 0x17c], eax */ 2625 MEM32(esi + 0x19C) = eax; /* 0x38001BE4: mov dword ptr [esi + 0x19c], eax */ 2626 MEM32(esi + 0x1A0) = eax; /* 0x38001BEA: mov dword ptr [esi + 0x1a0], eax */ 2627 MEM32(esi + 0x1A4) = eax; /* 0x38001BF0: mov dword ptr [esi + 0x1a4], eax */ 2628 MEM32(esi + 0x1AC) = eax; /* 0x38001BF6: mov dword ptr [esi + 0x1ac], eax */ 2629 MEM32(esi + 0x1B0) = eax; /* 0x38001BFC: mov dword ptr [esi + 0x1b0], eax */ 2630 MEM32(esi + 0x1B4) = eax; /* 0x38001C02: mov dword ptr [esi + 0x1b4], eax */ 2631 MEM32(esi + 0x1B8) = eax; /* 0x38001C08: mov dword ptr [esi + 0x1b8], eax */ 2632 MEM32(esi + 0x1BC) = eax; /* 0x38001C0E: mov dword ptr [esi + 0x1bc], eax */ 2633 MEM32(esi + 0x1C0) = eax; /* 0x38001C14: mov dword ptr [esi + 0x1c0], eax */ 2634 SET_LO8(ecx, 1); /* 0x38001C1A: mov cl, 1 */ 2635 MEM8(esi + 0x1A8) = (uint8_t)(LO8(ecx)); /* 0x38001C1C: mov byte ptr [esi + 0x1a8], cl */ 2636 MEM8(esi + 0x1C7) = (uint8_t)(LO8(ecx)); /* 0x38001C22: mov byte ptr [esi + 0x1c7], cl */ 2637 PUSH32(esp, 3); /* 0x38001C28: push 3 */ 2638 ecx = esi; /* 0x38001C2A: mov ecx, esi */ 2639 MEM32(ebp + (-0x4)) = eax; /* 0x38001C2C: mov dword ptr [ebp - 4], eax */ 2640 MEM32(esi) = 0x3804E82Cu; /* 0x38001C2F: mov dword ptr [esi], 0x3804e82c */ 2641 MEM32(esi + 0x20) = 0x3804E824u; /* 0x38001C35: mov dword ptr [esi + 0x20], 0x3804e824 */ 2642 MEM32(esi + 0x180) = eax; /* 0x38001C3C: mov dword ptr [esi + 0x180], eax */ 2643 MEM32(esi + 0x188) = eax; /* 0x38001C42: mov dword ptr [esi + 0x188], eax */ 2644 MEM32(esi + 0x184) = eax; /* 0x38001C48: mov dword ptr [esi + 0x184], eax */ 2645 MEM32(esi + 0x174) = 0x40A00000u; /* 0x38001C4E: mov dword ptr [esi + 0x174], 0x40a00000 */ 2646 MEM32(esi + 0x190) = eax; /* 0x38001C58: mov dword ptr [esi + 0x190], eax */ 2647 MEM8(esi + 0x1C4) = (uint8_t)(LO8(eax)); /* 0x38001C5E: mov byte ptr [esi + 0x1c4], al */ 2648 MEM8(esi + 0x1C5) = (uint8_t)(LO8(eax)); /* 0x38001C64: mov byte ptr [esi + 0x1c5], al */ 2649 MEM8(esi + 0x1A9) = (uint8_t)(LO8(eax)); /* 0x38001C6A: mov byte ptr [esi + 0x1a9], al */ 2650 MEM32(esi + 0x158) = eax; /* 0x38001C70: mov dword ptr [esi + 0x158], eax */ 2651 MEM8(esi + 0x1C6) = (uint8_t)(LO8(eax)); /* 0x38001C76: mov byte ptr [esi + 0x1c6], al */ 2652 MEM8(esi + 0x1C8) = (uint8_t)(LO8(eax)); /* 0x38001C7C: mov byte ptr [esi + 0x1c8], al */ 2653 MEM32(esi + 0x194) = eax; /* 0x38001C82: mov dword ptr [esi + 0x194], eax */ 2654 MEM32(esi + 0x108) = 0x3D4CCCCDu; /* 0x38001C88: mov dword ptr [esi + 0x108], 0x3d4ccccd */ 2655 RECOMP_ICALL(MEM32(0x3804E70C)); /* 0x38001C92: call dword ptr [0x3804e70c] */ 2656 RECOMP_FLAGS_IN(); 2657 ecx = MEM32(ebp + (-0xC)); /* 0x38001C98: mov ecx, dword ptr [ebp - 0xc] */ 2658 eax = esi; /* 0x38001C9B: mov eax, esi */ 2659 esi = POP32_VAL(esp); /* 0x38001C9D: pop esi */ 2660 MEM32(FS_BASE + (0)) = ecx; /* 0x38001C9E: mov dword ptr fs:[0], ecx */ 2661 esp = ebp; /* 0x38001CA5: mov esp, ebp */ 2662 ebp = POP32_VAL(esp); /* 0x38001CA7: pop ebp */ 2663 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38001CA8: ret */ 2664 RECOMP_REGS_OUT(); 2665 } 2666 2667 void sub_38001CB0(void) { 2668 int _fpu_cmp = 0; 2669 uint32_t _cf = 0; 2670 int _df = 1; 2671 uint32_t _flag_k = FK_NONE; 2672 uint32_t _flag_a = 0, _flag_b = 0; 2673 uint32_t _itail_tgt = 0; 2674 RECOMP_REGS_LOCALS 2675 RECOMP_ENTER(0x38001CB0u); 2676 2677 L_38001CB0: 2678 PUSH32(esp, ebp); /* 0x38001CB0: push ebp */ 2679 ebp = esp; /* 0x38001CB1: mov ebp, esp */ 2680 PUSH32(esp, ebx); /* 0x38001CB3: push ebx */ 2681 SET_LO8(ebx, MEM8(ebp + 0x8)); /* 0x38001CB4: mov bl, byte ptr [ebp + 8] */ 2682 /* test LO8(ebx), 2 */ /* 0x38001CB7: test bl, 2 */ 2683 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(2) << 24; 2684 _cf = 0; 2685 _flag_k = FK_NARROW(FK_TEST, 24); 2686 PUSH32(esp, esi); /* 0x38001CBA: push esi */ 2687 esi = ecx; /* 0x38001CBB: mov esi, ecx */ 2688 if (TEST_Z(_flag_a, _flag_b)) goto L_38001CEE; /* 0x38001CBD: je 0x38001cee */ 2689 L_38001CBF: 2690 eax = MEM32(esi + (-0x4)); /* 0x38001CBF: mov eax, dword ptr [esi - 4] */ 2691 PUSH32(esp, edi); /* 0x38001CC2: push edi */ 2692 PUSH32(esp, 0x38001D10u); /* 0x38001CC3: push 0x38001d10 */ 2693 edi = esi + (-0x4); /* 0x38001CC8: lea edi, [esi - 4] */ 2694 PUSH32(esp, eax); /* 0x38001CCB: push eax */ 2695 PUSH32(esp, 0x1CCu); /* 0x38001CCC: push 0x1cc */ 2696 PUSH32(esp, esi); /* 0x38001CD1: push esi */ 2697 RECOMP_ICALL(0x3804B582u); /* 0x38001CD2: call 0x3804b582 */ /* not lifted */ 2698 RECOMP_FLAGS_IN(); 2699 /* test LO8(ebx), 1 */ /* 0x38001CD7: test bl, 1 */ 2700 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(1) << 24; 2701 _cf = 0; 2702 _flag_k = FK_NARROW(FK_TEST, 24); 2703 if (TEST_Z(_flag_a, _flag_b)) goto L_38001CE5; /* 0x38001CDA: je 0x38001ce5 */ 2704 L_38001CDC: 2705 PUSH32(esp, edi); /* 0x38001CDC: push edi */ 2706 RECOMP_ICALL(0x3804B4F6u); /* 0x38001CDD: call 0x3804b4f6 */ /* not lifted */ 2707 RECOMP_FLAGS_IN(); 2708 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 2709 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 2710 esp = esp + 4; /* 0x38001CE2: add esp, 4 */ 2711 _flag_k = FK_ADD; 2712 L_38001CE5: 2713 eax = edi; /* 0x38001CE5: mov eax, edi */ 2714 edi = POP32_VAL(esp); /* 0x38001CE7: pop edi */ 2715 esi = POP32_VAL(esp); /* 0x38001CE8: pop esi */ 2716 ebx = POP32_VAL(esp); /* 0x38001CE9: pop ebx */ 2717 ebp = POP32_VAL(esp); /* 0x38001CEA: pop ebp */ 2718 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001CEB: ret 4 */ 2719 L_38001CEE: 2720 ecx = esi; /* 0x38001CEE: mov ecx, esi */ 2721 RECOMP_ICALL(0x38001D10u); /* 0x38001CF0: call 0x38001d10 */ /* not lifted */ 2722 RECOMP_FLAGS_IN(); 2723 /* test LO8(ebx), 1 */ /* 0x38001CF5: test bl, 1 */ 2724 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(1) << 24; 2725 _cf = 0; 2726 _flag_k = FK_NARROW(FK_TEST, 24); 2727 if (TEST_Z(_flag_a, _flag_b)) goto L_38001D03; /* 0x38001CF8: je 0x38001d03 */ 2728 L_38001CFA: 2729 PUSH32(esp, esi); /* 0x38001CFA: push esi */ 2730 RECOMP_ICALL(0x3804B4F6u); /* 0x38001CFB: call 0x3804b4f6 */ /* not lifted */ 2731 RECOMP_FLAGS_IN(); 2732 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 2733 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 2734 esp = esp + 4; /* 0x38001D00: add esp, 4 */ 2735 _flag_k = FK_ADD; 2736 L_38001D03: 2737 eax = esi; /* 0x38001D03: mov eax, esi */ 2738 esi = POP32_VAL(esp); /* 0x38001D05: pop esi */ 2739 ebx = POP32_VAL(esp); /* 0x38001D06: pop ebx */ 2740 ebp = POP32_VAL(esp); /* 0x38001D07: pop ebp */ 2741 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001D08: ret 4 */ 2742 RECOMP_REGS_OUT(); 2743 } 2744 2745 void sub_38001D10(void) { 2746 int _fpu_cmp = 0; 2747 uint32_t _cf = 0; 2748 int _df = 1; 2749 uint32_t _flag_k = FK_NONE; 2750 uint32_t _flag_a = 0, _flag_b = 0; 2751 uint32_t _itail_tgt = 0; 2752 RECOMP_REGS_LOCALS 2753 RECOMP_ENTER(0x38001D10u); 2754 2755 L_38001D10: 2756 MEM32(ecx) = 0x3804E82Cu; /* 0x38001D10: mov dword ptr [ecx], 0x3804e82c */ 2757 L_38001D16: 2758 MEM32(ecx + 0x20) = 0x3804E824u; /* 0x38001D16: mov dword ptr [ecx + 0x20], 0x3804e824 */ 2759 L_38001D1D: 2760 MEM32(ecx + 0x178) = 0; /* 0x38001D1D: mov dword ptr [ecx + 0x178], 0 */ 2761 L_38001D27: 2762 goto L_38014240; /* 0x38001D27: jmp 0x38014240 */ 2763 L_38014240: 2764 MEM32(ecx) = 0x3804EE28u; /* 0x38014240: mov dword ptr [ecx], 0x3804ee28 */ 2765 L_38014246: 2766 MEM32(ecx + 0x20) = 0x3804EE20u; /* 0x38014246: mov dword ptr [ecx + 0x20], 0x3804ee20 */ 2767 L_3801424D: 2768 MEM32(ecx + 0x130) = 0; /* 0x3801424D: mov dword ptr [ecx + 0x130], 0 */ 2769 L_38014257: 2770 { _itail_tgt = (uint32_t)(MEM32(0x3804E64C)); goto _ljump; } 2771 { RECOMP_REGS_OUT(); return; } /* end of function */ 2772 _ljump: 2773 switch (_itail_tgt) { 2774 case 0x38001D10u: goto L_38001D10; 2775 case 0x38001D16u: goto L_38001D16; 2776 case 0x38001D1Du: goto L_38001D1D; 2777 case 0x38001D27u: goto L_38001D27; 2778 case 0x38014240u: goto L_38014240; 2779 case 0x38014246u: goto L_38014246; 2780 case 0x3801424Du: goto L_3801424D; 2781 case 0x38014257u: goto L_38014257; 2782 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 2783 } 2784 RECOMP_REGS_OUT(); 2785 } 2786 2787 void sub_38001D30(void) { 2788 int _fpu_cmp = 0; 2789 uint32_t _cf = 0; 2790 int _df = 1; 2791 uint32_t _flag_k = FK_NONE; 2792 uint32_t _flag_a = 0, _flag_b = 0; 2793 uint32_t _itail_tgt = 0; 2794 RECOMP_REGS_LOCALS 2795 RECOMP_ENTER(0x38001D30u); 2796 2797 L_38001D30: 2798 PUSH32(esp, ebp); /* 0x38001D30: push ebp */ 2799 ebp = esp; /* 0x38001D31: mov ebp, esp */ 2800 eax = ecx; /* 0x38001D33: mov eax, ecx */ 2801 /* test eax, eax */ /* 0x38001D35: test eax, eax */ 2802 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 2803 _cf = 0; 2804 _flag_k = FK_TEST; 2805 ecx = MEM32(ebp + 0x8); /* 0x38001D37: mov ecx, dword ptr [ebp + 8] */ 2806 MEM32(eax + 0x158) = ecx; /* 0x38001D3A: mov dword ptr [eax + 0x158], ecx */ 2807 MEM8(eax + 0x1A9) = (uint8_t)(1); /* 0x38001D40: mov byte ptr [eax + 0x1a9], 1 */ 2808 if (TEST_Z(_flag_a, _flag_b)) goto L_38001D57; /* 0x38001D47: je 0x38001d57 */ 2809 L_38001D49: 2810 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x20u); 2811 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 2812 eax = eax + 0x20u; /* 0x38001D49: add eax, 0x20 */ 2813 _flag_k = FK_ADD; 2814 PUSH32(esp, eax); /* 0x38001D4C: push eax */ 2815 RECOMP_ICALL(MEM32(0x3804E708)); /* 0x38001D4D: call dword ptr [0x3804e708] */ 2816 RECOMP_FLAGS_IN(); 2817 ebp = POP32_VAL(esp); /* 0x38001D53: pop ebp */ 2818 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001D54: ret 4 */ 2819 L_38001D57: 2820 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 2821 eax = 0; /* 0x38001D57: xor eax, eax */ 2822 _cf = 0; 2823 _flag_k = FK_TEST; 2824 PUSH32(esp, eax); /* 0x38001D59: push eax */ 2825 RECOMP_ICALL(MEM32(0x3804E708)); /* 0x38001D5A: call dword ptr [0x3804e708] */ 2826 RECOMP_FLAGS_IN(); 2827 ebp = POP32_VAL(esp); /* 0x38001D60: pop ebp */ 2828 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001D61: ret 4 */ 2829 RECOMP_REGS_OUT(); 2830 } 2831 2832 void sub_38001D70(void) { 2833 int _fpu_cmp = 0; 2834 uint32_t _cf = 0; 2835 int _df = 1; 2836 uint32_t _flag_k = FK_NONE; 2837 uint32_t _flag_a = 0, _flag_b = 0; 2838 uint32_t _itail_tgt = 0; 2839 RECOMP_REGS_LOCALS 2840 RECOMP_ENTER(0x38001D70u); 2841 2842 L_38001D70: 2843 PUSH32(esp, ebp); /* 0x38001D70: push ebp */ 2844 ebp = esp; /* 0x38001D71: mov ebp, esp */ 2845 PUSH32(esp, ebx); /* 0x38001D73: push ebx */ 2846 PUSH32(esp, esi); /* 0x38001D74: push esi */ 2847 esi = ecx; /* 0x38001D75: mov esi, ecx */ 2848 ecx = MEM32(esi + 0x158); /* 0x38001D77: mov ecx, dword ptr [esi + 0x158] */ 2849 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 2850 ebx = 0; /* 0x38001D7D: xor ebx, ebx */ 2851 _cf = 0; 2852 _flag_k = FK_TEST; 2853 /* cmp ecx, ebx */ /* 0x38001D7F: cmp ecx, ebx */ 2854 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx); 2855 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2856 _flag_k = FK_CMP; 2857 if (CMP_EQ(_flag_a, _flag_b)) goto L_38001D9A; /* 0x38001D81: je 0x38001d9a */ 2858 L_38001D83: 2859 /* cmp MEM8(ebp + 0x8), LO8(ebx) */ /* 0x38001D83: cmp byte ptr [ebp + 8], bl */ 2860 _flag_a = (uint32_t)(MEM8(ebp + 0x8)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24; 2861 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2862 _flag_k = FK_NARROW(FK_CMP, 24); 2863 if (CMP_NE(_flag_a, _flag_b)) goto L_38001D9A; /* 0x38001D86: jne 0x38001d9a */ 2864 L_38001D88: 2865 /* cmp esi, ebx */ /* 0x38001D88: cmp esi, ebx */ 2866 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx); 2867 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2868 _flag_k = FK_CMP; 2869 if (CMP_EQ(_flag_a, _flag_b)) goto L_38001D91; /* 0x38001D8A: je 0x38001d91 */ 2870 L_38001D8C: 2871 eax = esi + 0x20; /* 0x38001D8C: lea eax, [esi + 0x20] */ 2872 goto L_38001D93; /* 0x38001D8F: jmp 0x38001d93 */ 2873 L_38001D91: 2874 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 2875 eax = 0; /* 0x38001D91: xor eax, eax */ 2876 _cf = 0; 2877 _flag_k = FK_TEST; 2878 L_38001D93: 2879 PUSH32(esp, eax); /* 0x38001D93: push eax */ 2880 RECOMP_ICALL(MEM32(0x3804E704)); /* 0x38001D94: call dword ptr [0x3804e704] */ 2881 RECOMP_FLAGS_IN(); 2882 L_38001D9A: 2883 MEM32(esi + 0x158) = ebx; /* 0x38001D9A: mov dword ptr [esi + 0x158], ebx */ 2884 MEM8(esi + 0x1A9) = (uint8_t)(LO8(ebx)); /* 0x38001DA0: mov byte ptr [esi + 0x1a9], bl */ 2885 esi = POP32_VAL(esp); /* 0x38001DA6: pop esi */ 2886 ebx = POP32_VAL(esp); /* 0x38001DA7: pop ebx */ 2887 ebp = POP32_VAL(esp); /* 0x38001DA8: pop ebp */ 2888 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001DA9: ret 4 */ 2889 RECOMP_REGS_OUT(); 2890 } 2891 2892 void sub_38001DB0(void) { 2893 int _fpu_cmp = 0; 2894 uint32_t _cf = 0; 2895 int _df = 1; 2896 uint32_t _flag_k = FK_NONE; 2897 uint32_t _flag_a = 0, _flag_b = 0; 2898 uint32_t _itail_tgt = 0; 2899 RECOMP_REGS_LOCALS 2900 RECOMP_ENTER(0x38001DB0u); 2901 2902 L_38001DB0: 2903 PUSH32(esp, ebp); /* 0x38001DB0: push ebp */ 2904 ebp = esp; /* 0x38001DB1: mov ebp, esp */ 2905 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x20u); 2906 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2907 esp = esp - 0x20u; /* 0x38001DB3: sub esp, 0x20 */ 2908 _flag_k = FK_CMP; 2909 PUSH32(esp, esi); /* 0x38001DB6: push esi */ 2910 esi = ecx; /* 0x38001DB7: mov esi, ecx */ 2911 eax = MEM32(esi); /* 0x38001DB9: mov eax, dword ptr [esi] */ 2912 PUSH32(esp, edi); /* 0x38001DBB: push edi */ 2913 RECOMP_ICALL(MEM32(eax + 0xC)); /* 0x38001DBC: call dword ptr [eax + 0xc] */ 2914 RECOMP_FLAGS_IN(); 2915 ecx = ebp + (-0x20); /* 0x38001DBF: lea ecx, [ebp - 0x20] */ 2916 PUSH32(esp, ecx); /* 0x38001DC2: push ecx */ 2917 ecx = esi; /* 0x38001DC3: mov ecx, esi */ 2918 edi = eax; /* 0x38001DC5: mov edi, eax */ 2919 RECOMP_ICALL(0x38001F50u); /* 0x38001DC7: call 0x38001f50 */ /* not lifted */ 2920 RECOMP_FLAGS_IN(); 2921 edx = MEM32(eax); /* 0x38001DCC: mov edx, dword ptr [eax] */ 2922 ecx = MEM32(eax + 0x4); /* 0x38001DCE: mov ecx, dword ptr [eax + 4] */ 2923 MEM32(ebp + (-0x14)) = edx; /* 0x38001DD1: mov dword ptr [ebp - 0x14], edx */ 2924 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38001DD4: fld dword ptr [ebp - 0x14] */ 2925 _st[0] -= (double)*(float*)ADDR(edi); /* 0x38001DD7: fsub dword ptr [edi] */ 2926 edx = MEM32(eax + 0x8); /* 0x38001DD9: mov edx, dword ptr [eax + 8] */ 2927 MEM32(ebp + (-0x10)) = ecx; /* 0x38001DDC: mov dword ptr [ebp - 0x10], ecx */ 2928 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38001DDF: fld dword ptr [ebp - 0x10] */ 2929 _st[0] -= (double)*(float*)ADDR(edi + 0x4); /* 0x38001DE2: fsub dword ptr [edi + 4] */ 2930 MEM32(ebp + (-0xC)) = edx; /* 0x38001DE5: mov dword ptr [ebp - 0xc], edx */ 2931 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x38001DE8: fld dword ptr [ebp - 0xc] */ 2932 _st[0] -= (double)*(float*)ADDR(edi + 0x8); /* 0x38001DEB: fsub dword ptr [edi + 8] */ 2933 fp_push(_st[0]); /* 0x38001DEE: fld st(0) */ 2934 _st[0] *= _st[1]; /* 0x38001DF0: fmul st(1) */ 2935 fp_push(_st[3]); /* 0x38001DF2: fld st(3) */ 2936 _st[0] *= _st[4]; /* 0x38001DF4: fmul st(4) */ 2937 { double _v = fp_pop(); _st[0] += _v; } /* 0x38001DF6: faddp st(1) */ 2938 fp_push(_st[2]); /* 0x38001DF8: fld st(2) */ 2939 _st[0] *= _st[3]; /* 0x38001DFA: fmul st(3) */ 2940 { double _v = fp_pop(); _st[0] += _v; } /* 0x38001DFC: faddp st(1) */ 2941 _st[0] = sqrt(_st[0]); /* 0x38001DFE: fsqrt */ 2942 { _st[3] = _st[0]; g_st_i64[3] = g_st_i64[0]; fp_pop(); } /* 0x38001E00: fstp st(3) */ 2943 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38001E02: fstp st(0) */ 2944 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38001E04: fstp st(0) */ 2945 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8D4)); /* 0x38001E06: fcom dword ptr [0x3804e8d4] */ 2946 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38001E0C: fnstsw ax */ 2947 /* test HI8(eax), 0x41u */ /* 0x38001E0E: test ah, 0x41 */ 2948 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 2949 _cf = 0; 2950 _flag_k = FK_NARROW(FK_TEST, 24); 2951 if (TEST_NZ(_flag_a, _flag_b)) goto L_38001E48; /* 0x38001E11: jne 0x38001e48 */ 2952 L_38001E13: 2953 _st[0] -= (double)*(float*)ADDR(0x3804E8D0); /* 0x38001E13: fsub dword ptr [0x3804e8d0] */ 2954 MEM32(ebp + (-0x8)) = 0x42A00000u; /* 0x38001E19: mov dword ptr [ebp - 8], 0x42a00000 */ 2955 _st[0] = sqrt(_st[0]); /* 0x38001E20: fsqrt */ 2956 _st[0] += (double)*(float*)ADDR(0x3804E8CC); /* 0x38001E22: fadd dword ptr [0x3804e8cc] */ 2957 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x38001E28: fmul dword ptr [ebp + 8] */ 2958 { float _v = (float)_st[0]; *(float*)ADDR(ebp + 0x8) = _v; } /* 0x38001E2B: fst dword ptr [ebp + 8] */ 2959 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8C8)); /* 0x38001E2E: fcomp dword ptr [0x3804e8c8] */ 2960 fp_pop(); 2961 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38001E34: fnstsw ax */ 2962 /* test HI8(eax), 1 */ /* 0x38001E36: test ah, 1 */ 2963 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 2964 _cf = 0; 2965 _flag_k = FK_NARROW(FK_TEST, 24); 2966 eax = ebp + 0x8; /* 0x38001E39: lea eax, [ebp + 8] */ 2967 if (TEST_NZ(_flag_a, _flag_b)) goto L_38001E41; /* 0x38001E3C: jne 0x38001e41 */ 2968 L_38001E3E: 2969 eax = ebp + (-0x8); /* 0x38001E3E: lea eax, [ebp - 8] */ 2970 L_38001E41: 2971 eax = MEM32(eax); /* 0x38001E41: mov eax, dword ptr [eax] */ 2972 MEM32(ebp + 0x8) = eax; /* 0x38001E43: mov dword ptr [ebp + 8], eax */ 2973 goto L_38001E4A; /* 0x38001E46: jmp 0x38001e4a */ 2974 L_38001E48: 2975 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38001E48: fstp st(0) */ 2976 L_38001E4A: 2977 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x38001E4A: fld dword ptr [ebp + 8] */ 2978 MEM32(ebp + (-0x8)) = 0x40000000u; /* 0x38001E4D: mov dword ptr [ebp - 8], 0x40000000 */ 2979 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8C4)); /* 0x38001E54: fcomp dword ptr [0x3804e8c4] */ 2980 fp_pop(); 2981 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38001E5A: fnstsw ax */ 2982 /* test HI8(eax), 0x41u */ /* 0x38001E5C: test ah, 0x41 */ 2983 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 2984 _cf = 0; 2985 _flag_k = FK_NARROW(FK_TEST, 24); 2986 eax = ebp + 0x8; /* 0x38001E5F: lea eax, [ebp + 8] */ 2987 if (TEST_Z(_flag_a, _flag_b)) goto L_38001E67; /* 0x38001E62: je 0x38001e67 */ 2988 L_38001E64: 2989 eax = ebp + (-0x8); /* 0x38001E64: lea eax, [ebp - 8] */ 2990 L_38001E67: 2991 ecx = MEM32(eax); /* 0x38001E67: mov ecx, dword ptr [eax] */ 2992 fp_push(*(float*)&MEM32(esi + 0x30)); /* 0x38001E69: fld dword ptr [esi + 0x30] */ 2993 MEM32(ebp + 0x8) = ecx; /* 0x38001E6C: mov dword ptr [ebp + 8], ecx */ 2994 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x38001E6F: fmul dword ptr [ebp + 8] */ 2995 edx = ecx; /* 0x38001E72: mov edx, ecx */ 2996 PUSH32(esp, edx); /* 0x38001E74: push edx */ 2997 { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x38001E75: fst dword ptr [ebp - 4] */ 2998 ecx = esi; /* 0x38001E78: mov ecx, esi */ 2999 _st[0] *= (double)*(float*)ADDR(0x3804E8C0); /* 0x38001E7A: fmul dword ptr [0x3804e8c0] */ 3000 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x38001E80: fstp dword ptr [ebp - 8] */ 3001 RECOMP_ICALL(MEM32(0x3804E6F8)); /* 0x38001E83: call dword ptr [0x3804e6f8] */ 3002 RECOMP_FLAGS_IN(); 3003 eax = MEM32(ebp + (-0x8)); /* 0x38001E89: mov eax, dword ptr [ebp - 8] */ 3004 PUSH32(esp, eax); /* 0x38001E8C: push eax */ 3005 ecx = esi; /* 0x38001E8D: mov ecx, esi */ 3006 RECOMP_ICALL(MEM32(0x3804E6FC)); /* 0x38001E8F: call dword ptr [0x3804e6fc] */ 3007 RECOMP_FLAGS_IN(); 3008 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x38001E95: fld dword ptr [ebp - 4] */ 3009 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x38001E98: fmul dword ptr [ebp + 8] */ 3010 PUSH32(esp, ecx); /* 0x38001E9B: push ecx */ 3011 ecx = esi; /* 0x38001E9C: mov ecx, esi */ 3012 _st[0] /= (double)*(float*)ADDR(ebp + (-0x8)); /* 0x38001E9E: fdiv dword ptr [ebp - 8] */ 3013 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38001EA1: fmul dword ptr [0x3804e8bc] */ 3014 _st[0] += _st[0]; /* 0x38001EA7: fadd st(0), st(0) */ 3015 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38001EA9: fstp dword ptr [esp] */ 3016 RECOMP_ICALL(MEM32(0x3804E700)); /* 0x38001EAC: call dword ptr [0x3804e700] */ 3017 RECOMP_FLAGS_IN(); 3018 edi = POP32_VAL(esp); /* 0x38001EB2: pop edi */ 3019 esi = POP32_VAL(esp); /* 0x38001EB3: pop esi */ 3020 esp = ebp; /* 0x38001EB4: mov esp, ebp */ 3021 ebp = POP32_VAL(esp); /* 0x38001EB6: pop ebp */ 3022 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001EB7: ret 4 */ 3023 RECOMP_REGS_OUT(); 3024 } 3025 3026 void sub_38001EC0(void) { 3027 int _fpu_cmp = 0; 3028 uint32_t _cf = 0; 3029 int _df = 1; 3030 uint32_t _flag_k = FK_NONE; 3031 uint32_t _flag_a = 0, _flag_b = 0; 3032 uint32_t _itail_tgt = 0; 3033 RECOMP_REGS_LOCALS 3034 RECOMP_ENTER(0x38001EC0u); 3035 3036 L_38001EC0: 3037 PUSH32(esp, ebp); /* 0x38001EC0: push ebp */ 3038 ebp = esp; /* 0x38001EC1: mov ebp, esp */ 3039 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x18u); 3040 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3041 esp = esp - 0x18u; /* 0x38001EC3: sub esp, 0x18 */ 3042 _flag_k = FK_CMP; 3043 edx = MEM32(ebp + 0x8); /* 0x38001EC6: mov edx, dword ptr [ebp + 8] */ 3044 PUSH32(esp, esi); /* 0x38001EC9: push esi */ 3045 esi = MEM32(edx); /* 0x38001ECA: mov esi, dword ptr [edx] */ 3046 eax = ecx + 0x15C; /* 0x38001ECC: lea eax, [ecx + 0x15c] */ 3047 MEM32(eax) = esi; /* 0x38001ED2: mov dword ptr [eax], esi */ 3048 esi = MEM32(edx + 0x4); /* 0x38001ED4: mov esi, dword ptr [edx + 4] */ 3049 MEM32(eax + 0x4) = esi; /* 0x38001ED7: mov dword ptr [eax + 4], esi */ 3050 edx = MEM32(edx + 0x8); /* 0x38001EDA: mov edx, dword ptr [edx + 8] */ 3051 MEM32(eax + 0x8) = edx; /* 0x38001EDD: mov dword ptr [eax + 8], edx */ 3052 eax = MEM32(0x3806B4C0); /* 0x38001EE0: mov eax, dword ptr [0x3806b4c0] */ 3053 /* test eax, eax */ /* 0x38001EE5: test eax, eax */ 3054 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 3055 _cf = 0; 3056 _flag_k = FK_TEST; 3057 esi = POP32_VAL(esp); /* 0x38001EE7: pop esi */ 3058 if (TEST_Z(_flag_a, _flag_b)) goto L_38001EF2; /* 0x38001EE8: je 0x38001ef2 */ 3059 L_38001EEA: 3060 fp_push(*(float*)&MEM32(0x3804E8DC)); /* 0x38001EEA: fld dword ptr [0x3804e8dc] */ 3061 goto L_38001EF8; /* 0x38001EF0: jmp 0x38001ef8 */ 3062 L_38001EF2: 3063 fp_push(*(float*)&MEM32(0x3804E8D8)); /* 0x38001EF2: fld dword ptr [0x3804e8d8] */ 3064 L_38001EF8: 3065 eax = ecx + 0x54; /* 0x38001EF8: lea eax, [ecx + 0x54] */ 3066 edx = MEM32(eax); /* 0x38001EFB: mov edx, dword ptr [eax] */ 3067 MEM32(ebp + (-0xC)) = edx; /* 0x38001EFD: mov dword ptr [ebp - 0xc], edx */ 3068 edx = MEM32(eax + 0x4); /* 0x38001F00: mov edx, dword ptr [eax + 4] */ 3069 eax = MEM32(eax + 0x8); /* 0x38001F03: mov eax, dword ptr [eax + 8] */ 3070 MEM32(ebp + (-0x8)) = edx; /* 0x38001F06: mov dword ptr [ebp - 8], edx */ 3071 _st[0] += (double)*(float*)ADDR(ebp + (-0x8)); /* 0x38001F09: fadd dword ptr [ebp - 8] */ 3072 edx = MEM32(ebp + (-0xC)); /* 0x38001F0C: mov edx, dword ptr [ebp - 0xc] */ 3073 MEM32(ebp + (-0x4)) = eax; /* 0x38001F0F: mov dword ptr [ebp - 4], eax */ 3074 MEM32(ebp + (-0x4)) = eax; /* 0x38001F12: mov dword ptr [ebp - 4], eax */ 3075 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x38001F15: fstp dword ptr [ebp - 8] */ 3076 eax = MEM32(ebp + (-0x8)); /* 0x38001F18: mov eax, dword ptr [ebp - 8] */ 3077 MEM32(ebp + (-0x14)) = eax; /* 0x38001F1B: mov dword ptr [ebp - 0x14], eax */ 3078 MEM32(ebp + (-0xC)) = edx; /* 0x38001F1E: mov dword ptr [ebp - 0xc], edx */ 3079 MEM32(ebp + (-0x18)) = edx; /* 0x38001F21: mov dword ptr [ebp - 0x18], edx */ 3080 edx = MEM32(ebp + (-0x4)); /* 0x38001F24: mov edx, dword ptr [ebp - 4] */ 3081 eax = ebp + (-0x18); /* 0x38001F27: lea eax, [ebp - 0x18] */ 3082 PUSH32(esp, eax); /* 0x38001F2A: push eax */ 3083 MEM32(ebp + (-0x10)) = edx; /* 0x38001F2B: mov dword ptr [ebp - 0x10], edx */ 3084 RECOMP_ICALL(MEM32(0x3804E6F4)); /* 0x38001F2E: call dword ptr [0x3804e6f4] */ 3085 RECOMP_FLAGS_IN(); 3086 eax = MEM32(0x3806B4C0); /* 0x38001F34: mov eax, dword ptr [0x3806b4c0] */ 3087 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 3088 ecx = 0; /* 0x38001F39: xor ecx, ecx */ 3089 _cf = 0; 3090 _flag_k = FK_TEST; 3091 /* test eax, eax */ /* 0x38001F3B: test eax, eax */ 3092 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 3093 _cf = 0; 3094 _flag_k = FK_TEST; 3095 SET_LO8(ecx, (TEST_Z(_flag_a, _flag_b)) ? 1 : 0); /* 0x38001F3D: sete cl */ 3096 MEM32(0x3806B4C0) = ecx; /* 0x38001F40: mov dword ptr [0x3806b4c0], ecx */ 3097 esp = ebp; /* 0x38001F46: mov esp, ebp */ 3098 ebp = POP32_VAL(esp); /* 0x38001F48: pop ebp */ 3099 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38001F49: ret 4 */ 3100 RECOMP_REGS_OUT(); 3101 } 3102 3103 void sub_38001F50(void) { 3104 int _fpu_cmp = 0; 3105 uint32_t _cf = 0; 3106 int _df = 1; 3107 uint32_t _flag_k = FK_NONE; 3108 uint32_t _flag_a = 0, _flag_b = 0; 3109 uint32_t _itail_tgt = 0; 3110 RECOMP_REGS_LOCALS 3111 RECOMP_ENTER(0x38001F50u); 3112 3113 L_38001F50: 3114 PUSH32(esp, ebp); /* 0x38001F50: push ebp */ 3115 ebp = esp; /* 0x38001F51: mov ebp, esp */ 3116 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x48u); 3117 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3118 esp = esp - 0x48u; /* 0x38001F53: sub esp, 0x48 */ 3119 _flag_k = FK_CMP; 3120 PUSH32(esp, esi); /* 0x38001F56: push esi */ 3121 esi = ecx; /* 0x38001F57: mov esi, ecx */ 3122 eax = esi + 0x15C; /* 0x38001F59: lea eax, [esi + 0x15c] */ 3123 ecx = MEM32(eax); /* 0x38001F5F: mov ecx, dword ptr [eax] */ 3124 edx = MEM32(eax + 0x4); /* 0x38001F61: mov edx, dword ptr [eax + 4] */ 3125 eax = MEM32(eax + 0x8); /* 0x38001F64: mov eax, dword ptr [eax + 8] */ 3126 MEM32(ebp + (-0xC)) = ecx; /* 0x38001F67: mov dword ptr [ebp - 0xc], ecx */ 3127 PUSH32(esp, edi); /* 0x38001F6A: push edi */ 3128 edi = esi + 0x148; /* 0x38001F6B: lea edi, [esi + 0x148] */ 3129 MEM32(ebp + (-0x8)) = edx; /* 0x38001F71: mov dword ptr [ebp - 8], edx */ 3130 ecx = edi; /* 0x38001F74: mov ecx, edi */ 3131 edx = MEM32(ecx); /* 0x38001F76: mov edx, dword ptr [ecx] */ 3132 MEM32(ebp + (-0x4)) = eax; /* 0x38001F78: mov dword ptr [ebp - 4], eax */ 3133 eax = MEM32(ecx + 0x4); /* 0x38001F7B: mov eax, dword ptr [ecx + 4] */ 3134 ecx = MEM32(ecx + 0x8); /* 0x38001F7E: mov ecx, dword ptr [ecx + 8] */ 3135 MEM32(ebp + (-0x3C)) = edx; /* 0x38001F81: mov dword ptr [ebp - 0x3c], edx */ 3136 edx = ebp + (-0xC); /* 0x38001F84: lea edx, [ebp - 0xc] */ 3137 MEM32(ebp + (-0x34)) = ecx; /* 0x38001F87: mov dword ptr [ebp - 0x34], ecx */ 3138 PUSH32(esp, edx); /* 0x38001F8A: push edx */ 3139 ecx = ebp + (-0x3C); /* 0x38001F8B: lea ecx, [ebp - 0x3c] */ 3140 MEM32(ebp + (-0x38)) = eax; /* 0x38001F8E: mov dword ptr [ebp - 0x38], eax */ 3141 RECOMP_ICALL(MEM32(0x3804E4C8)); /* 0x38001F91: call dword ptr [0x3804e4c8] */ 3142 RECOMP_FLAGS_IN(); 3143 ecx = MEM32(eax); /* 0x38001F97: mov ecx, dword ptr [eax] */ 3144 MEM32(ebp + (-0x18)) = ecx; /* 0x38001F99: mov dword ptr [ebp - 0x18], ecx */ 3145 edx = MEM32(eax + 0x4); /* 0x38001F9C: mov edx, dword ptr [eax + 4] */ 3146 MEM32(ebp + (-0x14)) = edx; /* 0x38001F9F: mov dword ptr [ebp - 0x14], edx */ 3147 eax = MEM32(eax + 0x8); /* 0x38001FA2: mov eax, dword ptr [eax + 8] */ 3148 ecx = edi; /* 0x38001FA5: mov ecx, edi */ 3149 edx = MEM32(ecx); /* 0x38001FA7: mov edx, dword ptr [ecx] */ 3150 MEM32(ebp + (-0x10)) = eax; /* 0x38001FA9: mov dword ptr [ebp - 0x10], eax */ 3151 eax = MEM32(ecx + 0x4); /* 0x38001FAC: mov eax, dword ptr [ecx + 4] */ 3152 ecx = MEM32(ecx + 0x8); /* 0x38001FAF: mov ecx, dword ptr [ecx + 8] */ 3153 MEM32(ebp + (-0x48)) = edx; /* 0x38001FB2: mov dword ptr [ebp - 0x48], edx */ 3154 edx = ebp + (-0x18); /* 0x38001FB5: lea edx, [ebp - 0x18] */ 3155 MEM32(ebp + (-0x40)) = ecx; /* 0x38001FB8: mov dword ptr [ebp - 0x40], ecx */ 3156 PUSH32(esp, edx); /* 0x38001FBB: push edx */ 3157 ecx = ebp + (-0x48); /* 0x38001FBC: lea ecx, [ebp - 0x48] */ 3158 MEM32(ebp + (-0x44)) = eax; /* 0x38001FBF: mov dword ptr [ebp - 0x44], eax */ 3159 RECOMP_ICALL(MEM32(0x3804E4C8)); /* 0x38001FC2: call dword ptr [0x3804e4c8] */ 3160 RECOMP_FLAGS_IN(); 3161 fp_push(*(float*)&MEM32(edi + 0xC)); /* 0x38001FC8: fld dword ptr [edi + 0xc] */ 3162 ecx = MEM32(eax); /* 0x38001FCB: mov ecx, dword ptr [eax] */ 3163 _st[0] += _st[0]; /* 0x38001FCD: fadd st(0), st(0) */ 3164 edx = MEM32(eax + 0x4); /* 0x38001FCF: mov edx, dword ptr [eax + 4] */ 3165 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x38001FD2: fld dword ptr [ebp - 0x18] */ 3166 eax = MEM32(eax + 0x8); /* 0x38001FD5: mov eax, dword ptr [eax + 8] */ 3167 _st[0] *= _st[1]; /* 0x38001FD8: fmul st(1) */ 3168 MEM32(ebp + (-0x24)) = ecx; /* 0x38001FDA: mov dword ptr [ebp - 0x24], ecx */ 3169 MEM32(ebp + (-0x20)) = edx; /* 0x38001FDD: mov dword ptr [ebp - 0x20], edx */ 3170 MEM32(ebp + (-0x1C)) = eax; /* 0x38001FE0: mov dword ptr [ebp - 0x1c], eax */ 3171 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x38001FE3: fstp dword ptr [ebp - 0x18] */ 3172 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38001FE6: fld dword ptr [ebp - 0x14] */ 3173 _st[0] *= _st[1]; /* 0x38001FE9: fmul st(1) */ 3174 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38001FEB: fstp dword ptr [ebp - 0x14] */ 3175 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38001FEE: fld dword ptr [ebp - 0x10] */ 3176 _st[0] *= _st[1]; /* 0x38001FF1: fmul st(1) */ 3177 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x38001FF3: fstp dword ptr [ebp - 0x10] */ 3178 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38001FF6: fstp st(0) */ 3179 fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x38001FF8: fld dword ptr [ebp - 0x24] */ 3180 _st[0] += _st[0]; /* 0x38001FFB: fadd st(0), st(0) */ 3181 fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x38001FFD: fld dword ptr [ebp - 0x20] */ 3182 _st[0] += _st[0]; /* 0x38002000: fadd st(0), st(0) */ 3183 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x38002002: fstp dword ptr [ebp - 0x20] */ 3184 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x38002005: fld dword ptr [ebp - 0x1c] */ 3185 _st[0] += _st[0]; /* 0x38002008: fadd st(0), st(0) */ 3186 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x3800200A: fstp dword ptr [ebp - 0x1c] */ 3187 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3800200D: fld dword ptr [ebp - 0xc] */ 3188 _st[0] += (double)*(float*)ADDR(ebp + (-0x18)); /* 0x38002010: fadd dword ptr [ebp - 0x18] */ 3189 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38002013: fld dword ptr [ebp - 0x14] */ 3190 _st[0] += (double)*(float*)ADDR(ebp + (-0x8)); /* 0x38002016: fadd dword ptr [ebp - 8] */ 3191 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x38002019: fstp dword ptr [ebp - 8] */ 3192 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x3800201C: fld dword ptr [ebp - 0x10] */ 3193 _st[0] += (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3800201F: fadd dword ptr [ebp - 4] */ 3194 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x38002022: fstp dword ptr [ebp - 4] */ 3195 _st[0] += _st[1]; /* 0x38002025: fadd st(1) */ 3196 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x38002027: fstp dword ptr [ebp - 0xc] */ 3197 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3800202A: fstp st(0) */ 3198 fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x3800202C: fld dword ptr [ebp - 0x20] */ 3199 _st[0] += (double)*(float*)ADDR(ebp + (-0x8)); /* 0x3800202F: fadd dword ptr [ebp - 8] */ 3200 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x38002032: fstp dword ptr [ebp - 8] */ 3201 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x38002035: fld dword ptr [ebp - 0x1c] */ 3202 _st[0] += (double)*(float*)ADDR(ebp + (-0x4)); /* 0x38002038: fadd dword ptr [ebp - 4] */ 3203 ecx = MEM32(ebp + (-0xC)); /* 0x3800203B: mov ecx, dword ptr [ebp - 0xc] */ 3204 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3800203E: fstp dword ptr [ebp - 4] */ 3205 edx = MEM32(ebp + (-0x8)); /* 0x38002041: mov edx, dword ptr [ebp - 8] */ 3206 eax = MEM32(ebp + (-0x4)); /* 0x38002044: mov eax, dword ptr [ebp - 4] */ 3207 MEM32(ebp + (-0x30)) = ecx; /* 0x38002047: mov dword ptr [ebp - 0x30], ecx */ 3208 ecx = esi; /* 0x3800204A: mov ecx, esi */ 3209 MEM32(ebp + (-0x2C)) = edx; /* 0x3800204C: mov dword ptr [ebp - 0x2c], edx */ 3210 MEM32(ebp + (-0x28)) = eax; /* 0x3800204F: mov dword ptr [ebp - 0x28], eax */ 3211 RECOMP_ICALL(0x38003C30u); /* 0x38002052: call 0x38003c30 */ /* not lifted */ 3212 RECOMP_FLAGS_IN(); 3213 fp_push(*(float*)&MEM32(ebp + (-0x30))); /* 0x38002057: fld dword ptr [ebp - 0x30] */ 3214 ecx = MEM32(eax); /* 0x3800205A: mov ecx, dword ptr [eax] */ 3215 edx = MEM32(eax + 0x4); /* 0x3800205C: mov edx, dword ptr [eax + 4] */ 3216 eax = MEM32(eax + 0x8); /* 0x3800205F: mov eax, dword ptr [eax + 8] */ 3217 MEM32(ebp + (-0x24)) = ecx; /* 0x38002062: mov dword ptr [ebp - 0x24], ecx */ 3218 _st[0] += (double)*(float*)ADDR(ebp + (-0x24)); /* 0x38002065: fadd dword ptr [ebp - 0x24] */ 3219 MEM32(ebp + (-0x20)) = edx; /* 0x38002068: mov dword ptr [ebp - 0x20], edx */ 3220 MEM32(ebp + (-0x1C)) = eax; /* 0x3800206B: mov dword ptr [ebp - 0x1c], eax */ 3221 eax = MEM32(ebp + 0x8); /* 0x3800206E: mov eax, dword ptr [ebp + 8] */ 3222 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x38002071: fstp dword ptr [ebp - 0x24] */ 3223 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x38002074: fld dword ptr [ebp - 0x2c] */ 3224 edx = MEM32(ebp + (-0x24)); /* 0x38002077: mov edx, dword ptr [ebp - 0x24] */ 3225 _st[0] += (double)*(float*)ADDR(ebp + (-0x20)); /* 0x3800207A: fadd dword ptr [ebp - 0x20] */ 3226 ecx = eax; /* 0x3800207D: mov ecx, eax */ 3227 MEM32(ecx) = edx; /* 0x3800207F: mov dword ptr [ecx], edx */ 3228 edi = POP32_VAL(esp); /* 0x38002081: pop edi */ 3229 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x38002082: fstp dword ptr [ebp - 0x20] */ 3230 edx = MEM32(ebp + (-0x20)); /* 0x38002085: mov edx, dword ptr [ebp - 0x20] */ 3231 fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x38002088: fld dword ptr [ebp - 0x28] */ 3232 MEM32(ecx + 0x4) = edx; /* 0x3800208B: mov dword ptr [ecx + 4], edx */ 3233 _st[0] += (double)*(float*)ADDR(ebp + (-0x1C)); /* 0x3800208E: fadd dword ptr [ebp - 0x1c] */ 3234 esi = POP32_VAL(esp); /* 0x38002091: pop esi */ 3235 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x38002092: fstp dword ptr [ebp - 0x1c] */ 3236 edx = MEM32(ebp + (-0x1C)); /* 0x38002095: mov edx, dword ptr [ebp - 0x1c] */ 3237 MEM32(ecx + 0x8) = edx; /* 0x38002098: mov dword ptr [ecx + 8], edx */ 3238 esp = ebp; /* 0x3800209B: mov esp, ebp */ 3239 ebp = POP32_VAL(esp); /* 0x3800209D: pop ebp */ 3240 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800209E: ret 4 */ 3241 RECOMP_REGS_OUT(); 3242 } 3243 3244 void sub_380020B0(void) { 3245 int _fpu_cmp = 0; 3246 uint32_t _cf = 0; 3247 int _df = 1; 3248 uint32_t _flag_k = FK_NONE; 3249 uint32_t _flag_a = 0, _flag_b = 0; 3250 uint32_t _itail_tgt = 0; 3251 RECOMP_REGS_LOCALS 3252 RECOMP_ENTER(0x380020B0u); 3253 3254 L_380020B0: 3255 PUSH32(esp, ebp); /* 0x380020B0: push ebp */ 3256 ebp = esp; /* 0x380020B1: mov ebp, esp */ 3257 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x18u); 3258 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3259 esp = esp - 0x18u; /* 0x380020B3: sub esp, 0x18 */ 3260 _flag_k = FK_CMP; 3261 eax = ecx + 0x168; /* 0x380020B6: lea eax, [ecx + 0x168] */ 3262 edx = ecx + 0x1AC; /* 0x380020BC: lea edx, [ecx + 0x1ac] */ 3263 PUSH32(esp, esi); /* 0x380020C2: push esi */ 3264 ecx = edx; /* 0x380020C3: mov ecx, edx */ 3265 esi = MEM32(ecx); /* 0x380020C5: mov esi, dword ptr [ecx] */ 3266 MEM32(ebp + (-0xC)) = esi; /* 0x380020C7: mov dword ptr [ebp - 0xc], esi */ 3267 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x380020CA: fld dword ptr [ebp - 0xc] */ 3268 _st[0] -= (double)*(float*)ADDR(eax); /* 0x380020CD: fsub dword ptr [eax] */ 3269 esi = MEM32(ecx + 0x4); /* 0x380020CF: mov esi, dword ptr [ecx + 4] */ 3270 ecx = MEM32(ecx + 0x8); /* 0x380020D2: mov ecx, dword ptr [ecx + 8] */ 3271 MEM32(ebp + (-0x8)) = esi; /* 0x380020D5: mov dword ptr [ebp - 8], esi */ 3272 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x380020D8: fstp dword ptr [ebp - 0xc] */ 3273 MEM32(ebp + (-0x4)) = ecx; /* 0x380020DB: mov dword ptr [ebp - 4], ecx */ 3274 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x380020DE: fld dword ptr [ebp - 8] */ 3275 ecx = MEM32(ebp + (-0xC)); /* 0x380020E1: mov ecx, dword ptr [ebp - 0xc] */ 3276 _st[0] -= (double)*(float*)ADDR(eax + 0x4); /* 0x380020E4: fsub dword ptr [eax + 4] */ 3277 MEM32(ebp + (-0x18)) = ecx; /* 0x380020E7: mov dword ptr [ebp - 0x18], ecx */ 3278 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x380020EA: fstp dword ptr [ebp - 8] */ 3279 ecx = MEM32(ebp + (-0x8)); /* 0x380020ED: mov ecx, dword ptr [ebp - 8] */ 3280 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x380020F0: fld dword ptr [ebp - 4] */ 3281 MEM32(ebp + (-0x14)) = ecx; /* 0x380020F3: mov dword ptr [ebp - 0x14], ecx */ 3282 _st[0] -= (double)*(float*)ADDR(eax + 0x8); /* 0x380020F6: fsub dword ptr [eax + 8] */ 3283 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x380020F9: fstp dword ptr [ebp - 4] */ 3284 ecx = MEM32(ebp + (-0x4)); /* 0x380020FC: mov ecx, dword ptr [ebp - 4] */ 3285 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x380020FF: fld dword ptr [ebp - 0xc] */ 3286 MEM32(ebp + (-0x10)) = ecx; /* 0x38002102: mov dword ptr [ebp - 0x10], ecx */ 3287 ecx = MEM32(ebp + 0x8); /* 0x38002105: mov ecx, dword ptr [ebp + 8] */ 3288 _st[0] += (double)*(float*)ADDR(ecx); /* 0x38002108: fadd dword ptr [ecx] */ 3289 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x3800210A: fstp dword ptr [ebp - 0x18] */ 3290 esi = MEM32(ebp + (-0x18)); /* 0x3800210D: mov esi, dword ptr [ebp - 0x18] */ 3291 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38002110: fld dword ptr [ebp - 0x14] */ 3292 _st[0] += (double)*(float*)ADDR(ecx + 0x4); /* 0x38002113: fadd dword ptr [ecx + 4] */ 3293 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002116: fstp dword ptr [ebp - 0x14] */ 3294 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38002119: fld dword ptr [ebp - 0x10] */ 3295 _st[0] += (double)*(float*)ADDR(ecx + 0x8); /* 0x3800211C: fadd dword ptr [ecx + 8] */ 3296 MEM32(edx) = esi; /* 0x3800211F: mov dword ptr [edx], esi */ 3297 esi = MEM32(ebp + (-0x14)); /* 0x38002121: mov esi, dword ptr [ebp - 0x14] */ 3298 MEM32(edx + 0x4) = esi; /* 0x38002124: mov dword ptr [edx + 4], esi */ 3299 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x38002127: fstp dword ptr [ebp - 0x10] */ 3300 esi = MEM32(ebp + (-0x10)); /* 0x3800212A: mov esi, dword ptr [ebp - 0x10] */ 3301 MEM32(edx + 0x8) = esi; /* 0x3800212D: mov dword ptr [edx + 8], esi */ 3302 edx = MEM32(ecx); /* 0x38002130: mov edx, dword ptr [ecx] */ 3303 MEM32(eax) = edx; /* 0x38002132: mov dword ptr [eax], edx */ 3304 edx = MEM32(ecx + 0x4); /* 0x38002134: mov edx, dword ptr [ecx + 4] */ 3305 MEM32(eax + 0x4) = edx; /* 0x38002137: mov dword ptr [eax + 4], edx */ 3306 ecx = MEM32(ecx + 0x8); /* 0x3800213A: mov ecx, dword ptr [ecx + 8] */ 3307 MEM32(eax + 0x8) = ecx; /* 0x3800213D: mov dword ptr [eax + 8], ecx */ 3308 esi = POP32_VAL(esp); /* 0x38002140: pop esi */ 3309 esp = ebp; /* 0x38002141: mov esp, ebp */ 3310 ebp = POP32_VAL(esp); /* 0x38002143: pop ebp */ 3311 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38002144: ret 4 */ 3312 RECOMP_REGS_OUT(); 3313 } 3314 3315 void sub_38002150(void) { 3316 int _fpu_cmp = 0; 3317 uint32_t _cf = 0; 3318 int _df = 1; 3319 uint32_t _flag_k = FK_NONE; 3320 uint32_t _flag_a = 0, _flag_b = 0; 3321 uint32_t _itail_tgt = 0; 3322 RECOMP_REGS_LOCALS 3323 RECOMP_ENTER(0x38002150u); 3324 3325 L_38002150: 3326 PUSH32(esp, ebp); /* 0x38002150: push ebp */ 3327 ebp = esp; /* 0x38002151: mov ebp, esp */ 3328 eax = MEM32(ebp + 0xC); /* 0x38002153: mov eax, dword ptr [ebp + 0xc] */ 3329 edx = MEM32(ebp + 0x8); /* 0x38002156: mov edx, dword ptr [ebp + 8] */ 3330 ecx = MEM32(ecx + 0x178); /* 0x38002159: mov ecx, dword ptr [ecx + 0x178] */ 3331 PUSH32(esp, eax); /* 0x3800215F: push eax */ 3332 PUSH32(esp, edx); /* 0x38002160: push edx */ 3333 RECOMP_ICALL(0x38007410u); /* 0x38002161: call 0x38007410 */ /* not lifted */ 3334 RECOMP_FLAGS_IN(); 3335 ebp = POP32_VAL(esp); /* 0x38002166: pop ebp */ 3336 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x38002167: ret 8 */ 3337 RECOMP_REGS_OUT(); 3338 } 3339 3340 void sub_38002170(void) { 3341 int _fpu_cmp = 0; 3342 uint32_t _cf = 0; 3343 int _df = 1; 3344 uint32_t _flag_k = FK_NONE; 3345 uint32_t _flag_a = 0, _flag_b = 0; 3346 uint32_t _itail_tgt = 0; 3347 RECOMP_REGS_LOCALS 3348 RECOMP_ENTER(0x38002170u); 3349 3350 L_38002170: 3351 PUSH32(esp, ebp); /* 0x38002170: push ebp */ 3352 ebp = esp; /* 0x38002171: mov ebp, esp */ 3353 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x30u); 3354 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3355 esp = esp - 0x30u; /* 0x38002173: sub esp, 0x30 */ 3356 _flag_k = FK_CMP; 3357 eax = MEM32(ebp + 0xC); /* 0x38002176: mov eax, dword ptr [ebp + 0xc] */ 3358 PUSH32(esp, ebx); /* 0x38002179: push ebx */ 3359 PUSH32(esp, esi); /* 0x3800217A: push esi */ 3360 esi = ecx; /* 0x3800217B: mov esi, ecx */ 3361 ecx = eax; /* 0x3800217D: mov ecx, eax */ 3362 edx = MEM32(ecx); /* 0x3800217F: mov edx, dword ptr [ecx] */ 3363 MEM32(ebp + (-0x18)) = edx; /* 0x38002181: mov dword ptr [ebp - 0x18], edx */ 3364 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x38002184: fld dword ptr [ebp - 0x18] */ 3365 _st[0] *= (double)*(float*)ADDR(ebp + 0x10); /* 0x38002187: fmul dword ptr [ebp + 0x10] */ 3366 edx = MEM32(ecx + 0x4); /* 0x3800218A: mov edx, dword ptr [ecx + 4] */ 3367 ecx = MEM32(ecx + 0x8); /* 0x3800218D: mov ecx, dword ptr [ecx + 8] */ 3368 MEM32(ebp + (-0x14)) = edx; /* 0x38002190: mov dword ptr [ebp - 0x14], edx */ 3369 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38002193: fld dword ptr [ebp - 0x14] */ 3370 _st[0] *= (double)*(float*)ADDR(ebp + 0x10); /* 0x38002196: fmul dword ptr [ebp + 0x10] */ 3371 MEM32(ebp + (-0x10)) = ecx; /* 0x38002199: mov dword ptr [ebp - 0x10], ecx */ 3372 PUSH32(esp, edi); /* 0x3800219C: push edi */ 3373 edi = esi + 0x54; /* 0x3800219D: lea edi, [esi + 0x54] */ 3374 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x380021A0: fstp dword ptr [ebp - 0x14] */ 3375 edx = edi; /* 0x380021A3: mov edx, edi */ 3376 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x380021A5: fld dword ptr [ebp - 0x10] */ 3377 ecx = MEM32(edx); /* 0x380021A8: mov ecx, dword ptr [edx] */ 3378 _st[0] *= (double)*(float*)ADDR(ebp + 0x10); /* 0x380021AA: fmul dword ptr [ebp + 0x10] */ 3379 MEM32(ebp + (-0xC)) = ecx; /* 0x380021AD: mov dword ptr [ebp - 0xc], ecx */ 3380 ecx = MEM32(edx + 0x4); /* 0x380021B0: mov ecx, dword ptr [edx + 4] */ 3381 edx = MEM32(edx + 0x8); /* 0x380021B3: mov edx, dword ptr [edx + 8] */ 3382 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x380021B6: fstp dword ptr [ebp - 0x10] */ 3383 MEM32(ebp + (-0x8)) = ecx; /* 0x380021B9: mov dword ptr [ebp - 8], ecx */ 3384 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x380021BC: fld dword ptr [ebp - 0xc] */ 3385 MEM32(ebp + (-0x4)) = edx; /* 0x380021BF: mov dword ptr [ebp - 4], edx */ 3386 _st[0] += _st[1]; /* 0x380021C2: fadd st(1) */ 3387 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x380021C4: fstp dword ptr [ebp - 0xc] */ 3388 ecx = MEM32(ebp + (-0xC)); /* 0x380021C7: mov ecx, dword ptr [ebp - 0xc] */ 3389 MEM32(ebp + (-0x18)) = ecx; /* 0x380021CA: mov dword ptr [ebp - 0x18], ecx */ 3390 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x380021CD: fstp st(0) */ 3391 MEM32(ebp + (-0x30)) = ecx; /* 0x380021CF: mov dword ptr [ebp - 0x30], ecx */ 3392 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x380021D2: fld dword ptr [ebp - 8] */ 3393 _st[0] += (double)*(float*)ADDR(ebp + (-0x14)); /* 0x380021D5: fadd dword ptr [ebp - 0x14] */ 3394 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x380021D8: fstp dword ptr [ebp - 8] */ 3395 edx = MEM32(ebp + (-0x8)); /* 0x380021DB: mov edx, dword ptr [ebp - 8] */ 3396 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x380021DE: fld dword ptr [ebp - 4] */ 3397 MEM32(ebp + (-0x14)) = edx; /* 0x380021E1: mov dword ptr [ebp - 0x14], edx */ 3398 _st[0] += (double)*(float*)ADDR(ebp + (-0x10)); /* 0x380021E4: fadd dword ptr [ebp - 0x10] */ 3399 MEM32(ebp + (-0x2C)) = edx; /* 0x380021E7: mov dword ptr [ebp - 0x2c], edx */ 3400 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x380021EA: fstp dword ptr [ebp - 4] */ 3401 ebx = MEM32(ebp + (-0x4)); /* 0x380021ED: mov ebx, dword ptr [ebp - 4] */ 3402 MEM32(ebp + (-0x28)) = ebx; /* 0x380021F0: mov dword ptr [ebp - 0x28], ebx */ 3403 ebx = MEM32(eax); /* 0x380021F3: mov ebx, dword ptr [eax] */ 3404 MEM32(ebp + (-0x24)) = ebx; /* 0x380021F5: mov dword ptr [ebp - 0x24], ebx */ 3405 fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x380021F8: fld dword ptr [ebp - 0x24] */ 3406 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x380021FB: fmul dword ptr [0x3804e8bc] */ 3407 ebx = MEM32(eax + 0x4); /* 0x38002201: mov ebx, dword ptr [eax + 4] */ 3408 eax = MEM32(eax + 0x8); /* 0x38002204: mov eax, dword ptr [eax + 8] */ 3409 ecx = MEM32(ebp + (-0x4)); /* 0x38002207: mov ecx, dword ptr [ebp - 4] */ 3410 MEM32(ebp + (-0x20)) = ebx; /* 0x3800220A: mov dword ptr [ebp - 0x20], ebx */ 3411 fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x3800220D: fld dword ptr [ebp - 0x20] */ 3412 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002210: fmul dword ptr [0x3804e8bc] */ 3413 MEM32(ebp + (-0x1C)) = eax; /* 0x38002216: mov dword ptr [ebp - 0x1c], eax */ 3414 MEM32(ebp + (-0x10)) = ecx; /* 0x38002219: mov dword ptr [ebp - 0x10], ecx */ 3415 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x3800221C: fstp dword ptr [ebp - 0x20] */ 3416 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x3800221F: fld dword ptr [ebp - 0x1c] */ 3417 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002222: fmul dword ptr [0x3804e8bc] */ 3418 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x38002228: fstp dword ptr [ebp - 0x1c] */ 3419 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3800222B: fld dword ptr [ebp - 0xc] */ 3420 _st[0] -= _st[1]; /* 0x3800222E: fsub st(1) */ 3421 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x38002230: fstp dword ptr [ebp - 0x18] */ 3422 edx = MEM32(ebp + (-0x18)); /* 0x38002233: mov edx, dword ptr [ebp - 0x18] */ 3423 MEM32(ebp + (-0x24)) = edx; /* 0x38002236: mov dword ptr [ebp - 0x24], edx */ 3424 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38002239: fstp st(0) */ 3425 edx = ebp + (-0x18); /* 0x3800223B: lea edx, [ebp - 0x18] */ 3426 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x3800223E: fld dword ptr [ebp - 0x14] */ 3427 PUSH32(esp, edx); /* 0x38002241: push edx */ 3428 _st[0] -= (double)*(float*)ADDR(ebp + (-0x20)); /* 0x38002242: fsub dword ptr [ebp - 0x20] */ 3429 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002245: fstp dword ptr [ebp - 0x14] */ 3430 eax = MEM32(ebp + (-0x14)); /* 0x38002248: mov eax, dword ptr [ebp - 0x14] */ 3431 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x3800224B: fld dword ptr [ebp - 0x10] */ 3432 MEM32(ebp + (-0x20)) = eax; /* 0x3800224E: mov dword ptr [ebp - 0x20], eax */ 3433 _st[0] -= (double)*(float*)ADDR(ebp + (-0x1C)); /* 0x38002251: fsub dword ptr [ebp - 0x1c] */ 3434 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x38002254: fstp dword ptr [ebp - 0x10] */ 3435 ecx = MEM32(ebp + (-0x10)); /* 0x38002257: mov ecx, dword ptr [ebp - 0x10] */ 3436 MEM32(ebp + (-0x1C)) = ecx; /* 0x3800225A: mov dword ptr [ebp - 0x1c], ecx */ 3437 ecx = esi; /* 0x3800225D: mov ecx, esi */ 3438 RECOMP_ICALL(0x38001F50u); /* 0x3800225F: call 0x38001f50 */ /* not lifted */ 3439 RECOMP_FLAGS_IN(); 3440 PUSH32(esp, eax); /* 0x38002264: push eax */ 3441 eax = ebp + (-0x24); /* 0x38002265: lea eax, [ebp - 0x24] */ 3442 PUSH32(esp, eax); /* 0x38002268: push eax */ 3443 ecx = esi; /* 0x38002269: mov ecx, esi */ 3444 RECOMP_ICALL(0x38002150u); /* 0x3800226B: call 0x38002150 */ /* not lifted */ 3445 RECOMP_FLAGS_IN(); 3446 /* test LO8(eax), LO8(eax) */ /* 0x38002270: test al, al */ 3447 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 3448 _cf = 0; 3449 _flag_k = FK_NARROW(FK_TEST, 24); 3450 if (TEST_Z(_flag_a, _flag_b)) goto L_3800228F; /* 0x38002272: je 0x3800228f */ 3451 L_38002274: 3452 ecx = ebp + (-0x30); /* 0x38002274: lea ecx, [ebp - 0x30] */ 3453 PUSH32(esp, ecx); /* 0x38002277: push ecx */ 3454 PUSH32(esp, edi); /* 0x38002278: push edi */ 3455 ecx = esi; /* 0x38002279: mov ecx, esi */ 3456 RECOMP_ICALL(0x38002150u); /* 0x3800227B: call 0x38002150 */ /* not lifted */ 3457 RECOMP_FLAGS_IN(); 3458 /* test LO8(eax), LO8(eax) */ /* 0x38002280: test al, al */ 3459 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 3460 _cf = 0; 3461 _flag_k = FK_NARROW(FK_TEST, 24); 3462 if (TEST_Z(_flag_a, _flag_b)) goto L_3800228F; /* 0x38002282: je 0x3800228f */ 3463 L_38002284: 3464 edi = POP32_VAL(esp); /* 0x38002284: pop edi */ 3465 esi = POP32_VAL(esp); /* 0x38002285: pop esi */ 3466 SET_LO8(eax, 1); /* 0x38002286: mov al, 1 */ 3467 ebx = POP32_VAL(esp); /* 0x38002288: pop ebx */ 3468 esp = ebp; /* 0x38002289: mov esp, ebp */ 3469 ebp = POP32_VAL(esp); /* 0x3800228B: pop ebp */ 3470 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3800228C: ret 0xc */ 3471 L_3800228F: 3472 edi = POP32_VAL(esp); /* 0x3800228F: pop edi */ 3473 esi = POP32_VAL(esp); /* 0x38002290: pop esi */ 3474 _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24; 3475 SET_LO8(eax, 0); /* 0x38002291: xor al, al */ 3476 _cf = 0; 3477 _flag_k = FK_NARROW(FK_TEST, 24); 3478 ebx = POP32_VAL(esp); /* 0x38002293: pop ebx */ 3479 esp = ebp; /* 0x38002294: mov esp, ebp */ 3480 ebp = POP32_VAL(esp); /* 0x38002296: pop ebp */ 3481 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x38002297: ret 0xc */ 3482 RECOMP_REGS_OUT(); 3483 } 3484 3485 void sub_380022A0(void) { 3486 int _fpu_cmp = 0; 3487 uint32_t _cf = 0; 3488 int _df = 1; 3489 uint32_t _flag_k = FK_NONE; 3490 uint32_t _flag_a = 0, _flag_b = 0; 3491 uint32_t _itail_tgt = 0; 3492 RECOMP_REGS_LOCALS 3493 RECOMP_ENTER(0x380022A0u); 3494 3495 L_380022A0: 3496 PUSH32(esp, ebp); /* 0x380022A0: push ebp */ 3497 ebp = esp; /* 0x380022A1: mov ebp, esp */ 3498 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x18u); 3499 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3500 esp = esp - 0x18u; /* 0x380022A3: sub esp, 0x18 */ 3501 _flag_k = FK_CMP; 3502 SET_LO8(eax, MEM8(0x3806E99C)); /* 0x380022A6: mov al, byte ptr [0x3806e99c] */ 3503 /* test LO8(eax), 1 */ /* 0x380022AB: test al, 1 */ 3504 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 3505 _cf = 0; 3506 _flag_k = FK_NARROW(FK_TEST, 24); 3507 PUSH32(esp, esi); /* 0x380022AD: push esi */ 3508 esi = ecx; /* 0x380022AE: mov esi, ecx */ 3509 if (TEST_NZ(_flag_a, _flag_b)) goto L_380022E8; /* 0x380022B0: jne 0x380022e8 */ 3510 L_380022B2: 3511 SET_LO8(edx, LO8(eax)); /* 0x380022B2: mov dl, al */ 3512 _flag_a = (uint32_t)((LO8(edx) | 1)) << 24; _flag_b = (uint32_t)((LO8(edx) | 1)) << 24; 3513 SET_LO8(edx, LO8(edx) | 1); /* 0x380022B4: or dl, 1 */ 3514 _cf = 0; 3515 _flag_k = FK_NARROW(FK_TEST, 24); 3516 PUSH32(esp, 0x38002360u); /* 0x380022B7: push 0x38002360 */ 3517 MEM8(0x3806E99C) = (uint8_t)(LO8(edx)); /* 0x380022BC: mov byte ptr [0x3806e99c], dl */ 3518 MEM32(0x3806E990) = 0; /* 0x380022C2: mov dword ptr [0x3806e990], 0 */ 3519 MEM32(0x3806E994) = 0; /* 0x380022CC: mov dword ptr [0x3806e994], 0 */ 3520 MEM32(0x3806E998) = 0; /* 0x380022D6: mov dword ptr [0x3806e998], 0 */ 3521 RECOMP_ICALL(0x3804B54Cu); /* 0x380022E0: call 0x3804b54c */ /* not lifted */ 3522 RECOMP_FLAGS_IN(); 3523 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 3524 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3525 esp = esp + 4; /* 0x380022E5: add esp, 4 */ 3526 _flag_k = FK_ADD; 3527 L_380022E8: 3528 eax = ebp + (-0x18); /* 0x380022E8: lea eax, [ebp - 0x18] */ 3529 PUSH32(esp, eax); /* 0x380022EB: push eax */ 3530 ecx = esi; /* 0x380022EC: mov ecx, esi */ 3531 RECOMP_ICALL(0x38001F50u); /* 0x380022EE: call 0x38001f50 */ /* not lifted */ 3532 RECOMP_FLAGS_IN(); 3533 ecx = MEM32(eax); /* 0x380022F3: mov ecx, dword ptr [eax] */ 3534 MEM32(ebp + (-0xC)) = ecx; /* 0x380022F5: mov dword ptr [ebp - 0xc], ecx */ 3535 edx = MEM32(eax + 0x4); /* 0x380022F8: mov edx, dword ptr [eax + 4] */ 3536 MEM32(ebp + (-0x8)) = edx; /* 0x380022FB: mov dword ptr [ebp - 8], edx */ 3537 eax = MEM32(eax + 0x8); /* 0x380022FE: mov eax, dword ptr [eax + 8] */ 3538 ecx = ebp + (-0xC); /* 0x38002301: lea ecx, [ebp - 0xc] */ 3539 PUSH32(esp, ecx); /* 0x38002304: push ecx */ 3540 edx = esi + 0x54; /* 0x38002305: lea edx, [esi + 0x54] */ 3541 PUSH32(esp, edx); /* 0x38002308: push edx */ 3542 ecx = esi; /* 0x38002309: mov ecx, esi */ 3543 MEM32(ebp + (-0x4)) = eax; /* 0x3800230B: mov dword ptr [ebp - 4], eax */ 3544 RECOMP_ICALL(0x38002150u); /* 0x3800230E: call 0x38002150 */ /* not lifted */ 3545 RECOMP_FLAGS_IN(); 3546 /* test LO8(eax), LO8(eax) */ /* 0x38002313: test al, al */ 3547 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 3548 _cf = 0; 3549 _flag_k = FK_NARROW(FK_TEST, 24); 3550 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002336; /* 0x38002315: jne 0x38002336 */ 3551 L_38002317: 3552 ecx = esi; /* 0x38002317: mov ecx, esi */ 3553 MEM8(esi + 0x198) = (uint8_t)(LO8(eax)); /* 0x38002319: mov byte ptr [esi + 0x198], al */ 3554 RECOMP_ICALL(0x38002370u); /* 0x3800231F: call 0x38002370 */ /* not lifted */ 3555 RECOMP_FLAGS_IN(); 3556 SET_LO8(ecx, MEM8(esi + 0x198)); /* 0x38002324: mov cl, byte ptr [esi + 0x198] */ 3557 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 3558 eax = 0; /* 0x3800232A: xor eax, eax */ 3559 _cf = 0; 3560 _flag_k = FK_TEST; 3561 /* test LO8(ecx), LO8(ecx) */ /* 0x3800232C: test cl, cl */ 3562 _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24; 3563 _cf = 0; 3564 _flag_k = FK_NARROW(FK_TEST, 24); 3565 SET_LO8(eax, (TEST_Z(_flag_a, _flag_b)) ? 1 : 0); /* 0x3800232E: sete al */ 3566 esi = POP32_VAL(esp); /* 0x38002331: pop esi */ 3567 esp = ebp; /* 0x38002332: mov esp, ebp */ 3568 ebp = POP32_VAL(esp); /* 0x38002334: pop ebp */ 3569 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38002335: ret */ 3570 L_38002336: 3571 MEM8(esi + 0x198) = (uint8_t)(1); /* 0x38002336: mov byte ptr [esi + 0x198], 1 */ 3572 SET_LO8(ecx, MEM8(esi + 0x198)); /* 0x3800233D: mov cl, byte ptr [esi + 0x198] */ 3573 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 3574 eax = 0; /* 0x38002343: xor eax, eax */ 3575 _cf = 0; 3576 _flag_k = FK_TEST; 3577 /* test LO8(ecx), LO8(ecx) */ /* 0x38002345: test cl, cl */ 3578 _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24; 3579 _cf = 0; 3580 _flag_k = FK_NARROW(FK_TEST, 24); 3581 MEM8(esi + 0x1C5) = (uint8_t)(0); /* 0x38002347: mov byte ptr [esi + 0x1c5], 0 */ 3582 SET_LO8(eax, (TEST_Z(_flag_a, _flag_b)) ? 1 : 0); /* 0x3800234E: sete al */ 3583 esi = POP32_VAL(esp); /* 0x38002351: pop esi */ 3584 esp = ebp; /* 0x38002352: mov esp, ebp */ 3585 ebp = POP32_VAL(esp); /* 0x38002354: pop ebp */ 3586 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38002355: ret */ 3587 RECOMP_REGS_OUT(); 3588 } 3589 3590 void sub_38002360(void) { 3591 int _fpu_cmp = 0; 3592 uint32_t _cf = 0; 3593 int _df = 1; 3594 uint32_t _flag_k = FK_NONE; 3595 uint32_t _flag_a = 0, _flag_b = 0; 3596 uint32_t _itail_tgt = 0; 3597 RECOMP_REGS_LOCALS 3598 RECOMP_ENTER(0x38002360u); 3599 3600 L_38002360: 3601 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38002360: ret */ 3602 RECOMP_REGS_OUT(); 3603 } 3604 3605 void sub_38002370(void) { 3606 int _fpu_cmp = 0; 3607 uint32_t _cf = 0; 3608 int _df = 1; 3609 uint32_t _flag_k = FK_NONE; 3610 uint32_t _flag_a = 0, _flag_b = 0; 3611 uint32_t _itail_tgt = 0; 3612 RECOMP_REGS_LOCALS 3613 RECOMP_ENTER(0x38002370u); 3614 3615 L_38002370: 3616 PUSH32(esp, ebp); /* 0x38002370: push ebp */ 3617 ebp = esp; /* 0x38002371: mov ebp, esp */ 3618 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xA4u); 3619 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3620 esp = esp - 0xA4u; /* 0x38002373: sub esp, 0xa4 */ 3621 _flag_k = FK_CMP; 3622 PUSH32(esp, ebx); /* 0x38002379: push ebx */ 3623 PUSH32(esp, esi); /* 0x3800237A: push esi */ 3624 esi = ecx; /* 0x3800237B: mov esi, ecx */ 3625 PUSH32(esp, edi); /* 0x3800237D: push edi */ 3626 edi = esi + 0x19C; /* 0x3800237E: lea edi, [esi + 0x19c] */ 3627 MEM32(ebp + (-0xC)) = 0; /* 0x38002384: mov dword ptr [ebp - 0xc], 0 */ 3628 ecx = MEM32(ebp + (-0xC)); /* 0x3800238B: mov ecx, dword ptr [ebp - 0xc] */ 3629 eax = edi; /* 0x3800238E: mov eax, edi */ 3630 MEM32(eax) = ecx; /* 0x38002390: mov dword ptr [eax], ecx */ 3631 MEM32(ebp + (-0x8)) = 0; /* 0x38002392: mov dword ptr [ebp - 8], 0 */ 3632 edx = MEM32(ebp + (-0x8)); /* 0x38002399: mov edx, dword ptr [ebp - 8] */ 3633 MEM32(eax + 0x4) = edx; /* 0x3800239C: mov dword ptr [eax + 4], edx */ 3634 MEM32(ebp + (-0x4)) = 0; /* 0x3800239F: mov dword ptr [ebp - 4], 0 */ 3635 ecx = MEM32(ebp + (-0x4)); /* 0x380023A6: mov ecx, dword ptr [ebp - 4] */ 3636 edx = ebp + (-0x74); /* 0x380023A9: lea edx, [ebp - 0x74] */ 3637 MEM32(eax + 0x8) = ecx; /* 0x380023AC: mov dword ptr [eax + 8], ecx */ 3638 PUSH32(esp, edx); /* 0x380023AF: push edx */ 3639 ecx = esi; /* 0x380023B0: mov ecx, esi */ 3640 MEM8(esi + 0x1C5) = (uint8_t)(0); /* 0x380023B2: mov byte ptr [esi + 0x1c5], 0 */ 3641 RECOMP_ICALL(0x38001F50u); /* 0x380023B9: call 0x38001f50 */ /* not lifted */ 3642 RECOMP_FLAGS_IN(); 3643 ebx = MEM32(0x3804E6F0); /* 0x380023BE: mov ebx, dword ptr [0x3804e6f0] */ 3644 ecx = esi; /* 0x380023C4: mov ecx, esi */ 3645 MEM32(ebp + (-0x1C)) = 0; /* 0x380023C6: mov dword ptr [ebp - 0x1c], 0 */ 3646 MEM32(ebp + (-0x18)) = 0x3F800000u; /* 0x380023CD: mov dword ptr [ebp - 0x18], 0x3f800000 */ 3647 MEM32(ebp + (-0x14)) = 0; /* 0x380023D4: mov dword ptr [ebp - 0x14], 0 */ 3648 MEM32(ebp + (-0xC)) = 0x3F800000u; /* 0x380023DB: mov dword ptr [ebp - 0xc], 0x3f800000 */ 3649 MEM32(ebp + (-0x8)) = 0; /* 0x380023E2: mov dword ptr [ebp - 8], 0 */ 3650 MEM32(ebp + (-0x4)) = 0; /* 0x380023E9: mov dword ptr [ebp - 4], 0 */ 3651 RECOMP_ICALL(ebx); /* 0x380023F0: call ebx */ 3652 RECOMP_FLAGS_IN(); 3653 ecx = MEM32(ebp + (-0xC)); /* 0x380023F2: mov ecx, dword ptr [ebp - 0xc] */ 3654 edx = MEM32(ebp + (-0x8)); /* 0x380023F5: mov edx, dword ptr [ebp - 8] */ 3655 MEM32(ebp + (-0x28)) = ecx; /* 0x380023F8: mov dword ptr [ebp - 0x28], ecx */ 3656 ecx = MEM32(ebp + (-0x4)); /* 0x380023FB: mov ecx, dword ptr [ebp - 4] */ 3657 MEM32(ebp + (-0x20)) = ecx; /* 0x380023FE: mov dword ptr [ebp - 0x20], ecx */ 3658 PUSH32(esp, eax); /* 0x38002401: push eax */ 3659 ecx = ebp + (-0x28); /* 0x38002402: lea ecx, [ebp - 0x28] */ 3660 MEM32(ebp + (-0x24)) = edx; /* 0x38002405: mov dword ptr [ebp - 0x24], edx */ 3661 RECOMP_ICALL(MEM32(0x3804E4E4)); /* 0x38002408: call dword ptr [0x3804e4e4] */ 3662 RECOMP_FLAGS_IN(); 3663 edx = MEM32(eax); /* 0x3800240E: mov edx, dword ptr [eax] */ 3664 MEM32(ebp + (-0x34)) = edx; /* 0x38002410: mov dword ptr [ebp - 0x34], edx */ 3665 ecx = MEM32(eax + 0x4); /* 0x38002413: mov ecx, dword ptr [eax + 4] */ 3666 MEM32(ebp + (-0x30)) = ecx; /* 0x38002416: mov dword ptr [ebp - 0x30], ecx */ 3667 edx = MEM32(eax + 0x8); /* 0x38002419: mov edx, dword ptr [eax + 8] */ 3668 ecx = esi; /* 0x3800241C: mov ecx, esi */ 3669 MEM32(ebp + (-0x2C)) = edx; /* 0x3800241E: mov dword ptr [ebp - 0x2c], edx */ 3670 MEM32(ebp + (-0xC)) = 0; /* 0x38002421: mov dword ptr [ebp - 0xc], 0 */ 3671 MEM32(ebp + (-0x8)) = 0; /* 0x38002428: mov dword ptr [ebp - 8], 0 */ 3672 MEM32(ebp + (-0x4)) = 0x3F800000u; /* 0x3800242F: mov dword ptr [ebp - 4], 0x3f800000 */ 3673 RECOMP_ICALL(ebx); /* 0x38002436: call ebx */ 3674 RECOMP_FLAGS_IN(); 3675 ecx = MEM32(ebp + (-0xC)); /* 0x38002438: mov ecx, dword ptr [ebp - 0xc] */ 3676 edx = MEM32(ebp + (-0x8)); /* 0x3800243B: mov edx, dword ptr [ebp - 8] */ 3677 MEM32(ebp + (-0x28)) = ecx; /* 0x3800243E: mov dword ptr [ebp - 0x28], ecx */ 3678 ecx = MEM32(ebp + (-0x4)); /* 0x38002441: mov ecx, dword ptr [ebp - 4] */ 3679 MEM32(ebp + (-0x20)) = ecx; /* 0x38002444: mov dword ptr [ebp - 0x20], ecx */ 3680 PUSH32(esp, eax); /* 0x38002447: push eax */ 3681 ecx = ebp + (-0x28); /* 0x38002448: lea ecx, [ebp - 0x28] */ 3682 MEM32(ebp + (-0x24)) = edx; /* 0x3800244B: mov dword ptr [ebp - 0x24], edx */ 3683 RECOMP_ICALL(MEM32(0x3804E4E4)); /* 0x3800244E: call dword ptr [0x3804e4e4] */ 3684 RECOMP_FLAGS_IN(); 3685 edx = MEM32(eax); /* 0x38002454: mov edx, dword ptr [eax] */ 3686 MEM32(ebp + (-0x40)) = edx; /* 0x38002456: mov dword ptr [ebp - 0x40], edx */ 3687 ecx = MEM32(eax + 0x4); /* 0x38002459: mov ecx, dword ptr [eax + 4] */ 3688 MEM32(ebp + (-0x3C)) = ecx; /* 0x3800245C: mov dword ptr [ebp - 0x3c], ecx */ 3689 edx = MEM32(eax + 0x8); /* 0x3800245F: mov edx, dword ptr [eax + 8] */ 3690 MEM32(ebp + (-0x38)) = edx; /* 0x38002462: mov dword ptr [ebp - 0x38], edx */ 3691 _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24; 3692 SET_LO8(ebx, 0); /* 0x38002465: xor bl, bl */ 3693 _cf = 0; 3694 _flag_k = FK_NARROW(FK_TEST, 24); 3695 MEM32(ebp + (-0x44)) = 0; /* 0x38002467: mov dword ptr [ebp - 0x44], 0 */ 3696 L_3800246E: 3697 /* test LO8(ebx), LO8(ebx) */ /* 0x3800246E: test bl, bl */ 3698 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24; 3699 _cf = 0; 3700 _flag_k = FK_NARROW(FK_TEST, 24); 3701 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002706; /* 0x38002470: jne 0x38002706 */ 3702 L_38002476: 3703 eax = esi + 0x54; /* 0x38002476: lea eax, [esi + 0x54] */ 3704 ecx = MEM32(eax); /* 0x38002479: mov ecx, dword ptr [eax] */ 3705 edx = MEM32(eax + 0x4); /* 0x3800247B: mov edx, dword ptr [eax + 4] */ 3706 eax = MEM32(eax + 0x8); /* 0x3800247E: mov eax, dword ptr [eax + 8] */ 3707 MEM32(ebp + (-0xC)) = ecx; /* 0x38002481: mov dword ptr [ebp - 0xc], ecx */ 3708 ecx = MEM32(ebp + (-0x44)); /* 0x38002484: mov ecx, dword ptr [ebp - 0x44] */ 3709 MEM32(ebp + (-0x8)) = edx; /* 0x38002487: mov dword ptr [ebp - 8], edx */ 3710 edx = 1; /* 0x3800248A: mov edx, 1 */ 3711 if (((LO8(ecx)) & 31)) _cf = ((((LO8(ecx)) & 31)) <= 32 ? (((edx) >> (32 - (((LO8(ecx)) & 31)))) & 1u) : 0u); /* 0x3800248F: shl edx, cl */ 3712 if (((LO8(ecx)) & 31)) { _flag_a = recomp_flags_pack((edx << ((LO8(ecx)) & 31)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 3713 edx = edx << ((LO8(ecx)) & 31); /* 0x3800248F: shl edx, cl */ 3714 MEM32(ebp + (-0x4)) = eax; /* 0x38002491: mov dword ptr [ebp - 4], eax */ 3715 ecx = ebp + (-0x34); /* 0x38002494: lea ecx, [ebp - 0x34] */ 3716 MEM32(ebp + (-0x10)) = edx; /* 0x38002497: mov dword ptr [ebp - 0x10], edx */ 3717 fp_push((double)(int32_t)MEM32(ebp + (-0x10))); /* 0x3800249A: fild dword ptr [ebp - 0x10] */ 3718 edx = ebp + (-0xC); /* 0x3800249D: lea edx, [ebp - 0xc] */ 3719 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x380024A0: fmul dword ptr [0x3804e8bc] */ 3720 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x380024A6: fstp dword ptr [ebp - 0x10] */ 3721 eax = MEM32(ebp + (-0x10)); /* 0x380024A9: mov eax, dword ptr [ebp - 0x10] */ 3722 PUSH32(esp, eax); /* 0x380024AC: push eax */ 3723 PUSH32(esp, ecx); /* 0x380024AD: push ecx */ 3724 PUSH32(esp, edx); /* 0x380024AE: push edx */ 3725 ecx = esi; /* 0x380024AF: mov ecx, esi */ 3726 RECOMP_ICALL(0x38002170u); /* 0x380024B1: call 0x38002170 */ /* not lifted */ 3727 RECOMP_FLAGS_IN(); 3728 /* test LO8(eax), LO8(eax) */ /* 0x380024B6: test al, al */ 3729 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 3730 _cf = 0; 3731 _flag_k = FK_NARROW(FK_TEST, 24); 3732 if (TEST_Z(_flag_a, _flag_b)) goto L_380024D2; /* 0x380024B8: je 0x380024d2 */ 3733 L_380024BA: 3734 ecx = MEM32(ebp + (-0x34)); /* 0x380024BA: mov ecx, dword ptr [ebp - 0x34] */ 3735 edx = MEM32(ebp + (-0x30)); /* 0x380024BD: mov edx, dword ptr [ebp - 0x30] */ 3736 eax = edi; /* 0x380024C0: mov eax, edi */ 3737 MEM32(eax) = ecx; /* 0x380024C2: mov dword ptr [eax], ecx */ 3738 ecx = MEM32(ebp + (-0x2C)); /* 0x380024C4: mov ecx, dword ptr [ebp - 0x2c] */ 3739 MEM32(eax + 0x4) = edx; /* 0x380024C7: mov dword ptr [eax + 4], edx */ 3740 MEM32(eax + 0x8) = ecx; /* 0x380024CA: mov dword ptr [eax + 8], ecx */ 3741 goto L_380026E7; /* 0x380024CD: jmp 0x380026e7 */ 3742 L_380024D2: 3743 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x380024D2: fld dword ptr [ebp - 0x34] */ 3744 _st[0] = -_st[0]; /* 0x380024D5: fchs */ 3745 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x68)) = _v; } /* 0x380024D7: fstp dword ptr [ebp - 0x68] */ 3746 fp_push(*(float*)&MEM32(ebp + (-0x30))); /* 0x380024DA: fld dword ptr [ebp - 0x30] */ 3747 edx = MEM32(ebp + (-0x68)); /* 0x380024DD: mov edx, dword ptr [ebp - 0x68] */ 3748 _st[0] = -_st[0]; /* 0x380024E0: fchs */ 3749 MEM32(ebp + (-0x98)) = edx; /* 0x380024E2: mov dword ptr [ebp - 0x98], edx */ 3750 edx = MEM32(ebp + (-0x10)); /* 0x380024E8: mov edx, dword ptr [ebp - 0x10] */ 3751 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x64)) = _v; } /* 0x380024EB: fstp dword ptr [ebp - 0x64] */ 3752 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x380024EE: fld dword ptr [ebp - 0x2c] */ 3753 eax = MEM32(ebp + (-0x64)); /* 0x380024F1: mov eax, dword ptr [ebp - 0x64] */ 3754 _st[0] = -_st[0]; /* 0x380024F4: fchs */ 3755 MEM32(ebp + (-0x94)) = eax; /* 0x380024F6: mov dword ptr [ebp - 0x94], eax */ 3756 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x60)) = _v; } /* 0x380024FC: fstp dword ptr [ebp - 0x60] */ 3757 ecx = MEM32(ebp + (-0x60)); /* 0x380024FF: mov ecx, dword ptr [ebp - 0x60] */ 3758 PUSH32(esp, edx); /* 0x38002502: push edx */ 3759 MEM32(ebp + (-0x90)) = ecx; /* 0x38002503: mov dword ptr [ebp - 0x90], ecx */ 3760 eax = ebp + (-0x98); /* 0x38002509: lea eax, [ebp - 0x98] */ 3761 PUSH32(esp, eax); /* 0x3800250F: push eax */ 3762 ecx = ebp + (-0xC); /* 0x38002510: lea ecx, [ebp - 0xc] */ 3763 PUSH32(esp, ecx); /* 0x38002513: push ecx */ 3764 ecx = esi; /* 0x38002514: mov ecx, esi */ 3765 RECOMP_ICALL(0x38002170u); /* 0x38002516: call 0x38002170 */ /* not lifted */ 3766 RECOMP_FLAGS_IN(); 3767 /* test LO8(eax), LO8(eax) */ /* 0x3800251B: test al, al */ 3768 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 3769 _cf = 0; 3770 _flag_k = FK_NARROW(FK_TEST, 24); 3771 if (TEST_Z(_flag_a, _flag_b)) goto L_3800256D; /* 0x3800251D: je 0x3800256d */ 3772 L_3800251F: 3773 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x3800251F: fld dword ptr [ebp - 0x34] */ 3774 edx = MEM32(ebp + (-0x34)); /* 0x38002522: mov edx, dword ptr [ebp - 0x34] */ 3775 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002525: fmul dword ptr [0x3804e8e0] */ 3776 eax = MEM32(ebp + (-0x30)); /* 0x3800252B: mov eax, dword ptr [ebp - 0x30] */ 3777 ecx = MEM32(ebp + (-0x2C)); /* 0x3800252E: mov ecx, dword ptr [ebp - 0x2c] */ 3778 MEM32(ebp + (-0x50)) = edx; /* 0x38002531: mov dword ptr [ebp - 0x50], edx */ 3779 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x50)) = _v; } /* 0x38002534: fstp dword ptr [ebp - 0x50] */ 3780 MEM32(ebp + (-0x4C)) = eax; /* 0x38002537: mov dword ptr [ebp - 0x4c], eax */ 3781 fp_push(*(float*)&MEM32(ebp + (-0x4C))); /* 0x3800253A: fld dword ptr [ebp - 0x4c] */ 3782 eax = MEM32(ebp + (-0x50)); /* 0x3800253D: mov eax, dword ptr [ebp - 0x50] */ 3783 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002540: fmul dword ptr [0x3804e8e0] */ 3784 MEM32(ebp + (-0x48)) = ecx; /* 0x38002546: mov dword ptr [ebp - 0x48], ecx */ 3785 edx = edi; /* 0x38002549: mov edx, edi */ 3786 MEM32(edx) = eax; /* 0x3800254B: mov dword ptr [edx], eax */ 3787 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4C)) = _v; } /* 0x3800254D: fstp dword ptr [ebp - 0x4c] */ 3788 ecx = MEM32(ebp + (-0x4C)); /* 0x38002550: mov ecx, dword ptr [ebp - 0x4c] */ 3789 fp_push(*(float*)&MEM32(ebp + (-0x48))); /* 0x38002553: fld dword ptr [ebp - 0x48] */ 3790 MEM32(edx + 0x4) = ecx; /* 0x38002556: mov dword ptr [edx + 4], ecx */ 3791 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002559: fmul dword ptr [0x3804e8e0] */ 3792 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x48)) = _v; } /* 0x3800255F: fstp dword ptr [ebp - 0x48] */ 3793 eax = MEM32(ebp + (-0x48)); /* 0x38002562: mov eax, dword ptr [ebp - 0x48] */ 3794 MEM32(edx + 0x8) = eax; /* 0x38002565: mov dword ptr [edx + 8], eax */ 3795 goto L_380026E7; /* 0x38002568: jmp 0x380026e7 */ 3796 L_3800256D: 3797 ecx = MEM32(ebp + (-0x10)); /* 0x3800256D: mov ecx, dword ptr [ebp - 0x10] */ 3798 PUSH32(esp, ecx); /* 0x38002570: push ecx */ 3799 edx = ebp + (-0x1C); /* 0x38002571: lea edx, [ebp - 0x1c] */ 3800 PUSH32(esp, edx); /* 0x38002574: push edx */ 3801 eax = ebp + (-0xC); /* 0x38002575: lea eax, [ebp - 0xc] */ 3802 PUSH32(esp, eax); /* 0x38002578: push eax */ 3803 ecx = esi; /* 0x38002579: mov ecx, esi */ 3804 RECOMP_ICALL(0x38002170u); /* 0x3800257B: call 0x38002170 */ /* not lifted */ 3805 RECOMP_FLAGS_IN(); 3806 /* test LO8(eax), LO8(eax) */ /* 0x38002580: test al, al */ 3807 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 3808 _cf = 0; 3809 _flag_k = FK_NARROW(FK_TEST, 24); 3810 if (TEST_Z(_flag_a, _flag_b)) goto L_3800259C; /* 0x38002582: je 0x3800259c */ 3811 L_38002584: 3812 edx = MEM32(ebp + (-0x1C)); /* 0x38002584: mov edx, dword ptr [ebp - 0x1c] */ 3813 eax = MEM32(ebp + (-0x18)); /* 0x38002587: mov eax, dword ptr [ebp - 0x18] */ 3814 ecx = edi; /* 0x3800258A: mov ecx, edi */ 3815 MEM32(ecx) = edx; /* 0x3800258C: mov dword ptr [ecx], edx */ 3816 edx = MEM32(ebp + (-0x14)); /* 0x3800258E: mov edx, dword ptr [ebp - 0x14] */ 3817 MEM32(ecx + 0x4) = eax; /* 0x38002591: mov dword ptr [ecx + 4], eax */ 3818 MEM32(ecx + 0x8) = edx; /* 0x38002594: mov dword ptr [ecx + 8], edx */ 3819 goto L_380026E7; /* 0x38002597: jmp 0x380026e7 */ 3820 L_3800259C: 3821 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x3800259C: fld dword ptr [ebp - 0x1c] */ 3822 _st[0] = -_st[0]; /* 0x3800259F: fchs */ 3823 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x380025A1: fstp dword ptr [ebp - 0x28] */ 3824 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x380025A4: fld dword ptr [ebp - 0x18] */ 3825 eax = MEM32(ebp + (-0x28)); /* 0x380025A7: mov eax, dword ptr [ebp - 0x28] */ 3826 _st[0] = -_st[0]; /* 0x380025AA: fchs */ 3827 MEM32(ebp + (-0x8C)) = eax; /* 0x380025AC: mov dword ptr [ebp - 0x8c], eax */ 3828 eax = MEM32(ebp + (-0x10)); /* 0x380025B2: mov eax, dword ptr [ebp - 0x10] */ 3829 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x380025B5: fstp dword ptr [ebp - 0x24] */ 3830 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x380025B8: fld dword ptr [ebp - 0x14] */ 3831 ecx = MEM32(ebp + (-0x24)); /* 0x380025BB: mov ecx, dword ptr [ebp - 0x24] */ 3832 _st[0] = -_st[0]; /* 0x380025BE: fchs */ 3833 MEM32(ebp + (-0x88)) = ecx; /* 0x380025C0: mov dword ptr [ebp - 0x88], ecx */ 3834 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x380025C6: fstp dword ptr [ebp - 0x20] */ 3835 edx = MEM32(ebp + (-0x20)); /* 0x380025C9: mov edx, dword ptr [ebp - 0x20] */ 3836 PUSH32(esp, eax); /* 0x380025CC: push eax */ 3837 ecx = ebp + (-0x8C); /* 0x380025CD: lea ecx, [ebp - 0x8c] */ 3838 MEM32(ebp + (-0x84)) = edx; /* 0x380025D3: mov dword ptr [ebp - 0x84], edx */ 3839 PUSH32(esp, ecx); /* 0x380025D9: push ecx */ 3840 edx = ebp + (-0xC); /* 0x380025DA: lea edx, [ebp - 0xc] */ 3841 PUSH32(esp, edx); /* 0x380025DD: push edx */ 3842 ecx = esi; /* 0x380025DE: mov ecx, esi */ 3843 RECOMP_ICALL(0x38002170u); /* 0x380025E0: call 0x38002170 */ /* not lifted */ 3844 RECOMP_FLAGS_IN(); 3845 /* test LO8(eax), LO8(eax) */ /* 0x380025E5: test al, al */ 3846 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 3847 _cf = 0; 3848 _flag_k = FK_NARROW(FK_TEST, 24); 3849 if (TEST_Z(_flag_a, _flag_b)) goto L_38002637; /* 0x380025E7: je 0x38002637 */ 3850 L_380025E9: 3851 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x380025E9: fld dword ptr [ebp - 0x1c] */ 3852 eax = MEM32(ebp + (-0x1C)); /* 0x380025EC: mov eax, dword ptr [ebp - 0x1c] */ 3853 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x380025EF: fmul dword ptr [0x3804e8e0] */ 3854 ecx = MEM32(ebp + (-0x18)); /* 0x380025F5: mov ecx, dword ptr [ebp - 0x18] */ 3855 edx = MEM32(ebp + (-0x14)); /* 0x380025F8: mov edx, dword ptr [ebp - 0x14] */ 3856 MEM32(ebp + (-0x5C)) = eax; /* 0x380025FB: mov dword ptr [ebp - 0x5c], eax */ 3857 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x5C)) = _v; } /* 0x380025FE: fstp dword ptr [ebp - 0x5c] */ 3858 MEM32(ebp + (-0x58)) = ecx; /* 0x38002601: mov dword ptr [ebp - 0x58], ecx */ 3859 fp_push(*(float*)&MEM32(ebp + (-0x58))); /* 0x38002604: fld dword ptr [ebp - 0x58] */ 3860 ecx = MEM32(ebp + (-0x5C)); /* 0x38002607: mov ecx, dword ptr [ebp - 0x5c] */ 3861 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x3800260A: fmul dword ptr [0x3804e8e0] */ 3862 MEM32(ebp + (-0x54)) = edx; /* 0x38002610: mov dword ptr [ebp - 0x54], edx */ 3863 eax = edi; /* 0x38002613: mov eax, edi */ 3864 MEM32(eax) = ecx; /* 0x38002615: mov dword ptr [eax], ecx */ 3865 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x58)) = _v; } /* 0x38002617: fstp dword ptr [ebp - 0x58] */ 3866 edx = MEM32(ebp + (-0x58)); /* 0x3800261A: mov edx, dword ptr [ebp - 0x58] */ 3867 fp_push(*(float*)&MEM32(ebp + (-0x54))); /* 0x3800261D: fld dword ptr [ebp - 0x54] */ 3868 MEM32(eax + 0x4) = edx; /* 0x38002620: mov dword ptr [eax + 4], edx */ 3869 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002623: fmul dword ptr [0x3804e8e0] */ 3870 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x54)) = _v; } /* 0x38002629: fstp dword ptr [ebp - 0x54] */ 3871 ecx = MEM32(ebp + (-0x54)); /* 0x3800262C: mov ecx, dword ptr [ebp - 0x54] */ 3872 MEM32(eax + 0x8) = ecx; /* 0x3800262F: mov dword ptr [eax + 8], ecx */ 3873 goto L_380026E7; /* 0x38002632: jmp 0x380026e7 */ 3874 L_38002637: 3875 edx = MEM32(ebp + (-0x10)); /* 0x38002637: mov edx, dword ptr [ebp - 0x10] */ 3876 PUSH32(esp, edx); /* 0x3800263A: push edx */ 3877 eax = ebp + (-0x40); /* 0x3800263B: lea eax, [ebp - 0x40] */ 3878 PUSH32(esp, eax); /* 0x3800263E: push eax */ 3879 ecx = ebp + (-0xC); /* 0x3800263F: lea ecx, [ebp - 0xc] */ 3880 PUSH32(esp, ecx); /* 0x38002642: push ecx */ 3881 ecx = esi; /* 0x38002643: mov ecx, esi */ 3882 RECOMP_ICALL(0x38002170u); /* 0x38002645: call 0x38002170 */ /* not lifted */ 3883 RECOMP_FLAGS_IN(); 3884 /* test LO8(eax), LO8(eax) */ /* 0x3800264A: test al, al */ 3885 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 3886 _cf = 0; 3887 _flag_k = FK_NARROW(FK_TEST, 24); 3888 if (TEST_Z(_flag_a, _flag_b)) goto L_38002666; /* 0x3800264C: je 0x38002666 */ 3889 L_3800264E: 3890 eax = MEM32(ebp + (-0x40)); /* 0x3800264E: mov eax, dword ptr [ebp - 0x40] */ 3891 ecx = MEM32(ebp + (-0x3C)); /* 0x38002651: mov ecx, dword ptr [ebp - 0x3c] */ 3892 edx = edi; /* 0x38002654: mov edx, edi */ 3893 MEM32(edx) = eax; /* 0x38002656: mov dword ptr [edx], eax */ 3894 eax = MEM32(ebp + (-0x38)); /* 0x38002658: mov eax, dword ptr [ebp - 0x38] */ 3895 MEM32(edx + 0x4) = ecx; /* 0x3800265B: mov dword ptr [edx + 4], ecx */ 3896 MEM32(edx + 0x8) = eax; /* 0x3800265E: mov dword ptr [edx + 8], eax */ 3897 goto L_380026E7; /* 0x38002661: jmp 0x380026e7 */ 3898 L_38002666: 3899 fp_push(*(float*)&MEM32(ebp + (-0x38))); /* 0x38002666: fld dword ptr [ebp - 0x38] */ 3900 PUSH32(esp, ecx); /* 0x38002669: push ecx */ 3901 _st[0] = -_st[0]; /* 0x3800266A: fchs */ 3902 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x3800266C: fstp dword ptr [esp] */ 3903 PUSH32(esp, ecx); /* 0x3800266F: push ecx */ 3904 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x38002670: fld dword ptr [ebp - 0x3c] */ 3905 _st[0] = -_st[0]; /* 0x38002673: fchs */ 3906 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38002675: fstp dword ptr [esp] */ 3907 PUSH32(esp, ecx); /* 0x38002678: push ecx */ 3908 fp_push(*(float*)&MEM32(ebp + (-0x40))); /* 0x38002679: fld dword ptr [ebp - 0x40] */ 3909 ecx = ebp + (-0xA4); /* 0x3800267C: lea ecx, [ebp - 0xa4] */ 3910 _st[0] = -_st[0]; /* 0x38002682: fchs */ 3911 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38002684: fstp dword ptr [esp] */ 3912 RECOMP_ICALL(MEM32(0x3804E4D8)); /* 0x38002687: call dword ptr [0x3804e4d8] */ 3913 RECOMP_FLAGS_IN(); 3914 ecx = MEM32(eax); /* 0x3800268D: mov ecx, dword ptr [eax] */ 3915 MEM32(ebp + (-0x80)) = ecx; /* 0x3800268F: mov dword ptr [ebp - 0x80], ecx */ 3916 edx = MEM32(eax + 0x4); /* 0x38002692: mov edx, dword ptr [eax + 4] */ 3917 ecx = MEM32(ebp + (-0x10)); /* 0x38002695: mov ecx, dword ptr [ebp - 0x10] */ 3918 MEM32(ebp + (-0x7C)) = edx; /* 0x38002698: mov dword ptr [ebp - 0x7c], edx */ 3919 eax = MEM32(eax + 0x8); /* 0x3800269B: mov eax, dword ptr [eax + 8] */ 3920 PUSH32(esp, ecx); /* 0x3800269E: push ecx */ 3921 edx = ebp + (-0x80); /* 0x3800269F: lea edx, [ebp - 0x80] */ 3922 MEM32(ebp + (-0x78)) = eax; /* 0x380026A2: mov dword ptr [ebp - 0x78], eax */ 3923 PUSH32(esp, edx); /* 0x380026A5: push edx */ 3924 eax = ebp + (-0xC); /* 0x380026A6: lea eax, [ebp - 0xc] */ 3925 PUSH32(esp, eax); /* 0x380026A9: push eax */ 3926 ecx = esi; /* 0x380026AA: mov ecx, esi */ 3927 RECOMP_ICALL(0x38002170u); /* 0x380026AC: call 0x38002170 */ /* not lifted */ 3928 RECOMP_FLAGS_IN(); 3929 /* test LO8(eax), LO8(eax) */ /* 0x380026B1: test al, al */ 3930 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 3931 _cf = 0; 3932 _flag_k = FK_NARROW(FK_TEST, 24); 3933 if (TEST_Z(_flag_a, _flag_b)) goto L_380026E9; /* 0x380026B3: je 0x380026e9 */ 3934 L_380026B5: 3935 ecx = MEM32(ebp + (-0x40)); /* 0x380026B5: mov ecx, dword ptr [ebp - 0x40] */ 3936 edx = MEM32(ebp + (-0x3C)); /* 0x380026B8: mov edx, dword ptr [ebp - 0x3c] */ 3937 eax = MEM32(ebp + (-0x38)); /* 0x380026BB: mov eax, dword ptr [ebp - 0x38] */ 3938 MEM32(ebp + (-0x74)) = ecx; /* 0x380026BE: mov dword ptr [ebp - 0x74], ecx */ 3939 PUSH32(esp, 0xBF800000u); /* 0x380026C1: push 0xbf800000 */ 3940 ecx = ebp + (-0x74); /* 0x380026C6: lea ecx, [ebp - 0x74] */ 3941 MEM32(ebp + (-0x70)) = edx; /* 0x380026C9: mov dword ptr [ebp - 0x70], edx */ 3942 MEM32(ebp + (-0x6C)) = eax; /* 0x380026CC: mov dword ptr [ebp - 0x6c], eax */ 3943 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x380026CF: call dword ptr [0x3804e4d4] */ 3944 RECOMP_FLAGS_IN(); 3945 edx = MEM32(eax); /* 0x380026D5: mov edx, dword ptr [eax] */ 3946 ecx = edi; /* 0x380026D7: mov ecx, edi */ 3947 MEM32(ecx) = edx; /* 0x380026D9: mov dword ptr [ecx], edx */ 3948 edx = MEM32(eax + 0x4); /* 0x380026DB: mov edx, dword ptr [eax + 4] */ 3949 MEM32(ecx + 0x4) = edx; /* 0x380026DE: mov dword ptr [ecx + 4], edx */ 3950 eax = MEM32(eax + 0x8); /* 0x380026E1: mov eax, dword ptr [eax + 8] */ 3951 MEM32(ecx + 0x8) = eax; /* 0x380026E4: mov dword ptr [ecx + 8], eax */ 3952 L_380026E7: 3953 SET_LO8(ebx, 1); /* 0x380026E7: mov bl, 1 */ 3954 L_380026E9: 3955 eax = MEM32(ebp + (-0x44)); /* 0x380026E9: mov eax, dword ptr [ebp - 0x44] */ 3956 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(2); 3957 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3958 eax = eax + 2; /* 0x380026EC: add eax, 2 */ 3959 _flag_k = FK_ADD; 3960 /* cmp eax, 8 */ /* 0x380026EF: cmp eax, 8 */ 3961 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(8); 3962 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3963 _flag_k = FK_CMP; 3964 MEM32(ebp + (-0x44)) = eax; /* 0x380026F2: mov dword ptr [ebp - 0x44], eax */ 3965 RECOMP_BACKEDGE(); 3966 if (CMP_L(_flag_a, _flag_b)) goto L_3800246E; /* 0x380026F5: jl 0x3800246e */ 3967 L_380026FB: 3968 /* test LO8(ebx), LO8(ebx) */ /* 0x380026FB: test bl, bl */ 3969 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24; 3970 _cf = 0; 3971 _flag_k = FK_NARROW(FK_TEST, 24); 3972 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002706; /* 0x380026FD: jne 0x38002706 */ 3973 L_380026FF: 3974 MEM8(esi + 0x1C5) = (uint8_t)(1); /* 0x380026FF: mov byte ptr [esi + 0x1c5], 1 */ 3975 L_38002706: 3976 edi = POP32_VAL(esp); /* 0x38002706: pop edi */ 3977 esi = POP32_VAL(esp); /* 0x38002707: pop esi */ 3978 ebx = POP32_VAL(esp); /* 0x38002708: pop ebx */ 3979 esp = ebp; /* 0x38002709: mov esp, ebp */ 3980 ebp = POP32_VAL(esp); /* 0x3800270B: pop ebp */ 3981 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800270C: ret */ 3982 RECOMP_REGS_OUT(); 3983 } 3984 3985 void sub_3800246E(void) { 3986 int _fpu_cmp = 0; 3987 uint32_t _cf = 0; 3988 int _df = 1; 3989 uint32_t _flag_k = FK_NONE; 3990 uint32_t _flag_a = 0, _flag_b = 0; 3991 uint32_t _itail_tgt = 0; 3992 RECOMP_REGS_LOCALS 3993 RECOMP_ENTER(0x3800246Eu); 3994 3995 L_3800246E: 3996 /* test LO8(ebx), LO8(ebx) */ /* 0x3800246E: test bl, bl */ 3997 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24; 3998 _cf = 0; 3999 _flag_k = FK_NARROW(FK_TEST, 24); 4000 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002706; /* 0x38002470: jne 0x38002706 */ 4001 L_38002476: 4002 eax = esi + 0x54; /* 0x38002476: lea eax, [esi + 0x54] */ 4003 ecx = MEM32(eax); /* 0x38002479: mov ecx, dword ptr [eax] */ 4004 edx = MEM32(eax + 0x4); /* 0x3800247B: mov edx, dword ptr [eax + 4] */ 4005 eax = MEM32(eax + 0x8); /* 0x3800247E: mov eax, dword ptr [eax + 8] */ 4006 MEM32(ebp + (-0xC)) = ecx; /* 0x38002481: mov dword ptr [ebp - 0xc], ecx */ 4007 ecx = MEM32(ebp + (-0x44)); /* 0x38002484: mov ecx, dword ptr [ebp - 0x44] */ 4008 MEM32(ebp + (-0x8)) = edx; /* 0x38002487: mov dword ptr [ebp - 8], edx */ 4009 edx = 1; /* 0x3800248A: mov edx, 1 */ 4010 if (((LO8(ecx)) & 31)) _cf = ((((LO8(ecx)) & 31)) <= 32 ? (((edx) >> (32 - (((LO8(ecx)) & 31)))) & 1u) : 0u); /* 0x3800248F: shl edx, cl */ 4011 if (((LO8(ecx)) & 31)) { _flag_a = recomp_flags_pack((edx << ((LO8(ecx)) & 31)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 4012 edx = edx << ((LO8(ecx)) & 31); /* 0x3800248F: shl edx, cl */ 4013 MEM32(ebp + (-0x4)) = eax; /* 0x38002491: mov dword ptr [ebp - 4], eax */ 4014 ecx = ebp + (-0x34); /* 0x38002494: lea ecx, [ebp - 0x34] */ 4015 MEM32(ebp + (-0x10)) = edx; /* 0x38002497: mov dword ptr [ebp - 0x10], edx */ 4016 fp_push((double)(int32_t)MEM32(ebp + (-0x10))); /* 0x3800249A: fild dword ptr [ebp - 0x10] */ 4017 edx = ebp + (-0xC); /* 0x3800249D: lea edx, [ebp - 0xc] */ 4018 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x380024A0: fmul dword ptr [0x3804e8bc] */ 4019 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x380024A6: fstp dword ptr [ebp - 0x10] */ 4020 eax = MEM32(ebp + (-0x10)); /* 0x380024A9: mov eax, dword ptr [ebp - 0x10] */ 4021 PUSH32(esp, eax); /* 0x380024AC: push eax */ 4022 PUSH32(esp, ecx); /* 0x380024AD: push ecx */ 4023 PUSH32(esp, edx); /* 0x380024AE: push edx */ 4024 ecx = esi; /* 0x380024AF: mov ecx, esi */ 4025 RECOMP_ICALL(0x38002170u); /* 0x380024B1: call 0x38002170 */ /* not lifted */ 4026 RECOMP_FLAGS_IN(); 4027 /* test LO8(eax), LO8(eax) */ /* 0x380024B6: test al, al */ 4028 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4029 _cf = 0; 4030 _flag_k = FK_NARROW(FK_TEST, 24); 4031 if (TEST_Z(_flag_a, _flag_b)) goto L_380024D2; /* 0x380024B8: je 0x380024d2 */ 4032 L_380024BA: 4033 ecx = MEM32(ebp + (-0x34)); /* 0x380024BA: mov ecx, dword ptr [ebp - 0x34] */ 4034 edx = MEM32(ebp + (-0x30)); /* 0x380024BD: mov edx, dword ptr [ebp - 0x30] */ 4035 eax = edi; /* 0x380024C0: mov eax, edi */ 4036 MEM32(eax) = ecx; /* 0x380024C2: mov dword ptr [eax], ecx */ 4037 ecx = MEM32(ebp + (-0x2C)); /* 0x380024C4: mov ecx, dword ptr [ebp - 0x2c] */ 4038 MEM32(eax + 0x4) = edx; /* 0x380024C7: mov dword ptr [eax + 4], edx */ 4039 MEM32(eax + 0x8) = ecx; /* 0x380024CA: mov dword ptr [eax + 8], ecx */ 4040 goto L_380026E7; /* 0x380024CD: jmp 0x380026e7 */ 4041 L_380024D2: 4042 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x380024D2: fld dword ptr [ebp - 0x34] */ 4043 _st[0] = -_st[0]; /* 0x380024D5: fchs */ 4044 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x68)) = _v; } /* 0x380024D7: fstp dword ptr [ebp - 0x68] */ 4045 fp_push(*(float*)&MEM32(ebp + (-0x30))); /* 0x380024DA: fld dword ptr [ebp - 0x30] */ 4046 edx = MEM32(ebp + (-0x68)); /* 0x380024DD: mov edx, dword ptr [ebp - 0x68] */ 4047 _st[0] = -_st[0]; /* 0x380024E0: fchs */ 4048 MEM32(ebp + (-0x98)) = edx; /* 0x380024E2: mov dword ptr [ebp - 0x98], edx */ 4049 edx = MEM32(ebp + (-0x10)); /* 0x380024E8: mov edx, dword ptr [ebp - 0x10] */ 4050 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x64)) = _v; } /* 0x380024EB: fstp dword ptr [ebp - 0x64] */ 4051 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x380024EE: fld dword ptr [ebp - 0x2c] */ 4052 eax = MEM32(ebp + (-0x64)); /* 0x380024F1: mov eax, dword ptr [ebp - 0x64] */ 4053 _st[0] = -_st[0]; /* 0x380024F4: fchs */ 4054 MEM32(ebp + (-0x94)) = eax; /* 0x380024F6: mov dword ptr [ebp - 0x94], eax */ 4055 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x60)) = _v; } /* 0x380024FC: fstp dword ptr [ebp - 0x60] */ 4056 ecx = MEM32(ebp + (-0x60)); /* 0x380024FF: mov ecx, dword ptr [ebp - 0x60] */ 4057 PUSH32(esp, edx); /* 0x38002502: push edx */ 4058 MEM32(ebp + (-0x90)) = ecx; /* 0x38002503: mov dword ptr [ebp - 0x90], ecx */ 4059 eax = ebp + (-0x98); /* 0x38002509: lea eax, [ebp - 0x98] */ 4060 PUSH32(esp, eax); /* 0x3800250F: push eax */ 4061 ecx = ebp + (-0xC); /* 0x38002510: lea ecx, [ebp - 0xc] */ 4062 PUSH32(esp, ecx); /* 0x38002513: push ecx */ 4063 ecx = esi; /* 0x38002514: mov ecx, esi */ 4064 RECOMP_ICALL(0x38002170u); /* 0x38002516: call 0x38002170 */ /* not lifted */ 4065 RECOMP_FLAGS_IN(); 4066 /* test LO8(eax), LO8(eax) */ /* 0x3800251B: test al, al */ 4067 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4068 _cf = 0; 4069 _flag_k = FK_NARROW(FK_TEST, 24); 4070 if (TEST_Z(_flag_a, _flag_b)) goto L_3800256D; /* 0x3800251D: je 0x3800256d */ 4071 L_3800251F: 4072 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x3800251F: fld dword ptr [ebp - 0x34] */ 4073 edx = MEM32(ebp + (-0x34)); /* 0x38002522: mov edx, dword ptr [ebp - 0x34] */ 4074 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002525: fmul dword ptr [0x3804e8e0] */ 4075 eax = MEM32(ebp + (-0x30)); /* 0x3800252B: mov eax, dword ptr [ebp - 0x30] */ 4076 ecx = MEM32(ebp + (-0x2C)); /* 0x3800252E: mov ecx, dword ptr [ebp - 0x2c] */ 4077 MEM32(ebp + (-0x50)) = edx; /* 0x38002531: mov dword ptr [ebp - 0x50], edx */ 4078 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x50)) = _v; } /* 0x38002534: fstp dword ptr [ebp - 0x50] */ 4079 MEM32(ebp + (-0x4C)) = eax; /* 0x38002537: mov dword ptr [ebp - 0x4c], eax */ 4080 fp_push(*(float*)&MEM32(ebp + (-0x4C))); /* 0x3800253A: fld dword ptr [ebp - 0x4c] */ 4081 eax = MEM32(ebp + (-0x50)); /* 0x3800253D: mov eax, dword ptr [ebp - 0x50] */ 4082 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002540: fmul dword ptr [0x3804e8e0] */ 4083 MEM32(ebp + (-0x48)) = ecx; /* 0x38002546: mov dword ptr [ebp - 0x48], ecx */ 4084 edx = edi; /* 0x38002549: mov edx, edi */ 4085 MEM32(edx) = eax; /* 0x3800254B: mov dword ptr [edx], eax */ 4086 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4C)) = _v; } /* 0x3800254D: fstp dword ptr [ebp - 0x4c] */ 4087 ecx = MEM32(ebp + (-0x4C)); /* 0x38002550: mov ecx, dword ptr [ebp - 0x4c] */ 4088 fp_push(*(float*)&MEM32(ebp + (-0x48))); /* 0x38002553: fld dword ptr [ebp - 0x48] */ 4089 MEM32(edx + 0x4) = ecx; /* 0x38002556: mov dword ptr [edx + 4], ecx */ 4090 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002559: fmul dword ptr [0x3804e8e0] */ 4091 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x48)) = _v; } /* 0x3800255F: fstp dword ptr [ebp - 0x48] */ 4092 eax = MEM32(ebp + (-0x48)); /* 0x38002562: mov eax, dword ptr [ebp - 0x48] */ 4093 MEM32(edx + 0x8) = eax; /* 0x38002565: mov dword ptr [edx + 8], eax */ 4094 goto L_380026E7; /* 0x38002568: jmp 0x380026e7 */ 4095 L_3800256D: 4096 ecx = MEM32(ebp + (-0x10)); /* 0x3800256D: mov ecx, dword ptr [ebp - 0x10] */ 4097 PUSH32(esp, ecx); /* 0x38002570: push ecx */ 4098 edx = ebp + (-0x1C); /* 0x38002571: lea edx, [ebp - 0x1c] */ 4099 PUSH32(esp, edx); /* 0x38002574: push edx */ 4100 eax = ebp + (-0xC); /* 0x38002575: lea eax, [ebp - 0xc] */ 4101 PUSH32(esp, eax); /* 0x38002578: push eax */ 4102 ecx = esi; /* 0x38002579: mov ecx, esi */ 4103 RECOMP_ICALL(0x38002170u); /* 0x3800257B: call 0x38002170 */ /* not lifted */ 4104 RECOMP_FLAGS_IN(); 4105 /* test LO8(eax), LO8(eax) */ /* 0x38002580: test al, al */ 4106 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4107 _cf = 0; 4108 _flag_k = FK_NARROW(FK_TEST, 24); 4109 if (TEST_Z(_flag_a, _flag_b)) goto L_3800259C; /* 0x38002582: je 0x3800259c */ 4110 L_38002584: 4111 edx = MEM32(ebp + (-0x1C)); /* 0x38002584: mov edx, dword ptr [ebp - 0x1c] */ 4112 eax = MEM32(ebp + (-0x18)); /* 0x38002587: mov eax, dword ptr [ebp - 0x18] */ 4113 ecx = edi; /* 0x3800258A: mov ecx, edi */ 4114 MEM32(ecx) = edx; /* 0x3800258C: mov dword ptr [ecx], edx */ 4115 edx = MEM32(ebp + (-0x14)); /* 0x3800258E: mov edx, dword ptr [ebp - 0x14] */ 4116 MEM32(ecx + 0x4) = eax; /* 0x38002591: mov dword ptr [ecx + 4], eax */ 4117 MEM32(ecx + 0x8) = edx; /* 0x38002594: mov dword ptr [ecx + 8], edx */ 4118 goto L_380026E7; /* 0x38002597: jmp 0x380026e7 */ 4119 L_3800259C: 4120 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x3800259C: fld dword ptr [ebp - 0x1c] */ 4121 _st[0] = -_st[0]; /* 0x3800259F: fchs */ 4122 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x380025A1: fstp dword ptr [ebp - 0x28] */ 4123 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x380025A4: fld dword ptr [ebp - 0x18] */ 4124 eax = MEM32(ebp + (-0x28)); /* 0x380025A7: mov eax, dword ptr [ebp - 0x28] */ 4125 _st[0] = -_st[0]; /* 0x380025AA: fchs */ 4126 MEM32(ebp + (-0x8C)) = eax; /* 0x380025AC: mov dword ptr [ebp - 0x8c], eax */ 4127 eax = MEM32(ebp + (-0x10)); /* 0x380025B2: mov eax, dword ptr [ebp - 0x10] */ 4128 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x380025B5: fstp dword ptr [ebp - 0x24] */ 4129 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x380025B8: fld dword ptr [ebp - 0x14] */ 4130 ecx = MEM32(ebp + (-0x24)); /* 0x380025BB: mov ecx, dword ptr [ebp - 0x24] */ 4131 _st[0] = -_st[0]; /* 0x380025BE: fchs */ 4132 MEM32(ebp + (-0x88)) = ecx; /* 0x380025C0: mov dword ptr [ebp - 0x88], ecx */ 4133 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x380025C6: fstp dword ptr [ebp - 0x20] */ 4134 edx = MEM32(ebp + (-0x20)); /* 0x380025C9: mov edx, dword ptr [ebp - 0x20] */ 4135 PUSH32(esp, eax); /* 0x380025CC: push eax */ 4136 ecx = ebp + (-0x8C); /* 0x380025CD: lea ecx, [ebp - 0x8c] */ 4137 MEM32(ebp + (-0x84)) = edx; /* 0x380025D3: mov dword ptr [ebp - 0x84], edx */ 4138 PUSH32(esp, ecx); /* 0x380025D9: push ecx */ 4139 edx = ebp + (-0xC); /* 0x380025DA: lea edx, [ebp - 0xc] */ 4140 PUSH32(esp, edx); /* 0x380025DD: push edx */ 4141 ecx = esi; /* 0x380025DE: mov ecx, esi */ 4142 RECOMP_ICALL(0x38002170u); /* 0x380025E0: call 0x38002170 */ /* not lifted */ 4143 RECOMP_FLAGS_IN(); 4144 /* test LO8(eax), LO8(eax) */ /* 0x380025E5: test al, al */ 4145 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4146 _cf = 0; 4147 _flag_k = FK_NARROW(FK_TEST, 24); 4148 if (TEST_Z(_flag_a, _flag_b)) goto L_38002637; /* 0x380025E7: je 0x38002637 */ 4149 L_380025E9: 4150 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x380025E9: fld dword ptr [ebp - 0x1c] */ 4151 eax = MEM32(ebp + (-0x1C)); /* 0x380025EC: mov eax, dword ptr [ebp - 0x1c] */ 4152 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x380025EF: fmul dword ptr [0x3804e8e0] */ 4153 ecx = MEM32(ebp + (-0x18)); /* 0x380025F5: mov ecx, dword ptr [ebp - 0x18] */ 4154 edx = MEM32(ebp + (-0x14)); /* 0x380025F8: mov edx, dword ptr [ebp - 0x14] */ 4155 MEM32(ebp + (-0x5C)) = eax; /* 0x380025FB: mov dword ptr [ebp - 0x5c], eax */ 4156 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x5C)) = _v; } /* 0x380025FE: fstp dword ptr [ebp - 0x5c] */ 4157 MEM32(ebp + (-0x58)) = ecx; /* 0x38002601: mov dword ptr [ebp - 0x58], ecx */ 4158 fp_push(*(float*)&MEM32(ebp + (-0x58))); /* 0x38002604: fld dword ptr [ebp - 0x58] */ 4159 ecx = MEM32(ebp + (-0x5C)); /* 0x38002607: mov ecx, dword ptr [ebp - 0x5c] */ 4160 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x3800260A: fmul dword ptr [0x3804e8e0] */ 4161 MEM32(ebp + (-0x54)) = edx; /* 0x38002610: mov dword ptr [ebp - 0x54], edx */ 4162 eax = edi; /* 0x38002613: mov eax, edi */ 4163 MEM32(eax) = ecx; /* 0x38002615: mov dword ptr [eax], ecx */ 4164 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x58)) = _v; } /* 0x38002617: fstp dword ptr [ebp - 0x58] */ 4165 edx = MEM32(ebp + (-0x58)); /* 0x3800261A: mov edx, dword ptr [ebp - 0x58] */ 4166 fp_push(*(float*)&MEM32(ebp + (-0x54))); /* 0x3800261D: fld dword ptr [ebp - 0x54] */ 4167 MEM32(eax + 0x4) = edx; /* 0x38002620: mov dword ptr [eax + 4], edx */ 4168 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002623: fmul dword ptr [0x3804e8e0] */ 4169 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x54)) = _v; } /* 0x38002629: fstp dword ptr [ebp - 0x54] */ 4170 ecx = MEM32(ebp + (-0x54)); /* 0x3800262C: mov ecx, dword ptr [ebp - 0x54] */ 4171 MEM32(eax + 0x8) = ecx; /* 0x3800262F: mov dword ptr [eax + 8], ecx */ 4172 goto L_380026E7; /* 0x38002632: jmp 0x380026e7 */ 4173 L_38002637: 4174 edx = MEM32(ebp + (-0x10)); /* 0x38002637: mov edx, dword ptr [ebp - 0x10] */ 4175 PUSH32(esp, edx); /* 0x3800263A: push edx */ 4176 eax = ebp + (-0x40); /* 0x3800263B: lea eax, [ebp - 0x40] */ 4177 PUSH32(esp, eax); /* 0x3800263E: push eax */ 4178 ecx = ebp + (-0xC); /* 0x3800263F: lea ecx, [ebp - 0xc] */ 4179 PUSH32(esp, ecx); /* 0x38002642: push ecx */ 4180 ecx = esi; /* 0x38002643: mov ecx, esi */ 4181 RECOMP_ICALL(0x38002170u); /* 0x38002645: call 0x38002170 */ /* not lifted */ 4182 RECOMP_FLAGS_IN(); 4183 /* test LO8(eax), LO8(eax) */ /* 0x3800264A: test al, al */ 4184 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4185 _cf = 0; 4186 _flag_k = FK_NARROW(FK_TEST, 24); 4187 if (TEST_Z(_flag_a, _flag_b)) goto L_38002666; /* 0x3800264C: je 0x38002666 */ 4188 L_3800264E: 4189 eax = MEM32(ebp + (-0x40)); /* 0x3800264E: mov eax, dword ptr [ebp - 0x40] */ 4190 ecx = MEM32(ebp + (-0x3C)); /* 0x38002651: mov ecx, dword ptr [ebp - 0x3c] */ 4191 edx = edi; /* 0x38002654: mov edx, edi */ 4192 MEM32(edx) = eax; /* 0x38002656: mov dword ptr [edx], eax */ 4193 eax = MEM32(ebp + (-0x38)); /* 0x38002658: mov eax, dword ptr [ebp - 0x38] */ 4194 MEM32(edx + 0x4) = ecx; /* 0x3800265B: mov dword ptr [edx + 4], ecx */ 4195 MEM32(edx + 0x8) = eax; /* 0x3800265E: mov dword ptr [edx + 8], eax */ 4196 goto L_380026E7; /* 0x38002661: jmp 0x380026e7 */ 4197 L_38002666: 4198 fp_push(*(float*)&MEM32(ebp + (-0x38))); /* 0x38002666: fld dword ptr [ebp - 0x38] */ 4199 PUSH32(esp, ecx); /* 0x38002669: push ecx */ 4200 _st[0] = -_st[0]; /* 0x3800266A: fchs */ 4201 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x3800266C: fstp dword ptr [esp] */ 4202 PUSH32(esp, ecx); /* 0x3800266F: push ecx */ 4203 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x38002670: fld dword ptr [ebp - 0x3c] */ 4204 _st[0] = -_st[0]; /* 0x38002673: fchs */ 4205 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38002675: fstp dword ptr [esp] */ 4206 PUSH32(esp, ecx); /* 0x38002678: push ecx */ 4207 fp_push(*(float*)&MEM32(ebp + (-0x40))); /* 0x38002679: fld dword ptr [ebp - 0x40] */ 4208 ecx = ebp + (-0xA4); /* 0x3800267C: lea ecx, [ebp - 0xa4] */ 4209 _st[0] = -_st[0]; /* 0x38002682: fchs */ 4210 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38002684: fstp dword ptr [esp] */ 4211 RECOMP_ICALL(MEM32(0x3804E4D8)); /* 0x38002687: call dword ptr [0x3804e4d8] */ 4212 RECOMP_FLAGS_IN(); 4213 ecx = MEM32(eax); /* 0x3800268D: mov ecx, dword ptr [eax] */ 4214 MEM32(ebp + (-0x80)) = ecx; /* 0x3800268F: mov dword ptr [ebp - 0x80], ecx */ 4215 edx = MEM32(eax + 0x4); /* 0x38002692: mov edx, dword ptr [eax + 4] */ 4216 ecx = MEM32(ebp + (-0x10)); /* 0x38002695: mov ecx, dword ptr [ebp - 0x10] */ 4217 MEM32(ebp + (-0x7C)) = edx; /* 0x38002698: mov dword ptr [ebp - 0x7c], edx */ 4218 eax = MEM32(eax + 0x8); /* 0x3800269B: mov eax, dword ptr [eax + 8] */ 4219 PUSH32(esp, ecx); /* 0x3800269E: push ecx */ 4220 edx = ebp + (-0x80); /* 0x3800269F: lea edx, [ebp - 0x80] */ 4221 MEM32(ebp + (-0x78)) = eax; /* 0x380026A2: mov dword ptr [ebp - 0x78], eax */ 4222 PUSH32(esp, edx); /* 0x380026A5: push edx */ 4223 eax = ebp + (-0xC); /* 0x380026A6: lea eax, [ebp - 0xc] */ 4224 PUSH32(esp, eax); /* 0x380026A9: push eax */ 4225 ecx = esi; /* 0x380026AA: mov ecx, esi */ 4226 RECOMP_ICALL(0x38002170u); /* 0x380026AC: call 0x38002170 */ /* not lifted */ 4227 RECOMP_FLAGS_IN(); 4228 /* test LO8(eax), LO8(eax) */ /* 0x380026B1: test al, al */ 4229 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4230 _cf = 0; 4231 _flag_k = FK_NARROW(FK_TEST, 24); 4232 if (TEST_Z(_flag_a, _flag_b)) goto L_380026E9; /* 0x380026B3: je 0x380026e9 */ 4233 L_380026B5: 4234 ecx = MEM32(ebp + (-0x40)); /* 0x380026B5: mov ecx, dword ptr [ebp - 0x40] */ 4235 edx = MEM32(ebp + (-0x3C)); /* 0x380026B8: mov edx, dword ptr [ebp - 0x3c] */ 4236 eax = MEM32(ebp + (-0x38)); /* 0x380026BB: mov eax, dword ptr [ebp - 0x38] */ 4237 MEM32(ebp + (-0x74)) = ecx; /* 0x380026BE: mov dword ptr [ebp - 0x74], ecx */ 4238 PUSH32(esp, 0xBF800000u); /* 0x380026C1: push 0xbf800000 */ 4239 ecx = ebp + (-0x74); /* 0x380026C6: lea ecx, [ebp - 0x74] */ 4240 MEM32(ebp + (-0x70)) = edx; /* 0x380026C9: mov dword ptr [ebp - 0x70], edx */ 4241 MEM32(ebp + (-0x6C)) = eax; /* 0x380026CC: mov dword ptr [ebp - 0x6c], eax */ 4242 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x380026CF: call dword ptr [0x3804e4d4] */ 4243 RECOMP_FLAGS_IN(); 4244 edx = MEM32(eax); /* 0x380026D5: mov edx, dword ptr [eax] */ 4245 ecx = edi; /* 0x380026D7: mov ecx, edi */ 4246 MEM32(ecx) = edx; /* 0x380026D9: mov dword ptr [ecx], edx */ 4247 edx = MEM32(eax + 0x4); /* 0x380026DB: mov edx, dword ptr [eax + 4] */ 4248 MEM32(ecx + 0x4) = edx; /* 0x380026DE: mov dword ptr [ecx + 4], edx */ 4249 eax = MEM32(eax + 0x8); /* 0x380026E1: mov eax, dword ptr [eax + 8] */ 4250 MEM32(ecx + 0x8) = eax; /* 0x380026E4: mov dword ptr [ecx + 8], eax */ 4251 L_380026E7: 4252 SET_LO8(ebx, 1); /* 0x380026E7: mov bl, 1 */ 4253 L_380026E9: 4254 eax = MEM32(ebp + (-0x44)); /* 0x380026E9: mov eax, dword ptr [ebp - 0x44] */ 4255 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(2); 4256 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 4257 eax = eax + 2; /* 0x380026EC: add eax, 2 */ 4258 _flag_k = FK_ADD; 4259 /* cmp eax, 8 */ /* 0x380026EF: cmp eax, 8 */ 4260 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(8); 4261 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4262 _flag_k = FK_CMP; 4263 MEM32(ebp + (-0x44)) = eax; /* 0x380026F2: mov dword ptr [ebp - 0x44], eax */ 4264 RECOMP_BACKEDGE(); 4265 if (CMP_L(_flag_a, _flag_b)) goto L_3800246E; /* 0x380026F5: jl 0x3800246e */ 4266 L_380026FB: 4267 /* test LO8(ebx), LO8(ebx) */ /* 0x380026FB: test bl, bl */ 4268 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24; 4269 _cf = 0; 4270 _flag_k = FK_NARROW(FK_TEST, 24); 4271 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002706; /* 0x380026FD: jne 0x38002706 */ 4272 L_380026FF: 4273 MEM8(esi + 0x1C5) = (uint8_t)(1); /* 0x380026FF: mov byte ptr [esi + 0x1c5], 1 */ 4274 L_38002706: 4275 edi = POP32_VAL(esp); /* 0x38002706: pop edi */ 4276 esi = POP32_VAL(esp); /* 0x38002707: pop esi */ 4277 ebx = POP32_VAL(esp); /* 0x38002708: pop ebx */ 4278 esp = ebp; /* 0x38002709: mov esp, ebp */ 4279 ebp = POP32_VAL(esp); /* 0x3800270B: pop ebp */ 4280 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800270C: ret */ 4281 RECOMP_REGS_OUT(); 4282 } 4283 4284 void sub_380026E7(void) { 4285 int _fpu_cmp = 0; 4286 uint32_t _cf = 0; 4287 int _df = 1; 4288 uint32_t _flag_k = FK_NONE; 4289 uint32_t _flag_a = 0, _flag_b = 0; 4290 uint32_t _itail_tgt = 0; 4291 RECOMP_REGS_LOCALS 4292 RECOMP_ENTER(0x380026E7u); 4293 4294 goto L_380026E7; 4295 L_3800246E: 4296 /* test LO8(ebx), LO8(ebx) */ /* 0x3800246E: test bl, bl */ 4297 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24; 4298 _cf = 0; 4299 _flag_k = FK_NARROW(FK_TEST, 24); 4300 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002706; /* 0x38002470: jne 0x38002706 */ 4301 L_38002476: 4302 eax = esi + 0x54; /* 0x38002476: lea eax, [esi + 0x54] */ 4303 ecx = MEM32(eax); /* 0x38002479: mov ecx, dword ptr [eax] */ 4304 edx = MEM32(eax + 0x4); /* 0x3800247B: mov edx, dword ptr [eax + 4] */ 4305 eax = MEM32(eax + 0x8); /* 0x3800247E: mov eax, dword ptr [eax + 8] */ 4306 MEM32(ebp + (-0xC)) = ecx; /* 0x38002481: mov dword ptr [ebp - 0xc], ecx */ 4307 ecx = MEM32(ebp + (-0x44)); /* 0x38002484: mov ecx, dword ptr [ebp - 0x44] */ 4308 MEM32(ebp + (-0x8)) = edx; /* 0x38002487: mov dword ptr [ebp - 8], edx */ 4309 edx = 1; /* 0x3800248A: mov edx, 1 */ 4310 if (((LO8(ecx)) & 31)) _cf = ((((LO8(ecx)) & 31)) <= 32 ? (((edx) >> (32 - (((LO8(ecx)) & 31)))) & 1u) : 0u); /* 0x3800248F: shl edx, cl */ 4311 if (((LO8(ecx)) & 31)) { _flag_a = recomp_flags_pack((edx << ((LO8(ecx)) & 31)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 4312 edx = edx << ((LO8(ecx)) & 31); /* 0x3800248F: shl edx, cl */ 4313 MEM32(ebp + (-0x4)) = eax; /* 0x38002491: mov dword ptr [ebp - 4], eax */ 4314 ecx = ebp + (-0x34); /* 0x38002494: lea ecx, [ebp - 0x34] */ 4315 MEM32(ebp + (-0x10)) = edx; /* 0x38002497: mov dword ptr [ebp - 0x10], edx */ 4316 fp_push((double)(int32_t)MEM32(ebp + (-0x10))); /* 0x3800249A: fild dword ptr [ebp - 0x10] */ 4317 edx = ebp + (-0xC); /* 0x3800249D: lea edx, [ebp - 0xc] */ 4318 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x380024A0: fmul dword ptr [0x3804e8bc] */ 4319 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x380024A6: fstp dword ptr [ebp - 0x10] */ 4320 eax = MEM32(ebp + (-0x10)); /* 0x380024A9: mov eax, dword ptr [ebp - 0x10] */ 4321 PUSH32(esp, eax); /* 0x380024AC: push eax */ 4322 PUSH32(esp, ecx); /* 0x380024AD: push ecx */ 4323 PUSH32(esp, edx); /* 0x380024AE: push edx */ 4324 ecx = esi; /* 0x380024AF: mov ecx, esi */ 4325 RECOMP_ICALL(0x38002170u); /* 0x380024B1: call 0x38002170 */ /* not lifted */ 4326 RECOMP_FLAGS_IN(); 4327 /* test LO8(eax), LO8(eax) */ /* 0x380024B6: test al, al */ 4328 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4329 _cf = 0; 4330 _flag_k = FK_NARROW(FK_TEST, 24); 4331 if (TEST_Z(_flag_a, _flag_b)) goto L_380024D2; /* 0x380024B8: je 0x380024d2 */ 4332 L_380024BA: 4333 ecx = MEM32(ebp + (-0x34)); /* 0x380024BA: mov ecx, dword ptr [ebp - 0x34] */ 4334 edx = MEM32(ebp + (-0x30)); /* 0x380024BD: mov edx, dword ptr [ebp - 0x30] */ 4335 eax = edi; /* 0x380024C0: mov eax, edi */ 4336 MEM32(eax) = ecx; /* 0x380024C2: mov dword ptr [eax], ecx */ 4337 ecx = MEM32(ebp + (-0x2C)); /* 0x380024C4: mov ecx, dword ptr [ebp - 0x2c] */ 4338 MEM32(eax + 0x4) = edx; /* 0x380024C7: mov dword ptr [eax + 4], edx */ 4339 MEM32(eax + 0x8) = ecx; /* 0x380024CA: mov dword ptr [eax + 8], ecx */ 4340 goto L_380026E7; /* 0x380024CD: jmp 0x380026e7 */ 4341 L_380024D2: 4342 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x380024D2: fld dword ptr [ebp - 0x34] */ 4343 _st[0] = -_st[0]; /* 0x380024D5: fchs */ 4344 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x68)) = _v; } /* 0x380024D7: fstp dword ptr [ebp - 0x68] */ 4345 fp_push(*(float*)&MEM32(ebp + (-0x30))); /* 0x380024DA: fld dword ptr [ebp - 0x30] */ 4346 edx = MEM32(ebp + (-0x68)); /* 0x380024DD: mov edx, dword ptr [ebp - 0x68] */ 4347 _st[0] = -_st[0]; /* 0x380024E0: fchs */ 4348 MEM32(ebp + (-0x98)) = edx; /* 0x380024E2: mov dword ptr [ebp - 0x98], edx */ 4349 edx = MEM32(ebp + (-0x10)); /* 0x380024E8: mov edx, dword ptr [ebp - 0x10] */ 4350 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x64)) = _v; } /* 0x380024EB: fstp dword ptr [ebp - 0x64] */ 4351 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x380024EE: fld dword ptr [ebp - 0x2c] */ 4352 eax = MEM32(ebp + (-0x64)); /* 0x380024F1: mov eax, dword ptr [ebp - 0x64] */ 4353 _st[0] = -_st[0]; /* 0x380024F4: fchs */ 4354 MEM32(ebp + (-0x94)) = eax; /* 0x380024F6: mov dword ptr [ebp - 0x94], eax */ 4355 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x60)) = _v; } /* 0x380024FC: fstp dword ptr [ebp - 0x60] */ 4356 ecx = MEM32(ebp + (-0x60)); /* 0x380024FF: mov ecx, dword ptr [ebp - 0x60] */ 4357 PUSH32(esp, edx); /* 0x38002502: push edx */ 4358 MEM32(ebp + (-0x90)) = ecx; /* 0x38002503: mov dword ptr [ebp - 0x90], ecx */ 4359 eax = ebp + (-0x98); /* 0x38002509: lea eax, [ebp - 0x98] */ 4360 PUSH32(esp, eax); /* 0x3800250F: push eax */ 4361 ecx = ebp + (-0xC); /* 0x38002510: lea ecx, [ebp - 0xc] */ 4362 PUSH32(esp, ecx); /* 0x38002513: push ecx */ 4363 ecx = esi; /* 0x38002514: mov ecx, esi */ 4364 RECOMP_ICALL(0x38002170u); /* 0x38002516: call 0x38002170 */ /* not lifted */ 4365 RECOMP_FLAGS_IN(); 4366 /* test LO8(eax), LO8(eax) */ /* 0x3800251B: test al, al */ 4367 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4368 _cf = 0; 4369 _flag_k = FK_NARROW(FK_TEST, 24); 4370 if (TEST_Z(_flag_a, _flag_b)) goto L_3800256D; /* 0x3800251D: je 0x3800256d */ 4371 L_3800251F: 4372 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x3800251F: fld dword ptr [ebp - 0x34] */ 4373 edx = MEM32(ebp + (-0x34)); /* 0x38002522: mov edx, dword ptr [ebp - 0x34] */ 4374 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002525: fmul dword ptr [0x3804e8e0] */ 4375 eax = MEM32(ebp + (-0x30)); /* 0x3800252B: mov eax, dword ptr [ebp - 0x30] */ 4376 ecx = MEM32(ebp + (-0x2C)); /* 0x3800252E: mov ecx, dword ptr [ebp - 0x2c] */ 4377 MEM32(ebp + (-0x50)) = edx; /* 0x38002531: mov dword ptr [ebp - 0x50], edx */ 4378 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x50)) = _v; } /* 0x38002534: fstp dword ptr [ebp - 0x50] */ 4379 MEM32(ebp + (-0x4C)) = eax; /* 0x38002537: mov dword ptr [ebp - 0x4c], eax */ 4380 fp_push(*(float*)&MEM32(ebp + (-0x4C))); /* 0x3800253A: fld dword ptr [ebp - 0x4c] */ 4381 eax = MEM32(ebp + (-0x50)); /* 0x3800253D: mov eax, dword ptr [ebp - 0x50] */ 4382 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002540: fmul dword ptr [0x3804e8e0] */ 4383 MEM32(ebp + (-0x48)) = ecx; /* 0x38002546: mov dword ptr [ebp - 0x48], ecx */ 4384 edx = edi; /* 0x38002549: mov edx, edi */ 4385 MEM32(edx) = eax; /* 0x3800254B: mov dword ptr [edx], eax */ 4386 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4C)) = _v; } /* 0x3800254D: fstp dword ptr [ebp - 0x4c] */ 4387 ecx = MEM32(ebp + (-0x4C)); /* 0x38002550: mov ecx, dword ptr [ebp - 0x4c] */ 4388 fp_push(*(float*)&MEM32(ebp + (-0x48))); /* 0x38002553: fld dword ptr [ebp - 0x48] */ 4389 MEM32(edx + 0x4) = ecx; /* 0x38002556: mov dword ptr [edx + 4], ecx */ 4390 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002559: fmul dword ptr [0x3804e8e0] */ 4391 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x48)) = _v; } /* 0x3800255F: fstp dword ptr [ebp - 0x48] */ 4392 eax = MEM32(ebp + (-0x48)); /* 0x38002562: mov eax, dword ptr [ebp - 0x48] */ 4393 MEM32(edx + 0x8) = eax; /* 0x38002565: mov dword ptr [edx + 8], eax */ 4394 goto L_380026E7; /* 0x38002568: jmp 0x380026e7 */ 4395 L_3800256D: 4396 ecx = MEM32(ebp + (-0x10)); /* 0x3800256D: mov ecx, dword ptr [ebp - 0x10] */ 4397 PUSH32(esp, ecx); /* 0x38002570: push ecx */ 4398 edx = ebp + (-0x1C); /* 0x38002571: lea edx, [ebp - 0x1c] */ 4399 PUSH32(esp, edx); /* 0x38002574: push edx */ 4400 eax = ebp + (-0xC); /* 0x38002575: lea eax, [ebp - 0xc] */ 4401 PUSH32(esp, eax); /* 0x38002578: push eax */ 4402 ecx = esi; /* 0x38002579: mov ecx, esi */ 4403 RECOMP_ICALL(0x38002170u); /* 0x3800257B: call 0x38002170 */ /* not lifted */ 4404 RECOMP_FLAGS_IN(); 4405 /* test LO8(eax), LO8(eax) */ /* 0x38002580: test al, al */ 4406 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4407 _cf = 0; 4408 _flag_k = FK_NARROW(FK_TEST, 24); 4409 if (TEST_Z(_flag_a, _flag_b)) goto L_3800259C; /* 0x38002582: je 0x3800259c */ 4410 L_38002584: 4411 edx = MEM32(ebp + (-0x1C)); /* 0x38002584: mov edx, dword ptr [ebp - 0x1c] */ 4412 eax = MEM32(ebp + (-0x18)); /* 0x38002587: mov eax, dword ptr [ebp - 0x18] */ 4413 ecx = edi; /* 0x3800258A: mov ecx, edi */ 4414 MEM32(ecx) = edx; /* 0x3800258C: mov dword ptr [ecx], edx */ 4415 edx = MEM32(ebp + (-0x14)); /* 0x3800258E: mov edx, dword ptr [ebp - 0x14] */ 4416 MEM32(ecx + 0x4) = eax; /* 0x38002591: mov dword ptr [ecx + 4], eax */ 4417 MEM32(ecx + 0x8) = edx; /* 0x38002594: mov dword ptr [ecx + 8], edx */ 4418 goto L_380026E7; /* 0x38002597: jmp 0x380026e7 */ 4419 L_3800259C: 4420 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x3800259C: fld dword ptr [ebp - 0x1c] */ 4421 _st[0] = -_st[0]; /* 0x3800259F: fchs */ 4422 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x380025A1: fstp dword ptr [ebp - 0x28] */ 4423 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x380025A4: fld dword ptr [ebp - 0x18] */ 4424 eax = MEM32(ebp + (-0x28)); /* 0x380025A7: mov eax, dword ptr [ebp - 0x28] */ 4425 _st[0] = -_st[0]; /* 0x380025AA: fchs */ 4426 MEM32(ebp + (-0x8C)) = eax; /* 0x380025AC: mov dword ptr [ebp - 0x8c], eax */ 4427 eax = MEM32(ebp + (-0x10)); /* 0x380025B2: mov eax, dword ptr [ebp - 0x10] */ 4428 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x380025B5: fstp dword ptr [ebp - 0x24] */ 4429 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x380025B8: fld dword ptr [ebp - 0x14] */ 4430 ecx = MEM32(ebp + (-0x24)); /* 0x380025BB: mov ecx, dword ptr [ebp - 0x24] */ 4431 _st[0] = -_st[0]; /* 0x380025BE: fchs */ 4432 MEM32(ebp + (-0x88)) = ecx; /* 0x380025C0: mov dword ptr [ebp - 0x88], ecx */ 4433 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x380025C6: fstp dword ptr [ebp - 0x20] */ 4434 edx = MEM32(ebp + (-0x20)); /* 0x380025C9: mov edx, dword ptr [ebp - 0x20] */ 4435 PUSH32(esp, eax); /* 0x380025CC: push eax */ 4436 ecx = ebp + (-0x8C); /* 0x380025CD: lea ecx, [ebp - 0x8c] */ 4437 MEM32(ebp + (-0x84)) = edx; /* 0x380025D3: mov dword ptr [ebp - 0x84], edx */ 4438 PUSH32(esp, ecx); /* 0x380025D9: push ecx */ 4439 edx = ebp + (-0xC); /* 0x380025DA: lea edx, [ebp - 0xc] */ 4440 PUSH32(esp, edx); /* 0x380025DD: push edx */ 4441 ecx = esi; /* 0x380025DE: mov ecx, esi */ 4442 RECOMP_ICALL(0x38002170u); /* 0x380025E0: call 0x38002170 */ /* not lifted */ 4443 RECOMP_FLAGS_IN(); 4444 /* test LO8(eax), LO8(eax) */ /* 0x380025E5: test al, al */ 4445 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4446 _cf = 0; 4447 _flag_k = FK_NARROW(FK_TEST, 24); 4448 if (TEST_Z(_flag_a, _flag_b)) goto L_38002637; /* 0x380025E7: je 0x38002637 */ 4449 L_380025E9: 4450 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x380025E9: fld dword ptr [ebp - 0x1c] */ 4451 eax = MEM32(ebp + (-0x1C)); /* 0x380025EC: mov eax, dword ptr [ebp - 0x1c] */ 4452 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x380025EF: fmul dword ptr [0x3804e8e0] */ 4453 ecx = MEM32(ebp + (-0x18)); /* 0x380025F5: mov ecx, dword ptr [ebp - 0x18] */ 4454 edx = MEM32(ebp + (-0x14)); /* 0x380025F8: mov edx, dword ptr [ebp - 0x14] */ 4455 MEM32(ebp + (-0x5C)) = eax; /* 0x380025FB: mov dword ptr [ebp - 0x5c], eax */ 4456 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x5C)) = _v; } /* 0x380025FE: fstp dword ptr [ebp - 0x5c] */ 4457 MEM32(ebp + (-0x58)) = ecx; /* 0x38002601: mov dword ptr [ebp - 0x58], ecx */ 4458 fp_push(*(float*)&MEM32(ebp + (-0x58))); /* 0x38002604: fld dword ptr [ebp - 0x58] */ 4459 ecx = MEM32(ebp + (-0x5C)); /* 0x38002607: mov ecx, dword ptr [ebp - 0x5c] */ 4460 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x3800260A: fmul dword ptr [0x3804e8e0] */ 4461 MEM32(ebp + (-0x54)) = edx; /* 0x38002610: mov dword ptr [ebp - 0x54], edx */ 4462 eax = edi; /* 0x38002613: mov eax, edi */ 4463 MEM32(eax) = ecx; /* 0x38002615: mov dword ptr [eax], ecx */ 4464 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x58)) = _v; } /* 0x38002617: fstp dword ptr [ebp - 0x58] */ 4465 edx = MEM32(ebp + (-0x58)); /* 0x3800261A: mov edx, dword ptr [ebp - 0x58] */ 4466 fp_push(*(float*)&MEM32(ebp + (-0x54))); /* 0x3800261D: fld dword ptr [ebp - 0x54] */ 4467 MEM32(eax + 0x4) = edx; /* 0x38002620: mov dword ptr [eax + 4], edx */ 4468 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002623: fmul dword ptr [0x3804e8e0] */ 4469 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x54)) = _v; } /* 0x38002629: fstp dword ptr [ebp - 0x54] */ 4470 ecx = MEM32(ebp + (-0x54)); /* 0x3800262C: mov ecx, dword ptr [ebp - 0x54] */ 4471 MEM32(eax + 0x8) = ecx; /* 0x3800262F: mov dword ptr [eax + 8], ecx */ 4472 goto L_380026E7; /* 0x38002632: jmp 0x380026e7 */ 4473 L_38002637: 4474 edx = MEM32(ebp + (-0x10)); /* 0x38002637: mov edx, dword ptr [ebp - 0x10] */ 4475 PUSH32(esp, edx); /* 0x3800263A: push edx */ 4476 eax = ebp + (-0x40); /* 0x3800263B: lea eax, [ebp - 0x40] */ 4477 PUSH32(esp, eax); /* 0x3800263E: push eax */ 4478 ecx = ebp + (-0xC); /* 0x3800263F: lea ecx, [ebp - 0xc] */ 4479 PUSH32(esp, ecx); /* 0x38002642: push ecx */ 4480 ecx = esi; /* 0x38002643: mov ecx, esi */ 4481 RECOMP_ICALL(0x38002170u); /* 0x38002645: call 0x38002170 */ /* not lifted */ 4482 RECOMP_FLAGS_IN(); 4483 /* test LO8(eax), LO8(eax) */ /* 0x3800264A: test al, al */ 4484 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4485 _cf = 0; 4486 _flag_k = FK_NARROW(FK_TEST, 24); 4487 if (TEST_Z(_flag_a, _flag_b)) goto L_38002666; /* 0x3800264C: je 0x38002666 */ 4488 L_3800264E: 4489 eax = MEM32(ebp + (-0x40)); /* 0x3800264E: mov eax, dword ptr [ebp - 0x40] */ 4490 ecx = MEM32(ebp + (-0x3C)); /* 0x38002651: mov ecx, dword ptr [ebp - 0x3c] */ 4491 edx = edi; /* 0x38002654: mov edx, edi */ 4492 MEM32(edx) = eax; /* 0x38002656: mov dword ptr [edx], eax */ 4493 eax = MEM32(ebp + (-0x38)); /* 0x38002658: mov eax, dword ptr [ebp - 0x38] */ 4494 MEM32(edx + 0x4) = ecx; /* 0x3800265B: mov dword ptr [edx + 4], ecx */ 4495 MEM32(edx + 0x8) = eax; /* 0x3800265E: mov dword ptr [edx + 8], eax */ 4496 goto L_380026E7; /* 0x38002661: jmp 0x380026e7 */ 4497 L_38002666: 4498 fp_push(*(float*)&MEM32(ebp + (-0x38))); /* 0x38002666: fld dword ptr [ebp - 0x38] */ 4499 PUSH32(esp, ecx); /* 0x38002669: push ecx */ 4500 _st[0] = -_st[0]; /* 0x3800266A: fchs */ 4501 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x3800266C: fstp dword ptr [esp] */ 4502 PUSH32(esp, ecx); /* 0x3800266F: push ecx */ 4503 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x38002670: fld dword ptr [ebp - 0x3c] */ 4504 _st[0] = -_st[0]; /* 0x38002673: fchs */ 4505 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38002675: fstp dword ptr [esp] */ 4506 PUSH32(esp, ecx); /* 0x38002678: push ecx */ 4507 fp_push(*(float*)&MEM32(ebp + (-0x40))); /* 0x38002679: fld dword ptr [ebp - 0x40] */ 4508 ecx = ebp + (-0xA4); /* 0x3800267C: lea ecx, [ebp - 0xa4] */ 4509 _st[0] = -_st[0]; /* 0x38002682: fchs */ 4510 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38002684: fstp dword ptr [esp] */ 4511 RECOMP_ICALL(MEM32(0x3804E4D8)); /* 0x38002687: call dword ptr [0x3804e4d8] */ 4512 RECOMP_FLAGS_IN(); 4513 ecx = MEM32(eax); /* 0x3800268D: mov ecx, dword ptr [eax] */ 4514 MEM32(ebp + (-0x80)) = ecx; /* 0x3800268F: mov dword ptr [ebp - 0x80], ecx */ 4515 edx = MEM32(eax + 0x4); /* 0x38002692: mov edx, dword ptr [eax + 4] */ 4516 ecx = MEM32(ebp + (-0x10)); /* 0x38002695: mov ecx, dword ptr [ebp - 0x10] */ 4517 MEM32(ebp + (-0x7C)) = edx; /* 0x38002698: mov dword ptr [ebp - 0x7c], edx */ 4518 eax = MEM32(eax + 0x8); /* 0x3800269B: mov eax, dword ptr [eax + 8] */ 4519 PUSH32(esp, ecx); /* 0x3800269E: push ecx */ 4520 edx = ebp + (-0x80); /* 0x3800269F: lea edx, [ebp - 0x80] */ 4521 MEM32(ebp + (-0x78)) = eax; /* 0x380026A2: mov dword ptr [ebp - 0x78], eax */ 4522 PUSH32(esp, edx); /* 0x380026A5: push edx */ 4523 eax = ebp + (-0xC); /* 0x380026A6: lea eax, [ebp - 0xc] */ 4524 PUSH32(esp, eax); /* 0x380026A9: push eax */ 4525 ecx = esi; /* 0x380026AA: mov ecx, esi */ 4526 RECOMP_ICALL(0x38002170u); /* 0x380026AC: call 0x38002170 */ /* not lifted */ 4527 RECOMP_FLAGS_IN(); 4528 /* test LO8(eax), LO8(eax) */ /* 0x380026B1: test al, al */ 4529 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4530 _cf = 0; 4531 _flag_k = FK_NARROW(FK_TEST, 24); 4532 if (TEST_Z(_flag_a, _flag_b)) goto L_380026E9; /* 0x380026B3: je 0x380026e9 */ 4533 L_380026B5: 4534 ecx = MEM32(ebp + (-0x40)); /* 0x380026B5: mov ecx, dword ptr [ebp - 0x40] */ 4535 edx = MEM32(ebp + (-0x3C)); /* 0x380026B8: mov edx, dword ptr [ebp - 0x3c] */ 4536 eax = MEM32(ebp + (-0x38)); /* 0x380026BB: mov eax, dword ptr [ebp - 0x38] */ 4537 MEM32(ebp + (-0x74)) = ecx; /* 0x380026BE: mov dword ptr [ebp - 0x74], ecx */ 4538 PUSH32(esp, 0xBF800000u); /* 0x380026C1: push 0xbf800000 */ 4539 ecx = ebp + (-0x74); /* 0x380026C6: lea ecx, [ebp - 0x74] */ 4540 MEM32(ebp + (-0x70)) = edx; /* 0x380026C9: mov dword ptr [ebp - 0x70], edx */ 4541 MEM32(ebp + (-0x6C)) = eax; /* 0x380026CC: mov dword ptr [ebp - 0x6c], eax */ 4542 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x380026CF: call dword ptr [0x3804e4d4] */ 4543 RECOMP_FLAGS_IN(); 4544 edx = MEM32(eax); /* 0x380026D5: mov edx, dword ptr [eax] */ 4545 ecx = edi; /* 0x380026D7: mov ecx, edi */ 4546 MEM32(ecx) = edx; /* 0x380026D9: mov dword ptr [ecx], edx */ 4547 edx = MEM32(eax + 0x4); /* 0x380026DB: mov edx, dword ptr [eax + 4] */ 4548 MEM32(ecx + 0x4) = edx; /* 0x380026DE: mov dword ptr [ecx + 4], edx */ 4549 eax = MEM32(eax + 0x8); /* 0x380026E1: mov eax, dword ptr [eax + 8] */ 4550 MEM32(ecx + 0x8) = eax; /* 0x380026E4: mov dword ptr [ecx + 8], eax */ 4551 L_380026E7: 4552 SET_LO8(ebx, 1); /* 0x380026E7: mov bl, 1 */ 4553 L_380026E9: 4554 eax = MEM32(ebp + (-0x44)); /* 0x380026E9: mov eax, dword ptr [ebp - 0x44] */ 4555 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(2); 4556 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 4557 eax = eax + 2; /* 0x380026EC: add eax, 2 */ 4558 _flag_k = FK_ADD; 4559 /* cmp eax, 8 */ /* 0x380026EF: cmp eax, 8 */ 4560 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(8); 4561 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4562 _flag_k = FK_CMP; 4563 MEM32(ebp + (-0x44)) = eax; /* 0x380026F2: mov dword ptr [ebp - 0x44], eax */ 4564 RECOMP_BACKEDGE(); 4565 if (CMP_L(_flag_a, _flag_b)) goto L_3800246E; /* 0x380026F5: jl 0x3800246e */ 4566 L_380026FB: 4567 /* test LO8(ebx), LO8(ebx) */ /* 0x380026FB: test bl, bl */ 4568 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24; 4569 _cf = 0; 4570 _flag_k = FK_NARROW(FK_TEST, 24); 4571 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002706; /* 0x380026FD: jne 0x38002706 */ 4572 L_380026FF: 4573 MEM8(esi + 0x1C5) = (uint8_t)(1); /* 0x380026FF: mov byte ptr [esi + 0x1c5], 1 */ 4574 L_38002706: 4575 edi = POP32_VAL(esp); /* 0x38002706: pop edi */ 4576 esi = POP32_VAL(esp); /* 0x38002707: pop esi */ 4577 ebx = POP32_VAL(esp); /* 0x38002708: pop ebx */ 4578 esp = ebp; /* 0x38002709: mov esp, ebp */ 4579 ebp = POP32_VAL(esp); /* 0x3800270B: pop ebp */ 4580 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800270C: ret */ 4581 RECOMP_REGS_OUT(); 4582 } 4583 4584 void sub_380026E9(void) { 4585 int _fpu_cmp = 0; 4586 uint32_t _cf = 0; 4587 int _df = 1; 4588 uint32_t _flag_k = FK_NONE; 4589 uint32_t _flag_a = 0, _flag_b = 0; 4590 uint32_t _itail_tgt = 0; 4591 RECOMP_REGS_LOCALS 4592 RECOMP_ENTER(0x380026E9u); 4593 4594 goto L_380026E9; 4595 L_3800246E: 4596 /* test LO8(ebx), LO8(ebx) */ /* 0x3800246E: test bl, bl */ 4597 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24; 4598 _cf = 0; 4599 _flag_k = FK_NARROW(FK_TEST, 24); 4600 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002706; /* 0x38002470: jne 0x38002706 */ 4601 L_38002476: 4602 eax = esi + 0x54; /* 0x38002476: lea eax, [esi + 0x54] */ 4603 ecx = MEM32(eax); /* 0x38002479: mov ecx, dword ptr [eax] */ 4604 edx = MEM32(eax + 0x4); /* 0x3800247B: mov edx, dword ptr [eax + 4] */ 4605 eax = MEM32(eax + 0x8); /* 0x3800247E: mov eax, dword ptr [eax + 8] */ 4606 MEM32(ebp + (-0xC)) = ecx; /* 0x38002481: mov dword ptr [ebp - 0xc], ecx */ 4607 ecx = MEM32(ebp + (-0x44)); /* 0x38002484: mov ecx, dword ptr [ebp - 0x44] */ 4608 MEM32(ebp + (-0x8)) = edx; /* 0x38002487: mov dword ptr [ebp - 8], edx */ 4609 edx = 1; /* 0x3800248A: mov edx, 1 */ 4610 if (((LO8(ecx)) & 31)) _cf = ((((LO8(ecx)) & 31)) <= 32 ? (((edx) >> (32 - (((LO8(ecx)) & 31)))) & 1u) : 0u); /* 0x3800248F: shl edx, cl */ 4611 if (((LO8(ecx)) & 31)) { _flag_a = recomp_flags_pack((edx << ((LO8(ecx)) & 31)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; } 4612 edx = edx << ((LO8(ecx)) & 31); /* 0x3800248F: shl edx, cl */ 4613 MEM32(ebp + (-0x4)) = eax; /* 0x38002491: mov dword ptr [ebp - 4], eax */ 4614 ecx = ebp + (-0x34); /* 0x38002494: lea ecx, [ebp - 0x34] */ 4615 MEM32(ebp + (-0x10)) = edx; /* 0x38002497: mov dword ptr [ebp - 0x10], edx */ 4616 fp_push((double)(int32_t)MEM32(ebp + (-0x10))); /* 0x3800249A: fild dword ptr [ebp - 0x10] */ 4617 edx = ebp + (-0xC); /* 0x3800249D: lea edx, [ebp - 0xc] */ 4618 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x380024A0: fmul dword ptr [0x3804e8bc] */ 4619 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x380024A6: fstp dword ptr [ebp - 0x10] */ 4620 eax = MEM32(ebp + (-0x10)); /* 0x380024A9: mov eax, dword ptr [ebp - 0x10] */ 4621 PUSH32(esp, eax); /* 0x380024AC: push eax */ 4622 PUSH32(esp, ecx); /* 0x380024AD: push ecx */ 4623 PUSH32(esp, edx); /* 0x380024AE: push edx */ 4624 ecx = esi; /* 0x380024AF: mov ecx, esi */ 4625 RECOMP_ICALL(0x38002170u); /* 0x380024B1: call 0x38002170 */ /* not lifted */ 4626 RECOMP_FLAGS_IN(); 4627 /* test LO8(eax), LO8(eax) */ /* 0x380024B6: test al, al */ 4628 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4629 _cf = 0; 4630 _flag_k = FK_NARROW(FK_TEST, 24); 4631 if (TEST_Z(_flag_a, _flag_b)) goto L_380024D2; /* 0x380024B8: je 0x380024d2 */ 4632 L_380024BA: 4633 ecx = MEM32(ebp + (-0x34)); /* 0x380024BA: mov ecx, dword ptr [ebp - 0x34] */ 4634 edx = MEM32(ebp + (-0x30)); /* 0x380024BD: mov edx, dword ptr [ebp - 0x30] */ 4635 eax = edi; /* 0x380024C0: mov eax, edi */ 4636 MEM32(eax) = ecx; /* 0x380024C2: mov dword ptr [eax], ecx */ 4637 ecx = MEM32(ebp + (-0x2C)); /* 0x380024C4: mov ecx, dword ptr [ebp - 0x2c] */ 4638 MEM32(eax + 0x4) = edx; /* 0x380024C7: mov dword ptr [eax + 4], edx */ 4639 MEM32(eax + 0x8) = ecx; /* 0x380024CA: mov dword ptr [eax + 8], ecx */ 4640 goto L_380026E7; /* 0x380024CD: jmp 0x380026e7 */ 4641 L_380024D2: 4642 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x380024D2: fld dword ptr [ebp - 0x34] */ 4643 _st[0] = -_st[0]; /* 0x380024D5: fchs */ 4644 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x68)) = _v; } /* 0x380024D7: fstp dword ptr [ebp - 0x68] */ 4645 fp_push(*(float*)&MEM32(ebp + (-0x30))); /* 0x380024DA: fld dword ptr [ebp - 0x30] */ 4646 edx = MEM32(ebp + (-0x68)); /* 0x380024DD: mov edx, dword ptr [ebp - 0x68] */ 4647 _st[0] = -_st[0]; /* 0x380024E0: fchs */ 4648 MEM32(ebp + (-0x98)) = edx; /* 0x380024E2: mov dword ptr [ebp - 0x98], edx */ 4649 edx = MEM32(ebp + (-0x10)); /* 0x380024E8: mov edx, dword ptr [ebp - 0x10] */ 4650 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x64)) = _v; } /* 0x380024EB: fstp dword ptr [ebp - 0x64] */ 4651 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x380024EE: fld dword ptr [ebp - 0x2c] */ 4652 eax = MEM32(ebp + (-0x64)); /* 0x380024F1: mov eax, dword ptr [ebp - 0x64] */ 4653 _st[0] = -_st[0]; /* 0x380024F4: fchs */ 4654 MEM32(ebp + (-0x94)) = eax; /* 0x380024F6: mov dword ptr [ebp - 0x94], eax */ 4655 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x60)) = _v; } /* 0x380024FC: fstp dword ptr [ebp - 0x60] */ 4656 ecx = MEM32(ebp + (-0x60)); /* 0x380024FF: mov ecx, dword ptr [ebp - 0x60] */ 4657 PUSH32(esp, edx); /* 0x38002502: push edx */ 4658 MEM32(ebp + (-0x90)) = ecx; /* 0x38002503: mov dword ptr [ebp - 0x90], ecx */ 4659 eax = ebp + (-0x98); /* 0x38002509: lea eax, [ebp - 0x98] */ 4660 PUSH32(esp, eax); /* 0x3800250F: push eax */ 4661 ecx = ebp + (-0xC); /* 0x38002510: lea ecx, [ebp - 0xc] */ 4662 PUSH32(esp, ecx); /* 0x38002513: push ecx */ 4663 ecx = esi; /* 0x38002514: mov ecx, esi */ 4664 RECOMP_ICALL(0x38002170u); /* 0x38002516: call 0x38002170 */ /* not lifted */ 4665 RECOMP_FLAGS_IN(); 4666 /* test LO8(eax), LO8(eax) */ /* 0x3800251B: test al, al */ 4667 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4668 _cf = 0; 4669 _flag_k = FK_NARROW(FK_TEST, 24); 4670 if (TEST_Z(_flag_a, _flag_b)) goto L_3800256D; /* 0x3800251D: je 0x3800256d */ 4671 L_3800251F: 4672 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x3800251F: fld dword ptr [ebp - 0x34] */ 4673 edx = MEM32(ebp + (-0x34)); /* 0x38002522: mov edx, dword ptr [ebp - 0x34] */ 4674 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002525: fmul dword ptr [0x3804e8e0] */ 4675 eax = MEM32(ebp + (-0x30)); /* 0x3800252B: mov eax, dword ptr [ebp - 0x30] */ 4676 ecx = MEM32(ebp + (-0x2C)); /* 0x3800252E: mov ecx, dword ptr [ebp - 0x2c] */ 4677 MEM32(ebp + (-0x50)) = edx; /* 0x38002531: mov dword ptr [ebp - 0x50], edx */ 4678 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x50)) = _v; } /* 0x38002534: fstp dword ptr [ebp - 0x50] */ 4679 MEM32(ebp + (-0x4C)) = eax; /* 0x38002537: mov dword ptr [ebp - 0x4c], eax */ 4680 fp_push(*(float*)&MEM32(ebp + (-0x4C))); /* 0x3800253A: fld dword ptr [ebp - 0x4c] */ 4681 eax = MEM32(ebp + (-0x50)); /* 0x3800253D: mov eax, dword ptr [ebp - 0x50] */ 4682 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002540: fmul dword ptr [0x3804e8e0] */ 4683 MEM32(ebp + (-0x48)) = ecx; /* 0x38002546: mov dword ptr [ebp - 0x48], ecx */ 4684 edx = edi; /* 0x38002549: mov edx, edi */ 4685 MEM32(edx) = eax; /* 0x3800254B: mov dword ptr [edx], eax */ 4686 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4C)) = _v; } /* 0x3800254D: fstp dword ptr [ebp - 0x4c] */ 4687 ecx = MEM32(ebp + (-0x4C)); /* 0x38002550: mov ecx, dword ptr [ebp - 0x4c] */ 4688 fp_push(*(float*)&MEM32(ebp + (-0x48))); /* 0x38002553: fld dword ptr [ebp - 0x48] */ 4689 MEM32(edx + 0x4) = ecx; /* 0x38002556: mov dword ptr [edx + 4], ecx */ 4690 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002559: fmul dword ptr [0x3804e8e0] */ 4691 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x48)) = _v; } /* 0x3800255F: fstp dword ptr [ebp - 0x48] */ 4692 eax = MEM32(ebp + (-0x48)); /* 0x38002562: mov eax, dword ptr [ebp - 0x48] */ 4693 MEM32(edx + 0x8) = eax; /* 0x38002565: mov dword ptr [edx + 8], eax */ 4694 goto L_380026E7; /* 0x38002568: jmp 0x380026e7 */ 4695 L_3800256D: 4696 ecx = MEM32(ebp + (-0x10)); /* 0x3800256D: mov ecx, dword ptr [ebp - 0x10] */ 4697 PUSH32(esp, ecx); /* 0x38002570: push ecx */ 4698 edx = ebp + (-0x1C); /* 0x38002571: lea edx, [ebp - 0x1c] */ 4699 PUSH32(esp, edx); /* 0x38002574: push edx */ 4700 eax = ebp + (-0xC); /* 0x38002575: lea eax, [ebp - 0xc] */ 4701 PUSH32(esp, eax); /* 0x38002578: push eax */ 4702 ecx = esi; /* 0x38002579: mov ecx, esi */ 4703 RECOMP_ICALL(0x38002170u); /* 0x3800257B: call 0x38002170 */ /* not lifted */ 4704 RECOMP_FLAGS_IN(); 4705 /* test LO8(eax), LO8(eax) */ /* 0x38002580: test al, al */ 4706 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4707 _cf = 0; 4708 _flag_k = FK_NARROW(FK_TEST, 24); 4709 if (TEST_Z(_flag_a, _flag_b)) goto L_3800259C; /* 0x38002582: je 0x3800259c */ 4710 L_38002584: 4711 edx = MEM32(ebp + (-0x1C)); /* 0x38002584: mov edx, dword ptr [ebp - 0x1c] */ 4712 eax = MEM32(ebp + (-0x18)); /* 0x38002587: mov eax, dword ptr [ebp - 0x18] */ 4713 ecx = edi; /* 0x3800258A: mov ecx, edi */ 4714 MEM32(ecx) = edx; /* 0x3800258C: mov dword ptr [ecx], edx */ 4715 edx = MEM32(ebp + (-0x14)); /* 0x3800258E: mov edx, dword ptr [ebp - 0x14] */ 4716 MEM32(ecx + 0x4) = eax; /* 0x38002591: mov dword ptr [ecx + 4], eax */ 4717 MEM32(ecx + 0x8) = edx; /* 0x38002594: mov dword ptr [ecx + 8], edx */ 4718 goto L_380026E7; /* 0x38002597: jmp 0x380026e7 */ 4719 L_3800259C: 4720 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x3800259C: fld dword ptr [ebp - 0x1c] */ 4721 _st[0] = -_st[0]; /* 0x3800259F: fchs */ 4722 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x380025A1: fstp dword ptr [ebp - 0x28] */ 4723 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x380025A4: fld dword ptr [ebp - 0x18] */ 4724 eax = MEM32(ebp + (-0x28)); /* 0x380025A7: mov eax, dword ptr [ebp - 0x28] */ 4725 _st[0] = -_st[0]; /* 0x380025AA: fchs */ 4726 MEM32(ebp + (-0x8C)) = eax; /* 0x380025AC: mov dword ptr [ebp - 0x8c], eax */ 4727 eax = MEM32(ebp + (-0x10)); /* 0x380025B2: mov eax, dword ptr [ebp - 0x10] */ 4728 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x380025B5: fstp dword ptr [ebp - 0x24] */ 4729 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x380025B8: fld dword ptr [ebp - 0x14] */ 4730 ecx = MEM32(ebp + (-0x24)); /* 0x380025BB: mov ecx, dword ptr [ebp - 0x24] */ 4731 _st[0] = -_st[0]; /* 0x380025BE: fchs */ 4732 MEM32(ebp + (-0x88)) = ecx; /* 0x380025C0: mov dword ptr [ebp - 0x88], ecx */ 4733 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x380025C6: fstp dword ptr [ebp - 0x20] */ 4734 edx = MEM32(ebp + (-0x20)); /* 0x380025C9: mov edx, dword ptr [ebp - 0x20] */ 4735 PUSH32(esp, eax); /* 0x380025CC: push eax */ 4736 ecx = ebp + (-0x8C); /* 0x380025CD: lea ecx, [ebp - 0x8c] */ 4737 MEM32(ebp + (-0x84)) = edx; /* 0x380025D3: mov dword ptr [ebp - 0x84], edx */ 4738 PUSH32(esp, ecx); /* 0x380025D9: push ecx */ 4739 edx = ebp + (-0xC); /* 0x380025DA: lea edx, [ebp - 0xc] */ 4740 PUSH32(esp, edx); /* 0x380025DD: push edx */ 4741 ecx = esi; /* 0x380025DE: mov ecx, esi */ 4742 RECOMP_ICALL(0x38002170u); /* 0x380025E0: call 0x38002170 */ /* not lifted */ 4743 RECOMP_FLAGS_IN(); 4744 /* test LO8(eax), LO8(eax) */ /* 0x380025E5: test al, al */ 4745 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4746 _cf = 0; 4747 _flag_k = FK_NARROW(FK_TEST, 24); 4748 if (TEST_Z(_flag_a, _flag_b)) goto L_38002637; /* 0x380025E7: je 0x38002637 */ 4749 L_380025E9: 4750 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x380025E9: fld dword ptr [ebp - 0x1c] */ 4751 eax = MEM32(ebp + (-0x1C)); /* 0x380025EC: mov eax, dword ptr [ebp - 0x1c] */ 4752 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x380025EF: fmul dword ptr [0x3804e8e0] */ 4753 ecx = MEM32(ebp + (-0x18)); /* 0x380025F5: mov ecx, dword ptr [ebp - 0x18] */ 4754 edx = MEM32(ebp + (-0x14)); /* 0x380025F8: mov edx, dword ptr [ebp - 0x14] */ 4755 MEM32(ebp + (-0x5C)) = eax; /* 0x380025FB: mov dword ptr [ebp - 0x5c], eax */ 4756 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x5C)) = _v; } /* 0x380025FE: fstp dword ptr [ebp - 0x5c] */ 4757 MEM32(ebp + (-0x58)) = ecx; /* 0x38002601: mov dword ptr [ebp - 0x58], ecx */ 4758 fp_push(*(float*)&MEM32(ebp + (-0x58))); /* 0x38002604: fld dword ptr [ebp - 0x58] */ 4759 ecx = MEM32(ebp + (-0x5C)); /* 0x38002607: mov ecx, dword ptr [ebp - 0x5c] */ 4760 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x3800260A: fmul dword ptr [0x3804e8e0] */ 4761 MEM32(ebp + (-0x54)) = edx; /* 0x38002610: mov dword ptr [ebp - 0x54], edx */ 4762 eax = edi; /* 0x38002613: mov eax, edi */ 4763 MEM32(eax) = ecx; /* 0x38002615: mov dword ptr [eax], ecx */ 4764 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x58)) = _v; } /* 0x38002617: fstp dword ptr [ebp - 0x58] */ 4765 edx = MEM32(ebp + (-0x58)); /* 0x3800261A: mov edx, dword ptr [ebp - 0x58] */ 4766 fp_push(*(float*)&MEM32(ebp + (-0x54))); /* 0x3800261D: fld dword ptr [ebp - 0x54] */ 4767 MEM32(eax + 0x4) = edx; /* 0x38002620: mov dword ptr [eax + 4], edx */ 4768 _st[0] *= (double)*(float*)ADDR(0x3804E8E0); /* 0x38002623: fmul dword ptr [0x3804e8e0] */ 4769 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x54)) = _v; } /* 0x38002629: fstp dword ptr [ebp - 0x54] */ 4770 ecx = MEM32(ebp + (-0x54)); /* 0x3800262C: mov ecx, dword ptr [ebp - 0x54] */ 4771 MEM32(eax + 0x8) = ecx; /* 0x3800262F: mov dword ptr [eax + 8], ecx */ 4772 goto L_380026E7; /* 0x38002632: jmp 0x380026e7 */ 4773 L_38002637: 4774 edx = MEM32(ebp + (-0x10)); /* 0x38002637: mov edx, dword ptr [ebp - 0x10] */ 4775 PUSH32(esp, edx); /* 0x3800263A: push edx */ 4776 eax = ebp + (-0x40); /* 0x3800263B: lea eax, [ebp - 0x40] */ 4777 PUSH32(esp, eax); /* 0x3800263E: push eax */ 4778 ecx = ebp + (-0xC); /* 0x3800263F: lea ecx, [ebp - 0xc] */ 4779 PUSH32(esp, ecx); /* 0x38002642: push ecx */ 4780 ecx = esi; /* 0x38002643: mov ecx, esi */ 4781 RECOMP_ICALL(0x38002170u); /* 0x38002645: call 0x38002170 */ /* not lifted */ 4782 RECOMP_FLAGS_IN(); 4783 /* test LO8(eax), LO8(eax) */ /* 0x3800264A: test al, al */ 4784 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4785 _cf = 0; 4786 _flag_k = FK_NARROW(FK_TEST, 24); 4787 if (TEST_Z(_flag_a, _flag_b)) goto L_38002666; /* 0x3800264C: je 0x38002666 */ 4788 L_3800264E: 4789 eax = MEM32(ebp + (-0x40)); /* 0x3800264E: mov eax, dword ptr [ebp - 0x40] */ 4790 ecx = MEM32(ebp + (-0x3C)); /* 0x38002651: mov ecx, dword ptr [ebp - 0x3c] */ 4791 edx = edi; /* 0x38002654: mov edx, edi */ 4792 MEM32(edx) = eax; /* 0x38002656: mov dword ptr [edx], eax */ 4793 eax = MEM32(ebp + (-0x38)); /* 0x38002658: mov eax, dword ptr [ebp - 0x38] */ 4794 MEM32(edx + 0x4) = ecx; /* 0x3800265B: mov dword ptr [edx + 4], ecx */ 4795 MEM32(edx + 0x8) = eax; /* 0x3800265E: mov dword ptr [edx + 8], eax */ 4796 goto L_380026E7; /* 0x38002661: jmp 0x380026e7 */ 4797 L_38002666: 4798 fp_push(*(float*)&MEM32(ebp + (-0x38))); /* 0x38002666: fld dword ptr [ebp - 0x38] */ 4799 PUSH32(esp, ecx); /* 0x38002669: push ecx */ 4800 _st[0] = -_st[0]; /* 0x3800266A: fchs */ 4801 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x3800266C: fstp dword ptr [esp] */ 4802 PUSH32(esp, ecx); /* 0x3800266F: push ecx */ 4803 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x38002670: fld dword ptr [ebp - 0x3c] */ 4804 _st[0] = -_st[0]; /* 0x38002673: fchs */ 4805 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38002675: fstp dword ptr [esp] */ 4806 PUSH32(esp, ecx); /* 0x38002678: push ecx */ 4807 fp_push(*(float*)&MEM32(ebp + (-0x40))); /* 0x38002679: fld dword ptr [ebp - 0x40] */ 4808 ecx = ebp + (-0xA4); /* 0x3800267C: lea ecx, [ebp - 0xa4] */ 4809 _st[0] = -_st[0]; /* 0x38002682: fchs */ 4810 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38002684: fstp dword ptr [esp] */ 4811 RECOMP_ICALL(MEM32(0x3804E4D8)); /* 0x38002687: call dword ptr [0x3804e4d8] */ 4812 RECOMP_FLAGS_IN(); 4813 ecx = MEM32(eax); /* 0x3800268D: mov ecx, dword ptr [eax] */ 4814 MEM32(ebp + (-0x80)) = ecx; /* 0x3800268F: mov dword ptr [ebp - 0x80], ecx */ 4815 edx = MEM32(eax + 0x4); /* 0x38002692: mov edx, dword ptr [eax + 4] */ 4816 ecx = MEM32(ebp + (-0x10)); /* 0x38002695: mov ecx, dword ptr [ebp - 0x10] */ 4817 MEM32(ebp + (-0x7C)) = edx; /* 0x38002698: mov dword ptr [ebp - 0x7c], edx */ 4818 eax = MEM32(eax + 0x8); /* 0x3800269B: mov eax, dword ptr [eax + 8] */ 4819 PUSH32(esp, ecx); /* 0x3800269E: push ecx */ 4820 edx = ebp + (-0x80); /* 0x3800269F: lea edx, [ebp - 0x80] */ 4821 MEM32(ebp + (-0x78)) = eax; /* 0x380026A2: mov dword ptr [ebp - 0x78], eax */ 4822 PUSH32(esp, edx); /* 0x380026A5: push edx */ 4823 eax = ebp + (-0xC); /* 0x380026A6: lea eax, [ebp - 0xc] */ 4824 PUSH32(esp, eax); /* 0x380026A9: push eax */ 4825 ecx = esi; /* 0x380026AA: mov ecx, esi */ 4826 RECOMP_ICALL(0x38002170u); /* 0x380026AC: call 0x38002170 */ /* not lifted */ 4827 RECOMP_FLAGS_IN(); 4828 /* test LO8(eax), LO8(eax) */ /* 0x380026B1: test al, al */ 4829 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 4830 _cf = 0; 4831 _flag_k = FK_NARROW(FK_TEST, 24); 4832 if (TEST_Z(_flag_a, _flag_b)) goto L_380026E9; /* 0x380026B3: je 0x380026e9 */ 4833 L_380026B5: 4834 ecx = MEM32(ebp + (-0x40)); /* 0x380026B5: mov ecx, dword ptr [ebp - 0x40] */ 4835 edx = MEM32(ebp + (-0x3C)); /* 0x380026B8: mov edx, dword ptr [ebp - 0x3c] */ 4836 eax = MEM32(ebp + (-0x38)); /* 0x380026BB: mov eax, dword ptr [ebp - 0x38] */ 4837 MEM32(ebp + (-0x74)) = ecx; /* 0x380026BE: mov dword ptr [ebp - 0x74], ecx */ 4838 PUSH32(esp, 0xBF800000u); /* 0x380026C1: push 0xbf800000 */ 4839 ecx = ebp + (-0x74); /* 0x380026C6: lea ecx, [ebp - 0x74] */ 4840 MEM32(ebp + (-0x70)) = edx; /* 0x380026C9: mov dword ptr [ebp - 0x70], edx */ 4841 MEM32(ebp + (-0x6C)) = eax; /* 0x380026CC: mov dword ptr [ebp - 0x6c], eax */ 4842 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x380026CF: call dword ptr [0x3804e4d4] */ 4843 RECOMP_FLAGS_IN(); 4844 edx = MEM32(eax); /* 0x380026D5: mov edx, dword ptr [eax] */ 4845 ecx = edi; /* 0x380026D7: mov ecx, edi */ 4846 MEM32(ecx) = edx; /* 0x380026D9: mov dword ptr [ecx], edx */ 4847 edx = MEM32(eax + 0x4); /* 0x380026DB: mov edx, dword ptr [eax + 4] */ 4848 MEM32(ecx + 0x4) = edx; /* 0x380026DE: mov dword ptr [ecx + 4], edx */ 4849 eax = MEM32(eax + 0x8); /* 0x380026E1: mov eax, dword ptr [eax + 8] */ 4850 MEM32(ecx + 0x8) = eax; /* 0x380026E4: mov dword ptr [ecx + 8], eax */ 4851 L_380026E7: 4852 SET_LO8(ebx, 1); /* 0x380026E7: mov bl, 1 */ 4853 L_380026E9: 4854 eax = MEM32(ebp + (-0x44)); /* 0x380026E9: mov eax, dword ptr [ebp - 0x44] */ 4855 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(2); 4856 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 4857 eax = eax + 2; /* 0x380026EC: add eax, 2 */ 4858 _flag_k = FK_ADD; 4859 /* cmp eax, 8 */ /* 0x380026EF: cmp eax, 8 */ 4860 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(8); 4861 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4862 _flag_k = FK_CMP; 4863 MEM32(ebp + (-0x44)) = eax; /* 0x380026F2: mov dword ptr [ebp - 0x44], eax */ 4864 RECOMP_BACKEDGE(); 4865 if (CMP_L(_flag_a, _flag_b)) goto L_3800246E; /* 0x380026F5: jl 0x3800246e */ 4866 L_380026FB: 4867 /* test LO8(ebx), LO8(ebx) */ /* 0x380026FB: test bl, bl */ 4868 _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24; 4869 _cf = 0; 4870 _flag_k = FK_NARROW(FK_TEST, 24); 4871 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002706; /* 0x380026FD: jne 0x38002706 */ 4872 L_380026FF: 4873 MEM8(esi + 0x1C5) = (uint8_t)(1); /* 0x380026FF: mov byte ptr [esi + 0x1c5], 1 */ 4874 L_38002706: 4875 edi = POP32_VAL(esp); /* 0x38002706: pop edi */ 4876 esi = POP32_VAL(esp); /* 0x38002707: pop esi */ 4877 ebx = POP32_VAL(esp); /* 0x38002708: pop ebx */ 4878 esp = ebp; /* 0x38002709: mov esp, ebp */ 4879 ebp = POP32_VAL(esp); /* 0x3800270B: pop ebp */ 4880 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800270C: ret */ 4881 RECOMP_REGS_OUT(); 4882 } 4883 4884 void sub_38002706(void) { 4885 int _fpu_cmp = 0; 4886 uint32_t _cf = 0; 4887 int _df = 1; 4888 uint32_t _flag_k = FK_NONE; 4889 uint32_t _flag_a = 0, _flag_b = 0; 4890 uint32_t _itail_tgt = 0; 4891 RECOMP_REGS_LOCALS 4892 RECOMP_ENTER(0x38002706u); 4893 4894 L_38002706: 4895 edi = POP32_VAL(esp); /* 0x38002706: pop edi */ 4896 esi = POP32_VAL(esp); /* 0x38002707: pop esi */ 4897 ebx = POP32_VAL(esp); /* 0x38002708: pop ebx */ 4898 esp = ebp; /* 0x38002709: mov esp, ebp */ 4899 ebp = POP32_VAL(esp); /* 0x3800270B: pop ebp */ 4900 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3800270C: ret */ 4901 RECOMP_REGS_OUT(); 4902 } 4903 4904 void sub_38002710(void) { 4905 int _fpu_cmp = 0; 4906 uint32_t _cf = 0; 4907 int _df = 1; 4908 uint32_t _flag_k = FK_NONE; 4909 uint32_t _flag_a = 0, _flag_b = 0; 4910 uint32_t _itail_tgt = 0; 4911 RECOMP_REGS_LOCALS 4912 RECOMP_ENTER(0x38002710u); 4913 4914 L_38002710: 4915 SET_LO8(eax, 1); /* 0x38002710: mov al, 1 */ 4916 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38002712: ret */ 4917 RECOMP_REGS_OUT(); 4918 } 4919 4920 void sub_38002720(void) { 4921 int _fpu_cmp = 0; 4922 uint32_t _cf = 0; 4923 int _df = 1; 4924 uint32_t _flag_k = FK_NONE; 4925 uint32_t _flag_a = 0, _flag_b = 0; 4926 uint32_t _itail_tgt = 0; 4927 RECOMP_REGS_LOCALS 4928 RECOMP_ENTER(0x38002720u); 4929 4930 L_38002720: 4931 PUSH32(esp, ebp); /* 0x38002720: push ebp */ 4932 ebp = esp; /* 0x38002721: mov ebp, esp */ 4933 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x30u); 4934 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4935 esp = esp - 0x30u; /* 0x38002723: sub esp, 0x30 */ 4936 _flag_k = FK_CMP; 4937 PUSH32(esp, esi); /* 0x38002726: push esi */ 4938 eax = ebp + (-0x24); /* 0x38002727: lea eax, [ebp - 0x24] */ 4939 esi = ecx; /* 0x3800272A: mov esi, ecx */ 4940 PUSH32(esp, eax); /* 0x3800272C: push eax */ 4941 RECOMP_ICALL(0x38001F50u); /* 0x3800272D: call 0x38001f50 */ /* not lifted */ 4942 RECOMP_FLAGS_IN(); 4943 ecx = MEM32(eax); /* 0x38002732: mov ecx, dword ptr [eax] */ 4944 edx = MEM32(eax + 0x4); /* 0x38002734: mov edx, dword ptr [eax + 4] */ 4945 eax = MEM32(eax + 0x8); /* 0x38002737: mov eax, dword ptr [eax + 8] */ 4946 MEM32(ebp + (-0xC)) = ecx; /* 0x3800273A: mov dword ptr [ebp - 0xc], ecx */ 4947 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3800273D: fld dword ptr [ebp - 0xc] */ 4948 _st[0] -= (double)*(float*)ADDR(esi + 0x54); /* 0x38002740: fsub dword ptr [esi + 0x54] */ 4949 SET_LO8(ecx, MEM8(0x3806E98C)); /* 0x38002743: mov cl, byte ptr [0x3806e98c] */ 4950 MEM32(ebp + (-0x8)) = edx; /* 0x38002749: mov dword ptr [ebp - 8], edx */ 4951 MEM32(ebp + (-0x4)) = eax; /* 0x3800274C: mov dword ptr [ebp - 4], eax */ 4952 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3800274F: fstp dword ptr [ebp - 0xc] */ 4953 SET_LO8(eax, 1); /* 0x38002752: mov al, 1 */ 4954 /* test LO8(eax), LO8(ecx) */ /* 0x38002754: test al, cl */ 4955 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24; 4956 _cf = 0; 4957 _flag_k = FK_NARROW(FK_TEST, 24); 4958 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x38002756: fld dword ptr [ebp - 8] */ 4959 _st[0] -= (double)*(float*)ADDR(esi + 0x58); /* 0x38002759: fsub dword ptr [esi + 0x58] */ 4960 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3800275C: fstp dword ptr [ebp - 8] */ 4961 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3800275F: fld dword ptr [ebp - 4] */ 4962 _st[0] -= (double)*(float*)ADDR(esi + 0x5C); /* 0x38002762: fsub dword ptr [esi + 0x5c] */ 4963 { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x38002765: fst dword ptr [ebp - 4] */ 4964 _st[0] *= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x38002768: fmul dword ptr [ebp - 4] */ 4965 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3800276B: fld dword ptr [ebp - 8] */ 4966 _st[0] *= (double)*(float*)ADDR(ebp + (-0x8)); /* 0x3800276E: fmul dword ptr [ebp - 8] */ 4967 { double _v = fp_pop(); _st[0] += _v; } /* 0x38002771: faddp st(1) */ 4968 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x38002773: fld dword ptr [ebp - 0xc] */ 4969 _st[0] *= (double)*(float*)ADDR(ebp + (-0xC)); /* 0x38002776: fmul dword ptr [ebp - 0xc] */ 4970 { double _v = fp_pop(); _st[0] += _v; } /* 0x38002779: faddp st(1) */ 4971 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800278F; /* 0x3800277B: jne 0x3800278f */ 4972 L_3800277D: 4973 _flag_a = (uint32_t)((LO8(ecx) | LO8(eax))) << 24; _flag_b = (uint32_t)((LO8(ecx) | LO8(eax))) << 24; 4974 SET_LO8(ecx, LO8(ecx) | LO8(eax)); /* 0x3800277D: or cl, al */ 4975 _cf = 0; 4976 _flag_k = FK_NARROW(FK_TEST, 24); 4977 MEM8(0x3806E98C) = (uint8_t)(LO8(ecx)); /* 0x3800277F: mov byte ptr [0x3806e98c], cl */ 4978 MEM32(0x3806E988) = 0x46AFC800u; /* 0x38002785: mov dword ptr [0x3806e988], 0x46afc800 */ 4979 L_3800278F: 4980 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E8)); /* 0x3800278F: fcom dword ptr [0x3804e8e8] */ 4981 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002795: fnstsw ax */ 4982 /* test HI8(eax), 0x41u */ /* 0x38002797: test ah, 0x41 */ 4983 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 4984 _cf = 0; 4985 _flag_k = FK_NARROW(FK_TEST, 24); 4986 if (TEST_NZ(_flag_a, _flag_b)) goto L_380027AC; /* 0x3800279A: jne 0x380027ac */ 4987 L_3800279C: 4988 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3800279C: fld dword ptr [ebp + 8] */ 4989 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x3800279F: fcomp dword ptr [0x3804e8e4] */ 4990 fp_pop(); 4991 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380027A5: fnstsw ax */ 4992 /* test HI8(eax), 0x41u */ /* 0x380027A7: test ah, 0x41 */ 4993 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 4994 _cf = 0; 4995 _flag_k = FK_NARROW(FK_TEST, 24); 4996 if (TEST_Z(_flag_a, _flag_b)) goto L_380027D3; /* 0x380027AA: je 0x380027d3 */ 4997 L_380027AC: 4998 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3806E988)); /* 0x380027AC: fcomp dword ptr [0x3806e988] */ 4999 fp_pop(); 5000 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380027B2: fnstsw ax */ 5001 /* test HI8(eax), 1 */ /* 0x380027B4: test ah, 1 */ 5002 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 5003 _cf = 0; 5004 _flag_k = FK_NARROW(FK_TEST, 24); 5005 if (TEST_Z(_flag_a, _flag_b)) goto L_38002869; /* 0x380027B7: je 0x38002869 */ 5006 L_380027BD: 5007 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x380027BD: fld dword ptr [ebp + 8] */ 5008 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x380027C0: fcomp dword ptr [0x3804e8e4] */ 5009 fp_pop(); 5010 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380027C6: fnstsw ax */ 5011 /* test HI8(eax), 1 */ /* 0x380027C8: test ah, 1 */ 5012 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 5013 _cf = 0; 5014 _flag_k = FK_NARROW(FK_TEST, 24); 5015 if (TEST_Z(_flag_a, _flag_b)) goto L_38002869; /* 0x380027CB: je 0x38002869 */ 5016 L_380027D1: 5017 goto L_380027D5; /* 0x380027D1: jmp 0x380027d5 */ 5018 L_380027D3: 5019 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x380027D3: fstp st(0) */ 5020 L_380027D5: 5021 fp_push(*(float*)&MEM32(esi + 0x194)); /* 0x380027D5: fld dword ptr [esi + 0x194] */ 5022 ecx = MEM32(ebp + (-0xC)); /* 0x380027DB: mov ecx, dword ptr [ebp - 0xc] */ 5023 edx = MEM32(ebp + (-0x8)); /* 0x380027DE: mov edx, dword ptr [ebp - 8] */ 5024 eax = MEM32(ebp + (-0x4)); /* 0x380027E1: mov eax, dword ptr [ebp - 4] */ 5025 _st[0] += _st[0]; /* 0x380027E4: fadd st(0), st(0) */ 5026 MEM32(ebp + (-0x18)) = ecx; /* 0x380027E6: mov dword ptr [ebp - 0x18], ecx */ 5027 MEM32(ebp + (-0x14)) = edx; /* 0x380027E9: mov dword ptr [ebp - 0x14], edx */ 5028 fp_push(_st[0]); /* 0x380027EC: fld st(0) */ 5029 _st[0] *= (double)*(float*)ADDR(ebp + (-0xC)); /* 0x380027EE: fmul dword ptr [ebp - 0xc] */ 5030 MEM32(ebp + (-0x10)) = eax; /* 0x380027F1: mov dword ptr [ebp - 0x10], eax */ 5031 ecx = ebp + (-0x30); /* 0x380027F4: lea ecx, [ebp - 0x30] */ 5032 PUSH32(esp, ecx); /* 0x380027F7: push ecx */ 5033 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x380027F8: fstp dword ptr [ebp - 0x18] */ 5034 ecx = esi; /* 0x380027FB: mov ecx, esi */ 5035 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x380027FD: fld dword ptr [ebp - 0x14] */ 5036 _st[0] *= _st[1]; /* 0x38002800: fmul st(1) */ 5037 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002802: fstp dword ptr [ebp - 0x14] */ 5038 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38002805: fld dword ptr [ebp - 0x10] */ 5039 _st[0] *= _st[1]; /* 0x38002808: fmul st(1) */ 5040 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3800280A: fstp dword ptr [ebp - 0x10] */ 5041 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3800280D: fstp st(0) */ 5042 RECOMP_ICALL(0x38001F50u); /* 0x3800280F: call 0x38001f50 */ /* not lifted */ 5043 RECOMP_FLAGS_IN(); 5044 edx = MEM32(eax); /* 0x38002814: mov edx, dword ptr [eax] */ 5045 ecx = MEM32(eax + 0x4); /* 0x38002816: mov ecx, dword ptr [eax + 4] */ 5046 MEM32(ebp + (-0xC)) = edx; /* 0x38002819: mov dword ptr [ebp - 0xc], edx */ 5047 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3800281C: fld dword ptr [ebp - 0xc] */ 5048 _st[0] += (double)*(float*)ADDR(ebp + (-0x18)); /* 0x3800281F: fadd dword ptr [ebp - 0x18] */ 5049 edx = MEM32(eax + 0x8); /* 0x38002822: mov edx, dword ptr [eax + 8] */ 5050 MEM32(ebp + (-0x8)) = ecx; /* 0x38002825: mov dword ptr [ebp - 8], ecx */ 5051 MEM32(ebp + (-0x4)) = edx; /* 0x38002828: mov dword ptr [ebp - 4], edx */ 5052 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3800282B: fstp dword ptr [ebp - 0xc] */ 5053 eax = MEM32(ebp + (-0xC)); /* 0x3800282E: mov eax, dword ptr [ebp - 0xc] */ 5054 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x38002831: fld dword ptr [ebp - 8] */ 5055 MEM32(ebp + (-0x24)) = eax; /* 0x38002834: mov dword ptr [ebp - 0x24], eax */ 5056 _st[0] += (double)*(float*)ADDR(ebp + (-0x14)); /* 0x38002837: fadd dword ptr [ebp - 0x14] */ 5057 eax = MEM32(ebp + 0xC); /* 0x3800283A: mov eax, dword ptr [ebp + 0xc] */ 5058 PUSH32(esp, eax); /* 0x3800283D: push eax */ 5059 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3800283E: fstp dword ptr [ebp - 8] */ 5060 ecx = MEM32(ebp + (-0x8)); /* 0x38002841: mov ecx, dword ptr [ebp - 8] */ 5061 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x38002844: fld dword ptr [ebp - 4] */ 5062 MEM32(ebp + (-0x20)) = ecx; /* 0x38002847: mov dword ptr [ebp - 0x20], ecx */ 5063 _st[0] += (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3800284A: fadd dword ptr [ebp - 0x10] */ 5064 ecx = ebp + (-0x24); /* 0x3800284D: lea ecx, [ebp - 0x24] */ 5065 PUSH32(esp, ecx); /* 0x38002850: push ecx */ 5066 ecx = esi; /* 0x38002851: mov ecx, esi */ 5067 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x38002853: fstp dword ptr [ebp - 4] */ 5068 edx = MEM32(ebp + (-0x4)); /* 0x38002856: mov edx, dword ptr [ebp - 4] */ 5069 MEM32(ebp + (-0x1C)) = edx; /* 0x38002859: mov dword ptr [ebp - 0x1c], edx */ 5070 RECOMP_ICALL(MEM32(0x3804E6E8)); /* 0x3800285C: call dword ptr [0x3804e6e8] */ 5071 RECOMP_FLAGS_IN(); 5072 esi = POP32_VAL(esp); /* 0x38002862: pop esi */ 5073 esp = ebp; /* 0x38002863: mov esp, ebp */ 5074 ebp = POP32_VAL(esp); /* 0x38002865: pop ebp */ 5075 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x38002866: ret 8 */ 5076 L_38002869: 5077 edx = MEM32(ebp + 0xC); /* 0x38002869: mov edx, dword ptr [ebp + 0xc] */ 5078 PUSH32(esp, edx); /* 0x3800286C: push edx */ 5079 ecx = esi; /* 0x3800286D: mov ecx, esi */ 5080 RECOMP_ICALL(MEM32(0x3804E6EC)); /* 0x3800286F: call dword ptr [0x3804e6ec] */ 5081 RECOMP_FLAGS_IN(); 5082 esi = POP32_VAL(esp); /* 0x38002875: pop esi */ 5083 esp = ebp; /* 0x38002876: mov esp, ebp */ 5084 ebp = POP32_VAL(esp); /* 0x38002878: pop ebp */ 5085 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x38002879: ret 8 */ 5086 RECOMP_REGS_OUT(); 5087 } 5088 5089 void sub_380027D5(void) { 5090 int _fpu_cmp = 0; 5091 uint32_t _cf = 0; 5092 int _df = 1; 5093 uint32_t _flag_k = FK_NONE; 5094 uint32_t _flag_a = 0, _flag_b = 0; 5095 uint32_t _itail_tgt = 0; 5096 RECOMP_REGS_LOCALS 5097 RECOMP_ENTER(0x380027D5u); 5098 5099 L_380027D5: 5100 fp_push(*(float*)&MEM32(esi + 0x194)); /* 0x380027D5: fld dword ptr [esi + 0x194] */ 5101 ecx = MEM32(ebp + (-0xC)); /* 0x380027DB: mov ecx, dword ptr [ebp - 0xc] */ 5102 edx = MEM32(ebp + (-0x8)); /* 0x380027DE: mov edx, dword ptr [ebp - 8] */ 5103 eax = MEM32(ebp + (-0x4)); /* 0x380027E1: mov eax, dword ptr [ebp - 4] */ 5104 _st[0] += _st[0]; /* 0x380027E4: fadd st(0), st(0) */ 5105 MEM32(ebp + (-0x18)) = ecx; /* 0x380027E6: mov dword ptr [ebp - 0x18], ecx */ 5106 MEM32(ebp + (-0x14)) = edx; /* 0x380027E9: mov dword ptr [ebp - 0x14], edx */ 5107 fp_push(_st[0]); /* 0x380027EC: fld st(0) */ 5108 _st[0] *= (double)*(float*)ADDR(ebp + (-0xC)); /* 0x380027EE: fmul dword ptr [ebp - 0xc] */ 5109 MEM32(ebp + (-0x10)) = eax; /* 0x380027F1: mov dword ptr [ebp - 0x10], eax */ 5110 ecx = ebp + (-0x30); /* 0x380027F4: lea ecx, [ebp - 0x30] */ 5111 PUSH32(esp, ecx); /* 0x380027F7: push ecx */ 5112 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x380027F8: fstp dword ptr [ebp - 0x18] */ 5113 ecx = esi; /* 0x380027FB: mov ecx, esi */ 5114 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x380027FD: fld dword ptr [ebp - 0x14] */ 5115 _st[0] *= _st[1]; /* 0x38002800: fmul st(1) */ 5116 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002802: fstp dword ptr [ebp - 0x14] */ 5117 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38002805: fld dword ptr [ebp - 0x10] */ 5118 _st[0] *= _st[1]; /* 0x38002808: fmul st(1) */ 5119 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3800280A: fstp dword ptr [ebp - 0x10] */ 5120 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3800280D: fstp st(0) */ 5121 RECOMP_ICALL(0x38001F50u); /* 0x3800280F: call 0x38001f50 */ /* not lifted */ 5122 RECOMP_FLAGS_IN(); 5123 edx = MEM32(eax); /* 0x38002814: mov edx, dword ptr [eax] */ 5124 ecx = MEM32(eax + 0x4); /* 0x38002816: mov ecx, dword ptr [eax + 4] */ 5125 MEM32(ebp + (-0xC)) = edx; /* 0x38002819: mov dword ptr [ebp - 0xc], edx */ 5126 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3800281C: fld dword ptr [ebp - 0xc] */ 5127 _st[0] += (double)*(float*)ADDR(ebp + (-0x18)); /* 0x3800281F: fadd dword ptr [ebp - 0x18] */ 5128 edx = MEM32(eax + 0x8); /* 0x38002822: mov edx, dword ptr [eax + 8] */ 5129 MEM32(ebp + (-0x8)) = ecx; /* 0x38002825: mov dword ptr [ebp - 8], ecx */ 5130 MEM32(ebp + (-0x4)) = edx; /* 0x38002828: mov dword ptr [ebp - 4], edx */ 5131 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3800282B: fstp dword ptr [ebp - 0xc] */ 5132 eax = MEM32(ebp + (-0xC)); /* 0x3800282E: mov eax, dword ptr [ebp - 0xc] */ 5133 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x38002831: fld dword ptr [ebp - 8] */ 5134 MEM32(ebp + (-0x24)) = eax; /* 0x38002834: mov dword ptr [ebp - 0x24], eax */ 5135 _st[0] += (double)*(float*)ADDR(ebp + (-0x14)); /* 0x38002837: fadd dword ptr [ebp - 0x14] */ 5136 eax = MEM32(ebp + 0xC); /* 0x3800283A: mov eax, dword ptr [ebp + 0xc] */ 5137 PUSH32(esp, eax); /* 0x3800283D: push eax */ 5138 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3800283E: fstp dword ptr [ebp - 8] */ 5139 ecx = MEM32(ebp + (-0x8)); /* 0x38002841: mov ecx, dword ptr [ebp - 8] */ 5140 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x38002844: fld dword ptr [ebp - 4] */ 5141 MEM32(ebp + (-0x20)) = ecx; /* 0x38002847: mov dword ptr [ebp - 0x20], ecx */ 5142 _st[0] += (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3800284A: fadd dword ptr [ebp - 0x10] */ 5143 ecx = ebp + (-0x24); /* 0x3800284D: lea ecx, [ebp - 0x24] */ 5144 PUSH32(esp, ecx); /* 0x38002850: push ecx */ 5145 ecx = esi; /* 0x38002851: mov ecx, esi */ 5146 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x38002853: fstp dword ptr [ebp - 4] */ 5147 edx = MEM32(ebp + (-0x4)); /* 0x38002856: mov edx, dword ptr [ebp - 4] */ 5148 MEM32(ebp + (-0x1C)) = edx; /* 0x38002859: mov dword ptr [ebp - 0x1c], edx */ 5149 RECOMP_ICALL(MEM32(0x3804E6E8)); /* 0x3800285C: call dword ptr [0x3804e6e8] */ 5150 RECOMP_FLAGS_IN(); 5151 esi = POP32_VAL(esp); /* 0x38002862: pop esi */ 5152 esp = ebp; /* 0x38002863: mov esp, ebp */ 5153 ebp = POP32_VAL(esp); /* 0x38002865: pop ebp */ 5154 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x38002866: ret 8 */ 5155 RECOMP_REGS_OUT(); 5156 } 5157 5158 void sub_38002880(void) { 5159 int _fpu_cmp = 0; 5160 uint32_t _cf = 0; 5161 int _df = 1; 5162 uint32_t _flag_k = FK_NONE; 5163 uint32_t _flag_a = 0, _flag_b = 0; 5164 uint32_t _itail_tgt = 0; 5165 RECOMP_REGS_LOCALS 5166 RECOMP_ENTER(0x38002880u); 5167 5168 L_38002880: 5169 PUSH32(esp, ebp); /* 0x38002880: push ebp */ 5170 ebp = esp; /* 0x38002881: mov ebp, esp */ 5171 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x7Cu); 5172 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 5173 esp = esp - 0x7Cu; /* 0x38002883: sub esp, 0x7c */ 5174 _flag_k = FK_CMP; 5175 PUSH32(esp, esi); /* 0x38002886: push esi */ 5176 eax = ebp + (-0x6C); /* 0x38002887: lea eax, [ebp - 0x6c] */ 5177 esi = ecx; /* 0x3800288A: mov esi, ecx */ 5178 PUSH32(esp, eax); /* 0x3800288C: push eax */ 5179 RECOMP_ICALL(0x38001F50u); /* 0x3800288D: call 0x38001f50 */ /* not lifted */ 5180 RECOMP_FLAGS_IN(); 5181 ecx = MEM32(eax); /* 0x38002892: mov ecx, dword ptr [eax] */ 5182 edx = MEM32(eax + 0x4); /* 0x38002894: mov edx, dword ptr [eax + 4] */ 5183 eax = MEM32(eax + 0x8); /* 0x38002897: mov eax, dword ptr [eax + 8] */ 5184 MEM32(ebp + (-0x40)) = eax; /* 0x3800289A: mov dword ptr [ebp - 0x40], eax */ 5185 eax = esi + 0x54; /* 0x3800289D: lea eax, [esi + 0x54] */ 5186 MEM32(ebp + (-0x48)) = ecx; /* 0x380028A0: mov dword ptr [ebp - 0x48], ecx */ 5187 PUSH32(esp, eax); /* 0x380028A3: push eax */ 5188 ecx = ebp + (-0x48); /* 0x380028A4: lea ecx, [ebp - 0x48] */ 5189 MEM32(ebp + (-0x44)) = edx; /* 0x380028A7: mov dword ptr [ebp - 0x44], edx */ 5190 RECOMP_ICALL(MEM32(0x3804E4F4)); /* 0x380028AA: call dword ptr [0x3804e4f4] */ 5191 RECOMP_FLAGS_IN(); 5192 ecx = MEM32(eax); /* 0x380028B0: mov ecx, dword ptr [eax] */ 5193 MEM32(ebp + (-0x24)) = ecx; /* 0x380028B2: mov dword ptr [ebp - 0x24], ecx */ 5194 edx = MEM32(eax + 0x4); /* 0x380028B5: mov edx, dword ptr [eax + 4] */ 5195 MEM32(ebp + (-0x20)) = edx; /* 0x380028B8: mov dword ptr [ebp - 0x20], edx */ 5196 eax = MEM32(eax + 0x8); /* 0x380028BB: mov eax, dword ptr [eax + 8] */ 5197 ecx = ebp + (-0x24); /* 0x380028BE: lea ecx, [ebp - 0x24] */ 5198 MEM32(ebp + (-0x1C)) = eax; /* 0x380028C1: mov dword ptr [ebp - 0x1c], eax */ 5199 RECOMP_ICALL(MEM32(0x3804E4F0)); /* 0x380028C4: call dword ptr [0x3804e4f0] */ 5200 RECOMP_FLAGS_IN(); 5201 _st[0] = sqrt(_st[0]); /* 0x380028CA: fsqrt */ 5202 ecx = esi; /* 0x380028CC: mov ecx, esi */ 5203 _st[0] = (double)*(float*)ADDR(0x3804E8CC) / _st[0]; /* 0x380028CE: fdivr dword ptr [0x3804e8cc] */ 5204 fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x380028D4: fld dword ptr [ebp - 0x24] */ 5205 _st[0] *= _st[1]; /* 0x380028D7: fmul st(1) */ 5206 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x380028D9: fstp dword ptr [ebp - 0x24] */ 5207 fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x380028DC: fld dword ptr [ebp - 0x20] */ 5208 _st[0] *= _st[1]; /* 0x380028DF: fmul st(1) */ 5209 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x380028E1: fstp dword ptr [ebp - 0x20] */ 5210 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x380028E4: fld dword ptr [ebp - 0x1c] */ 5211 _st[0] *= _st[1]; /* 0x380028E7: fmul st(1) */ 5212 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x380028E9: fstp dword ptr [ebp - 0x1c] */ 5213 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x380028EC: fstp st(0) */ 5214 RECOMP_ICALL(0x380041C0u); /* 0x380028EE: call 0x380041c0 */ /* not lifted */ 5215 RECOMP_FLAGS_IN(); 5216 /* test LO8(eax), LO8(eax) */ /* 0x380028F3: test al, al */ 5217 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 5218 _cf = 0; 5219 _flag_k = FK_NARROW(FK_TEST, 24); 5220 if (TEST_Z(_flag_a, _flag_b)) goto L_3800290E; /* 0x380028F5: je 0x3800290e */ 5221 L_380028F7: 5222 eax = MEM32(ebp + 0x8); /* 0x380028F7: mov eax, dword ptr [ebp + 8] */ 5223 ecx = MEM32(esi + 0x17C); /* 0x380028FA: mov ecx, dword ptr [esi + 0x17c] */ 5224 edx = MEM32(ecx); /* 0x38002900: mov edx, dword ptr [ecx] */ 5225 PUSH32(esp, eax); /* 0x38002902: push eax */ 5226 PUSH32(esp, esi); /* 0x38002903: push esi */ 5227 RECOMP_ICALL(MEM32(edx + 0x4)); /* 0x38002904: call dword ptr [edx + 4] */ 5228 RECOMP_FLAGS_IN(); 5229 esi = POP32_VAL(esp); /* 0x38002907: pop esi */ 5230 esp = ebp; /* 0x38002908: mov esp, ebp */ 5231 ebp = POP32_VAL(esp); /* 0x3800290A: pop ebp */ 5232 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800290B: ret 4 */ 5233 L_3800290E: 5234 fp_push(*(float*)&MEM32(esi + 0x194)); /* 0x3800290E: fld dword ptr [esi + 0x194] */ 5235 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38002914: fcomp dword ptr [0x3804e8e4] */ 5236 fp_pop(); 5237 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3800291A: fnstsw ax */ 5238 /* test HI8(eax), 0x40u */ /* 0x3800291C: test ah, 0x40 */ 5239 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 5240 _cf = 0; 5241 _flag_k = FK_NARROW(FK_TEST, 24); 5242 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800293F; /* 0x3800291F: jne 0x3800293f */ 5243 L_38002921: 5244 ecx = MEM32(esi + 0x194); /* 0x38002921: mov ecx, dword ptr [esi + 0x194] */ 5245 edx = MEM32(ebp + 0x8); /* 0x38002927: mov edx, dword ptr [ebp + 8] */ 5246 eax = ecx; /* 0x3800292A: mov eax, ecx */ 5247 PUSH32(esp, edx); /* 0x3800292C: push edx */ 5248 MEM32(ebp + (-0x8)) = ecx; /* 0x3800292D: mov dword ptr [ebp - 8], ecx */ 5249 PUSH32(esp, eax); /* 0x38002930: push eax */ 5250 ecx = esi; /* 0x38002931: mov ecx, esi */ 5251 RECOMP_ICALL(0x38002720u); /* 0x38002933: call 0x38002720 */ /* not lifted */ 5252 RECOMP_FLAGS_IN(); 5253 esi = POP32_VAL(esp); /* 0x38002938: pop esi */ 5254 esp = ebp; /* 0x38002939: mov esp, ebp */ 5255 ebp = POP32_VAL(esp); /* 0x3800293B: pop ebp */ 5256 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800293C: ret 4 */ 5257 L_3800293F: 5258 ecx = MEM32(ebp + 0x8); /* 0x3800293F: mov ecx, dword ptr [ebp + 8] */ 5259 PUSH32(esp, ecx); /* 0x38002942: push ecx */ 5260 ecx = esi; /* 0x38002943: mov ecx, esi */ 5261 RECOMP_ICALL(0x38003B40u); /* 0x38002945: call 0x38003b40 */ /* not lifted */ 5262 RECOMP_FLAGS_IN(); 5263 /* test eax, eax */ /* 0x3800294A: test eax, eax */ 5264 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 5265 _cf = 0; 5266 _flag_k = FK_TEST; 5267 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002F8B; /* 0x3800294C: jne 0x38002f8b */ 5268 L_38002952: 5269 MEM32(ebp + (-0x18)) = eax; /* 0x38002952: mov dword ptr [ebp - 0x18], eax */ 5270 MEM32(ebp + (-0x14)) = eax; /* 0x38002955: mov dword ptr [ebp - 0x14], eax */ 5271 MEM32(ebp + (-0x10)) = eax; /* 0x38002958: mov dword ptr [ebp - 0x10], eax */ 5272 SET_LO8(eax, MEM8(esi + 0x1A9)); /* 0x3800295B: mov al, byte ptr [esi + 0x1a9] */ 5273 /* test LO8(eax), LO8(eax) */ /* 0x38002961: test al, al */ 5274 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 5275 _cf = 0; 5276 _flag_k = FK_NARROW(FK_TEST, 24); 5277 PUSH32(esp, edi); /* 0x38002963: push edi */ 5278 if (TEST_Z(_flag_a, _flag_b)) goto L_38002C9C; /* 0x38002964: je 0x38002c9c */ 5279 L_3800296A: 5280 SET_LO8(eax, MEM8(esi + 0x1A8)); /* 0x3800296A: mov al, byte ptr [esi + 0x1a8] */ 5281 /* test LO8(eax), LO8(eax) */ /* 0x38002970: test al, al */ 5282 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 5283 _cf = 0; 5284 _flag_k = FK_NARROW(FK_TEST, 24); 5285 if (TEST_Z(_flag_a, _flag_b)) goto L_38002C9C; /* 0x38002972: je 0x38002c9c */ 5286 L_38002978: 5287 edx = MEM32(esi + 0x58); /* 0x38002978: mov edx, dword ptr [esi + 0x58] */ 5288 PUSH32(esp, ebx); /* 0x3800297B: push ebx */ 5289 eax = ebp + (-0x6C); /* 0x3800297C: lea eax, [ebp - 0x6c] */ 5290 PUSH32(esp, eax); /* 0x3800297F: push eax */ 5291 ecx = esi; /* 0x38002980: mov ecx, esi */ 5292 MEM32(ebp + (-0xC)) = edx; /* 0x38002982: mov dword ptr [ebp - 0xc], edx */ 5293 RECOMP_ICALL(0x38001F50u); /* 0x38002985: call 0x38001f50 */ /* not lifted */ 5294 RECOMP_FLAGS_IN(); 5295 ecx = MEM32(eax); /* 0x3800298A: mov ecx, dword ptr [eax] */ 5296 edx = MEM32(eax + 0x4); /* 0x3800298C: mov edx, dword ptr [eax + 4] */ 5297 eax = MEM32(eax + 0x8); /* 0x3800298F: mov eax, dword ptr [eax + 8] */ 5298 MEM32(ebp + (-0x48)) = ecx; /* 0x38002992: mov dword ptr [ebp - 0x48], ecx */ 5299 edi = esi + 0x1AC; /* 0x38002995: lea edi, [esi + 0x1ac] */ 5300 PUSH32(esp, edi); /* 0x3800299B: push edi */ 5301 ecx = ebp + (-0x48); /* 0x3800299C: lea ecx, [ebp - 0x48] */ 5302 MEM32(ebp + (-0x44)) = edx; /* 0x3800299F: mov dword ptr [ebp - 0x44], edx */ 5303 MEM32(ebp + (-0x40)) = eax; /* 0x380029A2: mov dword ptr [ebp - 0x40], eax */ 5304 RECOMP_ICALL(MEM32(0x3804E4F4)); /* 0x380029A5: call dword ptr [0x3804e4f4] */ 5305 RECOMP_FLAGS_IN(); 5306 ecx = MEM32(eax); /* 0x380029AB: mov ecx, dword ptr [eax] */ 5307 MEM32(ebp + (-0x3C)) = ecx; /* 0x380029AD: mov dword ptr [ebp - 0x3c], ecx */ 5308 edx = MEM32(eax + 0x4); /* 0x380029B0: mov edx, dword ptr [eax + 4] */ 5309 MEM32(ebp + (-0x38)) = edx; /* 0x380029B3: mov dword ptr [ebp - 0x38], edx */ 5310 eax = MEM32(eax + 0x8); /* 0x380029B6: mov eax, dword ptr [eax + 8] */ 5311 ecx = ebp + (-0x3C); /* 0x380029B9: lea ecx, [ebp - 0x3c] */ 5312 MEM32(ebp + (-0x34)) = eax; /* 0x380029BC: mov dword ptr [ebp - 0x34], eax */ 5313 RECOMP_ICALL(MEM32(0x3804E4F0)); /* 0x380029BF: call dword ptr [0x3804e4f0] */ 5314 RECOMP_FLAGS_IN(); 5315 _st[0] = sqrt(_st[0]); /* 0x380029C5: fsqrt */ 5316 ecx = ebp + (-0x6C); /* 0x380029C7: lea ecx, [ebp - 0x6c] */ 5317 PUSH32(esp, ecx); /* 0x380029CA: push ecx */ 5318 ecx = esi; /* 0x380029CB: mov ecx, esi */ 5319 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x380029CD: fmul dword ptr [0x3804e8bc] */ 5320 _st[0] += (double)*(float*)ADDR(esi + 0x174); /* 0x380029D3: fadd dword ptr [esi + 0x174] */ 5321 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x380029D9: fstp dword ptr [ebp - 4] */ 5322 RECOMP_ICALL(0x38001F50u); /* 0x380029DC: call 0x38001f50 */ /* not lifted */ 5323 RECOMP_FLAGS_IN(); 5324 edx = MEM32(eax); /* 0x380029E1: mov edx, dword ptr [eax] */ 5325 ecx = MEM32(eax + 0x4); /* 0x380029E3: mov ecx, dword ptr [eax + 4] */ 5326 MEM32(ebp + (-0x30)) = edx; /* 0x380029E6: mov dword ptr [ebp - 0x30], edx */ 5327 edx = MEM32(eax + 0x8); /* 0x380029E9: mov edx, dword ptr [eax + 8] */ 5328 MEM32(ebp + (-0x2C)) = ecx; /* 0x380029EC: mov dword ptr [ebp - 0x2c], ecx */ 5329 PUSH32(esp, edi); /* 0x380029EF: push edi */ 5330 ecx = ebp + (-0x30); /* 0x380029F0: lea ecx, [ebp - 0x30] */ 5331 MEM32(ebp + (-0x28)) = edx; /* 0x380029F3: mov dword ptr [ebp - 0x28], edx */ 5332 RECOMP_ICALL(MEM32(0x3804E4F4)); /* 0x380029F6: call dword ptr [0x3804e4f4] */ 5333 RECOMP_FLAGS_IN(); 5334 ecx = eax; /* 0x380029FC: mov ecx, eax */ 5335 ebx = MEM32(eax); /* 0x380029FE: mov ebx, dword ptr [eax] */ 5336 edx = MEM32(eax + 0x4); /* 0x38002A00: mov edx, dword ptr [eax + 4] */ 5337 eax = MEM32(eax + 0x8); /* 0x38002A03: mov eax, dword ptr [eax + 8] */ 5338 MEM32(ebp + (-0x3C)) = ebx; /* 0x38002A06: mov dword ptr [ebp - 0x3c], ebx */ 5339 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x38002A09: fld dword ptr [ebp - 0x3c] */ 5340 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38002A0C: fcomp dword ptr [0x3804e8e4] */ 5341 fp_pop(); 5342 MEM32(ebp + (-0x34)) = eax; /* 0x38002A12: mov dword ptr [ebp - 0x34], eax */ 5343 MEM32(ebp + (-0x38)) = edx; /* 0x38002A15: mov dword ptr [ebp - 0x38], edx */ 5344 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002A18: fnstsw ax */ 5345 /* test HI8(eax), 0x40u */ /* 0x38002A1A: test ah, 0x40 */ 5346 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 5347 _cf = 0; 5348 _flag_k = FK_NARROW(FK_TEST, 24); 5349 if (TEST_Z(_flag_a, _flag_b)) goto L_38002A65; /* 0x38002A1D: je 0x38002a65 */ 5350 L_38002A1F: 5351 fp_push(*(float*)&MEM32(ebp + (-0x38))); /* 0x38002A1F: fld dword ptr [ebp - 0x38] */ 5352 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38002A22: fcomp dword ptr [0x3804e8e4] */ 5353 fp_pop(); 5354 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002A28: fnstsw ax */ 5355 /* test HI8(eax), 0x40u */ /* 0x38002A2A: test ah, 0x40 */ 5356 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 5357 _cf = 0; 5358 _flag_k = FK_NARROW(FK_TEST, 24); 5359 if (TEST_Z(_flag_a, _flag_b)) goto L_38002A65; /* 0x38002A2D: je 0x38002a65 */ 5360 L_38002A2F: 5361 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x38002A2F: fld dword ptr [ebp - 0x34] */ 5362 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38002A32: fcomp dword ptr [0x3804e8e4] */ 5363 fp_pop(); 5364 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002A38: fnstsw ax */ 5365 /* test HI8(eax), 0x40u */ /* 0x38002A3A: test ah, 0x40 */ 5366 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 5367 _cf = 0; 5368 _flag_k = FK_NARROW(FK_TEST, 24); 5369 if (TEST_Z(_flag_a, _flag_b)) goto L_38002A65; /* 0x38002A3D: je 0x38002a65 */ 5370 L_38002A3F: 5371 MEM32(ebp + (-0x2C)) = 0; /* 0x38002A3F: mov dword ptr [ebp - 0x2c], 0 */ 5372 ecx = MEM32(ebp + (-0x2C)); /* 0x38002A46: mov ecx, dword ptr [ebp - 0x2c] */ 5373 MEM32(ebp + (-0x28)) = 0x3F800000u; /* 0x38002A49: mov dword ptr [ebp - 0x28], 0x3f800000 */ 5374 edx = MEM32(ebp + (-0x28)); /* 0x38002A50: mov edx, dword ptr [ebp - 0x28] */ 5375 MEM32(ebp + (-0x30)) = 0; /* 0x38002A53: mov dword ptr [ebp - 0x30], 0 */ 5376 ebx = MEM32(ebp + (-0x30)); /* 0x38002A5A: mov ebx, dword ptr [ebp - 0x30] */ 5377 MEM32(ebp + (-0x38)) = ecx; /* 0x38002A5D: mov dword ptr [ebp - 0x38], ecx */ 5378 MEM32(ebp + (-0x34)) = edx; /* 0x38002A60: mov dword ptr [ebp - 0x34], edx */ 5379 goto L_38002A8C; /* 0x38002A63: jmp 0x38002a8c */ 5380 L_38002A65: 5381 eax = MEM32(ecx); /* 0x38002A65: mov eax, dword ptr [ecx] */ 5382 edx = MEM32(ecx + 0x4); /* 0x38002A67: mov edx, dword ptr [ecx + 4] */ 5383 MEM32(ebp + (-0x48)) = eax; /* 0x38002A6A: mov dword ptr [ebp - 0x48], eax */ 5384 eax = MEM32(ecx + 0x8); /* 0x38002A6D: mov eax, dword ptr [ecx + 8] */ 5385 ecx = ebp + (-0x48); /* 0x38002A70: lea ecx, [ebp - 0x48] */ 5386 MEM32(ebp + (-0x44)) = edx; /* 0x38002A73: mov dword ptr [ebp - 0x44], edx */ 5387 MEM32(ebp + (-0x40)) = eax; /* 0x38002A76: mov dword ptr [ebp - 0x40], eax */ 5388 RECOMP_ICALL(MEM32(0x3804E4EC)); /* 0x38002A79: call dword ptr [0x3804e4ec] */ 5389 RECOMP_FLAGS_IN(); 5390 PUSH32(esp, ecx); /* 0x38002A7F: push ecx */ 5391 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38002A80: fstp dword ptr [esp] */ 5392 ecx = ebp + (-0x48); /* 0x38002A83: lea ecx, [ebp - 0x48] */ 5393 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x38002A86: call dword ptr [0x3804e4d4] */ 5394 RECOMP_FLAGS_IN(); 5395 L_38002A8C: 5396 ecx = ebp + (-0x6C); /* 0x38002A8C: lea ecx, [ebp - 0x6c] */ 5397 PUSH32(esp, ecx); /* 0x38002A8F: push ecx */ 5398 ecx = esi; /* 0x38002A90: mov ecx, esi */ 5399 RECOMP_ICALL(0x38001F50u); /* 0x38002A92: call 0x38001f50 */ /* not lifted */ 5400 RECOMP_FLAGS_IN(); 5401 edx = MEM32(eax); /* 0x38002A97: mov edx, dword ptr [eax] */ 5402 ecx = MEM32(eax + 0x4); /* 0x38002A99: mov ecx, dword ptr [eax + 4] */ 5403 MEM32(ebp + (-0x48)) = edx; /* 0x38002A9C: mov dword ptr [ebp - 0x48], edx */ 5404 edx = MEM32(eax + 0x8); /* 0x38002A9F: mov edx, dword ptr [eax + 8] */ 5405 MEM32(ebp + (-0x44)) = ecx; /* 0x38002AA2: mov dword ptr [ebp - 0x44], ecx */ 5406 PUSH32(esp, edi); /* 0x38002AA5: push edi */ 5407 ecx = ebp + (-0x48); /* 0x38002AA6: lea ecx, [ebp - 0x48] */ 5408 MEM32(ebp + (-0x40)) = edx; /* 0x38002AA9: mov dword ptr [ebp - 0x40], edx */ 5409 RECOMP_ICALL(MEM32(0x3804E4E8)); /* 0x38002AAC: call dword ptr [0x3804e4e8] */ 5410 RECOMP_FLAGS_IN(); 5411 ecx = MEM32(eax); /* 0x38002AB2: mov ecx, dword ptr [eax] */ 5412 edx = MEM32(eax + 0x4); /* 0x38002AB4: mov edx, dword ptr [eax + 4] */ 5413 eax = MEM32(eax + 0x8); /* 0x38002AB7: mov eax, dword ptr [eax + 8] */ 5414 MEM32(ebp + (-0x30)) = ecx; /* 0x38002ABA: mov dword ptr [ebp - 0x30], ecx */ 5415 fp_push(*(float*)&MEM32(ebp + (-0x30))); /* 0x38002ABD: fld dword ptr [ebp - 0x30] */ 5416 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002AC0: fmul dword ptr [0x3804e8bc] */ 5417 MEM32(ebp + (-0x2C)) = edx; /* 0x38002AC6: mov dword ptr [ebp - 0x2c], edx */ 5418 MEM32(ebp + (-0x28)) = eax; /* 0x38002AC9: mov dword ptr [ebp - 0x28], eax */ 5419 ecx = ebp + (-0x78); /* 0x38002ACC: lea ecx, [ebp - 0x78] */ 5420 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x30)) = _v; } /* 0x38002ACF: fstp dword ptr [ebp - 0x30] */ 5421 PUSH32(esp, ecx); /* 0x38002AD2: push ecx */ 5422 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x38002AD3: fld dword ptr [ebp - 0x2c] */ 5423 ecx = esi; /* 0x38002AD6: mov ecx, esi */ 5424 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002AD8: fmul dword ptr [0x3804e8bc] */ 5425 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x2C)) = _v; } /* 0x38002ADE: fstp dword ptr [ebp - 0x2c] */ 5426 fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x38002AE1: fld dword ptr [ebp - 0x28] */ 5427 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002AE4: fmul dword ptr [0x3804e8bc] */ 5428 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x38002AEA: fstp dword ptr [ebp - 0x28] */ 5429 RECOMP_ICALL(0x38001F50u); /* 0x38002AED: call 0x38001f50 */ /* not lifted */ 5430 RECOMP_FLAGS_IN(); 5431 ecx = esi; /* 0x38002AF2: mov ecx, esi */ 5432 edi = eax; /* 0x38002AF4: mov edi, eax */ 5433 RECOMP_ICALL(MEM32(0x3804E6DC)); /* 0x38002AF6: call dword ptr [0x3804e6dc] */ 5434 RECOMP_FLAGS_IN(); 5435 edx = MEM32(edi); /* 0x38002AFC: mov edx, dword ptr [edi] */ 5436 ecx = MEM32(edi + 0x4); /* 0x38002AFE: mov ecx, dword ptr [edi + 4] */ 5437 MEM32(ebp + (-0x54)) = edx; /* 0x38002B01: mov dword ptr [ebp - 0x54], edx */ 5438 edx = MEM32(edi + 0x8); /* 0x38002B04: mov edx, dword ptr [edi + 8] */ 5439 MEM32(ebp + (-0x50)) = ecx; /* 0x38002B07: mov dword ptr [ebp - 0x50], ecx */ 5440 PUSH32(esp, eax); /* 0x38002B0A: push eax */ 5441 ecx = ebp + (-0x54); /* 0x38002B0B: lea ecx, [ebp - 0x54] */ 5442 MEM32(ebp + (-0x4C)) = edx; /* 0x38002B0E: mov dword ptr [ebp - 0x4c], edx */ 5443 RECOMP_ICALL(MEM32(0x3804E4F4)); /* 0x38002B11: call dword ptr [0x3804e4f4] */ 5444 RECOMP_FLAGS_IN(); 5445 ecx = MEM32(eax); /* 0x38002B17: mov ecx, dword ptr [eax] */ 5446 edi = MEM32(ebp + (-0x38)); /* 0x38002B19: mov edi, dword ptr [ebp - 0x38] */ 5447 MEM32(ebp + (-0x60)) = ecx; /* 0x38002B1C: mov dword ptr [ebp - 0x60], ecx */ 5448 edx = MEM32(eax + 0x4); /* 0x38002B1F: mov edx, dword ptr [eax + 4] */ 5449 ecx = MEM32(ebp + (-0x34)); /* 0x38002B22: mov ecx, dword ptr [ebp - 0x34] */ 5450 MEM32(ebp + (-0x5C)) = edx; /* 0x38002B25: mov dword ptr [ebp - 0x5c], edx */ 5451 eax = MEM32(eax + 0x8); /* 0x38002B28: mov eax, dword ptr [eax + 8] */ 5452 edx = ebp + (-0x60); /* 0x38002B2B: lea edx, [ebp - 0x60] */ 5453 MEM32(ebp + (-0x64)) = ecx; /* 0x38002B2E: mov dword ptr [ebp - 0x64], ecx */ 5454 PUSH32(esp, edx); /* 0x38002B31: push edx */ 5455 ecx = ebp + (-0x6C); /* 0x38002B32: lea ecx, [ebp - 0x6c] */ 5456 MEM32(ebp + (-0x58)) = eax; /* 0x38002B35: mov dword ptr [ebp - 0x58], eax */ 5457 MEM32(ebp + (-0x6C)) = ebx; /* 0x38002B38: mov dword ptr [ebp - 0x6c], ebx */ 5458 MEM32(ebp + (-0x68)) = edi; /* 0x38002B3B: mov dword ptr [ebp - 0x68], edi */ 5459 RECOMP_ICALL(MEM32(0x3804E4C8)); /* 0x38002B3E: call dword ptr [0x3804e4c8] */ 5460 RECOMP_FLAGS_IN(); 5461 ecx = MEM32(eax); /* 0x38002B44: mov ecx, dword ptr [eax] */ 5462 edx = MEM32(eax + 0x4); /* 0x38002B46: mov edx, dword ptr [eax + 4] */ 5463 eax = MEM32(eax + 0x8); /* 0x38002B49: mov eax, dword ptr [eax + 8] */ 5464 MEM32(ebp + (-0x40)) = eax; /* 0x38002B4C: mov dword ptr [ebp - 0x40], eax */ 5465 fp_push(*(float*)&MEM32(ebp + (-0x40))); /* 0x38002B4F: fld dword ptr [ebp - 0x40] */ 5466 eax = MEM32(0x3804E6E0); /* 0x38002B52: mov eax, dword ptr [0x3804e6e0] */ 5467 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x38002B57: fmul dword ptr [eax + 8] */ 5468 MEM32(ebp + (-0x44)) = edx; /* 0x38002B5A: mov dword ptr [ebp - 0x44], edx */ 5469 fp_push(*(float*)&MEM32(ebp + (-0x44))); /* 0x38002B5D: fld dword ptr [ebp - 0x44] */ 5470 MEM32(ebp + (-0x48)) = ecx; /* 0x38002B60: mov dword ptr [ebp - 0x48], ecx */ 5471 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x38002B63: fmul dword ptr [eax + 4] */ 5472 { double _v = fp_pop(); _st[0] += _v; } /* 0x38002B66: faddp st(1) */ 5473 fp_push(*(float*)&MEM32(ebp + (-0x48))); /* 0x38002B68: fld dword ptr [ebp - 0x48] */ 5474 _st[0] *= (double)*(float*)ADDR(eax); /* 0x38002B6B: fmul dword ptr [eax] */ 5475 { double _v = fp_pop(); _st[0] += _v; } /* 0x38002B6D: faddp st(1) */ 5476 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38002B6F: fcomp dword ptr [0x3804e8e4] */ 5477 fp_pop(); 5478 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002B75: fnstsw ax */ 5479 /* test HI8(eax), 1 */ /* 0x38002B77: test ah, 1 */ 5480 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 5481 _cf = 0; 5482 _flag_k = FK_NARROW(FK_TEST, 24); 5483 if (TEST_Z(_flag_a, _flag_b)) goto L_38002B84; /* 0x38002B7A: je 0x38002b84 */ 5484 L_38002B7C: 5485 fp_push(*(float*)&MEM32(0x3804E908)); /* 0x38002B7C: fld dword ptr [0x3804e908] */ 5486 goto L_38002B8A; /* 0x38002B82: jmp 0x38002b8a */ 5487 L_38002B84: 5488 fp_push(*(float*)&MEM32(0x3804E904)); /* 0x38002B84: fld dword ptr [0x3804e904] */ 5489 L_38002B8A: 5490 fp_push(*(float*)&MEM32(0x3804E8D0)); /* 0x38002B8A: fld dword ptr [0x3804e8d0] */ 5491 MEM32(ebp + (-0x8)) = 0x40A00000u; /* 0x38002B90: mov dword ptr [ebp - 8], 0x40a00000 */ 5492 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ebp + (-0x4))); /* 0x38002B97: fcomp dword ptr [ebp - 4] */ 5493 fp_pop(); 5494 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002B9A: fnstsw ax */ 5495 /* test HI8(eax), 0x41u */ /* 0x38002B9C: test ah, 0x41 */ 5496 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 5497 _cf = 0; 5498 _flag_k = FK_NARROW(FK_TEST, 24); 5499 eax = ebp + (-0x8); /* 0x38002B9F: lea eax, [ebp - 8] */ 5500 if (TEST_Z(_flag_a, _flag_b)) goto L_38002BA7; /* 0x38002BA2: je 0x38002ba7 */ 5501 L_38002BA4: 5502 eax = ebp + (-0x4); /* 0x38002BA4: lea eax, [ebp - 4] */ 5503 L_38002BA7: 5504 fp_push(*(float*)&MEM32(0x3804E8D0)); /* 0x38002BA7: fld dword ptr [0x3804e8d0] */ 5505 _st[0] /= (double)*(float*)ADDR(eax); /* 0x38002BAD: fdiv dword ptr [eax] */ 5506 { double _v = fp_pop(); _st[0] *= _v; } /* 0x38002BAF: fmulp st(1) */ 5507 _st[0] *= (double)*(float*)ADDR(0x3804E900); /* 0x38002BB1: fmul dword ptr [0x3804e900] */ 5508 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38002BB7: fcom dword ptr [0x3804e8e4] */ 5509 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002BBD: fnstsw ax */ 5510 /* test HI8(eax), 1 */ /* 0x38002BBF: test ah, 1 */ 5511 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 5512 _cf = 0; 5513 _flag_k = FK_NARROW(FK_TEST, 24); 5514 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002BD9; /* 0x38002BC2: jne 0x38002bd9 */ 5515 L_38002BC4: 5516 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E8F8)); /* 0x38002BC4: fcom qword ptr [0x3804e8f8] */ 5517 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002BCA: fnstsw ax */ 5518 /* test HI8(eax), 1 */ /* 0x38002BCC: test ah, 1 */ 5519 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 5520 _cf = 0; 5521 _flag_k = FK_NARROW(FK_TEST, 24); 5522 if (TEST_Z(_flag_a, _flag_b)) goto L_38002BD9; /* 0x38002BCF: je 0x38002bd9 */ 5523 L_38002BD1: 5524 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002BD1: fmul dword ptr [0x3804e8bc] */ 5525 goto L_38002BFA; /* 0x38002BD7: jmp 0x38002bfa */ 5526 L_38002BD9: 5527 _st[0] *= (double)*(float*)ADDR(0x3804E8F4); /* 0x38002BD9: fmul dword ptr [0x3804e8f4] */ 5528 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8); 5529 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 5530 esp = esp - 8; /* 0x38002BDF: sub esp, 8 */ 5531 _flag_k = FK_CMP; 5532 { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x38002BE2: fst dword ptr [ebp - 8] */ 5533 { double _v = fp_pop(); *(double*)ADDR(esp) = _v; } /* 0x38002BE5: fstp qword ptr [esp] */ 5534 RECOMP_ICALL(MEM32(0x3804E0AC)); /* 0x38002BE8: call dword ptr [0x3804e0ac] */ 5535 RECOMP_FLAGS_IN(); 5536 _st[0] = (double)*(float*)ADDR(ebp + (-0x8)) - _st[0]; /* 0x38002BEE: fsubr dword ptr [ebp - 8] */ 5537 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8); 5538 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 5539 esp = esp + 8; /* 0x38002BF1: add esp, 8 */ 5540 _flag_k = FK_ADD; 5541 _st[0] *= (double)*(float*)ADDR(0x3804E8F0); /* 0x38002BF4: fmul dword ptr [0x3804e8f0] */ 5542 L_38002BFA: 5543 fp_push(_st[0]); /* 0x38002BFA: fld st(0) */ 5544 edx = MEM32(ebp + (-0x34)); /* 0x38002BFC: mov edx, dword ptr [ebp - 0x34] */ 5545 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x38002BFF: fsin */ 5546 eax = ebp + (-0x7C); /* 0x38002C01: lea eax, [ebp - 0x7c] */ 5547 PUSH32(esp, eax); /* 0x38002C04: push eax */ 5548 MEM32(ebp + (-0x6C)) = ebx; /* 0x38002C05: mov dword ptr [ebp - 0x6c], ebx */ 5549 MEM32(ebp + (-0x68)) = edi; /* 0x38002C08: mov dword ptr [ebp - 0x68], edi */ 5550 MEM32(ebp + (-0x64)) = edx; /* 0x38002C0B: mov dword ptr [ebp - 0x64], edx */ 5551 fp_push(*(float*)&MEM32(0x3804E8E4)); /* 0x38002C0E: fld dword ptr [0x3804e8e4] */ 5552 { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x38002C14: fst dword ptr [ebp - 8] */ 5553 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x7C)) = _v; } /* 0x38002C17: fstp dword ptr [ebp - 0x7c] */ 5554 ecx = MEM32(ebp + (-0x8)); /* 0x38002C1A: mov ecx, dword ptr [ebp - 8] */ 5555 MEM32(ebp + (-0x74)) = ecx; /* 0x38002C1D: mov dword ptr [ebp - 0x74], ecx */ 5556 ecx = ebp + (-0x6C); /* 0x38002C20: lea ecx, [ebp - 0x6c] */ 5557 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x78)) = _v; } /* 0x38002C23: fstp dword ptr [ebp - 0x78] */ 5558 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x38002C26: fcos */ 5559 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x70)) = _v; } /* 0x38002C28: fstp dword ptr [ebp - 0x70] */ 5560 RECOMP_ICALL(MEM32(0x3804E4E4)); /* 0x38002C2B: call dword ptr [0x3804e4e4] */ 5561 RECOMP_FLAGS_IN(); 5562 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x38002C31: fld dword ptr [ebp - 4] */ 5563 ecx = MEM32(eax); /* 0x38002C34: mov ecx, dword ptr [eax] */ 5564 edx = MEM32(eax + 0x4); /* 0x38002C36: mov edx, dword ptr [eax + 4] */ 5565 eax = MEM32(eax + 0x8); /* 0x38002C39: mov eax, dword ptr [eax + 8] */ 5566 PUSH32(esp, ecx); /* 0x38002C3C: push ecx */ 5567 MEM32(ebp + (-0x60)) = ecx; /* 0x38002C3D: mov dword ptr [ebp - 0x60], ecx */ 5568 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38002C40: fstp dword ptr [esp] */ 5569 ecx = ebp + (-0x60); /* 0x38002C43: lea ecx, [ebp - 0x60] */ 5570 MEM32(ebp + (-0x5C)) = edx; /* 0x38002C46: mov dword ptr [ebp - 0x5c], edx */ 5571 MEM32(ebp + (-0x58)) = eax; /* 0x38002C49: mov dword ptr [ebp - 0x58], eax */ 5572 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x38002C4C: call dword ptr [0x3804e4d4] */ 5573 RECOMP_FLAGS_IN(); 5574 ecx = MEM32(eax); /* 0x38002C52: mov ecx, dword ptr [eax] */ 5575 MEM32(ebp + (-0x6C)) = ecx; /* 0x38002C54: mov dword ptr [ebp - 0x6c], ecx */ 5576 edx = MEM32(eax + 0x4); /* 0x38002C57: mov edx, dword ptr [eax + 4] */ 5577 ecx = MEM32(ebp + (-0x30)); /* 0x38002C5A: mov ecx, dword ptr [ebp - 0x30] */ 5578 MEM32(ebp + (-0x68)) = edx; /* 0x38002C5D: mov dword ptr [ebp - 0x68], edx */ 5579 eax = MEM32(eax + 0x8); /* 0x38002C60: mov eax, dword ptr [eax + 8] */ 5580 edx = MEM32(ebp + (-0x2C)); /* 0x38002C63: mov edx, dword ptr [ebp - 0x2c] */ 5581 MEM32(ebp + (-0x54)) = ecx; /* 0x38002C66: mov dword ptr [ebp - 0x54], ecx */ 5582 ecx = ebp + (-0x6C); /* 0x38002C69: lea ecx, [ebp - 0x6c] */ 5583 MEM32(ebp + (-0x64)) = eax; /* 0x38002C6C: mov dword ptr [ebp - 0x64], eax */ 5584 eax = MEM32(ebp + (-0x28)); /* 0x38002C6F: mov eax, dword ptr [ebp - 0x28] */ 5585 PUSH32(esp, ecx); /* 0x38002C72: push ecx */ 5586 ecx = ebp + (-0x54); /* 0x38002C73: lea ecx, [ebp - 0x54] */ 5587 MEM32(ebp + (-0x50)) = edx; /* 0x38002C76: mov dword ptr [ebp - 0x50], edx */ 5588 MEM32(ebp + (-0x4C)) = eax; /* 0x38002C79: mov dword ptr [ebp - 0x4c], eax */ 5589 RECOMP_ICALL(MEM32(0x3804E4E8)); /* 0x38002C7C: call dword ptr [0x3804e4e8] */ 5590 RECOMP_FLAGS_IN(); 5591 edx = MEM32(eax); /* 0x38002C82: mov edx, dword ptr [eax] */ 5592 MEM32(ebp + (-0x18)) = edx; /* 0x38002C84: mov dword ptr [ebp - 0x18], edx */ 5593 ecx = MEM32(eax + 0x4); /* 0x38002C87: mov ecx, dword ptr [eax + 4] */ 5594 MEM32(ebp + (-0x14)) = ecx; /* 0x38002C8A: mov dword ptr [ebp - 0x14], ecx */ 5595 edx = MEM32(eax + 0x8); /* 0x38002C8D: mov edx, dword ptr [eax + 8] */ 5596 eax = MEM32(ebp + (-0xC)); /* 0x38002C90: mov eax, dword ptr [ebp - 0xc] */ 5597 MEM32(ebp + (-0x10)) = edx; /* 0x38002C93: mov dword ptr [ebp - 0x10], edx */ 5598 MEM32(ebp + (-0x14)) = eax; /* 0x38002C96: mov dword ptr [ebp - 0x14], eax */ 5599 ebx = POP32_VAL(esp); /* 0x38002C99: pop ebx */ 5600 goto L_38002D0F; /* 0x38002C9A: jmp 0x38002d0f */ 5601 L_38002C9C: 5602 ecx = MEM32(esi + 0x174); /* 0x38002C9C: mov ecx, dword ptr [esi + 0x174] */ 5603 edx = MEM32(ebp + (-0x24)); /* 0x38002CA2: mov edx, dword ptr [ebp - 0x24] */ 5604 eax = MEM32(ebp + (-0x20)); /* 0x38002CA5: mov eax, dword ptr [ebp - 0x20] */ 5605 MEM32(ebp + (-0xC)) = ecx; /* 0x38002CA8: mov dword ptr [ebp - 0xc], ecx */ 5606 ecx = MEM32(ebp + (-0x1C)); /* 0x38002CAB: mov ecx, dword ptr [ebp - 0x1c] */ 5607 MEM32(ebp + (-0x6C)) = edx; /* 0x38002CAE: mov dword ptr [ebp - 0x6c], edx */ 5608 edx = MEM32(ebp + (-0xC)); /* 0x38002CB1: mov edx, dword ptr [ebp - 0xc] */ 5609 MEM32(ebp + (-0x64)) = ecx; /* 0x38002CB4: mov dword ptr [ebp - 0x64], ecx */ 5610 PUSH32(esp, edx); /* 0x38002CB7: push edx */ 5611 ecx = ebp + (-0x6C); /* 0x38002CB8: lea ecx, [ebp - 0x6c] */ 5612 MEM32(ebp + (-0x68)) = eax; /* 0x38002CBB: mov dword ptr [ebp - 0x68], eax */ 5613 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x38002CBE: call dword ptr [0x3804e4d4] */ 5614 RECOMP_FLAGS_IN(); 5615 ecx = MEM32(eax); /* 0x38002CC4: mov ecx, dword ptr [eax] */ 5616 MEM32(ebp + (-0x60)) = ecx; /* 0x38002CC6: mov dword ptr [ebp - 0x60], ecx */ 5617 edx = MEM32(eax + 0x4); /* 0x38002CC9: mov edx, dword ptr [eax + 4] */ 5618 ecx = ebp + (-0x78); /* 0x38002CCC: lea ecx, [ebp - 0x78] */ 5619 MEM32(ebp + (-0x5C)) = edx; /* 0x38002CCF: mov dword ptr [ebp - 0x5c], edx */ 5620 eax = MEM32(eax + 0x8); /* 0x38002CD2: mov eax, dword ptr [eax + 8] */ 5621 PUSH32(esp, ecx); /* 0x38002CD5: push ecx */ 5622 ecx = esi; /* 0x38002CD6: mov ecx, esi */ 5623 MEM32(ebp + (-0x58)) = eax; /* 0x38002CD8: mov dword ptr [ebp - 0x58], eax */ 5624 RECOMP_ICALL(0x38001F50u); /* 0x38002CDB: call 0x38001f50 */ /* not lifted */ 5625 RECOMP_FLAGS_IN(); 5626 edx = MEM32(eax); /* 0x38002CE0: mov edx, dword ptr [eax] */ 5627 ecx = MEM32(eax + 0x4); /* 0x38002CE2: mov ecx, dword ptr [eax + 4] */ 5628 MEM32(ebp + (-0x54)) = edx; /* 0x38002CE5: mov dword ptr [ebp - 0x54], edx */ 5629 edx = MEM32(eax + 0x8); /* 0x38002CE8: mov edx, dword ptr [eax + 8] */ 5630 eax = ebp + (-0x60); /* 0x38002CEB: lea eax, [ebp - 0x60] */ 5631 MEM32(ebp + (-0x50)) = ecx; /* 0x38002CEE: mov dword ptr [ebp - 0x50], ecx */ 5632 PUSH32(esp, eax); /* 0x38002CF1: push eax */ 5633 ecx = ebp + (-0x54); /* 0x38002CF2: lea ecx, [ebp - 0x54] */ 5634 MEM32(ebp + (-0x4C)) = edx; /* 0x38002CF5: mov dword ptr [ebp - 0x4c], edx */ 5635 RECOMP_ICALL(MEM32(0x3804E4F4)); /* 0x38002CF8: call dword ptr [0x3804e4f4] */ 5636 RECOMP_FLAGS_IN(); 5637 ecx = MEM32(eax); /* 0x38002CFE: mov ecx, dword ptr [eax] */ 5638 MEM32(ebp + (-0x18)) = ecx; /* 0x38002D00: mov dword ptr [ebp - 0x18], ecx */ 5639 edx = MEM32(eax + 0x4); /* 0x38002D03: mov edx, dword ptr [eax + 4] */ 5640 MEM32(ebp + (-0x14)) = edx; /* 0x38002D06: mov dword ptr [ebp - 0x14], edx */ 5641 eax = MEM32(eax + 0x8); /* 0x38002D09: mov eax, dword ptr [eax + 8] */ 5642 MEM32(ebp + (-0x10)) = eax; /* 0x38002D0C: mov dword ptr [ebp - 0x10], eax */ 5643 L_38002D0F: 5644 SET_LO8(eax, MEM8(esi + 0x198)); /* 0x38002D0F: mov al, byte ptr [esi + 0x198] */ 5645 /* test LO8(eax), LO8(eax) */ /* 0x38002D15: test al, al */ 5646 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 5647 _cf = 0; 5648 _flag_k = FK_NARROW(FK_TEST, 24); 5649 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002D42; /* 0x38002D17: jne 0x38002d42 */ 5650 L_38002D19: 5651 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x38002D19: fld dword ptr [ebp - 0x18] */ 5652 _st[0] += (double)*(float*)ADDR(esi + 0x19C); /* 0x38002D1C: fadd dword ptr [esi + 0x19c] */ 5653 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x38002D22: fstp dword ptr [ebp - 0x18] */ 5654 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38002D25: fld dword ptr [ebp - 0x14] */ 5655 _st[0] += (double)*(float*)ADDR(esi + 0x1A0); /* 0x38002D28: fadd dword ptr [esi + 0x1a0] */ 5656 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002D2E: fstp dword ptr [ebp - 0x14] */ 5657 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38002D31: fld dword ptr [ebp - 0x10] */ 5658 _st[0] += (double)*(float*)ADDR(esi + 0x1A4); /* 0x38002D34: fadd dword ptr [esi + 0x1a4] */ 5659 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x38002D3A: fstp dword ptr [ebp - 0x10] */ 5660 goto L_38002E22; /* 0x38002D3D: jmp 0x38002e22 */ 5661 L_38002D42: 5662 edi = esi + 0x54; /* 0x38002D42: lea edi, [esi + 0x54] */ 5663 ecx = edi; /* 0x38002D45: mov ecx, edi */ 5664 edx = MEM32(ecx); /* 0x38002D47: mov edx, dword ptr [ecx] */ 5665 eax = MEM32(ecx + 0x4); /* 0x38002D49: mov eax, dword ptr [ecx + 4] */ 5666 ecx = MEM32(ecx + 0x8); /* 0x38002D4C: mov ecx, dword ptr [ecx + 8] */ 5667 MEM32(ebp + (-0x48)) = edx; /* 0x38002D4F: mov dword ptr [ebp - 0x48], edx */ 5668 edx = MEM32(esi); /* 0x38002D52: mov edx, dword ptr [esi] */ 5669 MEM32(ebp + (-0x40)) = ecx; /* 0x38002D54: mov dword ptr [ebp - 0x40], ecx */ 5670 ecx = esi; /* 0x38002D57: mov ecx, esi */ 5671 MEM32(ebp + (-0x30)) = 0; /* 0x38002D59: mov dword ptr [ebp - 0x30], 0 */ 5672 MEM32(ebp + (-0x2C)) = 0; /* 0x38002D60: mov dword ptr [ebp - 0x2c], 0 */ 5673 MEM32(ebp + (-0x28)) = 0; /* 0x38002D67: mov dword ptr [ebp - 0x28], 0 */ 5674 MEM32(ebp + (-0x6C)) = 0; /* 0x38002D6E: mov dword ptr [ebp - 0x6c], 0 */ 5675 MEM32(ebp + (-0x68)) = 0; /* 0x38002D75: mov dword ptr [ebp - 0x68], 0 */ 5676 MEM32(ebp + (-0x64)) = 0; /* 0x38002D7C: mov dword ptr [ebp - 0x64], 0 */ 5677 MEM32(ebp + (-0x44)) = eax; /* 0x38002D83: mov dword ptr [ebp - 0x44], eax */ 5678 RECOMP_ICALL(MEM32(edx + 0x40)); /* 0x38002D86: call dword ptr [edx + 0x40] */ 5679 RECOMP_FLAGS_IN(); 5680 edx = MEM32(eax); /* 0x38002D89: mov edx, dword ptr [eax] */ 5681 PUSH32(esp, 0); /* 0x38002D8B: push 0 */ 5682 PUSH32(esp, 0); /* 0x38002D8D: push 0 */ 5683 ecx = ebp + (-0x48); /* 0x38002D8F: lea ecx, [ebp - 0x48] */ 5684 PUSH32(esp, ecx); /* 0x38002D92: push ecx */ 5685 ecx = eax; /* 0x38002D93: mov ecx, eax */ 5686 RECOMP_ICALL(MEM32(edx + 0x20)); /* 0x38002D95: call dword ptr [edx + 0x20] */ 5687 RECOMP_FLAGS_IN(); 5688 edx = MEM32(esi); /* 0x38002D98: mov edx, dword ptr [esi] */ 5689 ecx = esi; /* 0x38002D9A: mov ecx, esi */ 5690 RECOMP_ICALL(MEM32(edx + 0x40)); /* 0x38002D9C: call dword ptr [edx + 0x40] */ 5691 RECOMP_FLAGS_IN(); 5692 edx = MEM32(eax); /* 0x38002D9F: mov edx, dword ptr [eax] */ 5693 PUSH32(esp, 0); /* 0x38002DA1: push 0 */ 5694 PUSH32(esp, 0); /* 0x38002DA3: push 0 */ 5695 ecx = ebp + (-0x6C); /* 0x38002DA5: lea ecx, [ebp - 0x6c] */ 5696 PUSH32(esp, ecx); /* 0x38002DA8: push ecx */ 5697 ecx = ebp + (-0x30); /* 0x38002DA9: lea ecx, [ebp - 0x30] */ 5698 PUSH32(esp, ecx); /* 0x38002DAC: push ecx */ 5699 ecx = ebp + (-0x48); /* 0x38002DAD: lea ecx, [ebp - 0x48] */ 5700 PUSH32(esp, ecx); /* 0x38002DB0: push ecx */ 5701 ecx = eax; /* 0x38002DB1: mov ecx, eax */ 5702 RECOMP_ICALL(MEM32(edx + 0x4)); /* 0x38002DB3: call dword ptr [edx + 4] */ 5703 RECOMP_FLAGS_IN(); 5704 edx = MEM32(edi); /* 0x38002DB6: mov edx, dword ptr [edi] */ 5705 ecx = MEM32(edi + 0x8); /* 0x38002DB8: mov ecx, dword ptr [edi + 8] */ 5706 eax = MEM32(edi + 0x4); /* 0x38002DBB: mov eax, dword ptr [edi + 4] */ 5707 MEM32(ebp + (-0x60)) = edx; /* 0x38002DBE: mov dword ptr [ebp - 0x60], edx */ 5708 edx = ebp + (-0x30); /* 0x38002DC1: lea edx, [ebp - 0x30] */ 5709 MEM32(ebp + (-0x58)) = ecx; /* 0x38002DC4: mov dword ptr [ebp - 0x58], ecx */ 5710 PUSH32(esp, edx); /* 0x38002DC7: push edx */ 5711 ecx = ebp + (-0x60); /* 0x38002DC8: lea ecx, [ebp - 0x60] */ 5712 MEM32(ebp + (-0x5C)) = eax; /* 0x38002DCB: mov dword ptr [ebp - 0x5c], eax */ 5713 RECOMP_ICALL(MEM32(0x3804E4F4)); /* 0x38002DCE: call dword ptr [0x3804e4f4] */ 5714 RECOMP_FLAGS_IN(); 5715 ecx = MEM32(eax); /* 0x38002DD4: mov ecx, dword ptr [eax] */ 5716 edx = MEM32(eax + 0x4); /* 0x38002DD6: mov edx, dword ptr [eax + 4] */ 5717 eax = MEM32(eax + 0x8); /* 0x38002DD9: mov eax, dword ptr [eax + 8] */ 5718 MEM32(ebp + (-0x34)) = eax; /* 0x38002DDC: mov dword ptr [ebp - 0x34], eax */ 5719 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x38002DDF: fld dword ptr [ebp - 0x34] */ 5720 _st[0] *= (double)*(float*)ADDR(ebp + (-0x34)); /* 0x38002DE2: fmul dword ptr [ebp - 0x34] */ 5721 MEM32(ebp + (-0x38)) = edx; /* 0x38002DE5: mov dword ptr [ebp - 0x38], edx */ 5722 fp_push(*(float*)&MEM32(ebp + (-0x38))); /* 0x38002DE8: fld dword ptr [ebp - 0x38] */ 5723 MEM32(ebp + (-0x3C)) = ecx; /* 0x38002DEB: mov dword ptr [ebp - 0x3c], ecx */ 5724 _st[0] *= (double)*(float*)ADDR(ebp + (-0x38)); /* 0x38002DEE: fmul dword ptr [ebp - 0x38] */ 5725 { double _v = fp_pop(); _st[0] += _v; } /* 0x38002DF1: faddp st(1) */ 5726 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x38002DF3: fld dword ptr [ebp - 0x3c] */ 5727 _st[0] *= (double)*(float*)ADDR(ebp + (-0x3C)); /* 0x38002DF6: fmul dword ptr [ebp - 0x3c] */ 5728 { double _v = fp_pop(); _st[0] += _v; } /* 0x38002DF9: faddp st(1) */ 5729 _st[0] = sqrt(_st[0]); /* 0x38002DFB: fsqrt */ 5730 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8EC)); /* 0x38002DFD: fcomp dword ptr [0x3804e8ec] */ 5731 fp_pop(); 5732 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002E03: fnstsw ax */ 5733 /* test HI8(eax), 1 */ /* 0x38002E05: test ah, 1 */ 5734 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 5735 _cf = 0; 5736 _flag_k = FK_NARROW(FK_TEST, 24); 5737 if (TEST_Z(_flag_a, _flag_b)) goto L_38002E22; /* 0x38002E08: je 0x38002e22 */ 5738 L_38002E0A: 5739 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38002E0A: fld dword ptr [ebp - 0x14] */ 5740 ecx = MEM32(ebp + (-0x18)); /* 0x38002E0D: mov ecx, dword ptr [ebp - 0x18] */ 5741 _st[0] += (double)*(float*)ADDR(0x3804E8EC); /* 0x38002E10: fadd dword ptr [0x3804e8ec] */ 5742 edx = MEM32(ebp + (-0x10)); /* 0x38002E16: mov edx, dword ptr [ebp - 0x10] */ 5743 MEM32(ebp + (-0x18)) = ecx; /* 0x38002E19: mov dword ptr [ebp - 0x18], ecx */ 5744 MEM32(ebp + (-0x10)) = edx; /* 0x38002E1C: mov dword ptr [ebp - 0x10], edx */ 5745 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002E1F: fstp dword ptr [ebp - 0x14] */ 5746 L_38002E22: 5747 ecx = esi; /* 0x38002E22: mov ecx, esi */ 5748 RECOMP_ICALL(MEM32(0x3804E6DC)); /* 0x38002E24: call dword ptr [0x3804e6dc] */ 5749 RECOMP_FLAGS_IN(); 5750 edi = eax; /* 0x38002E2A: mov edi, eax */ 5751 eax = ebp + (-0x78); /* 0x38002E2C: lea eax, [ebp - 0x78] */ 5752 PUSH32(esp, eax); /* 0x38002E2F: push eax */ 5753 ecx = esi; /* 0x38002E30: mov ecx, esi */ 5754 RECOMP_ICALL(0x38001F50u); /* 0x38002E32: call 0x38001f50 */ /* not lifted */ 5755 RECOMP_FLAGS_IN(); 5756 fp_push(*(float*)&MEM32(edi + 0x4)); /* 0x38002E37: fld dword ptr [edi + 4] */ 5757 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(eax + 0x4)); /* 0x38002E3A: fcomp dword ptr [eax + 4] */ 5758 fp_pop(); 5759 edi = POP32_VAL(esp); /* 0x38002E3D: pop edi */ 5760 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002E3E: fnstsw ax */ 5761 /* test HI8(eax), 1 */ /* 0x38002E40: test ah, 1 */ 5762 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 5763 _cf = 0; 5764 _flag_k = FK_NARROW(FK_TEST, 24); 5765 if (TEST_Z(_flag_a, _flag_b)) goto L_38002E5D; /* 0x38002E43: je 0x38002e5d */ 5766 L_38002E45: 5767 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38002E45: fld dword ptr [ebp - 0x14] */ 5768 ecx = MEM32(ebp + (-0x18)); /* 0x38002E48: mov ecx, dword ptr [ebp - 0x18] */ 5769 _st[0] += (double)*(float*)ADDR(0x3804E8EC); /* 0x38002E4B: fadd dword ptr [0x3804e8ec] */ 5770 edx = MEM32(ebp + (-0x10)); /* 0x38002E51: mov edx, dword ptr [ebp - 0x10] */ 5771 MEM32(ebp + (-0x18)) = ecx; /* 0x38002E54: mov dword ptr [ebp - 0x18], ecx */ 5772 MEM32(ebp + (-0x10)) = edx; /* 0x38002E57: mov dword ptr [ebp - 0x10], edx */ 5773 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002E5A: fstp dword ptr [ebp - 0x14] */ 5774 L_38002E5D: 5775 SET_LO8(eax, MEM8(esi + 0x1C4)); /* 0x38002E5D: mov al, byte ptr [esi + 0x1c4] */ 5776 /* test LO8(eax), LO8(eax) */ /* 0x38002E63: test al, al */ 5777 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 5778 _cf = 0; 5779 _flag_k = FK_NARROW(FK_TEST, 24); 5780 if (TEST_Z(_flag_a, _flag_b)) goto L_38002F77; /* 0x38002E65: je 0x38002f77 */ 5781 L_38002E6B: 5782 SET_LO8(eax, MEM8(esi + 0x1A9)); /* 0x38002E6B: mov al, byte ptr [esi + 0x1a9] */ 5783 /* test LO8(eax), LO8(eax) */ /* 0x38002E71: test al, al */ 5784 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 5785 _cf = 0; 5786 _flag_k = FK_NARROW(FK_TEST, 24); 5787 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002F77; /* 0x38002E73: jne 0x38002f77 */ 5788 L_38002E79: 5789 eax = MEM32(0x3804E6E4); /* 0x38002E79: mov eax, dword ptr [0x3804e6e4] */ 5790 fp_push(*(float*)&MEM32(esi + 0x174)); /* 0x38002E7E: fld dword ptr [esi + 0x174] */ 5791 ecx = MEM32(eax); /* 0x38002E84: mov ecx, dword ptr [eax] */ 5792 edx = MEM32(eax + 0x4); /* 0x38002E86: mov edx, dword ptr [eax + 4] */ 5793 eax = MEM32(eax + 0x8); /* 0x38002E89: mov eax, dword ptr [eax + 8] */ 5794 MEM32(ebp + (-0x30)) = ecx; /* 0x38002E8C: mov dword ptr [ebp - 0x30], ecx */ 5795 fp_push(*(float*)&MEM32(ebp + (-0x30))); /* 0x38002E8F: fld dword ptr [ebp - 0x30] */ 5796 _st[0] *= _st[1]; /* 0x38002E92: fmul st(1) */ 5797 MEM32(ebp + (-0x2C)) = edx; /* 0x38002E94: mov dword ptr [ebp - 0x2c], edx */ 5798 MEM32(ebp + (-0x28)) = eax; /* 0x38002E97: mov dword ptr [ebp - 0x28], eax */ 5799 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x30)) = _v; } /* 0x38002E9A: fstp dword ptr [ebp - 0x30] */ 5800 ecx = MEM32(ebp + (-0x30)); /* 0x38002E9D: mov ecx, dword ptr [ebp - 0x30] */ 5801 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x38002EA0: fld dword ptr [ebp - 0x2c] */ 5802 MEM32(ebp + (-0x6C)) = ecx; /* 0x38002EA3: mov dword ptr [ebp - 0x6c], ecx */ 5803 _st[0] *= _st[1]; /* 0x38002EA6: fmul st(1) */ 5804 ecx = esi + 0x148; /* 0x38002EA8: lea ecx, [esi + 0x148] */ 5805 PUSH32(esp, ecx); /* 0x38002EAE: push ecx */ 5806 ecx = ebp + (-0x6C); /* 0x38002EAF: lea ecx, [ebp - 0x6c] */ 5807 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x2C)) = _v; } /* 0x38002EB2: fstp dword ptr [ebp - 0x2c] */ 5808 edx = MEM32(ebp + (-0x2C)); /* 0x38002EB5: mov edx, dword ptr [ebp - 0x2c] */ 5809 fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x38002EB8: fld dword ptr [ebp - 0x28] */ 5810 MEM32(ebp + (-0x68)) = edx; /* 0x38002EBB: mov dword ptr [ebp - 0x68], edx */ 5811 _st[0] *= _st[1]; /* 0x38002EBE: fmul st(1) */ 5812 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x38002EC0: fstp dword ptr [ebp - 0x28] */ 5813 eax = MEM32(ebp + (-0x28)); /* 0x38002EC3: mov eax, dword ptr [ebp - 0x28] */ 5814 MEM32(ebp + (-0x64)) = eax; /* 0x38002EC6: mov dword ptr [ebp - 0x64], eax */ 5815 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38002EC9: fstp st(0) */ 5816 RECOMP_ICALL(MEM32(0x3804E4E4)); /* 0x38002ECB: call dword ptr [0x3804e4e4] */ 5817 RECOMP_FLAGS_IN(); 5818 edx = MEM32(eax); /* 0x38002ED1: mov edx, dword ptr [eax] */ 5819 MEM32(ebp + (-0x60)) = edx; /* 0x38002ED3: mov dword ptr [ebp - 0x60], edx */ 5820 ecx = MEM32(eax + 0x4); /* 0x38002ED6: mov ecx, dword ptr [eax + 4] */ 5821 MEM32(ebp + (-0x5C)) = ecx; /* 0x38002ED9: mov dword ptr [ebp - 0x5c], ecx */ 5822 edx = MEM32(eax + 0x8); /* 0x38002EDC: mov edx, dword ptr [eax + 8] */ 5823 eax = ebp + (-0x78); /* 0x38002EDF: lea eax, [ebp - 0x78] */ 5824 PUSH32(esp, eax); /* 0x38002EE2: push eax */ 5825 ecx = esi; /* 0x38002EE3: mov ecx, esi */ 5826 MEM32(ebp + (-0x58)) = edx; /* 0x38002EE5: mov dword ptr [ebp - 0x58], edx */ 5827 RECOMP_ICALL(0x38001F50u); /* 0x38002EE8: call 0x38001f50 */ /* not lifted */ 5828 RECOMP_FLAGS_IN(); 5829 ecx = MEM32(eax); /* 0x38002EED: mov ecx, dword ptr [eax] */ 5830 edx = MEM32(eax + 0x4); /* 0x38002EEF: mov edx, dword ptr [eax + 4] */ 5831 eax = MEM32(eax + 0x8); /* 0x38002EF2: mov eax, dword ptr [eax + 8] */ 5832 MEM32(ebp + (-0x54)) = ecx; /* 0x38002EF5: mov dword ptr [ebp - 0x54], ecx */ 5833 ecx = ebp + (-0x60); /* 0x38002EF8: lea ecx, [ebp - 0x60] */ 5834 PUSH32(esp, ecx); /* 0x38002EFB: push ecx */ 5835 ecx = ebp + (-0x54); /* 0x38002EFC: lea ecx, [ebp - 0x54] */ 5836 MEM32(ebp + (-0x50)) = edx; /* 0x38002EFF: mov dword ptr [ebp - 0x50], edx */ 5837 MEM32(ebp + (-0x4C)) = eax; /* 0x38002F02: mov dword ptr [ebp - 0x4c], eax */ 5838 RECOMP_ICALL(MEM32(0x3804E4F4)); /* 0x38002F05: call dword ptr [0x3804e4f4] */ 5839 RECOMP_FLAGS_IN(); 5840 fp_push(*(float*)&MEM32(esi + 0x58)); /* 0x38002F0B: fld dword ptr [esi + 0x58] */ 5841 edx = MEM32(eax); /* 0x38002F0E: mov edx, dword ptr [eax] */ 5842 ecx = MEM32(eax + 0x4); /* 0x38002F10: mov ecx, dword ptr [eax + 4] */ 5843 MEM32(ebp + (-0x3C)) = edx; /* 0x38002F13: mov dword ptr [ebp - 0x3c], edx */ 5844 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x38002F16: fld dword ptr [ebp - 0x3c] */ 5845 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F19: fmul dword ptr [0x3804e8bc] */ 5846 edx = MEM32(eax + 0x8); /* 0x38002F1F: mov edx, dword ptr [eax + 8] */ 5847 MEM32(ebp + (-0x34)) = edx; /* 0x38002F22: mov dword ptr [ebp - 0x34], edx */ 5848 MEM32(ebp + (-0x38)) = ecx; /* 0x38002F25: mov dword ptr [ebp - 0x38], ecx */ 5849 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x3C)) = _v; } /* 0x38002F28: fstp dword ptr [ebp - 0x3c] */ 5850 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F2B: fmul dword ptr [0x3804e8bc] */ 5851 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x38002F31: fld dword ptr [ebp - 0x34] */ 5852 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F34: fmul dword ptr [0x3804e8bc] */ 5853 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x34)) = _v; } /* 0x38002F3A: fstp dword ptr [ebp - 0x34] */ 5854 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x38002F3D: fld dword ptr [ebp - 0x18] */ 5855 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F40: fmul dword ptr [0x3804e8bc] */ 5856 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38002F46: fld dword ptr [ebp - 0x14] */ 5857 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F49: fmul dword ptr [0x3804e8bc] */ 5858 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002F4F: fstp dword ptr [ebp - 0x14] */ 5859 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38002F52: fld dword ptr [ebp - 0x10] */ 5860 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F55: fmul dword ptr [0x3804e8bc] */ 5861 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x38002F5B: fstp dword ptr [ebp - 0x10] */ 5862 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x38002F5E: fld dword ptr [ebp - 0x3c] */ 5863 _st[0] += _st[1]; /* 0x38002F61: fadd st(1) */ 5864 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x38002F63: fstp dword ptr [ebp - 0x18] */ 5865 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38002F66: fstp st(0) */ 5866 _st[0] += (double)*(float*)ADDR(ebp + (-0x14)); /* 0x38002F68: fadd dword ptr [ebp - 0x14] */ 5867 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002F6B: fstp dword ptr [ebp - 0x14] */ 5868 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38002F6E: fld dword ptr [ebp - 0x10] */ 5869 _st[0] += (double)*(float*)ADDR(ebp + (-0x34)); /* 0x38002F71: fadd dword ptr [ebp - 0x34] */ 5870 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x38002F74: fstp dword ptr [ebp - 0x10] */ 5871 L_38002F77: 5872 eax = MEM32(ebp + 0x8); /* 0x38002F77: mov eax, dword ptr [ebp + 8] */ 5873 PUSH32(esp, 0x3C23D70Au); /* 0x38002F7A: push 0x3c23d70a */ 5874 PUSH32(esp, eax); /* 0x38002F7F: push eax */ 5875 ecx = ebp + (-0x18); /* 0x38002F80: lea ecx, [ebp - 0x18] */ 5876 PUSH32(esp, ecx); /* 0x38002F83: push ecx */ 5877 ecx = esi; /* 0x38002F84: mov ecx, esi */ 5878 RECOMP_ICALL(0x38002FA0u); /* 0x38002F86: call 0x38002fa0 */ /* not lifted */ 5879 RECOMP_FLAGS_IN(); 5880 L_38002F8B: 5881 esi = POP32_VAL(esp); /* 0x38002F8B: pop esi */ 5882 esp = ebp; /* 0x38002F8C: mov esp, ebp */ 5883 ebp = POP32_VAL(esp); /* 0x38002F8E: pop ebp */ 5884 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38002F8F: ret 4 */ 5885 RECOMP_REGS_OUT(); 5886 } 5887 5888 void sub_38002E22(void) { 5889 int _fpu_cmp = 0; 5890 uint32_t _cf = 0; 5891 int _df = 1; 5892 uint32_t _flag_k = FK_NONE; 5893 uint32_t _flag_a = 0, _flag_b = 0; 5894 uint32_t _itail_tgt = 0; 5895 RECOMP_REGS_LOCALS 5896 RECOMP_ENTER(0x38002E22u); 5897 5898 L_38002E22: 5899 ecx = esi; /* 0x38002E22: mov ecx, esi */ 5900 RECOMP_ICALL(MEM32(0x3804E6DC)); /* 0x38002E24: call dword ptr [0x3804e6dc] */ 5901 RECOMP_FLAGS_IN(); 5902 edi = eax; /* 0x38002E2A: mov edi, eax */ 5903 eax = ebp + (-0x78); /* 0x38002E2C: lea eax, [ebp - 0x78] */ 5904 PUSH32(esp, eax); /* 0x38002E2F: push eax */ 5905 ecx = esi; /* 0x38002E30: mov ecx, esi */ 5906 RECOMP_ICALL(0x38001F50u); /* 0x38002E32: call 0x38001f50 */ /* not lifted */ 5907 RECOMP_FLAGS_IN(); 5908 fp_push(*(float*)&MEM32(edi + 0x4)); /* 0x38002E37: fld dword ptr [edi + 4] */ 5909 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(eax + 0x4)); /* 0x38002E3A: fcomp dword ptr [eax + 4] */ 5910 fp_pop(); 5911 edi = POP32_VAL(esp); /* 0x38002E3D: pop edi */ 5912 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002E3E: fnstsw ax */ 5913 /* test HI8(eax), 1 */ /* 0x38002E40: test ah, 1 */ 5914 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 5915 _cf = 0; 5916 _flag_k = FK_NARROW(FK_TEST, 24); 5917 if (TEST_Z(_flag_a, _flag_b)) goto L_38002E5D; /* 0x38002E43: je 0x38002e5d */ 5918 L_38002E45: 5919 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38002E45: fld dword ptr [ebp - 0x14] */ 5920 ecx = MEM32(ebp + (-0x18)); /* 0x38002E48: mov ecx, dword ptr [ebp - 0x18] */ 5921 _st[0] += (double)*(float*)ADDR(0x3804E8EC); /* 0x38002E4B: fadd dword ptr [0x3804e8ec] */ 5922 edx = MEM32(ebp + (-0x10)); /* 0x38002E51: mov edx, dword ptr [ebp - 0x10] */ 5923 MEM32(ebp + (-0x18)) = ecx; /* 0x38002E54: mov dword ptr [ebp - 0x18], ecx */ 5924 MEM32(ebp + (-0x10)) = edx; /* 0x38002E57: mov dword ptr [ebp - 0x10], edx */ 5925 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002E5A: fstp dword ptr [ebp - 0x14] */ 5926 L_38002E5D: 5927 SET_LO8(eax, MEM8(esi + 0x1C4)); /* 0x38002E5D: mov al, byte ptr [esi + 0x1c4] */ 5928 /* test LO8(eax), LO8(eax) */ /* 0x38002E63: test al, al */ 5929 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 5930 _cf = 0; 5931 _flag_k = FK_NARROW(FK_TEST, 24); 5932 if (TEST_Z(_flag_a, _flag_b)) goto L_38002F77; /* 0x38002E65: je 0x38002f77 */ 5933 L_38002E6B: 5934 SET_LO8(eax, MEM8(esi + 0x1A9)); /* 0x38002E6B: mov al, byte ptr [esi + 0x1a9] */ 5935 /* test LO8(eax), LO8(eax) */ /* 0x38002E71: test al, al */ 5936 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 5937 _cf = 0; 5938 _flag_k = FK_NARROW(FK_TEST, 24); 5939 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002F77; /* 0x38002E73: jne 0x38002f77 */ 5940 L_38002E79: 5941 eax = MEM32(0x3804E6E4); /* 0x38002E79: mov eax, dword ptr [0x3804e6e4] */ 5942 fp_push(*(float*)&MEM32(esi + 0x174)); /* 0x38002E7E: fld dword ptr [esi + 0x174] */ 5943 ecx = MEM32(eax); /* 0x38002E84: mov ecx, dword ptr [eax] */ 5944 edx = MEM32(eax + 0x4); /* 0x38002E86: mov edx, dword ptr [eax + 4] */ 5945 eax = MEM32(eax + 0x8); /* 0x38002E89: mov eax, dword ptr [eax + 8] */ 5946 MEM32(ebp + (-0x30)) = ecx; /* 0x38002E8C: mov dword ptr [ebp - 0x30], ecx */ 5947 fp_push(*(float*)&MEM32(ebp + (-0x30))); /* 0x38002E8F: fld dword ptr [ebp - 0x30] */ 5948 _st[0] *= _st[1]; /* 0x38002E92: fmul st(1) */ 5949 MEM32(ebp + (-0x2C)) = edx; /* 0x38002E94: mov dword ptr [ebp - 0x2c], edx */ 5950 MEM32(ebp + (-0x28)) = eax; /* 0x38002E97: mov dword ptr [ebp - 0x28], eax */ 5951 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x30)) = _v; } /* 0x38002E9A: fstp dword ptr [ebp - 0x30] */ 5952 ecx = MEM32(ebp + (-0x30)); /* 0x38002E9D: mov ecx, dword ptr [ebp - 0x30] */ 5953 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x38002EA0: fld dword ptr [ebp - 0x2c] */ 5954 MEM32(ebp + (-0x6C)) = ecx; /* 0x38002EA3: mov dword ptr [ebp - 0x6c], ecx */ 5955 _st[0] *= _st[1]; /* 0x38002EA6: fmul st(1) */ 5956 ecx = esi + 0x148; /* 0x38002EA8: lea ecx, [esi + 0x148] */ 5957 PUSH32(esp, ecx); /* 0x38002EAE: push ecx */ 5958 ecx = ebp + (-0x6C); /* 0x38002EAF: lea ecx, [ebp - 0x6c] */ 5959 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x2C)) = _v; } /* 0x38002EB2: fstp dword ptr [ebp - 0x2c] */ 5960 edx = MEM32(ebp + (-0x2C)); /* 0x38002EB5: mov edx, dword ptr [ebp - 0x2c] */ 5961 fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x38002EB8: fld dword ptr [ebp - 0x28] */ 5962 MEM32(ebp + (-0x68)) = edx; /* 0x38002EBB: mov dword ptr [ebp - 0x68], edx */ 5963 _st[0] *= _st[1]; /* 0x38002EBE: fmul st(1) */ 5964 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x38002EC0: fstp dword ptr [ebp - 0x28] */ 5965 eax = MEM32(ebp + (-0x28)); /* 0x38002EC3: mov eax, dword ptr [ebp - 0x28] */ 5966 MEM32(ebp + (-0x64)) = eax; /* 0x38002EC6: mov dword ptr [ebp - 0x64], eax */ 5967 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38002EC9: fstp st(0) */ 5968 RECOMP_ICALL(MEM32(0x3804E4E4)); /* 0x38002ECB: call dword ptr [0x3804e4e4] */ 5969 RECOMP_FLAGS_IN(); 5970 edx = MEM32(eax); /* 0x38002ED1: mov edx, dword ptr [eax] */ 5971 MEM32(ebp + (-0x60)) = edx; /* 0x38002ED3: mov dword ptr [ebp - 0x60], edx */ 5972 ecx = MEM32(eax + 0x4); /* 0x38002ED6: mov ecx, dword ptr [eax + 4] */ 5973 MEM32(ebp + (-0x5C)) = ecx; /* 0x38002ED9: mov dword ptr [ebp - 0x5c], ecx */ 5974 edx = MEM32(eax + 0x8); /* 0x38002EDC: mov edx, dword ptr [eax + 8] */ 5975 eax = ebp + (-0x78); /* 0x38002EDF: lea eax, [ebp - 0x78] */ 5976 PUSH32(esp, eax); /* 0x38002EE2: push eax */ 5977 ecx = esi; /* 0x38002EE3: mov ecx, esi */ 5978 MEM32(ebp + (-0x58)) = edx; /* 0x38002EE5: mov dword ptr [ebp - 0x58], edx */ 5979 RECOMP_ICALL(0x38001F50u); /* 0x38002EE8: call 0x38001f50 */ /* not lifted */ 5980 RECOMP_FLAGS_IN(); 5981 ecx = MEM32(eax); /* 0x38002EED: mov ecx, dword ptr [eax] */ 5982 edx = MEM32(eax + 0x4); /* 0x38002EEF: mov edx, dword ptr [eax + 4] */ 5983 eax = MEM32(eax + 0x8); /* 0x38002EF2: mov eax, dword ptr [eax + 8] */ 5984 MEM32(ebp + (-0x54)) = ecx; /* 0x38002EF5: mov dword ptr [ebp - 0x54], ecx */ 5985 ecx = ebp + (-0x60); /* 0x38002EF8: lea ecx, [ebp - 0x60] */ 5986 PUSH32(esp, ecx); /* 0x38002EFB: push ecx */ 5987 ecx = ebp + (-0x54); /* 0x38002EFC: lea ecx, [ebp - 0x54] */ 5988 MEM32(ebp + (-0x50)) = edx; /* 0x38002EFF: mov dword ptr [ebp - 0x50], edx */ 5989 MEM32(ebp + (-0x4C)) = eax; /* 0x38002F02: mov dword ptr [ebp - 0x4c], eax */ 5990 RECOMP_ICALL(MEM32(0x3804E4F4)); /* 0x38002F05: call dword ptr [0x3804e4f4] */ 5991 RECOMP_FLAGS_IN(); 5992 fp_push(*(float*)&MEM32(esi + 0x58)); /* 0x38002F0B: fld dword ptr [esi + 0x58] */ 5993 edx = MEM32(eax); /* 0x38002F0E: mov edx, dword ptr [eax] */ 5994 ecx = MEM32(eax + 0x4); /* 0x38002F10: mov ecx, dword ptr [eax + 4] */ 5995 MEM32(ebp + (-0x3C)) = edx; /* 0x38002F13: mov dword ptr [ebp - 0x3c], edx */ 5996 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x38002F16: fld dword ptr [ebp - 0x3c] */ 5997 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F19: fmul dword ptr [0x3804e8bc] */ 5998 edx = MEM32(eax + 0x8); /* 0x38002F1F: mov edx, dword ptr [eax + 8] */ 5999 MEM32(ebp + (-0x34)) = edx; /* 0x38002F22: mov dword ptr [ebp - 0x34], edx */ 6000 MEM32(ebp + (-0x38)) = ecx; /* 0x38002F25: mov dword ptr [ebp - 0x38], ecx */ 6001 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x3C)) = _v; } /* 0x38002F28: fstp dword ptr [ebp - 0x3c] */ 6002 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F2B: fmul dword ptr [0x3804e8bc] */ 6003 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x38002F31: fld dword ptr [ebp - 0x34] */ 6004 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F34: fmul dword ptr [0x3804e8bc] */ 6005 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x34)) = _v; } /* 0x38002F3A: fstp dword ptr [ebp - 0x34] */ 6006 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x38002F3D: fld dword ptr [ebp - 0x18] */ 6007 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F40: fmul dword ptr [0x3804e8bc] */ 6008 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38002F46: fld dword ptr [ebp - 0x14] */ 6009 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F49: fmul dword ptr [0x3804e8bc] */ 6010 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002F4F: fstp dword ptr [ebp - 0x14] */ 6011 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38002F52: fld dword ptr [ebp - 0x10] */ 6012 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38002F55: fmul dword ptr [0x3804e8bc] */ 6013 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x38002F5B: fstp dword ptr [ebp - 0x10] */ 6014 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x38002F5E: fld dword ptr [ebp - 0x3c] */ 6015 _st[0] += _st[1]; /* 0x38002F61: fadd st(1) */ 6016 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x38002F63: fstp dword ptr [ebp - 0x18] */ 6017 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38002F66: fstp st(0) */ 6018 _st[0] += (double)*(float*)ADDR(ebp + (-0x14)); /* 0x38002F68: fadd dword ptr [ebp - 0x14] */ 6019 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x38002F6B: fstp dword ptr [ebp - 0x14] */ 6020 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38002F6E: fld dword ptr [ebp - 0x10] */ 6021 _st[0] += (double)*(float*)ADDR(ebp + (-0x34)); /* 0x38002F71: fadd dword ptr [ebp - 0x34] */ 6022 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x38002F74: fstp dword ptr [ebp - 0x10] */ 6023 L_38002F77: 6024 eax = MEM32(ebp + 0x8); /* 0x38002F77: mov eax, dword ptr [ebp + 8] */ 6025 PUSH32(esp, 0x3C23D70Au); /* 0x38002F7A: push 0x3c23d70a */ 6026 PUSH32(esp, eax); /* 0x38002F7F: push eax */ 6027 ecx = ebp + (-0x18); /* 0x38002F80: lea ecx, [ebp - 0x18] */ 6028 PUSH32(esp, ecx); /* 0x38002F83: push ecx */ 6029 ecx = esi; /* 0x38002F84: mov ecx, esi */ 6030 RECOMP_ICALL(0x38002FA0u); /* 0x38002F86: call 0x38002fa0 */ /* not lifted */ 6031 RECOMP_FLAGS_IN(); 6032 esi = POP32_VAL(esp); /* 0x38002F8B: pop esi */ 6033 esp = ebp; /* 0x38002F8C: mov esp, ebp */ 6034 ebp = POP32_VAL(esp); /* 0x38002F8E: pop ebp */ 6035 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38002F8F: ret 4 */ 6036 RECOMP_REGS_OUT(); 6037 } 6038 6039 void sub_38002FA0(void) { 6040 int _fpu_cmp = 0; 6041 uint32_t _cf = 0; 6042 int _df = 1; 6043 uint32_t _flag_k = FK_NONE; 6044 uint32_t _flag_a = 0, _flag_b = 0; 6045 uint32_t _itail_tgt = 0; 6046 RECOMP_REGS_LOCALS 6047 RECOMP_ENTER(0x38002FA0u); 6048 6049 L_38002FA0: 6050 PUSH32(esp, ebp); /* 0x38002FA0: push ebp */ 6051 ebp = esp; /* 0x38002FA1: mov ebp, esp */ 6052 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x5Cu); 6053 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 6054 esp = esp - 0x5Cu; /* 0x38002FA3: sub esp, 0x5c */ 6055 _flag_k = FK_CMP; 6056 SET_LO8(eax, MEM8(0x3806E984)); /* 0x38002FA6: mov al, byte ptr [0x3806e984] */ 6057 PUSH32(esp, ebx); /* 0x38002FAB: push ebx */ 6058 PUSH32(esp, esi); /* 0x38002FAC: push esi */ 6059 esi = ecx; /* 0x38002FAD: mov esi, ecx */ 6060 SET_LO8(ecx, 1); /* 0x38002FAF: mov cl, 1 */ 6061 /* test LO8(ecx), LO8(eax) */ /* 0x38002FB1: test cl, al */ 6062 _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 6063 _cf = 0; 6064 _flag_k = FK_NARROW(FK_TEST, 24); 6065 eax = MEM32(0x3804E6D4); /* 0x38002FB3: mov eax, dword ptr [0x3804e6d4] */ 6066 PUSH32(esp, edi); /* 0x38002FB8: push edi */ 6067 if (TEST_NZ(_flag_a, _flag_b)) goto L_38002FD1; /* 0x38002FB9: jne 0x38002fd1 */ 6068 L_38002FBB: 6069 SET_LO8(edx, MEM8(0x3806E984)); /* 0x38002FBB: mov dl, byte ptr [0x3806e984] */ 6070 _flag_a = (uint32_t)((LO8(edx) | LO8(ecx))) << 24; _flag_b = (uint32_t)((LO8(edx) | LO8(ecx))) << 24; 6071 SET_LO8(edx, LO8(edx) | LO8(ecx)); /* 0x38002FC1: or dl, cl */ 6072 _cf = 0; 6073 _flag_k = FK_NARROW(FK_TEST, 24); 6074 MEM8(0x3806E984) = (uint8_t)(LO8(edx)); /* 0x38002FC3: mov byte ptr [0x3806e984], dl */ 6075 fp_push(*(float*)&MEM32(eax)); /* 0x38002FC9: fld dword ptr [eax] */ 6076 { float _v = (float)fp_pop(); *(float*)ADDR(0x3806E980) = _v; } /* 0x38002FCB: fstp dword ptr [0x3806e980] */ 6077 L_38002FD1: 6078 fp_push(*(float*)&MEM32(eax)); /* 0x38002FD1: fld dword ptr [eax] */ 6079 fp_push(*(float*)&MEM32(0x3806E980)); /* 0x38002FD3: fld dword ptr [0x3806e980] */ 6080 _st[0] *= (double)*(float*)ADDR(0x3804E920); /* 0x38002FD9: fmul dword ptr [0x3804e920] */ 6081 fp_push(_st[1]); /* 0x38002FDF: fld st(1) */ 6082 _fpu_cmp = FPU_CMP(_st[0], _st[1]); /* 0x38002FE1: fcompp */ 6083 fp_pop(); fp_pop(); 6084 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38002FE3: fnstsw ax */ 6085 /* test HI8(eax), 0x41u */ /* 0x38002FE5: test ah, 0x41 */ 6086 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 6087 _cf = 0; 6088 _flag_k = FK_NARROW(FK_TEST, 24); 6089 if (TEST_NZ(_flag_a, _flag_b)) goto L_38003001; /* 0x38002FE8: jne 0x38003001 */ 6090 L_38002FEA: 6091 eax = MEM32(ebp + 0xC); /* 0x38002FEA: mov eax, dword ptr [ebp + 0xc] */ 6092 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38002FED: fstp st(0) */ 6093 PUSH32(esp, eax); /* 0x38002FEF: push eax */ 6094 ecx = esi; /* 0x38002FF0: mov ecx, esi */ 6095 RECOMP_ICALL(MEM32(0x3804E6EC)); /* 0x38002FF2: call dword ptr [0x3804e6ec] */ 6096 RECOMP_FLAGS_IN(); 6097 edi = POP32_VAL(esp); /* 0x38002FF8: pop edi */ 6098 esi = POP32_VAL(esp); /* 0x38002FF9: pop esi */ 6099 ebx = POP32_VAL(esp); /* 0x38002FFA: pop ebx */ 6100 esp = ebp; /* 0x38002FFB: mov esp, ebp */ 6101 ebp = POP32_VAL(esp); /* 0x38002FFD: pop ebp */ 6102 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x38002FFE: ret 0xc */ 6103 L_38003001: 6104 fp_push(*(float*)&MEM32(0x3806E980)); /* 0x38003001: fld dword ptr [0x3806e980] */ 6105 ecx = MEM32(ebp + 0x8); /* 0x38003007: mov ecx, dword ptr [ebp + 8] */ 6106 _st[0] *= *(double*)ADDR(0x3804E918); /* 0x3800300A: fmul qword ptr [0x3804e918] */ 6107 fp_xch(1); /* 0x38003010: fxch st(1) */ 6108 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38003012: fmul dword ptr [0x3804e8bc] */ 6109 { double _v = fp_pop(); _st[0] += _v; } /* 0x38003018: faddp st(1) */ 6110 { float _v = (float)fp_pop(); *(float*)ADDR(0x3806E980) = _v; } /* 0x3800301A: fstp dword ptr [0x3806e980] */ 6111 edx = MEM32(ecx); /* 0x38003020: mov edx, dword ptr [ecx] */ 6112 eax = MEM32(ecx + 0x4); /* 0x38003022: mov eax, dword ptr [ecx + 4] */ 6113 ecx = MEM32(ecx + 0x8); /* 0x38003025: mov ecx, dword ptr [ecx + 8] */ 6114 MEM32(ebp + (-0x2C)) = edx; /* 0x38003028: mov dword ptr [ebp - 0x2c], edx */ 6115 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x3800302B: fld dword ptr [ebp - 0x2c] */ 6116 _st[0] -= (double)*(float*)ADDR(esi + 0x54); /* 0x3800302E: fsub dword ptr [esi + 0x54] */ 6117 MEM32(ebp + (-0x28)) = eax; /* 0x38003031: mov dword ptr [ebp - 0x28], eax */ 6118 MEM32(ebp + (-0x24)) = ecx; /* 0x38003034: mov dword ptr [ebp - 0x24], ecx */ 6119 edx = ebp + (-0x5C); /* 0x38003037: lea edx, [ebp - 0x5c] */ 6120 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x2C)) = _v; } /* 0x3800303A: fstp dword ptr [ebp - 0x2c] */ 6121 PUSH32(esp, edx); /* 0x3800303D: push edx */ 6122 fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x3800303E: fld dword ptr [ebp - 0x28] */ 6123 ecx = esi; /* 0x38003041: mov ecx, esi */ 6124 _st[0] -= (double)*(float*)ADDR(esi + 0x58); /* 0x38003043: fsub dword ptr [esi + 0x58] */ 6125 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x38003046: fstp dword ptr [ebp - 0x28] */ 6126 fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x38003049: fld dword ptr [ebp - 0x24] */ 6127 _st[0] -= (double)*(float*)ADDR(esi + 0x5C); /* 0x3800304C: fsub dword ptr [esi + 0x5c] */ 6128 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x3800304F: fstp dword ptr [ebp - 0x24] */ 6129 RECOMP_ICALL(0x38001F50u); /* 0x38003052: call 0x38001f50 */ /* not lifted */ 6130 RECOMP_FLAGS_IN(); 6131 ecx = eax; /* 0x38003057: mov ecx, eax */ 6132 edx = MEM32(ecx); /* 0x38003059: mov edx, dword ptr [ecx] */ 6133 MEM32(ebp + (-0x44)) = edx; /* 0x3800305B: mov dword ptr [ebp - 0x44], edx */ 6134 edx = MEM32(ecx + 0x4); /* 0x3800305E: mov edx, dword ptr [ecx + 4] */ 6135 ecx = MEM32(ecx + 0x8); /* 0x38003061: mov ecx, dword ptr [ecx + 8] */ 6136 MEM32(ebp + (-0x40)) = edx; /* 0x38003064: mov dword ptr [ebp - 0x40], edx */ 6137 edx = MEM32(eax); /* 0x38003067: mov edx, dword ptr [eax] */ 6138 MEM32(ebp + (-0x14)) = edx; /* 0x38003069: mov dword ptr [ebp - 0x14], edx */ 6139 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x3800306C: fld dword ptr [ebp - 0x14] */ 6140 _st[0] -= (double)*(float*)ADDR(esi + 0x54); /* 0x3800306F: fsub dword ptr [esi + 0x54] */ 6141 edx = MEM32(eax + 0x8); /* 0x38003072: mov edx, dword ptr [eax + 8] */ 6142 MEM32(ebp + (-0x3C)) = ecx; /* 0x38003075: mov dword ptr [ebp - 0x3c], ecx */ 6143 ecx = MEM32(eax + 0x4); /* 0x38003078: mov ecx, dword ptr [eax + 4] */ 6144 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3800307B: fstp dword ptr [ebp - 0x14] */ 6145 edi = MEM32(ebp + (-0x14)); /* 0x3800307E: mov edi, dword ptr [ebp - 0x14] */ 6146 MEM32(ebp + (-0x10)) = ecx; /* 0x38003081: mov dword ptr [ebp - 0x10], ecx */ 6147 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38003084: fld dword ptr [ebp - 0x10] */ 6148 _st[0] -= (double)*(float*)ADDR(esi + 0x58); /* 0x38003087: fsub dword ptr [esi + 0x58] */ 6149 ecx = MEM32(ebp + (-0x2C)); /* 0x3800308A: mov ecx, dword ptr [ebp - 0x2c] */ 6150 MEM32(ebp + (-0xC)) = edx; /* 0x3800308D: mov dword ptr [ebp - 0xc], edx */ 6151 edx = MEM32(ebp + (-0x28)); /* 0x38003090: mov edx, dword ptr [ebp - 0x28] */ 6152 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x38003093: fstp dword ptr [ebp - 0x10] */ 6153 eax = MEM32(ebp + (-0x10)); /* 0x38003096: mov eax, dword ptr [ebp - 0x10] */ 6154 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x38003099: fld dword ptr [ebp - 0xc] */ 6155 MEM32(ebp + (-0x20)) = edi; /* 0x3800309C: mov dword ptr [ebp - 0x20], edi */ 6156 _st[0] -= (double)*(float*)ADDR(esi + 0x5C); /* 0x3800309F: fsub dword ptr [esi + 0x5c] */ 6157 MEM32(ebp + (-0x1C)) = eax; /* 0x380030A2: mov dword ptr [ebp - 0x1c], eax */ 6158 MEM32(ebp + (-0x10)) = edx; /* 0x380030A5: mov dword ptr [ebp - 0x10], edx */ 6159 edx = MEM32(ebp + (-0x24)); /* 0x380030A8: mov edx, dword ptr [ebp - 0x24] */ 6160 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x380030AB: fstp dword ptr [ebp - 0xc] */ 6161 ebx = MEM32(ebp + (-0xC)); /* 0x380030AE: mov ebx, dword ptr [ebp - 0xc] */ 6162 fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x380030B1: fld dword ptr [ebp - 0x20] */ 6163 MEM32(ebp + (-0x18)) = ebx; /* 0x380030B4: mov dword ptr [ebp - 0x18], ebx */ 6164 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x380030B7: fcomp dword ptr [0x3804e8e4] */ 6165 fp_pop(); 6166 MEM32(ebp + (-0x1C)) = 0; /* 0x380030BD: mov dword ptr [ebp - 0x1c], 0 */ 6167 MEM32(ebp + (-0x14)) = ecx; /* 0x380030C4: mov dword ptr [ebp - 0x14], ecx */ 6168 MEM32(ebp + (-0xC)) = edx; /* 0x380030C7: mov dword ptr [ebp - 0xc], edx */ 6169 MEM32(ebp + (-0x10)) = 0; /* 0x380030CA: mov dword ptr [ebp - 0x10], 0 */ 6170 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380030D1: fnstsw ax */ 6171 /* test HI8(eax), 0x40u */ /* 0x380030D3: test ah, 0x40 */ 6172 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6173 _cf = 0; 6174 _flag_k = FK_NARROW(FK_TEST, 24); 6175 if (TEST_Z(_flag_a, _flag_b)) goto L_380030EC; /* 0x380030D6: je 0x380030ec */ 6176 L_380030D8: 6177 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x380030D8: fld dword ptr [ebp - 0x18] */ 6178 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x380030DB: fcomp dword ptr [0x3804e8e4] */ 6179 fp_pop(); 6180 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380030E1: fnstsw ax */ 6181 /* test HI8(eax), 0x40u */ /* 0x380030E3: test ah, 0x40 */ 6182 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6183 _cf = 0; 6184 _flag_k = FK_NARROW(FK_TEST, 24); 6185 if (TEST_NZ(_flag_a, _flag_b)) goto L_38003363; /* 0x380030E6: jne 0x38003363 */ 6186 L_380030EC: 6187 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x380030EC: fld dword ptr [ebp - 0x14] */ 6188 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x380030EF: fcomp dword ptr [0x3804e8e4] */ 6189 fp_pop(); 6190 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380030F5: fnstsw ax */ 6191 /* test HI8(eax), 0x40u */ /* 0x380030F7: test ah, 0x40 */ 6192 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6193 _cf = 0; 6194 _flag_k = FK_NARROW(FK_TEST, 24); 6195 if (TEST_Z(_flag_a, _flag_b)) goto L_38003110; /* 0x380030FA: je 0x38003110 */ 6196 L_380030FC: 6197 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x380030FC: fld dword ptr [ebp - 0xc] */ 6198 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x380030FF: fcomp dword ptr [0x3804e8e4] */ 6199 fp_pop(); 6200 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003105: fnstsw ax */ 6201 /* test HI8(eax), 0x40u */ /* 0x38003107: test ah, 0x40 */ 6202 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6203 _cf = 0; 6204 _flag_k = FK_NARROW(FK_TEST, 24); 6205 if (TEST_NZ(_flag_a, _flag_b)) goto L_38003363; /* 0x3800310A: jne 0x38003363 */ 6206 L_38003110: 6207 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x38003110: fld dword ptr [ebp - 0x18] */ 6208 eax = MEM32(ebp + (-0x10)); /* 0x38003113: mov eax, dword ptr [ebp - 0x10] */ 6209 _st[0] *= (double)*(float*)ADDR(ebp + (-0x18)); /* 0x38003116: fmul dword ptr [ebp - 0x18] */ 6210 MEM32(ebp + (-0x2C)) = ecx; /* 0x38003119: mov dword ptr [ebp - 0x2c], ecx */ 6211 fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x3800311C: fld dword ptr [ebp - 0x20] */ 6212 MEM32(ebp + (-0x28)) = eax; /* 0x3800311F: mov dword ptr [ebp - 0x28], eax */ 6213 _st[0] *= (double)*(float*)ADDR(ebp + (-0x20)); /* 0x38003122: fmul dword ptr [ebp - 0x20] */ 6214 MEM32(ebp + (-0x24)) = edx; /* 0x38003125: mov dword ptr [ebp - 0x24], edx */ 6215 { double _v = fp_pop(); _st[0] += _v; } /* 0x38003128: faddp st(1) */ 6216 _st[0] = sqrt(_st[0]); /* 0x3800312A: fsqrt */ 6217 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3800312C: fstp dword ptr [ebp - 8] */ 6218 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3800312F: fld dword ptr [ebp - 0xc] */ 6219 _st[0] *= (double)*(float*)ADDR(ebp + (-0xC)); /* 0x38003132: fmul dword ptr [ebp - 0xc] */ 6220 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38003135: fld dword ptr [ebp - 0x14] */ 6221 _st[0] *= (double)*(float*)ADDR(ebp + (-0x14)); /* 0x38003138: fmul dword ptr [ebp - 0x14] */ 6222 { double _v = fp_pop(); _st[0] += _v; } /* 0x3800313B: faddp st(1) */ 6223 _st[0] = sqrt(_st[0]); /* 0x3800313D: fsqrt */ 6224 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3800313F: fstp dword ptr [ebp - 4] */ 6225 fp_push(*(float*)&MEM32(0x3804E8CC)); /* 0x38003142: fld dword ptr [0x3804e8cc] */ 6226 _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x38003148: fdiv dword ptr [ebp - 4] */ 6227 fp_push(_st[0]); /* 0x3800314B: fld st(0) */ 6228 _st[0] *= (double)*(float*)ADDR(ebp + (-0x14)); /* 0x3800314D: fmul dword ptr [ebp - 0x14] */ 6229 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x2C)) = _v; } /* 0x38003150: fstp dword ptr [ebp - 0x2c] */ 6230 ecx = MEM32(ebp + (-0x2C)); /* 0x38003153: mov ecx, dword ptr [ebp - 0x2c] */ 6231 fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x38003156: fld dword ptr [ebp - 0x28] */ 6232 MEM32(ebp + (-0x38)) = ecx; /* 0x38003159: mov dword ptr [ebp - 0x38], ecx */ 6233 _st[0] *= _st[1]; /* 0x3800315C: fmul st(1) */ 6234 ecx = MEM32(ebp + (-0x1C)); /* 0x3800315E: mov ecx, dword ptr [ebp - 0x1c] */ 6235 MEM32(ebp + (-0x2C)) = edi; /* 0x38003161: mov dword ptr [ebp - 0x2c], edi */ 6236 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x38003164: fstp dword ptr [ebp - 0x28] */ 6237 edx = MEM32(ebp + (-0x28)); /* 0x38003167: mov edx, dword ptr [ebp - 0x28] */ 6238 fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x3800316A: fld dword ptr [ebp - 0x24] */ 6239 MEM32(ebp + (-0x28)) = ecx; /* 0x3800316D: mov dword ptr [ebp - 0x28], ecx */ 6240 _st[0] *= _st[1]; /* 0x38003170: fmul st(1) */ 6241 MEM32(ebp + (-0x34)) = edx; /* 0x38003172: mov dword ptr [ebp - 0x34], edx */ 6242 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x38003175: fstp dword ptr [ebp - 0x24] */ 6243 eax = MEM32(ebp + (-0x24)); /* 0x38003178: mov eax, dword ptr [ebp - 0x24] */ 6244 MEM32(ebp + (-0x24)) = ebx; /* 0x3800317B: mov dword ptr [ebp - 0x24], ebx */ 6245 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3800317E: fstp st(0) */ 6246 MEM32(ebp + (-0x30)) = eax; /* 0x38003180: mov dword ptr [ebp - 0x30], eax */ 6247 fp_push(*(float*)&MEM32(0x3804E8CC)); /* 0x38003183: fld dword ptr [0x3804e8cc] */ 6248 _st[0] /= (double)*(float*)ADDR(ebp + (-0x8)); /* 0x38003189: fdiv dword ptr [ebp - 8] */ 6249 fp_push(_st[0]); /* 0x3800318C: fld st(0) */ 6250 _st[0] *= (double)*(float*)ADDR(ebp + (-0x20)); /* 0x3800318E: fmul dword ptr [ebp - 0x20] */ 6251 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x2C)) = _v; } /* 0x38003191: fstp dword ptr [ebp - 0x2c] */ 6252 edx = MEM32(ebp + (-0x2C)); /* 0x38003194: mov edx, dword ptr [ebp - 0x2c] */ 6253 fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x38003197: fld dword ptr [ebp - 0x28] */ 6254 MEM32(ebp + (-0x5C)) = edx; /* 0x3800319A: mov dword ptr [ebp - 0x5c], edx */ 6255 _st[0] *= _st[1]; /* 0x3800319D: fmul st(1) */ 6256 edx = ebp + (-0x38); /* 0x3800319F: lea edx, [ebp - 0x38] */ 6257 PUSH32(esp, edx); /* 0x380031A2: push edx */ 6258 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x380031A3: fstp dword ptr [ebp - 0x28] */ 6259 eax = MEM32(ebp + (-0x28)); /* 0x380031A6: mov eax, dword ptr [ebp - 0x28] */ 6260 fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x380031A9: fld dword ptr [ebp - 0x24] */ 6261 MEM32(ebp + (-0x58)) = eax; /* 0x380031AC: mov dword ptr [ebp - 0x58], eax */ 6262 _st[0] *= _st[1]; /* 0x380031AF: fmul st(1) */ 6263 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x380031B1: fstp dword ptr [ebp - 0x24] */ 6264 ecx = MEM32(ebp + (-0x24)); /* 0x380031B4: mov ecx, dword ptr [ebp - 0x24] */ 6265 MEM32(ebp + (-0x54)) = ecx; /* 0x380031B7: mov dword ptr [ebp - 0x54], ecx */ 6266 ecx = ebp + (-0x5C); /* 0x380031BA: lea ecx, [ebp - 0x5c] */ 6267 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x380031BD: fstp st(0) */ 6268 RECOMP_ICALL(MEM32(0x3804E4C8)); /* 0x380031BF: call dword ptr [0x3804e4c8] */ 6269 RECOMP_FLAGS_IN(); 6270 ecx = MEM32(eax); /* 0x380031C5: mov ecx, dword ptr [eax] */ 6271 edx = MEM32(eax + 0x4); /* 0x380031C7: mov edx, dword ptr [eax + 4] */ 6272 eax = MEM32(eax + 0x8); /* 0x380031CA: mov eax, dword ptr [eax + 8] */ 6273 MEM32(ebp + (-0x50)) = ecx; /* 0x380031CD: mov dword ptr [ebp - 0x50], ecx */ 6274 ecx = MEM32(ebp + (-0x14)); /* 0x380031D0: mov ecx, dword ptr [ebp - 0x14] */ 6275 MEM32(ebp + (-0x4C)) = edx; /* 0x380031D3: mov dword ptr [ebp - 0x4c], edx */ 6276 edx = MEM32(ebp + (-0x10)); /* 0x380031D6: mov edx, dword ptr [ebp - 0x10] */ 6277 MEM32(ebp + (-0x48)) = eax; /* 0x380031D9: mov dword ptr [ebp - 0x48], eax */ 6278 eax = MEM32(ebp + (-0xC)); /* 0x380031DC: mov eax, dword ptr [ebp - 0xc] */ 6279 MEM32(ebp + (-0x2C)) = ecx; /* 0x380031DF: mov dword ptr [ebp - 0x2c], ecx */ 6280 ecx = ebp + (-0x2C); /* 0x380031E2: lea ecx, [ebp - 0x2c] */ 6281 MEM32(ebp + (-0x28)) = edx; /* 0x380031E5: mov dword ptr [ebp - 0x28], edx */ 6282 MEM32(ebp + (-0x24)) = eax; /* 0x380031E8: mov dword ptr [ebp - 0x24], eax */ 6283 RECOMP_ICALL(MEM32(0x3804E4EC)); /* 0x380031EB: call dword ptr [0x3804e4ec] */ 6284 RECOMP_FLAGS_IN(); 6285 PUSH32(esp, ecx); /* 0x380031F1: push ecx */ 6286 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x380031F2: fstp dword ptr [esp] */ 6287 ecx = ebp + (-0x2C); /* 0x380031F5: lea ecx, [ebp - 0x2c] */ 6288 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x380031F8: call dword ptr [0x3804e4d4] */ 6289 RECOMP_FLAGS_IN(); 6290 ecx = MEM32(ebp + (-0x2C)); /* 0x380031FE: mov ecx, dword ptr [ebp - 0x2c] */ 6291 edx = MEM32(ebp + (-0x28)); /* 0x38003201: mov edx, dword ptr [ebp - 0x28] */ 6292 eax = MEM32(ebp + (-0x24)); /* 0x38003204: mov eax, dword ptr [ebp - 0x24] */ 6293 MEM32(ebp + (-0x38)) = ecx; /* 0x38003207: mov dword ptr [ebp - 0x38], ecx */ 6294 ecx = MEM32(ebp + (-0x1C)); /* 0x3800320A: mov ecx, dword ptr [ebp - 0x1c] */ 6295 MEM32(ebp + (-0x10)) = ecx; /* 0x3800320D: mov dword ptr [ebp - 0x10], ecx */ 6296 ecx = ebp + (-0x14); /* 0x38003210: lea ecx, [ebp - 0x14] */ 6297 MEM32(ebp + (-0x34)) = edx; /* 0x38003213: mov dword ptr [ebp - 0x34], edx */ 6298 MEM32(ebp + (-0x30)) = eax; /* 0x38003216: mov dword ptr [ebp - 0x30], eax */ 6299 MEM32(ebp + (-0x14)) = edi; /* 0x38003219: mov dword ptr [ebp - 0x14], edi */ 6300 MEM32(ebp + (-0xC)) = ebx; /* 0x3800321C: mov dword ptr [ebp - 0xc], ebx */ 6301 RECOMP_ICALL(MEM32(0x3804E4EC)); /* 0x3800321F: call dword ptr [0x3804e4ec] */ 6302 RECOMP_FLAGS_IN(); 6303 PUSH32(esp, ecx); /* 0x38003225: push ecx */ 6304 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38003226: fstp dword ptr [esp] */ 6305 ecx = ebp + (-0x14); /* 0x38003229: lea ecx, [ebp - 0x14] */ 6306 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x3800322C: call dword ptr [0x3804e4d4] */ 6307 RECOMP_FLAGS_IN(); 6308 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x38003232: fld dword ptr [ebp - 8] */ 6309 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ebp + (-0x4))); /* 0x38003235: fcomp dword ptr [ebp - 4] */ 6310 fp_pop(); 6311 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003238: fnstsw ax */ 6312 /* test HI8(eax), 1 */ /* 0x3800323A: test ah, 1 */ 6313 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 6314 _cf = 0; 6315 _flag_k = FK_NARROW(FK_TEST, 24); 6316 if (TEST_Z(_flag_a, _flag_b)) goto L_38003363; /* 0x3800323D: je 0x38003363 */ 6317 L_38003243: 6318 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x38003243: fld dword ptr [ebp - 4] */ 6319 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8CC)); /* 0x38003246: fcomp dword ptr [0x3804e8cc] */ 6320 fp_pop(); 6321 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3800324C: fnstsw ax */ 6322 /* test HI8(eax), 0x41u */ /* 0x3800324E: test ah, 0x41 */ 6323 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 6324 _cf = 0; 6325 _flag_k = FK_NARROW(FK_TEST, 24); 6326 if (TEST_NZ(_flag_a, _flag_b)) goto L_38003363; /* 0x38003251: jne 0x38003363 */ 6327 L_38003257: 6328 fp_push(*(float*)&MEM32(ebp + (-0x4C))); /* 0x38003257: fld dword ptr [ebp - 0x4c] */ 6329 _st[0] = fabs(_st[0]); /* 0x3800325A: fabs */ 6330 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E910)); /* 0x3800325C: fcomp qword ptr [0x3804e910] */ 6331 fp_pop(); 6332 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003262: fnstsw ax */ 6333 /* test HI8(eax), 1 */ /* 0x38003264: test ah, 1 */ 6334 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 6335 _cf = 0; 6336 _flag_k = FK_NARROW(FK_TEST, 24); 6337 if (TEST_Z(_flag_a, _flag_b)) goto L_38003363; /* 0x38003267: je 0x38003363 */ 6338 L_3800326D: 6339 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3800326D: fld dword ptr [ebp - 0xc] */ 6340 _st[0] *= (double)*(float*)ADDR(ebp + (-0x30)); /* 0x38003270: fmul dword ptr [ebp - 0x30] */ 6341 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38003273: fld dword ptr [ebp - 0x10] */ 6342 _st[0] *= (double)*(float*)ADDR(ebp + (-0x34)); /* 0x38003276: fmul dword ptr [ebp - 0x34] */ 6343 { double _v = fp_pop(); _st[0] += _v; } /* 0x38003279: faddp st(1) */ 6344 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x3800327B: fld dword ptr [ebp - 0x14] */ 6345 _st[0] *= (double)*(float*)ADDR(ebp + (-0x38)); /* 0x3800327E: fmul dword ptr [ebp - 0x38] */ 6346 { double _v = fp_pop(); _st[0] += _v; } /* 0x38003281: faddp st(1) */ 6347 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38003283: fcomp dword ptr [0x3804e8e4] */ 6348 fp_pop(); 6349 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003289: fnstsw ax */ 6350 /* test HI8(eax), 0x41u */ /* 0x3800328B: test ah, 0x41 */ 6351 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 6352 _cf = 0; 6353 _flag_k = FK_NARROW(FK_TEST, 24); 6354 if (TEST_NZ(_flag_a, _flag_b)) goto L_38003363; /* 0x3800328E: jne 0x38003363 */ 6355 L_38003294: 6356 fp_push(*(float*)&MEM32(ebp + (-0x4C))); /* 0x38003294: fld dword ptr [ebp - 0x4c] */ 6357 MEM32(ebp + 0x8) = 0xBF800000u; /* 0x38003297: mov dword ptr [ebp + 8], 0xbf800000 */ 6358 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x3800329E: fcomp dword ptr [0x3804e8e4] */ 6359 fp_pop(); 6360 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380032A4: fnstsw ax */ 6361 /* test HI8(eax), 1 */ /* 0x380032A6: test ah, 1 */ 6362 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 6363 _cf = 0; 6364 _flag_k = FK_NARROW(FK_TEST, 24); 6365 if (TEST_NZ(_flag_a, _flag_b)) goto L_380032B2; /* 0x380032A9: jne 0x380032b2 */ 6366 L_380032AB: 6367 MEM32(ebp + 0x8) = 0x3F800000u; /* 0x380032AB: mov dword ptr [ebp + 8], 0x3f800000 */ 6368 L_380032B2: 6369 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x380032B2: fld dword ptr [ebp - 0x18] */ 6370 MEM32(ebp + (-0x34)) = 0; /* 0x380032B5: mov dword ptr [ebp - 0x34], 0 */ 6371 eax = MEM32(ebp + (-0x34)); /* 0x380032BC: mov eax, dword ptr [ebp - 0x34] */ 6372 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x38)) = _v; } /* 0x380032BF: fstp dword ptr [ebp - 0x38] */ 6373 fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x380032C2: fld dword ptr [ebp - 0x20] */ 6374 edx = MEM32(ebp + (-0x38)); /* 0x380032C5: mov edx, dword ptr [ebp - 0x38] */ 6375 _st[0] = -_st[0]; /* 0x380032C8: fchs */ 6376 MEM32(ebp + (-0x5C)) = edx; /* 0x380032CA: mov dword ptr [ebp - 0x5c], edx */ 6377 edx = MEM32(ebp + 0x8); /* 0x380032CD: mov edx, dword ptr [ebp + 8] */ 6378 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x30)) = _v; } /* 0x380032D0: fstp dword ptr [ebp - 0x30] */ 6379 ecx = MEM32(ebp + (-0x30)); /* 0x380032D3: mov ecx, dword ptr [ebp - 0x30] */ 6380 MEM32(ebp + (-0x54)) = ecx; /* 0x380032D6: mov dword ptr [ebp - 0x54], ecx */ 6381 PUSH32(esp, edx); /* 0x380032D9: push edx */ 6382 ecx = ebp + (-0x5C); /* 0x380032DA: lea ecx, [ebp - 0x5c] */ 6383 MEM32(ebp + (-0x58)) = eax; /* 0x380032DD: mov dword ptr [ebp - 0x58], eax */ 6384 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x380032E0: call dword ptr [0x3804e4d4] */ 6385 RECOMP_FLAGS_IN(); 6386 ecx = MEM32(eax); /* 0x380032E6: mov ecx, dword ptr [eax] */ 6387 edx = MEM32(eax + 0x4); /* 0x380032E8: mov edx, dword ptr [eax + 4] */ 6388 eax = MEM32(eax + 0x8); /* 0x380032EB: mov eax, dword ptr [eax + 8] */ 6389 MEM32(ebp + (-0x50)) = ecx; /* 0x380032EE: mov dword ptr [ebp - 0x50], ecx */ 6390 PUSH32(esp, 0x3F000000u); /* 0x380032F1: push 0x3f000000 */ 6391 ecx = ebp + (-0x50); /* 0x380032F6: lea ecx, [ebp - 0x50] */ 6392 MEM32(ebp + (-0x4C)) = edx; /* 0x380032F9: mov dword ptr [ebp - 0x4c], edx */ 6393 MEM32(ebp + (-0x48)) = eax; /* 0x380032FC: mov dword ptr [ebp - 0x48], eax */ 6394 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x380032FF: call dword ptr [0x3804e4d4] */ 6395 RECOMP_FLAGS_IN(); 6396 ecx = MEM32(eax); /* 0x38003305: mov ecx, dword ptr [eax] */ 6397 MEM32(ebp + (-0x5C)) = ecx; /* 0x38003307: mov dword ptr [ebp - 0x5c], ecx */ 6398 edx = MEM32(eax + 0x4); /* 0x3800330A: mov edx, dword ptr [eax + 4] */ 6399 ecx = MEM32(ebp + (-0x44)); /* 0x3800330D: mov ecx, dword ptr [ebp - 0x44] */ 6400 MEM32(ebp + (-0x58)) = edx; /* 0x38003310: mov dword ptr [ebp - 0x58], edx */ 6401 eax = MEM32(eax + 0x8); /* 0x38003313: mov eax, dword ptr [eax + 8] */ 6402 edx = MEM32(ebp + (-0x40)); /* 0x38003316: mov edx, dword ptr [ebp - 0x40] */ 6403 MEM32(ebp + (-0x38)) = ecx; /* 0x38003319: mov dword ptr [ebp - 0x38], ecx */ 6404 ecx = ebp + (-0x5C); /* 0x3800331C: lea ecx, [ebp - 0x5c] */ 6405 MEM32(ebp + (-0x54)) = eax; /* 0x3800331F: mov dword ptr [ebp - 0x54], eax */ 6406 eax = MEM32(ebp + (-0x3C)); /* 0x38003322: mov eax, dword ptr [ebp - 0x3c] */ 6407 PUSH32(esp, ecx); /* 0x38003325: push ecx */ 6408 ecx = ebp + (-0x38); /* 0x38003326: lea ecx, [ebp - 0x38] */ 6409 MEM32(ebp + (-0x34)) = edx; /* 0x38003329: mov dword ptr [ebp - 0x34], edx */ 6410 MEM32(ebp + (-0x30)) = eax; /* 0x3800332C: mov dword ptr [ebp - 0x30], eax */ 6411 RECOMP_ICALL(MEM32(0x3804E4E8)); /* 0x3800332F: call dword ptr [0x3804e4e8] */ 6412 RECOMP_FLAGS_IN(); 6413 edx = MEM32(eax); /* 0x38003335: mov edx, dword ptr [eax] */ 6414 MEM32(ebp + (-0x2C)) = edx; /* 0x38003337: mov dword ptr [ebp - 0x2c], edx */ 6415 ecx = MEM32(eax + 0x4); /* 0x3800333A: mov ecx, dword ptr [eax + 4] */ 6416 MEM32(ebp + (-0x28)) = ecx; /* 0x3800333D: mov dword ptr [ebp - 0x28], ecx */ 6417 edx = MEM32(eax + 0x8); /* 0x38003340: mov edx, dword ptr [eax + 8] */ 6418 eax = MEM32(ebp + 0x10); /* 0x38003343: mov eax, dword ptr [ebp + 0x10] */ 6419 ecx = MEM32(ebp + 0xC); /* 0x38003346: mov ecx, dword ptr [ebp + 0xc] */ 6420 PUSH32(esp, eax); /* 0x38003349: push eax */ 6421 MEM32(ebp + (-0x24)) = edx; /* 0x3800334A: mov dword ptr [ebp - 0x24], edx */ 6422 PUSH32(esp, ecx); /* 0x3800334D: push ecx */ 6423 edx = ebp + (-0x2C); /* 0x3800334E: lea edx, [ebp - 0x2c] */ 6424 PUSH32(esp, edx); /* 0x38003351: push edx */ 6425 ecx = esi; /* 0x38003352: mov ecx, esi */ 6426 RECOMP_ICALL(MEM32(0x3804E6D8)); /* 0x38003354: call dword ptr [0x3804e6d8] */ 6427 RECOMP_FLAGS_IN(); 6428 edi = POP32_VAL(esp); /* 0x3800335A: pop edi */ 6429 esi = POP32_VAL(esp); /* 0x3800335B: pop esi */ 6430 ebx = POP32_VAL(esp); /* 0x3800335C: pop ebx */ 6431 esp = ebp; /* 0x3800335D: mov esp, ebp */ 6432 ebp = POP32_VAL(esp); /* 0x3800335F: pop ebp */ 6433 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x38003360: ret 0xc */ 6434 L_38003363: 6435 eax = MEM32(ebp + 0x10); /* 0x38003363: mov eax, dword ptr [ebp + 0x10] */ 6436 ecx = MEM32(ebp + 0xC); /* 0x38003366: mov ecx, dword ptr [ebp + 0xc] */ 6437 edx = MEM32(ebp + 0x8); /* 0x38003369: mov edx, dword ptr [ebp + 8] */ 6438 PUSH32(esp, eax); /* 0x3800336C: push eax */ 6439 PUSH32(esp, ecx); /* 0x3800336D: push ecx */ 6440 PUSH32(esp, edx); /* 0x3800336E: push edx */ 6441 ecx = esi; /* 0x3800336F: mov ecx, esi */ 6442 RECOMP_ICALL(MEM32(0x3804E6D8)); /* 0x38003371: call dword ptr [0x3804e6d8] */ 6443 RECOMP_FLAGS_IN(); 6444 edi = POP32_VAL(esp); /* 0x38003377: pop edi */ 6445 esi = POP32_VAL(esp); /* 0x38003378: pop esi */ 6446 ebx = POP32_VAL(esp); /* 0x38003379: pop ebx */ 6447 esp = ebp; /* 0x3800337A: mov esp, ebp */ 6448 ebp = POP32_VAL(esp); /* 0x3800337C: pop ebp */ 6449 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3800337D: ret 0xc */ 6450 RECOMP_REGS_OUT(); 6451 } 6452 6453 void sub_38003380(void) { 6454 int _fpu_cmp = 0; 6455 uint32_t _cf = 0; 6456 int _df = 1; 6457 uint32_t _flag_k = FK_NONE; 6458 uint32_t _flag_a = 0, _flag_b = 0; 6459 uint32_t _itail_tgt = 0; 6460 RECOMP_REGS_LOCALS 6461 RECOMP_ENTER(0x38003380u); 6462 6463 L_38003380: 6464 eax = MEM32(ecx + 0x17C); /* 0x38003380: mov eax, dword ptr [ecx + 0x17c] */ 6465 /* test eax, eax */ /* 0x38003386: test eax, eax */ 6466 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 6467 _cf = 0; 6468 _flag_k = FK_TEST; 6469 if (TEST_Z(_flag_a, _flag_b)) goto L_38003396; /* 0x38003388: je 0x38003396 */ 6470 L_3800338A: 6471 edx = MEM32(eax); /* 0x3800338A: mov edx, dword ptr [eax] */ 6472 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0x54u); 6473 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 6474 ecx = ecx + 0x54u; /* 0x3800338C: add ecx, 0x54 */ 6475 _flag_k = FK_ADD; 6476 PUSH32(esp, ecx); /* 0x3800338F: push ecx */ 6477 ecx = eax; /* 0x38003390: mov ecx, eax */ 6478 RECOMP_ICALL(MEM32(edx + 0x14)); /* 0x38003392: call dword ptr [edx + 0x14] */ 6479 RECOMP_FLAGS_IN(); 6480 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38003395: ret */ 6481 L_38003396: 6482 eax = ecx + 0x54; /* 0x38003396: lea eax, [ecx + 0x54] */ 6483 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38003399: ret */ 6484 RECOMP_REGS_OUT(); 6485 } 6486 6487 void sub_380033A0(void) { 6488 int _fpu_cmp = 0; 6489 uint32_t _cf = 0; 6490 int _df = 1; 6491 uint32_t _flag_k = FK_NONE; 6492 uint32_t _flag_a = 0, _flag_b = 0; 6493 uint32_t _itail_tgt = 0; 6494 RECOMP_REGS_LOCALS 6495 RECOMP_ENTER(0x380033A0u); 6496 6497 L_380033A0: 6498 goto L_38014260; /* 0x380033A0: jmp 0x38014260 */ 6499 L_38014260: 6500 PUSH32(esp, esi); /* 0x38014260: push esi */ 6501 esi = ecx; /* 0x38014261: mov esi, ecx */ 6502 RECOMP_ICALL(0x38014350u); /* 0x38014263: call 0x38014350 */ /* not lifted */ 6503 RECOMP_FLAGS_IN(); 6504 /* test LO8(eax), LO8(eax) */ /* 0x38014268: test al, al */ 6505 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 6506 _cf = 0; 6507 _flag_k = FK_NARROW(FK_TEST, 24); 6508 if (TEST_NZ(_flag_a, _flag_b)) goto L_38014270; /* 0x3801426A: jne 0x38014270 */ 6509 L_3801426C: 6510 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 6511 eax = 0; /* 0x3801426C: xor eax, eax */ 6512 _cf = 0; 6513 _flag_k = FK_TEST; 6514 esi = POP32_VAL(esp); /* 0x3801426E: pop esi */ 6515 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3801426F: ret */ 6516 L_38014270: 6517 eax = MEM32(esi + 0x130); /* 0x38014270: mov eax, dword ptr [esi + 0x130] */ 6518 /* test eax, eax */ /* 0x38014276: test eax, eax */ 6519 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 6520 _cf = 0; 6521 _flag_k = FK_TEST; 6522 if (TEST_NZ(_flag_a, _flag_b)) goto L_3801429A; /* 0x38014278: jne 0x3801429a */ 6523 L_3801427A: 6524 eax = MEM32(esi + 0x134); /* 0x3801427A: mov eax, dword ptr [esi + 0x134] */ 6525 PUSH32(esp, eax); /* 0x38014280: push eax */ 6526 RECOMP_ICALL(0x380295A0u); /* 0x38014281: call 0x380295a0 */ /* not lifted */ 6527 RECOMP_FLAGS_IN(); 6528 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4); 6529 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 6530 esp = esp + 4; /* 0x38014286: add esp, 4 */ 6531 _flag_k = FK_ADD; 6532 /* test eax, eax */ /* 0x38014289: test eax, eax */ 6533 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 6534 _cf = 0; 6535 _flag_k = FK_TEST; 6536 if (TEST_Z(_flag_a, _flag_b)) goto L_3801429A; /* 0x3801428B: je 0x3801429a */ 6537 L_3801428D: 6538 ecx = eax; /* 0x3801428D: mov ecx, eax */ 6539 RECOMP_ICALL(0x3802BF20u); /* 0x3801428F: call 0x3802bf20 */ /* not lifted */ 6540 RECOMP_FLAGS_IN(); 6541 MEM32(esi + 0x130) = eax; /* 0x38014294: mov dword ptr [esi + 0x130], eax */ 6542 L_3801429A: 6543 eax = MEM32(esi + 0x130); /* 0x3801429A: mov eax, dword ptr [esi + 0x130] */ 6544 esi = POP32_VAL(esp); /* 0x380142A0: pop esi */ 6545 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x380142A1: ret */ 6546 RECOMP_REGS_OUT(); 6547 } 6548 6549 void sub_380033B0(void) { 6550 int _fpu_cmp = 0; 6551 uint32_t _cf = 0; 6552 int _df = 1; 6553 uint32_t _flag_k = FK_NONE; 6554 uint32_t _flag_a = 0, _flag_b = 0; 6555 uint32_t _itail_tgt = 0; 6556 RECOMP_REGS_LOCALS 6557 RECOMP_ENTER(0x380033B0u); 6558 6559 L_380033B0: 6560 PUSH32(esp, ebp); /* 0x380033B0: push ebp */ 6561 ebp = esp; /* 0x380033B1: mov ebp, esp */ 6562 eax = MEM32(ebp + 0x8); /* 0x380033B3: mov eax, dword ptr [ebp + 8] */ 6563 MEM32(ecx + 0x178) = eax; /* 0x380033B6: mov dword ptr [ecx + 0x178], eax */ 6564 ebp = POP32_VAL(esp); /* 0x380033BC: pop ebp */ 6565 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380033BD: ret 4 */ 6566 RECOMP_REGS_OUT(); 6567 } 6568 6569 void sub_380033C0(void) { 6570 int _fpu_cmp = 0; 6571 uint32_t _cf = 0; 6572 int _df = 1; 6573 uint32_t _flag_k = FK_NONE; 6574 uint32_t _flag_a = 0, _flag_b = 0; 6575 uint32_t _itail_tgt = 0; 6576 RECOMP_REGS_LOCALS 6577 RECOMP_ENTER(0x380033C0u); 6578 6579 L_380033C0: 6580 PUSH32(esp, ebp); /* 0x380033C0: push ebp */ 6581 ebp = esp; /* 0x380033C1: mov ebp, esp */ 6582 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x18u); 6583 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 6584 esp = esp - 0x18u; /* 0x380033C3: sub esp, 0x18 */ 6585 _flag_k = FK_CMP; 6586 PUSH32(esp, esi); /* 0x380033C6: push esi */ 6587 PUSH32(esp, edi); /* 0x380033C7: push edi */ 6588 edi = MEM32(ebp + 0x8); /* 0x380033C8: mov edi, dword ptr [ebp + 8] */ 6589 eax = MEM32(edi); /* 0x380033CB: mov eax, dword ptr [edi] */ 6590 esi = ecx; /* 0x380033CD: mov esi, ecx */ 6591 /* cmp eax, MEM32(esi + 0x138) */ /* 0x380033CF: cmp eax, dword ptr [esi + 0x138] */ 6592 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(esi + 0x138)); 6593 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 6594 _flag_k = FK_CMP; 6595 if (CMP_EQ(_flag_a, _flag_b)) goto L_380034DF; /* 0x380033D5: je 0x380034df */ 6596 L_380033DB: 6597 PUSH32(esp, ebx); /* 0x380033DB: push ebx */ 6598 edx = ebp + (-0x18); /* 0x380033DC: lea edx, [ebp - 0x18] */ 6599 ecx = esi + (-0x20); /* 0x380033DF: lea ecx, [esi - 0x20] */ 6600 PUSH32(esp, edx); /* 0x380033E2: push edx */ 6601 RECOMP_ICALL(0x38001F50u); /* 0x380033E3: call 0x38001f50 */ /* not lifted */ 6602 RECOMP_FLAGS_IN(); 6603 ecx = esi + 0xC8; /* 0x380033E8: lea ecx, [esi + 0xc8] */ 6604 edx = ecx; /* 0x380033EE: mov edx, ecx */ 6605 ebx = MEM32(edx); /* 0x380033F0: mov ebx, dword ptr [edx] */ 6606 MEM32(ebp + (-0xC)) = ebx; /* 0x380033F2: mov dword ptr [ebp - 0xc], ebx */ 6607 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x380033F5: fld dword ptr [ebp - 0xc] */ 6608 ebx = MEM32(edx + 0x4); /* 0x380033F8: mov ebx, dword ptr [edx + 4] */ 6609 _st[0] -= (double)*(float*)ADDR(eax); /* 0x380033FB: fsub dword ptr [eax] */ 6610 edx = MEM32(edx + 0x8); /* 0x380033FD: mov edx, dword ptr [edx + 8] */ 6611 MEM32(ebp + (-0x4)) = edx; /* 0x38003400: mov dword ptr [ebp - 4], edx */ 6612 MEM32(ebp + (-0x8)) = ebx; /* 0x38003403: mov dword ptr [ebp - 8], ebx */ 6613 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x38003406: fstp dword ptr [ebp - 0xc] */ 6614 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x38003409: fld dword ptr [ebp - 8] */ 6615 edx = MEM32(ebp + (-0xC)); /* 0x3800340C: mov edx, dword ptr [ebp - 0xc] */ 6616 _st[0] -= (double)*(float*)ADDR(eax + 0x4); /* 0x3800340F: fsub dword ptr [eax + 4] */ 6617 PUSH32(esp, 0); /* 0x38003412: push 0 */ 6618 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x38003414: fstp dword ptr [ebp - 8] */ 6619 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x38003417: fld dword ptr [ebp - 4] */ 6620 _st[0] -= (double)*(float*)ADDR(eax + 0x8); /* 0x3800341A: fsub dword ptr [eax + 8] */ 6621 eax = esi + 0x198; /* 0x3800341D: lea eax, [esi + 0x198] */ 6622 MEM32(eax) = edx; /* 0x38003423: mov dword ptr [eax], edx */ 6623 edx = MEM32(ebp + (-0x8)); /* 0x38003425: mov edx, dword ptr [ebp - 8] */ 6624 MEM32(eax + 0x4) = edx; /* 0x38003428: mov dword ptr [eax + 4], edx */ 6625 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3800342B: fstp dword ptr [ebp - 4] */ 6626 edx = MEM32(ebp + (-0x4)); /* 0x3800342E: mov edx, dword ptr [ebp - 4] */ 6627 MEM32(eax + 0x8) = edx; /* 0x38003431: mov dword ptr [eax + 8], edx */ 6628 eax = esi + 0x34; /* 0x38003434: lea eax, [esi + 0x34] */ 6629 edx = eax; /* 0x38003437: mov edx, eax */ 6630 ebx = MEM32(edx); /* 0x38003439: mov ebx, dword ptr [edx] */ 6631 MEM32(ecx) = ebx; /* 0x3800343B: mov dword ptr [ecx], ebx */ 6632 ebx = MEM32(edx + 0x4); /* 0x3800343D: mov ebx, dword ptr [edx + 4] */ 6633 MEM32(ecx + 0x4) = ebx; /* 0x38003440: mov dword ptr [ecx + 4], ebx */ 6634 edx = MEM32(edx + 0x8); /* 0x38003443: mov edx, dword ptr [edx + 8] */ 6635 MEM32(ecx + 0x8) = edx; /* 0x38003446: mov dword ptr [ecx + 8], edx */ 6636 edx = MEM32(edi + 0x4); /* 0x38003449: mov edx, dword ptr [edi + 4] */ 6637 ebx = MEM32(edx); /* 0x3800344C: mov ebx, dword ptr [edx] */ 6638 ecx = esi + 0x11C; /* 0x3800344E: lea ecx, [esi + 0x11c] */ 6639 MEM32(ecx) = ebx; /* 0x38003454: mov dword ptr [ecx], ebx */ 6640 ebx = MEM32(edx + 0x4); /* 0x38003456: mov ebx, dword ptr [edx + 4] */ 6641 MEM32(ecx + 0x4) = ebx; /* 0x38003459: mov dword ptr [ecx + 4], ebx */ 6642 edx = MEM32(edx + 0x8); /* 0x3800345C: mov edx, dword ptr [edx + 8] */ 6643 MEM32(ecx + 0x8) = edx; /* 0x3800345F: mov dword ptr [ecx + 8], edx */ 6644 edx = MEM32(edi + 0x8); /* 0x38003462: mov edx, dword ptr [edi + 8] */ 6645 ebx = MEM32(edx); /* 0x38003465: mov ebx, dword ptr [edx] */ 6646 ecx = esi + 0x128; /* 0x38003467: lea ecx, [esi + 0x128] */ 6647 MEM32(ecx) = ebx; /* 0x3800346D: mov dword ptr [ecx], ebx */ 6648 ebx = MEM32(edx + 0x4); /* 0x3800346F: mov ebx, dword ptr [edx + 4] */ 6649 MEM32(ecx + 0x4) = ebx; /* 0x38003472: mov dword ptr [ecx + 4], ebx */ 6650 ebx = MEM32(edx + 0x8); /* 0x38003475: mov ebx, dword ptr [edx + 8] */ 6651 MEM32(ecx + 0x8) = ebx; /* 0x38003478: mov dword ptr [ecx + 8], ebx */ 6652 edx = MEM32(edx + 0xC); /* 0x3800347B: mov edx, dword ptr [edx + 0xc] */ 6653 MEM32(ecx + 0xC) = edx; /* 0x3800347E: mov dword ptr [ecx + 0xc], edx */ 6654 PUSH32(esp, eax); /* 0x38003481: push eax */ 6655 ecx = esi + (-0x20); /* 0x38003482: lea ecx, [esi - 0x20] */ 6656 RECOMP_ICALL(MEM32(0x3804E6D0)); /* 0x38003485: call dword ptr [0x3804e6d0] */ 6657 RECOMP_FLAGS_IN(); 6658 eax = MEM32(edi); /* 0x3800348B: mov eax, dword ptr [edi] */ 6659 PUSH32(esp, 0); /* 0x3800348D: push 0 */ 6660 PUSH32(esp, 0x3806B5C0u); /* 0x3800348F: push 0x3806b5c0 */ 6661 PUSH32(esp, 0x3806B5A0u); /* 0x38003494: push 0x3806b5a0 */ 6662 PUSH32(esp, 0); /* 0x38003499: push 0 */ 6663 PUSH32(esp, eax); /* 0x3800349B: push eax */ 6664 RECOMP_ICALL(0x3804B682u); /* 0x3800349C: call 0x3804b682 */ /* not lifted */ 6665 RECOMP_FLAGS_IN(); 6666 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x14u); 6667 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 6668 esp = esp + 0x14u; /* 0x380034A1: add esp, 0x14 */ 6669 _flag_k = FK_ADD; 6670 /* test eax, eax */ /* 0x380034A4: test eax, eax */ 6671 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 6672 _cf = 0; 6673 _flag_k = FK_TEST; 6674 ebx = POP32_VAL(esp); /* 0x380034A6: pop ebx */ 6675 if (TEST_Z(_flag_a, _flag_b)) goto L_38003528; /* 0x380034A7: je 0x38003528 */ 6676 L_380034A9: 6677 fp_push(*(float*)&MEM32(eax + 0xD8)); /* 0x380034A9: fld dword ptr [eax + 0xd8] */ 6678 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E928)); /* 0x380034AF: fcomp qword ptr [0x3804e928] */ 6679 fp_pop(); 6680 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380034B5: fnstsw ax */ 6681 /* test HI8(eax), 0x40u */ /* 0x380034B7: test ah, 0x40 */ 6682 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6683 _cf = 0; 6684 _flag_k = FK_NARROW(FK_TEST, 24); 6685 if (TEST_Z(_flag_a, _flag_b)) goto L_380034CF; /* 0x380034BA: je 0x380034cf */ 6686 L_380034BC: 6687 eax = 1; /* 0x380034BC: mov eax, 1 */ 6688 edi = POP32_VAL(esp); /* 0x380034C1: pop edi */ 6689 MEM8(esi + 0x1A7) = (uint8_t)(LO8(eax)); /* 0x380034C2: mov byte ptr [esi + 0x1a7], al */ 6690 esi = POP32_VAL(esp); /* 0x380034C8: pop esi */ 6691 esp = ebp; /* 0x380034C9: mov esp, ebp */ 6692 ebp = POP32_VAL(esp); /* 0x380034CB: pop ebp */ 6693 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380034CC: ret 4 */ 6694 L_380034CF: 6695 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 6696 eax = 0; /* 0x380034CF: xor eax, eax */ 6697 _cf = 0; 6698 _flag_k = FK_TEST; 6699 edi = POP32_VAL(esp); /* 0x380034D1: pop edi */ 6700 MEM8(esi + 0x1A7) = (uint8_t)(LO8(eax)); /* 0x380034D2: mov byte ptr [esi + 0x1a7], al */ 6701 esi = POP32_VAL(esp); /* 0x380034D8: pop esi */ 6702 esp = ebp; /* 0x380034D9: mov esp, ebp */ 6703 ebp = POP32_VAL(esp); /* 0x380034DB: pop ebp */ 6704 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380034DC: ret 4 */ 6705 L_380034DF: 6706 ecx = MEM32(edi + 0x4); /* 0x380034DF: mov ecx, dword ptr [edi + 4] */ 6707 edx = MEM32(ecx); /* 0x380034E2: mov edx, dword ptr [ecx] */ 6708 eax = MEM32(ecx + 0x4); /* 0x380034E4: mov eax, dword ptr [ecx + 4] */ 6709 ecx = MEM32(ecx + 0x8); /* 0x380034E7: mov ecx, dword ptr [ecx + 8] */ 6710 MEM32(ebp + (-0xC)) = edx; /* 0x380034EA: mov dword ptr [ebp - 0xc], edx */ 6711 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x380034ED: fld dword ptr [ebp - 0xc] */ 6712 _st[0] += (double)*(float*)ADDR(esi + 0x148); /* 0x380034F0: fadd dword ptr [esi + 0x148] */ 6713 MEM32(ebp + (-0x8)) = eax; /* 0x380034F6: mov dword ptr [ebp - 8], eax */ 6714 MEM32(ebp + (-0x4)) = ecx; /* 0x380034F9: mov dword ptr [ebp - 4], ecx */ 6715 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0x18Cu); 6716 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 6717 esi = esi + 0x18Cu; /* 0x380034FC: add esi, 0x18c */ 6718 _flag_k = FK_ADD; 6719 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x38003502: fstp dword ptr [ebp - 0xc] */ 6720 edx = MEM32(ebp + (-0xC)); /* 0x38003505: mov edx, dword ptr [ebp - 0xc] */ 6721 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x38003508: fld dword ptr [ebp - 8] */ 6722 _st[0] += (double)*(float*)ADDR(esi + (-0x40)); /* 0x3800350B: fadd dword ptr [esi - 0x40] */ 6723 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3800350E: fstp dword ptr [ebp - 8] */ 6724 eax = MEM32(ebp + (-0x8)); /* 0x38003511: mov eax, dword ptr [ebp - 8] */ 6725 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x38003514: fld dword ptr [ebp - 4] */ 6726 _st[0] += (double)*(float*)ADDR(esi + (-0x3C)); /* 0x38003517: fadd dword ptr [esi - 0x3c] */ 6727 MEM32(esi) = edx; /* 0x3800351A: mov dword ptr [esi], edx */ 6728 MEM32(esi + 0x4) = eax; /* 0x3800351C: mov dword ptr [esi + 4], eax */ 6729 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3800351F: fstp dword ptr [ebp - 4] */ 6730 ecx = MEM32(ebp + (-0x4)); /* 0x38003522: mov ecx, dword ptr [ebp - 4] */ 6731 MEM32(esi + 0x8) = ecx; /* 0x38003525: mov dword ptr [esi + 8], ecx */ 6732 L_38003528: 6733 edi = POP32_VAL(esp); /* 0x38003528: pop edi */ 6734 esi = POP32_VAL(esp); /* 0x38003529: pop esi */ 6735 esp = ebp; /* 0x3800352A: mov esp, ebp */ 6736 ebp = POP32_VAL(esp); /* 0x3800352C: pop ebp */ 6737 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800352D: ret 4 */ 6738 RECOMP_REGS_OUT(); 6739 } 6740 6741 void sub_38003530(void) { 6742 int _fpu_cmp = 0; 6743 uint32_t _cf = 0; 6744 int _df = 1; 6745 uint32_t _flag_k = FK_NONE; 6746 uint32_t _flag_a = 0, _flag_b = 0; 6747 uint32_t _itail_tgt = 0; 6748 RECOMP_REGS_LOCALS 6749 RECOMP_ENTER(0x38003530u); 6750 6751 L_38003530: 6752 PUSH32(esp, ebp); /* 0x38003530: push ebp */ 6753 ebp = esp; /* 0x38003531: mov ebp, esp */ 6754 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x18u); 6755 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 6756 esp = esp - 0x18u; /* 0x38003533: sub esp, 0x18 */ 6757 _flag_k = FK_CMP; 6758 PUSH32(esp, esi); /* 0x38003536: push esi */ 6759 eax = ebp + (-0x18); /* 0x38003537: lea eax, [ebp - 0x18] */ 6760 esi = ecx; /* 0x3800353A: mov esi, ecx */ 6761 PUSH32(esp, eax); /* 0x3800353C: push eax */ 6762 RECOMP_ICALL(0x38001F50u); /* 0x3800353D: call 0x38001f50 */ /* not lifted */ 6763 RECOMP_FLAGS_IN(); 6764 ecx = MEM32(eax); /* 0x38003542: mov ecx, dword ptr [eax] */ 6765 edx = MEM32(eax + 0x4); /* 0x38003544: mov edx, dword ptr [eax + 4] */ 6766 eax = MEM32(eax + 0x8); /* 0x38003547: mov eax, dword ptr [eax + 8] */ 6767 MEM32(ebp + (-0xC)) = ecx; /* 0x3800354A: mov dword ptr [ebp - 0xc], ecx */ 6768 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3800354D: fld dword ptr [ebp - 0xc] */ 6769 _st[0] -= (double)*(float*)ADDR(esi + 0x54); /* 0x38003550: fsub dword ptr [esi + 0x54] */ 6770 ecx = MEM32(ebp + 0x8); /* 0x38003553: mov ecx, dword ptr [ebp + 8] */ 6771 MEM32(ebp + (-0x8)) = edx; /* 0x38003556: mov dword ptr [ebp - 8], edx */ 6772 MEM32(ebp + (-0x4)) = eax; /* 0x38003559: mov dword ptr [ebp - 4], eax */ 6773 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3800355C: fstp dword ptr [ebp - 0xc] */ 6774 eax = MEM32(ebp + (-0xC)); /* 0x3800355F: mov eax, dword ptr [ebp - 0xc] */ 6775 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x38003562: fld dword ptr [ebp - 8] */ 6776 edx = ecx; /* 0x38003565: mov edx, ecx */ 6777 _st[0] -= (double)*(float*)ADDR(esi + 0x58); /* 0x38003567: fsub dword ptr [esi + 0x58] */ 6778 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3800356A: fstp dword ptr [ebp - 8] */ 6779 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3800356D: fld dword ptr [ebp - 4] */ 6780 _st[0] -= (double)*(float*)ADDR(esi + 0x5C); /* 0x38003570: fsub dword ptr [esi + 0x5c] */ 6781 MEM32(edx) = eax; /* 0x38003573: mov dword ptr [edx], eax */ 6782 eax = MEM32(ebp + (-0x8)); /* 0x38003575: mov eax, dword ptr [ebp - 8] */ 6783 MEM32(edx + 0x4) = eax; /* 0x38003578: mov dword ptr [edx + 4], eax */ 6784 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3800357B: fstp dword ptr [ebp - 4] */ 6785 eax = MEM32(ebp + (-0x4)); /* 0x3800357E: mov eax, dword ptr [ebp - 4] */ 6786 MEM32(edx + 0x8) = eax; /* 0x38003581: mov dword ptr [edx + 8], eax */ 6787 fp_push(*(float*)&MEM32(ecx)); /* 0x38003584: fld dword ptr [ecx] */ 6788 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38003586: fcomp dword ptr [0x3804e8e4] */ 6789 fp_pop(); 6790 esi = POP32_VAL(esp); /* 0x3800358C: pop esi */ 6791 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3800358D: fnstsw ax */ 6792 /* test HI8(eax), 0x40u */ /* 0x3800358F: test ah, 0x40 */ 6793 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6794 _cf = 0; 6795 _flag_k = FK_NARROW(FK_TEST, 24); 6796 if (TEST_Z(_flag_a, _flag_b)) goto L_380035D2; /* 0x38003592: je 0x380035d2 */ 6797 L_38003594: 6798 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x38003594: fld dword ptr [ecx + 4] */ 6799 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38003597: fcomp dword ptr [0x3804e8e4] */ 6800 fp_pop(); 6801 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3800359D: fnstsw ax */ 6802 /* test HI8(eax), 0x40u */ /* 0x3800359F: test ah, 0x40 */ 6803 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6804 _cf = 0; 6805 _flag_k = FK_NARROW(FK_TEST, 24); 6806 if (TEST_Z(_flag_a, _flag_b)) goto L_380035D2; /* 0x380035A2: je 0x380035d2 */ 6807 L_380035A4: 6808 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x380035A4: fld dword ptr [ecx + 8] */ 6809 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x380035A7: fcomp dword ptr [0x3804e8e4] */ 6810 fp_pop(); 6811 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380035AD: fnstsw ax */ 6812 /* test HI8(eax), 0x40u */ /* 0x380035AF: test ah, 0x40 */ 6813 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6814 _cf = 0; 6815 _flag_k = FK_NARROW(FK_TEST, 24); 6816 if (TEST_Z(_flag_a, _flag_b)) goto L_380035D2; /* 0x380035B2: je 0x380035d2 */ 6817 L_380035B4: 6818 edx = MEM32(0x3804E6E4); /* 0x380035B4: mov edx, dword ptr [0x3804e6e4] */ 6819 eax = MEM32(edx); /* 0x380035BA: mov eax, dword ptr [edx] */ 6820 MEM32(ecx) = eax; /* 0x380035BC: mov dword ptr [ecx], eax */ 6821 eax = MEM32(edx + 0x4); /* 0x380035BE: mov eax, dword ptr [edx + 4] */ 6822 MEM32(ecx + 0x4) = eax; /* 0x380035C1: mov dword ptr [ecx + 4], eax */ 6823 edx = MEM32(edx + 0x8); /* 0x380035C4: mov edx, dword ptr [edx + 8] */ 6824 MEM32(ecx + 0x8) = edx; /* 0x380035C7: mov dword ptr [ecx + 8], edx */ 6825 SET_LO8(eax, 1); /* 0x380035CA: mov al, 1 */ 6826 esp = ebp; /* 0x380035CC: mov esp, ebp */ 6827 ebp = POP32_VAL(esp); /* 0x380035CE: pop ebp */ 6828 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380035CF: ret 4 */ 6829 L_380035D2: 6830 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x380035D2: fld dword ptr [ecx + 8] */ 6831 SET_LO8(eax, 1); /* 0x380035D5: mov al, 1 */ 6832 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x380035D7: fld dword ptr [ecx + 4] */ 6833 fp_push(*(float*)&MEM32(ecx)); /* 0x380035DA: fld dword ptr [ecx] */ 6834 fp_push(_st[2]); /* 0x380035DC: fld st(2) */ 6835 { double _v = fp_pop(); _st[2] *= _v; } /* 0x380035DE: fmulp st(3) */ 6836 fp_push(_st[1]); /* 0x380035E0: fld st(1) */ 6837 _st[0] *= _st[2]; /* 0x380035E2: fmul st(2) */ 6838 { double _v = fp_pop(); _st[2] += _v; } /* 0x380035E4: faddp st(3) */ 6839 fp_push(_st[0]); /* 0x380035E6: fld st(0) */ 6840 _st[0] *= _st[1]; /* 0x380035E8: fmul st(1) */ 6841 { double _v = fp_pop(); _st[2] += _v; } /* 0x380035EA: faddp st(3) */ 6842 fp_xch(2); /* 0x380035EC: fxch st(2) */ 6843 _st[0] = sqrt(_st[0]); /* 0x380035EE: fsqrt */ 6844 fp_xch(2); /* 0x380035F0: fxch st(2) */ 6845 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x380035F2: fstp st(0) */ 6846 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x380035F4: fstp st(0) */ 6847 _st[0] = (double)*(float*)ADDR(0x3804E8CC) / _st[0]; /* 0x380035F6: fdivr dword ptr [0x3804e8cc] */ 6848 fp_push(_st[0]); /* 0x380035FC: fld st(0) */ 6849 _st[0] *= (double)*(float*)ADDR(ecx); /* 0x380035FE: fmul dword ptr [ecx] */ 6850 { float _v = (float)fp_pop(); *(float*)ADDR(ecx) = _v; } /* 0x38003600: fstp dword ptr [ecx] */ 6851 fp_push(_st[0]); /* 0x38003602: fld st(0) */ 6852 _st[0] *= (double)*(float*)ADDR(ecx + 0x4); /* 0x38003604: fmul dword ptr [ecx + 4] */ 6853 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x4) = _v; } /* 0x38003607: fstp dword ptr [ecx + 4] */ 6854 _st[0] *= (double)*(float*)ADDR(ecx + 0x8); /* 0x3800360A: fmul dword ptr [ecx + 8] */ 6855 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x8) = _v; } /* 0x3800360D: fstp dword ptr [ecx + 8] */ 6856 esp = ebp; /* 0x38003610: mov esp, ebp */ 6857 ebp = POP32_VAL(esp); /* 0x38003612: pop ebp */ 6858 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38003613: ret 4 */ 6859 RECOMP_REGS_OUT(); 6860 } 6861 6862 void sub_38003620(void) { 6863 int _fpu_cmp = 0; 6864 uint32_t _cf = 0; 6865 int _df = 1; 6866 uint32_t _flag_k = FK_NONE; 6867 uint32_t _flag_a = 0, _flag_b = 0; 6868 uint32_t _itail_tgt = 0; 6869 RECOMP_REGS_LOCALS 6870 RECOMP_ENTER(0x38003620u); 6871 6872 L_38003620: 6873 PUSH32(esp, ebp); /* 0x38003620: push ebp */ 6874 ebp = esp; /* 0x38003621: mov ebp, esp */ 6875 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x1Cu); 6876 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 6877 esp = esp - 0x1Cu; /* 0x38003623: sub esp, 0x1c */ 6878 _flag_k = FK_CMP; 6879 eax = MEM32(0x3804E6E0); /* 0x38003626: mov eax, dword ptr [0x3804e6e0] */ 6880 PUSH32(esp, esi); /* 0x3800362B: push esi */ 6881 esi = MEM32(ebp + 0x8); /* 0x3800362C: mov esi, dword ptr [ebp + 8] */ 6882 PUSH32(esp, edi); /* 0x3800362F: push edi */ 6883 edi = MEM32(eax); /* 0x38003630: mov edi, dword ptr [eax] */ 6884 edx = esi; /* 0x38003632: mov edx, esi */ 6885 MEM32(edx) = edi; /* 0x38003634: mov dword ptr [edx], edi */ 6886 edi = MEM32(eax + 0x4); /* 0x38003636: mov edi, dword ptr [eax + 4] */ 6887 MEM32(edx + 0x4) = edi; /* 0x38003639: mov dword ptr [edx + 4], edi */ 6888 eax = MEM32(eax + 0x8); /* 0x3800363C: mov eax, dword ptr [eax + 8] */ 6889 MEM32(edx + 0x8) = eax; /* 0x3800363F: mov dword ptr [edx + 8], eax */ 6890 edx = MEM32(ecx); /* 0x38003642: mov edx, dword ptr [ecx] */ 6891 eax = ebp + (-0x10); /* 0x38003644: lea eax, [ebp - 0x10] */ 6892 PUSH32(esp, eax); /* 0x38003647: push eax */ 6893 MEM32(ebp + (-0x10)) = 0; /* 0x38003648: mov dword ptr [ebp - 0x10], 0 */ 6894 MEM32(ebp + (-0xC)) = 0; /* 0x3800364F: mov dword ptr [ebp - 0xc], 0 */ 6895 MEM32(ebp + (-0x8)) = 0; /* 0x38003656: mov dword ptr [ebp - 8], 0 */ 6896 RECOMP_ICALL(MEM32(edx + 0x70)); /* 0x3800365D: call dword ptr [edx + 0x70] */ 6897 RECOMP_FLAGS_IN(); 6898 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38003660: fld dword ptr [ebp - 0x10] */ 6899 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38003663: fcomp dword ptr [0x3804e8e4] */ 6900 fp_pop(); 6901 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003669: fnstsw ax */ 6902 /* test HI8(eax), 0x40u */ /* 0x3800366B: test ah, 0x40 */ 6903 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6904 _cf = 0; 6905 _flag_k = FK_NARROW(FK_TEST, 24); 6906 if (TEST_Z(_flag_a, _flag_b)) goto L_380036B0; /* 0x3800366E: je 0x380036b0 */ 6907 L_38003670: 6908 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x38003670: fld dword ptr [ebp - 0xc] */ 6909 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38003673: fcomp dword ptr [0x3804e8e4] */ 6910 fp_pop(); 6911 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003679: fnstsw ax */ 6912 /* test HI8(eax), 0x40u */ /* 0x3800367B: test ah, 0x40 */ 6913 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6914 _cf = 0; 6915 _flag_k = FK_NARROW(FK_TEST, 24); 6916 if (TEST_Z(_flag_a, _flag_b)) goto L_380036B0; /* 0x3800367E: je 0x380036b0 */ 6917 L_38003680: 6918 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x38003680: fld dword ptr [ebp - 8] */ 6919 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38003683: fcomp dword ptr [0x3804e8e4] */ 6920 fp_pop(); 6921 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003689: fnstsw ax */ 6922 /* test HI8(eax), 0x40u */ /* 0x3800368B: test ah, 0x40 */ 6923 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6924 _cf = 0; 6925 _flag_k = FK_NARROW(FK_TEST, 24); 6926 if (TEST_Z(_flag_a, _flag_b)) goto L_380036B0; /* 0x3800368E: je 0x380036b0 */ 6927 L_38003690: 6928 ecx = MEM32(0x3804E6E0); /* 0x38003690: mov ecx, dword ptr [0x3804e6e0] */ 6929 edx = MEM32(ecx); /* 0x38003696: mov edx, dword ptr [ecx] */ 6930 MEM32(esi) = edx; /* 0x38003698: mov dword ptr [esi], edx */ 6931 eax = MEM32(ecx + 0x4); /* 0x3800369A: mov eax, dword ptr [ecx + 4] */ 6932 MEM32(esi + 0x4) = eax; /* 0x3800369D: mov dword ptr [esi + 4], eax */ 6933 ecx = MEM32(ecx + 0x8); /* 0x380036A0: mov ecx, dword ptr [ecx + 8] */ 6934 edi = POP32_VAL(esp); /* 0x380036A3: pop edi */ 6935 MEM32(esi + 0x8) = ecx; /* 0x380036A4: mov dword ptr [esi + 8], ecx */ 6936 SET_LO8(eax, 1); /* 0x380036A7: mov al, 1 */ 6937 esi = POP32_VAL(esp); /* 0x380036A9: pop esi */ 6938 esp = ebp; /* 0x380036AA: mov esp, ebp */ 6939 ebp = POP32_VAL(esp); /* 0x380036AC: pop ebp */ 6940 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380036AD: ret 4 */ 6941 L_380036B0: 6942 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x380036B0: fld dword ptr [ebp - 0x10] */ 6943 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E928)); /* 0x380036B3: fcomp qword ptr [0x3804e928] */ 6944 fp_pop(); 6945 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380036B9: fnstsw ax */ 6946 /* test HI8(eax), 0x40u */ /* 0x380036BB: test ah, 0x40 */ 6947 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6948 _cf = 0; 6949 _flag_k = FK_NARROW(FK_TEST, 24); 6950 if (TEST_Z(_flag_a, _flag_b)) goto L_380036E8; /* 0x380036BE: je 0x380036e8 */ 6951 L_380036C0: 6952 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x380036C0: fld dword ptr [ebp - 8] */ 6953 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E928)); /* 0x380036C3: fcomp qword ptr [0x3804e928] */ 6954 fp_pop(); 6955 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380036C9: fnstsw ax */ 6956 /* test HI8(eax), 0x40u */ /* 0x380036CB: test ah, 0x40 */ 6957 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 6958 _cf = 0; 6959 _flag_k = FK_NARROW(FK_TEST, 24); 6960 if (TEST_Z(_flag_a, _flag_b)) goto L_380036E8; /* 0x380036CE: je 0x380036e8 */ 6961 L_380036D0: 6962 edx = MEM32(0x3804E6E4); /* 0x380036D0: mov edx, dword ptr [0x3804e6e4] */ 6963 ecx = MEM32(edx); /* 0x380036D6: mov ecx, dword ptr [edx] */ 6964 eax = esi; /* 0x380036D8: mov eax, esi */ 6965 MEM32(eax) = ecx; /* 0x380036DA: mov dword ptr [eax], ecx */ 6966 ecx = MEM32(edx + 0x4); /* 0x380036DC: mov ecx, dword ptr [edx + 4] */ 6967 MEM32(eax + 0x4) = ecx; /* 0x380036DF: mov dword ptr [eax + 4], ecx */ 6968 edx = MEM32(edx + 0x8); /* 0x380036E2: mov edx, dword ptr [edx + 8] */ 6969 MEM32(eax + 0x8) = edx; /* 0x380036E5: mov dword ptr [eax + 8], edx */ 6970 L_380036E8: 6971 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x380036E8: fld dword ptr [ebp - 0x10] */ 6972 eax = MEM32(ebp + (-0x10)); /* 0x380036EB: mov eax, dword ptr [ebp - 0x10] */ 6973 _st[0] *= (double)*(float*)ADDR(esi); /* 0x380036EE: fmul dword ptr [esi] */ 6974 ecx = MEM32(ebp + (-0xC)); /* 0x380036F0: mov ecx, dword ptr [ebp - 0xc] */ 6975 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x380036F3: fld dword ptr [ebp - 0xc] */ 6976 edx = MEM32(ebp + (-0x8)); /* 0x380036F6: mov edx, dword ptr [ebp - 8] */ 6977 _st[0] *= (double)*(float*)ADDR(esi + 0x4); /* 0x380036F9: fmul dword ptr [esi + 4] */ 6978 MEM32(ebp + (-0x1C)) = eax; /* 0x380036FC: mov dword ptr [ebp - 0x1c], eax */ 6979 MEM32(ebp + (-0x18)) = ecx; /* 0x380036FF: mov dword ptr [ebp - 0x18], ecx */ 6980 MEM32(ebp + (-0x14)) = edx; /* 0x38003702: mov dword ptr [ebp - 0x14], edx */ 6981 { double _v = fp_pop(); _st[0] += _v; } /* 0x38003705: faddp st(1) */ 6982 edi = POP32_VAL(esp); /* 0x38003707: pop edi */ 6983 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x38003708: fld dword ptr [ebp - 8] */ 6984 SET_LO8(eax, 1); /* 0x3800370B: mov al, 1 */ 6985 _st[0] *= (double)*(float*)ADDR(esi + 0x8); /* 0x3800370D: fmul dword ptr [esi + 8] */ 6986 { double _v = fp_pop(); _st[0] += _v; } /* 0x38003710: faddp st(1) */ 6987 fp_push(_st[0]); /* 0x38003712: fld st(0) */ 6988 _st[0] *= (double)*(float*)ADDR(ebp + (-0x10)); /* 0x38003714: fmul dword ptr [ebp - 0x10] */ 6989 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x38003717: fstp dword ptr [ebp - 0x1c] */ 6990 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x3800371A: fld dword ptr [ebp - 0x18] */ 6991 _st[0] *= _st[1]; /* 0x3800371D: fmul st(1) */ 6992 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x3800371F: fstp dword ptr [ebp - 0x18] */ 6993 _st[0] *= (double)*(float*)ADDR(ebp + (-0x14)); /* 0x38003722: fmul dword ptr [ebp - 0x14] */ 6994 fp_push(*(float*)&MEM32(esi)); /* 0x38003725: fld dword ptr [esi] */ 6995 _st[0] -= (double)*(float*)ADDR(ebp + (-0x1C)); /* 0x38003727: fsub dword ptr [ebp - 0x1c] */ 6996 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3800372A: fstp dword ptr [ebp + 8] */ 6997 fp_push(*(float*)&MEM32(esi + 0x4)); /* 0x3800372D: fld dword ptr [esi + 4] */ 6998 _st[0] -= (double)*(float*)ADDR(ebp + (-0x18)); /* 0x38003730: fsub dword ptr [ebp - 0x18] */ 6999 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x38003733: fstp dword ptr [ebp - 4] */ 7000 _st[0] = (double)*(float*)ADDR(esi + 0x8) - _st[0]; /* 0x38003736: fsubr dword ptr [esi + 8] */ 7001 fp_push(_st[0]); /* 0x38003739: fld st(0) */ 7002 _st[0] *= _st[1]; /* 0x3800373B: fmul st(1) */ 7003 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3800373D: fld dword ptr [ebp - 4] */ 7004 _st[0] *= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x38003740: fmul dword ptr [ebp - 4] */ 7005 { double _v = fp_pop(); _st[0] += _v; } /* 0x38003743: faddp st(1) */ 7006 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x38003745: fld dword ptr [ebp + 8] */ 7007 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x38003748: fmul dword ptr [ebp + 8] */ 7008 { double _v = fp_pop(); _st[0] += _v; } /* 0x3800374B: faddp st(1) */ 7009 _st[0] = sqrt(_st[0]); /* 0x3800374D: fsqrt */ 7010 _st[0] = (double)*(float*)ADDR(0x3804E8CC) / _st[0]; /* 0x3800374F: fdivr dword ptr [0x3804e8cc] */ 7011 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x38003755: fld dword ptr [ebp + 8] */ 7012 _st[0] *= _st[1]; /* 0x38003758: fmul st(1) */ 7013 { float _v = (float)fp_pop(); *(float*)ADDR(esi) = _v; } /* 0x3800375A: fstp dword ptr [esi] */ 7014 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3800375C: fld dword ptr [ebp - 4] */ 7015 _st[0] *= _st[1]; /* 0x3800375F: fmul st(1) */ 7016 { float _v = (float)fp_pop(); *(float*)ADDR(esi + 0x4) = _v; } /* 0x38003761: fstp dword ptr [esi + 4] */ 7017 fp_xch(1); /* 0x38003764: fxch st(1) */ 7018 _st[0] *= _st[1]; /* 0x38003766: fmul st(1) */ 7019 { float _v = (float)fp_pop(); *(float*)ADDR(esi + 0x8) = _v; } /* 0x38003768: fstp dword ptr [esi + 8] */ 7020 esi = POP32_VAL(esp); /* 0x3800376B: pop esi */ 7021 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3800376C: fstp st(0) */ 7022 esp = ebp; /* 0x3800376E: mov esp, ebp */ 7023 ebp = POP32_VAL(esp); /* 0x38003770: pop ebp */ 7024 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38003771: ret 4 */ 7025 RECOMP_REGS_OUT(); 7026 } 7027 7028 void sub_38003780(void) { 7029 int _fpu_cmp = 0; 7030 uint32_t _cf = 0; 7031 int _df = 1; 7032 uint32_t _flag_k = FK_NONE; 7033 uint32_t _flag_a = 0, _flag_b = 0; 7034 uint32_t _itail_tgt = 0; 7035 RECOMP_REGS_LOCALS 7036 RECOMP_ENTER(0x38003780u); 7037 7038 L_38003780: 7039 PUSH32(esp, ebp); /* 0x38003780: push ebp */ 7040 ebp = esp; /* 0x38003781: mov ebp, esp */ 7041 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x6Cu); 7042 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 7043 esp = esp - 0x6Cu; /* 0x38003783: sub esp, 0x6c */ 7044 _flag_k = FK_CMP; 7045 PUSH32(esp, esi); /* 0x38003786: push esi */ 7046 esi = ecx; /* 0x38003787: mov esi, ecx */ 7047 fp_push(*(float*)&MEM32(esi + 0x184)); /* 0x38003789: fld dword ptr [esi + 0x184] */ 7048 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E928)); /* 0x3800378F: fcomp qword ptr [0x3804e928] */ 7049 fp_pop(); 7050 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003795: fnstsw ax */ 7051 /* test HI8(eax), 0x40u */ /* 0x38003797: test ah, 0x40 */ 7052 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 7053 _cf = 0; 7054 _flag_k = FK_NARROW(FK_TEST, 24); 7055 if (TEST_Z(_flag_a, _flag_b)) goto L_380037B8; /* 0x3800379A: je 0x380037b8 */ 7056 L_3800379C: 7057 fp_push(*(float*)&MEM32(esi + 0x190)); /* 0x3800379C: fld dword ptr [esi + 0x190] */ 7058 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E928)); /* 0x380037A2: fcomp qword ptr [0x3804e928] */ 7059 fp_pop(); 7060 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380037A8: fnstsw ax */ 7061 /* test HI8(eax), 0x40u */ /* 0x380037AA: test ah, 0x40 */ 7062 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 7063 _cf = 0; 7064 _flag_k = FK_NARROW(FK_TEST, 24); 7065 if (TEST_Z(_flag_a, _flag_b)) goto L_380037B8; /* 0x380037AD: je 0x380037b8 */ 7066 L_380037AF: 7067 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 7068 eax = 0; /* 0x380037AF: xor eax, eax */ 7069 _cf = 0; 7070 _flag_k = FK_TEST; 7071 esi = POP32_VAL(esp); /* 0x380037B1: pop esi */ 7072 esp = ebp; /* 0x380037B2: mov esp, ebp */ 7073 ebp = POP32_VAL(esp); /* 0x380037B4: pop ebp */ 7074 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x380037B5: ret 4 */ 7075 L_380037B8: 7076 eax = ebp + (-0x48); /* 0x380037B8: lea eax, [ebp - 0x48] */ 7077 PUSH32(esp, eax); /* 0x380037BB: push eax */ 7078 ecx = esi; /* 0x380037BC: mov ecx, esi */ 7079 RECOMP_ICALL(0x38001F50u); /* 0x380037BE: call 0x38001f50 */ /* not lifted */ 7080 RECOMP_FLAGS_IN(); 7081 ecx = esi + 0x54; /* 0x380037C3: lea ecx, [esi + 0x54] */ 7082 edx = MEM32(ecx); /* 0x380037C6: mov edx, dword ptr [ecx] */ 7083 MEM32(ebp + (-0x18)) = edx; /* 0x380037C8: mov dword ptr [ebp - 0x18], edx */ 7084 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x380037CB: fld dword ptr [ebp - 0x18] */ 7085 _st[0] -= (double)*(float*)ADDR(eax); /* 0x380037CE: fsub dword ptr [eax] */ 7086 edx = MEM32(ecx + 0x4); /* 0x380037D0: mov edx, dword ptr [ecx + 4] */ 7087 ecx = MEM32(ecx + 0x8); /* 0x380037D3: mov ecx, dword ptr [ecx + 8] */ 7088 MEM32(ebp + (-0x14)) = edx; /* 0x380037D6: mov dword ptr [ebp - 0x14], edx */ 7089 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x380037D9: fstp dword ptr [ebp - 0x18] */ 7090 MEM32(ebp + (-0x10)) = ecx; /* 0x380037DC: mov dword ptr [ebp - 0x10], ecx */ 7091 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x380037DF: fld dword ptr [ebp - 0x14] */ 7092 edx = MEM32(ebp + (-0x18)); /* 0x380037E2: mov edx, dword ptr [ebp - 0x18] */ 7093 _st[0] -= (double)*(float*)ADDR(eax + 0x4); /* 0x380037E5: fsub dword ptr [eax + 4] */ 7094 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x380037E8: fstp dword ptr [ebp - 0x14] */ 7095 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x380037EB: fld dword ptr [ebp - 0x10] */ 7096 _st[0] -= (double)*(float*)ADDR(eax + 0x8); /* 0x380037EE: fsub dword ptr [eax + 8] */ 7097 eax = MEM32(ebp + (-0x14)); /* 0x380037F1: mov eax, dword ptr [ebp - 0x14] */ 7098 MEM32(ebp + (-0x24)) = edx; /* 0x380037F4: mov dword ptr [ebp - 0x24], edx */ 7099 edx = MEM32(0x3804E6D4); /* 0x380037F7: mov edx, dword ptr [0x3804e6d4] */ 7100 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x380037FD: fstp dword ptr [ebp - 0x10] */ 7101 ecx = MEM32(ebp + (-0x10)); /* 0x38003800: mov ecx, dword ptr [ebp - 0x10] */ 7102 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38003803: fld dword ptr [ebp - 0x10] */ 7103 MEM32(ebp + (-0x20)) = eax; /* 0x38003806: mov dword ptr [ebp - 0x20], eax */ 7104 _st[0] *= (double)*(float*)ADDR(ebp + (-0x10)); /* 0x38003809: fmul dword ptr [ebp - 0x10] */ 7105 MEM32(ebp + (-0x1C)) = ecx; /* 0x3800380C: mov dword ptr [ebp - 0x1c], ecx */ 7106 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x3800380F: fld dword ptr [ebp - 0x14] */ 7107 _st[0] *= (double)*(float*)ADDR(ebp + (-0x14)); /* 0x38003812: fmul dword ptr [ebp - 0x14] */ 7108 { double _v = fp_pop(); _st[0] += _v; } /* 0x38003815: faddp st(1) */ 7109 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x38003817: fld dword ptr [ebp - 0x18] */ 7110 _st[0] *= (double)*(float*)ADDR(ebp + (-0x18)); /* 0x3800381A: fmul dword ptr [ebp - 0x18] */ 7111 { double _v = fp_pop(); _st[0] += _v; } /* 0x3800381D: faddp st(1) */ 7112 _st[0] = sqrt(_st[0]); /* 0x3800381F: fsqrt */ 7113 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x38003821: fstp dword ptr [ebp - 8] */ 7114 fp_push(*(float*)&MEM32(edx)); /* 0x38003824: fld dword ptr [edx] */ 7115 { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x38003826: fst dword ptr [ebp - 0xc] */ 7116 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8EC)); /* 0x38003829: fcomp dword ptr [0x3804e8ec] */ 7117 fp_pop(); 7118 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3800382F: fnstsw ax */ 7119 /* test HI8(eax), 0x41u */ /* 0x38003831: test ah, 0x41 */ 7120 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 7121 _cf = 0; 7122 _flag_k = FK_NARROW(FK_TEST, 24); 7123 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800383F; /* 0x38003834: jne 0x3800383f */ 7124 L_38003836: 7125 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 7126 eax = 0; /* 0x38003836: xor eax, eax */ 7127 _cf = 0; 7128 _flag_k = FK_TEST; 7129 esi = POP32_VAL(esp); /* 0x38003838: pop esi */ 7130 esp = ebp; /* 0x38003839: mov esp, ebp */ 7131 ebp = POP32_VAL(esp); /* 0x3800383B: pop ebp */ 7132 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3800383C: ret 4 */ 7133 L_3800383F: 7134 PUSH32(esp, edi); /* 0x3800383F: push edi */ 7135 edi = MEM32(0x3804E6CC); /* 0x38003840: mov edi, dword ptr [0x3804e6cc] */ 7136 ecx = esi; /* 0x38003846: mov ecx, esi */ 7137 MEM32(ebp + (-0x18)) = 0x3F800000u; /* 0x38003848: mov dword ptr [ebp - 0x18], 0x3f800000 */ 7138 MEM32(ebp + (-0x14)) = 0; /* 0x3800384F: mov dword ptr [ebp - 0x14], 0 */ 7139 MEM32(ebp + (-0x10)) = 0; /* 0x38003856: mov dword ptr [ebp - 0x10], 0 */ 7140 RECOMP_ICALL(edi); /* 0x3800385D: call edi */ 7141 RECOMP_FLAGS_IN(); 7142 ecx = MEM32(ebp + (-0x18)); /* 0x3800385F: mov ecx, dword ptr [ebp - 0x18] */ 7143 edx = MEM32(ebp + (-0x14)); /* 0x38003862: mov edx, dword ptr [ebp - 0x14] */ 7144 MEM32(ebp + (-0x3C)) = ecx; /* 0x38003865: mov dword ptr [ebp - 0x3c], ecx */ 7145 ecx = MEM32(ebp + (-0x10)); /* 0x38003868: mov ecx, dword ptr [ebp - 0x10] */ 7146 MEM32(ebp + (-0x34)) = ecx; /* 0x3800386B: mov dword ptr [ebp - 0x34], ecx */ 7147 PUSH32(esp, eax); /* 0x3800386E: push eax */ 7148 ecx = ebp + (-0x3C); /* 0x3800386F: lea ecx, [ebp - 0x3c] */ 7149 MEM32(ebp + (-0x38)) = edx; /* 0x38003872: mov dword ptr [ebp - 0x38], edx */ 7150 RECOMP_ICALL(MEM32(0x3804E4E4)); /* 0x38003875: call dword ptr [0x3804e4e4] */ 7151 RECOMP_FLAGS_IN(); 7152 edx = MEM32(eax); /* 0x3800387B: mov edx, dword ptr [eax] */ 7153 ecx = MEM32(eax + 0x4); /* 0x3800387D: mov ecx, dword ptr [eax + 4] */ 7154 MEM32(ebp + (-0x18)) = edx; /* 0x38003880: mov dword ptr [ebp - 0x18], edx */ 7155 edx = MEM32(eax + 0x8); /* 0x38003883: mov edx, dword ptr [eax + 8] */ 7156 MEM32(ebp + (-0x14)) = ecx; /* 0x38003886: mov dword ptr [ebp - 0x14], ecx */ 7157 ecx = esi; /* 0x38003889: mov ecx, esi */ 7158 MEM32(ebp + (-0x10)) = edx; /* 0x3800388B: mov dword ptr [ebp - 0x10], edx */ 7159 RECOMP_ICALL(edi); /* 0x3800388E: call edi */ 7160 RECOMP_FLAGS_IN(); 7161 ecx = MEM32(0x3804E6E0); /* 0x38003890: mov ecx, dword ptr [0x3804e6e0] */ 7162 edx = MEM32(ecx); /* 0x38003896: mov edx, dword ptr [ecx] */ 7163 MEM32(ebp + (-0x3C)) = edx; /* 0x38003898: mov dword ptr [ebp - 0x3c], edx */ 7164 edx = MEM32(ecx + 0x4); /* 0x3800389B: mov edx, dword ptr [ecx + 4] */ 7165 ecx = MEM32(ecx + 0x8); /* 0x3800389E: mov ecx, dword ptr [ecx + 8] */ 7166 MEM32(ebp + (-0x34)) = ecx; /* 0x380038A1: mov dword ptr [ebp - 0x34], ecx */ 7167 PUSH32(esp, eax); /* 0x380038A4: push eax */ 7168 ecx = ebp + (-0x3C); /* 0x380038A5: lea ecx, [ebp - 0x3c] */ 7169 MEM32(ebp + (-0x38)) = edx; /* 0x380038A8: mov dword ptr [ebp - 0x38], edx */ 7170 RECOMP_ICALL(MEM32(0x3804E4E4)); /* 0x380038AB: call dword ptr [0x3804e4e4] */ 7171 RECOMP_FLAGS_IN(); 7172 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x380038B1: fld dword ptr [ebp - 8] */ 7173 _st[0] += (double)*(float*)ADDR(0x3804E8CC); /* 0x380038B4: fadd dword ptr [0x3804e8cc] */ 7174 _st[0] = sqrt(_st[0]); /* 0x380038BA: fsqrt */ 7175 _st[0] *= (double)*(float*)ADDR(0x3804E930); /* 0x380038BC: fmul dword ptr [0x3804e930] */ 7176 fp_push(_st[0]); /* 0x380038C2: fld st(0) */ 7177 _st[0] *= (double)*(float*)ADDR(esi + 0x184); /* 0x380038C4: fmul dword ptr [esi + 0x184] */ 7178 _st[0] *= (double)*(float*)ADDR(ebp + (-0xC)); /* 0x380038CA: fmul dword ptr [ebp - 0xc] */ 7179 _st[0] /= (double)*(float*)ADDR(ebp + (-0x8)); /* 0x380038CD: fdiv dword ptr [ebp - 8] */ 7180 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x380038D0: fstp dword ptr [ebp - 4] */ 7181 _st[0] *= (double)*(float*)ADDR(esi + 0x190); /* 0x380038D3: fmul dword ptr [esi + 0x190] */ 7182 _st[0] *= (double)*(float*)ADDR(ebp + (-0xC)); /* 0x380038D9: fmul dword ptr [ebp - 0xc] */ 7183 _st[0] /= (double)*(float*)ADDR(ebp + (-0x8)); /* 0x380038DC: fdiv dword ptr [ebp - 8] */ 7184 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x380038DF: fcom dword ptr [0x3804e8e4] */ 7185 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380038E5: fnstsw ax */ 7186 /* test HI8(eax), 1 */ /* 0x380038E7: test ah, 1 */ 7187 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 7188 _cf = 0; 7189 _flag_k = FK_NARROW(FK_TEST, 24); 7190 if (TEST_NZ(_flag_a, _flag_b)) goto L_38003901; /* 0x380038EA: jne 0x38003901 */ 7191 L_380038EC: 7192 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E8F8)); /* 0x380038EC: fcom qword ptr [0x3804e8f8] */ 7193 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x380038F2: fnstsw ax */ 7194 /* test HI8(eax), 1 */ /* 0x380038F4: test ah, 1 */ 7195 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 7196 _cf = 0; 7197 _flag_k = FK_NARROW(FK_TEST, 24); 7198 if (TEST_Z(_flag_a, _flag_b)) goto L_38003901; /* 0x380038F7: je 0x38003901 */ 7199 L_380038F9: 7200 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x380038F9: fmul dword ptr [0x3804e8bc] */ 7201 goto L_38003922; /* 0x380038FF: jmp 0x38003922 */ 7202 L_38003901: 7203 _st[0] *= (double)*(float*)ADDR(0x3804E8F4); /* 0x38003901: fmul dword ptr [0x3804e8f4] */ 7204 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8); 7205 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 7206 esp = esp - 8; /* 0x38003907: sub esp, 8 */ 7207 _flag_k = FK_CMP; 7208 { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3800390A: fst dword ptr [ebp - 8] */ 7209 { double _v = fp_pop(); *(double*)ADDR(esp) = _v; } /* 0x3800390D: fstp qword ptr [esp] */ 7210 RECOMP_ICALL(MEM32(0x3804E0AC)); /* 0x38003910: call dword ptr [0x3804e0ac] */ 7211 RECOMP_FLAGS_IN(); 7212 _st[0] = (double)*(float*)ADDR(ebp + (-0x8)) - _st[0]; /* 0x38003916: fsubr dword ptr [ebp - 8] */ 7213 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8); 7214 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 7215 esp = esp + 8; /* 0x38003919: add esp, 8 */ 7216 _flag_k = FK_ADD; 7217 _st[0] *= (double)*(float*)ADDR(0x3804E8F0); /* 0x3800391C: fmul dword ptr [0x3804e8f0] */ 7218 L_38003922: 7219 fp_push(_st[0]); /* 0x38003922: fld st(0) */ 7220 esi = MEM32(0x3804E6E0); /* 0x38003924: mov esi, dword ptr [0x3804e6e0] */ 7221 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3800392A: fsin */ 7222 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x3800392C: fld dword ptr [ebp - 0x18] */ 7223 _st[0] *= _st[1]; /* 0x3800392F: fmul st(1) */ 7224 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4C)) = _v; } /* 0x38003931: fstp dword ptr [ebp - 0x4c] */ 7225 edx = MEM32(ebp + (-0x4C)); /* 0x38003934: mov edx, dword ptr [ebp - 0x4c] */ 7226 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x38003937: fld dword ptr [ebp - 0x14] */ 7227 MEM32(ebp + (-0x6C)) = edx; /* 0x3800393A: mov dword ptr [ebp - 0x6c], edx */ 7228 _st[0] *= _st[1]; /* 0x3800393D: fmul st(1) */ 7229 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x48)) = _v; } /* 0x3800393F: fstp dword ptr [ebp - 0x48] */ 7230 eax = MEM32(ebp + (-0x48)); /* 0x38003942: mov eax, dword ptr [ebp - 0x48] */ 7231 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38003945: fld dword ptr [ebp - 0x10] */ 7232 MEM32(ebp + (-0x68)) = eax; /* 0x38003948: mov dword ptr [ebp - 0x68], eax */ 7233 _st[0] *= _st[1]; /* 0x3800394B: fmul st(1) */ 7234 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x44)) = _v; } /* 0x3800394D: fstp dword ptr [ebp - 0x44] */ 7235 ecx = MEM32(ebp + (-0x44)); /* 0x38003950: mov ecx, dword ptr [ebp - 0x44] */ 7236 MEM32(ebp + (-0x64)) = ecx; /* 0x38003953: mov dword ptr [ebp - 0x64], ecx */ 7237 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x38003956: fstp st(0) */ 7238 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x38003958: fcos */ 7239 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x40)) = _v; } /* 0x3800395A: fstp dword ptr [ebp - 0x40] */ 7240 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3800395D: fld dword ptr [ebp - 4] */ 7241 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38003960: fcomp dword ptr [0x3804e8e4] */ 7242 fp_pop(); 7243 edx = MEM32(ebp + (-0x40)); /* 0x38003966: mov edx, dword ptr [ebp - 0x40] */ 7244 MEM32(ebp + (-0x60)) = edx; /* 0x38003969: mov dword ptr [ebp - 0x60], edx */ 7245 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3800396C: fnstsw ax */ 7246 /* test HI8(eax), 1 */ /* 0x3800396E: test ah, 1 */ 7247 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 7248 _cf = 0; 7249 _flag_k = FK_NARROW(FK_TEST, 24); 7250 if (TEST_NZ(_flag_a, _flag_b)) goto L_3800398E; /* 0x38003971: jne 0x3800398e */ 7251 L_38003973: 7252 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x38003973: fld dword ptr [ebp - 4] */ 7253 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E8F8)); /* 0x38003976: fcomp qword ptr [0x3804e8f8] */ 7254 fp_pop(); 7255 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3800397C: fnstsw ax */ 7256 /* test HI8(eax), 1 */ /* 0x3800397E: test ah, 1 */ 7257 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 7258 _cf = 0; 7259 _flag_k = FK_NARROW(FK_TEST, 24); 7260 if (TEST_Z(_flag_a, _flag_b)) goto L_3800398E; /* 0x38003981: je 0x3800398e */ 7261 L_38003983: 7262 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x38003983: fld dword ptr [ebp - 4] */ 7263 _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x38003986: fmul dword ptr [0x3804e8bc] */ 7264 goto L_380039B2; /* 0x3800398C: jmp 0x380039b2 */ 7265 L_3800398E: 7266 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3800398E: fld dword ptr [ebp - 4] */ 7267 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8); 7268 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 7269 esp = esp - 8; /* 0x38003991: sub esp, 8 */ 7270 _flag_k = FK_CMP; 7271 _st[0] *= (double)*(float*)ADDR(0x3804E8F4); /* 0x38003994: fmul dword ptr [0x3804e8f4] */ 7272 { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3800399A: fst dword ptr [ebp - 8] */ 7273 { double _v = fp_pop(); *(double*)ADDR(esp) = _v; } /* 0x3800399D: fstp qword ptr [esp] */ 7274 RECOMP_ICALL(MEM32(0x3804E0AC)); /* 0x380039A0: call dword ptr [0x3804e0ac] */ 7275 RECOMP_FLAGS_IN(); 7276 _st[0] = (double)*(float*)ADDR(ebp + (-0x8)) - _st[0]; /* 0x380039A6: fsubr dword ptr [ebp - 8] */ 7277 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8); 7278 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 7279 esp = esp + 8; /* 0x380039A9: add esp, 8 */ 7280 _flag_k = FK_ADD; 7281 _st[0] *= (double)*(float*)ADDR(0x3804E8F0); /* 0x380039AC: fmul dword ptr [0x3804e8f0] */ 7282 L_380039B2: 7283 fp_push(_st[0]); /* 0x380039B2: fld st(0) */ 7284 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x380039B4: fsin */ 7285 fp_push(_st[0]); /* 0x380039B6: fld st(0) */ 7286 _st[0] *= (double)*(float*)ADDR(esi); /* 0x380039B8: fmul dword ptr [esi] */ 7287 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4C)) = _v; } /* 0x380039BA: fstp dword ptr [ebp - 0x4c] */ 7288 eax = MEM32(ebp + (-0x4C)); /* 0x380039BD: mov eax, dword ptr [ebp - 0x4c] */ 7289 fp_push(_st[0]); /* 0x380039C0: fld st(0) */ 7290 _st[0] *= (double)*(float*)ADDR(esi + 0x4); /* 0x380039C2: fmul dword ptr [esi + 4] */ 7291 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x48)) = _v; } /* 0x380039C5: fstp dword ptr [ebp - 0x48] */ 7292 ecx = MEM32(ebp + (-0x48)); /* 0x380039C8: mov ecx, dword ptr [ebp - 0x48] */ 7293 _st[0] *= (double)*(float*)ADDR(esi + 0x8); /* 0x380039CB: fmul dword ptr [esi + 8] */ 7294 MEM32(ebp + (-0x58)) = ecx; /* 0x380039CE: mov dword ptr [ebp - 0x58], ecx */ 7295 ecx = MEM32(ebp + (-0x24)); /* 0x380039D1: mov ecx, dword ptr [ebp - 0x24] */ 7296 MEM32(ebp + (-0x5C)) = eax; /* 0x380039D4: mov dword ptr [ebp - 0x5c], eax */ 7297 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x44)) = _v; } /* 0x380039D7: fstp dword ptr [ebp - 0x44] */ 7298 edx = MEM32(ebp + (-0x44)); /* 0x380039DA: mov edx, dword ptr [ebp - 0x44] */ 7299 MEM32(ebp + (-0x3C)) = ecx; /* 0x380039DD: mov dword ptr [ebp - 0x3c], ecx */ 7300 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x380039E0: fcos */ 7301 ecx = ebp + (-0x6C); /* 0x380039E2: lea ecx, [ebp - 0x6c] */ 7302 MEM32(ebp + (-0x54)) = edx; /* 0x380039E5: mov dword ptr [ebp - 0x54], edx */ 7303 edx = MEM32(ebp + (-0x20)); /* 0x380039E8: mov edx, dword ptr [ebp - 0x20] */ 7304 PUSH32(esp, ecx); /* 0x380039EB: push ecx */ 7305 ecx = ebp + (-0x3C); /* 0x380039EC: lea ecx, [ebp - 0x3c] */ 7306 MEM32(ebp + (-0x38)) = edx; /* 0x380039EF: mov dword ptr [ebp - 0x38], edx */ 7307 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x40)) = _v; } /* 0x380039F2: fstp dword ptr [ebp - 0x40] */ 7308 eax = MEM32(ebp + (-0x40)); /* 0x380039F5: mov eax, dword ptr [ebp - 0x40] */ 7309 MEM32(ebp + (-0x50)) = eax; /* 0x380039F8: mov dword ptr [ebp - 0x50], eax */ 7310 eax = MEM32(ebp + (-0x1C)); /* 0x380039FB: mov eax, dword ptr [ebp - 0x1c] */ 7311 MEM32(ebp + (-0x34)) = eax; /* 0x380039FE: mov dword ptr [ebp - 0x34], eax */ 7312 RECOMP_ICALL(MEM32(0x3804E4E4)); /* 0x38003A01: call dword ptr [0x3804e4e4] */ 7313 RECOMP_FLAGS_IN(); 7314 edi = MEM32(eax); /* 0x38003A07: mov edi, dword ptr [eax] */ 7315 MEM32(ebp + (-0x18)) = edi; /* 0x38003A09: mov dword ptr [ebp - 0x18], edi */ 7316 edi = MEM32(eax + 0x4); /* 0x38003A0C: mov edi, dword ptr [eax + 4] */ 7317 esi = eax; /* 0x38003A0F: mov esi, eax */ 7318 eax = MEM32(eax + 0x8); /* 0x38003A11: mov eax, dword ptr [eax + 8] */ 7319 ecx = MEM32(esi); /* 0x38003A14: mov ecx, dword ptr [esi] */ 7320 edx = MEM32(esi + 0x4); /* 0x38003A16: mov edx, dword ptr [esi + 4] */ 7321 esi = MEM32(esi + 0x8); /* 0x38003A19: mov esi, dword ptr [esi + 8] */ 7322 MEM32(ebp + (-0x10)) = eax; /* 0x38003A1C: mov dword ptr [ebp - 0x10], eax */ 7323 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x38003A1F: fld dword ptr [ebp - 0x10] */ 7324 _st[0] *= (double)*(float*)ADDR(ebp + (-0x1C)); /* 0x38003A22: fmul dword ptr [ebp - 0x1c] */ 7325 MEM32(ebp + (-0x14)) = edi; /* 0x38003A25: mov dword ptr [ebp - 0x14], edi */ 7326 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x38003A28: fld dword ptr [ebp - 0x18] */ 7327 edi = POP32_VAL(esp); /* 0x38003A2B: pop edi */ 7328 _st[0] *= (double)*(float*)ADDR(ebp + (-0x24)); /* 0x38003A2C: fmul dword ptr [ebp - 0x24] */ 7329 { double _v = fp_pop(); _st[0] += _v; } /* 0x38003A2F: faddp st(1) */ 7330 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x38003A31: fcomp dword ptr [0x3804e8e4] */ 7331 fp_pop(); 7332 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003A37: fnstsw ax */ 7333 /* test HI8(eax), 1 */ /* 0x38003A39: test ah, 1 */ 7334 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 7335 _cf = 0; 7336 _flag_k = FK_NARROW(FK_TEST, 24); 7337 if (TEST_Z(_flag_a, _flag_b)) goto L_38003A47; /* 0x38003A3C: je 0x38003a47 */ 7338 L_38003A3E: 7339 ecx = MEM32(ebp + (-0x24)); /* 0x38003A3E: mov ecx, dword ptr [ebp - 0x24] */ 7340 edx = MEM32(ebp + (-0x20)); /* 0x38003A41: mov edx, dword ptr [ebp - 0x20] */ 7341 esi = MEM32(ebp + (-0x1C)); /* 0x38003A44: mov esi, dword ptr [ebp - 0x1c] */ 7342 L_38003A47: 7343 eax = MEM32(ebp + (-0x54)); /* 0x38003A47: mov eax, dword ptr [ebp - 0x54] */ 7344 MEM32(ebp + (-0x30)) = ecx; /* 0x38003A4A: mov dword ptr [ebp - 0x30], ecx */ 7345 ecx = MEM32(ebp + (-0x5C)); /* 0x38003A4D: mov ecx, dword ptr [ebp - 0x5c] */ 7346 MEM32(ebp + (-0x48)) = ecx; /* 0x38003A50: mov dword ptr [ebp - 0x48], ecx */ 7347 ecx = ebp + (-0x30); /* 0x38003A53: lea ecx, [ebp - 0x30] */ 7348 MEM32(ebp + (-0x2C)) = edx; /* 0x38003A56: mov dword ptr [ebp - 0x2c], edx */ 7349 edx = MEM32(ebp + (-0x58)); /* 0x38003A59: mov edx, dword ptr [ebp - 0x58] */ 7350 PUSH32(esp, ecx); /* 0x38003A5C: push ecx */ 7351 ecx = ebp + (-0x48); /* 0x38003A5D: lea ecx, [ebp - 0x48] */ 7352 MEM32(ebp + (-0x28)) = esi; /* 0x38003A60: mov dword ptr [ebp - 0x28], esi */ 7353 MEM32(ebp + (-0x44)) = edx; /* 0x38003A63: mov dword ptr [ebp - 0x44], edx */ 7354 MEM32(ebp + (-0x40)) = eax; /* 0x38003A66: mov dword ptr [ebp - 0x40], eax */ 7355 RECOMP_ICALL(MEM32(0x3804E4C8)); /* 0x38003A69: call dword ptr [0x3804e4c8] */ 7356 RECOMP_FLAGS_IN(); 7357 edx = MEM32(eax); /* 0x38003A6F: mov edx, dword ptr [eax] */ 7358 MEM32(ebp + (-0x18)) = edx; /* 0x38003A71: mov dword ptr [ebp - 0x18], edx */ 7359 ecx = MEM32(eax + 0x4); /* 0x38003A74: mov ecx, dword ptr [eax + 4] */ 7360 MEM32(ebp + (-0x14)) = ecx; /* 0x38003A77: mov dword ptr [ebp - 0x14], ecx */ 7361 edx = MEM32(eax + 0x8); /* 0x38003A7A: mov edx, dword ptr [eax + 8] */ 7362 eax = ebp + (-0x18); /* 0x38003A7D: lea eax, [ebp - 0x18] */ 7363 PUSH32(esp, eax); /* 0x38003A80: push eax */ 7364 ecx = ebp + (-0x48); /* 0x38003A81: lea ecx, [ebp - 0x48] */ 7365 PUSH32(esp, ecx); /* 0x38003A84: push ecx */ 7366 ecx = ebp + (-0x5C); /* 0x38003A85: lea ecx, [ebp - 0x5c] */ 7367 MEM32(ebp + (-0x10)) = edx; /* 0x38003A88: mov dword ptr [ebp - 0x10], edx */ 7368 RECOMP_ICALL(MEM32(0x3804E4FC)); /* 0x38003A8B: call dword ptr [0x3804e4fc] */ 7369 RECOMP_FLAGS_IN(); 7370 fp_push(*(float*)&MEM32(ebp + (-0x50))); /* 0x38003A91: fld dword ptr [ebp - 0x50] */ 7371 edx = MEM32(eax); /* 0x38003A94: mov edx, dword ptr [eax] */ 7372 _st[0] += _st[0]; /* 0x38003A96: fadd st(0), st(0) */ 7373 MEM32(ebp + (-0x3C)) = edx; /* 0x38003A98: mov dword ptr [ebp - 0x3c], edx */ 7374 ecx = MEM32(eax + 0x4); /* 0x38003A9B: mov ecx, dword ptr [eax + 4] */ 7375 MEM32(ebp + (-0x38)) = ecx; /* 0x38003A9E: mov dword ptr [ebp - 0x38], ecx */ 7376 edx = MEM32(eax + 0x8); /* 0x38003AA1: mov edx, dword ptr [eax + 8] */ 7377 PUSH32(esp, ecx); /* 0x38003AA4: push ecx */ 7378 ecx = ebp + (-0x18); /* 0x38003AA5: lea ecx, [ebp - 0x18] */ 7379 { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x38003AA8: fstp dword ptr [esp] */ 7380 MEM32(ebp + (-0x34)) = edx; /* 0x38003AAB: mov dword ptr [ebp - 0x34], edx */ 7381 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x38003AAE: call dword ptr [0x3804e4d4] */ 7382 RECOMP_FLAGS_IN(); 7383 PUSH32(esp, 0x40000000u); /* 0x38003AB4: push 0x40000000 */ 7384 ecx = ebp + (-0x3C); /* 0x38003AB9: lea ecx, [ebp - 0x3c] */ 7385 RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x38003ABC: call dword ptr [0x3804e4d4] */ 7386 RECOMP_FLAGS_IN(); 7387 eax = ebp + (-0x18); /* 0x38003AC2: lea eax, [ebp - 0x18] */ 7388 PUSH32(esp, eax); /* 0x38003AC5: push eax */ 7389 ecx = ebp + (-0x30); /* 0x38003AC6: lea ecx, [ebp - 0x30] */ 7390 RECOMP_ICALL(MEM32(0x3804E4E8)); /* 0x38003AC9: call dword ptr [0x3804e4e8] */ 7391 RECOMP_FLAGS_IN(); 7392 ecx = ebp + (-0x3C); /* 0x38003ACF: lea ecx, [ebp - 0x3c] */ 7393 PUSH32(esp, ecx); /* 0x38003AD2: push ecx */ 7394 ecx = ebp + (-0x30); /* 0x38003AD3: lea ecx, [ebp - 0x30] */ 7395 RECOMP_ICALL(MEM32(0x3804E4E8)); /* 0x38003AD6: call dword ptr [0x3804e4e8] */ 7396 RECOMP_FLAGS_IN(); 7397 edx = MEM32(ebp + (-0x30)); /* 0x38003ADC: mov edx, dword ptr [ebp - 0x30] */ 7398 ecx = MEM32(ebp + (-0x28)); /* 0x38003ADF: mov ecx, dword ptr [ebp - 0x28] */ 7399 eax = MEM32(ebp + (-0x2C)); /* 0x38003AE2: mov eax, dword ptr [ebp - 0x2c] */ 7400 MEM32(ebp + (-0x48)) = edx; /* 0x38003AE5: mov dword ptr [ebp - 0x48], edx */ 7401 edx = ebp + (-0x24); /* 0x38003AE8: lea edx, [ebp - 0x24] */ 7402 MEM32(ebp + (-0x40)) = ecx; /* 0x38003AEB: mov dword ptr [ebp - 0x40], ecx */ 7403 PUSH32(esp, edx); /* 0x38003AEE: push edx */ 7404 ecx = ebp + (-0x48); /* 0x38003AEF: lea ecx, [ebp - 0x48] */ 7405 MEM32(ebp + (-0x44)) = eax; /* 0x38003AF2: mov dword ptr [ebp - 0x44], eax */ 7406 RECOMP_ICALL(MEM32(0x3804E4F4)); /* 0x38003AF5: call dword ptr [0x3804e4f4] */ 7407 RECOMP_FLAGS_IN(); 7408 ecx = MEM32(eax); /* 0x38003AFB: mov ecx, dword ptr [eax] */ 7409 edx = MEM32(eax + 0x4); /* 0x38003AFD: mov edx, dword ptr [eax + 4] */ 7410 eax = MEM32(eax + 0x8); /* 0x38003B00: mov eax, dword ptr [eax + 8] */ 7411 MEM32(ebp + (-0x3C)) = ecx; /* 0x38003B03: mov dword ptr [ebp - 0x3c], ecx */ 7412 ecx = MEM32(ebp + (-0xC)); /* 0x38003B06: mov ecx, dword ptr [ebp - 0xc] */ 7413 PUSH32(esp, ecx); /* 0x38003B09: push ecx */ 7414 ecx = ebp + (-0x3C); /* 0x38003B0A: lea ecx, [ebp - 0x3c] */ 7415 MEM32(ebp + (-0x38)) = edx; /* 0x38003B0D: mov dword ptr [ebp - 0x38], edx */ 7416 MEM32(ebp + (-0x34)) = eax; /* 0x38003B10: mov dword ptr [ebp - 0x34], eax */ 7417 RECOMP_ICALL(MEM32(0x3804E4F8)); /* 0x38003B13: call dword ptr [0x3804e4f8] */ 7418 RECOMP_FLAGS_IN(); 7419 ecx = MEM32(eax); /* 0x38003B19: mov ecx, dword ptr [eax] */ 7420 edx = MEM32(ebp + 0x8); /* 0x38003B1B: mov edx, dword ptr [ebp + 8] */ 7421 MEM32(edx) = ecx; /* 0x38003B1E: mov dword ptr [edx], ecx */ 7422 ecx = MEM32(eax + 0x4); /* 0x38003B20: mov ecx, dword ptr [eax + 4] */ 7423 MEM32(edx + 0x4) = ecx; /* 0x38003B23: mov dword ptr [edx + 4], ecx */ 7424 eax = MEM32(eax + 0x8); /* 0x38003B26: mov eax, dword ptr [eax + 8] */ 7425 MEM32(edx + 0x8) = eax; /* 0x38003B29: mov dword ptr [edx + 8], eax */ 7426 eax = 3; /* 0x38003B2C: mov eax, 3 */ 7427 esi = POP32_VAL(esp); /* 0x38003B31: pop esi */ 7428 esp = ebp; /* 0x38003B32: mov esp, ebp */ 7429 ebp = POP32_VAL(esp); /* 0x38003B34: pop ebp */ 7430 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38003B35: ret 4 */ 7431 RECOMP_REGS_OUT(); 7432 } 7433 7434 void sub_38003B40(void) { 7435 int _fpu_cmp = 0; 7436 uint32_t _cf = 0; 7437 int _df = 1; 7438 uint32_t _flag_k = FK_NONE; 7439 uint32_t _flag_a = 0, _flag_b = 0; 7440 uint32_t _itail_tgt = 0; 7441 RECOMP_REGS_LOCALS 7442 RECOMP_ENTER(0x38003B40u); 7443 7444 L_38003B40: 7445 PUSH32(esp, ebp); /* 0x38003B40: push ebp */ 7446 ebp = esp; /* 0x38003B41: mov ebp, esp */ 7447 PUSH32(esp, esi); /* 0x38003B43: push esi */ 7448 esi = ecx; /* 0x38003B44: mov esi, ecx */ 7449 fp_push(*(float*)&MEM32(esi + 0x180)); /* 0x38003B46: fld dword ptr [esi + 0x180] */ 7450 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E928)); /* 0x38003B4C: fcomp qword ptr [0x3804e928] */ 7451 fp_pop(); 7452 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003B52: fnstsw ax */ 7453 /* test HI8(eax), 0x40u */ /* 0x38003B54: test ah, 0x40 */ 7454 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 7455 _cf = 0; 7456 _flag_k = FK_NARROW(FK_TEST, 24); 7457 if (TEST_Z(_flag_a, _flag_b)) goto L_38003B60; /* 0x38003B57: je 0x38003b60 */ 7458 L_38003B59: 7459 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 7460 eax = 0; /* 0x38003B59: xor eax, eax */ 7461 _cf = 0; 7462 _flag_k = FK_TEST; 7463 esi = POP32_VAL(esp); /* 0x38003B5B: pop esi */ 7464 ebp = POP32_VAL(esp); /* 0x38003B5C: pop ebp */ 7465 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38003B5D: ret 4 */ 7466 L_38003B60: 7467 fp_push(*(float*)&MEM32(esi + 0x180)); /* 0x38003B60: fld dword ptr [esi + 0x180] */ 7468 PUSH32(esp, 1); /* 0x38003B66: push 1 */ 7469 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E928)); /* 0x38003B68: fcomp qword ptr [0x3804e928] */ 7470 fp_pop(); 7471 ecx = esi; /* 0x38003B6E: mov ecx, esi */ 7472 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x38003B70: fnstsw ax */ 7473 /* test HI8(eax), 0x41u */ /* 0x38003B72: test ah, 0x41 */ 7474 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 7475 _cf = 0; 7476 _flag_k = FK_NARROW(FK_TEST, 24); 7477 if (TEST_NZ(_flag_a, _flag_b)) goto L_38003B8E; /* 0x38003B75: jne 0x38003b8e */ 7478 L_38003B77: 7479 RECOMP_ICALL(MEM32(0x3804E6C0)); /* 0x38003B77: call dword ptr [0x3804e6c0] */ 7480 RECOMP_FLAGS_IN(); 7481 eax = MEM32(ebp + 0x8); /* 0x38003B7D: mov eax, dword ptr [ebp + 8] */ 7482 PUSH32(esp, eax); /* 0x38003B80: push eax */ 7483 ecx = esi; /* 0x38003B81: mov ecx, esi */ 7484 RECOMP_ICALL(MEM32(0x3804E6C4)); /* 0x38003B83: call dword ptr [0x3804e6c4] */ 7485 RECOMP_FLAGS_IN(); 7486 esi = POP32_VAL(esp); /* 0x38003B89: pop esi */ 7487 ebp = POP32_VAL(esp); /* 0x38003B8A: pop ebp */ 7488 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38003B8B: ret 4 */ 7489 L_38003B8E: 7490 RECOMP_ICALL(MEM32(0x3804E6C0)); /* 0x38003B8E: call dword ptr [0x3804e6c0] */ 7491 RECOMP_FLAGS_IN(); 7492 ecx = MEM32(ebp + 0x8); /* 0x38003B94: mov ecx, dword ptr [ebp + 8] */ 7493 PUSH32(esp, ecx); /* 0x38003B97: push ecx */ 7494 ecx = esi; /* 0x38003B98: mov ecx, esi */ 7495 RECOMP_ICALL(MEM32(0x3804E6C8)); /* 0x38003B9A: call dword ptr [0x3804e6c8] */ 7496 RECOMP_FLAGS_IN(); 7497 esi = POP32_VAL(esp); /* 0x38003BA0: pop esi */ 7498 ebp = POP32_VAL(esp); /* 0x38003BA1: pop ebp */ 7499 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38003BA2: ret 4 */ 7500 RECOMP_REGS_OUT(); 7501 } 7502 7503 void sub_38003BB0(void) { 7504 int _fpu_cmp = 0; 7505 uint32_t _cf = 0; 7506 int _df = 1; 7507 uint32_t _flag_k = FK_NONE; 7508 uint32_t _flag_a = 0, _flag_b = 0; 7509 uint32_t _itail_tgt = 0; 7510 RECOMP_REGS_LOCALS 7511 RECOMP_ENTER(0x38003BB0u); 7512 7513 L_38003BB0: 7514 PUSH32(esp, ebp); /* 0x38003BB0: push ebp */ 7515 ebp = esp; /* 0x38003BB1: mov ebp, esp */ 7516 eax = MEM32(ebp + 0x8); /* 0x38003BB3: mov eax, dword ptr [ebp + 8] */ 7517 MEM32(ecx + 0x194) = eax; /* 0x38003BB6: mov dword ptr [ecx + 0x194], eax */ 7518 ebp = POP32_VAL(esp); /* 0x38003BBC: pop ebp */ 7519 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x38003BBD: ret 4 */ 7520 RECOMP_REGS_OUT(); 7521 }