client/game/mr.dll/lifted-0001.c (267867B)
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_3B0034A0(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(0x3B0034A0u); 17 18 L_3B0034A0: 19 PUSH32(esp, ebp); /* 0x3B0034A0: push ebp */ 20 ebp = esp; /* 0x3B0034A1: mov ebp, esp */ 21 eax = MEM32(ebp + 0x8); /* 0x3B0034A3: mov eax, dword ptr [ebp + 8] */ 22 fp_push(*(float*)&MEM32(eax)); /* 0x3B0034A6: fld dword ptr [eax] */ 23 _st[0] -= (double)*(float*)ADDR(ecx + 0x30); /* 0x3B0034A8: fsub dword ptr [ecx + 0x30] */ 24 { float _v = (float)fp_pop(); *(float*)ADDR(eax) = _v; } /* 0x3B0034AB: fstp dword ptr [eax] */ 25 fp_push(*(float*)&MEM32(eax + 0x4)); /* 0x3B0034AD: fld dword ptr [eax + 4] */ 26 _st[0] -= (double)*(float*)ADDR(ecx + 0x34); /* 0x3B0034B0: fsub dword ptr [ecx + 0x34] */ 27 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x4) = _v; } /* 0x3B0034B3: fstp dword ptr [eax + 4] */ 28 fp_push(*(float*)&MEM32(eax + 0x8)); /* 0x3B0034B6: fld dword ptr [eax + 8] */ 29 _st[0] -= (double)*(float*)ADDR(ecx + 0x38); /* 0x3B0034B9: fsub dword ptr [ecx + 0x38] */ 30 { float _v = (float)_st[0]; *(float*)ADDR(eax + 0x8) = _v; } /* 0x3B0034BC: fst dword ptr [eax + 8] */ 31 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B0034BF: fld dword ptr [ecx + 0x10] */ 32 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B0034C2: fmul dword ptr [eax] */ 33 fp_push(_st[1]); /* 0x3B0034C4: fld st(1) */ 34 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B0034C6: fmul dword ptr [ecx + 0x18] */ 35 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0034C9: faddp st(1) */ 36 fp_push(*(float*)&MEM32(ecx + 0x14)); /* 0x3B0034CB: fld dword ptr [ecx + 0x14] */ 37 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B0034CE: fmul dword ptr [eax + 4] */ 38 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0034D1: faddp st(1) */ 39 fp_push(*(float*)&MEM32(ecx + 0x20)); /* 0x3B0034D3: fld dword ptr [ecx + 0x20] */ 40 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B0034D6: fmul dword ptr [eax] */ 41 fp_push(_st[2]); /* 0x3B0034D8: fld st(2) */ 42 _st[0] *= (double)*(float*)ADDR(ecx + 0x28); /* 0x3B0034DA: fmul dword ptr [ecx + 0x28] */ 43 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0034DD: faddp st(1) */ 44 fp_push(*(float*)&MEM32(ecx + 0x24)); /* 0x3B0034DF: fld dword ptr [ecx + 0x24] */ 45 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B0034E2: fmul dword ptr [eax + 4] */ 46 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0034E5: faddp st(1) */ 47 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3B0034E7: fstp dword ptr [ebp + 8] */ 48 fp_xch(1); /* 0x3B0034EA: fxch st(1) */ 49 _st[0] *= (double)*(float*)ADDR(ecx + 0x8); /* 0x3B0034EC: fmul dword ptr [ecx + 8] */ 50 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x3B0034EF: fld dword ptr [ecx + 4] */ 51 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B0034F2: fmul dword ptr [eax + 4] */ 52 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0034F5: faddp st(1) */ 53 fp_push(*(float*)&MEM32(eax)); /* 0x3B0034F7: fld dword ptr [eax] */ 54 _st[0] *= (double)*(float*)ADDR(ecx); /* 0x3B0034F9: fmul dword ptr [ecx] */ 55 ecx = MEM32(ebp + 0x8); /* 0x3B0034FB: mov ecx, dword ptr [ebp + 8] */ 56 MEM32(eax + 0x8) = ecx; /* 0x3B0034FE: mov dword ptr [eax + 8], ecx */ 57 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003501: faddp st(1) */ 58 { float _v = (float)fp_pop(); *(float*)ADDR(eax) = _v; } /* 0x3B003503: fstp dword ptr [eax] */ 59 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x4) = _v; } /* 0x3B003505: fstp dword ptr [eax + 4] */ 60 ebp = POP32_VAL(esp); /* 0x3B003508: pop ebp */ 61 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B003509: ret 4 */ 62 RECOMP_REGS_OUT(); 63 } 64 65 void sub_3B003510(void) { 66 int _fpu_cmp = 0; 67 uint32_t _cf = 0; 68 int _df = 1; 69 uint32_t _flag_k = FK_NONE; 70 uint32_t _flag_a = 0, _flag_b = 0; 71 uint32_t _itail_tgt = 0; 72 RECOMP_REGS_LOCALS 73 RECOMP_ENTER(0x3B003510u); 74 75 L_3B003510: 76 PUSH32(esp, ebp); /* 0x3B003510: push ebp */ 77 ebp = esp; /* 0x3B003511: mov ebp, esp */ 78 eax = MEM32(ebp + 0x8); /* 0x3B003513: mov eax, dword ptr [ebp + 8] */ 79 fp_push(*(float*)&MEM32(ecx + 0x14)); /* 0x3B003516: fld dword ptr [ecx + 0x14] */ 80 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B003519: fmul dword ptr [eax + 4] */ 81 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B00351C: fld dword ptr [ecx + 0x10] */ 82 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B00351F: fmul dword ptr [eax] */ 83 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003521: faddp st(1) */ 84 fp_push(*(float*)&MEM32(ecx + 0x18)); /* 0x3B003523: fld dword ptr [ecx + 0x18] */ 85 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B003526: fmul dword ptr [eax + 8] */ 86 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003529: faddp st(1) */ 87 fp_push(*(float*)&MEM32(ecx + 0x24)); /* 0x3B00352B: fld dword ptr [ecx + 0x24] */ 88 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B00352E: fmul dword ptr [eax + 4] */ 89 fp_push(*(float*)&MEM32(ecx + 0x20)); /* 0x3B003531: fld dword ptr [ecx + 0x20] */ 90 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B003534: fmul dword ptr [eax] */ 91 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003536: faddp st(1) */ 92 fp_push(*(float*)&MEM32(ecx + 0x28)); /* 0x3B003538: fld dword ptr [ecx + 0x28] */ 93 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B00353B: fmul dword ptr [eax + 8] */ 94 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00353E: faddp st(1) */ 95 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3B003540: fstp dword ptr [ebp + 8] */ 96 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x3B003543: fld dword ptr [ecx + 4] */ 97 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B003546: fmul dword ptr [eax + 4] */ 98 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B003549: fld dword ptr [ecx + 8] */ 99 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B00354C: fmul dword ptr [eax + 8] */ 100 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00354F: faddp st(1) */ 101 fp_push(*(float*)&MEM32(eax)); /* 0x3B003551: fld dword ptr [eax] */ 102 _st[0] *= (double)*(float*)ADDR(ecx); /* 0x3B003553: fmul dword ptr [ecx] */ 103 ecx = MEM32(ebp + 0x8); /* 0x3B003555: mov ecx, dword ptr [ebp + 8] */ 104 MEM32(eax + 0x8) = ecx; /* 0x3B003558: mov dword ptr [eax + 8], ecx */ 105 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00355B: faddp st(1) */ 106 { float _v = (float)fp_pop(); *(float*)ADDR(eax) = _v; } /* 0x3B00355D: fstp dword ptr [eax] */ 107 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x4) = _v; } /* 0x3B00355F: fstp dword ptr [eax + 4] */ 108 ebp = POP32_VAL(esp); /* 0x3B003562: pop ebp */ 109 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B003563: ret 4 */ 110 RECOMP_REGS_OUT(); 111 } 112 113 void sub_3B003570(void) { 114 int _fpu_cmp = 0; 115 uint32_t _cf = 0; 116 int _df = 1; 117 uint32_t _flag_k = FK_NONE; 118 uint32_t _flag_a = 0, _flag_b = 0; 119 uint32_t _itail_tgt = 0; 120 RECOMP_REGS_LOCALS 121 RECOMP_ENTER(0x3B003570u); 122 123 L_3B003570: 124 PUSH32(esp, ebp); /* 0x3B003570: push ebp */ 125 ebp = esp; /* 0x3B003571: mov ebp, esp */ 126 eax = ecx; /* 0x3B003573: mov eax, ecx */ 127 ecx = MEM32(ebp + 0x8); /* 0x3B003575: mov ecx, dword ptr [ebp + 8] */ 128 edx = MEM32(ecx); /* 0x3B003578: mov edx, dword ptr [ecx] */ 129 MEM32(eax) = edx; /* 0x3B00357A: mov dword ptr [eax], edx */ 130 edx = MEM32(ecx + 0x4); /* 0x3B00357C: mov edx, dword ptr [ecx + 4] */ 131 MEM32(eax + 0x4) = edx; /* 0x3B00357F: mov dword ptr [eax + 4], edx */ 132 ecx = MEM32(ecx + 0x8); /* 0x3B003582: mov ecx, dword ptr [ecx + 8] */ 133 MEM32(eax + 0x8) = ecx; /* 0x3B003585: mov dword ptr [eax + 8], ecx */ 134 ebp = POP32_VAL(esp); /* 0x3B003588: pop ebp */ 135 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B003589: ret 4 */ 136 RECOMP_REGS_OUT(); 137 } 138 139 void sub_3B003590(void) { 140 int _fpu_cmp = 0; 141 uint32_t _cf = 0; 142 int _df = 1; 143 uint32_t _flag_k = FK_NONE; 144 uint32_t _flag_a = 0, _flag_b = 0; 145 uint32_t _itail_tgt = 0; 146 RECOMP_REGS_LOCALS 147 RECOMP_ENTER(0x3B003590u); 148 149 L_3B003590: 150 fp_push(*(float*)&MEM32(ecx)); /* 0x3B003590: fld dword ptr [ecx] */ 151 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B003592: fcomp dword ptr [0x3b00604c] */ 152 fp_pop(); 153 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B003598: fld dword ptr [ecx + 8] */ 154 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B00359B: fnstsw ax */ 155 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B00359D: fcomp dword ptr [0x3b00604c] */ 156 fp_pop(); 157 /* test HI8(eax), 1 */ /* 0x3B0035A3: test ah, 1 */ 158 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 159 _cf = 0; 160 _flag_k = FK_NARROW(FK_TEST, 24); 161 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0035A6: fnstsw ax */ 162 if (TEST_Z(_flag_a, _flag_b)) goto L_3B0035FF; /* 0x3B0035A8: je 0x3b0035ff */ 163 L_3B0035AA: 164 fp_push(*(float*)&MEM32(ecx)); /* 0x3B0035AA: fld dword ptr [ecx] */ 165 /* test HI8(eax), 1 */ /* 0x3B0035AC: test ah, 1 */ 166 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 167 _cf = 0; 168 _flag_k = FK_NARROW(FK_TEST, 24); 169 if (TEST_Z(_flag_a, _flag_b)) goto L_3B0035DB; /* 0x3B0035AF: je 0x3b0035db */ 170 L_3B0035B1: 171 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ecx + 0x8)); /* 0x3B0035B1: fcomp dword ptr [ecx + 8] */ 172 fp_pop(); 173 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0035B4: fnstsw ax */ 174 /* test HI8(eax), 1 */ /* 0x3B0035B6: test ah, 1 */ 175 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 176 _cf = 0; 177 _flag_k = FK_NARROW(FK_TEST, 24); 178 if (TEST_Z(_flag_a, _flag_b)) goto L_3B0035CB; /* 0x3B0035B9: je 0x3b0035cb */ 179 L_3B0035BB: 180 fp_push(*(float*)&MEM32(ecx)); /* 0x3B0035BB: fld dword ptr [ecx] */ 181 _st[0] = -_st[0]; /* 0x3B0035BD: fchs */ 182 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B0035BF: fld dword ptr [ecx + 8] */ 183 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B0035C2: fmul dword ptr [0x3b006068] */ 184 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0035C8: fsubp st(1) */ 185 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0035CA: ret */ 186 L_3B0035CB: 187 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B0035CB: fld dword ptr [ecx + 8] */ 188 _st[0] = -_st[0]; /* 0x3B0035CE: fchs */ 189 fp_push(*(float*)&MEM32(ecx)); /* 0x3B0035D0: fld dword ptr [ecx] */ 190 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B0035D2: fmul dword ptr [0x3b006068] */ 191 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0035D8: fsubp st(1) */ 192 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0035DA: ret */ 193 L_3B0035DB: 194 _st[0] = -_st[0]; /* 0x3B0035DB: fchs */ 195 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ecx + 0x8)); /* 0x3B0035DD: fcomp dword ptr [ecx + 8] */ 196 fp_pop(); 197 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0035E0: fnstsw ax */ 198 /* test HI8(eax), 0x41u */ /* 0x3B0035E2: test ah, 0x41 */ 199 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 200 _cf = 0; 201 _flag_k = FK_NARROW(FK_TEST, 24); 202 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B0035F3; /* 0x3B0035E5: jne 0x3b0035f3 */ 203 L_3B0035E7: 204 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B0035E7: fld dword ptr [ecx + 8] */ 205 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B0035EA: fmul dword ptr [0x3b006068] */ 206 _st[0] -= (double)*(float*)ADDR(ecx); /* 0x3B0035F0: fsub dword ptr [ecx] */ 207 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0035F2: ret */ 208 L_3B0035F3: 209 fp_push(*(float*)&MEM32(ecx)); /* 0x3B0035F3: fld dword ptr [ecx] */ 210 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B0035F5: fmul dword ptr [0x3b006068] */ 211 _st[0] = (double)*(float*)ADDR(ecx + 0x8) - _st[0]; /* 0x3B0035FB: fsubr dword ptr [ecx + 8] */ 212 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0035FE: ret */ 213 L_3B0035FF: 214 /* test HI8(eax), 1 */ /* 0x3B0035FF: test ah, 1 */ 215 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 216 _cf = 0; 217 _flag_k = FK_NARROW(FK_TEST, 24); 218 if (TEST_Z(_flag_a, _flag_b)) goto L_3B00362A; /* 0x3B003602: je 0x3b00362a */ 219 L_3B003604: 220 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B003604: fld dword ptr [ecx + 8] */ 221 _st[0] = -_st[0]; /* 0x3B003607: fchs */ 222 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ecx)); /* 0x3B003609: fcomp dword ptr [ecx] */ 223 fp_pop(); 224 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B00360B: fnstsw ax */ 225 /* test HI8(eax), 1 */ /* 0x3B00360D: test ah, 1 */ 226 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 227 _cf = 0; 228 _flag_k = FK_NARROW(FK_TEST, 24); 229 if (TEST_Z(_flag_a, _flag_b)) goto L_3B00361E; /* 0x3B003610: je 0x3b00361e */ 230 L_3B003612: 231 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B003612: fld dword ptr [ecx + 8] */ 232 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B003615: fmul dword ptr [0x3b006068] */ 233 _st[0] = (double)*(float*)ADDR(ecx) - _st[0]; /* 0x3B00361B: fsubr dword ptr [ecx] */ 234 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00361D: ret */ 235 L_3B00361E: 236 fp_push(*(float*)&MEM32(ecx)); /* 0x3B00361E: fld dword ptr [ecx] */ 237 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B003620: fmul dword ptr [0x3b006068] */ 238 _st[0] -= (double)*(float*)ADDR(ecx + 0x8); /* 0x3B003626: fsub dword ptr [ecx + 8] */ 239 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003629: ret */ 240 L_3B00362A: 241 fp_push(*(float*)&MEM32(ecx)); /* 0x3B00362A: fld dword ptr [ecx] */ 242 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ecx + 0x8)); /* 0x3B00362C: fcomp dword ptr [ecx + 8] */ 243 fp_pop(); 244 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B00362F: fnstsw ax */ 245 /* test HI8(eax), 0x41u */ /* 0x3B003631: test ah, 0x41 */ 246 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 247 _cf = 0; 248 _flag_k = FK_NARROW(FK_TEST, 24); 249 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B003642; /* 0x3B003634: jne 0x3b003642 */ 250 L_3B003636: 251 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B003636: fld dword ptr [ecx + 8] */ 252 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B003639: fmul dword ptr [0x3b006068] */ 253 _st[0] += (double)*(float*)ADDR(ecx); /* 0x3B00363F: fadd dword ptr [ecx] */ 254 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003641: ret */ 255 L_3B003642: 256 fp_push(*(float*)&MEM32(ecx)); /* 0x3B003642: fld dword ptr [ecx] */ 257 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B003644: fmul dword ptr [0x3b006068] */ 258 _st[0] += (double)*(float*)ADDR(ecx + 0x8); /* 0x3B00364A: fadd dword ptr [ecx + 8] */ 259 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00364D: ret */ 260 RECOMP_REGS_OUT(); 261 } 262 263 void sub_3B003650(void) { 264 int _fpu_cmp = 0; 265 uint32_t _cf = 0; 266 int _df = 1; 267 uint32_t _flag_k = FK_NONE; 268 uint32_t _flag_a = 0, _flag_b = 0; 269 uint32_t _itail_tgt = 0; 270 RECOMP_REGS_LOCALS 271 RECOMP_ENTER(0x3B003650u); 272 273 L_3B003650: 274 PUSH32(esp, ebp); /* 0x3B003650: push ebp */ 275 ebp = esp; /* 0x3B003651: mov ebp, esp */ 276 eax = MEM32(ebp + 0x8); /* 0x3B003653: mov eax, dword ptr [ebp + 8] */ 277 fp_push(*(float*)&MEM32(ecx)); /* 0x3B003656: fld dword ptr [ecx] */ 278 _st[0] -= (double)*(float*)ADDR(eax); /* 0x3B003658: fsub dword ptr [eax] */ 279 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B00365A: fld dword ptr [ecx + 8] */ 280 _st[0] -= (double)*(float*)ADDR(eax + 0x8); /* 0x3B00365D: fsub dword ptr [eax + 8] */ 281 fp_push(_st[1]); /* 0x3B003660: fld st(1) */ 282 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B003662: fcomp dword ptr [0x3b00604c] */ 283 fp_pop(); 284 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B003668: fnstsw ax */ 285 /* test HI8(eax), 1 */ /* 0x3B00366A: test ah, 1 */ 286 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 287 _cf = 0; 288 _flag_k = FK_NARROW(FK_TEST, 24); 289 if (TEST_Z(_flag_a, _flag_b)) goto L_3B0036C2; /* 0x3B00366D: je 0x3b0036c2 */ 290 L_3B00366F: 291 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B00366F: fcom dword ptr [0x3b00604c] */ 292 fp_push(_st[1]); /* 0x3B003675: fld st(1) */ 293 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B003677: fnstsw ax */ 294 /* test HI8(eax), 1 */ /* 0x3B003679: test ah, 1 */ 295 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 296 _cf = 0; 297 _flag_k = FK_NARROW(FK_TEST, 24); 298 if (TEST_Z(_flag_a, _flag_b)) goto L_3B003699; /* 0x3B00367C: je 0x3b003699 */ 299 L_3B00367E: 300 _fpu_cmp = FPU_CMP(_st[0], _st[1]); /* 0x3B00367E: fcomp st(1) */ 301 fp_pop(); 302 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B003680: fnstsw ax */ 303 /* test HI8(eax), 1 */ /* 0x3B003682: test ah, 1 */ 304 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 305 _cf = 0; 306 _flag_k = FK_NARROW(FK_TEST, 24); 307 if (TEST_Z(_flag_a, _flag_b)) goto L_3B003689; /* 0x3B003685: je 0x3b003689 */ 308 L_3B003687: 309 fp_xch(1); /* 0x3B003687: fxch st(1) */ 310 L_3B003689: 311 _st[0] = -_st[0]; /* 0x3B003689: fchs */ 312 fp_xch(1); /* 0x3B00368B: fxch st(1) */ 313 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B00368D: fmul dword ptr [0x3b006068] */ 314 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003693: fsubp st(1) */ 315 ebp = POP32_VAL(esp); /* 0x3B003695: pop ebp */ 316 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B003696: ret 4 */ 317 L_3B003699: 318 _st[0] = -_st[0]; /* 0x3B003699: fchs */ 319 _fpu_cmp = FPU_CMP(_st[0], _st[1]); /* 0x3B00369B: fcomp st(1) */ 320 fp_pop(); 321 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B00369D: fnstsw ax */ 322 /* test HI8(eax), 0x41u */ /* 0x3B00369F: test ah, 0x41 */ 323 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 324 _cf = 0; 325 _flag_k = FK_NARROW(FK_TEST, 24); 326 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B0036B0; /* 0x3B0036A2: jne 0x3b0036b0 */ 327 L_3B0036A4: 328 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B0036A4: fmul dword ptr [0x3b006068] */ 329 { double _v = fp_pop(); _st[0] = _v - _st[0]; } /* 0x3B0036AA: fsubrp st(1) */ 330 ebp = POP32_VAL(esp); /* 0x3B0036AC: pop ebp */ 331 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B0036AD: ret 4 */ 332 L_3B0036B0: 333 fp_xch(1); /* 0x3B0036B0: fxch st(1) */ 334 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B0036B2: fmul dword ptr [0x3b006068] */ 335 _st[0] = _st[1] - _st[0]; /* 0x3B0036B8: fsubr st(1) */ 336 fp_xch(1); /* 0x3B0036BA: fxch st(1) */ 337 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B0036BC: fstp st(0) */ 338 ebp = POP32_VAL(esp); /* 0x3B0036BE: pop ebp */ 339 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B0036BF: ret 4 */ 340 L_3B0036C2: 341 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B0036C2: fld dword ptr [ecx + 8] */ 342 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B0036C5: fcomp dword ptr [0x3b00604c] */ 343 fp_pop(); 344 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0036CB: fnstsw ax */ 345 /* test HI8(eax), 1 */ /* 0x3B0036CD: test ah, 1 */ 346 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 347 _cf = 0; 348 _flag_k = FK_NARROW(FK_TEST, 24); 349 if (TEST_Z(_flag_a, _flag_b)) goto L_3B0036FF; /* 0x3B0036D0: je 0x3b0036ff */ 350 L_3B0036D2: 351 fp_push(_st[0]); /* 0x3B0036D2: fld st(0) */ 352 _st[0] = -_st[0]; /* 0x3B0036D4: fchs */ 353 fp_push(_st[2]); /* 0x3B0036D6: fld st(2) */ 354 _fpu_cmp = FPU_CMP(_st[0], _st[1]); /* 0x3B0036D8: fcompp */ 355 fp_pop(); fp_pop(); 356 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0036DA: fnstsw ax */ 357 /* test HI8(eax), 0x41u */ /* 0x3B0036DC: test ah, 0x41 */ 358 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 359 _cf = 0; 360 _flag_k = FK_NARROW(FK_TEST, 24); 361 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B0036ED; /* 0x3B0036DF: jne 0x3b0036ed */ 362 L_3B0036E1: 363 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B0036E1: fmul dword ptr [0x3b006068] */ 364 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0036E7: fsubp st(1) */ 365 ebp = POP32_VAL(esp); /* 0x3B0036E9: pop ebp */ 366 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B0036EA: ret 4 */ 367 L_3B0036ED: 368 fp_xch(1); /* 0x3B0036ED: fxch st(1) */ 369 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B0036EF: fmul dword ptr [0x3b006068] */ 370 _st[0] -= _st[1]; /* 0x3B0036F5: fsub st(1) */ 371 fp_xch(1); /* 0x3B0036F7: fxch st(1) */ 372 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B0036F9: fstp st(0) */ 373 ebp = POP32_VAL(esp); /* 0x3B0036FB: pop ebp */ 374 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B0036FC: ret 4 */ 375 L_3B0036FF: 376 fp_push(_st[1]); /* 0x3B0036FF: fld st(1) */ 377 _fpu_cmp = FPU_CMP(_st[0], _st[1]); /* 0x3B003701: fcomp st(1) */ 378 fp_pop(); 379 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B003703: fnstsw ax */ 380 /* test HI8(eax), 0x41u */ /* 0x3B003705: test ah, 0x41 */ 381 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 382 _cf = 0; 383 _flag_k = FK_NARROW(FK_TEST, 24); 384 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B003716; /* 0x3B003708: jne 0x3b003716 */ 385 L_3B00370A: 386 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B00370A: fmul dword ptr [0x3b006068] */ 387 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003710: faddp st(1) */ 388 ebp = POP32_VAL(esp); /* 0x3B003712: pop ebp */ 389 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B003713: ret 4 */ 390 L_3B003716: 391 fp_xch(1); /* 0x3B003716: fxch st(1) */ 392 _st[0] *= (double)*(float*)ADDR(0x3B006068); /* 0x3B003718: fmul dword ptr [0x3b006068] */ 393 _st[0] += _st[1]; /* 0x3B00371E: fadd st(1) */ 394 fp_xch(1); /* 0x3B003720: fxch st(1) */ 395 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B003722: fstp st(0) */ 396 ebp = POP32_VAL(esp); /* 0x3B003724: pop ebp */ 397 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B003725: ret 4 */ 398 RECOMP_REGS_OUT(); 399 } 400 401 void sub_3B003730(void) { 402 int _fpu_cmp = 0; 403 uint32_t _cf = 0; 404 int _df = 1; 405 uint32_t _flag_k = FK_NONE; 406 uint32_t _flag_a = 0, _flag_b = 0; 407 uint32_t _itail_tgt = 0; 408 RECOMP_REGS_LOCALS 409 RECOMP_ENTER(0x3B003730u); 410 411 L_3B003730: 412 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B003730: fld dword ptr [ecx + 8] */ 413 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x3B003733: fld dword ptr [ecx + 4] */ 414 fp_push(*(float*)&MEM32(ecx)); /* 0x3B003736: fld dword ptr [ecx] */ 415 fp_push(_st[0]); /* 0x3B003738: fld st(0) */ 416 _st[0] *= _st[1]; /* 0x3B00373A: fmul st(1) */ 417 fp_push(_st[2]); /* 0x3B00373C: fld st(2) */ 418 _st[0] *= _st[3]; /* 0x3B00373E: fmul st(3) */ 419 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003740: faddp st(1) */ 420 fp_push(_st[3]); /* 0x3B003742: fld st(3) */ 421 _st[0] *= _st[4]; /* 0x3B003744: fmul st(4) */ 422 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003746: faddp st(1) */ 423 _st[0] = sqrt(_st[0]); /* 0x3B003748: fsqrt */ 424 { _st[3] = _st[0]; g_st_i64[3] = g_st_i64[0]; fp_pop(); } /* 0x3B00374A: fstp st(3) */ 425 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B00374C: fstp st(0) */ 426 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B00374E: fstp st(0) */ 427 _st[0] = (double)*(float*)ADDR(0x3B006048) / _st[0]; /* 0x3B003750: fdivr dword ptr [0x3b006048] */ 428 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003756: ret */ 429 RECOMP_REGS_OUT(); 430 } 431 432 void sub_3B003760(void) { 433 int _fpu_cmp = 0; 434 uint32_t _cf = 0; 435 int _df = 1; 436 uint32_t _flag_k = FK_NONE; 437 uint32_t _flag_a = 0, _flag_b = 0; 438 uint32_t _itail_tgt = 0; 439 RECOMP_REGS_LOCALS 440 RECOMP_ENTER(0x3B003760u); 441 442 L_3B003760: 443 PUSH32(esp, ebp); /* 0x3B003760: push ebp */ 444 ebp = esp; /* 0x3B003761: mov ebp, esp */ 445 eax = ecx; /* 0x3B003763: mov eax, ecx */ 446 ecx = MEM32(ebp + 0x8); /* 0x3B003765: mov ecx, dword ptr [ebp + 8] */ 447 fp_push(*(float*)&MEM32(ecx + 0x18)); /* 0x3B003768: fld dword ptr [ecx + 0x18] */ 448 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B00376B: fmul dword ptr [eax + 8] */ 449 fp_push(*(float*)&MEM32(ecx + 0xC)); /* 0x3B00376E: fld dword ptr [ecx + 0xc] */ 450 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B003771: fmul dword ptr [eax + 4] */ 451 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003774: faddp st(1) */ 452 fp_push(*(float*)&MEM32(ecx)); /* 0x3B003776: fld dword ptr [ecx] */ 453 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B003778: fmul dword ptr [eax] */ 454 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00377A: faddp st(1) */ 455 fp_push(*(float*)&MEM32(ecx + 0x1C)); /* 0x3B00377C: fld dword ptr [ecx + 0x1c] */ 456 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B00377F: fmul dword ptr [eax + 8] */ 457 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x3B003782: fld dword ptr [ecx + 4] */ 458 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B003785: fmul dword ptr [eax] */ 459 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003787: faddp st(1) */ 460 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B003789: fld dword ptr [ecx + 0x10] */ 461 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B00378C: fmul dword ptr [eax + 4] */ 462 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00378F: faddp st(1) */ 463 fp_push(*(float*)&MEM32(ecx + 0x20)); /* 0x3B003791: fld dword ptr [ecx + 0x20] */ 464 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B003794: fmul dword ptr [eax + 8] */ 465 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B003797: fld dword ptr [ecx + 8] */ 466 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B00379A: fmul dword ptr [eax] */ 467 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00379C: faddp st(1) */ 468 fp_push(*(float*)&MEM32(ecx + 0x14)); /* 0x3B00379E: fld dword ptr [ecx + 0x14] */ 469 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B0037A1: fmul dword ptr [eax + 4] */ 470 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0037A4: faddp st(1) */ 471 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x8) = _v; } /* 0x3B0037A6: fstp dword ptr [eax + 8] */ 472 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x4) = _v; } /* 0x3B0037A9: fstp dword ptr [eax + 4] */ 473 { float _v = (float)fp_pop(); *(float*)ADDR(eax) = _v; } /* 0x3B0037AC: fstp dword ptr [eax] */ 474 ebp = POP32_VAL(esp); /* 0x3B0037AE: pop ebp */ 475 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B0037AF: ret 4 */ 476 RECOMP_REGS_OUT(); 477 } 478 479 void sub_3B0037C0(void) { 480 int _fpu_cmp = 0; 481 uint32_t _cf = 0; 482 int _df = 1; 483 uint32_t _flag_k = FK_NONE; 484 uint32_t _flag_a = 0, _flag_b = 0; 485 uint32_t _itail_tgt = 0; 486 RECOMP_REGS_LOCALS 487 RECOMP_ENTER(0x3B0037C0u); 488 489 L_3B0037C0: 490 PUSH32(esp, ebp); /* 0x3B0037C0: push ebp */ 491 ebp = esp; /* 0x3B0037C1: mov ebp, esp */ 492 eax = ecx; /* 0x3B0037C3: mov eax, ecx */ 493 ecx = MEM32(ebp + 0x8); /* 0x3B0037C5: mov ecx, dword ptr [ebp + 8] */ 494 fp_push(*(float*)&MEM32(ecx + 0x24)); /* 0x3B0037C8: fld dword ptr [ecx + 0x24] */ 495 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B0037CB: fmul dword ptr [eax + 8] */ 496 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x3B0037CE: fld dword ptr [ecx + 4] */ 497 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B0037D1: fmul dword ptr [eax] */ 498 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0037D3: faddp st(1) */ 499 fp_push(*(float*)&MEM32(ecx + 0x14)); /* 0x3B0037D5: fld dword ptr [ecx + 0x14] */ 500 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B0037D8: fmul dword ptr [eax + 4] */ 501 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0037DB: faddp st(1) */ 502 _st[0] += (double)*(float*)ADDR(ecx + 0x34); /* 0x3B0037DD: fadd dword ptr [ecx + 0x34] */ 503 fp_push(*(float*)&MEM32(ecx + 0x28)); /* 0x3B0037E0: fld dword ptr [ecx + 0x28] */ 504 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B0037E3: fmul dword ptr [eax + 8] */ 505 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B0037E6: fld dword ptr [ecx + 8] */ 506 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B0037E9: fmul dword ptr [eax] */ 507 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0037EB: faddp st(1) */ 508 fp_push(*(float*)&MEM32(ecx + 0x18)); /* 0x3B0037ED: fld dword ptr [ecx + 0x18] */ 509 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B0037F0: fmul dword ptr [eax + 4] */ 510 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0037F3: faddp st(1) */ 511 _st[0] += (double)*(float*)ADDR(ecx + 0x38); /* 0x3B0037F5: fadd dword ptr [ecx + 0x38] */ 512 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3B0037F8: fstp dword ptr [ebp + 8] */ 513 fp_push(*(float*)&MEM32(ecx + 0x20)); /* 0x3B0037FB: fld dword ptr [ecx + 0x20] */ 514 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B0037FE: fmul dword ptr [eax + 8] */ 515 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B003801: fld dword ptr [ecx + 0x10] */ 516 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B003804: fmul dword ptr [eax + 4] */ 517 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003807: faddp st(1) */ 518 fp_push(*(float*)&MEM32(ecx)); /* 0x3B003809: fld dword ptr [ecx] */ 519 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B00380B: fmul dword ptr [eax] */ 520 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00380D: faddp st(1) */ 521 _st[0] += (double)*(float*)ADDR(ecx + 0x30); /* 0x3B00380F: fadd dword ptr [ecx + 0x30] */ 522 ecx = MEM32(ebp + 0x8); /* 0x3B003812: mov ecx, dword ptr [ebp + 8] */ 523 MEM32(eax + 0x8) = ecx; /* 0x3B003815: mov dword ptr [eax + 8], ecx */ 524 { float _v = (float)fp_pop(); *(float*)ADDR(eax) = _v; } /* 0x3B003818: fstp dword ptr [eax] */ 525 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x4) = _v; } /* 0x3B00381A: fstp dword ptr [eax + 4] */ 526 ebp = POP32_VAL(esp); /* 0x3B00381D: pop ebp */ 527 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B00381E: ret 4 */ 528 RECOMP_REGS_OUT(); 529 } 530 531 void sub_3B003830(void) { 532 int _fpu_cmp = 0; 533 uint32_t _cf = 0; 534 int _df = 1; 535 uint32_t _flag_k = FK_NONE; 536 uint32_t _flag_a = 0, _flag_b = 0; 537 uint32_t _itail_tgt = 0; 538 RECOMP_REGS_LOCALS 539 RECOMP_ENTER(0x3B003830u); 540 541 L_3B003830: 542 PUSH32(esp, ebp); /* 0x3B003830: push ebp */ 543 ebp = esp; /* 0x3B003831: mov ebp, esp */ 544 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x28u); 545 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 546 esp = esp - 0x28u; /* 0x3B003833: sub esp, 0x28 */ 547 _flag_k = FK_CMP; 548 eax = ecx; /* 0x3B003836: mov eax, ecx */ 549 PUSH32(esp, esi); /* 0x3B003838: push esi */ 550 ecx = MEM32(ebp + 0x8); /* 0x3B003839: mov ecx, dword ptr [ebp + 8] */ 551 edx = ecx; /* 0x3B00383C: mov edx, ecx */ 552 esi = MEM32(edx); /* 0x3B00383E: mov esi, dword ptr [edx] */ 553 MEM32(ebp + (-0x10)) = esi; /* 0x3B003840: mov dword ptr [ebp - 0x10], esi */ 554 esi = MEM32(edx + 0x4); /* 0x3B003843: mov esi, dword ptr [edx + 4] */ 555 MEM32(ebp + (-0xC)) = esi; /* 0x3B003846: mov dword ptr [ebp - 0xc], esi */ 556 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B003849: fld dword ptr [ebp - 0xc] */ 557 edx = MEM32(edx + 0x8); /* 0x3B00384C: mov edx, dword ptr [edx + 8] */ 558 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B00384F: fmul dword ptr [eax + 8] */ 559 MEM32(ebp + (-0x8)) = edx; /* 0x3B003852: mov dword ptr [ebp - 8], edx */ 560 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B003855: fld dword ptr [ebp - 8] */ 561 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B003858: fmul dword ptr [eax + 4] */ 562 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B00385B: fsubp st(1) */ 563 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B00385D: fld dword ptr [ebp - 8] */ 564 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B003860: fmul dword ptr [eax] */ 565 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x3B003862: fld dword ptr [ebp - 0x10] */ 566 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B003865: fmul dword ptr [eax + 8] */ 567 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003868: fsubp st(1) */ 568 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x3B00386A: fld dword ptr [ebp - 0x10] */ 569 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B00386D: fmul dword ptr [eax + 4] */ 570 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B003870: fld dword ptr [ebp - 0xc] */ 571 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B003873: fmul dword ptr [eax] */ 572 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003875: fsubp st(1) */ 573 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3B003877: fstp dword ptr [ebp - 8] */ 574 fp_push(_st[1]); /* 0x3B00387A: fld st(1) */ 575 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3B00387C: fstp dword ptr [ebp - 0x10] */ 576 edx = MEM32(ebp + (-0x10)); /* 0x3B00387F: mov edx, dword ptr [ebp - 0x10] */ 577 { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3B003882: fst dword ptr [ebp - 0xc] */ 578 MEM32(ebp + (-0x28)) = edx; /* 0x3B003885: mov dword ptr [ebp - 0x28], edx */ 579 edx = MEM32(ebp + (-0xC)); /* 0x3B003888: mov edx, dword ptr [ebp - 0xc] */ 580 MEM32(ebp + (-0x24)) = edx; /* 0x3B00388B: mov dword ptr [ebp - 0x24], edx */ 581 edx = MEM32(ebp + (-0x8)); /* 0x3B00388E: mov edx, dword ptr [ebp - 8] */ 582 MEM32(ebp + (-0x20)) = edx; /* 0x3B003891: mov dword ptr [ebp - 0x20], edx */ 583 edx = ecx; /* 0x3B003894: mov edx, ecx */ 584 esi = MEM32(edx); /* 0x3B003896: mov esi, dword ptr [edx] */ 585 MEM32(ebp + (-0x1C)) = esi; /* 0x3B003898: mov dword ptr [ebp - 0x1c], esi */ 586 esi = MEM32(edx + 0x4); /* 0x3B00389B: mov esi, dword ptr [edx + 4] */ 587 MEM32(ebp + (-0x18)) = esi; /* 0x3B00389E: mov dword ptr [ebp - 0x18], esi */ 588 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x3B0038A1: fld dword ptr [ebp - 0x18] */ 589 edx = MEM32(edx + 0x8); /* 0x3B0038A4: mov edx, dword ptr [edx + 8] */ 590 _st[0] *= (double)*(float*)ADDR(ebp + (-0x8)); /* 0x3B0038A7: fmul dword ptr [ebp - 8] */ 591 MEM32(ebp + (-0x14)) = edx; /* 0x3B0038AA: mov dword ptr [ebp - 0x14], edx */ 592 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x3B0038AD: fld dword ptr [ebp - 0x14] */ 593 _st[0] *= _st[2]; /* 0x3B0038B0: fmul st(2) */ 594 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0038B2: fsubp st(1) */ 595 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3B0038B4: fstp dword ptr [ebp - 4] */ 596 fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x3B0038B7: fld dword ptr [ebp - 0x14] */ 597 _st[0] *= _st[2]; /* 0x3B0038BA: fmul st(2) */ 598 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B0038BC: fld dword ptr [ebp - 8] */ 599 _st[0] *= (double)*(float*)ADDR(ebp + (-0x1C)); /* 0x3B0038BF: fmul dword ptr [ebp - 0x1c] */ 600 edx = MEM32(ebp + (-0x4)); /* 0x3B0038C2: mov edx, dword ptr [ebp - 4] */ 601 MEM32(ebp + (-0x10)) = edx; /* 0x3B0038C5: mov dword ptr [ebp - 0x10], edx */ 602 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0038C8: fsubp st(1) */ 603 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x3B0038CA: fld dword ptr [ebp - 0x1c] */ 604 _st[0] *= _st[2]; /* 0x3B0038CD: fmul st(2) */ 605 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x3B0038CF: fld dword ptr [ebp - 0x18] */ 606 _st[0] *= _st[4]; /* 0x3B0038D2: fmul st(4) */ 607 MEM32(ebp + (-0x1C)) = edx; /* 0x3B0038D4: mov dword ptr [ebp - 0x1c], edx */ 608 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0038D7: fsubp st(1) */ 609 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3B0038D9: fstp dword ptr [ebp - 0x14] */ 610 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x3B0038DC: fstp dword ptr [ebp - 0x18] */ 611 edx = MEM32(ebp + (-0x18)); /* 0x3B0038DF: mov edx, dword ptr [ebp - 0x18] */ 612 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B0038E2: fstp st(0) */ 613 fp_push(*(float*)&MEM32(ecx + 0xC)); /* 0x3B0038E4: fld dword ptr [ecx + 0xc] */ 614 _st[0] += _st[0]; /* 0x3B0038E7: fadd st(0), st(0) */ 615 MEM32(ebp + (-0xC)) = edx; /* 0x3B0038E9: mov dword ptr [ebp - 0xc], edx */ 616 edx = MEM32(ebp + (-0x14)); /* 0x3B0038EC: mov edx, dword ptr [ebp - 0x14] */ 617 MEM32(ebp + (-0x8)) = edx; /* 0x3B0038EF: mov dword ptr [ebp - 8], edx */ 618 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3B0038F2: fstp dword ptr [ebp + 8] */ 619 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B0038F5: fmul dword ptr [ebp + 8] */ 620 fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x3B0038F8: fld dword ptr [ebp - 0x24] */ 621 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B0038FB: fmul dword ptr [ebp + 8] */ 622 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x3B0038FE: fstp dword ptr [ebp - 0x24] */ 623 fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x3B003901: fld dword ptr [ebp - 0x20] */ 624 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B003904: fmul dword ptr [ebp + 8] */ 625 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x3B003907: fstp dword ptr [ebp - 0x20] */ 626 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B00390A: fld dword ptr [ebp - 4] */ 627 _st[0] += _st[0]; /* 0x3B00390D: fadd st(0), st(0) */ 628 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B00390F: fld dword ptr [ebp - 0xc] */ 629 _st[0] += _st[0]; /* 0x3B003912: fadd st(0), st(0) */ 630 esi = POP32_VAL(esp); /* 0x3B003914: pop esi */ 631 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3B003915: fstp dword ptr [ebp - 0xc] */ 632 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B003918: fld dword ptr [ebp - 8] */ 633 _st[0] += _st[0]; /* 0x3B00391B: fadd st(0), st(0) */ 634 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3B00391D: fstp dword ptr [ebp - 8] */ 635 fp_xch(1); /* 0x3B003920: fxch st(1) */ 636 _st[0] += (double)*(float*)ADDR(eax); /* 0x3B003922: fadd dword ptr [eax] */ 637 _st[0] += _st[1]; /* 0x3B003924: fadd st(1) */ 638 { float _v = (float)fp_pop(); *(float*)ADDR(eax) = _v; } /* 0x3B003926: fstp dword ptr [eax] */ 639 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B003928: fstp st(0) */ 640 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B00392A: fld dword ptr [ebp - 0xc] */ 641 _st[0] += (double)*(float*)ADDR(eax + 0x4); /* 0x3B00392D: fadd dword ptr [eax + 4] */ 642 _st[0] += (double)*(float*)ADDR(ebp + (-0x24)); /* 0x3B003930: fadd dword ptr [ebp - 0x24] */ 643 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x4) = _v; } /* 0x3B003933: fstp dword ptr [eax + 4] */ 644 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B003936: fld dword ptr [ebp - 8] */ 645 _st[0] += (double)*(float*)ADDR(eax + 0x8); /* 0x3B003939: fadd dword ptr [eax + 8] */ 646 _st[0] += (double)*(float*)ADDR(ebp + (-0x20)); /* 0x3B00393C: fadd dword ptr [ebp - 0x20] */ 647 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x8) = _v; } /* 0x3B00393F: fstp dword ptr [eax + 8] */ 648 esp = ebp; /* 0x3B003942: mov esp, ebp */ 649 ebp = POP32_VAL(esp); /* 0x3B003944: pop ebp */ 650 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B003945: ret 4 */ 651 RECOMP_REGS_OUT(); 652 } 653 654 void sub_3B003950(void) { 655 int _fpu_cmp = 0; 656 uint32_t _cf = 0; 657 int _df = 1; 658 uint32_t _flag_k = FK_NONE; 659 uint32_t _flag_a = 0, _flag_b = 0; 660 uint32_t _itail_tgt = 0; 661 RECOMP_REGS_LOCALS 662 RECOMP_ENTER(0x3B003950u); 663 664 L_3B003950: 665 PUSH32(esp, ebp); /* 0x3B003950: push ebp */ 666 ebp = esp; /* 0x3B003951: mov ebp, esp */ 667 fp_push(*(float*)&MEM32(0x3B006048)); /* 0x3B003953: fld dword ptr [0x3b006048] */ 668 _st[0] -= (double)*(float*)ADDR(ebp + 0x10); /* 0x3B003959: fsub dword ptr [ebp + 0x10] */ 669 eax = MEM32(ebp + 0x8); /* 0x3B00395C: mov eax, dword ptr [ebp + 8] */ 670 edx = MEM32(ebp + 0xC); /* 0x3B00395F: mov edx, dword ptr [ebp + 0xc] */ 671 fp_push(_st[0]); /* 0x3B003962: fld st(0) */ 672 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B003964: fmul dword ptr [eax] */ 673 fp_push(*(float*)&MEM32(ebp + 0x10)); /* 0x3B003966: fld dword ptr [ebp + 0x10] */ 674 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B003969: fmul dword ptr [edx] */ 675 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00396B: faddp st(1) */ 676 { float _v = (float)fp_pop(); *(float*)ADDR(ecx) = _v; } /* 0x3B00396D: fstp dword ptr [ecx] */ 677 fp_push(_st[0]); /* 0x3B00396F: fld st(0) */ 678 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B003971: fmul dword ptr [eax + 4] */ 679 fp_push(*(float*)&MEM32(ebp + 0x10)); /* 0x3B003974: fld dword ptr [ebp + 0x10] */ 680 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B003977: fmul dword ptr [edx + 4] */ 681 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00397A: faddp st(1) */ 682 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x4) = _v; } /* 0x3B00397C: fstp dword ptr [ecx + 4] */ 683 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B00397F: fmul dword ptr [eax + 8] */ 684 fp_push(*(float*)&MEM32(ebp + 0x10)); /* 0x3B003982: fld dword ptr [ebp + 0x10] */ 685 _st[0] *= (double)*(float*)ADDR(edx + 0x8); /* 0x3B003985: fmul dword ptr [edx + 8] */ 686 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003988: faddp st(1) */ 687 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x8) = _v; } /* 0x3B00398A: fstp dword ptr [ecx + 8] */ 688 ebp = POP32_VAL(esp); /* 0x3B00398D: pop ebp */ 689 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3B00398E: ret 0xc */ 690 RECOMP_REGS_OUT(); 691 } 692 693 void sub_3B0039A0(void) { 694 int _fpu_cmp = 0; 695 uint32_t _cf = 0; 696 int _df = 1; 697 uint32_t _flag_k = FK_NONE; 698 uint32_t _flag_a = 0, _flag_b = 0; 699 uint32_t _itail_tgt = 0; 700 RECOMP_REGS_LOCALS 701 RECOMP_ENTER(0x3B0039A0u); 702 703 L_3B0039A0: 704 PUSH32(esp, ebp); /* 0x3B0039A0: push ebp */ 705 ebp = esp; /* 0x3B0039A1: mov ebp, esp */ 706 eax = MEM32(ebp + 0x8); /* 0x3B0039A3: mov eax, dword ptr [ebp + 8] */ 707 edx = MEM32(ebp + 0xC); /* 0x3B0039A6: mov edx, dword ptr [ebp + 0xc] */ 708 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B0039A9: fld dword ptr [ecx + 8] */ 709 _st[0] -= (double)*(float*)ADDR(eax + 0x8); /* 0x3B0039AC: fsub dword ptr [eax + 8] */ 710 _st[0] *= (double)*(float*)ADDR(edx + 0x8); /* 0x3B0039AF: fmul dword ptr [edx + 8] */ 711 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x3B0039B2: fld dword ptr [ecx + 4] */ 712 _st[0] -= (double)*(float*)ADDR(eax + 0x4); /* 0x3B0039B5: fsub dword ptr [eax + 4] */ 713 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B0039B8: fmul dword ptr [edx + 4] */ 714 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0039BB: faddp st(1) */ 715 fp_push(*(float*)&MEM32(ecx)); /* 0x3B0039BD: fld dword ptr [ecx] */ 716 _st[0] -= (double)*(float*)ADDR(eax); /* 0x3B0039BF: fsub dword ptr [eax] */ 717 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B0039C1: fmul dword ptr [edx] */ 718 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0039C3: faddp st(1) */ 719 ebp = POP32_VAL(esp); /* 0x3B0039C5: pop ebp */ 720 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3B0039C6: ret 8 */ 721 RECOMP_REGS_OUT(); 722 } 723 724 void sub_3B0039D0(void) { 725 int _fpu_cmp = 0; 726 uint32_t _cf = 0; 727 int _df = 1; 728 uint32_t _flag_k = FK_NONE; 729 uint32_t _flag_a = 0, _flag_b = 0; 730 uint32_t _itail_tgt = 0; 731 RECOMP_REGS_LOCALS 732 RECOMP_ENTER(0x3B0039D0u); 733 734 L_3B0039D0: 735 RECOMP_ICALL(0x3B0039E0u); /* 0x3B0039D0: call 0x3b0039e0 */ /* not lifted */ 736 RECOMP_FLAGS_IN(); 737 goto L_3B0039F0; /* 0x3B0039D5: jmp 0x3b0039f0 */ 738 L_3B0039F0: 739 PUSH32(esp, 0x3B003A00u); /* 0x3B0039F0: push 0x3b003a00 */ 740 RECOMP_ICALL(0x3B0050E8u); /* 0x3B0039F5: call 0x3b0050e8 */ /* not lifted */ 741 RECOMP_FLAGS_IN(); 742 ecx = POP32_VAL(esp); /* 0x3B0039FA: pop ecx */ 743 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0039FB: ret */ 744 RECOMP_REGS_OUT(); 745 } 746 747 void sub_3B0039E0(void) { 748 int _fpu_cmp = 0; 749 uint32_t _cf = 0; 750 int _df = 1; 751 uint32_t _flag_k = FK_NONE; 752 uint32_t _flag_a = 0, _flag_b = 0; 753 uint32_t _itail_tgt = 0; 754 RECOMP_REGS_LOCALS 755 RECOMP_ENTER(0x3B0039E0u); 756 757 L_3B0039E0: 758 ecx = 0x3B008041u; /* 0x3B0039E0: mov ecx, 0x3b008041 */ 759 L_3B0039E5: 760 { _itail_tgt = (uint32_t)(MEM32(0x3B006014)); goto _ljump; } 761 { RECOMP_REGS_OUT(); return; } /* end of function */ 762 _ljump: 763 switch (_itail_tgt) { 764 case 0x3B0039E0u: goto L_3B0039E0; 765 case 0x3B0039E5u: goto L_3B0039E5; 766 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 767 } 768 RECOMP_REGS_OUT(); 769 } 770 771 void sub_3B0039F0(void) { 772 int _fpu_cmp = 0; 773 uint32_t _cf = 0; 774 int _df = 1; 775 uint32_t _flag_k = FK_NONE; 776 uint32_t _flag_a = 0, _flag_b = 0; 777 uint32_t _itail_tgt = 0; 778 RECOMP_REGS_LOCALS 779 RECOMP_ENTER(0x3B0039F0u); 780 781 L_3B0039F0: 782 PUSH32(esp, 0x3B003A00u); /* 0x3B0039F0: push 0x3b003a00 */ 783 RECOMP_ICALL(0x3B0050E8u); /* 0x3B0039F5: call 0x3b0050e8 */ /* not lifted */ 784 RECOMP_FLAGS_IN(); 785 ecx = POP32_VAL(esp); /* 0x3B0039FA: pop ecx */ 786 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0039FB: ret */ 787 RECOMP_REGS_OUT(); 788 } 789 790 void sub_3B003A00(void) { 791 int _fpu_cmp = 0; 792 uint32_t _cf = 0; 793 int _df = 1; 794 uint32_t _flag_k = FK_NONE; 795 uint32_t _flag_a = 0, _flag_b = 0; 796 uint32_t _itail_tgt = 0; 797 RECOMP_REGS_LOCALS 798 RECOMP_ENTER(0x3B003A00u); 799 800 L_3B003A00: 801 ecx = 0x3B008041u; /* 0x3B003A00: mov ecx, 0x3b008041 */ 802 L_3B003A05: 803 { _itail_tgt = (uint32_t)(MEM32(0x3B006008)); goto _ljump; } 804 { RECOMP_REGS_OUT(); return; } /* end of function */ 805 _ljump: 806 switch (_itail_tgt) { 807 case 0x3B003A00u: goto L_3B003A00; 808 case 0x3B003A05u: goto L_3B003A05; 809 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 810 } 811 RECOMP_REGS_OUT(); 812 } 813 814 void sub_3B003A10(void) { 815 int _fpu_cmp = 0; 816 uint32_t _cf = 0; 817 int _df = 1; 818 uint32_t _flag_k = FK_NONE; 819 uint32_t _flag_a = 0, _flag_b = 0; 820 uint32_t _itail_tgt = 0; 821 RECOMP_REGS_LOCALS 822 RECOMP_ENTER(0x3B003A10u); 823 824 L_3B003A10: 825 RECOMP_ICALL(0x3B003A20u); /* 0x3B003A10: call 0x3b003a20 */ /* not lifted */ 826 RECOMP_FLAGS_IN(); 827 goto L_3B003A30; /* 0x3B003A15: jmp 0x3b003a30 */ 828 L_3B003A30: 829 PUSH32(esp, 0x3B003A40u); /* 0x3B003A30: push 0x3b003a40 */ 830 RECOMP_ICALL(0x3B0050E8u); /* 0x3B003A35: call 0x3b0050e8 */ /* not lifted */ 831 RECOMP_FLAGS_IN(); 832 ecx = POP32_VAL(esp); /* 0x3B003A3A: pop ecx */ 833 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003A3B: ret */ 834 RECOMP_REGS_OUT(); 835 } 836 837 void sub_3B003A20(void) { 838 int _fpu_cmp = 0; 839 uint32_t _cf = 0; 840 int _df = 1; 841 uint32_t _flag_k = FK_NONE; 842 uint32_t _flag_a = 0, _flag_b = 0; 843 uint32_t _itail_tgt = 0; 844 RECOMP_REGS_LOCALS 845 RECOMP_ENTER(0x3B003A20u); 846 847 L_3B003A20: 848 ecx = 0x3B008040u; /* 0x3B003A20: mov ecx, 0x3b008040 */ 849 L_3B003A25: 850 { _itail_tgt = (uint32_t)(MEM32(0x3B00600C)); goto _ljump; } 851 { RECOMP_REGS_OUT(); return; } /* end of function */ 852 _ljump: 853 switch (_itail_tgt) { 854 case 0x3B003A20u: goto L_3B003A20; 855 case 0x3B003A25u: goto L_3B003A25; 856 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 857 } 858 RECOMP_REGS_OUT(); 859 } 860 861 void sub_3B003A30(void) { 862 int _fpu_cmp = 0; 863 uint32_t _cf = 0; 864 int _df = 1; 865 uint32_t _flag_k = FK_NONE; 866 uint32_t _flag_a = 0, _flag_b = 0; 867 uint32_t _itail_tgt = 0; 868 RECOMP_REGS_LOCALS 869 RECOMP_ENTER(0x3B003A30u); 870 871 L_3B003A30: 872 PUSH32(esp, 0x3B003A40u); /* 0x3B003A30: push 0x3b003a40 */ 873 RECOMP_ICALL(0x3B0050E8u); /* 0x3B003A35: call 0x3b0050e8 */ /* not lifted */ 874 RECOMP_FLAGS_IN(); 875 ecx = POP32_VAL(esp); /* 0x3B003A3A: pop ecx */ 876 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003A3B: ret */ 877 RECOMP_REGS_OUT(); 878 } 879 880 void sub_3B003A40(void) { 881 int _fpu_cmp = 0; 882 uint32_t _cf = 0; 883 int _df = 1; 884 uint32_t _flag_k = FK_NONE; 885 uint32_t _flag_a = 0, _flag_b = 0; 886 uint32_t _itail_tgt = 0; 887 RECOMP_REGS_LOCALS 888 RECOMP_ENTER(0x3B003A40u); 889 890 L_3B003A40: 891 ecx = 0x3B008040u; /* 0x3B003A40: mov ecx, 0x3b008040 */ 892 L_3B003A45: 893 { _itail_tgt = (uint32_t)(MEM32(0x3B006010)); goto _ljump; } 894 { RECOMP_REGS_OUT(); return; } /* end of function */ 895 _ljump: 896 switch (_itail_tgt) { 897 case 0x3B003A40u: goto L_3B003A40; 898 case 0x3B003A45u: goto L_3B003A45; 899 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 900 } 901 RECOMP_REGS_OUT(); 902 } 903 904 void sub_3B003A50(void) { 905 int _fpu_cmp = 0; 906 uint32_t _cf = 0; 907 int _df = 1; 908 uint32_t _flag_k = FK_NONE; 909 uint32_t _flag_a = 0, _flag_b = 0; 910 uint32_t _itail_tgt = 0; 911 RECOMP_REGS_LOCALS 912 RECOMP_ENTER(0x3B003A50u); 913 914 L_3B003A50: 915 PUSH32(esp, ebp); /* 0x3B003A50: push ebp */ 916 ebp = esp; /* 0x3B003A51: mov ebp, esp */ 917 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x10u); 918 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 919 esp = esp - 0x10u; /* 0x3B003A53: sub esp, 0x10 */ 920 _flag_k = FK_CMP; 921 eax = ecx; /* 0x3B003A56: mov eax, ecx */ 922 edx = MEM32(eax + 0x10); /* 0x3B003A58: mov edx, dword ptr [eax + 0x10] */ 923 ecx = MEM32(eax + 0xC); /* 0x3B003A5B: mov ecx, dword ptr [eax + 0xc] */ 924 fp_push(*(float*)&MEM32(eax)); /* 0x3B003A5E: fld dword ptr [eax] */ 925 fp_push(*(float*)&MEM32(eax + 0x4)); /* 0x3B003A60: fld dword ptr [eax + 4] */ 926 MEM32(ebp + (-0x4)) = edx; /* 0x3B003A63: mov dword ptr [ebp - 4], edx */ 927 edx = MEM32(eax + 0x1C); /* 0x3B003A66: mov edx, dword ptr [eax + 0x1c] */ 928 MEM32(ebp + (-0xC)) = edx; /* 0x3B003A69: mov dword ptr [ebp - 0xc], edx */ 929 edx = MEM32(ebp + 0x8); /* 0x3B003A6C: mov edx, dword ptr [ebp + 8] */ 930 fp_push(_st[1]); /* 0x3B003A6F: fld st(1) */ 931 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B003A71: fmul dword ptr [edx] */ 932 fp_push(_st[1]); /* 0x3B003A73: fld st(1) */ 933 _st[0] *= (double)*(float*)ADDR(edx + 0xC); /* 0x3B003A75: fmul dword ptr [edx + 0xc] */ 934 MEM32(ebp + (-0x8)) = ecx; /* 0x3B003A78: mov dword ptr [ebp - 8], ecx */ 935 ecx = MEM32(eax + 0x18); /* 0x3B003A7B: mov ecx, dword ptr [eax + 0x18] */ 936 MEM32(ebp + (-0x10)) = ecx; /* 0x3B003A7E: mov dword ptr [ebp - 0x10], ecx */ 937 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003A81: faddp st(1) */ 938 fp_push(*(float*)&MEM32(eax + 0x8)); /* 0x3B003A83: fld dword ptr [eax + 8] */ 939 _st[0] *= (double)*(float*)ADDR(edx + 0x18); /* 0x3B003A86: fmul dword ptr [edx + 0x18] */ 940 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003A89: faddp st(1) */ 941 { float _v = (float)fp_pop(); *(float*)ADDR(eax) = _v; } /* 0x3B003A8B: fstp dword ptr [eax] */ 942 fp_push(_st[1]); /* 0x3B003A8D: fld st(1) */ 943 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B003A8F: fmul dword ptr [edx + 4] */ 944 fp_push(_st[1]); /* 0x3B003A92: fld st(1) */ 945 _st[0] *= (double)*(float*)ADDR(edx + 0x10); /* 0x3B003A94: fmul dword ptr [edx + 0x10] */ 946 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003A97: faddp st(1) */ 947 fp_push(*(float*)&MEM32(eax + 0x8)); /* 0x3B003A99: fld dword ptr [eax + 8] */ 948 _st[0] *= (double)*(float*)ADDR(edx + 0x1C); /* 0x3B003A9C: fmul dword ptr [edx + 0x1c] */ 949 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003A9F: faddp st(1) */ 950 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x4) = _v; } /* 0x3B003AA1: fstp dword ptr [eax + 4] */ 951 _st[0] *= (double)*(float*)ADDR(edx + 0x14); /* 0x3B003AA4: fmul dword ptr [edx + 0x14] */ 952 fp_push(*(float*)&MEM32(edx + 0x20)); /* 0x3B003AA7: fld dword ptr [edx + 0x20] */ 953 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B003AAA: fmul dword ptr [eax + 8] */ 954 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003AAD: faddp st(1) */ 955 fp_xch(1); /* 0x3B003AAF: fxch st(1) */ 956 _st[0] *= (double)*(float*)ADDR(edx + 0x8); /* 0x3B003AB1: fmul dword ptr [edx + 8] */ 957 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003AB4: faddp st(1) */ 958 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x8) = _v; } /* 0x3B003AB6: fstp dword ptr [eax + 8] */ 959 fp_push(*(float*)&MEM32(edx + 0x18)); /* 0x3B003AB9: fld dword ptr [edx + 0x18] */ 960 _st[0] *= (double)*(float*)ADDR(eax + 0x14); /* 0x3B003ABC: fmul dword ptr [eax + 0x14] */ 961 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B003ABF: fld dword ptr [ebp - 8] */ 962 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B003AC2: fmul dword ptr [edx] */ 963 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003AC4: faddp st(1) */ 964 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B003AC6: fld dword ptr [ebp - 4] */ 965 _st[0] *= (double)*(float*)ADDR(edx + 0xC); /* 0x3B003AC9: fmul dword ptr [edx + 0xc] */ 966 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003ACC: faddp st(1) */ 967 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0xC) = _v; } /* 0x3B003ACE: fstp dword ptr [eax + 0xc] */ 968 fp_push(*(float*)&MEM32(edx + 0x1C)); /* 0x3B003AD1: fld dword ptr [edx + 0x1c] */ 969 _st[0] *= (double)*(float*)ADDR(eax + 0x14); /* 0x3B003AD4: fmul dword ptr [eax + 0x14] */ 970 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B003AD7: fld dword ptr [ebp - 8] */ 971 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B003ADA: fmul dword ptr [edx + 4] */ 972 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003ADD: faddp st(1) */ 973 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B003ADF: fld dword ptr [ebp - 4] */ 974 _st[0] *= (double)*(float*)ADDR(edx + 0x10); /* 0x3B003AE2: fmul dword ptr [edx + 0x10] */ 975 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003AE5: faddp st(1) */ 976 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x10) = _v; } /* 0x3B003AE7: fstp dword ptr [eax + 0x10] */ 977 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B003AEA: fld dword ptr [ebp - 4] */ 978 _st[0] *= (double)*(float*)ADDR(edx + 0x14); /* 0x3B003AED: fmul dword ptr [edx + 0x14] */ 979 fp_push(*(float*)&MEM32(edx + 0x20)); /* 0x3B003AF0: fld dword ptr [edx + 0x20] */ 980 _st[0] *= (double)*(float*)ADDR(eax + 0x14); /* 0x3B003AF3: fmul dword ptr [eax + 0x14] */ 981 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003AF6: faddp st(1) */ 982 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B003AF8: fld dword ptr [ebp - 8] */ 983 _st[0] *= (double)*(float*)ADDR(edx + 0x8); /* 0x3B003AFB: fmul dword ptr [edx + 8] */ 984 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003AFE: faddp st(1) */ 985 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x14) = _v; } /* 0x3B003B00: fstp dword ptr [eax + 0x14] */ 986 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x3B003B03: fld dword ptr [ebp - 0x10] */ 987 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B003B06: fmul dword ptr [edx] */ 988 fp_push(*(float*)&MEM32(eax + 0x20)); /* 0x3B003B08: fld dword ptr [eax + 0x20] */ 989 _st[0] *= (double)*(float*)ADDR(edx + 0x18); /* 0x3B003B0B: fmul dword ptr [edx + 0x18] */ 990 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003B0E: faddp st(1) */ 991 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B003B10: fld dword ptr [ebp - 0xc] */ 992 _st[0] *= (double)*(float*)ADDR(edx + 0xC); /* 0x3B003B13: fmul dword ptr [edx + 0xc] */ 993 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003B16: faddp st(1) */ 994 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x18) = _v; } /* 0x3B003B18: fstp dword ptr [eax + 0x18] */ 995 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x3B003B1B: fld dword ptr [ebp - 0x10] */ 996 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B003B1E: fmul dword ptr [edx + 4] */ 997 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B003B21: fld dword ptr [ebp - 0xc] */ 998 _st[0] *= (double)*(float*)ADDR(edx + 0x10); /* 0x3B003B24: fmul dword ptr [edx + 0x10] */ 999 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003B27: faddp st(1) */ 1000 fp_push(*(float*)&MEM32(eax + 0x20)); /* 0x3B003B29: fld dword ptr [eax + 0x20] */ 1001 _st[0] *= (double)*(float*)ADDR(edx + 0x1C); /* 0x3B003B2C: fmul dword ptr [edx + 0x1c] */ 1002 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003B2F: faddp st(1) */ 1003 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x1C) = _v; } /* 0x3B003B31: fstp dword ptr [eax + 0x1c] */ 1004 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B003B34: fld dword ptr [ebp - 0xc] */ 1005 _st[0] *= (double)*(float*)ADDR(edx + 0x14); /* 0x3B003B37: fmul dword ptr [edx + 0x14] */ 1006 fp_push(*(float*)&MEM32(edx + 0x20)); /* 0x3B003B3A: fld dword ptr [edx + 0x20] */ 1007 _st[0] *= (double)*(float*)ADDR(eax + 0x20); /* 0x3B003B3D: fmul dword ptr [eax + 0x20] */ 1008 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003B40: faddp st(1) */ 1009 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x3B003B42: fld dword ptr [ebp - 0x10] */ 1010 _st[0] *= (double)*(float*)ADDR(edx + 0x8); /* 0x3B003B45: fmul dword ptr [edx + 8] */ 1011 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003B48: faddp st(1) */ 1012 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x20) = _v; } /* 0x3B003B4A: fstp dword ptr [eax + 0x20] */ 1013 esp = ebp; /* 0x3B003B4D: mov esp, ebp */ 1014 ebp = POP32_VAL(esp); /* 0x3B003B4F: pop ebp */ 1015 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B003B50: ret 4 */ 1016 RECOMP_REGS_OUT(); 1017 } 1018 1019 void sub_3B003B60(void) { 1020 int _fpu_cmp = 0; 1021 uint32_t _cf = 0; 1022 int _df = 1; 1023 uint32_t _flag_k = FK_NONE; 1024 uint32_t _flag_a = 0, _flag_b = 0; 1025 uint32_t _itail_tgt = 0; 1026 RECOMP_REGS_LOCALS 1027 RECOMP_ENTER(0x3B003B60u); 1028 1029 L_3B003B60: 1030 PUSH32(esp, ebp); /* 0x3B003B60: push ebp */ 1031 ebp = esp; /* 0x3B003B61: mov ebp, esp */ 1032 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x24u); 1033 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1034 esp = esp - 0x24u; /* 0x3B003B63: sub esp, 0x24 */ 1035 _flag_k = FK_CMP; 1036 eax = MEM32(ebp + 0xC); /* 0x3B003B66: mov eax, dword ptr [ebp + 0xc] */ 1037 PUSH32(esp, esi); /* 0x3B003B69: push esi */ 1038 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B003B6A: fld dword ptr [ecx + 8] */ 1039 _st[0] *= (double)*(float*)ADDR(eax + 0x18); /* 0x3B003B6D: fmul dword ptr [eax + 0x18] */ 1040 fp_push(*(float*)&MEM32(eax + 0xC)); /* 0x3B003B70: fld dword ptr [eax + 0xc] */ 1041 _st[0] *= (double)*(float*)ADDR(ecx + 0x4); /* 0x3B003B73: fmul dword ptr [ecx + 4] */ 1042 PUSH32(esp, edi); /* 0x3B003B76: push edi */ 1043 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003B77: faddp st(1) */ 1044 fp_push(*(float*)&MEM32(eax)); /* 0x3B003B79: fld dword ptr [eax] */ 1045 _st[0] *= (double)*(float*)ADDR(ecx); /* 0x3B003B7B: fmul dword ptr [ecx] */ 1046 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003B7D: faddp st(1) */ 1047 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x3B003B7F: fstp dword ptr [ebp - 0x24] */ 1048 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B003B82: fld dword ptr [ecx + 8] */ 1049 _st[0] *= (double)*(float*)ADDR(eax + 0x1C); /* 0x3B003B85: fmul dword ptr [eax + 0x1c] */ 1050 fp_push(*(float*)&MEM32(eax + 0x10)); /* 0x3B003B88: fld dword ptr [eax + 0x10] */ 1051 _st[0] *= (double)*(float*)ADDR(ecx + 0x4); /* 0x3B003B8B: fmul dword ptr [ecx + 4] */ 1052 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003B8E: faddp st(1) */ 1053 fp_push(*(float*)&MEM32(eax + 0x4)); /* 0x3B003B90: fld dword ptr [eax + 4] */ 1054 _st[0] *= (double)*(float*)ADDR(ecx); /* 0x3B003B93: fmul dword ptr [ecx] */ 1055 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003B95: faddp st(1) */ 1056 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x3B003B97: fstp dword ptr [ebp - 0x20] */ 1057 fp_push(*(float*)&MEM32(eax + 0x8)); /* 0x3B003B9A: fld dword ptr [eax + 8] */ 1058 _st[0] *= (double)*(float*)ADDR(ecx); /* 0x3B003B9D: fmul dword ptr [ecx] */ 1059 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B003B9F: fld dword ptr [ecx + 8] */ 1060 _st[0] *= (double)*(float*)ADDR(eax + 0x20); /* 0x3B003BA2: fmul dword ptr [eax + 0x20] */ 1061 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003BA5: faddp st(1) */ 1062 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x3B003BA7: fld dword ptr [ecx + 4] */ 1063 _st[0] *= (double)*(float*)ADDR(eax + 0x14); /* 0x3B003BAA: fmul dword ptr [eax + 0x14] */ 1064 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003BAD: faddp st(1) */ 1065 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x3B003BAF: fstp dword ptr [ebp - 0x1c] */ 1066 fp_push(*(float*)&MEM32(eax + 0xC)); /* 0x3B003BB2: fld dword ptr [eax + 0xc] */ 1067 _st[0] *= (double)*(float*)ADDR(ecx + 0x10); /* 0x3B003BB5: fmul dword ptr [ecx + 0x10] */ 1068 fp_push(*(float*)&MEM32(ecx + 0xC)); /* 0x3B003BB8: fld dword ptr [ecx + 0xc] */ 1069 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B003BBB: fmul dword ptr [eax] */ 1070 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003BBD: faddp st(1) */ 1071 fp_push(*(float*)&MEM32(eax + 0x18)); /* 0x3B003BBF: fld dword ptr [eax + 0x18] */ 1072 _st[0] *= (double)*(float*)ADDR(ecx + 0x14); /* 0x3B003BC2: fmul dword ptr [ecx + 0x14] */ 1073 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003BC5: faddp st(1) */ 1074 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x3B003BC7: fstp dword ptr [ebp - 0x18] */ 1075 fp_push(*(float*)&MEM32(eax + 0x1C)); /* 0x3B003BCA: fld dword ptr [eax + 0x1c] */ 1076 _st[0] *= (double)*(float*)ADDR(ecx + 0x14); /* 0x3B003BCD: fmul dword ptr [ecx + 0x14] */ 1077 fp_push(*(float*)&MEM32(eax + 0x10)); /* 0x3B003BD0: fld dword ptr [eax + 0x10] */ 1078 _st[0] *= (double)*(float*)ADDR(ecx + 0x10); /* 0x3B003BD3: fmul dword ptr [ecx + 0x10] */ 1079 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003BD6: faddp st(1) */ 1080 fp_push(*(float*)&MEM32(eax + 0x4)); /* 0x3B003BD8: fld dword ptr [eax + 4] */ 1081 _st[0] *= (double)*(float*)ADDR(ecx + 0xC); /* 0x3B003BDB: fmul dword ptr [ecx + 0xc] */ 1082 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003BDE: faddp st(1) */ 1083 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3B003BE0: fstp dword ptr [ebp - 0x14] */ 1084 fp_push(*(float*)&MEM32(eax + 0x20)); /* 0x3B003BE3: fld dword ptr [eax + 0x20] */ 1085 _st[0] *= (double)*(float*)ADDR(ecx + 0x14); /* 0x3B003BE6: fmul dword ptr [ecx + 0x14] */ 1086 fp_push(*(float*)&MEM32(eax + 0x14)); /* 0x3B003BE9: fld dword ptr [eax + 0x14] */ 1087 _st[0] *= (double)*(float*)ADDR(ecx + 0x10); /* 0x3B003BEC: fmul dword ptr [ecx + 0x10] */ 1088 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003BEF: faddp st(1) */ 1089 fp_push(*(float*)&MEM32(eax + 0x8)); /* 0x3B003BF1: fld dword ptr [eax + 8] */ 1090 _st[0] *= (double)*(float*)ADDR(ecx + 0xC); /* 0x3B003BF4: fmul dword ptr [ecx + 0xc] */ 1091 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003BF7: faddp st(1) */ 1092 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3B003BF9: fstp dword ptr [ebp - 0x10] */ 1093 fp_push(*(float*)&MEM32(ecx + 0x20)); /* 0x3B003BFC: fld dword ptr [ecx + 0x20] */ 1094 _st[0] *= (double)*(float*)ADDR(eax + 0x18); /* 0x3B003BFF: fmul dword ptr [eax + 0x18] */ 1095 fp_push(*(float*)&MEM32(ecx + 0x1C)); /* 0x3B003C02: fld dword ptr [ecx + 0x1c] */ 1096 _st[0] *= (double)*(float*)ADDR(eax + 0xC); /* 0x3B003C05: fmul dword ptr [eax + 0xc] */ 1097 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003C08: faddp st(1) */ 1098 fp_push(*(float*)&MEM32(eax)); /* 0x3B003C0A: fld dword ptr [eax] */ 1099 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B003C0C: fmul dword ptr [ecx + 0x18] */ 1100 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003C0F: faddp st(1) */ 1101 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3B003C11: fstp dword ptr [ebp - 0xc] */ 1102 fp_push(*(float*)&MEM32(ecx + 0x20)); /* 0x3B003C14: fld dword ptr [ecx + 0x20] */ 1103 _st[0] *= (double)*(float*)ADDR(eax + 0x1C); /* 0x3B003C17: fmul dword ptr [eax + 0x1c] */ 1104 fp_push(*(float*)&MEM32(ecx + 0x1C)); /* 0x3B003C1A: fld dword ptr [ecx + 0x1c] */ 1105 _st[0] *= (double)*(float*)ADDR(eax + 0x10); /* 0x3B003C1D: fmul dword ptr [eax + 0x10] */ 1106 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003C20: faddp st(1) */ 1107 fp_push(*(float*)&MEM32(eax + 0x4)); /* 0x3B003C22: fld dword ptr [eax + 4] */ 1108 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B003C25: fmul dword ptr [ecx + 0x18] */ 1109 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003C28: faddp st(1) */ 1110 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3B003C2A: fstp dword ptr [ebp - 8] */ 1111 fp_push(*(float*)&MEM32(eax + 0x8)); /* 0x3B003C2D: fld dword ptr [eax + 8] */ 1112 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B003C30: fmul dword ptr [ecx + 0x18] */ 1113 fp_push(*(float*)&MEM32(ecx + 0x20)); /* 0x3B003C33: fld dword ptr [ecx + 0x20] */ 1114 _st[0] *= (double)*(float*)ADDR(eax + 0x20); /* 0x3B003C36: fmul dword ptr [eax + 0x20] */ 1115 esi = ebp + (-0x24); /* 0x3B003C39: lea esi, [ebp - 0x24] */ 1116 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003C3C: faddp st(1) */ 1117 fp_push(*(float*)&MEM32(ecx + 0x1C)); /* 0x3B003C3E: fld dword ptr [ecx + 0x1c] */ 1118 _st[0] *= (double)*(float*)ADDR(eax + 0x14); /* 0x3B003C41: fmul dword ptr [eax + 0x14] */ 1119 eax = MEM32(ebp + 0x8); /* 0x3B003C44: mov eax, dword ptr [ebp + 8] */ 1120 ecx = 9; /* 0x3B003C47: mov ecx, 9 */ 1121 edi = eax; /* 0x3B003C4C: mov edi, eax */ 1122 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003C4E: faddp st(1) */ 1123 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3B003C50: fstp dword ptr [ebp - 4] */ 1124 if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3B003C53: rep movsd dword ptr es:[edi], dword ptr [esi] */ if (_df > 0) { memmove((void*)ADDR(edi), (void*)ADDR(esi), _b); esi += _b; edi += _b; } else { memmove((void*)ADDR(edi - _b + 4u), (void*)ADDR(esi - _b + 4u), _b); esi -= _b; edi -= _b; } ecx = 0; } 1125 edi = POP32_VAL(esp); /* 0x3B003C55: pop edi */ 1126 esi = POP32_VAL(esp); /* 0x3B003C56: pop esi */ 1127 esp = ebp; /* 0x3B003C57: mov esp, ebp */ 1128 ebp = POP32_VAL(esp); /* 0x3B003C59: pop ebp */ 1129 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3B003C5A: ret 8 */ 1130 RECOMP_REGS_OUT(); 1131 } 1132 1133 void sub_3B003C60(void) { 1134 int _fpu_cmp = 0; 1135 uint32_t _cf = 0; 1136 int _df = 1; 1137 uint32_t _flag_k = FK_NONE; 1138 uint32_t _flag_a = 0, _flag_b = 0; 1139 uint32_t _itail_tgt = 0; 1140 RECOMP_REGS_LOCALS 1141 RECOMP_ENTER(0x3B003C60u); 1142 1143 L_3B003C60: 1144 PUSH32(esp, ebp); /* 0x3B003C60: push ebp */ 1145 ebp = esp; /* 0x3B003C61: mov ebp, esp */ 1146 PUSH32(esp, ecx); /* 0x3B003C63: push ecx */ 1147 PUSH32(esp, esi); /* 0x3B003C64: push esi */ 1148 esi = ecx; /* 0x3B003C65: mov esi, ecx */ 1149 fp_push(*(float*)&MEM32(esi + 0x10)); /* 0x3B003C67: fld dword ptr [esi + 0x10] */ 1150 _st[0] *= (double)*(float*)ADDR(esi + 0x20); /* 0x3B003C6A: fmul dword ptr [esi + 0x20] */ 1151 fp_push(*(float*)&MEM32(esi + 0x1C)); /* 0x3B003C6D: fld dword ptr [esi + 0x1c] */ 1152 _st[0] *= (double)*(float*)ADDR(esi + 0x14); /* 0x3B003C70: fmul dword ptr [esi + 0x14] */ 1153 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003C73: fsubp st(1) */ 1154 _st[0] *= (double)*(float*)ADDR(esi); /* 0x3B003C75: fmul dword ptr [esi] */ 1155 fp_push(*(float*)&MEM32(esi + 0xC)); /* 0x3B003C77: fld dword ptr [esi + 0xc] */ 1156 _st[0] *= (double)*(float*)ADDR(esi + 0x20); /* 0x3B003C7A: fmul dword ptr [esi + 0x20] */ 1157 fp_push(*(float*)&MEM32(esi + 0x18)); /* 0x3B003C7D: fld dword ptr [esi + 0x18] */ 1158 _st[0] *= (double)*(float*)ADDR(esi + 0x14); /* 0x3B003C80: fmul dword ptr [esi + 0x14] */ 1159 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003C83: fsubp st(1) */ 1160 _st[0] *= (double)*(float*)ADDR(esi + 0x4); /* 0x3B003C85: fmul dword ptr [esi + 4] */ 1161 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003C88: fsubp st(1) */ 1162 fp_push(*(float*)&MEM32(esi + 0x1C)); /* 0x3B003C8A: fld dword ptr [esi + 0x1c] */ 1163 _st[0] *= (double)*(float*)ADDR(esi + 0xC); /* 0x3B003C8D: fmul dword ptr [esi + 0xc] */ 1164 fp_push(*(float*)&MEM32(esi + 0x18)); /* 0x3B003C90: fld dword ptr [esi + 0x18] */ 1165 _st[0] *= (double)*(float*)ADDR(esi + 0x10); /* 0x3B003C93: fmul dword ptr [esi + 0x10] */ 1166 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003C96: fsubp st(1) */ 1167 _st[0] *= (double)*(float*)ADDR(esi + 0x8); /* 0x3B003C98: fmul dword ptr [esi + 8] */ 1168 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B003C9B: faddp st(1) */ 1169 { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3B003C9D: fst dword ptr [ebp - 4] */ 1170 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B003CA0: fcomp dword ptr [0x3b00604c] */ 1171 fp_pop(); 1172 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B003CA6: fnstsw ax */ 1173 /* test HI8(eax), 0x40u */ /* 0x3B003CA8: test ah, 0x40 */ 1174 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 1175 _cf = 0; 1176 _flag_k = FK_NARROW(FK_TEST, 24); 1177 if (TEST_Z(_flag_a, _flag_b)) goto L_3B003CD0; /* 0x3B003CAB: je 0x3b003cd0 */ 1178 L_3B003CAD: 1179 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1180 eax = 0; /* 0x3B003CAD: xor eax, eax */ 1181 _cf = 0; 1182 _flag_k = FK_TEST; 1183 MEM32(esi + 0x20) = eax; /* 0x3B003CAF: mov dword ptr [esi + 0x20], eax */ 1184 MEM32(esi + 0x1C) = eax; /* 0x3B003CB2: mov dword ptr [esi + 0x1c], eax */ 1185 MEM32(esi + 0x18) = eax; /* 0x3B003CB5: mov dword ptr [esi + 0x18], eax */ 1186 MEM32(esi + 0x14) = eax; /* 0x3B003CB8: mov dword ptr [esi + 0x14], eax */ 1187 MEM32(esi + 0x10) = eax; /* 0x3B003CBB: mov dword ptr [esi + 0x10], eax */ 1188 MEM32(esi + 0xC) = eax; /* 0x3B003CBE: mov dword ptr [esi + 0xc], eax */ 1189 MEM32(esi + 0x8) = eax; /* 0x3B003CC1: mov dword ptr [esi + 8], eax */ 1190 MEM32(esi + 0x4) = eax; /* 0x3B003CC4: mov dword ptr [esi + 4], eax */ 1191 MEM32(esi) = eax; /* 0x3B003CC7: mov dword ptr [esi], eax */ 1192 eax = esi; /* 0x3B003CC9: mov eax, esi */ 1193 esi = POP32_VAL(esp); /* 0x3B003CCB: pop esi */ 1194 esp = ebp; /* 0x3B003CCC: mov esp, ebp */ 1195 ebp = POP32_VAL(esp); /* 0x3B003CCE: pop ebp */ 1196 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003CCF: ret */ 1197 L_3B003CD0: 1198 ecx = esi; /* 0x3B003CD0: mov ecx, esi */ 1199 RECOMP_ICALL(0x3B003D30u); /* 0x3B003CD2: call 0x3b003d30 */ /* not lifted */ 1200 RECOMP_FLAGS_IN(); 1201 fp_push(*(float*)&MEM32(esi)); /* 0x3B003CD7: fld dword ptr [esi] */ 1202 _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B003CD9: fdiv dword ptr [ebp - 4] */ 1203 eax = esi; /* 0x3B003CDC: mov eax, esi */ 1204 { float _v = (float)fp_pop(); *(float*)ADDR(esi) = _v; } /* 0x3B003CDE: fstp dword ptr [esi] */ 1205 fp_push(*(float*)&MEM32(esi + 0x4)); /* 0x3B003CE0: fld dword ptr [esi + 4] */ 1206 _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B003CE3: fdiv dword ptr [ebp - 4] */ 1207 { float _v = (float)fp_pop(); *(float*)ADDR(esi + 0x4) = _v; } /* 0x3B003CE6: fstp dword ptr [esi + 4] */ 1208 fp_push(*(float*)&MEM32(esi + 0x8)); /* 0x3B003CE9: fld dword ptr [esi + 8] */ 1209 _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B003CEC: fdiv dword ptr [ebp - 4] */ 1210 { float _v = (float)fp_pop(); *(float*)ADDR(esi + 0x8) = _v; } /* 0x3B003CEF: fstp dword ptr [esi + 8] */ 1211 fp_push(*(float*)&MEM32(esi + 0xC)); /* 0x3B003CF2: fld dword ptr [esi + 0xc] */ 1212 _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B003CF5: fdiv dword ptr [ebp - 4] */ 1213 { float _v = (float)fp_pop(); *(float*)ADDR(esi + 0xC) = _v; } /* 0x3B003CF8: fstp dword ptr [esi + 0xc] */ 1214 fp_push(*(float*)&MEM32(esi + 0x10)); /* 0x3B003CFB: fld dword ptr [esi + 0x10] */ 1215 _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B003CFE: fdiv dword ptr [ebp - 4] */ 1216 { float _v = (float)fp_pop(); *(float*)ADDR(esi + 0x10) = _v; } /* 0x3B003D01: fstp dword ptr [esi + 0x10] */ 1217 fp_push(*(float*)&MEM32(esi + 0x14)); /* 0x3B003D04: fld dword ptr [esi + 0x14] */ 1218 _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B003D07: fdiv dword ptr [ebp - 4] */ 1219 { float _v = (float)fp_pop(); *(float*)ADDR(esi + 0x14) = _v; } /* 0x3B003D0A: fstp dword ptr [esi + 0x14] */ 1220 fp_push(*(float*)&MEM32(esi + 0x18)); /* 0x3B003D0D: fld dword ptr [esi + 0x18] */ 1221 _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B003D10: fdiv dword ptr [ebp - 4] */ 1222 { float _v = (float)fp_pop(); *(float*)ADDR(esi + 0x18) = _v; } /* 0x3B003D13: fstp dword ptr [esi + 0x18] */ 1223 fp_push(*(float*)&MEM32(esi + 0x1C)); /* 0x3B003D16: fld dword ptr [esi + 0x1c] */ 1224 _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B003D19: fdiv dword ptr [ebp - 4] */ 1225 { float _v = (float)fp_pop(); *(float*)ADDR(esi + 0x1C) = _v; } /* 0x3B003D1C: fstp dword ptr [esi + 0x1c] */ 1226 fp_push(*(float*)&MEM32(esi + 0x20)); /* 0x3B003D1F: fld dword ptr [esi + 0x20] */ 1227 _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B003D22: fdiv dword ptr [ebp - 4] */ 1228 { float _v = (float)fp_pop(); *(float*)ADDR(esi + 0x20) = _v; } /* 0x3B003D25: fstp dword ptr [esi + 0x20] */ 1229 esi = POP32_VAL(esp); /* 0x3B003D28: pop esi */ 1230 esp = ebp; /* 0x3B003D29: mov esp, ebp */ 1231 ebp = POP32_VAL(esp); /* 0x3B003D2B: pop ebp */ 1232 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003D2C: ret */ 1233 RECOMP_REGS_OUT(); 1234 } 1235 1236 void sub_3B003D30(void) { 1237 int _fpu_cmp = 0; 1238 uint32_t _cf = 0; 1239 int _df = 1; 1240 uint32_t _flag_k = FK_NONE; 1241 uint32_t _flag_a = 0, _flag_b = 0; 1242 uint32_t _itail_tgt = 0; 1243 RECOMP_REGS_LOCALS 1244 RECOMP_ENTER(0x3B003D30u); 1245 1246 L_3B003D30: 1247 PUSH32(esp, ebp); /* 0x3B003D30: push ebp */ 1248 ebp = esp; /* 0x3B003D31: mov ebp, esp */ 1249 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x24u); 1250 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1251 esp = esp - 0x24u; /* 0x3B003D33: sub esp, 0x24 */ 1252 _flag_k = FK_CMP; 1253 eax = ecx; /* 0x3B003D36: mov eax, ecx */ 1254 fp_push(*(float*)&MEM32(eax + 0x10)); /* 0x3B003D38: fld dword ptr [eax + 0x10] */ 1255 _st[0] *= (double)*(float*)ADDR(eax + 0x20); /* 0x3B003D3B: fmul dword ptr [eax + 0x20] */ 1256 fp_push(*(float*)&MEM32(eax + 0x1C)); /* 0x3B003D3E: fld dword ptr [eax + 0x1c] */ 1257 _st[0] *= (double)*(float*)ADDR(eax + 0x14); /* 0x3B003D41: fmul dword ptr [eax + 0x14] */ 1258 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003D44: fsubp st(1) */ 1259 fp_push(*(float*)&MEM32(eax + 0x1C)); /* 0x3B003D46: fld dword ptr [eax + 0x1c] */ 1260 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B003D49: fmul dword ptr [eax + 8] */ 1261 fp_push(*(float*)&MEM32(eax + 0x4)); /* 0x3B003D4C: fld dword ptr [eax + 4] */ 1262 _st[0] *= (double)*(float*)ADDR(eax + 0x20); /* 0x3B003D4F: fmul dword ptr [eax + 0x20] */ 1263 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003D52: fsubp st(1) */ 1264 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x3B003D54: fstp dword ptr [ebp - 0x20] */ 1265 fp_push(*(float*)&MEM32(eax + 0x4)); /* 0x3B003D57: fld dword ptr [eax + 4] */ 1266 _st[0] *= (double)*(float*)ADDR(eax + 0x14); /* 0x3B003D5A: fmul dword ptr [eax + 0x14] */ 1267 fp_push(*(float*)&MEM32(eax + 0x8)); /* 0x3B003D5D: fld dword ptr [eax + 8] */ 1268 _st[0] *= (double)*(float*)ADDR(eax + 0x10); /* 0x3B003D60: fmul dword ptr [eax + 0x10] */ 1269 ecx = MEM32(ebp + (-0x20)); /* 0x3B003D63: mov ecx, dword ptr [ebp - 0x20] */ 1270 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003D66: fsubp st(1) */ 1271 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x3B003D68: fstp dword ptr [ebp - 0x1c] */ 1272 fp_push(*(float*)&MEM32(eax + 0x18)); /* 0x3B003D6B: fld dword ptr [eax + 0x18] */ 1273 _st[0] *= (double)*(float*)ADDR(eax + 0x14); /* 0x3B003D6E: fmul dword ptr [eax + 0x14] */ 1274 fp_push(*(float*)&MEM32(eax + 0xC)); /* 0x3B003D71: fld dword ptr [eax + 0xc] */ 1275 _st[0] *= (double)*(float*)ADDR(eax + 0x20); /* 0x3B003D74: fmul dword ptr [eax + 0x20] */ 1276 edx = MEM32(ebp + (-0x1C)); /* 0x3B003D77: mov edx, dword ptr [ebp - 0x1c] */ 1277 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003D7A: fsubp st(1) */ 1278 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x3B003D7C: fstp dword ptr [ebp - 0x18] */ 1279 fp_push(*(float*)&MEM32(eax)); /* 0x3B003D7F: fld dword ptr [eax] */ 1280 _st[0] *= (double)*(float*)ADDR(eax + 0x20); /* 0x3B003D81: fmul dword ptr [eax + 0x20] */ 1281 fp_push(*(float*)&MEM32(eax + 0x18)); /* 0x3B003D84: fld dword ptr [eax + 0x18] */ 1282 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B003D87: fmul dword ptr [eax + 8] */ 1283 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003D8A: fsubp st(1) */ 1284 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3B003D8C: fstp dword ptr [ebp - 0x14] */ 1285 fp_push(*(float*)&MEM32(eax + 0xC)); /* 0x3B003D8F: fld dword ptr [eax + 0xc] */ 1286 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B003D92: fmul dword ptr [eax + 8] */ 1287 fp_push(*(float*)&MEM32(eax)); /* 0x3B003D95: fld dword ptr [eax] */ 1288 _st[0] *= (double)*(float*)ADDR(eax + 0x14); /* 0x3B003D97: fmul dword ptr [eax + 0x14] */ 1289 MEM32(eax + 0x8) = edx; /* 0x3B003D9A: mov dword ptr [eax + 8], edx */ 1290 edx = MEM32(ebp + (-0x14)); /* 0x3B003D9D: mov edx, dword ptr [ebp - 0x14] */ 1291 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003DA0: fsubp st(1) */ 1292 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3B003DA2: fstp dword ptr [ebp - 0x10] */ 1293 fp_push(*(float*)&MEM32(eax + 0x1C)); /* 0x3B003DA5: fld dword ptr [eax + 0x1c] */ 1294 _st[0] *= (double)*(float*)ADDR(eax + 0xC); /* 0x3B003DA8: fmul dword ptr [eax + 0xc] */ 1295 fp_push(*(float*)&MEM32(eax + 0x18)); /* 0x3B003DAB: fld dword ptr [eax + 0x18] */ 1296 _st[0] *= (double)*(float*)ADDR(eax + 0x10); /* 0x3B003DAE: fmul dword ptr [eax + 0x10] */ 1297 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003DB1: fsubp st(1) */ 1298 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3B003DB3: fstp dword ptr [ebp - 0xc] */ 1299 fp_push(*(float*)&MEM32(eax + 0x18)); /* 0x3B003DB6: fld dword ptr [eax + 0x18] */ 1300 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B003DB9: fmul dword ptr [eax + 4] */ 1301 fp_push(*(float*)&MEM32(eax + 0x1C)); /* 0x3B003DBC: fld dword ptr [eax + 0x1c] */ 1302 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B003DBF: fmul dword ptr [eax] */ 1303 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003DC1: fsubp st(1) */ 1304 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3B003DC3: fstp dword ptr [ebp - 8] */ 1305 fp_push(*(float*)&MEM32(eax + 0x10)); /* 0x3B003DC6: fld dword ptr [eax + 0x10] */ 1306 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B003DC9: fmul dword ptr [eax] */ 1307 fp_push(*(float*)&MEM32(eax + 0xC)); /* 0x3B003DCB: fld dword ptr [eax + 0xc] */ 1308 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B003DCE: fmul dword ptr [eax + 4] */ 1309 MEM32(eax + 0x4) = ecx; /* 0x3B003DD1: mov dword ptr [eax + 4], ecx */ 1310 ecx = MEM32(ebp + (-0x18)); /* 0x3B003DD4: mov ecx, dword ptr [ebp - 0x18] */ 1311 MEM32(eax + 0xC) = ecx; /* 0x3B003DD7: mov dword ptr [eax + 0xc], ecx */ 1312 ecx = MEM32(ebp + (-0x10)); /* 0x3B003DDA: mov ecx, dword ptr [ebp - 0x10] */ 1313 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B003DDD: fsubp st(1) */ 1314 MEM32(eax + 0x10) = edx; /* 0x3B003DDF: mov dword ptr [eax + 0x10], edx */ 1315 edx = MEM32(ebp + (-0xC)); /* 0x3B003DE2: mov edx, dword ptr [ebp - 0xc] */ 1316 MEM32(eax + 0x14) = ecx; /* 0x3B003DE5: mov dword ptr [eax + 0x14], ecx */ 1317 ecx = MEM32(ebp + (-0x8)); /* 0x3B003DE8: mov ecx, dword ptr [ebp - 8] */ 1318 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3B003DEB: fstp dword ptr [ebp - 4] */ 1319 MEM32(eax + 0x18) = edx; /* 0x3B003DEE: mov dword ptr [eax + 0x18], edx */ 1320 edx = MEM32(ebp + (-0x4)); /* 0x3B003DF1: mov edx, dword ptr [ebp - 4] */ 1321 { float _v = (float)fp_pop(); *(float*)ADDR(eax) = _v; } /* 0x3B003DF4: fstp dword ptr [eax] */ 1322 MEM32(eax + 0x1C) = ecx; /* 0x3B003DF6: mov dword ptr [eax + 0x1c], ecx */ 1323 MEM32(eax + 0x20) = edx; /* 0x3B003DF9: mov dword ptr [eax + 0x20], edx */ 1324 esp = ebp; /* 0x3B003DFC: mov esp, ebp */ 1325 ebp = POP32_VAL(esp); /* 0x3B003DFE: pop ebp */ 1326 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003DFF: ret */ 1327 RECOMP_REGS_OUT(); 1328 } 1329 1330 void sub_3B003E00(void) { 1331 int _fpu_cmp = 0; 1332 uint32_t _cf = 0; 1333 int _df = 1; 1334 uint32_t _flag_k = FK_NONE; 1335 uint32_t _flag_a = 0, _flag_b = 0; 1336 uint32_t _itail_tgt = 0; 1337 RECOMP_REGS_LOCALS 1338 RECOMP_ENTER(0x3B003E00u); 1339 1340 L_3B003E00: 1341 PUSH32(esp, ebp); /* 0x3B003E00: push ebp */ 1342 ebp = esp; /* 0x3B003E01: mov ebp, esp */ 1343 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x24u); 1344 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1345 esp = esp - 0x24u; /* 0x3B003E03: sub esp, 0x24 */ 1346 _flag_k = FK_CMP; 1347 eax = ecx; /* 0x3B003E06: mov eax, ecx */ 1348 ecx = MEM32(eax + 0x18); /* 0x3B003E08: mov ecx, dword ptr [eax + 0x18] */ 1349 edx = MEM32(eax + 0x4); /* 0x3B003E0B: mov edx, dword ptr [eax + 4] */ 1350 fp_push(*(float*)&MEM32(eax + 0xC)); /* 0x3B003E0E: fld dword ptr [eax + 0xc] */ 1351 MEM32(ebp + (-0x1C)) = ecx; /* 0x3B003E11: mov dword ptr [ebp - 0x1c], ecx */ 1352 ecx = MEM32(eax + 0x1C); /* 0x3B003E14: mov ecx, dword ptr [eax + 0x1c] */ 1353 MEM32(ebp + (-0x18)) = edx; /* 0x3B003E17: mov dword ptr [ebp - 0x18], edx */ 1354 edx = MEM32(eax + 0x8); /* 0x3B003E1A: mov edx, dword ptr [eax + 8] */ 1355 MEM32(ebp + (-0x10)) = ecx; /* 0x3B003E1D: mov dword ptr [ebp - 0x10], ecx */ 1356 ecx = MEM32(eax + 0x14); /* 0x3B003E20: mov ecx, dword ptr [eax + 0x14] */ 1357 MEM32(ebp + (-0xC)) = edx; /* 0x3B003E23: mov dword ptr [ebp - 0xc], edx */ 1358 edx = MEM32(ebp + (-0x1C)); /* 0x3B003E26: mov edx, dword ptr [ebp - 0x1c] */ 1359 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x4) = _v; } /* 0x3B003E29: fstp dword ptr [eax + 4] */ 1360 MEM32(ebp + (-0x8)) = ecx; /* 0x3B003E2C: mov dword ptr [ebp - 8], ecx */ 1361 ecx = MEM32(ebp + (-0x18)); /* 0x3B003E2F: mov ecx, dword ptr [ebp - 0x18] */ 1362 MEM32(eax + 0x8) = edx; /* 0x3B003E32: mov dword ptr [eax + 8], edx */ 1363 edx = MEM32(ebp + (-0x10)); /* 0x3B003E35: mov edx, dword ptr [ebp - 0x10] */ 1364 MEM32(eax + 0xC) = ecx; /* 0x3B003E38: mov dword ptr [eax + 0xc], ecx */ 1365 ecx = MEM32(ebp + (-0xC)); /* 0x3B003E3B: mov ecx, dword ptr [ebp - 0xc] */ 1366 MEM32(eax + 0x14) = edx; /* 0x3B003E3E: mov dword ptr [eax + 0x14], edx */ 1367 edx = MEM32(ebp + (-0x8)); /* 0x3B003E41: mov edx, dword ptr [ebp - 8] */ 1368 MEM32(eax + 0x18) = ecx; /* 0x3B003E44: mov dword ptr [eax + 0x18], ecx */ 1369 MEM32(eax + 0x1C) = edx; /* 0x3B003E47: mov dword ptr [eax + 0x1c], edx */ 1370 esp = ebp; /* 0x3B003E4A: mov esp, ebp */ 1371 ebp = POP32_VAL(esp); /* 0x3B003E4C: pop ebp */ 1372 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003E4D: ret */ 1373 RECOMP_REGS_OUT(); 1374 } 1375 1376 void sub_3B003E50(void) { 1377 int _fpu_cmp = 0; 1378 uint32_t _cf = 0; 1379 int _df = 1; 1380 uint32_t _flag_k = FK_NONE; 1381 uint32_t _flag_a = 0, _flag_b = 0; 1382 uint32_t _itail_tgt = 0; 1383 RECOMP_REGS_LOCALS 1384 RECOMP_ENTER(0x3B003E50u); 1385 1386 L_3B003E50: 1387 RECOMP_ICALL(0x3B003E60u); /* 0x3B003E50: call 0x3b003e60 */ /* not lifted */ 1388 RECOMP_FLAGS_IN(); 1389 goto L_3B003E70; /* 0x3B003E55: jmp 0x3b003e70 */ 1390 L_3B003E70: 1391 PUSH32(esp, 0x3B003E80u); /* 0x3B003E70: push 0x3b003e80 */ 1392 RECOMP_ICALL(0x3B0050E8u); /* 0x3B003E75: call 0x3b0050e8 */ /* not lifted */ 1393 RECOMP_FLAGS_IN(); 1394 ecx = POP32_VAL(esp); /* 0x3B003E7A: pop ecx */ 1395 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003E7B: ret */ 1396 RECOMP_REGS_OUT(); 1397 } 1398 1399 void sub_3B003E60(void) { 1400 int _fpu_cmp = 0; 1401 uint32_t _cf = 0; 1402 int _df = 1; 1403 uint32_t _flag_k = FK_NONE; 1404 uint32_t _flag_a = 0, _flag_b = 0; 1405 uint32_t _itail_tgt = 0; 1406 RECOMP_REGS_LOCALS 1407 RECOMP_ENTER(0x3B003E60u); 1408 1409 L_3B003E60: 1410 ecx = 0x3B008045u; /* 0x3B003E60: mov ecx, 0x3b008045 */ 1411 L_3B003E65: 1412 { _itail_tgt = (uint32_t)(MEM32(0x3B006014)); goto _ljump; } 1413 { RECOMP_REGS_OUT(); return; } /* end of function */ 1414 _ljump: 1415 switch (_itail_tgt) { 1416 case 0x3B003E60u: goto L_3B003E60; 1417 case 0x3B003E65u: goto L_3B003E65; 1418 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 1419 } 1420 RECOMP_REGS_OUT(); 1421 } 1422 1423 void sub_3B003E70(void) { 1424 int _fpu_cmp = 0; 1425 uint32_t _cf = 0; 1426 int _df = 1; 1427 uint32_t _flag_k = FK_NONE; 1428 uint32_t _flag_a = 0, _flag_b = 0; 1429 uint32_t _itail_tgt = 0; 1430 RECOMP_REGS_LOCALS 1431 RECOMP_ENTER(0x3B003E70u); 1432 1433 L_3B003E70: 1434 PUSH32(esp, 0x3B003E80u); /* 0x3B003E70: push 0x3b003e80 */ 1435 RECOMP_ICALL(0x3B0050E8u); /* 0x3B003E75: call 0x3b0050e8 */ /* not lifted */ 1436 RECOMP_FLAGS_IN(); 1437 ecx = POP32_VAL(esp); /* 0x3B003E7A: pop ecx */ 1438 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003E7B: ret */ 1439 RECOMP_REGS_OUT(); 1440 } 1441 1442 void sub_3B003E80(void) { 1443 int _fpu_cmp = 0; 1444 uint32_t _cf = 0; 1445 int _df = 1; 1446 uint32_t _flag_k = FK_NONE; 1447 uint32_t _flag_a = 0, _flag_b = 0; 1448 uint32_t _itail_tgt = 0; 1449 RECOMP_REGS_LOCALS 1450 RECOMP_ENTER(0x3B003E80u); 1451 1452 L_3B003E80: 1453 ecx = 0x3B008045u; /* 0x3B003E80: mov ecx, 0x3b008045 */ 1454 L_3B003E85: 1455 { _itail_tgt = (uint32_t)(MEM32(0x3B006008)); goto _ljump; } 1456 { RECOMP_REGS_OUT(); return; } /* end of function */ 1457 _ljump: 1458 switch (_itail_tgt) { 1459 case 0x3B003E80u: goto L_3B003E80; 1460 case 0x3B003E85u: goto L_3B003E85; 1461 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 1462 } 1463 RECOMP_REGS_OUT(); 1464 } 1465 1466 void sub_3B003E90(void) { 1467 int _fpu_cmp = 0; 1468 uint32_t _cf = 0; 1469 int _df = 1; 1470 uint32_t _flag_k = FK_NONE; 1471 uint32_t _flag_a = 0, _flag_b = 0; 1472 uint32_t _itail_tgt = 0; 1473 RECOMP_REGS_LOCALS 1474 RECOMP_ENTER(0x3B003E90u); 1475 1476 L_3B003E90: 1477 RECOMP_ICALL(0x3B003EA0u); /* 0x3B003E90: call 0x3b003ea0 */ /* not lifted */ 1478 RECOMP_FLAGS_IN(); 1479 goto L_3B003EB0; /* 0x3B003E95: jmp 0x3b003eb0 */ 1480 L_3B003EB0: 1481 PUSH32(esp, 0x3B003EC0u); /* 0x3B003EB0: push 0x3b003ec0 */ 1482 RECOMP_ICALL(0x3B0050E8u); /* 0x3B003EB5: call 0x3b0050e8 */ /* not lifted */ 1483 RECOMP_FLAGS_IN(); 1484 ecx = POP32_VAL(esp); /* 0x3B003EBA: pop ecx */ 1485 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003EBB: ret */ 1486 RECOMP_REGS_OUT(); 1487 } 1488 1489 void sub_3B003EA0(void) { 1490 int _fpu_cmp = 0; 1491 uint32_t _cf = 0; 1492 int _df = 1; 1493 uint32_t _flag_k = FK_NONE; 1494 uint32_t _flag_a = 0, _flag_b = 0; 1495 uint32_t _itail_tgt = 0; 1496 RECOMP_REGS_LOCALS 1497 RECOMP_ENTER(0x3B003EA0u); 1498 1499 L_3B003EA0: 1500 ecx = 0x3B008044u; /* 0x3B003EA0: mov ecx, 0x3b008044 */ 1501 L_3B003EA5: 1502 { _itail_tgt = (uint32_t)(MEM32(0x3B00600C)); goto _ljump; } 1503 { RECOMP_REGS_OUT(); return; } /* end of function */ 1504 _ljump: 1505 switch (_itail_tgt) { 1506 case 0x3B003EA0u: goto L_3B003EA0; 1507 case 0x3B003EA5u: goto L_3B003EA5; 1508 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 1509 } 1510 RECOMP_REGS_OUT(); 1511 } 1512 1513 void sub_3B003EB0(void) { 1514 int _fpu_cmp = 0; 1515 uint32_t _cf = 0; 1516 int _df = 1; 1517 uint32_t _flag_k = FK_NONE; 1518 uint32_t _flag_a = 0, _flag_b = 0; 1519 uint32_t _itail_tgt = 0; 1520 RECOMP_REGS_LOCALS 1521 RECOMP_ENTER(0x3B003EB0u); 1522 1523 L_3B003EB0: 1524 PUSH32(esp, 0x3B003EC0u); /* 0x3B003EB0: push 0x3b003ec0 */ 1525 RECOMP_ICALL(0x3B0050E8u); /* 0x3B003EB5: call 0x3b0050e8 */ /* not lifted */ 1526 RECOMP_FLAGS_IN(); 1527 ecx = POP32_VAL(esp); /* 0x3B003EBA: pop ecx */ 1528 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B003EBB: ret */ 1529 RECOMP_REGS_OUT(); 1530 } 1531 1532 void sub_3B003EC0(void) { 1533 int _fpu_cmp = 0; 1534 uint32_t _cf = 0; 1535 int _df = 1; 1536 uint32_t _flag_k = FK_NONE; 1537 uint32_t _flag_a = 0, _flag_b = 0; 1538 uint32_t _itail_tgt = 0; 1539 RECOMP_REGS_LOCALS 1540 RECOMP_ENTER(0x3B003EC0u); 1541 1542 L_3B003EC0: 1543 ecx = 0x3B008044u; /* 0x3B003EC0: mov ecx, 0x3b008044 */ 1544 L_3B003EC5: 1545 { _itail_tgt = (uint32_t)(MEM32(0x3B006010)); goto _ljump; } 1546 { RECOMP_REGS_OUT(); return; } /* end of function */ 1547 _ljump: 1548 switch (_itail_tgt) { 1549 case 0x3B003EC0u: goto L_3B003EC0; 1550 case 0x3B003EC5u: goto L_3B003EC5; 1551 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 1552 } 1553 RECOMP_REGS_OUT(); 1554 } 1555 1556 void sub_3B003ED0(void) { 1557 int _fpu_cmp = 0; 1558 uint32_t _cf = 0; 1559 int _df = 1; 1560 uint32_t _flag_k = FK_NONE; 1561 uint32_t _flag_a = 0, _flag_b = 0; 1562 uint32_t _itail_tgt = 0; 1563 RECOMP_REGS_LOCALS 1564 RECOMP_ENTER(0x3B003ED0u); 1565 1566 L_3B003ED0: 1567 PUSH32(esp, ebp); /* 0x3B003ED0: push ebp */ 1568 ebp = esp; /* 0x3B003ED1: mov ebp, esp */ 1569 PUSH32(esp, 0xFFFFFFFFu); /* 0x3B003ED3: push -1 */ 1570 PUSH32(esp, 0x3B005298u); /* 0x3B003ED5: push 0x3b005298 */ 1571 eax = MEM32(FS_BASE + (0)); /* 0x3B003EDA: mov eax, dword ptr fs:[0] */ 1572 PUSH32(esp, eax); /* 0x3B003EE0: push eax */ 1573 MEM32(FS_BASE + (0)) = esp; /* 0x3B003EE1: mov dword ptr fs:[0], esp */ 1574 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x80u); 1575 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1576 esp = esp - 0x80u; /* 0x3B003EE8: sub esp, 0x80 */ 1577 _flag_k = FK_CMP; 1578 PUSH32(esp, ebx); /* 0x3B003EEE: push ebx */ 1579 PUSH32(esp, esi); /* 0x3B003EEF: push esi */ 1580 esi = MEM32(ebp + 0x8); /* 0x3B003EF0: mov esi, dword ptr [ebp + 8] */ 1581 ebx = ecx; /* 0x3B003EF3: mov ebx, ecx */ 1582 PUSH32(esp, edi); /* 0x3B003EF5: push edi */ 1583 ecx = 0x10u; /* 0x3B003EF6: mov ecx, 0x10 */ 1584 edi = ebp + (-0x4C); /* 0x3B003EFB: lea edi, [ebp - 0x4c] */ 1585 if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3B003EFE: rep movsd dword ptr es:[edi], dword ptr [esi] */ if (_df > 0) { memmove((void*)ADDR(edi), (void*)ADDR(esi), _b); esi += _b; edi += _b; } else { memmove((void*)ADDR(edi - _b + 4u), (void*)ADDR(esi - _b + 4u), _b); esi -= _b; edi -= _b; } ecx = 0; } 1586 ecx = ebp + (-0x4C); /* 0x3B003F00: lea ecx, [ebp - 0x4c] */ 1587 MEM32(ebp + (-0x4)) = 0; /* 0x3B003F03: mov dword ptr [ebp - 4], 0 */ 1588 RECOMP_ICALL(0x3B0042B0u); /* 0x3B003F0A: call 0x3b0042b0 */ /* not lifted */ 1589 RECOMP_FLAGS_IN(); 1590 fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x3B003F0F: fld dword ptr [ebp - 0x24] */ 1591 _st[0] += (double)*(float*)ADDR(ebp + (-0x38)); /* 0x3B003F12: fadd dword ptr [ebp - 0x38] */ 1592 { float _v = (float)_st[0]; *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3B003F15: fst dword ptr [ebp + 8] */ 1593 _st[0] += (double)*(float*)ADDR(ebp + (-0x4C)); /* 0x3B003F18: fadd dword ptr [ebp - 0x4c] */ 1594 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3B006070)); /* 0x3B003F1B: fcom qword ptr [0x3b006070] */ 1595 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B003F21: fnstsw ax */ 1596 /* test HI8(eax), 1 */ /* 0x3B003F23: test ah, 1 */ 1597 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 1598 _cf = 0; 1599 _flag_k = FK_NARROW(FK_TEST, 24); 1600 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B003F63; /* 0x3B003F26: jne 0x3b003f63 */ 1601 L_3B003F28: 1602 _st[0] += (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3B003F28: fadd dword ptr [ebp - 0x10] */ 1603 _st[0] = sqrt(_st[0]); /* 0x3B003F2B: fsqrt */ 1604 fp_push(_st[0]); /* 0x3B003F2D: fld st(0) */ 1605 _st[0] *= (double)*(float*)ADDR(0x3B006058); /* 0x3B003F2F: fmul dword ptr [0x3b006058] */ 1606 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0xC) = _v; } /* 0x3B003F35: fstp dword ptr [ebx + 0xc] */ 1607 _st[0] = (double)*(float*)ADDR(0x3B006058) / _st[0]; /* 0x3B003F38: fdivr dword ptr [0x3b006058] */ 1608 fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x3B003F3E: fld dword ptr [ebp - 0x28] */ 1609 _st[0] -= (double)*(float*)ADDR(ebp + (-0x34)); /* 0x3B003F41: fsub dword ptr [ebp - 0x34] */ 1610 _st[0] *= _st[1]; /* 0x3B003F44: fmul st(1) */ 1611 { float _v = (float)fp_pop(); *(float*)ADDR(ebx) = _v; } /* 0x3B003F46: fstp dword ptr [ebx] */ 1612 fp_push(*(float*)&MEM32(ebp + (-0x44))); /* 0x3B003F48: fld dword ptr [ebp - 0x44] */ 1613 _st[0] -= (double)*(float*)ADDR(ebp + (-0x2C)); /* 0x3B003F4B: fsub dword ptr [ebp - 0x2c] */ 1614 _st[0] *= _st[1]; /* 0x3B003F4E: fmul st(1) */ 1615 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0x4) = _v; } /* 0x3B003F50: fstp dword ptr [ebx + 4] */ 1616 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x3B003F53: fld dword ptr [ebp - 0x3c] */ 1617 _st[0] -= (double)*(float*)ADDR(ebp + (-0x48)); /* 0x3B003F56: fsub dword ptr [ebp - 0x48] */ 1618 _st[0] *= _st[1]; /* 0x3B003F59: fmul st(1) */ 1619 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0x8) = _v; } /* 0x3B003F5B: fstp dword ptr [ebx + 8] */ 1620 goto L_3B004058; /* 0x3B003F5E: jmp 0x3b004058 */ 1621 L_3B003F63: 1622 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B003F63: fstp st(0) */ 1623 fp_push(*(float*)&MEM32(ebp + (-0x38))); /* 0x3B003F65: fld dword ptr [ebp - 0x38] */ 1624 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ebp + (-0x4C))); /* 0x3B003F68: fcomp dword ptr [ebp - 0x4c] */ 1625 fp_pop(); 1626 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 1627 ecx = 0; /* 0x3B003F6B: xor ecx, ecx */ 1628 _cf = 0; 1629 _flag_k = FK_TEST; 1630 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B003F6D: fnstsw ax */ 1631 /* test HI8(eax), 0x41u */ /* 0x3B003F6F: test ah, 0x41 */ 1632 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 1633 _cf = 0; 1634 _flag_k = FK_NARROW(FK_TEST, 24); 1635 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B003F79; /* 0x3B003F72: jne 0x3b003f79 */ 1636 L_3B003F74: 1637 ecx = 1; /* 0x3B003F74: mov ecx, 1 */ 1638 L_3B003F79: 1639 fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x3B003F79: fld dword ptr [ebp - 0x24] */ 1640 eax = ecx + ecx * 4; /* 0x3B003F7C: lea eax, [ecx + ecx*4] */ 1641 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ebp + eax * 4 + (-0x4C))); /* 0x3B003F7F: fcomp dword ptr [ebp + eax*4 - 0x4c] */ 1642 fp_pop(); 1643 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B003F83: fnstsw ax */ 1644 /* test HI8(eax), 0x41u */ /* 0x3B003F85: test ah, 0x41 */ 1645 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24; 1646 _cf = 0; 1647 _flag_k = FK_NARROW(FK_TEST, 24); 1648 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B003F8F; /* 0x3B003F88: jne 0x3b003f8f */ 1649 L_3B003F8A: 1650 ecx = 2; /* 0x3B003F8A: mov ecx, 2 */ 1651 L_3B003F8F: 1652 eax = ecx; /* 0x3B003F8F: mov eax, ecx */ 1653 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0); 1654 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 1655 eax = eax - 0; /* 0x3B003F91: sub eax, 0 */ 1656 _flag_k = FK_CMP; 1657 if (/* sub result */ CMP_EQ(_flag_a, _flag_b)) goto L_3B00401C; /* 0x3B003F94: je 0x3b00401c */ 1658 L_3B003F9A: 1659 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1); 1660 eax = eax - 1; /* 0x3B003F9A: dec eax */ 1661 _flag_k = FK_DEC; 1662 if (/* dec result */ CMP_EQ(_flag_a, _flag_b)) goto L_3B003FE0; /* 0x3B003F9B: je 0x3b003fe0 */ 1663 L_3B003F9D: 1664 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1); 1665 eax = eax - 1; /* 0x3B003F9D: dec eax */ 1666 _flag_k = FK_DEC; 1667 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B00405A; /* 0x3B003F9E: jne 0x3b00405a */ 1668 L_3B003FA4: 1669 fp_push(*(float*)&MEM32(ebp + (-0x38))); /* 0x3B003FA4: fld dword ptr [ebp - 0x38] */ 1670 _st[0] += (double)*(float*)ADDR(ebp + (-0x4C)); /* 0x3B003FA7: fadd dword ptr [ebp - 0x4c] */ 1671 _st[0] = (double)*(float*)ADDR(ebp + (-0x24)) - _st[0]; /* 0x3B003FAA: fsubr dword ptr [ebp - 0x24] */ 1672 _st[0] += (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3B003FAD: fadd dword ptr [ebp - 0x10] */ 1673 _st[0] = sqrt(_st[0]); /* 0x3B003FB0: fsqrt */ 1674 fp_push(_st[0]); /* 0x3B003FB2: fld st(0) */ 1675 _st[0] *= (double)*(float*)ADDR(0x3B006058); /* 0x3B003FB4: fmul dword ptr [0x3b006058] */ 1676 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0x8) = _v; } /* 0x3B003FBA: fstp dword ptr [ebx + 8] */ 1677 _st[0] = (double)*(float*)ADDR(0x3B006058) / _st[0]; /* 0x3B003FBD: fdivr dword ptr [0x3b006058] */ 1678 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x3B003FC3: fld dword ptr [ebp - 0x2c] */ 1679 _st[0] += (double)*(float*)ADDR(ebp + (-0x44)); /* 0x3B003FC6: fadd dword ptr [ebp - 0x44] */ 1680 _st[0] *= _st[1]; /* 0x3B003FC9: fmul st(1) */ 1681 { float _v = (float)fp_pop(); *(float*)ADDR(ebx) = _v; } /* 0x3B003FCB: fstp dword ptr [ebx] */ 1682 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x3B003FCD: fld dword ptr [ebp - 0x34] */ 1683 _st[0] += (double)*(float*)ADDR(ebp + (-0x28)); /* 0x3B003FD0: fadd dword ptr [ebp - 0x28] */ 1684 _st[0] *= _st[1]; /* 0x3B003FD3: fmul st(1) */ 1685 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0x4) = _v; } /* 0x3B003FD5: fstp dword ptr [ebx + 4] */ 1686 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x3B003FD8: fld dword ptr [ebp - 0x3c] */ 1687 _st[0] -= (double)*(float*)ADDR(ebp + (-0x48)); /* 0x3B003FDB: fsub dword ptr [ebp - 0x48] */ 1688 goto L_3B004053; /* 0x3B003FDE: jmp 0x3b004053 */ 1689 L_3B003FE0: 1690 fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x3B003FE0: fld dword ptr [ebp - 0x24] */ 1691 _st[0] += (double)*(float*)ADDR(ebp + (-0x4C)); /* 0x3B003FE3: fadd dword ptr [ebp - 0x4c] */ 1692 _st[0] = (double)*(float*)ADDR(ebp + (-0x38)) - _st[0]; /* 0x3B003FE6: fsubr dword ptr [ebp - 0x38] */ 1693 _st[0] += (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3B003FE9: fadd dword ptr [ebp - 0x10] */ 1694 _st[0] = sqrt(_st[0]); /* 0x3B003FEC: fsqrt */ 1695 fp_push(_st[0]); /* 0x3B003FEE: fld st(0) */ 1696 _st[0] *= (double)*(float*)ADDR(0x3B006058); /* 0x3B003FF0: fmul dword ptr [0x3b006058] */ 1697 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0x4) = _v; } /* 0x3B003FF6: fstp dword ptr [ebx + 4] */ 1698 _st[0] = (double)*(float*)ADDR(0x3B006058) / _st[0]; /* 0x3B003FF9: fdivr dword ptr [0x3b006058] */ 1699 fp_push(*(float*)&MEM32(ebp + (-0x34))); /* 0x3B003FFF: fld dword ptr [ebp - 0x34] */ 1700 _st[0] += (double)*(float*)ADDR(ebp + (-0x28)); /* 0x3B004002: fadd dword ptr [ebp - 0x28] */ 1701 _st[0] *= _st[1]; /* 0x3B004005: fmul st(1) */ 1702 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0x8) = _v; } /* 0x3B004007: fstp dword ptr [ebx + 8] */ 1703 fp_push(*(float*)&MEM32(ebp + (-0x48))); /* 0x3B00400A: fld dword ptr [ebp - 0x48] */ 1704 _st[0] += (double)*(float*)ADDR(ebp + (-0x3C)); /* 0x3B00400D: fadd dword ptr [ebp - 0x3c] */ 1705 _st[0] *= _st[1]; /* 0x3B004010: fmul st(1) */ 1706 { float _v = (float)fp_pop(); *(float*)ADDR(ebx) = _v; } /* 0x3B004012: fstp dword ptr [ebx] */ 1707 fp_push(*(float*)&MEM32(ebp + (-0x44))); /* 0x3B004014: fld dword ptr [ebp - 0x44] */ 1708 _st[0] -= (double)*(float*)ADDR(ebp + (-0x2C)); /* 0x3B004017: fsub dword ptr [ebp - 0x2c] */ 1709 goto L_3B004053; /* 0x3B00401A: jmp 0x3b004053 */ 1710 L_3B00401C: 1711 fp_push(*(float*)&MEM32(ebp + (-0x4C))); /* 0x3B00401C: fld dword ptr [ebp - 0x4c] */ 1712 _st[0] -= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B00401F: fsub dword ptr [ebp + 8] */ 1713 _st[0] += (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3B004022: fadd dword ptr [ebp - 0x10] */ 1714 _st[0] = sqrt(_st[0]); /* 0x3B004025: fsqrt */ 1715 fp_push(_st[0]); /* 0x3B004027: fld st(0) */ 1716 _st[0] *= (double)*(float*)ADDR(0x3B006058); /* 0x3B004029: fmul dword ptr [0x3b006058] */ 1717 { float _v = (float)fp_pop(); *(float*)ADDR(ebx) = _v; } /* 0x3B00402F: fstp dword ptr [ebx] */ 1718 _st[0] = (double)*(float*)ADDR(0x3B006058) / _st[0]; /* 0x3B004031: fdivr dword ptr [0x3b006058] */ 1719 fp_push(*(float*)&MEM32(ebp + (-0x48))); /* 0x3B004037: fld dword ptr [ebp - 0x48] */ 1720 _st[0] += (double)*(float*)ADDR(ebp + (-0x3C)); /* 0x3B00403A: fadd dword ptr [ebp - 0x3c] */ 1721 _st[0] *= _st[1]; /* 0x3B00403D: fmul st(1) */ 1722 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0x4) = _v; } /* 0x3B00403F: fstp dword ptr [ebx + 4] */ 1723 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x3B004042: fld dword ptr [ebp - 0x2c] */ 1724 _st[0] += (double)*(float*)ADDR(ebp + (-0x44)); /* 0x3B004045: fadd dword ptr [ebp - 0x44] */ 1725 _st[0] *= _st[1]; /* 0x3B004048: fmul st(1) */ 1726 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0x8) = _v; } /* 0x3B00404A: fstp dword ptr [ebx + 8] */ 1727 fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x3B00404D: fld dword ptr [ebp - 0x28] */ 1728 _st[0] -= (double)*(float*)ADDR(ebp + (-0x34)); /* 0x3B004050: fsub dword ptr [ebp - 0x34] */ 1729 L_3B004053: 1730 _st[0] *= _st[1]; /* 0x3B004053: fmul st(1) */ 1731 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0xC) = _v; } /* 0x3B004055: fstp dword ptr [ebx + 0xc] */ 1732 L_3B004058: 1733 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004058: fstp st(0) */ 1734 L_3B00405A: 1735 PUSH32(esp, ebx); /* 0x3B00405A: push ebx */ 1736 ecx = ebp + (-0x8C); /* 0x3B00405B: lea ecx, [ebp - 0x8c] */ 1737 RECOMP_ICALL(0x3B004270u); /* 0x3B004061: call 0x3b004270 */ /* not lifted */ 1738 RECOMP_FLAGS_IN(); 1739 ecx = MEM32(ebp + (-0xC)); /* 0x3B004066: mov ecx, dword ptr [ebp - 0xc] */ 1740 edi = POP32_VAL(esp); /* 0x3B004069: pop edi */ 1741 eax = ebx; /* 0x3B00406A: mov eax, ebx */ 1742 esi = POP32_VAL(esp); /* 0x3B00406C: pop esi */ 1743 ebx = POP32_VAL(esp); /* 0x3B00406D: pop ebx */ 1744 MEM32(FS_BASE + (0)) = ecx; /* 0x3B00406E: mov dword ptr fs:[0], ecx */ 1745 esp = ebp; /* 0x3B004075: mov esp, ebp */ 1746 ebp = POP32_VAL(esp); /* 0x3B004077: pop ebp */ 1747 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004078: ret 4 */ 1748 RECOMP_REGS_OUT(); 1749 } 1750 1751 void sub_3B004058(void) { 1752 int _fpu_cmp = 0; 1753 uint32_t _cf = 0; 1754 int _df = 1; 1755 uint32_t _flag_k = FK_NONE; 1756 uint32_t _flag_a = 0, _flag_b = 0; 1757 uint32_t _itail_tgt = 0; 1758 RECOMP_REGS_LOCALS 1759 RECOMP_ENTER(0x3B004058u); 1760 1761 L_3B004058: 1762 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004058: fstp st(0) */ 1763 PUSH32(esp, ebx); /* 0x3B00405A: push ebx */ 1764 ecx = ebp + (-0x8C); /* 0x3B00405B: lea ecx, [ebp - 0x8c] */ 1765 RECOMP_ICALL(0x3B004270u); /* 0x3B004061: call 0x3b004270 */ /* not lifted */ 1766 RECOMP_FLAGS_IN(); 1767 ecx = MEM32(ebp + (-0xC)); /* 0x3B004066: mov ecx, dword ptr [ebp - 0xc] */ 1768 edi = POP32_VAL(esp); /* 0x3B004069: pop edi */ 1769 eax = ebx; /* 0x3B00406A: mov eax, ebx */ 1770 esi = POP32_VAL(esp); /* 0x3B00406C: pop esi */ 1771 ebx = POP32_VAL(esp); /* 0x3B00406D: pop ebx */ 1772 MEM32(FS_BASE + (0)) = ecx; /* 0x3B00406E: mov dword ptr fs:[0], ecx */ 1773 esp = ebp; /* 0x3B004075: mov esp, ebp */ 1774 ebp = POP32_VAL(esp); /* 0x3B004077: pop ebp */ 1775 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004078: ret 4 */ 1776 RECOMP_REGS_OUT(); 1777 } 1778 1779 void sub_3B004080(void) { 1780 int _fpu_cmp = 0; 1781 uint32_t _cf = 0; 1782 int _df = 1; 1783 uint32_t _flag_k = FK_NONE; 1784 uint32_t _flag_a = 0, _flag_b = 0; 1785 uint32_t _itail_tgt = 0; 1786 RECOMP_REGS_LOCALS 1787 RECOMP_ENTER(0x3B004080u); 1788 1789 L_3B004080: 1790 PUSH32(esp, ebp); /* 0x3B004080: push ebp */ 1791 ebp = esp; /* 0x3B004081: mov ebp, esp */ 1792 PUSH32(esp, ebx); /* 0x3B004083: push ebx */ 1793 PUSH32(esp, esi); /* 0x3B004084: push esi */ 1794 esi = MEM32(ebp + 0x8); /* 0x3B004085: mov esi, dword ptr [ebp + 8] */ 1795 PUSH32(esp, edi); /* 0x3B004088: push edi */ 1796 edi = MEM32(ebp + 0xC); /* 0x3B004089: mov edi, dword ptr [ebp + 0xc] */ 1797 ebx = ecx; /* 0x3B00408C: mov ebx, ecx */ 1798 fp_push(*(float*)&MEM32(esi + 0x8)); /* 0x3B00408E: fld dword ptr [esi + 8] */ 1799 _st[0] *= (double)*(float*)ADDR(edi + 0x8); /* 0x3B004091: fmul dword ptr [edi + 8] */ 1800 fp_push(*(float*)&MEM32(esi + 0x4)); /* 0x3B004094: fld dword ptr [esi + 4] */ 1801 _st[0] *= (double)*(float*)ADDR(edi + 0x4); /* 0x3B004097: fmul dword ptr [edi + 4] */ 1802 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00409A: faddp st(1) */ 1803 fp_push(*(float*)&MEM32(edi + 0xC)); /* 0x3B00409C: fld dword ptr [edi + 0xc] */ 1804 _st[0] *= (double)*(float*)ADDR(esi + 0xC); /* 0x3B00409F: fmul dword ptr [esi + 0xc] */ 1805 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0040A2: faddp st(1) */ 1806 fp_push(*(float*)&MEM32(esi)); /* 0x3B0040A4: fld dword ptr [esi] */ 1807 _st[0] *= (double)*(float*)ADDR(edi); /* 0x3B0040A6: fmul dword ptr [edi] */ 1808 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0040A8: faddp st(1) */ 1809 { float _v = (float)_st[0]; *(float*)ADDR(ebp + 0xC) = _v; } /* 0x3B0040AA: fst dword ptr [ebp + 0xc] */ 1810 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3B006070)); /* 0x3B0040AD: fcomp qword ptr [0x3b006070] */ 1811 fp_pop(); 1812 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0040B3: fnstsw ax */ 1813 /* test HI8(eax), 1 */ /* 0x3B0040B5: test ah, 1 */ 1814 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 1815 _cf = 0; 1816 _flag_k = FK_NARROW(FK_TEST, 24); 1817 if (TEST_Z(_flag_a, _flag_b)) goto L_3B0040C8; /* 0x3B0040B8: je 0x3b0040c8 */ 1818 L_3B0040BA: 1819 fp_push(*(float*)&MEM32(ebp + 0xC)); /* 0x3B0040BA: fld dword ptr [ebp + 0xc] */ 1820 _st[0] = -_st[0]; /* 0x3B0040BD: fchs */ 1821 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0xC) = _v; } /* 0x3B0040BF: fstp dword ptr [ebp + 0xc] */ 1822 MEM8(ebp + 0xB) = (uint8_t)(1); /* 0x3B0040C2: mov byte ptr [ebp + 0xb], 1 */ 1823 goto L_3B0040CC; /* 0x3B0040C6: jmp 0x3b0040cc */ 1824 L_3B0040C8: 1825 MEM8(ebp + 0xB) = (uint8_t)(0); /* 0x3B0040C8: mov byte ptr [ebp + 0xb], 0 */ 1826 L_3B0040CC: 1827 fp_push(*(float*)&MEM32(0x3B006048)); /* 0x3B0040CC: fld dword ptr [0x3b006048] */ 1828 _st[0] -= (double)*(float*)ADDR(ebp + 0xC); /* 0x3B0040D2: fsub dword ptr [ebp + 0xc] */ 1829 _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3B006078)); /* 0x3B0040D5: fcomp qword ptr [0x3b006078] */ 1830 fp_pop(); 1831 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0040DB: fnstsw ax */ 1832 /* test HI8(eax), 1 */ /* 0x3B0040DD: test ah, 1 */ 1833 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24; 1834 _cf = 0; 1835 _flag_k = FK_NARROW(FK_TEST, 24); 1836 if (TEST_Z(_flag_a, _flag_b)) goto L_3B0040ED; /* 0x3B0040E0: je 0x3b0040ed */ 1837 L_3B0040E2: 1838 fp_push(*(float*)&MEM32(0x3B006048)); /* 0x3B0040E2: fld dword ptr [0x3b006048] */ 1839 _st[0] -= (double)*(float*)ADDR(ebp + 0x10); /* 0x3B0040E8: fsub dword ptr [ebp + 0x10] */ 1840 goto L_3B00411D; /* 0x3B0040EB: jmp 0x3b00411d */ 1841 L_3B0040ED: 1842 fp_push(*(float*)&MEM32(ebp + 0xC)); /* 0x3B0040ED: fld dword ptr [ebp + 0xc] */ 1843 RECOMP_ICALL(0x3B0050B0u); /* 0x3B0040F0: call 0x3b0050b0 */ /* not lifted */ 1844 RECOMP_FLAGS_IN(); 1845 fp_push(_st[0]); /* 0x3B0040F5: fld st(0) */ 1846 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B0040F7: fsin */ 1847 _st[0] = (double)*(float*)ADDR(0x3B006048) / _st[0]; /* 0x3B0040F9: fdivr dword ptr [0x3b006048] */ 1848 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0xC) = _v; } /* 0x3B0040FF: fstp dword ptr [ebp + 0xc] */ 1849 fp_push(_st[0]); /* 0x3B004102: fld st(0) */ 1850 _st[0] *= (double)*(float*)ADDR(ebp + 0x10); /* 0x3B004104: fmul dword ptr [ebp + 0x10] */ 1851 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x10) = _v; } /* 0x3B004107: fstp dword ptr [ebp + 0x10] */ 1852 _st[0] -= (double)*(float*)ADDR(ebp + 0x10); /* 0x3B00410A: fsub dword ptr [ebp + 0x10] */ 1853 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B00410D: fsin */ 1854 _st[0] *= (double)*(float*)ADDR(ebp + 0xC); /* 0x3B00410F: fmul dword ptr [ebp + 0xc] */ 1855 fp_push(*(float*)&MEM32(ebp + 0x10)); /* 0x3B004112: fld dword ptr [ebp + 0x10] */ 1856 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B004115: fsin */ 1857 _st[0] *= (double)*(float*)ADDR(ebp + 0xC); /* 0x3B004117: fmul dword ptr [ebp + 0xc] */ 1858 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x10) = _v; } /* 0x3B00411A: fstp dword ptr [ebp + 0x10] */ 1859 L_3B00411D: 1860 SET_LO8(eax, MEM8(ebp + 0xB)); /* 0x3B00411D: mov al, byte ptr [ebp + 0xb] */ 1861 fp_push(*(float*)&MEM32(ebp + 0x10)); /* 0x3B004120: fld dword ptr [ebp + 0x10] */ 1862 /* test LO8(eax), LO8(eax) */ /* 0x3B004123: test al, al */ 1863 _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24; 1864 _cf = 0; 1865 _flag_k = FK_NARROW(FK_TEST, 24); 1866 if (TEST_Z(_flag_a, _flag_b)) goto L_3B004129; /* 0x3B004125: je 0x3b004129 */ 1867 L_3B004127: 1868 _st[0] = -_st[0]; /* 0x3B004127: fchs */ 1869 L_3B004129: 1870 fp_push(_st[1]); /* 0x3B004129: fld st(1) */ 1871 _st[0] *= (double)*(float*)ADDR(esi); /* 0x3B00412B: fmul dword ptr [esi] */ 1872 fp_push(_st[1]); /* 0x3B00412D: fld st(1) */ 1873 _st[0] *= (double)*(float*)ADDR(edi); /* 0x3B00412F: fmul dword ptr [edi] */ 1874 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004131: faddp st(1) */ 1875 { float _v = (float)fp_pop(); *(float*)ADDR(ebx) = _v; } /* 0x3B004133: fstp dword ptr [ebx] */ 1876 fp_push(_st[1]); /* 0x3B004135: fld st(1) */ 1877 _st[0] *= (double)*(float*)ADDR(esi + 0x4); /* 0x3B004137: fmul dword ptr [esi + 4] */ 1878 fp_push(_st[1]); /* 0x3B00413A: fld st(1) */ 1879 _st[0] *= (double)*(float*)ADDR(edi + 0x4); /* 0x3B00413C: fmul dword ptr [edi + 4] */ 1880 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00413F: faddp st(1) */ 1881 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0x4) = _v; } /* 0x3B004141: fstp dword ptr [ebx + 4] */ 1882 fp_push(_st[1]); /* 0x3B004144: fld st(1) */ 1883 _st[0] *= (double)*(float*)ADDR(esi + 0x8); /* 0x3B004146: fmul dword ptr [esi + 8] */ 1884 fp_push(_st[1]); /* 0x3B004149: fld st(1) */ 1885 _st[0] *= (double)*(float*)ADDR(edi + 0x8); /* 0x3B00414B: fmul dword ptr [edi + 8] */ 1886 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00414E: faddp st(1) */ 1887 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0x8) = _v; } /* 0x3B004150: fstp dword ptr [ebx + 8] */ 1888 _st[0] *= (double)*(float*)ADDR(edi + 0xC); /* 0x3B004153: fmul dword ptr [edi + 0xc] */ 1889 fp_xch(1); /* 0x3B004156: fxch st(1) */ 1890 _st[0] *= (double)*(float*)ADDR(esi + 0xC); /* 0x3B004158: fmul dword ptr [esi + 0xc] */ 1891 edi = POP32_VAL(esp); /* 0x3B00415B: pop edi */ 1892 esi = POP32_VAL(esp); /* 0x3B00415C: pop esi */ 1893 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00415D: faddp st(1) */ 1894 { float _v = (float)fp_pop(); *(float*)ADDR(ebx + 0xC) = _v; } /* 0x3B00415F: fstp dword ptr [ebx + 0xc] */ 1895 ebx = POP32_VAL(esp); /* 0x3B004162: pop ebx */ 1896 ebp = POP32_VAL(esp); /* 0x3B004163: pop ebp */ 1897 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3B004164: ret 0xc */ 1898 RECOMP_REGS_OUT(); 1899 } 1900 1901 void sub_3B004170(void) { 1902 int _fpu_cmp = 0; 1903 uint32_t _cf = 0; 1904 int _df = 1; 1905 uint32_t _flag_k = FK_NONE; 1906 uint32_t _flag_a = 0, _flag_b = 0; 1907 uint32_t _itail_tgt = 0; 1908 RECOMP_REGS_LOCALS 1909 RECOMP_ENTER(0x3B004170u); 1910 1911 L_3B004170: 1912 RECOMP_ICALL(0x3B004180u); /* 0x3B004170: call 0x3b004180 */ /* not lifted */ 1913 RECOMP_FLAGS_IN(); 1914 goto L_3B004190; /* 0x3B004175: jmp 0x3b004190 */ 1915 L_3B004190: 1916 PUSH32(esp, 0x3B0041A0u); /* 0x3B004190: push 0x3b0041a0 */ 1917 RECOMP_ICALL(0x3B0050E8u); /* 0x3B004195: call 0x3b0050e8 */ /* not lifted */ 1918 RECOMP_FLAGS_IN(); 1919 ecx = POP32_VAL(esp); /* 0x3B00419A: pop ecx */ 1920 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00419B: ret */ 1921 RECOMP_REGS_OUT(); 1922 } 1923 1924 void sub_3B004180(void) { 1925 int _fpu_cmp = 0; 1926 uint32_t _cf = 0; 1927 int _df = 1; 1928 uint32_t _flag_k = FK_NONE; 1929 uint32_t _flag_a = 0, _flag_b = 0; 1930 uint32_t _itail_tgt = 0; 1931 RECOMP_REGS_LOCALS 1932 RECOMP_ENTER(0x3B004180u); 1933 1934 L_3B004180: 1935 ecx = 0x3B008049u; /* 0x3B004180: mov ecx, 0x3b008049 */ 1936 L_3B004185: 1937 { _itail_tgt = (uint32_t)(MEM32(0x3B006014)); goto _ljump; } 1938 { RECOMP_REGS_OUT(); return; } /* end of function */ 1939 _ljump: 1940 switch (_itail_tgt) { 1941 case 0x3B004180u: goto L_3B004180; 1942 case 0x3B004185u: goto L_3B004185; 1943 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 1944 } 1945 RECOMP_REGS_OUT(); 1946 } 1947 1948 void sub_3B004190(void) { 1949 int _fpu_cmp = 0; 1950 uint32_t _cf = 0; 1951 int _df = 1; 1952 uint32_t _flag_k = FK_NONE; 1953 uint32_t _flag_a = 0, _flag_b = 0; 1954 uint32_t _itail_tgt = 0; 1955 RECOMP_REGS_LOCALS 1956 RECOMP_ENTER(0x3B004190u); 1957 1958 L_3B004190: 1959 PUSH32(esp, 0x3B0041A0u); /* 0x3B004190: push 0x3b0041a0 */ 1960 RECOMP_ICALL(0x3B0050E8u); /* 0x3B004195: call 0x3b0050e8 */ /* not lifted */ 1961 RECOMP_FLAGS_IN(); 1962 ecx = POP32_VAL(esp); /* 0x3B00419A: pop ecx */ 1963 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00419B: ret */ 1964 RECOMP_REGS_OUT(); 1965 } 1966 1967 void sub_3B0041A0(void) { 1968 int _fpu_cmp = 0; 1969 uint32_t _cf = 0; 1970 int _df = 1; 1971 uint32_t _flag_k = FK_NONE; 1972 uint32_t _flag_a = 0, _flag_b = 0; 1973 uint32_t _itail_tgt = 0; 1974 RECOMP_REGS_LOCALS 1975 RECOMP_ENTER(0x3B0041A0u); 1976 1977 L_3B0041A0: 1978 ecx = 0x3B008049u; /* 0x3B0041A0: mov ecx, 0x3b008049 */ 1979 L_3B0041A5: 1980 { _itail_tgt = (uint32_t)(MEM32(0x3B006008)); goto _ljump; } 1981 { RECOMP_REGS_OUT(); return; } /* end of function */ 1982 _ljump: 1983 switch (_itail_tgt) { 1984 case 0x3B0041A0u: goto L_3B0041A0; 1985 case 0x3B0041A5u: goto L_3B0041A5; 1986 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 1987 } 1988 RECOMP_REGS_OUT(); 1989 } 1990 1991 void sub_3B0041B0(void) { 1992 int _fpu_cmp = 0; 1993 uint32_t _cf = 0; 1994 int _df = 1; 1995 uint32_t _flag_k = FK_NONE; 1996 uint32_t _flag_a = 0, _flag_b = 0; 1997 uint32_t _itail_tgt = 0; 1998 RECOMP_REGS_LOCALS 1999 RECOMP_ENTER(0x3B0041B0u); 2000 2001 L_3B0041B0: 2002 RECOMP_ICALL(0x3B0041C0u); /* 0x3B0041B0: call 0x3b0041c0 */ /* not lifted */ 2003 RECOMP_FLAGS_IN(); 2004 goto L_3B0041D0; /* 0x3B0041B5: jmp 0x3b0041d0 */ 2005 L_3B0041D0: 2006 PUSH32(esp, 0x3B0041E0u); /* 0x3B0041D0: push 0x3b0041e0 */ 2007 RECOMP_ICALL(0x3B0050E8u); /* 0x3B0041D5: call 0x3b0050e8 */ /* not lifted */ 2008 RECOMP_FLAGS_IN(); 2009 ecx = POP32_VAL(esp); /* 0x3B0041DA: pop ecx */ 2010 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0041DB: ret */ 2011 RECOMP_REGS_OUT(); 2012 } 2013 2014 void sub_3B0041C0(void) { 2015 int _fpu_cmp = 0; 2016 uint32_t _cf = 0; 2017 int _df = 1; 2018 uint32_t _flag_k = FK_NONE; 2019 uint32_t _flag_a = 0, _flag_b = 0; 2020 uint32_t _itail_tgt = 0; 2021 RECOMP_REGS_LOCALS 2022 RECOMP_ENTER(0x3B0041C0u); 2023 2024 L_3B0041C0: 2025 ecx = 0x3B008048u; /* 0x3B0041C0: mov ecx, 0x3b008048 */ 2026 L_3B0041C5: 2027 { _itail_tgt = (uint32_t)(MEM32(0x3B00600C)); goto _ljump; } 2028 { RECOMP_REGS_OUT(); return; } /* end of function */ 2029 _ljump: 2030 switch (_itail_tgt) { 2031 case 0x3B0041C0u: goto L_3B0041C0; 2032 case 0x3B0041C5u: goto L_3B0041C5; 2033 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 2034 } 2035 RECOMP_REGS_OUT(); 2036 } 2037 2038 void sub_3B0041D0(void) { 2039 int _fpu_cmp = 0; 2040 uint32_t _cf = 0; 2041 int _df = 1; 2042 uint32_t _flag_k = FK_NONE; 2043 uint32_t _flag_a = 0, _flag_b = 0; 2044 uint32_t _itail_tgt = 0; 2045 RECOMP_REGS_LOCALS 2046 RECOMP_ENTER(0x3B0041D0u); 2047 2048 L_3B0041D0: 2049 PUSH32(esp, 0x3B0041E0u); /* 0x3B0041D0: push 0x3b0041e0 */ 2050 RECOMP_ICALL(0x3B0050E8u); /* 0x3B0041D5: call 0x3b0050e8 */ /* not lifted */ 2051 RECOMP_FLAGS_IN(); 2052 ecx = POP32_VAL(esp); /* 0x3B0041DA: pop ecx */ 2053 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0041DB: ret */ 2054 RECOMP_REGS_OUT(); 2055 } 2056 2057 void sub_3B0041E0(void) { 2058 int _fpu_cmp = 0; 2059 uint32_t _cf = 0; 2060 int _df = 1; 2061 uint32_t _flag_k = FK_NONE; 2062 uint32_t _flag_a = 0, _flag_b = 0; 2063 uint32_t _itail_tgt = 0; 2064 RECOMP_REGS_LOCALS 2065 RECOMP_ENTER(0x3B0041E0u); 2066 2067 L_3B0041E0: 2068 ecx = 0x3B008048u; /* 0x3B0041E0: mov ecx, 0x3b008048 */ 2069 L_3B0041E5: 2070 { _itail_tgt = (uint32_t)(MEM32(0x3B006010)); goto _ljump; } 2071 { RECOMP_REGS_OUT(); return; } /* end of function */ 2072 _ljump: 2073 switch (_itail_tgt) { 2074 case 0x3B0041E0u: goto L_3B0041E0; 2075 case 0x3B0041E5u: goto L_3B0041E5; 2076 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 2077 } 2078 RECOMP_REGS_OUT(); 2079 } 2080 2081 void sub_3B0041F0(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(0x3B0041F0u); 2090 2091 L_3B0041F0: 2092 RECOMP_ICALL(0x3B004200u); /* 0x3B0041F0: call 0x3b004200 */ /* not lifted */ 2093 RECOMP_FLAGS_IN(); 2094 goto L_3B004210; /* 0x3B0041F5: jmp 0x3b004210 */ 2095 L_3B004210: 2096 PUSH32(esp, 0x3B004220u); /* 0x3B004210: push 0x3b004220 */ 2097 RECOMP_ICALL(0x3B0050E8u); /* 0x3B004215: call 0x3b0050e8 */ /* not lifted */ 2098 RECOMP_FLAGS_IN(); 2099 ecx = POP32_VAL(esp); /* 0x3B00421A: pop ecx */ 2100 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00421B: ret */ 2101 RECOMP_REGS_OUT(); 2102 } 2103 2104 void sub_3B004200(void) { 2105 int _fpu_cmp = 0; 2106 uint32_t _cf = 0; 2107 int _df = 1; 2108 uint32_t _flag_k = FK_NONE; 2109 uint32_t _flag_a = 0, _flag_b = 0; 2110 uint32_t _itail_tgt = 0; 2111 RECOMP_REGS_LOCALS 2112 RECOMP_ENTER(0x3B004200u); 2113 2114 L_3B004200: 2115 ecx = 0x3B00804Du; /* 0x3B004200: mov ecx, 0x3b00804d */ 2116 L_3B004205: 2117 { _itail_tgt = (uint32_t)(MEM32(0x3B006014)); goto _ljump; } 2118 { RECOMP_REGS_OUT(); return; } /* end of function */ 2119 _ljump: 2120 switch (_itail_tgt) { 2121 case 0x3B004200u: goto L_3B004200; 2122 case 0x3B004205u: goto L_3B004205; 2123 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 2124 } 2125 RECOMP_REGS_OUT(); 2126 } 2127 2128 void sub_3B004210(void) { 2129 int _fpu_cmp = 0; 2130 uint32_t _cf = 0; 2131 int _df = 1; 2132 uint32_t _flag_k = FK_NONE; 2133 uint32_t _flag_a = 0, _flag_b = 0; 2134 uint32_t _itail_tgt = 0; 2135 RECOMP_REGS_LOCALS 2136 RECOMP_ENTER(0x3B004210u); 2137 2138 L_3B004210: 2139 PUSH32(esp, 0x3B004220u); /* 0x3B004210: push 0x3b004220 */ 2140 RECOMP_ICALL(0x3B0050E8u); /* 0x3B004215: call 0x3b0050e8 */ /* not lifted */ 2141 RECOMP_FLAGS_IN(); 2142 ecx = POP32_VAL(esp); /* 0x3B00421A: pop ecx */ 2143 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00421B: ret */ 2144 RECOMP_REGS_OUT(); 2145 } 2146 2147 void sub_3B004220(void) { 2148 int _fpu_cmp = 0; 2149 uint32_t _cf = 0; 2150 int _df = 1; 2151 uint32_t _flag_k = FK_NONE; 2152 uint32_t _flag_a = 0, _flag_b = 0; 2153 uint32_t _itail_tgt = 0; 2154 RECOMP_REGS_LOCALS 2155 RECOMP_ENTER(0x3B004220u); 2156 2157 L_3B004220: 2158 ecx = 0x3B00804Du; /* 0x3B004220: mov ecx, 0x3b00804d */ 2159 L_3B004225: 2160 { _itail_tgt = (uint32_t)(MEM32(0x3B006008)); goto _ljump; } 2161 { RECOMP_REGS_OUT(); return; } /* end of function */ 2162 _ljump: 2163 switch (_itail_tgt) { 2164 case 0x3B004220u: goto L_3B004220; 2165 case 0x3B004225u: goto L_3B004225; 2166 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 2167 } 2168 RECOMP_REGS_OUT(); 2169 } 2170 2171 void sub_3B004230(void) { 2172 int _fpu_cmp = 0; 2173 uint32_t _cf = 0; 2174 int _df = 1; 2175 uint32_t _flag_k = FK_NONE; 2176 uint32_t _flag_a = 0, _flag_b = 0; 2177 uint32_t _itail_tgt = 0; 2178 RECOMP_REGS_LOCALS 2179 RECOMP_ENTER(0x3B004230u); 2180 2181 L_3B004230: 2182 RECOMP_ICALL(0x3B004240u); /* 0x3B004230: call 0x3b004240 */ /* not lifted */ 2183 RECOMP_FLAGS_IN(); 2184 goto L_3B004250; /* 0x3B004235: jmp 0x3b004250 */ 2185 L_3B004250: 2186 PUSH32(esp, 0x3B004260u); /* 0x3B004250: push 0x3b004260 */ 2187 RECOMP_ICALL(0x3B0050E8u); /* 0x3B004255: call 0x3b0050e8 */ /* not lifted */ 2188 RECOMP_FLAGS_IN(); 2189 ecx = POP32_VAL(esp); /* 0x3B00425A: pop ecx */ 2190 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00425B: ret */ 2191 RECOMP_REGS_OUT(); 2192 } 2193 2194 void sub_3B004240(void) { 2195 int _fpu_cmp = 0; 2196 uint32_t _cf = 0; 2197 int _df = 1; 2198 uint32_t _flag_k = FK_NONE; 2199 uint32_t _flag_a = 0, _flag_b = 0; 2200 uint32_t _itail_tgt = 0; 2201 RECOMP_REGS_LOCALS 2202 RECOMP_ENTER(0x3B004240u); 2203 2204 L_3B004240: 2205 ecx = 0x3B00804Cu; /* 0x3B004240: mov ecx, 0x3b00804c */ 2206 L_3B004245: 2207 { _itail_tgt = (uint32_t)(MEM32(0x3B00600C)); goto _ljump; } 2208 { RECOMP_REGS_OUT(); return; } /* end of function */ 2209 _ljump: 2210 switch (_itail_tgt) { 2211 case 0x3B004240u: goto L_3B004240; 2212 case 0x3B004245u: goto L_3B004245; 2213 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 2214 } 2215 RECOMP_REGS_OUT(); 2216 } 2217 2218 void sub_3B004250(void) { 2219 int _fpu_cmp = 0; 2220 uint32_t _cf = 0; 2221 int _df = 1; 2222 uint32_t _flag_k = FK_NONE; 2223 uint32_t _flag_a = 0, _flag_b = 0; 2224 uint32_t _itail_tgt = 0; 2225 RECOMP_REGS_LOCALS 2226 RECOMP_ENTER(0x3B004250u); 2227 2228 L_3B004250: 2229 PUSH32(esp, 0x3B004260u); /* 0x3B004250: push 0x3b004260 */ 2230 RECOMP_ICALL(0x3B0050E8u); /* 0x3B004255: call 0x3b0050e8 */ /* not lifted */ 2231 RECOMP_FLAGS_IN(); 2232 ecx = POP32_VAL(esp); /* 0x3B00425A: pop ecx */ 2233 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00425B: ret */ 2234 RECOMP_REGS_OUT(); 2235 } 2236 2237 void sub_3B004260(void) { 2238 int _fpu_cmp = 0; 2239 uint32_t _cf = 0; 2240 int _df = 1; 2241 uint32_t _flag_k = FK_NONE; 2242 uint32_t _flag_a = 0, _flag_b = 0; 2243 uint32_t _itail_tgt = 0; 2244 RECOMP_REGS_LOCALS 2245 RECOMP_ENTER(0x3B004260u); 2246 2247 L_3B004260: 2248 ecx = 0x3B00804Cu; /* 0x3B004260: mov ecx, 0x3b00804c */ 2249 L_3B004265: 2250 { _itail_tgt = (uint32_t)(MEM32(0x3B006010)); goto _ljump; } 2251 { RECOMP_REGS_OUT(); return; } /* end of function */ 2252 _ljump: 2253 switch (_itail_tgt) { 2254 case 0x3B004260u: goto L_3B004260; 2255 case 0x3B004265u: goto L_3B004265; 2256 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 2257 } 2258 RECOMP_REGS_OUT(); 2259 } 2260 2261 void sub_3B004270(void) { 2262 int _fpu_cmp = 0; 2263 uint32_t _cf = 0; 2264 int _df = 1; 2265 uint32_t _flag_k = FK_NONE; 2266 uint32_t _flag_a = 0, _flag_b = 0; 2267 uint32_t _itail_tgt = 0; 2268 RECOMP_REGS_LOCALS 2269 RECOMP_ENTER(0x3B004270u); 2270 2271 L_3B004270: 2272 PUSH32(esp, ebp); /* 0x3B004270: push ebp */ 2273 ebp = esp; /* 0x3B004271: mov ebp, esp */ 2274 eax = MEM32(ebp + 0x8); /* 0x3B004273: mov eax, dword ptr [ebp + 8] */ 2275 PUSH32(esp, esi); /* 0x3B004276: push esi */ 2276 esi = ecx; /* 0x3B004277: mov esi, ecx */ 2277 PUSH32(esp, eax); /* 0x3B004279: push eax */ 2278 RECOMP_ICALL(0x3B004840u); /* 0x3B00427A: call 0x3b004840 */ /* not lifted */ 2279 RECOMP_FLAGS_IN(); 2280 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 2281 eax = 0; /* 0x3B00427F: xor eax, eax */ 2282 _cf = 0; 2283 _flag_k = FK_TEST; 2284 MEM32(esi + 0x3C) = 0x3F800000u; /* 0x3B004281: mov dword ptr [esi + 0x3c], 0x3f800000 */ 2285 MEM32(esi + 0x38) = eax; /* 0x3B004288: mov dword ptr [esi + 0x38], eax */ 2286 MEM32(esi + 0x34) = eax; /* 0x3B00428B: mov dword ptr [esi + 0x34], eax */ 2287 MEM32(esi + 0x30) = eax; /* 0x3B00428E: mov dword ptr [esi + 0x30], eax */ 2288 MEM32(esi + 0x2C) = eax; /* 0x3B004291: mov dword ptr [esi + 0x2c], eax */ 2289 MEM32(esi + 0x1C) = eax; /* 0x3B004294: mov dword ptr [esi + 0x1c], eax */ 2290 MEM32(esi + 0xC) = eax; /* 0x3B004297: mov dword ptr [esi + 0xc], eax */ 2291 eax = esi; /* 0x3B00429A: mov eax, esi */ 2292 esi = POP32_VAL(esp); /* 0x3B00429C: pop esi */ 2293 ebp = POP32_VAL(esp); /* 0x3B00429D: pop ebp */ 2294 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B00429E: ret 4 */ 2295 RECOMP_REGS_OUT(); 2296 } 2297 2298 void sub_3B0042B0(void) { 2299 int _fpu_cmp = 0; 2300 uint32_t _cf = 0; 2301 int _df = 1; 2302 uint32_t _flag_k = FK_NONE; 2303 uint32_t _flag_a = 0, _flag_b = 0; 2304 uint32_t _itail_tgt = 0; 2305 RECOMP_REGS_LOCALS 2306 RECOMP_ENTER(0x3B0042B0u); 2307 2308 L_3B0042B0: 2309 eax = ecx; /* 0x3B0042B0: mov eax, ecx */ 2310 fp_push(*(float*)&MEM32(eax + 0x10)); /* 0x3B0042B2: fld dword ptr [eax + 0x10] */ 2311 ecx = MEM32(eax + 0x4); /* 0x3B0042B5: mov ecx, dword ptr [eax + 4] */ 2312 edx = MEM32(eax + 0x8); /* 0x3B0042B8: mov edx, dword ptr [eax + 8] */ 2313 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x4) = _v; } /* 0x3B0042BB: fstp dword ptr [eax + 4] */ 2314 fp_push(*(float*)&MEM32(eax + 0x20)); /* 0x3B0042BE: fld dword ptr [eax + 0x20] */ 2315 MEM32(eax + 0x10) = ecx; /* 0x3B0042C1: mov dword ptr [eax + 0x10], ecx */ 2316 ecx = MEM32(eax + 0xC); /* 0x3B0042C4: mov ecx, dword ptr [eax + 0xc] */ 2317 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x8) = _v; } /* 0x3B0042C7: fstp dword ptr [eax + 8] */ 2318 fp_push(*(float*)&MEM32(eax + 0x30)); /* 0x3B0042CA: fld dword ptr [eax + 0x30] */ 2319 MEM32(eax + 0x20) = edx; /* 0x3B0042CD: mov dword ptr [eax + 0x20], edx */ 2320 edx = MEM32(eax + 0x18); /* 0x3B0042D0: mov edx, dword ptr [eax + 0x18] */ 2321 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0xC) = _v; } /* 0x3B0042D3: fstp dword ptr [eax + 0xc] */ 2322 fp_push(*(float*)&MEM32(eax + 0x24)); /* 0x3B0042D6: fld dword ptr [eax + 0x24] */ 2323 MEM32(eax + 0x30) = ecx; /* 0x3B0042D9: mov dword ptr [eax + 0x30], ecx */ 2324 ecx = MEM32(eax + 0x1C); /* 0x3B0042DC: mov ecx, dword ptr [eax + 0x1c] */ 2325 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x18) = _v; } /* 0x3B0042DF: fstp dword ptr [eax + 0x18] */ 2326 fp_push(*(float*)&MEM32(eax + 0x34)); /* 0x3B0042E2: fld dword ptr [eax + 0x34] */ 2327 MEM32(eax + 0x24) = edx; /* 0x3B0042E5: mov dword ptr [eax + 0x24], edx */ 2328 edx = MEM32(eax + 0x2C); /* 0x3B0042E8: mov edx, dword ptr [eax + 0x2c] */ 2329 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x1C) = _v; } /* 0x3B0042EB: fstp dword ptr [eax + 0x1c] */ 2330 fp_push(*(float*)&MEM32(eax + 0x38)); /* 0x3B0042EE: fld dword ptr [eax + 0x38] */ 2331 MEM32(eax + 0x34) = ecx; /* 0x3B0042F1: mov dword ptr [eax + 0x34], ecx */ 2332 MEM32(eax + 0x38) = edx; /* 0x3B0042F4: mov dword ptr [eax + 0x38], edx */ 2333 { float _v = (float)fp_pop(); *(float*)ADDR(eax + 0x2C) = _v; } /* 0x3B0042F7: fstp dword ptr [eax + 0x2c] */ 2334 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0042FA: ret */ 2335 RECOMP_REGS_OUT(); 2336 } 2337 2338 void sub_3B004300(void) { 2339 int _fpu_cmp = 0; 2340 uint32_t _cf = 0; 2341 int _df = 1; 2342 uint32_t _flag_k = FK_NONE; 2343 uint32_t _flag_a = 0, _flag_b = 0; 2344 uint32_t _itail_tgt = 0; 2345 RECOMP_REGS_LOCALS 2346 RECOMP_ENTER(0x3B004300u); 2347 2348 L_3B004300: 2349 PUSH32(esp, ebp); /* 0x3B004300: push ebp */ 2350 ebp = esp; /* 0x3B004301: mov ebp, esp */ 2351 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x40u); 2352 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2353 esp = esp - 0x40u; /* 0x3B004303: sub esp, 0x40 */ 2354 _flag_k = FK_CMP; 2355 edx = ecx; /* 0x3B004306: mov edx, ecx */ 2356 MEM32(ebp + (-0x34)) = 0; /* 0x3B004308: mov dword ptr [ebp - 0x34], 0 */ 2357 MEM32(ebp + (-0x24)) = 0; /* 0x3B00430F: mov dword ptr [ebp - 0x24], 0 */ 2358 MEM32(ebp + (-0x14)) = 0; /* 0x3B004316: mov dword ptr [ebp - 0x14], 0 */ 2359 fp_push(*(float*)&MEM32(edx + 0x14)); /* 0x3B00431D: fld dword ptr [edx + 0x14] */ 2360 _st[0] *= (double)*(float*)ADDR(edx + 0x28); /* 0x3B004320: fmul dword ptr [edx + 0x28] */ 2361 fp_push(*(float*)&MEM32(edx + 0x18)); /* 0x3B004323: fld dword ptr [edx + 0x18] */ 2362 _st[0] *= (double)*(float*)ADDR(edx + 0x24); /* 0x3B004326: fmul dword ptr [edx + 0x24] */ 2363 MEM32(ebp + (-0x4)) = 0x3F800000u; /* 0x3B004329: mov dword ptr [ebp - 4], 0x3f800000 */ 2364 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004330: fsubp st(1) */ 2365 fp_push(*(float*)&MEM32(edx + 0x20)); /* 0x3B004332: fld dword ptr [edx + 0x20] */ 2366 _st[0] *= (double)*(float*)ADDR(edx + 0x18); /* 0x3B004335: fmul dword ptr [edx + 0x18] */ 2367 fp_push(*(float*)&MEM32(edx + 0x28)); /* 0x3B004338: fld dword ptr [edx + 0x28] */ 2368 _st[0] *= (double)*(float*)ADDR(edx + 0x10); /* 0x3B00433B: fmul dword ptr [edx + 0x10] */ 2369 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B00433E: fsubp st(1) */ 2370 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x30)) = _v; } /* 0x3B004340: fstp dword ptr [ebp - 0x30] */ 2371 fp_push(*(float*)&MEM32(edx + 0x10)); /* 0x3B004343: fld dword ptr [edx + 0x10] */ 2372 _st[0] *= (double)*(float*)ADDR(edx + 0x24); /* 0x3B004346: fmul dword ptr [edx + 0x24] */ 2373 fp_push(*(float*)&MEM32(edx + 0x14)); /* 0x3B004349: fld dword ptr [edx + 0x14] */ 2374 _st[0] *= (double)*(float*)ADDR(edx + 0x20); /* 0x3B00434C: fmul dword ptr [edx + 0x20] */ 2375 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B00434F: fsubp st(1) */ 2376 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x3B004351: fstp dword ptr [ebp - 0x20] */ 2377 fp_push(*(float*)&MEM32(edx + 0x24)); /* 0x3B004354: fld dword ptr [edx + 0x24] */ 2378 _st[0] *= (double)*(float*)ADDR(edx + 0x8); /* 0x3B004357: fmul dword ptr [edx + 8] */ 2379 fp_push(*(float*)&MEM32(edx + 0x28)); /* 0x3B00435A: fld dword ptr [edx + 0x28] */ 2380 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B00435D: fmul dword ptr [edx + 4] */ 2381 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004360: fsubp st(1) */ 2382 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x3C)) = _v; } /* 0x3B004362: fstp dword ptr [ebp - 0x3c] */ 2383 fp_push(*(float*)&MEM32(edx + 0x28)); /* 0x3B004365: fld dword ptr [edx + 0x28] */ 2384 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B004368: fmul dword ptr [edx] */ 2385 fp_push(*(float*)&MEM32(edx + 0x20)); /* 0x3B00436A: fld dword ptr [edx + 0x20] */ 2386 _st[0] *= (double)*(float*)ADDR(edx + 0x8); /* 0x3B00436D: fmul dword ptr [edx + 8] */ 2387 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004370: fsubp st(1) */ 2388 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x2C)) = _v; } /* 0x3B004372: fstp dword ptr [ebp - 0x2c] */ 2389 fp_push(*(float*)&MEM32(edx + 0x20)); /* 0x3B004375: fld dword ptr [edx + 0x20] */ 2390 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B004378: fmul dword ptr [edx + 4] */ 2391 fp_push(*(float*)&MEM32(edx + 0x24)); /* 0x3B00437B: fld dword ptr [edx + 0x24] */ 2392 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B00437E: fmul dword ptr [edx] */ 2393 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004380: fsubp st(1) */ 2394 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x3B004382: fstp dword ptr [ebp - 0x1c] */ 2395 fp_push(*(float*)&MEM32(edx + 0x18)); /* 0x3B004385: fld dword ptr [edx + 0x18] */ 2396 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B004388: fmul dword ptr [edx + 4] */ 2397 fp_push(*(float*)&MEM32(edx + 0x14)); /* 0x3B00438B: fld dword ptr [edx + 0x14] */ 2398 _st[0] *= (double)*(float*)ADDR(edx + 0x8); /* 0x3B00438E: fmul dword ptr [edx + 8] */ 2399 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004391: fsubp st(1) */ 2400 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x38)) = _v; } /* 0x3B004393: fstp dword ptr [ebp - 0x38] */ 2401 fp_push(*(float*)&MEM32(edx + 0x10)); /* 0x3B004396: fld dword ptr [edx + 0x10] */ 2402 _st[0] *= (double)*(float*)ADDR(edx + 0x8); /* 0x3B004399: fmul dword ptr [edx + 8] */ 2403 fp_push(*(float*)&MEM32(edx + 0x18)); /* 0x3B00439C: fld dword ptr [edx + 0x18] */ 2404 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B00439F: fmul dword ptr [edx] */ 2405 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0043A1: fsubp st(1) */ 2406 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x3B0043A3: fstp dword ptr [ebp - 0x28] */ 2407 fp_push(*(float*)&MEM32(edx + 0x14)); /* 0x3B0043A6: fld dword ptr [edx + 0x14] */ 2408 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B0043A9: fmul dword ptr [edx] */ 2409 fp_push(*(float*)&MEM32(edx + 0x10)); /* 0x3B0043AB: fld dword ptr [edx + 0x10] */ 2410 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B0043AE: fmul dword ptr [edx + 4] */ 2411 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0043B1: fsubp st(1) */ 2412 fp_push(*(float*)&MEM32(ebp + (-0x38))); /* 0x3B0043B3: fld dword ptr [ebp - 0x38] */ 2413 _st[0] *= (double)*(float*)ADDR(edx + 0x20); /* 0x3B0043B6: fmul dword ptr [edx + 0x20] */ 2414 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x3B0043B9: fld dword ptr [ebp - 0x3c] */ 2415 _st[0] *= (double)*(float*)ADDR(edx + 0x10); /* 0x3B0043BC: fmul dword ptr [edx + 0x10] */ 2416 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0043BF: faddp st(1) */ 2417 fp_push(_st[2]); /* 0x3B0043C1: fld st(2) */ 2418 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B0043C3: fmul dword ptr [edx] */ 2419 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0043C5: faddp st(1) */ 2420 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B0043C7: fcom dword ptr [0x3b00604c] */ 2421 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0043CD: fnstsw ax */ 2422 /* test HI8(eax), 0x40u */ /* 0x3B0043CF: test ah, 0x40 */ 2423 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 2424 _cf = 0; 2425 _flag_k = FK_NARROW(FK_TEST, 24); 2426 if (TEST_Z(_flag_a, _flag_b)) goto L_3B0043DE; /* 0x3B0043D2: je 0x3b0043de */ 2427 L_3B0043D4: 2428 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B0043D4: fstp st(0) */ 2429 fp_push(*(float*)&MEM32(0x3B006080)); /* 0x3B0043D6: fld dword ptr [0x3b006080] */ 2430 goto L_3B0043E4; /* 0x3B0043DC: jmp 0x3b0043e4 */ 2431 L_3B0043DE: 2432 _st[0] = (double)*(float*)ADDR(0x3B006048) / _st[0]; /* 0x3B0043DE: fdivr dword ptr [0x3b006048] */ 2433 L_3B0043E4: 2434 fp_push(_st[0]); /* 0x3B0043E4: fld st(0) */ 2435 _st[0] *= _st[3]; /* 0x3B0043E6: fmul st(3) */ 2436 PUSH32(esp, esi); /* 0x3B0043E8: push esi */ 2437 PUSH32(esp, edi); /* 0x3B0043E9: push edi */ 2438 ecx = 0x10u; /* 0x3B0043EA: mov ecx, 0x10 */ 2439 esi = ebp + (-0x40); /* 0x3B0043EF: lea esi, [ebp - 0x40] */ 2440 edi = edx; /* 0x3B0043F2: mov edi, edx */ 2441 eax = edx; /* 0x3B0043F4: mov eax, edx */ 2442 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x40)) = _v; } /* 0x3B0043F6: fstp dword ptr [ebp - 0x40] */ 2443 fp_push(_st[0]); /* 0x3B0043F9: fld st(0) */ 2444 _st[0] *= (double)*(float*)ADDR(ebp + (-0x3C)); /* 0x3B0043FB: fmul dword ptr [ebp - 0x3c] */ 2445 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x3C)) = _v; } /* 0x3B0043FE: fstp dword ptr [ebp - 0x3c] */ 2446 fp_push(_st[0]); /* 0x3B004401: fld st(0) */ 2447 _st[0] *= (double)*(float*)ADDR(ebp + (-0x38)); /* 0x3B004403: fmul dword ptr [ebp - 0x38] */ 2448 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x38)) = _v; } /* 0x3B004406: fstp dword ptr [ebp - 0x38] */ 2449 fp_push(_st[0]); /* 0x3B004409: fld st(0) */ 2450 _st[0] *= (double)*(float*)ADDR(ebp + (-0x30)); /* 0x3B00440B: fmul dword ptr [ebp - 0x30] */ 2451 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x30)) = _v; } /* 0x3B00440E: fstp dword ptr [ebp - 0x30] */ 2452 fp_push(_st[0]); /* 0x3B004411: fld st(0) */ 2453 _st[0] *= (double)*(float*)ADDR(ebp + (-0x2C)); /* 0x3B004413: fmul dword ptr [ebp - 0x2c] */ 2454 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x2C)) = _v; } /* 0x3B004416: fstp dword ptr [ebp - 0x2c] */ 2455 fp_push(_st[0]); /* 0x3B004419: fld st(0) */ 2456 _st[0] *= (double)*(float*)ADDR(ebp + (-0x28)); /* 0x3B00441B: fmul dword ptr [ebp - 0x28] */ 2457 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x3B00441E: fstp dword ptr [ebp - 0x28] */ 2458 fp_push(_st[0]); /* 0x3B004421: fld st(0) */ 2459 _st[0] *= (double)*(float*)ADDR(ebp + (-0x20)); /* 0x3B004423: fmul dword ptr [ebp - 0x20] */ 2460 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x3B004426: fstp dword ptr [ebp - 0x20] */ 2461 fp_push(_st[0]); /* 0x3B004429: fld st(0) */ 2462 _st[0] *= (double)*(float*)ADDR(ebp + (-0x1C)); /* 0x3B00442B: fmul dword ptr [ebp - 0x1c] */ 2463 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x3B00442E: fstp dword ptr [ebp - 0x1c] */ 2464 _st[0] *= _st[1]; /* 0x3B004431: fmul st(1) */ 2465 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x3B004433: fstp dword ptr [ebp - 0x18] */ 2466 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004436: fstp st(0) */ 2467 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004438: fstp st(0) */ 2468 fp_push(*(float*)&MEM32(ebp + (-0x40))); /* 0x3B00443A: fld dword ptr [ebp - 0x40] */ 2469 _st[0] *= (double)*(float*)ADDR(edx + 0x30); /* 0x3B00443D: fmul dword ptr [edx + 0x30] */ 2470 fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x3B004440: fld dword ptr [ebp - 0x20] */ 2471 _st[0] *= (double)*(float*)ADDR(edx + 0x38); /* 0x3B004443: fmul dword ptr [edx + 0x38] */ 2472 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004446: faddp st(1) */ 2473 fp_push(*(float*)&MEM32(ebp + (-0x30))); /* 0x3B004448: fld dword ptr [ebp - 0x30] */ 2474 _st[0] *= (double)*(float*)ADDR(edx + 0x34); /* 0x3B00444B: fmul dword ptr [edx + 0x34] */ 2475 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00444E: faddp st(1) */ 2476 _st[0] = -_st[0]; /* 0x3B004450: fchs */ 2477 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3B004452: fstp dword ptr [ebp - 0x10] */ 2478 fp_push(*(float*)&MEM32(ebp + (-0x3C))); /* 0x3B004455: fld dword ptr [ebp - 0x3c] */ 2479 _st[0] *= (double)*(float*)ADDR(edx + 0x30); /* 0x3B004458: fmul dword ptr [edx + 0x30] */ 2480 fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x3B00445B: fld dword ptr [ebp - 0x1c] */ 2481 _st[0] *= (double)*(float*)ADDR(edx + 0x38); /* 0x3B00445E: fmul dword ptr [edx + 0x38] */ 2482 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004461: faddp st(1) */ 2483 fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x3B004463: fld dword ptr [ebp - 0x2c] */ 2484 _st[0] *= (double)*(float*)ADDR(edx + 0x34); /* 0x3B004466: fmul dword ptr [edx + 0x34] */ 2485 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004469: faddp st(1) */ 2486 _st[0] = -_st[0]; /* 0x3B00446B: fchs */ 2487 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3B00446D: fstp dword ptr [ebp - 0xc] */ 2488 fp_push(*(float*)&MEM32(ebp + (-0x38))); /* 0x3B004470: fld dword ptr [ebp - 0x38] */ 2489 _st[0] *= (double)*(float*)ADDR(edx + 0x30); /* 0x3B004473: fmul dword ptr [edx + 0x30] */ 2490 fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x3B004476: fld dword ptr [ebp - 0x18] */ 2491 _st[0] *= (double)*(float*)ADDR(edx + 0x38); /* 0x3B004479: fmul dword ptr [edx + 0x38] */ 2492 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00447C: faddp st(1) */ 2493 fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x3B00447E: fld dword ptr [ebp - 0x28] */ 2494 _st[0] *= (double)*(float*)ADDR(edx + 0x34); /* 0x3B004481: fmul dword ptr [edx + 0x34] */ 2495 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004484: faddp st(1) */ 2496 _st[0] = -_st[0]; /* 0x3B004486: fchs */ 2497 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3B004488: fstp dword ptr [ebp - 8] */ 2498 if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3B00448B: rep movsd dword ptr es:[edi], dword ptr [esi] */ if (_df > 0) { memmove((void*)ADDR(edi), (void*)ADDR(esi), _b); esi += _b; edi += _b; } else { memmove((void*)ADDR(edi - _b + 4u), (void*)ADDR(esi - _b + 4u), _b); esi -= _b; edi -= _b; } ecx = 0; } 2499 edi = POP32_VAL(esp); /* 0x3B00448D: pop edi */ 2500 esi = POP32_VAL(esp); /* 0x3B00448E: pop esi */ 2501 esp = ebp; /* 0x3B00448F: mov esp, ebp */ 2502 ebp = POP32_VAL(esp); /* 0x3B004491: pop ebp */ 2503 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B004492: ret */ 2504 RECOMP_REGS_OUT(); 2505 } 2506 2507 /* anarchy-vanilla-14.9.1/mr.dll: TMatrix4_t::operator*= (RVA 0x44a0) 2508 * and operator* (RVA 0x4580). Preserve the x87 addition order and round only 2509 * when storing each float; the temporary also permits either input to alias. */ 2510 static void matrix4_multiply(uint32_t output, uint32_t left, uint32_t right) 2511 { 2512 const float *a = (const float *)ADDR(left), *b = (const float *)ADDR(right); 2513 float product[16]; 2514 for (unsigned row = 0; row < 4; ++row) 2515 for (unsigned column = 0; column < 4; ++column) { 2516 double value = (double)b[12 + column] * a[row * 4 + 3]; 2517 value += (double)b[column] * a[row * 4]; 2518 value += (double)b[4 + column] * a[row * 4 + 1]; 2519 value += (double)b[8 + column] * a[row * 4 + 2]; 2520 product[row * 4 + column] = (float)value; 2521 } 2522 memcpy((void *)ADDR(output), product, sizeof(product)); 2523 2524 /* Two temporary x87 slots are popped; preserve all live caller values. */ 2525 g_st[6] = g_st[7] = 0; 2526 g_st_i64[6] = g_st_i64[7] = 0; 2527 } 2528 2529 void sub_3B0044A0(void) { 2530 uint32_t _flag_k, _flag_a, _flag_b, _cf; 2531 RECOMP_ENTER(0x3B0044A0u); 2532 uint32_t matrix = g_ecx; 2533 matrix4_multiply(matrix, matrix, MEM32(g_esp + 4)); 2534 2535 /* Thiscall return state, including the final loop's flags. */ 2536 g_eax = matrix; 2537 g_ecx = 0; 2538 g_edx = matrix + 72; 2539 g_esp += 8; 2540 g_flag_k = FK_DEC; 2541 g_flag_a = g_flag_b = 1; 2542 g_flag_cf = g_edx < matrix + 56; 2543 } 2544 2545 void sub_3B004503(void) { 2546 int _fpu_cmp = 0; 2547 uint32_t _cf = 0; 2548 int _df = 1; 2549 uint32_t _flag_k = FK_NONE; 2550 uint32_t _flag_a = 0, _flag_b = 0; 2551 uint32_t _itail_tgt = 0; 2552 RECOMP_REGS_LOCALS 2553 RECOMP_ENTER(0x3B004503u); 2554 2555 L_3B004503: 2556 MEM32(ebp + (-0x14)) = 0; /* 0x3B004503: mov dword ptr [ebp - 0x14], 0 */ 2557 MEM32(ebp + (-0x10)) = 0; /* 0x3B00450A: mov dword ptr [ebp - 0x10], 0 */ 2558 MEM32(ebp + (-0xC)) = 0; /* 0x3B004511: mov dword ptr [ebp - 0xc], 0 */ 2559 MEM32(ebp + (-0x8)) = 0x3F800000u; /* 0x3B004518: mov dword ptr [ebp - 8], 0x3f800000 */ 2560 esi = ebp + (-0x44); /* 0x3B00451F: lea esi, [ebp - 0x44] */ 2561 edx = ecx + 0x8; /* 0x3B004522: lea edx, [ecx + 8] */ 2562 ebx = 4; /* 0x3B004525: mov ebx, 4 */ 2563 L_3B00452A: 2564 ecx = eax + 0x20; /* 0x3B00452A: lea ecx, [eax + 0x20] */ 2565 edi = 4; /* 0x3B00452D: mov edi, 4 */ 2566 L_3B004532: 2567 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B004532: fld dword ptr [ecx + 0x10] */ 2568 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B004535: fmul dword ptr [edx + 4] */ 2569 fp_push(*(float*)&MEM32(ecx + (-0x20))); /* 0x3B004538: fld dword ptr [ecx - 0x20] */ 2570 _st[0] *= (double)*(float*)ADDR(edx + (-0x8)); /* 0x3B00453B: fmul dword ptr [edx - 8] */ 2571 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4); 2572 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 2573 ecx = ecx + 4; /* 0x3B00453E: add ecx, 4 */ 2574 _flag_k = FK_ADD; 2575 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(4); 2576 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 2577 esi = esi + 4; /* 0x3B004541: add esi, 4 */ 2578 _flag_k = FK_ADD; 2579 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(1); 2580 edi = edi - 1; /* 0x3B004544: dec edi */ 2581 _flag_k = FK_DEC; 2582 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004545: faddp st(1) */ 2583 fp_push(*(float*)&MEM32(ecx + (-0x14))); /* 0x3B004547: fld dword ptr [ecx - 0x14] */ 2584 _st[0] *= (double)*(float*)ADDR(edx + (-0x4)); /* 0x3B00454A: fmul dword ptr [edx - 4] */ 2585 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B00454D: faddp st(1) */ 2586 fp_push(*(float*)&MEM32(ecx + (-0x4))); /* 0x3B00454F: fld dword ptr [ecx - 4] */ 2587 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B004552: fmul dword ptr [edx] */ 2588 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004554: faddp st(1) */ 2589 { float _v = (float)fp_pop(); *(float*)ADDR(esi + (-0x4)) = _v; } /* 0x3B004556: fstp dword ptr [esi - 4] */ 2590 RECOMP_BACKEDGE(); 2591 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004532; /* 0x3B004559: jne 0x3b004532 */ 2592 L_3B00455B: 2593 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u); 2594 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 2595 edx = edx + 0x10u; /* 0x3B00455B: add edx, 0x10 */ 2596 _flag_k = FK_ADD; 2597 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(1); 2598 ebx = ebx - 1; /* 0x3B00455E: dec ebx */ 2599 _flag_k = FK_DEC; 2600 RECOMP_BACKEDGE(); 2601 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B00452A; /* 0x3B00455F: jne 0x3b00452a */ 2602 L_3B004561: 2603 eax = MEM32(ebp + (-0x4)); /* 0x3B004561: mov eax, dword ptr [ebp - 4] */ 2604 ecx = 0x10u; /* 0x3B004564: mov ecx, 0x10 */ 2605 esi = ebp + (-0x44); /* 0x3B004569: lea esi, [ebp - 0x44] */ 2606 edi = eax; /* 0x3B00456C: mov edi, eax */ 2607 if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3B00456E: rep movsd dword ptr es:[edi], dword ptr [esi] */ if (_df > 0) { memmove((void*)ADDR(edi), (void*)ADDR(esi), _b); esi += _b; edi += _b; } else { memmove((void*)ADDR(edi - _b + 4u), (void*)ADDR(esi - _b + 4u), _b); esi -= _b; edi -= _b; } ecx = 0; } 2608 edi = POP32_VAL(esp); /* 0x3B004570: pop edi */ 2609 esi = POP32_VAL(esp); /* 0x3B004571: pop esi */ 2610 ebx = POP32_VAL(esp); /* 0x3B004572: pop ebx */ 2611 esp = ebp; /* 0x3B004573: mov esp, ebp */ 2612 ebp = POP32_VAL(esp); /* 0x3B004575: pop ebp */ 2613 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004576: ret 4 */ 2614 RECOMP_REGS_OUT(); 2615 } 2616 2617 void sub_3B004580(void) { 2618 uint32_t _flag_k, _flag_a, _flag_b, _cf; 2619 RECOMP_ENTER(0x3B004580u); 2620 uint32_t matrix = g_ecx, output = MEM32(g_esp + 4); 2621 matrix4_multiply(output, matrix, MEM32(g_esp + 8)); 2622 2623 /* The returned value uses the caller's hidden result pointer. */ 2624 g_eax = output; 2625 g_ecx = 0; 2626 g_edx = g_esp - 8; 2627 g_esp += 12; 2628 g_flag_k = FK_DEC; 2629 g_flag_a = g_flag_b = 1; 2630 g_flag_cf = (uint32_t)(matrix + 72) < (uint32_t)(matrix + 56); 2631 } 2632 2633 void sub_3B0045F0(void) { 2634 int _fpu_cmp = 0; 2635 uint32_t _cf = 0; 2636 int _df = 1; 2637 uint32_t _flag_k = FK_NONE; 2638 uint32_t _flag_a = 0, _flag_b = 0; 2639 uint32_t _itail_tgt = 0; 2640 RECOMP_REGS_LOCALS 2641 RECOMP_ENTER(0x3B0045F0u); 2642 2643 L_3B0045F0: 2644 PUSH32(esp, ebp); /* 0x3B0045F0: push ebp */ 2645 ebp = esp; /* 0x3B0045F1: mov ebp, esp */ 2646 PUSH32(esp, ecx); /* 0x3B0045F3: push ecx */ 2647 PUSH32(esp, ebx); /* 0x3B0045F4: push ebx */ 2648 ebx = MEM32(ebp + 0x8); /* 0x3B0045F5: mov ebx, dword ptr [ebp + 8] */ 2649 PUSH32(esp, esi); /* 0x3B0045F8: push esi */ 2650 PUSH32(esp, edi); /* 0x3B0045F9: push edi */ 2651 MEM32(ebp + (-0x4)) = 0; /* 0x3B0045FA: mov dword ptr [ebp - 4], 0 */ 2652 L_3B004601: 2653 eax = MEM32(ebp + 0x8); /* 0x3B004601: mov eax, dword ptr [ebp + 8] */ 2654 edi = ecx; /* 0x3B004604: mov edi, ecx */ 2655 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 2656 esi = 0; /* 0x3B004606: xor esi, esi */ 2657 _cf = 0; 2658 _flag_k = FK_TEST; 2659 edx = ebx; /* 0x3B004608: mov edx, ebx */ 2660 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax); 2661 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2662 edi = edi - eax; /* 0x3B00460A: sub edi, eax */ 2663 _flag_k = FK_CMP; 2664 L_3B00460C: 2665 fp_push(*(float*)&MEM32(edi + edx)); /* 0x3B00460C: fld dword ptr [edi + edx] */ 2666 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(edx)); /* 0x3B00460F: fcomp dword ptr [edx] */ 2667 fp_pop(); 2668 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B004611: fnstsw ax */ 2669 /* test HI8(eax), 0x40u */ /* 0x3B004613: test ah, 0x40 */ 2670 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 2671 _cf = 0; 2672 _flag_k = FK_NARROW(FK_TEST, 24); 2673 if (TEST_Z(_flag_a, _flag_b)) goto L_3B00463B; /* 0x3B004616: je 0x3b00463b */ 2674 L_3B004618: 2675 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1); 2676 esi = esi + 1; /* 0x3B004618: inc esi */ 2677 _flag_k = FK_INC; 2678 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(4); 2679 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 2680 edx = edx + 4; /* 0x3B004619: add edx, 4 */ 2681 _flag_k = FK_ADD; 2682 /* cmp esi, 4 */ /* 0x3B00461C: cmp esi, 4 */ 2683 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(4); 2684 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2685 _flag_k = FK_CMP; 2686 RECOMP_BACKEDGE(); 2687 if (CMP_B(_flag_a, _flag_b)) goto L_3B00460C; /* 0x3B00461F: jb 0x3b00460c */ 2688 L_3B004621: 2689 eax = MEM32(ebp + (-0x4)); /* 0x3B004621: mov eax, dword ptr [ebp - 4] */ 2690 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0x10u); 2691 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 2692 ebx = ebx + 0x10u; /* 0x3B004624: add ebx, 0x10 */ 2693 _flag_k = FK_ADD; 2694 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1); 2695 eax = eax + 1; /* 0x3B004627: inc eax */ 2696 _flag_k = FK_INC; 2697 /* cmp eax, 4 */ /* 0x3B004628: cmp eax, 4 */ 2698 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4); 2699 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2700 _flag_k = FK_CMP; 2701 MEM32(ebp + (-0x4)) = eax; /* 0x3B00462B: mov dword ptr [ebp - 4], eax */ 2702 RECOMP_BACKEDGE(); 2703 if (CMP_B(_flag_a, _flag_b)) goto L_3B004601; /* 0x3B00462E: jb 0x3b004601 */ 2704 L_3B004630: 2705 edi = POP32_VAL(esp); /* 0x3B004630: pop edi */ 2706 esi = POP32_VAL(esp); /* 0x3B004631: pop esi */ 2707 SET_LO8(eax, 1); /* 0x3B004632: mov al, 1 */ 2708 ebx = POP32_VAL(esp); /* 0x3B004634: pop ebx */ 2709 esp = ebp; /* 0x3B004635: mov esp, ebp */ 2710 ebp = POP32_VAL(esp); /* 0x3B004637: pop ebp */ 2711 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004638: ret 4 */ 2712 L_3B00463B: 2713 edi = POP32_VAL(esp); /* 0x3B00463B: pop edi */ 2714 esi = POP32_VAL(esp); /* 0x3B00463C: pop esi */ 2715 _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24; 2716 SET_LO8(eax, 0); /* 0x3B00463D: xor al, al */ 2717 _cf = 0; 2718 _flag_k = FK_NARROW(FK_TEST, 24); 2719 ebx = POP32_VAL(esp); /* 0x3B00463F: pop ebx */ 2720 esp = ebp; /* 0x3B004640: mov esp, ebp */ 2721 ebp = POP32_VAL(esp); /* 0x3B004642: pop ebp */ 2722 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004643: ret 4 */ 2723 RECOMP_REGS_OUT(); 2724 } 2725 2726 void sub_3B004650(void) { 2727 int _fpu_cmp = 0; 2728 uint32_t _cf = 0; 2729 int _df = 1; 2730 uint32_t _flag_k = FK_NONE; 2731 uint32_t _flag_a = 0, _flag_b = 0; 2732 uint32_t _itail_tgt = 0; 2733 RECOMP_REGS_LOCALS 2734 RECOMP_ENTER(0x3B004650u); 2735 2736 L_3B004650: 2737 PUSH32(esp, ebp); /* 0x3B004650: push ebp */ 2738 ebp = esp; /* 0x3B004651: mov ebp, esp */ 2739 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x24u); 2740 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2741 esp = esp - 0x24u; /* 0x3B004653: sub esp, 0x24 */ 2742 _flag_k = FK_CMP; 2743 edx = MEM32(ebp + 0x8); /* 0x3B004656: mov edx, dword ptr [ebp + 8] */ 2744 PUSH32(esp, esi); /* 0x3B004659: push esi */ 2745 eax = edx; /* 0x3B00465A: mov eax, edx */ 2746 esi = MEM32(eax); /* 0x3B00465C: mov esi, dword ptr [eax] */ 2747 MEM32(ebp + (-0xC)) = esi; /* 0x3B00465E: mov dword ptr [ebp - 0xc], esi */ 2748 esi = MEM32(eax + 0x4); /* 0x3B004661: mov esi, dword ptr [eax + 4] */ 2749 MEM32(ebp + (-0x8)) = esi; /* 0x3B004664: mov dword ptr [ebp - 8], esi */ 2750 esi = POP32_VAL(esp); /* 0x3B004667: pop esi */ 2751 eax = MEM32(eax + 0x8); /* 0x3B004668: mov eax, dword ptr [eax + 8] */ 2752 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B00466B: fld dword ptr [ebp - 8] */ 2753 MEM32(ebp + (-0x4)) = eax; /* 0x3B00466E: mov dword ptr [ebp - 4], eax */ 2754 eax = MEM32(ebp + 0xC); /* 0x3B004671: mov eax, dword ptr [ebp + 0xc] */ 2755 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B004674: fmul dword ptr [eax + 8] */ 2756 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B004677: fld dword ptr [ebp - 4] */ 2757 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B00467A: fmul dword ptr [eax + 4] */ 2758 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B00467D: fsubp st(1) */ 2759 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B00467F: fld dword ptr [ebp - 4] */ 2760 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B004682: fmul dword ptr [eax] */ 2761 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B004684: fld dword ptr [ebp - 0xc] */ 2762 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B004687: fmul dword ptr [eax + 8] */ 2763 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B00468A: fsubp st(1) */ 2764 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B00468C: fld dword ptr [ebp - 0xc] */ 2765 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B00468F: fmul dword ptr [eax + 4] */ 2766 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B004692: fld dword ptr [ebp - 8] */ 2767 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B004695: fmul dword ptr [eax] */ 2768 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004697: fsubp st(1) */ 2769 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3B004699: fstp dword ptr [ebp - 4] */ 2770 fp_push(_st[1]); /* 0x3B00469C: fld st(1) */ 2771 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3B00469E: fstp dword ptr [ebp - 0xc] */ 2772 eax = MEM32(ebp + (-0xC)); /* 0x3B0046A1: mov eax, dword ptr [ebp - 0xc] */ 2773 { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3B0046A4: fst dword ptr [ebp - 8] */ 2774 MEM32(ebp + (-0x18)) = eax; /* 0x3B0046A7: mov dword ptr [ebp - 0x18], eax */ 2775 eax = MEM32(ebp + (-0x8)); /* 0x3B0046AA: mov eax, dword ptr [ebp - 8] */ 2776 fp_push(_st[1]); /* 0x3B0046AD: fld st(1) */ 2777 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B0046AF: fcomp dword ptr [0x3b00604c] */ 2778 fp_pop(); 2779 MEM32(ebp + (-0x14)) = eax; /* 0x3B0046B5: mov dword ptr [ebp - 0x14], eax */ 2780 eax = MEM32(ebp + (-0x4)); /* 0x3B0046B8: mov eax, dword ptr [ebp - 4] */ 2781 MEM32(ebp + (-0x10)) = eax; /* 0x3B0046BB: mov dword ptr [ebp - 0x10], eax */ 2782 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0046BE: fnstsw ax */ 2783 /* test HI8(eax), 0x40u */ /* 0x3B0046C0: test ah, 0x40 */ 2784 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 2785 _cf = 0; 2786 _flag_k = FK_NARROW(FK_TEST, 24); 2787 if (TEST_Z(_flag_a, _flag_b)) goto L_3B004755; /* 0x3B0046C3: je 0x3b004755 */ 2788 L_3B0046C9: 2789 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B0046C9: fcom dword ptr [0x3b00604c] */ 2790 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0046CF: fnstsw ax */ 2791 /* test HI8(eax), 0x40u */ /* 0x3B0046D1: test ah, 0x40 */ 2792 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 2793 _cf = 0; 2794 _flag_k = FK_NARROW(FK_TEST, 24); 2795 if (TEST_Z(_flag_a, _flag_b)) goto L_3B004755; /* 0x3B0046D4: je 0x3b004755 */ 2796 L_3B0046D6: 2797 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B0046D6: fld dword ptr [ebp - 4] */ 2798 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B0046D9: fcomp dword ptr [0x3b00604c] */ 2799 fp_pop(); 2800 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0046DF: fnstsw ax */ 2801 /* test HI8(eax), 0x40u */ /* 0x3B0046E1: test ah, 0x40 */ 2802 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 2803 _cf = 0; 2804 _flag_k = FK_NARROW(FK_TEST, 24); 2805 if (TEST_Z(_flag_a, _flag_b)) goto L_3B004755; /* 0x3B0046E4: je 0x3b004755 */ 2806 L_3B0046E6: 2807 fp_push(*(float*)&MEM32(edx)); /* 0x3B0046E6: fld dword ptr [edx] */ 2808 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B0046E8: fcomp dword ptr [0x3b00604c] */ 2809 fp_pop(); 2810 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0046EE: fnstsw ax */ 2811 /* test HI8(eax), 0x40u */ /* 0x3B0046F0: test ah, 0x40 */ 2812 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 2813 _cf = 0; 2814 _flag_k = FK_NARROW(FK_TEST, 24); 2815 if (TEST_Z(_flag_a, _flag_b)) goto L_3B004755; /* 0x3B0046F3: je 0x3b004755 */ 2816 L_3B0046F5: 2817 fp_push(*(float*)&MEM32(edx + 0x4)); /* 0x3B0046F5: fld dword ptr [edx + 4] */ 2818 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B0046F8: fcomp dword ptr [0x3b00604c] */ 2819 fp_pop(); 2820 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B0046FE: fnstsw ax */ 2821 /* test HI8(eax), 0x40u */ /* 0x3B004700: test ah, 0x40 */ 2822 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 2823 _cf = 0; 2824 _flag_k = FK_NARROW(FK_TEST, 24); 2825 if (TEST_Z(_flag_a, _flag_b)) goto L_3B004755; /* 0x3B004703: je 0x3b004755 */ 2826 L_3B004705: 2827 fp_push(*(float*)&MEM32(edx + 0x8)); /* 0x3B004705: fld dword ptr [edx + 8] */ 2828 _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3B00604C)); /* 0x3B004708: fcomp dword ptr [0x3b00604c] */ 2829 fp_pop(); 2830 eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3B00470E: fnstsw ax */ 2831 /* test HI8(eax), 0x40u */ /* 0x3B004710: test ah, 0x40 */ 2832 _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24; 2833 _cf = 0; 2834 _flag_k = FK_NARROW(FK_TEST, 24); 2835 if (TEST_Z(_flag_a, _flag_b)) goto L_3B004755; /* 0x3B004713: je 0x3b004755 */ 2836 L_3B004715: 2837 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004715: fstp st(0) */ 2838 edx = 0x3F800000u; /* 0x3B004717: mov edx, 0x3f800000 */ 2839 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 2840 eax = 0; /* 0x3B00471C: xor eax, eax */ 2841 _cf = 0; 2842 _flag_k = FK_TEST; 2843 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B00471E: fstp st(0) */ 2844 MEM32(ecx) = edx; /* 0x3B004720: mov dword ptr [ecx], edx */ 2845 MEM32(ecx + 0x4) = eax; /* 0x3B004722: mov dword ptr [ecx + 4], eax */ 2846 MEM32(ecx + 0x8) = eax; /* 0x3B004725: mov dword ptr [ecx + 8], eax */ 2847 MEM32(ecx + 0xC) = eax; /* 0x3B004728: mov dword ptr [ecx + 0xc], eax */ 2848 MEM32(ecx + 0x10) = eax; /* 0x3B00472B: mov dword ptr [ecx + 0x10], eax */ 2849 MEM32(ecx + 0x14) = edx; /* 0x3B00472E: mov dword ptr [ecx + 0x14], edx */ 2850 MEM32(ecx + 0x18) = eax; /* 0x3B004731: mov dword ptr [ecx + 0x18], eax */ 2851 MEM32(ecx + 0x1C) = eax; /* 0x3B004734: mov dword ptr [ecx + 0x1c], eax */ 2852 MEM32(ecx + 0x20) = eax; /* 0x3B004737: mov dword ptr [ecx + 0x20], eax */ 2853 MEM32(ecx + 0x24) = eax; /* 0x3B00473A: mov dword ptr [ecx + 0x24], eax */ 2854 MEM32(ecx + 0x28) = edx; /* 0x3B00473D: mov dword ptr [ecx + 0x28], edx */ 2855 MEM32(ecx + 0x2C) = eax; /* 0x3B004740: mov dword ptr [ecx + 0x2c], eax */ 2856 MEM32(ecx + 0x30) = eax; /* 0x3B004743: mov dword ptr [ecx + 0x30], eax */ 2857 MEM32(ecx + 0x34) = eax; /* 0x3B004746: mov dword ptr [ecx + 0x34], eax */ 2858 MEM32(ecx + 0x38) = eax; /* 0x3B004749: mov dword ptr [ecx + 0x38], eax */ 2859 MEM32(ecx + 0x3C) = edx; /* 0x3B00474C: mov dword ptr [ecx + 0x3c], edx */ 2860 esp = ebp; /* 0x3B00474F: mov esp, ebp */ 2861 ebp = POP32_VAL(esp); /* 0x3B004751: pop ebp */ 2862 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3B004752: ret 8 */ 2863 L_3B004755: 2864 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B004755: fld dword ptr [ebp - 4] */ 2865 _st[0] *= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B004758: fmul dword ptr [ebp - 4] */ 2866 fp_push(_st[1]); /* 0x3B00475B: fld st(1) */ 2867 _st[0] *= _st[2]; /* 0x3B00475D: fmul st(2) */ 2868 eax = MEM32(edx); /* 0x3B00475F: mov eax, dword ptr [edx] */ 2869 MEM32(ebp + (-0xC)) = eax; /* 0x3B004761: mov dword ptr [ebp - 0xc], eax */ 2870 eax = MEM32(edx + 0x4); /* 0x3B004764: mov eax, dword ptr [edx + 4] */ 2871 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004767: faddp st(1) */ 2872 fp_push(_st[2]); /* 0x3B004769: fld st(2) */ 2873 _st[0] *= _st[3]; /* 0x3B00476B: fmul st(3) */ 2874 edx = MEM32(edx + 0x8); /* 0x3B00476D: mov edx, dword ptr [edx + 8] */ 2875 MEM32(ebp + (-0x8)) = eax; /* 0x3B004770: mov dword ptr [ebp - 8], eax */ 2876 MEM32(ebp + (-0x4)) = edx; /* 0x3B004773: mov dword ptr [ebp - 4], edx */ 2877 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004776: faddp st(1) */ 2878 _st[0] = sqrt(_st[0]); /* 0x3B004778: fsqrt */ 2879 { _st[1] = _st[0]; g_st_i64[1] = g_st_i64[0]; fp_pop(); } /* 0x3B00477A: fstp st(1) */ 2880 _st[0] = (double)*(float*)ADDR(0x3B006048) / _st[0]; /* 0x3B00477C: fdivr dword ptr [0x3b006048] */ 2881 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3B004782: fstp dword ptr [ebp + 8] */ 2882 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B004785: fmul dword ptr [ebp + 8] */ 2883 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004788: fld dword ptr [ebp + 8] */ 2884 _st[0] *= (double)*(float*)ADDR(ebp + (-0x14)); /* 0x3B00478B: fmul dword ptr [ebp - 0x14] */ 2885 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3B00478E: fstp dword ptr [ebp - 0x14] */ 2886 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004791: fld dword ptr [ebp + 8] */ 2887 _st[0] *= (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3B004794: fmul dword ptr [ebp - 0x10] */ 2888 eax = MEM32(ebp + (-0x14)); /* 0x3B004797: mov eax, dword ptr [ebp - 0x14] */ 2889 MEM32(ecx + 0x4) = eax; /* 0x3B00479A: mov dword ptr [ecx + 4], eax */ 2890 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3B00479D: fstp dword ptr [ebp - 0x10] */ 2891 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B0047A0: fld dword ptr [ebp - 4] */ 2892 _st[0] *= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B0047A3: fmul dword ptr [ebp - 4] */ 2893 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B0047A6: fld dword ptr [ebp - 8] */ 2894 _st[0] *= (double)*(float*)ADDR(ebp + (-0x8)); /* 0x3B0047A9: fmul dword ptr [ebp - 8] */ 2895 edx = MEM32(ebp + (-0x10)); /* 0x3B0047AC: mov edx, dword ptr [ebp - 0x10] */ 2896 MEM32(ecx + 0x8) = edx; /* 0x3B0047AF: mov dword ptr [ecx + 8], edx */ 2897 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0047B2: faddp st(1) */ 2898 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B0047B4: fld dword ptr [ebp - 0xc] */ 2899 _st[0] *= (double)*(float*)ADDR(ebp + (-0xC)); /* 0x3B0047B7: fmul dword ptr [ebp - 0xc] */ 2900 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0047BA: faddp st(1) */ 2901 _st[0] = sqrt(_st[0]); /* 0x3B0047BC: fsqrt */ 2902 _st[0] = (double)*(float*)ADDR(0x3B006048) / _st[0]; /* 0x3B0047BE: fdivr dword ptr [0x3b006048] */ 2903 fp_push(_st[0]); /* 0x3B0047C4: fld st(0) */ 2904 _st[0] *= (double)*(float*)ADDR(ebp + (-0xC)); /* 0x3B0047C6: fmul dword ptr [ebp - 0xc] */ 2905 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3B0047C9: fstp dword ptr [ebp - 0xc] */ 2906 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B0047CC: fld dword ptr [ebp - 8] */ 2907 _st[0] *= _st[1]; /* 0x3B0047CF: fmul st(1) */ 2908 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3B0047D1: fstp dword ptr [ebp - 8] */ 2909 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B0047D4: fld dword ptr [ebp - 4] */ 2910 _st[0] *= _st[1]; /* 0x3B0047D7: fmul st(1) */ 2911 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3B0047D9: fstp dword ptr [ebp - 4] */ 2912 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B0047DC: fstp st(0) */ 2913 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B0047DE: fld dword ptr [ebp - 8] */ 2914 _st[0] *= (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3B0047E1: fmul dword ptr [ebp - 0x10] */ 2915 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B0047E4: fld dword ptr [ebp - 4] */ 2916 _st[0] *= (double)*(float*)ADDR(ebp + (-0x14)); /* 0x3B0047E7: fmul dword ptr [ebp - 0x14] */ 2917 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0047EA: fsubp st(1) */ 2918 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3B0047EC: fstp dword ptr [ebp + 8] */ 2919 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B0047EF: fld dword ptr [ebp - 4] */ 2920 _st[0] *= _st[1]; /* 0x3B0047F2: fmul st(1) */ 2921 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B0047F4: fld dword ptr [ebp - 0xc] */ 2922 _st[0] *= (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3B0047F7: fmul dword ptr [ebp - 0x10] */ 2923 eax = MEM32(ebp + 0x8); /* 0x3B0047FA: mov eax, dword ptr [ebp + 8] */ 2924 MEM32(ecx + 0x10) = eax; /* 0x3B0047FD: mov dword ptr [ecx + 0x10], eax */ 2925 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004800: fsubp st(1) */ 2926 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0xC) = _v; } /* 0x3B004802: fstp dword ptr [ebp + 0xc] */ 2927 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B004805: fld dword ptr [ebp - 0xc] */ 2928 _st[0] *= (double)*(float*)ADDR(ebp + (-0x14)); /* 0x3B004808: fmul dword ptr [ebp - 0x14] */ 2929 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B00480B: fld dword ptr [ebp - 8] */ 2930 edx = MEM32(ebp + 0xC); /* 0x3B00480E: mov edx, dword ptr [ebp + 0xc] */ 2931 _st[0] *= _st[2]; /* 0x3B004811: fmul st(2) */ 2932 MEM32(ecx + 0x14) = edx; /* 0x3B004813: mov dword ptr [ecx + 0x14], edx */ 2933 edx = MEM32(ebp + (-0xC)); /* 0x3B004816: mov edx, dword ptr [ebp - 0xc] */ 2934 MEM32(ecx + 0x20) = edx; /* 0x3B004819: mov dword ptr [ecx + 0x20], edx */ 2935 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B00481C: fsubp st(1) */ 2936 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x3B00481E: fstp dword ptr [ebp - 0x1c] */ 2937 eax = MEM32(ebp + (-0x1C)); /* 0x3B004821: mov eax, dword ptr [ebp - 0x1c] */ 2938 { float _v = (float)fp_pop(); *(float*)ADDR(ecx) = _v; } /* 0x3B004824: fstp dword ptr [ecx] */ 2939 MEM32(ecx + 0x18) = eax; /* 0x3B004826: mov dword ptr [ecx + 0x18], eax */ 2940 eax = MEM32(ebp + (-0x8)); /* 0x3B004829: mov eax, dword ptr [ebp - 8] */ 2941 edx = MEM32(ebp + (-0x4)); /* 0x3B00482C: mov edx, dword ptr [ebp - 4] */ 2942 MEM32(ecx + 0x24) = eax; /* 0x3B00482F: mov dword ptr [ecx + 0x24], eax */ 2943 MEM32(ecx + 0x28) = edx; /* 0x3B004832: mov dword ptr [ecx + 0x28], edx */ 2944 esp = ebp; /* 0x3B004835: mov esp, ebp */ 2945 ebp = POP32_VAL(esp); /* 0x3B004837: pop ebp */ 2946 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3B004838: ret 8 */ 2947 RECOMP_REGS_OUT(); 2948 } 2949 2950 void sub_3B004840(void) { 2951 int _fpu_cmp = 0; 2952 uint32_t _cf = 0; 2953 int _df = 1; 2954 uint32_t _flag_k = FK_NONE; 2955 uint32_t _flag_a = 0, _flag_b = 0; 2956 uint32_t _itail_tgt = 0; 2957 RECOMP_REGS_LOCALS 2958 RECOMP_ENTER(0x3B004840u); 2959 2960 L_3B004840: 2961 PUSH32(esp, ebp); /* 0x3B004840: push ebp */ 2962 ebp = esp; /* 0x3B004841: mov ebp, esp */ 2963 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x14u); 2964 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 2965 esp = esp - 0x14u; /* 0x3B004843: sub esp, 0x14 */ 2966 _flag_k = FK_CMP; 2967 eax = MEM32(ebp + 0x8); /* 0x3B004846: mov eax, dword ptr [ebp + 8] */ 2968 fp_push(*(float*)&MEM32(eax)); /* 0x3B004849: fld dword ptr [eax] */ 2969 fp_push(_st[0]); /* 0x3B00484B: fld st(0) */ 2970 { double _v = fp_pop(); _st[0] *= _v; } /* 0x3B00484D: fmulp st(1) */ 2971 _st[0] += _st[0]; /* 0x3B00484F: fadd st(0), st(0) */ 2972 fp_push(*(float*)&MEM32(eax + 0x4)); /* 0x3B004851: fld dword ptr [eax + 4] */ 2973 fp_push(_st[0]); /* 0x3B004854: fld st(0) */ 2974 _st[0] *= _st[1]; /* 0x3B004856: fmul st(1) */ 2975 _st[0] += _st[0]; /* 0x3B004858: fadd st(0), st(0) */ 2976 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3B00485A: fstp dword ptr [ebp - 0x14] */ 2977 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B00485D: fstp st(0) */ 2978 fp_push(*(float*)&MEM32(eax + 0x8)); /* 0x3B00485F: fld dword ptr [eax + 8] */ 2979 fp_push(_st[0]); /* 0x3B004862: fld st(0) */ 2980 _st[0] *= _st[1]; /* 0x3B004864: fmul st(1) */ 2981 _st[0] += _st[0]; /* 0x3B004866: fadd st(0), st(0) */ 2982 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3B004868: fstp dword ptr [ebp + 8] */ 2983 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B00486B: fstp st(0) */ 2984 fp_push(*(float*)&MEM32(eax)); /* 0x3B00486D: fld dword ptr [eax] */ 2985 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B00486F: fmul dword ptr [eax + 4] */ 2986 _st[0] += _st[0]; /* 0x3B004872: fadd st(0), st(0) */ 2987 fp_push(*(float*)&MEM32(eax + 0x8)); /* 0x3B004874: fld dword ptr [eax + 8] */ 2988 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B004877: fmul dword ptr [eax] */ 2989 _st[0] += _st[0]; /* 0x3B004879: fadd st(0), st(0) */ 2990 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3B00487B: fstp dword ptr [ebp - 8] */ 2991 fp_push(*(float*)&MEM32(eax + 0xC)); /* 0x3B00487E: fld dword ptr [eax + 0xc] */ 2992 _st[0] *= (double)*(float*)ADDR(eax); /* 0x3B004881: fmul dword ptr [eax] */ 2993 _st[0] += _st[0]; /* 0x3B004883: fadd st(0), st(0) */ 2994 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3B004885: fstp dword ptr [ebp - 0x10] */ 2995 fp_push(*(float*)&MEM32(eax + 0x8)); /* 0x3B004888: fld dword ptr [eax + 8] */ 2996 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B00488B: fmul dword ptr [eax + 4] */ 2997 _st[0] += _st[0]; /* 0x3B00488E: fadd st(0), st(0) */ 2998 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3B004890: fstp dword ptr [ebp - 0xc] */ 2999 fp_push(*(float*)&MEM32(eax + 0xC)); /* 0x3B004893: fld dword ptr [eax + 0xc] */ 3000 _st[0] *= (double)*(float*)ADDR(eax + 0x4); /* 0x3B004896: fmul dword ptr [eax + 4] */ 3001 _st[0] += _st[0]; /* 0x3B004899: fadd st(0), st(0) */ 3002 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3B00489B: fstp dword ptr [ebp - 4] */ 3003 fp_push(*(float*)&MEM32(eax + 0xC)); /* 0x3B00489E: fld dword ptr [eax + 0xc] */ 3004 _st[0] *= (double)*(float*)ADDR(eax + 0x8); /* 0x3B0048A1: fmul dword ptr [eax + 8] */ 3005 _st[0] += _st[0]; /* 0x3B0048A4: fadd st(0), st(0) */ 3006 fp_push(*(float*)&MEM32(0x3B006048)); /* 0x3B0048A6: fld dword ptr [0x3b006048] */ 3007 _st[0] -= (double)*(float*)ADDR(ebp + (-0x14)); /* 0x3B0048AC: fsub dword ptr [ebp - 0x14] */ 3008 _st[0] -= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B0048AF: fsub dword ptr [ebp + 8] */ 3009 { float _v = (float)fp_pop(); *(float*)ADDR(ecx) = _v; } /* 0x3B0048B2: fstp dword ptr [ecx] */ 3010 fp_push(_st[0]); /* 0x3B0048B4: fld st(0) */ 3011 _st[0] += _st[2]; /* 0x3B0048B6: fadd st(2) */ 3012 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x4) = _v; } /* 0x3B0048B8: fstp dword ptr [ecx + 4] */ 3013 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B0048BB: fld dword ptr [ebp - 8] */ 3014 _st[0] -= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B0048BE: fsub dword ptr [ebp - 4] */ 3015 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x8) = _v; } /* 0x3B0048C1: fstp dword ptr [ecx + 8] */ 3016 fp_xch(1); /* 0x3B0048C4: fxch st(1) */ 3017 _st[0] -= _st[1]; /* 0x3B0048C6: fsub st(1) */ 3018 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x10) = _v; } /* 0x3B0048C8: fstp dword ptr [ecx + 0x10] */ 3019 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B0048CB: fstp st(0) */ 3020 _st[0] = (double)*(float*)ADDR(0x3B006048) - _st[0]; /* 0x3B0048CD: fsubr dword ptr [0x3b006048] */ 3021 fp_push(_st[0]); /* 0x3B0048D3: fld st(0) */ 3022 _st[0] -= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B0048D5: fsub dword ptr [ebp + 8] */ 3023 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x14) = _v; } /* 0x3B0048D8: fstp dword ptr [ecx + 0x14] */ 3024 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B0048DB: fld dword ptr [ebp - 0xc] */ 3025 _st[0] += (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3B0048DE: fadd dword ptr [ebp - 0x10] */ 3026 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x18) = _v; } /* 0x3B0048E1: fstp dword ptr [ecx + 0x18] */ 3027 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B0048E4: fld dword ptr [ebp - 4] */ 3028 _st[0] += (double)*(float*)ADDR(ebp + (-0x8)); /* 0x3B0048E7: fadd dword ptr [ebp - 8] */ 3029 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x20) = _v; } /* 0x3B0048EA: fstp dword ptr [ecx + 0x20] */ 3030 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B0048ED: fld dword ptr [ebp - 0xc] */ 3031 _st[0] -= (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3B0048F0: fsub dword ptr [ebp - 0x10] */ 3032 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x24) = _v; } /* 0x3B0048F3: fstp dword ptr [ecx + 0x24] */ 3033 _st[0] -= (double)*(float*)ADDR(ebp + (-0x14)); /* 0x3B0048F6: fsub dword ptr [ebp - 0x14] */ 3034 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x28) = _v; } /* 0x3B0048F9: fstp dword ptr [ecx + 0x28] */ 3035 esp = ebp; /* 0x3B0048FC: mov esp, ebp */ 3036 ebp = POP32_VAL(esp); /* 0x3B0048FE: pop ebp */ 3037 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B0048FF: ret 4 */ 3038 RECOMP_REGS_OUT(); 3039 } 3040 3041 void sub_3B004910(void) { 3042 int _fpu_cmp = 0; 3043 uint32_t _cf = 0; 3044 int _df = 1; 3045 uint32_t _flag_k = FK_NONE; 3046 uint32_t _flag_a = 0, _flag_b = 0; 3047 uint32_t _itail_tgt = 0; 3048 RECOMP_REGS_LOCALS 3049 RECOMP_ENTER(0x3B004910u); 3050 3051 L_3B004910: 3052 PUSH32(esp, ebp); /* 0x3B004910: push ebp */ 3053 ebp = esp; /* 0x3B004911: mov ebp, esp */ 3054 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004913: fld dword ptr [ebp + 8] */ 3055 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3B004916: fcos */ 3056 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004918: fld dword ptr [ebp + 8] */ 3057 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B00491B: fsin */ 3058 fp_push(*(float*)&MEM32(ecx + 0x14)); /* 0x3B00491D: fld dword ptr [ecx + 0x14] */ 3059 fp_push(_st[2]); /* 0x3B004920: fld st(2) */ 3060 _st[0] *= (double)*(float*)ADDR(ecx + 0x14); /* 0x3B004922: fmul dword ptr [ecx + 0x14] */ 3061 fp_push(_st[2]); /* 0x3B004925: fld st(2) */ 3062 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B004927: fmul dword ptr [ecx + 0x18] */ 3063 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B00492A: fsubp st(1) */ 3064 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x14) = _v; } /* 0x3B00492C: fstp dword ptr [ecx + 0x14] */ 3065 fp_push(_st[2]); /* 0x3B00492F: fld st(2) */ 3066 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B004931: fmul dword ptr [ecx + 0x18] */ 3067 fp_xch(1); /* 0x3B004934: fxch st(1) */ 3068 _st[0] *= _st[2]; /* 0x3B004936: fmul st(2) */ 3069 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004938: faddp st(1) */ 3070 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x18) = _v; } /* 0x3B00493A: fstp dword ptr [ecx + 0x18] */ 3071 fp_push(*(float*)&MEM32(ecx + 0x24)); /* 0x3B00493D: fld dword ptr [ecx + 0x24] */ 3072 fp_push(_st[2]); /* 0x3B004940: fld st(2) */ 3073 _st[0] *= (double)*(float*)ADDR(ecx + 0x24); /* 0x3B004942: fmul dword ptr [ecx + 0x24] */ 3074 fp_push(_st[2]); /* 0x3B004945: fld st(2) */ 3075 _st[0] *= (double)*(float*)ADDR(ecx + 0x28); /* 0x3B004947: fmul dword ptr [ecx + 0x28] */ 3076 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B00494A: fsubp st(1) */ 3077 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x24) = _v; } /* 0x3B00494C: fstp dword ptr [ecx + 0x24] */ 3078 fp_push(_st[2]); /* 0x3B00494F: fld st(2) */ 3079 _st[0] *= (double)*(float*)ADDR(ecx + 0x28); /* 0x3B004951: fmul dword ptr [ecx + 0x28] */ 3080 fp_xch(1); /* 0x3B004954: fxch st(1) */ 3081 _st[0] *= _st[2]; /* 0x3B004956: fmul st(2) */ 3082 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004958: faddp st(1) */ 3083 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x28) = _v; } /* 0x3B00495A: fstp dword ptr [ecx + 0x28] */ 3084 fp_push(*(float*)&MEM32(ecx + 0x34)); /* 0x3B00495D: fld dword ptr [ecx + 0x34] */ 3085 fp_push(_st[2]); /* 0x3B004960: fld st(2) */ 3086 _st[0] *= (double)*(float*)ADDR(ecx + 0x34); /* 0x3B004962: fmul dword ptr [ecx + 0x34] */ 3087 fp_push(_st[2]); /* 0x3B004965: fld st(2) */ 3088 _st[0] *= (double)*(float*)ADDR(ecx + 0x38); /* 0x3B004967: fmul dword ptr [ecx + 0x38] */ 3089 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B00496A: fsubp st(1) */ 3090 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x34) = _v; } /* 0x3B00496C: fstp dword ptr [ecx + 0x34] */ 3091 _st[0] *= _st[1]; /* 0x3B00496F: fmul st(1) */ 3092 fp_push(_st[2]); /* 0x3B004971: fld st(2) */ 3093 _st[0] *= (double)*(float*)ADDR(ecx + 0x38); /* 0x3B004973: fmul dword ptr [ecx + 0x38] */ 3094 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004976: faddp st(1) */ 3095 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x38) = _v; } /* 0x3B004978: fstp dword ptr [ecx + 0x38] */ 3096 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x3B00497B: fld dword ptr [ecx + 4] */ 3097 fp_push(_st[2]); /* 0x3B00497E: fld st(2) */ 3098 _st[0] *= (double)*(float*)ADDR(ecx + 0x4); /* 0x3B004980: fmul dword ptr [ecx + 4] */ 3099 fp_push(_st[2]); /* 0x3B004983: fld st(2) */ 3100 _st[0] *= (double)*(float*)ADDR(ecx + 0x8); /* 0x3B004985: fmul dword ptr [ecx + 8] */ 3101 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004988: fsubp st(1) */ 3102 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x4) = _v; } /* 0x3B00498A: fstp dword ptr [ecx + 4] */ 3103 fp_xch(2); /* 0x3B00498D: fxch st(2) */ 3104 _st[0] *= (double)*(float*)ADDR(ecx + 0x8); /* 0x3B00498F: fmul dword ptr [ecx + 8] */ 3105 fp_xch(2); /* 0x3B004992: fxch st(2) */ 3106 _st[0] *= _st[1]; /* 0x3B004994: fmul st(1) */ 3107 { double _v = fp_pop(); _st[1] += _v; } /* 0x3B004996: faddp st(2) */ 3108 fp_xch(1); /* 0x3B004998: fxch st(1) */ 3109 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x8) = _v; } /* 0x3B00499A: fstp dword ptr [ecx + 8] */ 3110 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B00499D: fstp st(0) */ 3111 ebp = POP32_VAL(esp); /* 0x3B00499F: pop ebp */ 3112 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B0049A0: ret 4 */ 3113 RECOMP_REGS_OUT(); 3114 } 3115 3116 void sub_3B0049B0(void) { 3117 int _fpu_cmp = 0; 3118 uint32_t _cf = 0; 3119 int _df = 1; 3120 uint32_t _flag_k = FK_NONE; 3121 uint32_t _flag_a = 0, _flag_b = 0; 3122 uint32_t _itail_tgt = 0; 3123 RECOMP_REGS_LOCALS 3124 RECOMP_ENTER(0x3B0049B0u); 3125 3126 L_3B0049B0: 3127 PUSH32(esp, ebp); /* 0x3B0049B0: push ebp */ 3128 ebp = esp; /* 0x3B0049B1: mov ebp, esp */ 3129 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B0049B3: fld dword ptr [ebp + 8] */ 3130 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3B0049B6: fcos */ 3131 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B0049B8: fld dword ptr [ebp + 8] */ 3132 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B0049BB: fsin */ 3133 fp_push(*(float*)&MEM32(ecx)); /* 0x3B0049BD: fld dword ptr [ecx] */ 3134 fp_push(_st[1]); /* 0x3B0049BF: fld st(1) */ 3135 _st[0] *= (double)*(float*)ADDR(ecx + 0x8); /* 0x3B0049C1: fmul dword ptr [ecx + 8] */ 3136 fp_push(_st[3]); /* 0x3B0049C4: fld st(3) */ 3137 _st[0] *= (double)*(float*)ADDR(ecx); /* 0x3B0049C6: fmul dword ptr [ecx] */ 3138 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0049C8: faddp st(1) */ 3139 { float _v = (float)fp_pop(); *(float*)ADDR(ecx) = _v; } /* 0x3B0049CA: fstp dword ptr [ecx] */ 3140 fp_push(_st[2]); /* 0x3B0049CC: fld st(2) */ 3141 _st[0] *= (double)*(float*)ADDR(ecx + 0x8); /* 0x3B0049CE: fmul dword ptr [ecx + 8] */ 3142 fp_xch(1); /* 0x3B0049D1: fxch st(1) */ 3143 _st[0] *= _st[2]; /* 0x3B0049D3: fmul st(2) */ 3144 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0049D5: fsubp st(1) */ 3145 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x8) = _v; } /* 0x3B0049D7: fstp dword ptr [ecx + 8] */ 3146 fp_push(*(float*)&MEM32(ecx + 0x20)); /* 0x3B0049DA: fld dword ptr [ecx + 0x20] */ 3147 fp_push(_st[1]); /* 0x3B0049DD: fld st(1) */ 3148 _st[0] *= (double)*(float*)ADDR(ecx + 0x28); /* 0x3B0049DF: fmul dword ptr [ecx + 0x28] */ 3149 fp_push(_st[3]); /* 0x3B0049E2: fld st(3) */ 3150 _st[0] *= (double)*(float*)ADDR(ecx + 0x20); /* 0x3B0049E4: fmul dword ptr [ecx + 0x20] */ 3151 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B0049E7: faddp st(1) */ 3152 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x20) = _v; } /* 0x3B0049E9: fstp dword ptr [ecx + 0x20] */ 3153 fp_push(_st[2]); /* 0x3B0049EC: fld st(2) */ 3154 _st[0] *= (double)*(float*)ADDR(ecx + 0x28); /* 0x3B0049EE: fmul dword ptr [ecx + 0x28] */ 3155 fp_xch(1); /* 0x3B0049F1: fxch st(1) */ 3156 _st[0] *= _st[2]; /* 0x3B0049F3: fmul st(2) */ 3157 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B0049F5: fsubp st(1) */ 3158 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x28) = _v; } /* 0x3B0049F7: fstp dword ptr [ecx + 0x28] */ 3159 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B0049FA: fld dword ptr [ecx + 0x10] */ 3160 fp_push(_st[2]); /* 0x3B0049FD: fld st(2) */ 3161 _st[0] *= (double)*(float*)ADDR(ecx + 0x10); /* 0x3B0049FF: fmul dword ptr [ecx + 0x10] */ 3162 fp_push(_st[2]); /* 0x3B004A02: fld st(2) */ 3163 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B004A04: fmul dword ptr [ecx + 0x18] */ 3164 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004A07: faddp st(1) */ 3165 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x10) = _v; } /* 0x3B004A09: fstp dword ptr [ecx + 0x10] */ 3166 fp_push(_st[2]); /* 0x3B004A0C: fld st(2) */ 3167 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B004A0E: fmul dword ptr [ecx + 0x18] */ 3168 fp_xch(1); /* 0x3B004A11: fxch st(1) */ 3169 _st[0] *= _st[2]; /* 0x3B004A13: fmul st(2) */ 3170 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004A15: fsubp st(1) */ 3171 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x18) = _v; } /* 0x3B004A17: fstp dword ptr [ecx + 0x18] */ 3172 fp_push(*(float*)&MEM32(ecx + 0x30)); /* 0x3B004A1A: fld dword ptr [ecx + 0x30] */ 3173 fp_push(_st[2]); /* 0x3B004A1D: fld st(2) */ 3174 _st[0] *= (double)*(float*)ADDR(ecx + 0x30); /* 0x3B004A1F: fmul dword ptr [ecx + 0x30] */ 3175 fp_push(_st[2]); /* 0x3B004A22: fld st(2) */ 3176 _st[0] *= (double)*(float*)ADDR(ecx + 0x38); /* 0x3B004A24: fmul dword ptr [ecx + 0x38] */ 3177 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004A27: faddp st(1) */ 3178 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x30) = _v; } /* 0x3B004A29: fstp dword ptr [ecx + 0x30] */ 3179 fp_xch(2); /* 0x3B004A2C: fxch st(2) */ 3180 _st[0] *= (double)*(float*)ADDR(ecx + 0x38); /* 0x3B004A2E: fmul dword ptr [ecx + 0x38] */ 3181 fp_xch(2); /* 0x3B004A31: fxch st(2) */ 3182 _st[0] *= _st[1]; /* 0x3B004A33: fmul st(1) */ 3183 { double _v = fp_pop(); _st[1] -= _v; } /* 0x3B004A35: fsubp st(2) */ 3184 fp_xch(1); /* 0x3B004A37: fxch st(1) */ 3185 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x38) = _v; } /* 0x3B004A39: fstp dword ptr [ecx + 0x38] */ 3186 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004A3C: fstp st(0) */ 3187 ebp = POP32_VAL(esp); /* 0x3B004A3E: pop ebp */ 3188 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004A3F: ret 4 */ 3189 RECOMP_REGS_OUT(); 3190 } 3191 3192 void sub_3B004A50(void) { 3193 int _fpu_cmp = 0; 3194 uint32_t _cf = 0; 3195 int _df = 1; 3196 uint32_t _flag_k = FK_NONE; 3197 uint32_t _flag_a = 0, _flag_b = 0; 3198 uint32_t _itail_tgt = 0; 3199 RECOMP_REGS_LOCALS 3200 RECOMP_ENTER(0x3B004A50u); 3201 3202 L_3B004A50: 3203 PUSH32(esp, ebp); /* 0x3B004A50: push ebp */ 3204 ebp = esp; /* 0x3B004A51: mov ebp, esp */ 3205 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004A53: fld dword ptr [ebp + 8] */ 3206 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3B004A56: fcos */ 3207 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004A58: fld dword ptr [ebp + 8] */ 3208 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B004A5B: fsin */ 3209 fp_push(*(float*)&MEM32(ecx)); /* 0x3B004A5D: fld dword ptr [ecx] */ 3210 fp_push(_st[2]); /* 0x3B004A5F: fld st(2) */ 3211 _st[0] *= (double)*(float*)ADDR(ecx); /* 0x3B004A61: fmul dword ptr [ecx] */ 3212 fp_push(_st[2]); /* 0x3B004A63: fld st(2) */ 3213 _st[0] *= (double)*(float*)ADDR(ecx + 0x4); /* 0x3B004A65: fmul dword ptr [ecx + 4] */ 3214 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004A68: fsubp st(1) */ 3215 { float _v = (float)fp_pop(); *(float*)ADDR(ecx) = _v; } /* 0x3B004A6A: fstp dword ptr [ecx] */ 3216 _st[0] *= _st[1]; /* 0x3B004A6C: fmul st(1) */ 3217 fp_push(_st[2]); /* 0x3B004A6E: fld st(2) */ 3218 _st[0] *= (double)*(float*)ADDR(ecx + 0x4); /* 0x3B004A70: fmul dword ptr [ecx + 4] */ 3219 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004A73: faddp st(1) */ 3220 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x4) = _v; } /* 0x3B004A75: fstp dword ptr [ecx + 4] */ 3221 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B004A78: fld dword ptr [ecx + 0x10] */ 3222 fp_push(_st[2]); /* 0x3B004A7B: fld st(2) */ 3223 _st[0] *= (double)*(float*)ADDR(ecx + 0x10); /* 0x3B004A7D: fmul dword ptr [ecx + 0x10] */ 3224 fp_push(_st[2]); /* 0x3B004A80: fld st(2) */ 3225 _st[0] *= (double)*(float*)ADDR(ecx + 0x14); /* 0x3B004A82: fmul dword ptr [ecx + 0x14] */ 3226 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004A85: fsubp st(1) */ 3227 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x10) = _v; } /* 0x3B004A87: fstp dword ptr [ecx + 0x10] */ 3228 _st[0] *= _st[1]; /* 0x3B004A8A: fmul st(1) */ 3229 fp_push(_st[2]); /* 0x3B004A8C: fld st(2) */ 3230 _st[0] *= (double)*(float*)ADDR(ecx + 0x14); /* 0x3B004A8E: fmul dword ptr [ecx + 0x14] */ 3231 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004A91: faddp st(1) */ 3232 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x14) = _v; } /* 0x3B004A93: fstp dword ptr [ecx + 0x14] */ 3233 fp_push(*(float*)&MEM32(ecx + 0x20)); /* 0x3B004A96: fld dword ptr [ecx + 0x20] */ 3234 fp_push(_st[2]); /* 0x3B004A99: fld st(2) */ 3235 _st[0] *= (double)*(float*)ADDR(ecx + 0x20); /* 0x3B004A9B: fmul dword ptr [ecx + 0x20] */ 3236 fp_push(_st[2]); /* 0x3B004A9E: fld st(2) */ 3237 _st[0] *= (double)*(float*)ADDR(ecx + 0x24); /* 0x3B004AA0: fmul dword ptr [ecx + 0x24] */ 3238 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004AA3: fsubp st(1) */ 3239 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x20) = _v; } /* 0x3B004AA5: fstp dword ptr [ecx + 0x20] */ 3240 fp_push(_st[2]); /* 0x3B004AA8: fld st(2) */ 3241 _st[0] *= (double)*(float*)ADDR(ecx + 0x24); /* 0x3B004AAA: fmul dword ptr [ecx + 0x24] */ 3242 fp_xch(1); /* 0x3B004AAD: fxch st(1) */ 3243 _st[0] *= _st[2]; /* 0x3B004AAF: fmul st(2) */ 3244 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004AB1: faddp st(1) */ 3245 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x24) = _v; } /* 0x3B004AB3: fstp dword ptr [ecx + 0x24] */ 3246 fp_push(*(float*)&MEM32(ecx + 0x30)); /* 0x3B004AB6: fld dword ptr [ecx + 0x30] */ 3247 fp_push(_st[2]); /* 0x3B004AB9: fld st(2) */ 3248 _st[0] *= (double)*(float*)ADDR(ecx + 0x30); /* 0x3B004ABB: fmul dword ptr [ecx + 0x30] */ 3249 fp_push(_st[2]); /* 0x3B004ABE: fld st(2) */ 3250 _st[0] *= (double)*(float*)ADDR(ecx + 0x34); /* 0x3B004AC0: fmul dword ptr [ecx + 0x34] */ 3251 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004AC3: fsubp st(1) */ 3252 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x30) = _v; } /* 0x3B004AC5: fstp dword ptr [ecx + 0x30] */ 3253 fp_xch(2); /* 0x3B004AC8: fxch st(2) */ 3254 _st[0] *= (double)*(float*)ADDR(ecx + 0x34); /* 0x3B004ACA: fmul dword ptr [ecx + 0x34] */ 3255 fp_xch(2); /* 0x3B004ACD: fxch st(2) */ 3256 _st[0] *= _st[1]; /* 0x3B004ACF: fmul st(1) */ 3257 { double _v = fp_pop(); _st[1] += _v; } /* 0x3B004AD1: faddp st(2) */ 3258 fp_xch(1); /* 0x3B004AD3: fxch st(1) */ 3259 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x34) = _v; } /* 0x3B004AD5: fstp dword ptr [ecx + 0x34] */ 3260 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004AD8: fstp st(0) */ 3261 ebp = POP32_VAL(esp); /* 0x3B004ADA: pop ebp */ 3262 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004ADB: ret 4 */ 3263 RECOMP_REGS_OUT(); 3264 } 3265 3266 void sub_3B004AE0(void) { 3267 int _fpu_cmp = 0; 3268 uint32_t _cf = 0; 3269 int _df = 1; 3270 uint32_t _flag_k = FK_NONE; 3271 uint32_t _flag_a = 0, _flag_b = 0; 3272 uint32_t _itail_tgt = 0; 3273 RECOMP_REGS_LOCALS 3274 RECOMP_ENTER(0x3B004AE0u); 3275 3276 L_3B004AE0: 3277 PUSH32(esp, ebp); /* 0x3B004AE0: push ebp */ 3278 ebp = esp; /* 0x3B004AE1: mov ebp, esp */ 3279 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004AE3: fld dword ptr [ebp + 8] */ 3280 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3B004AE6: fcos */ 3281 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004AE8: fld dword ptr [ebp + 8] */ 3282 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B004AEB: fsin */ 3283 fp_push(*(float*)&MEM32(ecx + 0x14)); /* 0x3B004AED: fld dword ptr [ecx + 0x14] */ 3284 fp_push(_st[2]); /* 0x3B004AF0: fld st(2) */ 3285 _st[0] *= (double)*(float*)ADDR(ecx + 0x14); /* 0x3B004AF2: fmul dword ptr [ecx + 0x14] */ 3286 fp_push(_st[2]); /* 0x3B004AF5: fld st(2) */ 3287 _st[0] *= (double)*(float*)ADDR(ecx + 0x24); /* 0x3B004AF7: fmul dword ptr [ecx + 0x24] */ 3288 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004AFA: faddp st(1) */ 3289 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x14) = _v; } /* 0x3B004AFC: fstp dword ptr [ecx + 0x14] */ 3290 fp_push(_st[2]); /* 0x3B004AFF: fld st(2) */ 3291 _st[0] *= (double)*(float*)ADDR(ecx + 0x24); /* 0x3B004B01: fmul dword ptr [ecx + 0x24] */ 3292 fp_xch(1); /* 0x3B004B04: fxch st(1) */ 3293 _st[0] *= _st[2]; /* 0x3B004B06: fmul st(2) */ 3294 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004B08: fsubp st(1) */ 3295 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x24) = _v; } /* 0x3B004B0A: fstp dword ptr [ecx + 0x24] */ 3296 fp_push(*(float*)&MEM32(ecx + 0x18)); /* 0x3B004B0D: fld dword ptr [ecx + 0x18] */ 3297 fp_push(_st[2]); /* 0x3B004B10: fld st(2) */ 3298 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B004B12: fmul dword ptr [ecx + 0x18] */ 3299 fp_push(_st[2]); /* 0x3B004B15: fld st(2) */ 3300 _st[0] *= (double)*(float*)ADDR(ecx + 0x28); /* 0x3B004B17: fmul dword ptr [ecx + 0x28] */ 3301 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004B1A: faddp st(1) */ 3302 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x18) = _v; } /* 0x3B004B1C: fstp dword ptr [ecx + 0x18] */ 3303 fp_push(_st[2]); /* 0x3B004B1F: fld st(2) */ 3304 _st[0] *= (double)*(float*)ADDR(ecx + 0x28); /* 0x3B004B21: fmul dword ptr [ecx + 0x28] */ 3305 fp_xch(1); /* 0x3B004B24: fxch st(1) */ 3306 _st[0] *= _st[2]; /* 0x3B004B26: fmul st(2) */ 3307 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004B28: fsubp st(1) */ 3308 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x28) = _v; } /* 0x3B004B2A: fstp dword ptr [ecx + 0x28] */ 3309 fp_push(*(float*)&MEM32(ecx + 0x1C)); /* 0x3B004B2D: fld dword ptr [ecx + 0x1c] */ 3310 fp_push(_st[1]); /* 0x3B004B30: fld st(1) */ 3311 _st[0] *= (double)*(float*)ADDR(ecx + 0x2C); /* 0x3B004B32: fmul dword ptr [ecx + 0x2c] */ 3312 fp_push(_st[3]); /* 0x3B004B35: fld st(3) */ 3313 _st[0] *= (double)*(float*)ADDR(ecx + 0x1C); /* 0x3B004B37: fmul dword ptr [ecx + 0x1c] */ 3314 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004B3A: faddp st(1) */ 3315 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x1C) = _v; } /* 0x3B004B3C: fstp dword ptr [ecx + 0x1c] */ 3316 fp_push(_st[2]); /* 0x3B004B3F: fld st(2) */ 3317 _st[0] *= (double)*(float*)ADDR(ecx + 0x2C); /* 0x3B004B41: fmul dword ptr [ecx + 0x2c] */ 3318 fp_xch(1); /* 0x3B004B44: fxch st(1) */ 3319 _st[0] *= _st[2]; /* 0x3B004B46: fmul st(2) */ 3320 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004B48: fsubp st(1) */ 3321 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x2C) = _v; } /* 0x3B004B4A: fstp dword ptr [ecx + 0x2c] */ 3322 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B004B4D: fld dword ptr [ecx + 0x10] */ 3323 fp_push(_st[2]); /* 0x3B004B50: fld st(2) */ 3324 _st[0] *= (double)*(float*)ADDR(ecx + 0x10); /* 0x3B004B52: fmul dword ptr [ecx + 0x10] */ 3325 fp_push(_st[2]); /* 0x3B004B55: fld st(2) */ 3326 _st[0] *= (double)*(float*)ADDR(ecx + 0x20); /* 0x3B004B57: fmul dword ptr [ecx + 0x20] */ 3327 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004B5A: faddp st(1) */ 3328 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x10) = _v; } /* 0x3B004B5C: fstp dword ptr [ecx + 0x10] */ 3329 fp_xch(2); /* 0x3B004B5F: fxch st(2) */ 3330 _st[0] *= (double)*(float*)ADDR(ecx + 0x20); /* 0x3B004B61: fmul dword ptr [ecx + 0x20] */ 3331 fp_xch(2); /* 0x3B004B64: fxch st(2) */ 3332 _st[0] *= _st[1]; /* 0x3B004B66: fmul st(1) */ 3333 { double _v = fp_pop(); _st[1] -= _v; } /* 0x3B004B68: fsubp st(2) */ 3334 fp_xch(1); /* 0x3B004B6A: fxch st(1) */ 3335 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x20) = _v; } /* 0x3B004B6C: fstp dword ptr [ecx + 0x20] */ 3336 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004B6F: fstp st(0) */ 3337 ebp = POP32_VAL(esp); /* 0x3B004B71: pop ebp */ 3338 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004B72: ret 4 */ 3339 RECOMP_REGS_OUT(); 3340 } 3341 3342 void sub_3B004B80(void) { 3343 int _fpu_cmp = 0; 3344 uint32_t _cf = 0; 3345 int _df = 1; 3346 uint32_t _flag_k = FK_NONE; 3347 uint32_t _flag_a = 0, _flag_b = 0; 3348 uint32_t _itail_tgt = 0; 3349 RECOMP_REGS_LOCALS 3350 RECOMP_ENTER(0x3B004B80u); 3351 3352 L_3B004B80: 3353 PUSH32(esp, ebp); /* 0x3B004B80: push ebp */ 3354 ebp = esp; /* 0x3B004B81: mov ebp, esp */ 3355 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004B83: fld dword ptr [ebp + 8] */ 3356 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3B004B86: fcos */ 3357 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004B88: fld dword ptr [ebp + 8] */ 3358 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B004B8B: fsin */ 3359 fp_push(*(float*)&MEM32(ecx)); /* 0x3B004B8D: fld dword ptr [ecx] */ 3360 fp_push(_st[2]); /* 0x3B004B8F: fld st(2) */ 3361 _st[0] *= (double)*(float*)ADDR(ecx); /* 0x3B004B91: fmul dword ptr [ecx] */ 3362 fp_push(_st[2]); /* 0x3B004B93: fld st(2) */ 3363 _st[0] *= (double)*(float*)ADDR(ecx + 0x20); /* 0x3B004B95: fmul dword ptr [ecx + 0x20] */ 3364 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004B98: fsubp st(1) */ 3365 { float _v = (float)fp_pop(); *(float*)ADDR(ecx) = _v; } /* 0x3B004B9A: fstp dword ptr [ecx] */ 3366 _st[0] *= _st[1]; /* 0x3B004B9C: fmul st(1) */ 3367 fp_push(_st[2]); /* 0x3B004B9E: fld st(2) */ 3368 _st[0] *= (double)*(float*)ADDR(ecx + 0x20); /* 0x3B004BA0: fmul dword ptr [ecx + 0x20] */ 3369 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004BA3: faddp st(1) */ 3370 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x20) = _v; } /* 0x3B004BA5: fstp dword ptr [ecx + 0x20] */ 3371 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B004BA8: fld dword ptr [ecx + 8] */ 3372 fp_push(_st[2]); /* 0x3B004BAB: fld st(2) */ 3373 _st[0] *= (double)*(float*)ADDR(ecx + 0x8); /* 0x3B004BAD: fmul dword ptr [ecx + 8] */ 3374 fp_push(_st[2]); /* 0x3B004BB0: fld st(2) */ 3375 _st[0] *= (double)*(float*)ADDR(ecx + 0x28); /* 0x3B004BB2: fmul dword ptr [ecx + 0x28] */ 3376 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004BB5: fsubp st(1) */ 3377 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x8) = _v; } /* 0x3B004BB7: fstp dword ptr [ecx + 8] */ 3378 _st[0] *= _st[1]; /* 0x3B004BBA: fmul st(1) */ 3379 fp_push(_st[2]); /* 0x3B004BBC: fld st(2) */ 3380 _st[0] *= (double)*(float*)ADDR(ecx + 0x28); /* 0x3B004BBE: fmul dword ptr [ecx + 0x28] */ 3381 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004BC1: faddp st(1) */ 3382 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x28) = _v; } /* 0x3B004BC3: fstp dword ptr [ecx + 0x28] */ 3383 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x3B004BC6: fld dword ptr [ecx + 4] */ 3384 fp_push(_st[2]); /* 0x3B004BC9: fld st(2) */ 3385 _st[0] *= (double)*(float*)ADDR(ecx + 0x4); /* 0x3B004BCB: fmul dword ptr [ecx + 4] */ 3386 fp_push(_st[2]); /* 0x3B004BCE: fld st(2) */ 3387 _st[0] *= (double)*(float*)ADDR(ecx + 0x24); /* 0x3B004BD0: fmul dword ptr [ecx + 0x24] */ 3388 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004BD3: fsubp st(1) */ 3389 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x4) = _v; } /* 0x3B004BD5: fstp dword ptr [ecx + 4] */ 3390 fp_push(_st[2]); /* 0x3B004BD8: fld st(2) */ 3391 _st[0] *= (double)*(float*)ADDR(ecx + 0x24); /* 0x3B004BDA: fmul dword ptr [ecx + 0x24] */ 3392 fp_xch(1); /* 0x3B004BDD: fxch st(1) */ 3393 _st[0] *= _st[2]; /* 0x3B004BDF: fmul st(2) */ 3394 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004BE1: faddp st(1) */ 3395 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x24) = _v; } /* 0x3B004BE3: fstp dword ptr [ecx + 0x24] */ 3396 fp_push(*(float*)&MEM32(ecx + 0xC)); /* 0x3B004BE6: fld dword ptr [ecx + 0xc] */ 3397 fp_push(_st[2]); /* 0x3B004BE9: fld st(2) */ 3398 _st[0] *= (double)*(float*)ADDR(ecx + 0xC); /* 0x3B004BEB: fmul dword ptr [ecx + 0xc] */ 3399 fp_push(_st[2]); /* 0x3B004BEE: fld st(2) */ 3400 _st[0] *= (double)*(float*)ADDR(ecx + 0x2C); /* 0x3B004BF0: fmul dword ptr [ecx + 0x2c] */ 3401 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004BF3: fsubp st(1) */ 3402 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0xC) = _v; } /* 0x3B004BF5: fstp dword ptr [ecx + 0xc] */ 3403 fp_xch(2); /* 0x3B004BF8: fxch st(2) */ 3404 _st[0] *= (double)*(float*)ADDR(ecx + 0x2C); /* 0x3B004BFA: fmul dword ptr [ecx + 0x2c] */ 3405 fp_xch(2); /* 0x3B004BFD: fxch st(2) */ 3406 _st[0] *= _st[1]; /* 0x3B004BFF: fmul st(1) */ 3407 { double _v = fp_pop(); _st[1] += _v; } /* 0x3B004C01: faddp st(2) */ 3408 fp_xch(1); /* 0x3B004C03: fxch st(1) */ 3409 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x2C) = _v; } /* 0x3B004C05: fstp dword ptr [ecx + 0x2c] */ 3410 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004C08: fstp st(0) */ 3411 ebp = POP32_VAL(esp); /* 0x3B004C0A: pop ebp */ 3412 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004C0B: ret 4 */ 3413 RECOMP_REGS_OUT(); 3414 } 3415 3416 void sub_3B004C10(void) { 3417 int _fpu_cmp = 0; 3418 uint32_t _cf = 0; 3419 int _df = 1; 3420 uint32_t _flag_k = FK_NONE; 3421 uint32_t _flag_a = 0, _flag_b = 0; 3422 uint32_t _itail_tgt = 0; 3423 RECOMP_REGS_LOCALS 3424 RECOMP_ENTER(0x3B004C10u); 3425 3426 L_3B004C10: 3427 PUSH32(esp, ebp); /* 0x3B004C10: push ebp */ 3428 ebp = esp; /* 0x3B004C11: mov ebp, esp */ 3429 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004C13: fld dword ptr [ebp + 8] */ 3430 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3B004C16: fcos */ 3431 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004C18: fld dword ptr [ebp + 8] */ 3432 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B004C1B: fsin */ 3433 fp_push(*(float*)&MEM32(ecx)); /* 0x3B004C1D: fld dword ptr [ecx] */ 3434 fp_push(_st[1]); /* 0x3B004C1F: fld st(1) */ 3435 _st[0] *= (double)*(float*)ADDR(ecx + 0x10); /* 0x3B004C21: fmul dword ptr [ecx + 0x10] */ 3436 fp_push(_st[3]); /* 0x3B004C24: fld st(3) */ 3437 _st[0] *= (double)*(float*)ADDR(ecx); /* 0x3B004C26: fmul dword ptr [ecx] */ 3438 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004C28: faddp st(1) */ 3439 { float _v = (float)fp_pop(); *(float*)ADDR(ecx) = _v; } /* 0x3B004C2A: fstp dword ptr [ecx] */ 3440 fp_push(_st[2]); /* 0x3B004C2C: fld st(2) */ 3441 _st[0] *= (double)*(float*)ADDR(ecx + 0x10); /* 0x3B004C2E: fmul dword ptr [ecx + 0x10] */ 3442 fp_xch(1); /* 0x3B004C31: fxch st(1) */ 3443 _st[0] *= _st[2]; /* 0x3B004C33: fmul st(2) */ 3444 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004C35: fsubp st(1) */ 3445 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x10) = _v; } /* 0x3B004C37: fstp dword ptr [ecx + 0x10] */ 3446 fp_push(*(float*)&MEM32(ecx + 0x4)); /* 0x3B004C3A: fld dword ptr [ecx + 4] */ 3447 fp_push(_st[1]); /* 0x3B004C3D: fld st(1) */ 3448 _st[0] *= (double)*(float*)ADDR(ecx + 0x14); /* 0x3B004C3F: fmul dword ptr [ecx + 0x14] */ 3449 fp_push(_st[3]); /* 0x3B004C42: fld st(3) */ 3450 _st[0] *= (double)*(float*)ADDR(ecx + 0x4); /* 0x3B004C44: fmul dword ptr [ecx + 4] */ 3451 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004C47: faddp st(1) */ 3452 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x4) = _v; } /* 0x3B004C49: fstp dword ptr [ecx + 4] */ 3453 fp_push(_st[2]); /* 0x3B004C4C: fld st(2) */ 3454 _st[0] *= (double)*(float*)ADDR(ecx + 0x14); /* 0x3B004C4E: fmul dword ptr [ecx + 0x14] */ 3455 fp_xch(1); /* 0x3B004C51: fxch st(1) */ 3456 _st[0] *= _st[2]; /* 0x3B004C53: fmul st(2) */ 3457 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004C55: fsubp st(1) */ 3458 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x14) = _v; } /* 0x3B004C57: fstp dword ptr [ecx + 0x14] */ 3459 fp_push(*(float*)&MEM32(ecx + 0x8)); /* 0x3B004C5A: fld dword ptr [ecx + 8] */ 3460 fp_push(_st[2]); /* 0x3B004C5D: fld st(2) */ 3461 _st[0] *= (double)*(float*)ADDR(ecx + 0x8); /* 0x3B004C5F: fmul dword ptr [ecx + 8] */ 3462 fp_push(_st[2]); /* 0x3B004C62: fld st(2) */ 3463 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B004C64: fmul dword ptr [ecx + 0x18] */ 3464 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004C67: faddp st(1) */ 3465 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x8) = _v; } /* 0x3B004C69: fstp dword ptr [ecx + 8] */ 3466 fp_push(_st[2]); /* 0x3B004C6C: fld st(2) */ 3467 _st[0] *= (double)*(float*)ADDR(ecx + 0x18); /* 0x3B004C6E: fmul dword ptr [ecx + 0x18] */ 3468 fp_xch(1); /* 0x3B004C71: fxch st(1) */ 3469 _st[0] *= _st[2]; /* 0x3B004C73: fmul st(2) */ 3470 { double _v = fp_pop(); _st[0] -= _v; } /* 0x3B004C75: fsubp st(1) */ 3471 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x18) = _v; } /* 0x3B004C77: fstp dword ptr [ecx + 0x18] */ 3472 fp_push(*(float*)&MEM32(ecx + 0xC)); /* 0x3B004C7A: fld dword ptr [ecx + 0xc] */ 3473 fp_push(_st[2]); /* 0x3B004C7D: fld st(2) */ 3474 _st[0] *= (double)*(float*)ADDR(ecx + 0xC); /* 0x3B004C7F: fmul dword ptr [ecx + 0xc] */ 3475 fp_push(_st[2]); /* 0x3B004C82: fld st(2) */ 3476 _st[0] *= (double)*(float*)ADDR(ecx + 0x1C); /* 0x3B004C84: fmul dword ptr [ecx + 0x1c] */ 3477 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004C87: faddp st(1) */ 3478 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0xC) = _v; } /* 0x3B004C89: fstp dword ptr [ecx + 0xc] */ 3479 fp_xch(2); /* 0x3B004C8C: fxch st(2) */ 3480 _st[0] *= (double)*(float*)ADDR(ecx + 0x1C); /* 0x3B004C8E: fmul dword ptr [ecx + 0x1c] */ 3481 fp_xch(2); /* 0x3B004C91: fxch st(2) */ 3482 _st[0] *= _st[1]; /* 0x3B004C93: fmul st(1) */ 3483 { double _v = fp_pop(); _st[1] -= _v; } /* 0x3B004C95: fsubp st(2) */ 3484 fp_xch(1); /* 0x3B004C97: fxch st(1) */ 3485 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x1C) = _v; } /* 0x3B004C99: fstp dword ptr [ecx + 0x1c] */ 3486 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004C9C: fstp st(0) */ 3487 ebp = POP32_VAL(esp); /* 0x3B004C9E: pop ebp */ 3488 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004C9F: ret 4 */ 3489 RECOMP_REGS_OUT(); 3490 } 3491 3492 void sub_3B004CB0(void) { 3493 int _fpu_cmp = 0; 3494 uint32_t _cf = 0; 3495 int _df = 1; 3496 uint32_t _flag_k = FK_NONE; 3497 uint32_t _flag_a = 0, _flag_b = 0; 3498 uint32_t _itail_tgt = 0; 3499 RECOMP_REGS_LOCALS 3500 RECOMP_ENTER(0x3B004CB0u); 3501 3502 L_3B004CB0: 3503 PUSH32(esp, ebp); /* 0x3B004CB0: push ebp */ 3504 ebp = esp; /* 0x3B004CB1: mov ebp, esp */ 3505 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x10u); 3506 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3507 esp = esp - 0x10u; /* 0x3B004CB3: sub esp, 0x10 */ 3508 _flag_k = FK_CMP; 3509 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004CB6: fld dword ptr [ebp + 8] */ 3510 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3B004CB9: fcos */ 3511 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 3512 eax = 0; /* 0x3B004CBB: xor eax, eax */ 3513 _cf = 0; 3514 _flag_k = FK_TEST; 3515 MEM32(ecx + 0x3C) = 0x3F800000u; /* 0x3B004CBD: mov dword ptr [ecx + 0x3c], 0x3f800000 */ 3516 MEM32(ecx + 0xC) = eax; /* 0x3B004CC4: mov dword ptr [ecx + 0xc], eax */ 3517 MEM32(ecx + 0x1C) = eax; /* 0x3B004CC7: mov dword ptr [ecx + 0x1c], eax */ 3518 MEM32(ecx + 0x2C) = eax; /* 0x3B004CCA: mov dword ptr [ecx + 0x2c], eax */ 3519 MEM32(ecx + 0x30) = eax; /* 0x3B004CCD: mov dword ptr [ecx + 0x30], eax */ 3520 MEM32(ecx + 0x34) = eax; /* 0x3B004CD0: mov dword ptr [ecx + 0x34], eax */ 3521 MEM32(ecx + 0x38) = eax; /* 0x3B004CD3: mov dword ptr [ecx + 0x38], eax */ 3522 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004CD6: fld dword ptr [ebp + 8] */ 3523 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B004CD9: fsin */ 3524 fp_push(*(float*)&MEM32(ebp + 0xC)); /* 0x3B004CDB: fld dword ptr [ebp + 0xc] */ 3525 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3B004CDE: fcos */ 3526 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3B004CE0: fstp dword ptr [ebp - 4] */ 3527 fp_push(*(float*)&MEM32(ebp + 0xC)); /* 0x3B004CE3: fld dword ptr [ebp + 0xc] */ 3528 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B004CE6: fsin */ 3529 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3B004CE8: fstp dword ptr [ebp + 8] */ 3530 fp_push(*(float*)&MEM32(ebp + 0x10)); /* 0x3B004CEB: fld dword ptr [ebp + 0x10] */ 3531 _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3B004CEE: fcos */ 3532 fp_push(*(float*)&MEM32(ebp + 0x10)); /* 0x3B004CF0: fld dword ptr [ebp + 0x10] */ 3533 _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3B004CF3: fsin */ 3534 { float _v = (float)_st[0]; *(float*)ADDR(ebp + 0xC) = _v; } /* 0x3B004CF5: fst dword ptr [ebp + 0xc] */ 3535 _st[0] *= _st[3]; /* 0x3B004CF8: fmul st(3) */ 3536 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3B004CFA: fstp dword ptr [ebp - 0xc] */ 3537 fp_push(*(float*)&MEM32(ebp + 0xC)); /* 0x3B004CFD: fld dword ptr [ebp + 0xc] */ 3538 _st[0] *= _st[2]; /* 0x3B004D00: fmul st(2) */ 3539 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3B004D02: fstp dword ptr [ebp - 8] */ 3540 fp_push(_st[0]); /* 0x3B004D05: fld st(0) */ 3541 _st[0] *= _st[3]; /* 0x3B004D07: fmul st(3) */ 3542 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x10) = _v; } /* 0x3B004D09: fstp dword ptr [ebp + 0x10] */ 3543 fp_push(_st[0]); /* 0x3B004D0C: fld st(0) */ 3544 _st[0] *= _st[2]; /* 0x3B004D0E: fmul st(2) */ 3545 { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3B004D10: fstp dword ptr [ebp - 0x10] */ 3546 _st[0] *= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B004D13: fmul dword ptr [ebp - 4] */ 3547 { float _v = (float)fp_pop(); *(float*)ADDR(ecx) = _v; } /* 0x3B004D16: fstp dword ptr [ecx] */ 3548 fp_push(*(float*)&MEM32(ebp + 0xC)); /* 0x3B004D18: fld dword ptr [ebp + 0xc] */ 3549 _st[0] *= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3B004D1B: fmul dword ptr [ebp - 4] */ 3550 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x4) = _v; } /* 0x3B004D1E: fstp dword ptr [ecx + 4] */ 3551 fp_push(*(float*)&MEM32(ebp + 0x8)); /* 0x3B004D21: fld dword ptr [ebp + 8] */ 3552 _st[0] = -_st[0]; /* 0x3B004D24: fchs */ 3553 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x8) = _v; } /* 0x3B004D26: fstp dword ptr [ecx + 8] */ 3554 fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x3B004D29: fld dword ptr [ebp - 0x10] */ 3555 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B004D2C: fmul dword ptr [ebp + 8] */ 3556 _st[0] -= (double)*(float*)ADDR(ebp + (-0xC)); /* 0x3B004D2F: fsub dword ptr [ebp - 0xc] */ 3557 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x10) = _v; } /* 0x3B004D32: fstp dword ptr [ecx + 0x10] */ 3558 fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3B004D35: fld dword ptr [ebp - 8] */ 3559 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B004D38: fmul dword ptr [ebp + 8] */ 3560 _st[0] += (double)*(float*)ADDR(ebp + 0x10); /* 0x3B004D3B: fadd dword ptr [ebp + 0x10] */ 3561 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x14) = _v; } /* 0x3B004D3E: fstp dword ptr [ecx + 0x14] */ 3562 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B004D41: fld dword ptr [ebp - 4] */ 3563 _st[0] *= _st[1]; /* 0x3B004D44: fmul st(1) */ 3564 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x18) = _v; } /* 0x3B004D46: fstp dword ptr [ecx + 0x18] */ 3565 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004D49: fstp st(0) */ 3566 fp_push(*(float*)&MEM32(ebp + 0x10)); /* 0x3B004D4B: fld dword ptr [ebp + 0x10] */ 3567 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B004D4E: fmul dword ptr [ebp + 8] */ 3568 _st[0] += (double)*(float*)ADDR(ebp + (-0x8)); /* 0x3B004D51: fadd dword ptr [ebp - 8] */ 3569 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x20) = _v; } /* 0x3B004D54: fstp dword ptr [ecx + 0x20] */ 3570 fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3B004D57: fld dword ptr [ebp - 0xc] */ 3571 _st[0] *= (double)*(float*)ADDR(ebp + 0x8); /* 0x3B004D5A: fmul dword ptr [ebp + 8] */ 3572 _st[0] -= (double)*(float*)ADDR(ebp + (-0x10)); /* 0x3B004D5D: fsub dword ptr [ebp - 0x10] */ 3573 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x24) = _v; } /* 0x3B004D60: fstp dword ptr [ecx + 0x24] */ 3574 fp_push(*(float*)&MEM32(ebp + (-0x4))); /* 0x3B004D63: fld dword ptr [ebp - 4] */ 3575 _st[0] *= _st[1]; /* 0x3B004D66: fmul st(1) */ 3576 { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x28) = _v; } /* 0x3B004D68: fstp dword ptr [ecx + 0x28] */ 3577 { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3B004D6B: fstp st(0) */ 3578 esp = ebp; /* 0x3B004D6D: mov esp, ebp */ 3579 ebp = POP32_VAL(esp); /* 0x3B004D6F: pop ebp */ 3580 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3B004D70: ret 0xc */ 3581 RECOMP_REGS_OUT(); 3582 } 3583 3584 void sub_3B004D80(void) { 3585 int _fpu_cmp = 0; 3586 uint32_t _cf = 0; 3587 int _df = 1; 3588 uint32_t _flag_k = FK_NONE; 3589 uint32_t _flag_a = 0, _flag_b = 0; 3590 uint32_t _itail_tgt = 0; 3591 RECOMP_REGS_LOCALS 3592 RECOMP_ENTER(0x3B004D80u); 3593 3594 L_3B004D80: 3595 PUSH32(esp, ebp); /* 0x3B004D80: push ebp */ 3596 ebp = esp; /* 0x3B004D81: mov ebp, esp */ 3597 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x44u); 3598 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3599 esp = esp - 0x44u; /* 0x3B004D83: sub esp, 0x44 */ 3600 _flag_k = FK_CMP; 3601 PUSH32(esp, ebx); /* 0x3B004D86: push ebx */ 3602 PUSH32(esp, esi); /* 0x3B004D87: push esi */ 3603 MEM32(ebp + (-0x4)) = 0; /* 0x3B004D88: mov dword ptr [ebp - 4], 0 */ 3604 PUSH32(esp, edi); /* 0x3B004D8F: push edi */ 3605 MEM32(ebp + (-0x44)) = 0x3F800000u; /* 0x3B004D90: mov dword ptr [ebp - 0x44], 0x3f800000 */ 3606 MEM32(ebp + (-0x40)) = 0; /* 0x3B004D97: mov dword ptr [ebp - 0x40], 0 */ 3607 MEM32(ebp + (-0x3C)) = 0; /* 0x3B004D9E: mov dword ptr [ebp - 0x3c], 0 */ 3608 MEM32(ebp + (-0x38)) = 0; /* 0x3B004DA5: mov dword ptr [ebp - 0x38], 0 */ 3609 MEM32(ebp + (-0x34)) = 0; /* 0x3B004DAC: mov dword ptr [ebp - 0x34], 0 */ 3610 MEM32(ebp + (-0x30)) = 0x3F800000u; /* 0x3B004DB3: mov dword ptr [ebp - 0x30], 0x3f800000 */ 3611 MEM32(ebp + (-0x2C)) = 0; /* 0x3B004DBA: mov dword ptr [ebp - 0x2c], 0 */ 3612 MEM32(ebp + (-0x28)) = 0; /* 0x3B004DC1: mov dword ptr [ebp - 0x28], 0 */ 3613 MEM32(ebp + (-0x24)) = 0; /* 0x3B004DC8: mov dword ptr [ebp - 0x24], 0 */ 3614 MEM32(ebp + (-0x20)) = 0; /* 0x3B004DCF: mov dword ptr [ebp - 0x20], 0 */ 3615 MEM32(ebp + (-0x1C)) = 0x3F800000u; /* 0x3B004DD6: mov dword ptr [ebp - 0x1c], 0x3f800000 */ 3616 MEM32(ebp + (-0x18)) = 0; /* 0x3B004DDD: mov dword ptr [ebp - 0x18], 0 */ 3617 MEM32(ebp + (-0x14)) = 0; /* 0x3B004DE4: mov dword ptr [ebp - 0x14], 0 */ 3618 MEM32(ebp + (-0x10)) = 0; /* 0x3B004DEB: mov dword ptr [ebp - 0x10], 0 */ 3619 MEM32(ebp + (-0xC)) = 0; /* 0x3B004DF2: mov dword ptr [ebp - 0xc], 0 */ 3620 MEM32(ebp + (-0x8)) = 0x3F800000u; /* 0x3B004DF9: mov dword ptr [ebp - 8], 0x3f800000 */ 3621 ebx = ebp + (-0x44); /* 0x3B004E00: lea ebx, [ebp - 0x44] */ 3622 edx = ecx + 0x4; /* 0x3B004E03: lea edx, [ecx + 4] */ 3623 MEM32(ebp + (-0x4)) = 3; /* 0x3B004E06: mov dword ptr [ebp - 4], 3 */ 3624 L_3B004E0D: 3625 eax = MEM32(ebp + 0xC); /* 0x3B004E0D: mov eax, dword ptr [ebp + 0xc] */ 3626 esi = ebx; /* 0x3B004E10: mov esi, ebx */ 3627 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x10u); 3628 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3629 eax = eax + 0x10u; /* 0x3B004E12: add eax, 0x10 */ 3630 _flag_k = FK_ADD; 3631 edi = 3; /* 0x3B004E15: mov edi, 3 */ 3632 L_3B004E1A: 3633 fp_push(*(float*)&MEM32(eax + (-0x10))); /* 0x3B004E1A: fld dword ptr [eax - 0x10] */ 3634 _st[0] *= (double)*(float*)ADDR(edx + (-0x4)); /* 0x3B004E1D: fmul dword ptr [edx - 4] */ 3635 fp_push(*(float*)&MEM32(eax + 0x10)); /* 0x3B004E20: fld dword ptr [eax + 0x10] */ 3636 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B004E23: fmul dword ptr [edx + 4] */ 3637 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4); 3638 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3639 eax = eax + 4; /* 0x3B004E26: add eax, 4 */ 3640 _flag_k = FK_ADD; 3641 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(4); 3642 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3643 esi = esi + 4; /* 0x3B004E29: add esi, 4 */ 3644 _flag_k = FK_ADD; 3645 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(1); 3646 edi = edi - 1; /* 0x3B004E2C: dec edi */ 3647 _flag_k = FK_DEC; 3648 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004E2D: faddp st(1) */ 3649 fp_push(*(float*)&MEM32(eax + (-0x4))); /* 0x3B004E2F: fld dword ptr [eax - 4] */ 3650 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B004E32: fmul dword ptr [edx] */ 3651 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004E34: faddp st(1) */ 3652 { float _v = (float)fp_pop(); *(float*)ADDR(esi + (-0x4)) = _v; } /* 0x3B004E36: fstp dword ptr [esi - 4] */ 3653 RECOMP_BACKEDGE(); 3654 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004E1A; /* 0x3B004E39: jne 0x3b004e1a */ 3655 L_3B004E3B: 3656 eax = MEM32(ebp + (-0x4)); /* 0x3B004E3B: mov eax, dword ptr [ebp - 4] */ 3657 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u); 3658 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3659 edx = edx + 0x10u; /* 0x3B004E3E: add edx, 0x10 */ 3660 _flag_k = FK_ADD; 3661 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0x10u); 3662 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3663 ebx = ebx + 0x10u; /* 0x3B004E41: add ebx, 0x10 */ 3664 _flag_k = FK_ADD; 3665 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1); 3666 eax = eax - 1; /* 0x3B004E44: dec eax */ 3667 _flag_k = FK_DEC; 3668 MEM32(ebp + (-0x4)) = eax; /* 0x3B004E45: mov dword ptr [ebp - 4], eax */ 3669 RECOMP_BACKEDGE(); 3670 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004E0D; /* 0x3B004E48: jne 0x3b004e0d */ 3671 L_3B004E4A: 3672 esi = MEM32(ebp + 0xC); /* 0x3B004E4A: mov esi, dword ptr [ebp + 0xc] */ 3673 edx = ebp + (-0x24); /* 0x3B004E4D: lea edx, [ebp - 0x24] */ 3674 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(esi); 3675 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3676 edx = edx - esi; /* 0x3B004E50: sub edx, esi */ 3677 _flag_k = FK_CMP; 3678 eax = esi + 0x10; /* 0x3B004E52: lea eax, [esi + 0x10] */ 3679 esi = 3; /* 0x3B004E55: mov esi, 3 */ 3680 L_3B004E5A: 3681 fp_push(*(float*)&MEM32(eax + 0x10)); /* 0x3B004E5A: fld dword ptr [eax + 0x10] */ 3682 _st[0] *= (double)*(float*)ADDR(ecx + 0x38); /* 0x3B004E5D: fmul dword ptr [ecx + 0x38] */ 3683 fp_push(*(float*)&MEM32(eax + (-0x10))); /* 0x3B004E60: fld dword ptr [eax - 0x10] */ 3684 _st[0] *= (double)*(float*)ADDR(ecx + 0x30); /* 0x3B004E63: fmul dword ptr [ecx + 0x30] */ 3685 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4); 3686 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3687 eax = eax + 4; /* 0x3B004E66: add eax, 4 */ 3688 _flag_k = FK_ADD; 3689 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1); 3690 esi = esi - 1; /* 0x3B004E69: dec esi */ 3691 _flag_k = FK_DEC; 3692 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004E6A: faddp st(1) */ 3693 fp_push(*(float*)&MEM32(eax + (-0x4))); /* 0x3B004E6C: fld dword ptr [eax - 4] */ 3694 _st[0] *= (double)*(float*)ADDR(ecx + 0x34); /* 0x3B004E6F: fmul dword ptr [ecx + 0x34] */ 3695 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004E72: faddp st(1) */ 3696 _st[0] += (double)*(float*)ADDR(eax + 0x1C); /* 0x3B004E74: fadd dword ptr [eax + 0x1c] */ 3697 { float _v = (float)fp_pop(); *(float*)ADDR(edx + eax + (-0x4)) = _v; } /* 0x3B004E77: fstp dword ptr [edx + eax - 4] */ 3698 RECOMP_BACKEDGE(); 3699 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004E5A; /* 0x3B004E7B: jne 0x3b004e5a */ 3700 L_3B004E7D: 3701 eax = MEM32(ebp + 0x8); /* 0x3B004E7D: mov eax, dword ptr [ebp + 8] */ 3702 ecx = 0x10u; /* 0x3B004E80: mov ecx, 0x10 */ 3703 esi = ebp + (-0x44); /* 0x3B004E85: lea esi, [ebp - 0x44] */ 3704 edi = eax; /* 0x3B004E88: mov edi, eax */ 3705 if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3B004E8A: rep movsd dword ptr es:[edi], dword ptr [esi] */ if (_df > 0) { memmove((void*)ADDR(edi), (void*)ADDR(esi), _b); esi += _b; edi += _b; } else { memmove((void*)ADDR(edi - _b + 4u), (void*)ADDR(esi - _b + 4u), _b); esi -= _b; edi -= _b; } ecx = 0; } 3706 edi = POP32_VAL(esp); /* 0x3B004E8C: pop edi */ 3707 esi = POP32_VAL(esp); /* 0x3B004E8D: pop esi */ 3708 ebx = POP32_VAL(esp); /* 0x3B004E8E: pop ebx */ 3709 esp = ebp; /* 0x3B004E8F: mov esp, ebp */ 3710 ebp = POP32_VAL(esp); /* 0x3B004E91: pop ebp */ 3711 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3B004E92: ret 8 */ 3712 RECOMP_REGS_OUT(); 3713 } 3714 3715 void sub_3B004DE4(void) { 3716 int _fpu_cmp = 0; 3717 uint32_t _cf = 0; 3718 int _df = 1; 3719 uint32_t _flag_k = FK_NONE; 3720 uint32_t _flag_a = 0, _flag_b = 0; 3721 uint32_t _itail_tgt = 0; 3722 RECOMP_REGS_LOCALS 3723 RECOMP_ENTER(0x3B004DE4u); 3724 3725 L_3B004DE4: 3726 MEM32(ebp + (-0x14)) = 0; /* 0x3B004DE4: mov dword ptr [ebp - 0x14], 0 */ 3727 MEM32(ebp + (-0x10)) = 0; /* 0x3B004DEB: mov dword ptr [ebp - 0x10], 0 */ 3728 MEM32(ebp + (-0xC)) = 0; /* 0x3B004DF2: mov dword ptr [ebp - 0xc], 0 */ 3729 MEM32(ebp + (-0x8)) = 0x3F800000u; /* 0x3B004DF9: mov dword ptr [ebp - 8], 0x3f800000 */ 3730 ebx = ebp + (-0x44); /* 0x3B004E00: lea ebx, [ebp - 0x44] */ 3731 edx = ecx + 0x4; /* 0x3B004E03: lea edx, [ecx + 4] */ 3732 MEM32(ebp + (-0x4)) = 3; /* 0x3B004E06: mov dword ptr [ebp - 4], 3 */ 3733 L_3B004E0D: 3734 eax = MEM32(ebp + 0xC); /* 0x3B004E0D: mov eax, dword ptr [ebp + 0xc] */ 3735 esi = ebx; /* 0x3B004E10: mov esi, ebx */ 3736 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x10u); 3737 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3738 eax = eax + 0x10u; /* 0x3B004E12: add eax, 0x10 */ 3739 _flag_k = FK_ADD; 3740 edi = 3; /* 0x3B004E15: mov edi, 3 */ 3741 L_3B004E1A: 3742 fp_push(*(float*)&MEM32(eax + (-0x10))); /* 0x3B004E1A: fld dword ptr [eax - 0x10] */ 3743 _st[0] *= (double)*(float*)ADDR(edx + (-0x4)); /* 0x3B004E1D: fmul dword ptr [edx - 4] */ 3744 fp_push(*(float*)&MEM32(eax + 0x10)); /* 0x3B004E20: fld dword ptr [eax + 0x10] */ 3745 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B004E23: fmul dword ptr [edx + 4] */ 3746 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4); 3747 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3748 eax = eax + 4; /* 0x3B004E26: add eax, 4 */ 3749 _flag_k = FK_ADD; 3750 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(4); 3751 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3752 esi = esi + 4; /* 0x3B004E29: add esi, 4 */ 3753 _flag_k = FK_ADD; 3754 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(1); 3755 edi = edi - 1; /* 0x3B004E2C: dec edi */ 3756 _flag_k = FK_DEC; 3757 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004E2D: faddp st(1) */ 3758 fp_push(*(float*)&MEM32(eax + (-0x4))); /* 0x3B004E2F: fld dword ptr [eax - 4] */ 3759 _st[0] *= (double)*(float*)ADDR(edx); /* 0x3B004E32: fmul dword ptr [edx] */ 3760 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004E34: faddp st(1) */ 3761 { float _v = (float)fp_pop(); *(float*)ADDR(esi + (-0x4)) = _v; } /* 0x3B004E36: fstp dword ptr [esi - 4] */ 3762 RECOMP_BACKEDGE(); 3763 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004E1A; /* 0x3B004E39: jne 0x3b004e1a */ 3764 L_3B004E3B: 3765 eax = MEM32(ebp + (-0x4)); /* 0x3B004E3B: mov eax, dword ptr [ebp - 4] */ 3766 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u); 3767 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3768 edx = edx + 0x10u; /* 0x3B004E3E: add edx, 0x10 */ 3769 _flag_k = FK_ADD; 3770 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0x10u); 3771 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3772 ebx = ebx + 0x10u; /* 0x3B004E41: add ebx, 0x10 */ 3773 _flag_k = FK_ADD; 3774 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1); 3775 eax = eax - 1; /* 0x3B004E44: dec eax */ 3776 _flag_k = FK_DEC; 3777 MEM32(ebp + (-0x4)) = eax; /* 0x3B004E45: mov dword ptr [ebp - 4], eax */ 3778 RECOMP_BACKEDGE(); 3779 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004E0D; /* 0x3B004E48: jne 0x3b004e0d */ 3780 L_3B004E4A: 3781 esi = MEM32(ebp + 0xC); /* 0x3B004E4A: mov esi, dword ptr [ebp + 0xc] */ 3782 edx = ebp + (-0x24); /* 0x3B004E4D: lea edx, [ebp - 0x24] */ 3783 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(esi); 3784 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3785 edx = edx - esi; /* 0x3B004E50: sub edx, esi */ 3786 _flag_k = FK_CMP; 3787 eax = esi + 0x10; /* 0x3B004E52: lea eax, [esi + 0x10] */ 3788 esi = 3; /* 0x3B004E55: mov esi, 3 */ 3789 L_3B004E5A: 3790 fp_push(*(float*)&MEM32(eax + 0x10)); /* 0x3B004E5A: fld dword ptr [eax + 0x10] */ 3791 _st[0] *= (double)*(float*)ADDR(ecx + 0x38); /* 0x3B004E5D: fmul dword ptr [ecx + 0x38] */ 3792 fp_push(*(float*)&MEM32(eax + (-0x10))); /* 0x3B004E60: fld dword ptr [eax - 0x10] */ 3793 _st[0] *= (double)*(float*)ADDR(ecx + 0x30); /* 0x3B004E63: fmul dword ptr [ecx + 0x30] */ 3794 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4); 3795 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3796 eax = eax + 4; /* 0x3B004E66: add eax, 4 */ 3797 _flag_k = FK_ADD; 3798 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1); 3799 esi = esi - 1; /* 0x3B004E69: dec esi */ 3800 _flag_k = FK_DEC; 3801 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004E6A: faddp st(1) */ 3802 fp_push(*(float*)&MEM32(eax + (-0x4))); /* 0x3B004E6C: fld dword ptr [eax - 4] */ 3803 _st[0] *= (double)*(float*)ADDR(ecx + 0x34); /* 0x3B004E6F: fmul dword ptr [ecx + 0x34] */ 3804 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004E72: faddp st(1) */ 3805 _st[0] += (double)*(float*)ADDR(eax + 0x1C); /* 0x3B004E74: fadd dword ptr [eax + 0x1c] */ 3806 { float _v = (float)fp_pop(); *(float*)ADDR(edx + eax + (-0x4)) = _v; } /* 0x3B004E77: fstp dword ptr [edx + eax - 4] */ 3807 RECOMP_BACKEDGE(); 3808 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004E5A; /* 0x3B004E7B: jne 0x3b004e5a */ 3809 L_3B004E7D: 3810 eax = MEM32(ebp + 0x8); /* 0x3B004E7D: mov eax, dword ptr [ebp + 8] */ 3811 ecx = 0x10u; /* 0x3B004E80: mov ecx, 0x10 */ 3812 esi = ebp + (-0x44); /* 0x3B004E85: lea esi, [ebp - 0x44] */ 3813 edi = eax; /* 0x3B004E88: mov edi, eax */ 3814 if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3B004E8A: rep movsd dword ptr es:[edi], dword ptr [esi] */ if (_df > 0) { memmove((void*)ADDR(edi), (void*)ADDR(esi), _b); esi += _b; edi += _b; } else { memmove((void*)ADDR(edi - _b + 4u), (void*)ADDR(esi - _b + 4u), _b); esi -= _b; edi -= _b; } ecx = 0; } 3815 edi = POP32_VAL(esp); /* 0x3B004E8C: pop edi */ 3816 esi = POP32_VAL(esp); /* 0x3B004E8D: pop esi */ 3817 ebx = POP32_VAL(esp); /* 0x3B004E8E: pop ebx */ 3818 esp = ebp; /* 0x3B004E8F: mov esp, ebp */ 3819 ebp = POP32_VAL(esp); /* 0x3B004E91: pop ebp */ 3820 RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3B004E92: ret 8 */ 3821 RECOMP_REGS_OUT(); 3822 } 3823 3824 void sub_3B004EA0(void) { 3825 int _fpu_cmp = 0; 3826 uint32_t _cf = 0; 3827 int _df = 1; 3828 uint32_t _flag_k = FK_NONE; 3829 uint32_t _flag_a = 0, _flag_b = 0; 3830 uint32_t _itail_tgt = 0; 3831 RECOMP_REGS_LOCALS 3832 RECOMP_ENTER(0x3B004EA0u); 3833 3834 L_3B004EA0: 3835 PUSH32(esp, ebp); /* 0x3B004EA0: push ebp */ 3836 ebp = esp; /* 0x3B004EA1: mov ebp, esp */ 3837 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x44u); 3838 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3839 esp = esp - 0x44u; /* 0x3B004EA3: sub esp, 0x44 */ 3840 _flag_k = FK_CMP; 3841 eax = ecx; /* 0x3B004EA6: mov eax, ecx */ 3842 PUSH32(esp, ebx); /* 0x3B004EA8: push ebx */ 3843 PUSH32(esp, esi); /* 0x3B004EA9: push esi */ 3844 PUSH32(esp, edi); /* 0x3B004EAA: push edi */ 3845 MEM32(ebp + (-0x44)) = 0x3F800000u; /* 0x3B004EAB: mov dword ptr [ebp - 0x44], 0x3f800000 */ 3846 MEM32(ebp + (-0x40)) = 0; /* 0x3B004EB2: mov dword ptr [ebp - 0x40], 0 */ 3847 MEM32(ebp + (-0x3C)) = 0; /* 0x3B004EB9: mov dword ptr [ebp - 0x3c], 0 */ 3848 MEM32(ebp + (-0x38)) = 0; /* 0x3B004EC0: mov dword ptr [ebp - 0x38], 0 */ 3849 MEM32(ebp + (-0x34)) = 0; /* 0x3B004EC7: mov dword ptr [ebp - 0x34], 0 */ 3850 MEM32(ebp + (-0x30)) = 0x3F800000u; /* 0x3B004ECE: mov dword ptr [ebp - 0x30], 0x3f800000 */ 3851 MEM32(ebp + (-0x2C)) = 0; /* 0x3B004ED5: mov dword ptr [ebp - 0x2c], 0 */ 3852 MEM32(ebp + (-0x28)) = 0; /* 0x3B004EDC: mov dword ptr [ebp - 0x28], 0 */ 3853 MEM32(ebp + (-0x24)) = 0; /* 0x3B004EE3: mov dword ptr [ebp - 0x24], 0 */ 3854 MEM32(ebp + (-0x20)) = 0; /* 0x3B004EEA: mov dword ptr [ebp - 0x20], 0 */ 3855 MEM32(ebp + (-0x1C)) = 0x3F800000u; /* 0x3B004EF1: mov dword ptr [ebp - 0x1c], 0x3f800000 */ 3856 MEM32(ebp + (-0x18)) = 0; /* 0x3B004EF8: mov dword ptr [ebp - 0x18], 0 */ 3857 MEM32(ebp + (-0x14)) = 0; /* 0x3B004EFF: mov dword ptr [ebp - 0x14], 0 */ 3858 MEM32(ebp + (-0x10)) = 0; /* 0x3B004F06: mov dword ptr [ebp - 0x10], 0 */ 3859 MEM32(ebp + (-0xC)) = 0; /* 0x3B004F0D: mov dword ptr [ebp - 0xc], 0 */ 3860 MEM32(ebp + (-0x8)) = 0x3F800000u; /* 0x3B004F14: mov dword ptr [ebp - 8], 0x3f800000 */ 3861 ebx = ebp + (-0x44); /* 0x3B004F1B: lea ebx, [ebp - 0x44] */ 3862 edx = eax + 0x4; /* 0x3B004F1E: lea edx, [eax + 4] */ 3863 MEM32(ebp + (-0x4)) = 3; /* 0x3B004F21: mov dword ptr [ebp - 4], 3 */ 3864 L_3B004F28: 3865 ecx = MEM32(ebp + 0x8); /* 0x3B004F28: mov ecx, dword ptr [ebp + 8] */ 3866 esi = ebx; /* 0x3B004F2B: mov esi, ebx */ 3867 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0x10u); 3868 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3869 ecx = ecx + 0x10u; /* 0x3B004F2D: add ecx, 0x10 */ 3870 _flag_k = FK_ADD; 3871 edi = 3; /* 0x3B004F30: mov edi, 3 */ 3872 L_3B004F35: 3873 fp_push(*(float*)&MEM32(ecx + (-0x10))); /* 0x3B004F35: fld dword ptr [ecx - 0x10] */ 3874 _st[0] *= (double)*(float*)ADDR(edx + (-0x4)); /* 0x3B004F38: fmul dword ptr [edx - 4] */ 3875 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B004F3B: fld dword ptr [ecx + 0x10] */ 3876 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B004F3E: fmul dword ptr [edx + 4] */ 3877 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4); 3878 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3879 ecx = ecx + 4; /* 0x3B004F41: add ecx, 4 */ 3880 _flag_k = FK_ADD; 3881 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(4); 3882 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3883 esi = esi + 4; /* 0x3B004F44: add esi, 4 */ 3884 _flag_k = FK_ADD; 3885 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(1); 3886 edi = edi - 1; /* 0x3B004F47: dec edi */ 3887 _flag_k = FK_DEC; 3888 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004F48: faddp st(1) */ 3889 fp_push(*(float*)&MEM32(edx)); /* 0x3B004F4A: fld dword ptr [edx] */ 3890 _st[0] *= (double)*(float*)ADDR(ecx + (-0x4)); /* 0x3B004F4C: fmul dword ptr [ecx - 4] */ 3891 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004F4F: faddp st(1) */ 3892 { float _v = (float)fp_pop(); *(float*)ADDR(esi + (-0x4)) = _v; } /* 0x3B004F51: fstp dword ptr [esi - 4] */ 3893 RECOMP_BACKEDGE(); 3894 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004F35; /* 0x3B004F54: jne 0x3b004f35 */ 3895 L_3B004F56: 3896 ecx = MEM32(ebp + (-0x4)); /* 0x3B004F56: mov ecx, dword ptr [ebp - 4] */ 3897 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u); 3898 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3899 edx = edx + 0x10u; /* 0x3B004F59: add edx, 0x10 */ 3900 _flag_k = FK_ADD; 3901 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0x10u); 3902 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3903 ebx = ebx + 0x10u; /* 0x3B004F5C: add ebx, 0x10 */ 3904 _flag_k = FK_ADD; 3905 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1); 3906 ecx = ecx - 1; /* 0x3B004F5F: dec ecx */ 3907 _flag_k = FK_DEC; 3908 MEM32(ebp + (-0x4)) = ecx; /* 0x3B004F60: mov dword ptr [ebp - 4], ecx */ 3909 RECOMP_BACKEDGE(); 3910 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004F28; /* 0x3B004F63: jne 0x3b004f28 */ 3911 L_3B004F65: 3912 esi = MEM32(ebp + 0x8); /* 0x3B004F65: mov esi, dword ptr [ebp + 8] */ 3913 edx = ebp + (-0x24); /* 0x3B004F68: lea edx, [ebp - 0x24] */ 3914 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(esi); 3915 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 3916 edx = edx - esi; /* 0x3B004F6B: sub edx, esi */ 3917 _flag_k = FK_CMP; 3918 ecx = esi + 0x10; /* 0x3B004F6D: lea ecx, [esi + 0x10] */ 3919 esi = 3; /* 0x3B004F70: mov esi, 3 */ 3920 L_3B004F75: 3921 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B004F75: fld dword ptr [ecx + 0x10] */ 3922 _st[0] *= (double)*(float*)ADDR(eax + 0x38); /* 0x3B004F78: fmul dword ptr [eax + 0x38] */ 3923 fp_push(*(float*)&MEM32(ecx + (-0x10))); /* 0x3B004F7B: fld dword ptr [ecx - 0x10] */ 3924 _st[0] *= (double)*(float*)ADDR(eax + 0x30); /* 0x3B004F7E: fmul dword ptr [eax + 0x30] */ 3925 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4); 3926 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3927 ecx = ecx + 4; /* 0x3B004F81: add ecx, 4 */ 3928 _flag_k = FK_ADD; 3929 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1); 3930 esi = esi - 1; /* 0x3B004F84: dec esi */ 3931 _flag_k = FK_DEC; 3932 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004F85: faddp st(1) */ 3933 fp_push(*(float*)&MEM32(ecx + (-0x4))); /* 0x3B004F87: fld dword ptr [ecx - 4] */ 3934 _st[0] *= (double)*(float*)ADDR(eax + 0x34); /* 0x3B004F8A: fmul dword ptr [eax + 0x34] */ 3935 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004F8D: faddp st(1) */ 3936 _st[0] += (double)*(float*)ADDR(ecx + 0x1C); /* 0x3B004F8F: fadd dword ptr [ecx + 0x1c] */ 3937 { float _v = (float)fp_pop(); *(float*)ADDR(edx + ecx + (-0x4)) = _v; } /* 0x3B004F92: fstp dword ptr [edx + ecx - 4] */ 3938 RECOMP_BACKEDGE(); 3939 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004F75; /* 0x3B004F96: jne 0x3b004f75 */ 3940 L_3B004F98: 3941 ecx = 0x10u; /* 0x3B004F98: mov ecx, 0x10 */ 3942 esi = ebp + (-0x44); /* 0x3B004F9D: lea esi, [ebp - 0x44] */ 3943 edi = eax; /* 0x3B004FA0: mov edi, eax */ 3944 if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3B004FA2: rep movsd dword ptr es:[edi], dword ptr [esi] */ if (_df > 0) { memmove((void*)ADDR(edi), (void*)ADDR(esi), _b); esi += _b; edi += _b; } else { memmove((void*)ADDR(edi - _b + 4u), (void*)ADDR(esi - _b + 4u), _b); esi -= _b; edi -= _b; } ecx = 0; } 3945 edi = POP32_VAL(esp); /* 0x3B004FA4: pop edi */ 3946 esi = POP32_VAL(esp); /* 0x3B004FA5: pop esi */ 3947 ebx = POP32_VAL(esp); /* 0x3B004FA6: pop ebx */ 3948 esp = ebp; /* 0x3B004FA7: mov esp, ebp */ 3949 ebp = POP32_VAL(esp); /* 0x3B004FA9: pop ebp */ 3950 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004FAA: ret 4 */ 3951 RECOMP_REGS_OUT(); 3952 } 3953 3954 void sub_3B004EFF(void) { 3955 int _fpu_cmp = 0; 3956 uint32_t _cf = 0; 3957 int _df = 1; 3958 uint32_t _flag_k = FK_NONE; 3959 uint32_t _flag_a = 0, _flag_b = 0; 3960 uint32_t _itail_tgt = 0; 3961 RECOMP_REGS_LOCALS 3962 RECOMP_ENTER(0x3B004EFFu); 3963 3964 L_3B004EFF: 3965 MEM32(ebp + (-0x14)) = 0; /* 0x3B004EFF: mov dword ptr [ebp - 0x14], 0 */ 3966 MEM32(ebp + (-0x10)) = 0; /* 0x3B004F06: mov dword ptr [ebp - 0x10], 0 */ 3967 MEM32(ebp + (-0xC)) = 0; /* 0x3B004F0D: mov dword ptr [ebp - 0xc], 0 */ 3968 MEM32(ebp + (-0x8)) = 0x3F800000u; /* 0x3B004F14: mov dword ptr [ebp - 8], 0x3f800000 */ 3969 ebx = ebp + (-0x44); /* 0x3B004F1B: lea ebx, [ebp - 0x44] */ 3970 edx = eax + 0x4; /* 0x3B004F1E: lea edx, [eax + 4] */ 3971 MEM32(ebp + (-0x4)) = 3; /* 0x3B004F21: mov dword ptr [ebp - 4], 3 */ 3972 L_3B004F28: 3973 ecx = MEM32(ebp + 0x8); /* 0x3B004F28: mov ecx, dword ptr [ebp + 8] */ 3974 esi = ebx; /* 0x3B004F2B: mov esi, ebx */ 3975 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0x10u); 3976 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3977 ecx = ecx + 0x10u; /* 0x3B004F2D: add ecx, 0x10 */ 3978 _flag_k = FK_ADD; 3979 edi = 3; /* 0x3B004F30: mov edi, 3 */ 3980 L_3B004F35: 3981 fp_push(*(float*)&MEM32(ecx + (-0x10))); /* 0x3B004F35: fld dword ptr [ecx - 0x10] */ 3982 _st[0] *= (double)*(float*)ADDR(edx + (-0x4)); /* 0x3B004F38: fmul dword ptr [edx - 4] */ 3983 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B004F3B: fld dword ptr [ecx + 0x10] */ 3984 _st[0] *= (double)*(float*)ADDR(edx + 0x4); /* 0x3B004F3E: fmul dword ptr [edx + 4] */ 3985 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4); 3986 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3987 ecx = ecx + 4; /* 0x3B004F41: add ecx, 4 */ 3988 _flag_k = FK_ADD; 3989 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(4); 3990 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 3991 esi = esi + 4; /* 0x3B004F44: add esi, 4 */ 3992 _flag_k = FK_ADD; 3993 _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(1); 3994 edi = edi - 1; /* 0x3B004F47: dec edi */ 3995 _flag_k = FK_DEC; 3996 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004F48: faddp st(1) */ 3997 fp_push(*(float*)&MEM32(edx)); /* 0x3B004F4A: fld dword ptr [edx] */ 3998 _st[0] *= (double)*(float*)ADDR(ecx + (-0x4)); /* 0x3B004F4C: fmul dword ptr [ecx - 4] */ 3999 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004F4F: faddp st(1) */ 4000 { float _v = (float)fp_pop(); *(float*)ADDR(esi + (-0x4)) = _v; } /* 0x3B004F51: fstp dword ptr [esi - 4] */ 4001 RECOMP_BACKEDGE(); 4002 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004F35; /* 0x3B004F54: jne 0x3b004f35 */ 4003 L_3B004F56: 4004 ecx = MEM32(ebp + (-0x4)); /* 0x3B004F56: mov ecx, dword ptr [ebp - 4] */ 4005 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u); 4006 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 4007 edx = edx + 0x10u; /* 0x3B004F59: add edx, 0x10 */ 4008 _flag_k = FK_ADD; 4009 _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0x10u); 4010 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 4011 ebx = ebx + 0x10u; /* 0x3B004F5C: add ebx, 0x10 */ 4012 _flag_k = FK_ADD; 4013 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1); 4014 ecx = ecx - 1; /* 0x3B004F5F: dec ecx */ 4015 _flag_k = FK_DEC; 4016 MEM32(ebp + (-0x4)) = ecx; /* 0x3B004F60: mov dword ptr [ebp - 4], ecx */ 4017 RECOMP_BACKEDGE(); 4018 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004F28; /* 0x3B004F63: jne 0x3b004f28 */ 4019 L_3B004F65: 4020 esi = MEM32(ebp + 0x8); /* 0x3B004F65: mov esi, dword ptr [ebp + 8] */ 4021 edx = ebp + (-0x24); /* 0x3B004F68: lea edx, [ebp - 0x24] */ 4022 _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(esi); 4023 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4024 edx = edx - esi; /* 0x3B004F6B: sub edx, esi */ 4025 _flag_k = FK_CMP; 4026 ecx = esi + 0x10; /* 0x3B004F6D: lea ecx, [esi + 0x10] */ 4027 esi = 3; /* 0x3B004F70: mov esi, 3 */ 4028 L_3B004F75: 4029 fp_push(*(float*)&MEM32(ecx + 0x10)); /* 0x3B004F75: fld dword ptr [ecx + 0x10] */ 4030 _st[0] *= (double)*(float*)ADDR(eax + 0x38); /* 0x3B004F78: fmul dword ptr [eax + 0x38] */ 4031 fp_push(*(float*)&MEM32(ecx + (-0x10))); /* 0x3B004F7B: fld dword ptr [ecx - 0x10] */ 4032 _st[0] *= (double)*(float*)ADDR(eax + 0x30); /* 0x3B004F7E: fmul dword ptr [eax + 0x30] */ 4033 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4); 4034 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 4035 ecx = ecx + 4; /* 0x3B004F81: add ecx, 4 */ 4036 _flag_k = FK_ADD; 4037 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1); 4038 esi = esi - 1; /* 0x3B004F84: dec esi */ 4039 _flag_k = FK_DEC; 4040 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004F85: faddp st(1) */ 4041 fp_push(*(float*)&MEM32(ecx + (-0x4))); /* 0x3B004F87: fld dword ptr [ecx - 4] */ 4042 _st[0] *= (double)*(float*)ADDR(eax + 0x34); /* 0x3B004F8A: fmul dword ptr [eax + 0x34] */ 4043 { double _v = fp_pop(); _st[0] += _v; } /* 0x3B004F8D: faddp st(1) */ 4044 _st[0] += (double)*(float*)ADDR(ecx + 0x1C); /* 0x3B004F8F: fadd dword ptr [ecx + 0x1c] */ 4045 { float _v = (float)fp_pop(); *(float*)ADDR(edx + ecx + (-0x4)) = _v; } /* 0x3B004F92: fstp dword ptr [edx + ecx - 4] */ 4046 RECOMP_BACKEDGE(); 4047 if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3B004F75; /* 0x3B004F96: jne 0x3b004f75 */ 4048 L_3B004F98: 4049 ecx = 0x10u; /* 0x3B004F98: mov ecx, 0x10 */ 4050 esi = ebp + (-0x44); /* 0x3B004F9D: lea esi, [ebp - 0x44] */ 4051 edi = eax; /* 0x3B004FA0: mov edi, eax */ 4052 if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3B004FA2: rep movsd dword ptr es:[edi], dword ptr [esi] */ if (_df > 0) { memmove((void*)ADDR(edi), (void*)ADDR(esi), _b); esi += _b; edi += _b; } else { memmove((void*)ADDR(edi - _b + 4u), (void*)ADDR(esi - _b + 4u), _b); esi -= _b; edi -= _b; } ecx = 0; } 4053 edi = POP32_VAL(esp); /* 0x3B004FA4: pop edi */ 4054 esi = POP32_VAL(esp); /* 0x3B004FA5: pop esi */ 4055 ebx = POP32_VAL(esp); /* 0x3B004FA6: pop ebx */ 4056 esp = ebp; /* 0x3B004FA7: mov esp, ebp */ 4057 ebp = POP32_VAL(esp); /* 0x3B004FA9: pop ebp */ 4058 RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3B004FAA: ret 4 */ 4059 RECOMP_REGS_OUT(); 4060 } 4061 4062 void sub_3B004FB0(void) { 4063 int _fpu_cmp = 0; 4064 uint32_t _cf = 0; 4065 int _df = 1; 4066 uint32_t _flag_k = FK_NONE; 4067 uint32_t _flag_a = 0, _flag_b = 0; 4068 uint32_t _itail_tgt = 0; 4069 RECOMP_REGS_LOCALS 4070 RECOMP_ENTER(0x3B004FB0u); 4071 4072 L_3B004FB0: 4073 RECOMP_ICALL(0x3B004FC0u); /* 0x3B004FB0: call 0x3b004fc0 */ /* not lifted */ 4074 RECOMP_FLAGS_IN(); 4075 goto L_3B004FD0; /* 0x3B004FB5: jmp 0x3b004fd0 */ 4076 L_3B004FD0: 4077 PUSH32(esp, 0x3B004FE0u); /* 0x3B004FD0: push 0x3b004fe0 */ 4078 RECOMP_ICALL(0x3B0050E8u); /* 0x3B004FD5: call 0x3b0050e8 */ /* not lifted */ 4079 RECOMP_FLAGS_IN(); 4080 ecx = POP32_VAL(esp); /* 0x3B004FDA: pop ecx */ 4081 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B004FDB: ret */ 4082 RECOMP_REGS_OUT(); 4083 } 4084 4085 void sub_3B004FC0(void) { 4086 int _fpu_cmp = 0; 4087 uint32_t _cf = 0; 4088 int _df = 1; 4089 uint32_t _flag_k = FK_NONE; 4090 uint32_t _flag_a = 0, _flag_b = 0; 4091 uint32_t _itail_tgt = 0; 4092 RECOMP_REGS_LOCALS 4093 RECOMP_ENTER(0x3B004FC0u); 4094 4095 L_3B004FC0: 4096 ecx = 0x3B008051u; /* 0x3B004FC0: mov ecx, 0x3b008051 */ 4097 L_3B004FC5: 4098 { _itail_tgt = (uint32_t)(MEM32(0x3B006014)); goto _ljump; } 4099 { RECOMP_REGS_OUT(); return; } /* end of function */ 4100 _ljump: 4101 switch (_itail_tgt) { 4102 case 0x3B004FC0u: goto L_3B004FC0; 4103 case 0x3B004FC5u: goto L_3B004FC5; 4104 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4105 } 4106 RECOMP_REGS_OUT(); 4107 } 4108 4109 void sub_3B004FD0(void) { 4110 int _fpu_cmp = 0; 4111 uint32_t _cf = 0; 4112 int _df = 1; 4113 uint32_t _flag_k = FK_NONE; 4114 uint32_t _flag_a = 0, _flag_b = 0; 4115 uint32_t _itail_tgt = 0; 4116 RECOMP_REGS_LOCALS 4117 RECOMP_ENTER(0x3B004FD0u); 4118 4119 L_3B004FD0: 4120 PUSH32(esp, 0x3B004FE0u); /* 0x3B004FD0: push 0x3b004fe0 */ 4121 RECOMP_ICALL(0x3B0050E8u); /* 0x3B004FD5: call 0x3b0050e8 */ /* not lifted */ 4122 RECOMP_FLAGS_IN(); 4123 ecx = POP32_VAL(esp); /* 0x3B004FDA: pop ecx */ 4124 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B004FDB: ret */ 4125 RECOMP_REGS_OUT(); 4126 } 4127 4128 void sub_3B004FE0(void) { 4129 int _fpu_cmp = 0; 4130 uint32_t _cf = 0; 4131 int _df = 1; 4132 uint32_t _flag_k = FK_NONE; 4133 uint32_t _flag_a = 0, _flag_b = 0; 4134 uint32_t _itail_tgt = 0; 4135 RECOMP_REGS_LOCALS 4136 RECOMP_ENTER(0x3B004FE0u); 4137 4138 L_3B004FE0: 4139 ecx = 0x3B008051u; /* 0x3B004FE0: mov ecx, 0x3b008051 */ 4140 L_3B004FE5: 4141 { _itail_tgt = (uint32_t)(MEM32(0x3B006008)); goto _ljump; } 4142 { RECOMP_REGS_OUT(); return; } /* end of function */ 4143 _ljump: 4144 switch (_itail_tgt) { 4145 case 0x3B004FE0u: goto L_3B004FE0; 4146 case 0x3B004FE5u: goto L_3B004FE5; 4147 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4148 } 4149 RECOMP_REGS_OUT(); 4150 } 4151 4152 void sub_3B004FF0(void) { 4153 int _fpu_cmp = 0; 4154 uint32_t _cf = 0; 4155 int _df = 1; 4156 uint32_t _flag_k = FK_NONE; 4157 uint32_t _flag_a = 0, _flag_b = 0; 4158 uint32_t _itail_tgt = 0; 4159 RECOMP_REGS_LOCALS 4160 RECOMP_ENTER(0x3B004FF0u); 4161 4162 L_3B004FF0: 4163 RECOMP_ICALL(0x3B005000u); /* 0x3B004FF0: call 0x3b005000 */ /* not lifted */ 4164 RECOMP_FLAGS_IN(); 4165 goto L_3B005010; /* 0x3B004FF5: jmp 0x3b005010 */ 4166 L_3B005010: 4167 PUSH32(esp, 0x3B005020u); /* 0x3B005010: push 0x3b005020 */ 4168 RECOMP_ICALL(0x3B0050E8u); /* 0x3B005015: call 0x3b0050e8 */ /* not lifted */ 4169 RECOMP_FLAGS_IN(); 4170 ecx = POP32_VAL(esp); /* 0x3B00501A: pop ecx */ 4171 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00501B: ret */ 4172 RECOMP_REGS_OUT(); 4173 } 4174 4175 void sub_3B005000(void) { 4176 int _fpu_cmp = 0; 4177 uint32_t _cf = 0; 4178 int _df = 1; 4179 uint32_t _flag_k = FK_NONE; 4180 uint32_t _flag_a = 0, _flag_b = 0; 4181 uint32_t _itail_tgt = 0; 4182 RECOMP_REGS_LOCALS 4183 RECOMP_ENTER(0x3B005000u); 4184 4185 L_3B005000: 4186 ecx = 0x3B008050u; /* 0x3B005000: mov ecx, 0x3b008050 */ 4187 L_3B005005: 4188 { _itail_tgt = (uint32_t)(MEM32(0x3B00600C)); goto _ljump; } 4189 { RECOMP_REGS_OUT(); return; } /* end of function */ 4190 _ljump: 4191 switch (_itail_tgt) { 4192 case 0x3B005000u: goto L_3B005000; 4193 case 0x3B005005u: goto L_3B005005; 4194 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4195 } 4196 RECOMP_REGS_OUT(); 4197 } 4198 4199 void sub_3B005010(void) { 4200 int _fpu_cmp = 0; 4201 uint32_t _cf = 0; 4202 int _df = 1; 4203 uint32_t _flag_k = FK_NONE; 4204 uint32_t _flag_a = 0, _flag_b = 0; 4205 uint32_t _itail_tgt = 0; 4206 RECOMP_REGS_LOCALS 4207 RECOMP_ENTER(0x3B005010u); 4208 4209 L_3B005010: 4210 PUSH32(esp, 0x3B005020u); /* 0x3B005010: push 0x3b005020 */ 4211 RECOMP_ICALL(0x3B0050E8u); /* 0x3B005015: call 0x3b0050e8 */ /* not lifted */ 4212 RECOMP_FLAGS_IN(); 4213 ecx = POP32_VAL(esp); /* 0x3B00501A: pop ecx */ 4214 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00501B: ret */ 4215 RECOMP_REGS_OUT(); 4216 } 4217 4218 void sub_3B005020(void) { 4219 int _fpu_cmp = 0; 4220 uint32_t _cf = 0; 4221 int _df = 1; 4222 uint32_t _flag_k = FK_NONE; 4223 uint32_t _flag_a = 0, _flag_b = 0; 4224 uint32_t _itail_tgt = 0; 4225 RECOMP_REGS_LOCALS 4226 RECOMP_ENTER(0x3B005020u); 4227 4228 L_3B005020: 4229 ecx = 0x3B008050u; /* 0x3B005020: mov ecx, 0x3b008050 */ 4230 L_3B005025: 4231 { _itail_tgt = (uint32_t)(MEM32(0x3B006010)); goto _ljump; } 4232 { RECOMP_REGS_OUT(); return; } /* end of function */ 4233 _ljump: 4234 switch (_itail_tgt) { 4235 case 0x3B005020u: goto L_3B005020; 4236 case 0x3B005025u: goto L_3B005025; 4237 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4238 } 4239 RECOMP_REGS_OUT(); 4240 } 4241 4242 void sub_3B005030(void) { 4243 int _fpu_cmp = 0; 4244 uint32_t _cf = 0; 4245 int _df = 1; 4246 uint32_t _flag_k = FK_NONE; 4247 uint32_t _flag_a = 0, _flag_b = 0; 4248 uint32_t _itail_tgt = 0; 4249 RECOMP_REGS_LOCALS 4250 RECOMP_ENTER(0x3B005030u); 4251 4252 L_3B005030: 4253 RECOMP_ICALL(0x3B005040u); /* 0x3B005030: call 0x3b005040 */ /* not lifted */ 4254 RECOMP_FLAGS_IN(); 4255 goto L_3B005050; /* 0x3B005035: jmp 0x3b005050 */ 4256 L_3B005050: 4257 PUSH32(esp, 0x3B005060u); /* 0x3B005050: push 0x3b005060 */ 4258 RECOMP_ICALL(0x3B0050E8u); /* 0x3B005055: call 0x3b0050e8 */ /* not lifted */ 4259 RECOMP_FLAGS_IN(); 4260 ecx = POP32_VAL(esp); /* 0x3B00505A: pop ecx */ 4261 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00505B: ret */ 4262 RECOMP_REGS_OUT(); 4263 } 4264 4265 void sub_3B005040(void) { 4266 int _fpu_cmp = 0; 4267 uint32_t _cf = 0; 4268 int _df = 1; 4269 uint32_t _flag_k = FK_NONE; 4270 uint32_t _flag_a = 0, _flag_b = 0; 4271 uint32_t _itail_tgt = 0; 4272 RECOMP_REGS_LOCALS 4273 RECOMP_ENTER(0x3B005040u); 4274 4275 L_3B005040: 4276 ecx = 0x3B008055u; /* 0x3B005040: mov ecx, 0x3b008055 */ 4277 L_3B005045: 4278 { _itail_tgt = (uint32_t)(MEM32(0x3B006014)); goto _ljump; } 4279 { RECOMP_REGS_OUT(); return; } /* end of function */ 4280 _ljump: 4281 switch (_itail_tgt) { 4282 case 0x3B005040u: goto L_3B005040; 4283 case 0x3B005045u: goto L_3B005045; 4284 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4285 } 4286 RECOMP_REGS_OUT(); 4287 } 4288 4289 void sub_3B005050(void) { 4290 int _fpu_cmp = 0; 4291 uint32_t _cf = 0; 4292 int _df = 1; 4293 uint32_t _flag_k = FK_NONE; 4294 uint32_t _flag_a = 0, _flag_b = 0; 4295 uint32_t _itail_tgt = 0; 4296 RECOMP_REGS_LOCALS 4297 RECOMP_ENTER(0x3B005050u); 4298 4299 L_3B005050: 4300 PUSH32(esp, 0x3B005060u); /* 0x3B005050: push 0x3b005060 */ 4301 RECOMP_ICALL(0x3B0050E8u); /* 0x3B005055: call 0x3b0050e8 */ /* not lifted */ 4302 RECOMP_FLAGS_IN(); 4303 ecx = POP32_VAL(esp); /* 0x3B00505A: pop ecx */ 4304 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00505B: ret */ 4305 RECOMP_REGS_OUT(); 4306 } 4307 4308 void sub_3B005060(void) { 4309 int _fpu_cmp = 0; 4310 uint32_t _cf = 0; 4311 int _df = 1; 4312 uint32_t _flag_k = FK_NONE; 4313 uint32_t _flag_a = 0, _flag_b = 0; 4314 uint32_t _itail_tgt = 0; 4315 RECOMP_REGS_LOCALS 4316 RECOMP_ENTER(0x3B005060u); 4317 4318 L_3B005060: 4319 ecx = 0x3B008055u; /* 0x3B005060: mov ecx, 0x3b008055 */ 4320 L_3B005065: 4321 { _itail_tgt = (uint32_t)(MEM32(0x3B006008)); goto _ljump; } 4322 { RECOMP_REGS_OUT(); return; } /* end of function */ 4323 _ljump: 4324 switch (_itail_tgt) { 4325 case 0x3B005060u: goto L_3B005060; 4326 case 0x3B005065u: goto L_3B005065; 4327 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4328 } 4329 RECOMP_REGS_OUT(); 4330 } 4331 4332 void sub_3B005070(void) { 4333 int _fpu_cmp = 0; 4334 uint32_t _cf = 0; 4335 int _df = 1; 4336 uint32_t _flag_k = FK_NONE; 4337 uint32_t _flag_a = 0, _flag_b = 0; 4338 uint32_t _itail_tgt = 0; 4339 RECOMP_REGS_LOCALS 4340 RECOMP_ENTER(0x3B005070u); 4341 4342 L_3B005070: 4343 RECOMP_ICALL(0x3B005080u); /* 0x3B005070: call 0x3b005080 */ /* not lifted */ 4344 RECOMP_FLAGS_IN(); 4345 goto L_3B005090; /* 0x3B005075: jmp 0x3b005090 */ 4346 L_3B005090: 4347 PUSH32(esp, 0x3B0050A0u); /* 0x3B005090: push 0x3b0050a0 */ 4348 RECOMP_ICALL(0x3B0050E8u); /* 0x3B005095: call 0x3b0050e8 */ /* not lifted */ 4349 RECOMP_FLAGS_IN(); 4350 ecx = POP32_VAL(esp); /* 0x3B00509A: pop ecx */ 4351 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00509B: ret */ 4352 RECOMP_REGS_OUT(); 4353 } 4354 4355 void sub_3B005080(void) { 4356 int _fpu_cmp = 0; 4357 uint32_t _cf = 0; 4358 int _df = 1; 4359 uint32_t _flag_k = FK_NONE; 4360 uint32_t _flag_a = 0, _flag_b = 0; 4361 uint32_t _itail_tgt = 0; 4362 RECOMP_REGS_LOCALS 4363 RECOMP_ENTER(0x3B005080u); 4364 4365 L_3B005080: 4366 ecx = 0x3B008054u; /* 0x3B005080: mov ecx, 0x3b008054 */ 4367 L_3B005085: 4368 { _itail_tgt = (uint32_t)(MEM32(0x3B00600C)); goto _ljump; } 4369 { RECOMP_REGS_OUT(); return; } /* end of function */ 4370 _ljump: 4371 switch (_itail_tgt) { 4372 case 0x3B005080u: goto L_3B005080; 4373 case 0x3B005085u: goto L_3B005085; 4374 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4375 } 4376 RECOMP_REGS_OUT(); 4377 } 4378 4379 void sub_3B005090(void) { 4380 int _fpu_cmp = 0; 4381 uint32_t _cf = 0; 4382 int _df = 1; 4383 uint32_t _flag_k = FK_NONE; 4384 uint32_t _flag_a = 0, _flag_b = 0; 4385 uint32_t _itail_tgt = 0; 4386 RECOMP_REGS_LOCALS 4387 RECOMP_ENTER(0x3B005090u); 4388 4389 L_3B005090: 4390 PUSH32(esp, 0x3B0050A0u); /* 0x3B005090: push 0x3b0050a0 */ 4391 RECOMP_ICALL(0x3B0050E8u); /* 0x3B005095: call 0x3b0050e8 */ /* not lifted */ 4392 RECOMP_FLAGS_IN(); 4393 ecx = POP32_VAL(esp); /* 0x3B00509A: pop ecx */ 4394 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B00509B: ret */ 4395 RECOMP_REGS_OUT(); 4396 } 4397 4398 void sub_3B0050A0(void) { 4399 int _fpu_cmp = 0; 4400 uint32_t _cf = 0; 4401 int _df = 1; 4402 uint32_t _flag_k = FK_NONE; 4403 uint32_t _flag_a = 0, _flag_b = 0; 4404 uint32_t _itail_tgt = 0; 4405 RECOMP_REGS_LOCALS 4406 RECOMP_ENTER(0x3B0050A0u); 4407 4408 L_3B0050A0: 4409 ecx = 0x3B008054u; /* 0x3B0050A0: mov ecx, 0x3b008054 */ 4410 L_3B0050A5: 4411 { _itail_tgt = (uint32_t)(MEM32(0x3B006010)); goto _ljump; } 4412 { RECOMP_REGS_OUT(); return; } /* end of function */ 4413 _ljump: 4414 switch (_itail_tgt) { 4415 case 0x3B0050A0u: goto L_3B0050A0; 4416 case 0x3B0050A5u: goto L_3B0050A5; 4417 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4418 } 4419 RECOMP_REGS_OUT(); 4420 } 4421 4422 void sub_3B0050B0(void) { 4423 int _fpu_cmp = 0; 4424 uint32_t _cf = 0; 4425 int _df = 1; 4426 uint32_t _flag_k = FK_NONE; 4427 uint32_t _flag_a = 0, _flag_b = 0; 4428 uint32_t _itail_tgt = 0; 4429 RECOMP_REGS_LOCALS 4430 RECOMP_ENTER(0x3B0050B0u); 4431 4432 L_3B0050B0: 4433 { _itail_tgt = (uint32_t)(MEM32(0x3B006038)); goto _ljump; } 4434 { RECOMP_REGS_OUT(); return; } /* end of function */ 4435 _ljump: 4436 switch (_itail_tgt) { 4437 case 0x3B0050B0u: goto L_3B0050B0; 4438 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4439 } 4440 RECOMP_REGS_OUT(); 4441 } 4442 4443 void sub_3B0050B6(void) { 4444 int _fpu_cmp = 0; 4445 uint32_t _cf = 0; 4446 int _df = 1; 4447 uint32_t _flag_k = FK_NONE; 4448 uint32_t _flag_a = 0, _flag_b = 0; 4449 uint32_t _itail_tgt = 0; 4450 RECOMP_REGS_LOCALS 4451 RECOMP_ENTER(0x3B0050B6u); 4452 4453 L_3B0050B6: 4454 { _itail_tgt = (uint32_t)(MEM32(0x3B00603C)); goto _ljump; } 4455 { RECOMP_REGS_OUT(); return; } /* end of function */ 4456 _ljump: 4457 switch (_itail_tgt) { 4458 case 0x3B0050B6u: goto L_3B0050B6; 4459 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4460 } 4461 RECOMP_REGS_OUT(); 4462 } 4463 4464 void sub_3B0050BC(void) { 4465 int _fpu_cmp = 0; 4466 uint32_t _cf = 0; 4467 int _df = 1; 4468 uint32_t _flag_k = FK_NONE; 4469 uint32_t _flag_a = 0, _flag_b = 0; 4470 uint32_t _itail_tgt = 0; 4471 RECOMP_REGS_LOCALS 4472 RECOMP_ENTER(0x3B0050BCu); 4473 4474 L_3B0050BC: 4475 /* cmp MEM32(0x3B008068), 0xFFFFFFFFu */ /* 0x3B0050BC: cmp dword ptr [0x3b008068], -1 */ 4476 _flag_a = (uint32_t)(MEM32(0x3B008068)); _flag_b = (uint32_t)(0xFFFFFFFFu); 4477 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4478 _flag_k = FK_CMP; 4479 if (CMP_NE(_flag_a, _flag_b)) goto L_3B0050D1; /* 0x3B0050C3: jne 0x3b0050d1 */ 4480 L_3B0050C5: 4481 PUSH32(esp, MEM32(esp + 0x4)); /* 0x3B0050C5: push dword ptr [esp + 4] */ 4482 RECOMP_ICALL(MEM32(0x3B006024)); /* 0x3B0050C9: call dword ptr [0x3b006024] */ 4483 RECOMP_FLAGS_IN(); 4484 ecx = POP32_VAL(esp); /* 0x3B0050CF: pop ecx */ 4485 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0050D0: ret */ 4486 L_3B0050D1: 4487 PUSH32(esp, 0x3B008064u); /* 0x3B0050D1: push 0x3b008064 */ 4488 PUSH32(esp, 0x3B008068u); /* 0x3B0050D6: push 0x3b008068 */ 4489 PUSH32(esp, MEM32(esp + 0xC)); /* 0x3B0050DB: push dword ptr [esp + 0xc] */ 4490 RECOMP_ICALL(0x3B005242u); /* 0x3B0050DF: call 0x3b005242 */ /* not lifted */ 4491 RECOMP_FLAGS_IN(); 4492 _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu); 4493 _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a); 4494 esp = esp + 0xCu; /* 0x3B0050E4: add esp, 0xc */ 4495 _flag_k = FK_ADD; 4496 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0050E7: ret */ 4497 RECOMP_REGS_OUT(); 4498 } 4499 4500 void sub_3B0050E8(void) { 4501 int _fpu_cmp = 0; 4502 uint32_t _cf = 0; 4503 int _df = 1; 4504 uint32_t _flag_k = FK_NONE; 4505 uint32_t _flag_a = 0, _flag_b = 0; 4506 uint32_t _itail_tgt = 0; 4507 RECOMP_REGS_LOCALS 4508 RECOMP_ENTER(0x3B0050E8u); 4509 4510 L_3B0050E8: 4511 PUSH32(esp, MEM32(esp + 0x4)); /* 0x3B0050E8: push dword ptr [esp + 4] */ 4512 RECOMP_ICALL(0x3B0050BCu); /* 0x3B0050EC: call 0x3b0050bc */ /* not lifted */ 4513 RECOMP_FLAGS_IN(); 4514 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(eax); 4515 _cf = (eax) != 0; 4516 eax = (uint32_t)(-(int32_t)eax); /* 0x3B0050F1: neg eax */ 4517 _flag_k = FK_CMP; 4518 { uint32_t _sa = eax, _sb = eax, _sc = _cf; /* 0x3B0050F3: sbb eax, eax */ 4519 eax = _sc ? 0xFFFFFFFFu : 0; 4520 _flag_a = recomp_flags_sbb(_sa, _sb, _sc); _flag_b = 0; 4521 _flag_k = FK_EFLAGS; _cf = _flag_a & 1u; } 4522 ecx = POP32_VAL(esp); /* 0x3B0050F5: pop ecx */ 4523 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(eax); 4524 _cf = (eax) != 0; 4525 eax = (uint32_t)(-(int32_t)eax); /* 0x3B0050F6: neg eax */ 4526 _flag_k = FK_CMP; 4527 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1); 4528 eax = eax - 1; /* 0x3B0050F8: dec eax */ 4529 _flag_k = FK_DEC; 4530 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B0050F9: ret */ 4531 RECOMP_REGS_OUT(); 4532 } 4533 4534 void sub_3B0050FA(void) { 4535 int _fpu_cmp = 0; 4536 uint32_t _cf = 0; 4537 int _df = 1; 4538 uint32_t _flag_k = FK_NONE; 4539 uint32_t _flag_a = 0, _flag_b = 0; 4540 uint32_t _itail_tgt = 0; 4541 RECOMP_REGS_LOCALS 4542 RECOMP_ENTER(0x3B0050FAu); 4543 4544 L_3B0050FA: 4545 eax = MEM32(esp + 0x8); /* 0x3B0050FA: mov eax, dword ptr [esp + 8] */ 4546 /* test eax, eax */ /* 0x3B0050FE: test eax, eax */ 4547 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 4548 _cf = 0; 4549 _flag_k = FK_TEST; 4550 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B005110; /* 0x3B005100: jne 0x3b005110 */ 4551 L_3B005102: 4552 /* cmp MEM32(0x3B008058), eax */ /* 0x3B005102: cmp dword ptr [0x3b008058], eax */ 4553 _flag_a = (uint32_t)(MEM32(0x3B008058)); _flag_b = (uint32_t)(eax); 4554 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4555 _flag_k = FK_CMP; 4556 if (CMP_LE(_flag_a, _flag_b)) goto L_3B005138; /* 0x3B005108: jle 0x3b005138 */ 4557 L_3B00510A: 4558 _flag_a = (uint32_t)(MEM32(0x3B008058)); _flag_b = (uint32_t)(1); 4559 MEM32(0x3B008058) = MEM32(0x3B008058) - 1; /* 0x3B00510A: dec dword ptr [0x3b008058] */ 4560 _flag_k = FK_DEC; 4561 L_3B005110: 4562 ecx = MEM32(0x3B006034); /* 0x3B005110: mov ecx, dword ptr [0x3b006034] */ 4563 /* cmp eax, 1 */ /* 0x3B005116: cmp eax, 1 */ 4564 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1); 4565 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4566 _flag_k = FK_CMP; 4567 ecx = MEM32(ecx); /* 0x3B005119: mov ecx, dword ptr [ecx] */ 4568 MEM32(0x3B00805C) = ecx; /* 0x3B00511B: mov dword ptr [0x3b00805c], ecx */ 4569 if (CMP_NE(_flag_a, _flag_b)) goto L_3B005162; /* 0x3B005121: jne 0x3b005162 */ 4570 L_3B005123: 4571 PUSH32(esp, 0x80u); /* 0x3B005123: push 0x80 */ 4572 RECOMP_ICALL(MEM32(0x3B006030)); /* 0x3B005128: call dword ptr [0x3b006030] */ 4573 RECOMP_FLAGS_IN(); 4574 /* test eax, eax */ /* 0x3B00512E: test eax, eax */ 4575 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 4576 _cf = 0; 4577 _flag_k = FK_TEST; 4578 ecx = POP32_VAL(esp); /* 0x3B005130: pop ecx */ 4579 MEM32(0x3B008068) = eax; /* 0x3B005131: mov dword ptr [0x3b008068], eax */ 4580 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B00513C; /* 0x3B005136: jne 0x3b00513c */ 4581 L_3B005138: 4582 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 4583 eax = 0; /* 0x3B005138: xor eax, eax */ 4584 _cf = 0; 4585 _flag_k = FK_TEST; 4586 goto L_3B0051A2; /* 0x3B00513A: jmp 0x3b0051a2 */ 4587 L_3B00513C: 4588 _flag_a = (uint32_t)(MEM32(eax)); _flag_b = (uint32_t)(0); 4589 MEM32(eax) = MEM32(eax) & 0; /* 0x3B00513C: and dword ptr [eax], 0 */ 4590 _cf = 0; 4591 _flag_k = FK_TEST; 4592 eax = MEM32(0x3B008068); /* 0x3B00513F: mov eax, dword ptr [0x3b008068] */ 4593 PUSH32(esp, 0x3B008034u); /* 0x3B005144: push 0x3b008034 */ 4594 PUSH32(esp, 0x3B008000u); /* 0x3B005149: push 0x3b008000 */ 4595 MEM32(0x3B008064) = eax; /* 0x3B00514E: mov dword ptr [0x3b008064], eax */ 4596 RECOMP_ICALL(0x3B005248u); /* 0x3B005153: call 0x3b005248 */ /* not lifted */ 4597 RECOMP_FLAGS_IN(); 4598 _flag_a = (uint32_t)(MEM32(0x3B008058)); _flag_b = (uint32_t)(1); 4599 MEM32(0x3B008058) = MEM32(0x3B008058) + 1; /* 0x3B005158: inc dword ptr [0x3b008058] */ 4600 _flag_k = FK_INC; 4601 ecx = POP32_VAL(esp); /* 0x3B00515E: pop ecx */ 4602 ecx = POP32_VAL(esp); /* 0x3B00515F: pop ecx */ 4603 goto L_3B00519F; /* 0x3B005160: jmp 0x3b00519f */ 4604 L_3B005162: 4605 /* test eax, eax */ /* 0x3B005162: test eax, eax */ 4606 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 4607 _cf = 0; 4608 _flag_k = FK_TEST; 4609 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B00519F; /* 0x3B005164: jne 0x3b00519f */ 4610 L_3B005166: 4611 eax = MEM32(0x3B008068); /* 0x3B005166: mov eax, dword ptr [0x3b008068] */ 4612 /* test eax, eax */ /* 0x3B00516B: test eax, eax */ 4613 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 4614 _cf = 0; 4615 _flag_k = FK_TEST; 4616 if (TEST_Z(_flag_a, _flag_b)) goto L_3B00519F; /* 0x3B00516D: je 0x3b00519f */ 4617 L_3B00516F: 4618 ecx = MEM32(0x3B008064); /* 0x3B00516F: mov ecx, dword ptr [0x3b008064] */ 4619 PUSH32(esp, esi); /* 0x3B005175: push esi */ 4620 esi = ecx + (-0x4); /* 0x3B005176: lea esi, [ecx - 4] */ 4621 L_3B005179: 4622 /* cmp esi, eax */ /* 0x3B005179: cmp esi, eax */ 4623 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax); 4624 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4625 _flag_k = FK_CMP; 4626 if (CMP_B(_flag_a, _flag_b)) goto L_3B00518F; /* 0x3B00517B: jb 0x3b00518f */ 4627 L_3B00517D: 4628 ecx = MEM32(esi); /* 0x3B00517D: mov ecx, dword ptr [esi] */ 4629 /* test ecx, ecx */ /* 0x3B00517F: test ecx, ecx */ 4630 _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx); 4631 _cf = 0; 4632 _flag_k = FK_TEST; 4633 if (TEST_Z(_flag_a, _flag_b)) goto L_3B00518A; /* 0x3B005181: je 0x3b00518a */ 4634 L_3B005183: 4635 RECOMP_ICALL(ecx); /* 0x3B005183: call ecx */ 4636 RECOMP_FLAGS_IN(); 4637 eax = MEM32(0x3B008068); /* 0x3B005185: mov eax, dword ptr [0x3b008068] */ 4638 L_3B00518A: 4639 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(4); 4640 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4641 esi = esi - 4; /* 0x3B00518A: sub esi, 4 */ 4642 _flag_k = FK_CMP; 4643 RECOMP_BACKEDGE(); 4644 goto L_3B005179; /* 0x3B00518D: jmp 0x3b005179 */ 4645 L_3B00518F: 4646 PUSH32(esp, eax); /* 0x3B00518F: push eax */ 4647 RECOMP_ICALL(MEM32(0x3B006028)); /* 0x3B005190: call dword ptr [0x3b006028] */ 4648 RECOMP_FLAGS_IN(); 4649 _flag_a = (uint32_t)(MEM32(0x3B008068)); _flag_b = (uint32_t)(0); 4650 MEM32(0x3B008068) = MEM32(0x3B008068) & 0; /* 0x3B005196: and dword ptr [0x3b008068], 0 */ 4651 _cf = 0; 4652 _flag_k = FK_TEST; 4653 ecx = POP32_VAL(esp); /* 0x3B00519D: pop ecx */ 4654 esi = POP32_VAL(esp); /* 0x3B00519E: pop esi */ 4655 L_3B00519F: 4656 PUSH32(esp, 1); /* 0x3B00519F: push 1 */ 4657 eax = POP32_VAL(esp); /* 0x3B0051A1: pop eax */ 4658 L_3B0051A2: 4659 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3B0051A2: ret 0xc */ 4660 RECOMP_REGS_OUT(); 4661 } 4662 4663 void sub_3B0051A5(void) { 4664 int _fpu_cmp = 0; 4665 uint32_t _cf = 0; 4666 int _df = 1; 4667 uint32_t _flag_k = FK_NONE; 4668 uint32_t _flag_a = 0, _flag_b = 0; 4669 uint32_t _itail_tgt = 0; 4670 RECOMP_REGS_LOCALS 4671 RECOMP_ENTER(0x3B0051A5u); 4672 4673 L_3B0051A5: 4674 PUSH32(esp, ebp); /* 0x3B0051A5: push ebp */ 4675 ebp = esp; /* 0x3B0051A6: mov ebp, esp */ 4676 PUSH32(esp, ebx); /* 0x3B0051A8: push ebx */ 4677 ebx = MEM32(ebp + 0x8); /* 0x3B0051A9: mov ebx, dword ptr [ebp + 8] */ 4678 PUSH32(esp, esi); /* 0x3B0051AC: push esi */ 4679 esi = MEM32(ebp + 0xC); /* 0x3B0051AD: mov esi, dword ptr [ebp + 0xc] */ 4680 PUSH32(esp, edi); /* 0x3B0051B0: push edi */ 4681 edi = MEM32(ebp + 0x10); /* 0x3B0051B1: mov edi, dword ptr [ebp + 0x10] */ 4682 /* test esi, esi */ /* 0x3B0051B4: test esi, esi */ 4683 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi); 4684 _cf = 0; 4685 _flag_k = FK_TEST; 4686 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B0051C1; /* 0x3B0051B6: jne 0x3b0051c1 */ 4687 L_3B0051B8: 4688 /* cmp MEM32(0x3B008058), 0 */ /* 0x3B0051B8: cmp dword ptr [0x3b008058], 0 */ 4689 _flag_a = (uint32_t)(MEM32(0x3B008058)); _flag_b = (uint32_t)(0); 4690 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4691 _flag_k = FK_CMP; 4692 goto L_3B0051E7; /* 0x3B0051BF: jmp 0x3b0051e7 */ 4693 L_3B0051C1: 4694 /* cmp esi, 1 */ /* 0x3B0051C1: cmp esi, 1 */ 4695 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1); 4696 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4697 _flag_k = FK_CMP; 4698 if (CMP_EQ(_flag_a, _flag_b)) goto L_3B0051CB; /* 0x3B0051C4: je 0x3b0051cb */ 4699 L_3B0051C6: 4700 /* cmp esi, 2 */ /* 0x3B0051C6: cmp esi, 2 */ 4701 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(2); 4702 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4703 _flag_k = FK_CMP; 4704 if (CMP_NE(_flag_a, _flag_b)) goto L_3B0051ED; /* 0x3B0051C9: jne 0x3b0051ed */ 4705 L_3B0051CB: 4706 eax = MEM32(0x3B008060); /* 0x3B0051CB: mov eax, dword ptr [0x3b008060] */ 4707 /* test eax, eax */ /* 0x3B0051D0: test eax, eax */ 4708 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 4709 _cf = 0; 4710 _flag_k = FK_TEST; 4711 if (TEST_Z(_flag_a, _flag_b)) goto L_3B0051DD; /* 0x3B0051D2: je 0x3b0051dd */ 4712 L_3B0051D4: 4713 PUSH32(esp, edi); /* 0x3B0051D4: push edi */ 4714 PUSH32(esp, esi); /* 0x3B0051D5: push esi */ 4715 PUSH32(esp, ebx); /* 0x3B0051D6: push ebx */ 4716 RECOMP_ICALL(eax); /* 0x3B0051D7: call eax */ 4717 RECOMP_FLAGS_IN(); 4718 /* test eax, eax */ /* 0x3B0051D9: test eax, eax */ 4719 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 4720 _cf = 0; 4721 _flag_k = FK_TEST; 4722 if (TEST_Z(_flag_a, _flag_b)) goto L_3B0051E9; /* 0x3B0051DB: je 0x3b0051e9 */ 4723 L_3B0051DD: 4724 PUSH32(esp, edi); /* 0x3B0051DD: push edi */ 4725 PUSH32(esp, esi); /* 0x3B0051DE: push esi */ 4726 PUSH32(esp, ebx); /* 0x3B0051DF: push ebx */ 4727 RECOMP_ICALL(0x3B0050FAu); /* 0x3B0051E0: call 0x3b0050fa */ /* not lifted */ 4728 RECOMP_FLAGS_IN(); 4729 /* test eax, eax */ /* 0x3B0051E5: test eax, eax */ 4730 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 4731 _cf = 0; 4732 _flag_k = FK_TEST; 4733 L_3B0051E7: 4734 if (recomp_cond_cf(_flag_k, _flag_a, _flag_b, CC_NE, _cf)) goto L_3B0051ED; /* 0x3B0051E7: jne 0x3b0051ed */ 4735 L_3B0051E9: 4736 _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0); 4737 eax = 0; /* 0x3B0051E9: xor eax, eax */ 4738 _cf = 0; 4739 _flag_k = FK_TEST; 4740 goto L_3B00523B; /* 0x3B0051EB: jmp 0x3b00523b */ 4741 L_3B0051ED: 4742 PUSH32(esp, edi); /* 0x3B0051ED: push edi */ 4743 PUSH32(esp, esi); /* 0x3B0051EE: push esi */ 4744 PUSH32(esp, ebx); /* 0x3B0051EF: push ebx */ 4745 RECOMP_ICALL(0x3B00524Eu); /* 0x3B0051F0: call 0x3b00524e */ /* not lifted */ 4746 RECOMP_FLAGS_IN(); 4747 /* cmp esi, 1 */ /* 0x3B0051F5: cmp esi, 1 */ 4748 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1); 4749 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4750 _flag_k = FK_CMP; 4751 MEM32(ebp + 0xC) = eax; /* 0x3B0051F8: mov dword ptr [ebp + 0xc], eax */ 4752 if (CMP_NE(_flag_a, _flag_b)) goto L_3B005209; /* 0x3B0051FB: jne 0x3b005209 */ 4753 L_3B0051FD: 4754 /* test eax, eax */ /* 0x3B0051FD: test eax, eax */ 4755 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 4756 _cf = 0; 4757 _flag_k = FK_TEST; 4758 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B005238; /* 0x3B0051FF: jne 0x3b005238 */ 4759 L_3B005201: 4760 PUSH32(esp, edi); /* 0x3B005201: push edi */ 4761 PUSH32(esp, eax); /* 0x3B005202: push eax */ 4762 PUSH32(esp, ebx); /* 0x3B005203: push ebx */ 4763 RECOMP_ICALL(0x3B0050FAu); /* 0x3B005204: call 0x3b0050fa */ /* not lifted */ 4764 RECOMP_FLAGS_IN(); 4765 L_3B005209: 4766 /* test esi, esi */ /* 0x3B005209: test esi, esi */ 4767 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi); 4768 _cf = 0; 4769 _flag_k = FK_TEST; 4770 if (TEST_Z(_flag_a, _flag_b)) goto L_3B005212; /* 0x3B00520B: je 0x3b005212 */ 4771 L_3B00520D: 4772 /* cmp esi, 3 */ /* 0x3B00520D: cmp esi, 3 */ 4773 _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(3); 4774 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4775 _flag_k = FK_CMP; 4776 if (CMP_NE(_flag_a, _flag_b)) goto L_3B005238; /* 0x3B005210: jne 0x3b005238 */ 4777 L_3B005212: 4778 PUSH32(esp, edi); /* 0x3B005212: push edi */ 4779 PUSH32(esp, esi); /* 0x3B005213: push esi */ 4780 PUSH32(esp, ebx); /* 0x3B005214: push ebx */ 4781 RECOMP_ICALL(0x3B0050FAu); /* 0x3B005215: call 0x3b0050fa */ /* not lifted */ 4782 RECOMP_FLAGS_IN(); 4783 /* test eax, eax */ /* 0x3B00521A: test eax, eax */ 4784 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 4785 _cf = 0; 4786 _flag_k = FK_TEST; 4787 if (TEST_NZ(_flag_a, _flag_b)) goto L_3B005221; /* 0x3B00521C: jne 0x3b005221 */ 4788 L_3B00521E: 4789 _flag_a = (uint32_t)(MEM32(ebp + 0xC)); _flag_b = (uint32_t)(eax); 4790 MEM32(ebp + 0xC) = MEM32(ebp + 0xC) & eax; /* 0x3B00521E: and dword ptr [ebp + 0xc], eax */ 4791 _cf = 0; 4792 _flag_k = FK_TEST; 4793 L_3B005221: 4794 /* cmp MEM32(ebp + 0xC), 0 */ /* 0x3B005221: cmp dword ptr [ebp + 0xc], 0 */ 4795 _flag_a = (uint32_t)(MEM32(ebp + 0xC)); _flag_b = (uint32_t)(0); 4796 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4797 _flag_k = FK_CMP; 4798 if (CMP_EQ(_flag_a, _flag_b)) goto L_3B005238; /* 0x3B005225: je 0x3b005238 */ 4799 L_3B005227: 4800 eax = MEM32(0x3B008060); /* 0x3B005227: mov eax, dword ptr [0x3b008060] */ 4801 /* test eax, eax */ /* 0x3B00522C: test eax, eax */ 4802 _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax); 4803 _cf = 0; 4804 _flag_k = FK_TEST; 4805 if (TEST_Z(_flag_a, _flag_b)) goto L_3B005238; /* 0x3B00522E: je 0x3b005238 */ 4806 L_3B005230: 4807 PUSH32(esp, edi); /* 0x3B005230: push edi */ 4808 PUSH32(esp, esi); /* 0x3B005231: push esi */ 4809 PUSH32(esp, ebx); /* 0x3B005232: push ebx */ 4810 RECOMP_ICALL(eax); /* 0x3B005233: call eax */ 4811 RECOMP_FLAGS_IN(); 4812 MEM32(ebp + 0xC) = eax; /* 0x3B005235: mov dword ptr [ebp + 0xc], eax */ 4813 L_3B005238: 4814 eax = MEM32(ebp + 0xC); /* 0x3B005238: mov eax, dword ptr [ebp + 0xc] */ 4815 L_3B00523B: 4816 edi = POP32_VAL(esp); /* 0x3B00523B: pop edi */ 4817 esi = POP32_VAL(esp); /* 0x3B00523C: pop esi */ 4818 ebx = POP32_VAL(esp); /* 0x3B00523D: pop ebx */ 4819 ebp = POP32_VAL(esp); /* 0x3B00523E: pop ebp */ 4820 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3B00523F: ret 0xc */ 4821 RECOMP_REGS_OUT(); 4822 } 4823 4824 void sub_3B005242(void) { 4825 int _fpu_cmp = 0; 4826 uint32_t _cf = 0; 4827 int _df = 1; 4828 uint32_t _flag_k = FK_NONE; 4829 uint32_t _flag_a = 0, _flag_b = 0; 4830 uint32_t _itail_tgt = 0; 4831 RECOMP_REGS_LOCALS 4832 RECOMP_ENTER(0x3B005242u); 4833 4834 L_3B005242: 4835 { _itail_tgt = (uint32_t)(MEM32(0x3B006020)); goto _ljump; } 4836 { RECOMP_REGS_OUT(); return; } /* end of function */ 4837 _ljump: 4838 switch (_itail_tgt) { 4839 case 0x3B005242u: goto L_3B005242; 4840 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4841 } 4842 RECOMP_REGS_OUT(); 4843 } 4844 4845 void sub_3B005248(void) { 4846 int _fpu_cmp = 0; 4847 uint32_t _cf = 0; 4848 int _df = 1; 4849 uint32_t _flag_k = FK_NONE; 4850 uint32_t _flag_a = 0, _flag_b = 0; 4851 uint32_t _itail_tgt = 0; 4852 RECOMP_REGS_LOCALS 4853 RECOMP_ENTER(0x3B005248u); 4854 4855 L_3B005248: 4856 { _itail_tgt = (uint32_t)(MEM32(0x3B00601C)); goto _ljump; } 4857 { RECOMP_REGS_OUT(); return; } /* end of function */ 4858 _ljump: 4859 switch (_itail_tgt) { 4860 case 0x3B005248u: goto L_3B005248; 4861 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4862 } 4863 RECOMP_REGS_OUT(); 4864 } 4865 4866 void sub_3B00524E(void) { 4867 int _fpu_cmp = 0; 4868 uint32_t _cf = 0; 4869 int _df = 1; 4870 uint32_t _flag_k = FK_NONE; 4871 uint32_t _flag_a = 0, _flag_b = 0; 4872 uint32_t _itail_tgt = 0; 4873 RECOMP_REGS_LOCALS 4874 RECOMP_ENTER(0x3B00524Eu); 4875 4876 L_3B00524E: 4877 /* cmp MEM32(esp + 0x8), 1 */ /* 0x3B00524E: cmp dword ptr [esp + 8], 1 */ 4878 _flag_a = (uint32_t)(MEM32(esp + 0x8)); _flag_b = (uint32_t)(1); 4879 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4880 _flag_k = FK_CMP; 4881 if (CMP_NE(_flag_a, _flag_b)) goto L_3B005268; /* 0x3B005253: jne 0x3b005268 */ 4882 L_3B005255: 4883 /* cmp MEM32(0x3B008060), 0 */ /* 0x3B005255: cmp dword ptr [0x3b008060], 0 */ 4884 _flag_a = (uint32_t)(MEM32(0x3B008060)); _flag_b = (uint32_t)(0); 4885 _cf = (uint32_t)CMP_B(_flag_a, _flag_b); 4886 _flag_k = FK_CMP; 4887 if (CMP_NE(_flag_a, _flag_b)) goto L_3B005268; /* 0x3B00525C: jne 0x3b005268 */ 4888 L_3B00525E: 4889 PUSH32(esp, MEM32(esp + 0x4)); /* 0x3B00525E: push dword ptr [esp + 4] */ 4890 RECOMP_ICALL(MEM32(0x3B006000)); /* 0x3B005262: call dword ptr [0x3b006000] */ 4891 RECOMP_FLAGS_IN(); 4892 L_3B005268: 4893 PUSH32(esp, 1); /* 0x3B005268: push 1 */ 4894 eax = POP32_VAL(esp); /* 0x3B00526A: pop eax */ 4895 RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3B00526B: ret 0xc */ 4896 RECOMP_REGS_OUT(); 4897 } 4898 4899 void sub_3B005270(void) { 4900 int _fpu_cmp = 0; 4901 uint32_t _cf = 0; 4902 int _df = 1; 4903 uint32_t _flag_k = FK_NONE; 4904 uint32_t _flag_a = 0, _flag_b = 0; 4905 uint32_t _itail_tgt = 0; 4906 RECOMP_REGS_LOCALS 4907 RECOMP_ENTER(0x3B005270u); 4908 4909 goto L_3B005270; 4910 L_3B002D00: 4911 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B002D00: ret */ 4912 L_3B005270: 4913 ecx = ebp + (-0x4C); /* 0x3B005270: lea ecx, [ebp - 0x4c] */ 4914 RECOMP_BACKEDGE(); 4915 goto L_3B002D00; /* 0x3B005273: jmp 0x3b002d00 */ 4916 { RECOMP_REGS_OUT(); return; } /* end of function */ 4917 RECOMP_REGS_OUT(); 4918 } 4919 4920 void sub_3B005278(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(0x3B005278u); 4929 4930 goto L_3B005278; 4931 L_3B0050B6: 4932 { _itail_tgt = (uint32_t)(MEM32(0x3B00603C)); goto _ljump; } 4933 L_3B005278: 4934 eax = 0x3B006088u; /* 0x3B005278: mov eax, 0x3b006088 */ 4935 L_3B00527D: 4936 RECOMP_BACKEDGE(); 4937 goto L_3B0050B6; /* 0x3B00527D: jmp 0x3b0050b6 */ 4938 { RECOMP_REGS_OUT(); return; } /* end of function */ 4939 _ljump: 4940 switch (_itail_tgt) { 4941 case 0x3B0050B6u: goto L_3B0050B6; 4942 case 0x3B005278u: goto L_3B005278; 4943 case 0x3B00527Du: goto L_3B00527D; 4944 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4945 } 4946 RECOMP_REGS_OUT(); 4947 } 4948 4949 void sub_3B005290(void) { 4950 int _fpu_cmp = 0; 4951 uint32_t _cf = 0; 4952 int _df = 1; 4953 uint32_t _flag_k = FK_NONE; 4954 uint32_t _flag_a = 0, _flag_b = 0; 4955 uint32_t _itail_tgt = 0; 4956 RECOMP_REGS_LOCALS 4957 RECOMP_ENTER(0x3B005290u); 4958 4959 goto L_3B005290; 4960 L_3B002D00: 4961 RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3B002D00: ret */ 4962 L_3B005290: 4963 ecx = ebp + (-0x4C); /* 0x3B005290: lea ecx, [ebp - 0x4c] */ 4964 RECOMP_BACKEDGE(); 4965 goto L_3B002D00; /* 0x3B005293: jmp 0x3b002d00 */ 4966 { RECOMP_REGS_OUT(); return; } /* end of function */ 4967 RECOMP_REGS_OUT(); 4968 } 4969 4970 void sub_3B005298(void) { 4971 int _fpu_cmp = 0; 4972 uint32_t _cf = 0; 4973 int _df = 1; 4974 uint32_t _flag_k = FK_NONE; 4975 uint32_t _flag_a = 0, _flag_b = 0; 4976 uint32_t _itail_tgt = 0; 4977 RECOMP_REGS_LOCALS 4978 RECOMP_ENTER(0x3B005298u); 4979 4980 goto L_3B005298; 4981 L_3B0050B6: 4982 { _itail_tgt = (uint32_t)(MEM32(0x3B00603C)); goto _ljump; } 4983 L_3B005298: 4984 eax = 0x3B0060B0u; /* 0x3B005298: mov eax, 0x3b0060b0 */ 4985 L_3B00529D: 4986 RECOMP_BACKEDGE(); 4987 goto L_3B0050B6; /* 0x3B00529D: jmp 0x3b0050b6 */ 4988 { RECOMP_REGS_OUT(); return; } /* end of function */ 4989 _ljump: 4990 switch (_itail_tgt) { 4991 case 0x3B0050B6u: goto L_3B0050B6; 4992 case 0x3B005298u: goto L_3B005298; 4993 case 0x3B00529Du: goto L_3B00529D; 4994 default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; } 4995 } 4996 RECOMP_REGS_OUT(); 4997 }