aorecomp

Anarchy Online classic in the browser

git clone https://aorecomp.ubeagle.com/code/aorecomp.git


client/game/llr.dll/lifted-0018.c (789523B)


      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_3802B1B0(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(0x3802B1B0u);
     17 
     18 L_3802B1B0:
     19     PUSH32(esp, ebp); /* 0x3802B1B0: push ebp */
     20     ebp = esp; /* 0x3802B1B1: mov ebp, esp */
     21     PUSH32(esp, ebx); /* 0x3802B1B3: push ebx */
     22     PUSH32(esp, esi); /* 0x3802B1B4: push esi */
     23     PUSH32(esp, edi); /* 0x3802B1B5: push edi */
     24     edi = MEM32(0x3804E648); /* 0x3802B1B6: mov edi, dword ptr [0x3804e648] */
     25     ebx = ecx; /* 0x3802B1BC: mov ebx, ecx */
     26     ecx = MEM32(ebp + 0x8); /* 0x3802B1BE: mov ecx, dword ptr [ebp + 8] */
     27     RECOMP_ICALL(edi); /* 0x3802B1C1: call edi */
     28     RECOMP_FLAGS_IN();
     29     esi = eax; /* 0x3802B1C3: mov esi, eax */
     30     eax = MEM32(esi); /* 0x3802B1C5: mov eax, dword ptr [esi] */
     31     ecx = esi; /* 0x3802B1C7: mov ecx, esi */
     32     RECOMP_ICALL(MEM32(eax + 0x10)); /* 0x3802B1C9: call dword ptr [eax + 0x10] */
     33     RECOMP_FLAGS_IN();
     34     /* cmp eax, 1 */ /* 0x3802B1CC: cmp eax, 1 */
     35     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
     36     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
     37     _flag_k = FK_CMP;
     38     if (CMP_NE(_flag_a, _flag_b)) goto L_3802B1D8; /* 0x3802B1CF: jne 0x3802b1d8 */
     39 L_3802B1D1:
     40     edi = POP32_VAL(esp); /* 0x3802B1D1: pop edi */
     41     esi = POP32_VAL(esp); /* 0x3802B1D2: pop esi */
     42     ebx = POP32_VAL(esp); /* 0x3802B1D3: pop ebx */
     43     ebp = POP32_VAL(esp); /* 0x3802B1D4: pop ebp */
     44     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802B1D5: ret 8 */
     45 L_3802B1D8:
     46     ecx = MEM32(ebp + 0xC); /* 0x3802B1D8: mov ecx, dword ptr [ebp + 0xc] */
     47     RECOMP_ICALL(edi); /* 0x3802B1DB: call edi */
     48     RECOMP_FLAGS_IN();
     49     edi = eax; /* 0x3802B1DD: mov edi, eax */
     50     edx = MEM32(edi); /* 0x3802B1DF: mov edx, dword ptr [edi] */
     51     ecx = edi; /* 0x3802B1E1: mov ecx, edi */
     52     RECOMP_ICALL(MEM32(edx + 0x10)); /* 0x3802B1E3: call dword ptr [edx + 0x10] */
     53     RECOMP_FLAGS_IN();
     54     /* cmp eax, 1 */ /* 0x3802B1E6: cmp eax, 1 */
     55     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
     56     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
     57     _flag_k = FK_CMP;
     58     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802B210; /* 0x3802B1E9: je 0x3802b210 */
     59 L_3802B1EB:
     60     eax = MEM32(esi); /* 0x3802B1EB: mov eax, dword ptr [esi] */
     61     ecx = esi; /* 0x3802B1ED: mov ecx, esi */
     62     RECOMP_ICALL(MEM32(eax + 0x10)); /* 0x3802B1EF: call dword ptr [eax + 0x10] */
     63     RECOMP_FLAGS_IN();
     64     /* test eax, eax */ /* 0x3802B1F2: test eax, eax */
     65     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
     66     _cf = 0;
     67     _flag_k = FK_TEST;
     68     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802B201; /* 0x3802B1F4: jne 0x3802b201 */
     69 L_3802B1F6:
     70     edx = MEM32(edi); /* 0x3802B1F6: mov edx, dword ptr [edi] */
     71     ecx = edi; /* 0x3802B1F8: mov ecx, edi */
     72     RECOMP_ICALL(MEM32(edx + 0x10)); /* 0x3802B1FA: call dword ptr [edx + 0x10] */
     73     RECOMP_FLAGS_IN();
     74     /* test eax, eax */ /* 0x3802B1FD: test eax, eax */
     75     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
     76     _cf = 0;
     77     _flag_k = FK_TEST;
     78     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B210; /* 0x3802B1FF: je 0x3802b210 */
     79 L_3802B201:
     80     eax = MEM32(esi); /* 0x3802B201: mov eax, dword ptr [esi] */
     81     ecx = ebx + 0x10; /* 0x3802B203: lea ecx, [ebx + 0x10] */
     82     PUSH32(esp, ecx); /* 0x3802B206: push ecx */
     83     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(4);
     84     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
     85     ebx = ebx + 4; /* 0x3802B207: add ebx, 4 */
     86     _flag_k = FK_ADD;
     87     PUSH32(esp, ebx); /* 0x3802B20A: push ebx */
     88     PUSH32(esp, edi); /* 0x3802B20B: push edi */
     89     ecx = esi; /* 0x3802B20C: mov ecx, esi */
     90     RECOMP_ICALL(MEM32(eax)); /* 0x3802B20E: call dword ptr [eax] */
     91     RECOMP_FLAGS_IN();
     92 L_3802B210:
     93     edi = POP32_VAL(esp); /* 0x3802B210: pop edi */
     94     esi = POP32_VAL(esp); /* 0x3802B211: pop esi */
     95     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
     96     eax = 0; /* 0x3802B212: xor eax, eax */
     97     _cf = 0;
     98     _flag_k = FK_TEST;
     99     ebx = POP32_VAL(esp); /* 0x3802B214: pop ebx */
    100     ebp = POP32_VAL(esp); /* 0x3802B215: pop ebp */
    101     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802B216: ret 8 */
    102     RECOMP_REGS_OUT();
    103 }
    104 
    105 void sub_3802B220(void) {
    106     int _fpu_cmp = 0;
    107     uint32_t _cf = 0;
    108     int _df = 1;
    109     uint32_t _flag_k = FK_NONE;
    110     uint32_t _flag_a = 0, _flag_b = 0;
    111     uint32_t _itail_tgt = 0;
    112     RECOMP_REGS_LOCALS
    113     RECOMP_ENTER(0x3802B220u);
    114 
    115 L_3802B220:
    116     PUSH32(esp, ebp); /* 0x3802B220: push ebp */
    117     ebp = esp; /* 0x3802B221: mov ebp, esp */
    118     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x18u);
    119     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    120     esp = esp - 0x18u; /* 0x3802B223: sub esp, 0x18 */
    121     _flag_k = FK_CMP;
    122     PUSH32(esp, ebx); /* 0x3802B226: push ebx */
    123     PUSH32(esp, esi); /* 0x3802B227: push esi */
    124     esi = ecx; /* 0x3802B228: mov esi, ecx */
    125     ecx = MEM32(ebp + 0x8); /* 0x3802B22A: mov ecx, dword ptr [ebp + 8] */
    126     PUSH32(esp, edi); /* 0x3802B22D: push edi */
    127     RECOMP_ICALL(MEM32(0x3804E648)); /* 0x3802B22E: call dword ptr [0x3804e648] */
    128     RECOMP_FLAGS_IN();
    129     /* test eax, eax */ /* 0x3802B234: test eax, eax */
    130     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
    131     _cf = 0;
    132     _flag_k = FK_TEST;
    133     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B23D; /* 0x3802B236: je 0x3802b23d */
    134 L_3802B238:
    135     ebx = eax + (-0x1C); /* 0x3802B238: lea ebx, [eax - 0x1c] */
    136     goto L_3802B23F; /* 0x3802B23B: jmp 0x3802b23f */
    137 L_3802B23D:
    138     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
    139     ebx = 0; /* 0x3802B23D: xor ebx, ebx */
    140     _cf = 0;
    141     _flag_k = FK_TEST;
    142 L_3802B23F:
    143     edi = MEM32(esi + 0x8); /* 0x3802B23F: mov edi, dword ptr [esi + 8] */
    144     ecx = ebx; /* 0x3802B242: mov ecx, ebx */
    145     RECOMP_ICALL(0x38017F50u); /* 0x3802B244: call 0x38017f50 */ /* not lifted */
    146     RECOMP_FLAGS_IN();
    147     ecx = MEM32(eax); /* 0x3802B249: mov ecx, dword ptr [eax] */
    148     edx = MEM32(eax + 0x4); /* 0x3802B24B: mov edx, dword ptr [eax + 4] */
    149     eax = MEM32(eax + 0x8); /* 0x3802B24E: mov eax, dword ptr [eax + 8] */
    150     MEM32(ebp + (-0x18)) = ecx; /* 0x3802B251: mov dword ptr [ebp - 0x18], ecx */
    151     fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x3802B254: fld dword ptr [ebp - 0x18] */
    152     _st[0] -= (double)*(float*)ADDR(edi); /* 0x3802B257: fsub dword ptr [edi] */
    153     ecx = MEM32(esi + 0x18); /* 0x3802B259: mov ecx, dword ptr [esi + 0x18] */
    154     MEM32(ebp + (-0x14)) = edx; /* 0x3802B25C: mov dword ptr [ebp - 0x14], edx */
    155     fp_push(*(float*)&MEM32(ebp + (-0x14))); /* 0x3802B25F: fld dword ptr [ebp - 0x14] */
    156     _st[0] -= (double)*(float*)ADDR(edi + 0x4); /* 0x3802B262: fsub dword ptr [edi + 4] */
    157     MEM32(ebp + (-0x10)) = eax; /* 0x3802B265: mov dword ptr [ebp - 0x10], eax */
    158     fp_push(*(float*)&MEM32(ebp + (-0x10))); /* 0x3802B268: fld dword ptr [ebp - 0x10] */
    159     eax = MEM32(esi + 0x14); /* 0x3802B26B: mov eax, dword ptr [esi + 0x14] */
    160     _st[0] -= (double)*(float*)ADDR(edi + 0x8); /* 0x3802B26E: fsub dword ptr [edi + 8] */
    161     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0xCu);
    162     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    163     esi = esi + 0xCu; /* 0x3802B271: add esi, 0xc */
    164     _flag_k = FK_ADD;
    165     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
    166     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    167     ecx = ecx - eax; /* 0x3802B274: sub ecx, eax */
    168     _flag_k = FK_CMP;
    169     if (3u) _cf = (((ecx) >> 2) & 1u); /* 0x3802B276: sar ecx, 3 */
    170     if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
    171     ecx = (uint32_t)((int32_t)ecx >> 3u);
    172     /* cmp ecx, 1 */ /* 0x3802B279: cmp ecx, 1 */
    173     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
    174     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    175     _flag_k = FK_CMP;
    176     fp_push(_st[1]); /* 0x3802B27C: fld st(1) */
    177     _st[0] *= _st[2]; /* 0x3802B27E: fmul st(2) */
    178     MEM32(ebp + (-0xC)) = ebx; /* 0x3802B280: mov dword ptr [ebp - 0xc], ebx */
    179     fp_push(_st[1]); /* 0x3802B283: fld st(1) */
    180     edi = eax; /* 0x3802B285: mov edi, eax */
    181     _st[0] *= _st[2]; /* 0x3802B287: fmul st(2) */
    182     { double _v = fp_pop(); _st[0] += _v; } /* 0x3802B289: faddp st(1) */
    183     fp_push(_st[3]); /* 0x3802B28B: fld st(3) */
    184     _st[0] *= _st[4]; /* 0x3802B28D: fmul st(4) */
    185     { double _v = fp_pop(); _st[0] += _v; } /* 0x3802B28F: faddp st(1) */
    186     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802B291: fstp dword ptr [ebp - 8] */
    187     { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3802B294: fstp st(0) */
    188     { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3802B296: fstp st(0) */
    189     { _st[0] = _st[0]; g_st_i64[0] = g_st_i64[0]; fp_pop(); } /* 0x3802B298: fstp st(0) */
    190     if (CMP_AE(_flag_a, _flag_b)) goto L_3802B353; /* 0x3802B29A: jae 0x3802b353 */
    191 L_3802B2A0:
    192     edx = MEM32(esi + 0x4); /* 0x3802B2A0: mov edx, dword ptr [esi + 4] */
    193     /* test edx, edx */ /* 0x3802B2A3: test edx, edx */
    194     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
    195     _cf = 0;
    196     _flag_k = FK_TEST;
    197     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B2B3; /* 0x3802B2A5: je 0x3802b2b3 */
    198 L_3802B2A7:
    199     ecx = eax; /* 0x3802B2A7: mov ecx, eax */
    200     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
    201     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    202     ecx = ecx - edx; /* 0x3802B2A9: sub ecx, edx */
    203     _flag_k = FK_CMP;
    204     if (3u) _cf = (((ecx) >> 2) & 1u); /* 0x3802B2AB: sar ecx, 3 */
    205     if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
    206     ecx = (uint32_t)((int32_t)ecx >> 3u);
    207     /* cmp ecx, 1 */ /* 0x3802B2AE: cmp ecx, 1 */
    208     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
    209     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    210     _flag_k = FK_CMP;
    211     if (CMP_A(_flag_a, _flag_b)) goto L_3802B2B8; /* 0x3802B2B1: ja 0x3802b2b8 */
    212 L_3802B2B3:
    213     ecx = 1; /* 0x3802B2B3: mov ecx, 1 */
    214 L_3802B2B8:
    215     /* test edx, edx */ /* 0x3802B2B8: test edx, edx */
    216     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
    217     _cf = 0;
    218     _flag_k = FK_TEST;
    219     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802B2C0; /* 0x3802B2BA: jne 0x3802b2c0 */
    220 L_3802B2BC:
    221     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
    222     eax = 0; /* 0x3802B2BC: xor eax, eax */
    223     _cf = 0;
    224     _flag_k = FK_TEST;
    225     goto L_3802B2C5; /* 0x3802B2BE: jmp 0x3802b2c5 */
    226 L_3802B2C0:
    227     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
    228     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    229     eax = eax - edx; /* 0x3802B2C0: sub eax, edx */
    230     _flag_k = FK_CMP;
    231     if (3u) _cf = (((eax) >> 2) & 1u); /* 0x3802B2C2: sar eax, 3 */
    232     if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
    233     eax = (uint32_t)((int32_t)eax >> 3u);
    234 L_3802B2C5:
    235     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
    236     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    237     eax = eax + ecx; /* 0x3802B2C5: add eax, ecx */
    238     _flag_k = FK_ADD;
    239     /* test eax, eax */ /* 0x3802B2C7: test eax, eax */
    240     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
    241     _cf = 0;
    242     _flag_k = FK_TEST;
    243     MEM32(ebp + (-0x4)) = eax; /* 0x3802B2C9: mov dword ptr [ebp - 4], eax */
    244     if (TEST_NS(_flag_a, _flag_b)) goto L_3802B2D0; /* 0x3802B2CC: jge 0x3802b2d0 */
    245 L_3802B2CE:
    246     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
    247     eax = 0; /* 0x3802B2CE: xor eax, eax */
    248     _cf = 0;
    249     _flag_k = FK_TEST;
    250 L_3802B2D0:
    251     edx = eax * 8; /* 0x3802B2D0: lea edx, [eax*8] */
    252     PUSH32(esp, edx); /* 0x3802B2D7: push edx */
    253     RECOMP_ICALL(0x3804B676u); /* 0x3802B2D8: call 0x3804b676 */ /* not lifted */
    254     RECOMP_FLAGS_IN();
    255     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
    256     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    257     esp = esp + 4; /* 0x3802B2DD: add esp, 4 */
    258     _flag_k = FK_ADD;
    259     ebx = eax; /* 0x3802B2E0: mov ebx, eax */
    260     eax = MEM32(esi + 0x4); /* 0x3802B2E2: mov eax, dword ptr [esi + 4] */
    261     PUSH32(esp, ebx); /* 0x3802B2E5: push ebx */
    262     PUSH32(esp, edi); /* 0x3802B2E6: push edi */
    263     PUSH32(esp, eax); /* 0x3802B2E7: push eax */
    264     ecx = esi; /* 0x3802B2E8: mov ecx, esi */
    265     RECOMP_ICALL(0x3800FE40u); /* 0x3802B2EA: call 0x3800fe40 */ /* not lifted */
    266     RECOMP_FLAGS_IN();
    267     ecx = ebp + (-0xC); /* 0x3802B2EF: lea ecx, [ebp - 0xc] */
    268     PUSH32(esp, ecx); /* 0x3802B2F2: push ecx */
    269     PUSH32(esp, 1); /* 0x3802B2F3: push 1 */
    270     PUSH32(esp, eax); /* 0x3802B2F5: push eax */
    271     ecx = esi; /* 0x3802B2F6: mov ecx, esi */
    272     MEM32(ebp + 0x8) = eax; /* 0x3802B2F8: mov dword ptr [ebp + 8], eax */
    273     RECOMP_ICALL(0x3802F0D0u); /* 0x3802B2FB: call 0x3802f0d0 */ /* not lifted */
    274     RECOMP_FLAGS_IN();
    275     edx = MEM32(ebp + 0x8); /* 0x3802B300: mov edx, dword ptr [ebp + 8] */
    276     eax = MEM32(esi + 0x8); /* 0x3802B303: mov eax, dword ptr [esi + 8] */
    277     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(8);
    278     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    279     edx = edx + 8; /* 0x3802B306: add edx, 8 */
    280     _flag_k = FK_ADD;
    281     PUSH32(esp, edx); /* 0x3802B309: push edx */
    282     PUSH32(esp, eax); /* 0x3802B30A: push eax */
    283     PUSH32(esp, edi); /* 0x3802B30B: push edi */
    284     ecx = esi; /* 0x3802B30C: mov ecx, esi */
    285     RECOMP_ICALL(0x3800FE40u); /* 0x3802B30E: call 0x3800fe40 */ /* not lifted */
    286     RECOMP_FLAGS_IN();
    287     ecx = MEM32(esi + 0x8); /* 0x3802B313: mov ecx, dword ptr [esi + 8] */
    288     edx = MEM32(esi + 0x4); /* 0x3802B316: mov edx, dword ptr [esi + 4] */
    289     PUSH32(esp, ecx); /* 0x3802B319: push ecx */
    290     PUSH32(esp, edx); /* 0x3802B31A: push edx */
    291     ecx = esi; /* 0x3802B31B: mov ecx, esi */
    292     RECOMP_ICALL(0x38042760u); /* 0x3802B31D: call 0x38042760 */ /* not lifted */
    293     RECOMP_FLAGS_IN();
    294     eax = MEM32(esi + 0x4); /* 0x3802B322: mov eax, dword ptr [esi + 4] */
    295     PUSH32(esp, eax); /* 0x3802B325: push eax */
    296     RECOMP_ICALL(0x3804B4F6u); /* 0x3802B326: call 0x3804b4f6 */ /* not lifted */
    297     RECOMP_FLAGS_IN();
    298     ecx = MEM32(ebp + (-0x4)); /* 0x3802B32B: mov ecx, dword ptr [ebp - 4] */
    299     edx = ebx + ecx * 8; /* 0x3802B32E: lea edx, [ebx + ecx*8] */
    300     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
    301     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    302     esp = esp + 4; /* 0x3802B331: add esp, 4 */
    303     _flag_k = FK_ADD;
    304     ecx = esi; /* 0x3802B334: mov ecx, esi */
    305     MEM32(esi + 0xC) = edx; /* 0x3802B336: mov dword ptr [esi + 0xc], edx */
    306     RECOMP_ICALL(0x3802F0B0u); /* 0x3802B339: call 0x3802f0b0 */ /* not lifted */
    307     RECOMP_FLAGS_IN();
    308     eax = ebx + eax * 8 + 0x8; /* 0x3802B33E: lea eax, [ebx + eax*8 + 8] */
    309     edi = POP32_VAL(esp); /* 0x3802B342: pop edi */
    310     MEM32(esi + 0x8) = eax; /* 0x3802B343: mov dword ptr [esi + 8], eax */
    311     MEM32(esi + 0x4) = ebx; /* 0x3802B346: mov dword ptr [esi + 4], ebx */
    312     esi = POP32_VAL(esp); /* 0x3802B349: pop esi */
    313     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
    314     eax = 0; /* 0x3802B34A: xor eax, eax */
    315     _cf = 0;
    316     _flag_k = FK_TEST;
    317     ebx = POP32_VAL(esp); /* 0x3802B34C: pop ebx */
    318     esp = ebp; /* 0x3802B34D: mov esp, ebp */
    319     ebp = POP32_VAL(esp); /* 0x3802B34F: pop ebp */
    320     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802B350: ret 4 */
    321 L_3802B353:
    322     ecx = eax; /* 0x3802B353: mov ecx, eax */
    323     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
    324     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    325     ecx = ecx - edi; /* 0x3802B355: sub ecx, edi */
    326     _flag_k = FK_CMP;
    327     if (3u) _cf = (((ecx) >> 2) & 1u); /* 0x3802B357: sar ecx, 3 */
    328     if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
    329     ecx = (uint32_t)((int32_t)ecx >> 3u);
    330     /* cmp ecx, 1 */ /* 0x3802B35A: cmp ecx, 1 */
    331     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
    332     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    333     _flag_k = FK_CMP;
    334     if (CMP_AE(_flag_a, _flag_b)) goto L_3802B3B7; /* 0x3802B35D: jae 0x3802b3b7 */
    335 L_3802B35F:
    336     edx = edi + 0x8; /* 0x3802B35F: lea edx, [edi + 8] */
    337     PUSH32(esp, edx); /* 0x3802B362: push edx */
    338     PUSH32(esp, eax); /* 0x3802B363: push eax */
    339     PUSH32(esp, edi); /* 0x3802B364: push edi */
    340     ecx = esi; /* 0x3802B365: mov ecx, esi */
    341     RECOMP_ICALL(0x3800FE40u); /* 0x3802B367: call 0x3800fe40 */ /* not lifted */
    342     RECOMP_FLAGS_IN();
    343     eax = MEM32(esi + 0x8); /* 0x3802B36C: mov eax, dword ptr [esi + 8] */
    344     edx = eax; /* 0x3802B36F: mov edx, eax */
    345     ecx = ebp + (-0xC); /* 0x3802B371: lea ecx, [ebp - 0xc] */
    346     PUSH32(esp, ecx); /* 0x3802B374: push ecx */
    347     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edi);
    348     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    349     edx = edx - edi; /* 0x3802B375: sub edx, edi */
    350     _flag_k = FK_CMP;
    351     if (3u) _cf = (((edx) >> 2) & 1u); /* 0x3802B377: sar edx, 3 */
    352     if (3u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 3u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
    353     edx = (uint32_t)((int32_t)edx >> 3u);
    354     ecx = 1; /* 0x3802B37A: mov ecx, 1 */
    355     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
    356     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    357     ecx = ecx - edx; /* 0x3802B37F: sub ecx, edx */
    358     _flag_k = FK_CMP;
    359     PUSH32(esp, ecx); /* 0x3802B381: push ecx */
    360     PUSH32(esp, eax); /* 0x3802B382: push eax */
    361     ecx = esi; /* 0x3802B383: mov ecx, esi */
    362     RECOMP_ICALL(0x3802F0D0u); /* 0x3802B385: call 0x3802f0d0 */ /* not lifted */
    363     RECOMP_FLAGS_IN();
    364     eax = MEM32(esi + 0x8); /* 0x3802B38A: mov eax, dword ptr [esi + 8] */
    365     /* cmp edi, eax */ /* 0x3802B38D: cmp edi, eax */
    366     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
    367     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    368     _flag_k = FK_CMP;
    369     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802B3FE; /* 0x3802B38F: je 0x3802b3fe */
    370 L_3802B391:
    371     edx = MEM32(ebp + (-0xC)); /* 0x3802B391: mov edx, dword ptr [ebp - 0xc] */
    372     MEM32(edi) = edx; /* 0x3802B394: mov dword ptr [edi], edx */
    373     ecx = MEM32(ebp + (-0x8)); /* 0x3802B396: mov ecx, dword ptr [ebp - 8] */
    374     MEM32(edi + 0x4) = ecx; /* 0x3802B399: mov dword ptr [edi + 4], ecx */
    375     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(8);
    376     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    377     edi = edi + 8; /* 0x3802B39C: add edi, 8 */
    378     _flag_k = FK_ADD;
    379     /* cmp edi, eax */ /* 0x3802B39F: cmp edi, eax */
    380     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
    381     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    382     _flag_k = FK_CMP;
    383     RECOMP_BACKEDGE();
    384     if (CMP_NE(_flag_a, _flag_b)) goto L_3802B391; /* 0x3802B3A1: jne 0x3802b391 */
    385 L_3802B3A3:
    386     eax = MEM32(esi + 0x8); /* 0x3802B3A3: mov eax, dword ptr [esi + 8] */
    387     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(8);
    388     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    389     eax = eax + 8; /* 0x3802B3A6: add eax, 8 */
    390     _flag_k = FK_ADD;
    391     edi = POP32_VAL(esp); /* 0x3802B3A9: pop edi */
    392     MEM32(esi + 0x8) = eax; /* 0x3802B3AA: mov dword ptr [esi + 8], eax */
    393     esi = POP32_VAL(esp); /* 0x3802B3AD: pop esi */
    394     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
    395     eax = 0; /* 0x3802B3AE: xor eax, eax */
    396     _cf = 0;
    397     _flag_k = FK_TEST;
    398     ebx = POP32_VAL(esp); /* 0x3802B3B0: pop ebx */
    399     esp = ebp; /* 0x3802B3B1: mov esp, ebp */
    400     ebp = POP32_VAL(esp); /* 0x3802B3B3: pop ebp */
    401     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802B3B4: ret 4 */
    402 L_3802B3B7:
    403     PUSH32(esp, eax); /* 0x3802B3B7: push eax */
    404     PUSH32(esp, eax); /* 0x3802B3B8: push eax */
    405     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xFFFFFFF8u);
    406     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    407     eax = eax + 0xFFFFFFF8u; /* 0x3802B3B9: add eax, -8 */
    408     _flag_k = FK_ADD;
    409     PUSH32(esp, eax); /* 0x3802B3BC: push eax */
    410     ecx = esi; /* 0x3802B3BD: mov ecx, esi */
    411     RECOMP_ICALL(0x3800FE40u); /* 0x3802B3BF: call 0x3800fe40 */ /* not lifted */
    412     RECOMP_FLAGS_IN();
    413     ecx = MEM32(esi + 0x8); /* 0x3802B3C4: mov ecx, dword ptr [esi + 8] */
    414     eax = ecx + (-0x8); /* 0x3802B3C7: lea eax, [ecx - 8] */
    415     /* cmp edi, eax */ /* 0x3802B3CA: cmp edi, eax */
    416     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
    417     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    418     _flag_k = FK_CMP;
    419     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802B3E3; /* 0x3802B3CC: je 0x3802b3e3 */
    420 L_3802B3CE:
    421     edx = MEM32(eax + (-0x8)); /* 0x3802B3CE: mov edx, dword ptr [eax - 8] */
    422     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(8);
    423     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    424     eax = eax - 8; /* 0x3802B3D1: sub eax, 8 */
    425     _flag_k = FK_CMP;
    426     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(8);
    427     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    428     ecx = ecx - 8; /* 0x3802B3D4: sub ecx, 8 */
    429     _flag_k = FK_CMP;
    430     /* cmp eax, edi */ /* 0x3802B3D7: cmp eax, edi */
    431     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
    432     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    433     _flag_k = FK_CMP;
    434     MEM32(ecx) = edx; /* 0x3802B3D9: mov dword ptr [ecx], edx */
    435     edx = MEM32(eax + 0x4); /* 0x3802B3DB: mov edx, dword ptr [eax + 4] */
    436     MEM32(ecx + 0x4) = edx; /* 0x3802B3DE: mov dword ptr [ecx + 4], edx */
    437     RECOMP_BACKEDGE();
    438     if (CMP_NE(_flag_a, _flag_b)) goto L_3802B3CE; /* 0x3802B3E1: jne 0x3802b3ce */
    439 L_3802B3E3:
    440     ecx = edi + 0x8; /* 0x3802B3E3: lea ecx, [edi + 8] */
    441     /* cmp edi, ecx */ /* 0x3802B3E6: cmp edi, ecx */
    442     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx);
    443     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    444     _flag_k = FK_CMP;
    445     eax = edi; /* 0x3802B3E8: mov eax, edi */
    446     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802B3FE; /* 0x3802B3EA: je 0x3802b3fe */
    447 L_3802B3EC:
    448     edx = MEM32(ebp + (-0xC)); /* 0x3802B3EC: mov edx, dword ptr [ebp - 0xc] */
    449     MEM32(eax) = edx; /* 0x3802B3EF: mov dword ptr [eax], edx */
    450     edx = MEM32(ebp + (-0x8)); /* 0x3802B3F1: mov edx, dword ptr [ebp - 8] */
    451     MEM32(eax + 0x4) = edx; /* 0x3802B3F4: mov dword ptr [eax + 4], edx */
    452     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(8);
    453     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    454     eax = eax + 8; /* 0x3802B3F7: add eax, 8 */
    455     _flag_k = FK_ADD;
    456     /* cmp eax, ecx */ /* 0x3802B3FA: cmp eax, ecx */
    457     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
    458     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    459     _flag_k = FK_CMP;
    460     RECOMP_BACKEDGE();
    461     if (CMP_NE(_flag_a, _flag_b)) goto L_3802B3EC; /* 0x3802B3FC: jne 0x3802b3ec */
    462 L_3802B3FE:
    463     eax = MEM32(esi + 0x8); /* 0x3802B3FE: mov eax, dword ptr [esi + 8] */
    464     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(8);
    465     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    466     eax = eax + 8; /* 0x3802B401: add eax, 8 */
    467     _flag_k = FK_ADD;
    468     edi = POP32_VAL(esp); /* 0x3802B404: pop edi */
    469     MEM32(esi + 0x8) = eax; /* 0x3802B405: mov dword ptr [esi + 8], eax */
    470     esi = POP32_VAL(esp); /* 0x3802B408: pop esi */
    471     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
    472     eax = 0; /* 0x3802B409: xor eax, eax */
    473     _cf = 0;
    474     _flag_k = FK_TEST;
    475     ebx = POP32_VAL(esp); /* 0x3802B40B: pop ebx */
    476     esp = ebp; /* 0x3802B40C: mov esp, ebp */
    477     ebp = POP32_VAL(esp); /* 0x3802B40E: pop ebp */
    478     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802B40F: ret 4 */
    479     RECOMP_REGS_OUT();
    480 }
    481 
    482 void sub_3802B420(void) {
    483     int _fpu_cmp = 0;
    484     uint32_t _cf = 0;
    485     int _df = 1;
    486     uint32_t _flag_k = FK_NONE;
    487     uint32_t _flag_a = 0, _flag_b = 0;
    488     uint32_t _itail_tgt = 0;
    489     RECOMP_REGS_LOCALS
    490     RECOMP_ENTER(0x3802B420u);
    491 
    492 L_3802B420:
    493     PUSH32(esp, ebp); /* 0x3802B420: push ebp */
    494     ebp = esp; /* 0x3802B421: mov ebp, esp */
    495     PUSH32(esp, ecx); /* 0x3802B423: push ecx */
    496     PUSH32(esp, esi); /* 0x3802B424: push esi */
    497     esi = ecx; /* 0x3802B425: mov esi, ecx */
    498     eax = MEM32(esi + 0x10); /* 0x3802B427: mov eax, dword ptr [esi + 0x10] */
    499     PUSH32(esp, eax); /* 0x3802B42A: push eax */
    500     MEM32(ebp + (-0x4)) = eax; /* 0x3802B42B: mov dword ptr [ebp - 4], eax */
    501     RECOMP_ICALL(0x3804B4F6u); /* 0x3802B42E: call 0x3804b4f6 */ /* not lifted */
    502     RECOMP_FLAGS_IN();
    503     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
    504     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    505     esp = esp + 4; /* 0x3802B433: add esp, 4 */
    506     _flag_k = FK_ADD;
    507     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
    508     eax = 0; /* 0x3802B436: xor eax, eax */
    509     _cf = 0;
    510     _flag_k = FK_TEST;
    511     MEM32(esi + 0x10) = eax; /* 0x3802B438: mov dword ptr [esi + 0x10], eax */
    512     MEM32(esi + 0x14) = eax; /* 0x3802B43B: mov dword ptr [esi + 0x14], eax */
    513     MEM32(esi + 0x18) = eax; /* 0x3802B43E: mov dword ptr [esi + 0x18], eax */
    514     esi = POP32_VAL(esp); /* 0x3802B441: pop esi */
    515     esp = ebp; /* 0x3802B442: mov esp, ebp */
    516     ebp = POP32_VAL(esp); /* 0x3802B444: pop ebp */
    517     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802B445: ret  */
    518     RECOMP_REGS_OUT();
    519 }
    520 
    521 void sub_3802B450(void) {
    522     int _fpu_cmp = 0;
    523     uint32_t _cf = 0;
    524     int _df = 1;
    525     uint32_t _flag_k = FK_NONE;
    526     uint32_t _flag_a = 0, _flag_b = 0;
    527     uint32_t _itail_tgt = 0;
    528     RECOMP_REGS_LOCALS
    529     RECOMP_ENTER(0x3802B450u);
    530 
    531 L_3802B450:
    532     PUSH32(esp, ebp); /* 0x3802B450: push ebp */
    533     ebp = esp; /* 0x3802B451: mov ebp, esp */
    534     PUSH32(esp, esi); /* 0x3802B453: push esi */
    535     esi = ecx; /* 0x3802B454: mov esi, ecx */
    536     eax = MEM32(esi); /* 0x3802B456: mov eax, dword ptr [esi] */
    537     PUSH32(esp, edi); /* 0x3802B458: push edi */
    538     RECOMP_ICALL(MEM32(eax + 0x64)); /* 0x3802B459: call dword ptr [eax + 0x64] */
    539     RECOMP_FLAGS_IN();
    540     eax = MEM32(esi + 0x74); /* 0x3802B45C: mov eax, dword ptr [esi + 0x74] */
    541     edi = MEM32(eax + 0x4); /* 0x3802B45F: mov edi, dword ptr [eax + 4] */
    542     /* cmp edi, MEM32(eax + 0x8) */ /* 0x3802B462: cmp edi, dword ptr [eax + 8] */
    543     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(eax + 0x8));
    544     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    545     _flag_k = FK_CMP;
    546     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802B481; /* 0x3802B465: je 0x3802b481 */
    547 L_3802B467:
    548     PUSH32(esp, ebx); /* 0x3802B467: push ebx */
    549     ebx = MEM32(ebp + 0x8); /* 0x3802B468: mov ebx, dword ptr [ebp + 8] */
    550 L_3802B46B:
    551     PUSH32(esp, ebx); /* 0x3802B46B: push ebx */
    552     ecx = edi; /* 0x3802B46C: mov ecx, edi */
    553     RECOMP_ICALL(0x3801B640u); /* 0x3802B46E: call 0x3801b640 */ /* not lifted */
    554     RECOMP_FLAGS_IN();
    555     ecx = MEM32(esi + 0x74); /* 0x3802B473: mov ecx, dword ptr [esi + 0x74] */
    556     eax = MEM32(ecx + 0x8); /* 0x3802B476: mov eax, dword ptr [ecx + 8] */
    557     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(8);
    558     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    559     edi = edi + 8; /* 0x3802B479: add edi, 8 */
    560     _flag_k = FK_ADD;
    561     /* cmp edi, eax */ /* 0x3802B47C: cmp edi, eax */
    562     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
    563     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    564     _flag_k = FK_CMP;
    565     RECOMP_BACKEDGE();
    566     if (CMP_NE(_flag_a, _flag_b)) goto L_3802B46B; /* 0x3802B47E: jne 0x3802b46b */
    567 L_3802B480:
    568     ebx = POP32_VAL(esp); /* 0x3802B480: pop ebx */
    569 L_3802B481:
    570     eax = MEM32(esi + 0x78); /* 0x3802B481: mov eax, dword ptr [esi + 0x78] */
    571     edi = MEM32(eax + 0x4); /* 0x3802B484: mov edi, dword ptr [eax + 4] */
    572     /* cmp edi, MEM32(eax + 0x8) */ /* 0x3802B487: cmp edi, dword ptr [eax + 8] */
    573     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(eax + 0x8));
    574     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    575     _flag_k = FK_CMP;
    576     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802B4A0; /* 0x3802B48A: je 0x3802b4a0 */
    577 L_3802B48C:
    578     ecx = MEM32(edi); /* 0x3802B48C: mov ecx, dword ptr [edi] */
    579     edx = MEM32(ecx); /* 0x3802B48E: mov edx, dword ptr [ecx] */
    580     RECOMP_ICALL(MEM32(edx + 0x20)); /* 0x3802B490: call dword ptr [edx + 0x20] */
    581     RECOMP_FLAGS_IN();
    582     eax = MEM32(esi + 0x78); /* 0x3802B493: mov eax, dword ptr [esi + 0x78] */
    583     ecx = MEM32(eax + 0x8); /* 0x3802B496: mov ecx, dword ptr [eax + 8] */
    584     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(4);
    585     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    586     edi = edi + 4; /* 0x3802B499: add edi, 4 */
    587     _flag_k = FK_ADD;
    588     /* cmp edi, ecx */ /* 0x3802B49C: cmp edi, ecx */
    589     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx);
    590     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    591     _flag_k = FK_CMP;
    592     RECOMP_BACKEDGE();
    593     if (CMP_NE(_flag_a, _flag_b)) goto L_3802B48C; /* 0x3802B49E: jne 0x3802b48c */
    594 L_3802B4A0:
    595     edi = POP32_VAL(esp); /* 0x3802B4A0: pop edi */
    596     MEM8(esi + 0x6C) = (uint8_t)(1); /* 0x3802B4A1: mov byte ptr [esi + 0x6c], 1 */
    597     MEM32(esi + 0x70) = 2; /* 0x3802B4A5: mov dword ptr [esi + 0x70], 2 */
    598     esi = POP32_VAL(esp); /* 0x3802B4AC: pop esi */
    599     ebp = POP32_VAL(esp); /* 0x3802B4AD: pop ebp */
    600     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802B4AE: ret 4 */
    601     RECOMP_REGS_OUT();
    602 }
    603 
    604 void sub_3802B4C0(void) {
    605     int _fpu_cmp = 0;
    606     uint32_t _cf = 0;
    607     int _df = 1;
    608     uint32_t _flag_k = FK_NONE;
    609     uint32_t _flag_a = 0, _flag_b = 0;
    610     uint32_t _itail_tgt = 0;
    611     RECOMP_REGS_LOCALS
    612     RECOMP_ENTER(0x3802B4C0u);
    613 
    614 L_3802B4C0:
    615     SET_LO8(eax, MEM8(ecx + 0x6C)); /* 0x3802B4C0: mov al, byte ptr [ecx + 0x6c] */
    616     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802B4C3: ret  */
    617     RECOMP_REGS_OUT();
    618 }
    619 
    620 void sub_3802B4D0(void) {
    621     int _fpu_cmp = 0;
    622     uint32_t _cf = 0;
    623     int _df = 1;
    624     uint32_t _flag_k = FK_NONE;
    625     uint32_t _flag_a = 0, _flag_b = 0;
    626     uint32_t _itail_tgt = 0;
    627     RECOMP_REGS_LOCALS
    628     RECOMP_ENTER(0x3802B4D0u);
    629 
    630 L_3802B4D0:
    631     PUSH32(esp, ebp); /* 0x3802B4D0: push ebp */
    632     ebp = esp; /* 0x3802B4D1: mov ebp, esp */
    633     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
    634     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    635     esp = esp - 8; /* 0x3802B4D3: sub esp, 8 */
    636     _flag_k = FK_CMP;
    637     PUSH32(esp, ebx); /* 0x3802B4D6: push ebx */
    638     PUSH32(esp, esi); /* 0x3802B4D7: push esi */
    639     PUSH32(esp, edi); /* 0x3802B4D8: push edi */
    640     ebx = ecx; /* 0x3802B4D9: mov ebx, ecx */
    641     RECOMP_ICALL(0x38029E80u); /* 0x3802B4DB: call 0x38029e80 */ /* not lifted */
    642     RECOMP_FLAGS_IN();
    643     ecx = ebx; /* 0x3802B4E0: mov ecx, ebx */
    644     esi = eax; /* 0x3802B4E2: mov esi, eax */
    645     RECOMP_ICALL(0x3802D200u); /* 0x3802B4E4: call 0x3802d200 */ /* not lifted */
    646     RECOMP_FLAGS_IN();
    647     /* test LO8(eax), LO8(eax) */ /* 0x3802B4E9: test al, al */
    648     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
    649     _cf = 0;
    650     _flag_k = FK_NARROW(FK_TEST, 24);
    651     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B50E; /* 0x3802B4EB: je 0x3802b50e */
    652 L_3802B4ED:
    653     eax = MEM32(ebp + 0x8); /* 0x3802B4ED: mov eax, dword ptr [ebp + 8] */
    654     PUSH32(esp, 0xFFFFFFFFu); /* 0x3802B4F0: push -1 */
    655     PUSH32(esp, eax); /* 0x3802B4F2: push eax */
    656     ecx = ebx; /* 0x3802B4F3: mov ecx, ebx */
    657     RECOMP_ICALL(0x3802B820u); /* 0x3802B4F5: call 0x3802b820 */ /* not lifted */
    658     RECOMP_FLAGS_IN();
    659     /* test eax, eax */ /* 0x3802B4FA: test eax, eax */
    660     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
    661     _cf = 0;
    662     _flag_k = FK_TEST;
    663     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B5E6; /* 0x3802B4FC: je 0x3802b5e6 */
    664 L_3802B502:
    665     eax = MEM32(eax + 0xC); /* 0x3802B502: mov eax, dword ptr [eax + 0xc] */
    666     edi = POP32_VAL(esp); /* 0x3802B505: pop edi */
    667     esi = POP32_VAL(esp); /* 0x3802B506: pop esi */
    668     ebx = POP32_VAL(esp); /* 0x3802B507: pop ebx */
    669     esp = ebp; /* 0x3802B508: mov esp, ebp */
    670     ebp = POP32_VAL(esp); /* 0x3802B50A: pop ebp */
    671     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802B50B: ret 4 */
    672 L_3802B50E:
    673     edi = MEM32(ebp + 0x8); /* 0x3802B50E: mov edi, dword ptr [ebp + 8] */
    674     fp_push(*(float*)&MEM32(edi)); /* 0x3802B511: fld dword ptr [edi] */
    675     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x3802B513: fcomp dword ptr [0x3804e8e4] */
    676     fp_pop();
    677     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802B519: fnstsw ax */
    678     /* test HI8(eax), 1 */ /* 0x3802B51B: test ah, 1 */
    679     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
    680     _cf = 0;
    681     _flag_k = FK_NARROW(FK_TEST, 24);
    682     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802B5E6; /* 0x3802B51E: jne 0x3802b5e6 */
    683 L_3802B524:
    684     ecx = MEM32(esi + 0xC); /* 0x3802B524: mov ecx, dword ptr [esi + 0xc] */
    685     fp_push(*(float*)&MEM32(ecx + 0x8264)); /* 0x3802B527: fld dword ptr [ecx + 0x8264] */
    686     ecx = esi; /* 0x3802B52D: mov ecx, esi */
    687     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B52F: fstp dword ptr [ebp - 4] */
    688     RECOMP_ICALL(0x38039DA0u); /* 0x3802B532: call 0x38039da0 */ /* not lifted */
    689     RECOMP_FLAGS_IN();
    690     MEM32(ebp + 0x8) = eax; /* 0x3802B537: mov dword ptr [ebp + 8], eax */
    691     fp_push((double)(int32_t)MEM32(ebp + 0x8)); /* 0x3802B53A: fild dword ptr [ebp + 8] */
    692     _st[0] *= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3802B53D: fmul dword ptr [ebp - 4] */
    693     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(edi)); /* 0x3802B540: fcomp dword ptr [edi] */
    694     fp_pop();
    695     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802B542: fnstsw ax */
    696     /* test HI8(eax), 0x41u */ /* 0x3802B544: test ah, 0x41 */
    697     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24;
    698     _cf = 0;
    699     _flag_k = FK_NARROW(FK_TEST, 24);
    700     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802B5E6; /* 0x3802B547: jne 0x3802b5e6 */
    701 L_3802B54D:
    702     fp_push(*(float*)&MEM32(edi + 0x8)); /* 0x3802B54D: fld dword ptr [edi + 8] */
    703     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x3802B550: fcomp dword ptr [0x3804e8e4] */
    704     fp_pop();
    705     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802B556: fnstsw ax */
    706     /* test HI8(eax), 1 */ /* 0x3802B558: test ah, 1 */
    707     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
    708     _cf = 0;
    709     _flag_k = FK_NARROW(FK_TEST, 24);
    710     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802B5E6; /* 0x3802B55B: jne 0x3802b5e6 */
    711 L_3802B561:
    712     edx = MEM32(esi + 0xC); /* 0x3802B561: mov edx, dword ptr [esi + 0xc] */
    713     fp_push(*(float*)&MEM32(edx + 0x8264)); /* 0x3802B564: fld dword ptr [edx + 0x8264] */
    714     ecx = esi; /* 0x3802B56A: mov ecx, esi */
    715     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B56C: fstp dword ptr [ebp - 4] */
    716     RECOMP_ICALL(0x38039DB0u); /* 0x3802B56F: call 0x38039db0 */ /* not lifted */
    717     RECOMP_FLAGS_IN();
    718     MEM32(ebp + 0x8) = eax; /* 0x3802B574: mov dword ptr [ebp + 8], eax */
    719     fp_push((double)(int32_t)MEM32(ebp + 0x8)); /* 0x3802B577: fild dword ptr [ebp + 8] */
    720     _st[0] *= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3802B57A: fmul dword ptr [ebp - 4] */
    721     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(edi + 0x8)); /* 0x3802B57D: fcomp dword ptr [edi + 8] */
    722     fp_pop();
    723     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802B580: fnstsw ax */
    724     /* test HI8(eax), 0x41u */ /* 0x3802B582: test ah, 0x41 */
    725     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24;
    726     _cf = 0;
    727     _flag_k = FK_NARROW(FK_TEST, 24);
    728     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802B5E6; /* 0x3802B585: jne 0x3802b5e6 */
    729 L_3802B587:
    730     fp_push((double)(int32_t)MEM32(ebx + 0x58)); /* 0x3802B587: fild dword ptr [ebx + 0x58] */
    731     eax = MEM32(esi + 0xC); /* 0x3802B58A: mov eax, dword ptr [esi + 0xc] */
    732     ecx = esi; /* 0x3802B58D: mov ecx, esi */
    733     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + 0x8) = _v; } /* 0x3802B58F: fstp dword ptr [ebp + 8] */
    734     fp_push(*(float*)&MEM32(eax + 0x8264)); /* 0x3802B592: fld dword ptr [eax + 0x8264] */
    735     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B598: fstp dword ptr [ebp - 4] */
    736     RECOMP_ICALL(0x38039DA0u); /* 0x3802B59B: call 0x38039da0 */ /* not lifted */
    737     RECOMP_FLAGS_IN();
    738     MEM32(ebp + (-0x8)) = eax; /* 0x3802B5A0: mov dword ptr [ebp - 8], eax */
    739     fp_push((double)(int32_t)MEM32(ebp + (-0x8))); /* 0x3802B5A3: fild dword ptr [ebp - 8] */
    740     _st[0] /= (double)*(float*)ADDR(ebp + 0x8); /* 0x3802B5A6: fdiv dword ptr [ebp + 8] */
    741     RECOMP_ICALL(0x3804B688u); /* 0x3802B5A9: call 0x3804b688 */ /* not lifted */
    742     RECOMP_FLAGS_IN();
    743     fp_push(*(float*)&MEM32(edi + 0x8)); /* 0x3802B5AE: fld dword ptr [edi + 8] */
    744     _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3802B5B1: fdiv dword ptr [ebp - 4] */
    745     esi = eax; /* 0x3802B5B4: mov esi, eax */
    746     RECOMP_ICALL(0x3804B688u); /* 0x3802B5B6: call 0x3804b688 */ /* not lifted */
    747     RECOMP_FLAGS_IN();
    748     MEM32(ebp + (-0x8)) = eax; /* 0x3802B5BB: mov dword ptr [ebp - 8], eax */
    749     fp_push((double)(int32_t)MEM32(ebp + (-0x8))); /* 0x3802B5BE: fild dword ptr [ebp - 8] */
    750     _st[0] /= (double)*(float*)ADDR(ebp + 0x8); /* 0x3802B5C1: fdiv dword ptr [ebp + 8] */
    751     RECOMP_ICALL(0x3804B688u); /* 0x3802B5C4: call 0x3804b688 */ /* not lifted */
    752     RECOMP_FLAGS_IN();
    753     fp_push(*(float*)&MEM32(edi)); /* 0x3802B5C9: fld dword ptr [edi] */
    754     _st[0] /= (double)*(float*)ADDR(ebp + (-0x4)); /* 0x3802B5CB: fdiv dword ptr [ebp - 4] */
    755     ebx = eax; /* 0x3802B5CE: mov ebx, eax */
    756     ebx = (uint32_t)((int32_t)ebx * (int32_t)esi); /* 0x3802B5D0: imul ebx, esi */
    757     _st[0] /= (double)*(float*)ADDR(ebp + 0x8); /* 0x3802B5D3: fdiv dword ptr [ebp + 8] */
    758     RECOMP_ICALL(0x3804B688u); /* 0x3802B5D6: call 0x3804b688 */ /* not lifted */
    759     RECOMP_FLAGS_IN();
    760     edi = POP32_VAL(esp); /* 0x3802B5DB: pop edi */
    761     esi = POP32_VAL(esp); /* 0x3802B5DC: pop esi */
    762     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
    763     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    764     eax = eax + ebx; /* 0x3802B5DD: add eax, ebx */
    765     _flag_k = FK_ADD;
    766     ebx = POP32_VAL(esp); /* 0x3802B5DF: pop ebx */
    767     esp = ebp; /* 0x3802B5E0: mov esp, ebp */
    768     ebp = POP32_VAL(esp); /* 0x3802B5E2: pop ebp */
    769     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802B5E3: ret 4 */
    770 L_3802B5E6:
    771     edi = POP32_VAL(esp); /* 0x3802B5E6: pop edi */
    772     esi = POP32_VAL(esp); /* 0x3802B5E7: pop esi */
    773     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
    774     eax = 0; /* 0x3802B5E8: xor eax, eax */
    775     _cf = 0;
    776     _flag_k = FK_TEST;
    777     ebx = POP32_VAL(esp); /* 0x3802B5EA: pop ebx */
    778     esp = ebp; /* 0x3802B5EB: mov esp, ebp */
    779     ebp = POP32_VAL(esp); /* 0x3802B5ED: pop ebp */
    780     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802B5EE: ret 4 */
    781     RECOMP_REGS_OUT();
    782 }
    783 
    784 void sub_3802B600(void) {
    785     int _fpu_cmp = 0;
    786     uint32_t _cf = 0;
    787     int _df = 1;
    788     uint32_t _flag_k = FK_NONE;
    789     uint32_t _flag_a = 0, _flag_b = 0;
    790     uint32_t _itail_tgt = 0;
    791     RECOMP_REGS_LOCALS
    792     RECOMP_ENTER(0x3802B600u);
    793 
    794 L_3802B600:
    795     PUSH32(esp, ebp); /* 0x3802B600: push ebp */
    796     ebp = esp; /* 0x3802B601: mov ebp, esp */
    797     PUSH32(esp, esi); /* 0x3802B603: push esi */
    798     PUSH32(esp, edi); /* 0x3802B604: push edi */
    799     esi = ecx; /* 0x3802B605: mov esi, ecx */
    800     RECOMP_ICALL(0x38029E80u); /* 0x3802B607: call 0x38029e80 */ /* not lifted */
    801     RECOMP_FLAGS_IN();
    802     esi = MEM32(esi + 0x58); /* 0x3802B60C: mov esi, dword ptr [esi + 0x58] */
    803     edi = eax; /* 0x3802B60F: mov edi, eax */
    804     ecx = edi; /* 0x3802B611: mov ecx, edi */
    805     RECOMP_ICALL(0x38039DA0u); /* 0x3802B613: call 0x38039da0 */ /* not lifted */
    806     RECOMP_FLAGS_IN();
    807     edx = ((int32_t)eax < 0) ? 0xFFFFFFFFu : 0; /* 0x3802B618: cdq  */
    808     { int64_t _dividend = ((int64_t)(int32_t)edx << 32) | eax; int32_t _dv = (int32_t)esi; /* 0x3802B619: idiv esi */
    809       if (_dv && !(_dv == -1 && _dividend == INT64_MIN)) { eax = (uint32_t)((int32_t)(_dividend / _dv)); edx = (uint32_t)((int32_t)(_dividend % _dv)); }
    810       else { eax = 0; edx = 0; } }
    811     ecx = edi; /* 0x3802B61B: mov ecx, edi */
    812     esi = eax; /* 0x3802B61D: mov esi, eax */
    813     RECOMP_ICALL(0x38039DB0u); /* 0x3802B61F: call 0x38039db0 */ /* not lifted */
    814     RECOMP_FLAGS_IN();
    815     ecx = MEM32(ebp + 0x8); /* 0x3802B624: mov ecx, dword ptr [ebp + 8] */
    816     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
    817     edx = 0; /* 0x3802B627: xor edx, edx */
    818     _cf = 0;
    819     _flag_k = FK_TEST;
    820     eax = ecx; /* 0x3802B629: mov eax, ecx */
    821     { uint64_t _dividend = ((uint64_t)edx << 32) | eax; uint32_t _dv = (uint32_t)esi; /* 0x3802B62B: div esi */
    822       if (_dv) { eax = (uint32_t)(_dividend / _dv); edx = (uint32_t)(_dividend % _dv); }
    823       else { eax = 0; edx = 0; } }
    824     edx = MEM32(ebp + 0x10); /* 0x3802B62D: mov edx, dword ptr [ebp + 0x10] */
    825     edi = POP32_VAL(esp); /* 0x3802B630: pop edi */
    826     MEM32(edx) = eax; /* 0x3802B631: mov dword ptr [edx], eax */
    827     eax = ecx; /* 0x3802B633: mov eax, ecx */
    828     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
    829     edx = 0; /* 0x3802B635: xor edx, edx */
    830     _cf = 0;
    831     _flag_k = FK_TEST;
    832     { uint64_t _dividend = ((uint64_t)edx << 32) | eax; uint32_t _dv = (uint32_t)esi; /* 0x3802B637: div esi */
    833       if (_dv) { eax = (uint32_t)(_dividend / _dv); edx = (uint32_t)(_dividend % _dv); }
    834       else { eax = 0; edx = 0; } }
    835     eax = MEM32(ebp + 0xC); /* 0x3802B639: mov eax, dword ptr [ebp + 0xc] */
    836     esi = POP32_VAL(esp); /* 0x3802B63C: pop esi */
    837     MEM32(eax) = edx; /* 0x3802B63D: mov dword ptr [eax], edx */
    838     ebp = POP32_VAL(esp); /* 0x3802B63F: pop ebp */
    839     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802B640: ret 0xc */
    840     RECOMP_REGS_OUT();
    841 }
    842 
    843 void sub_3802B650(void) {
    844     int _fpu_cmp = 0;
    845     uint32_t _cf = 0;
    846     int _df = 1;
    847     uint32_t _flag_k = FK_NONE;
    848     uint32_t _flag_a = 0, _flag_b = 0;
    849     uint32_t _itail_tgt = 0;
    850     RECOMP_REGS_LOCALS
    851     RECOMP_ENTER(0x3802B650u);
    852 
    853 L_3802B650:
    854     PUSH32(esp, ebp); /* 0x3802B650: push ebp */
    855     ebp = esp; /* 0x3802B651: mov ebp, esp */
    856     PUSH32(esp, esi); /* 0x3802B653: push esi */
    857     esi = MEM32(ecx + 0x58); /* 0x3802B654: mov esi, dword ptr [ecx + 0x58] */
    858     RECOMP_ICALL(0x38029E80u); /* 0x3802B657: call 0x38029e80 */ /* not lifted */
    859     RECOMP_FLAGS_IN();
    860     ecx = eax; /* 0x3802B65C: mov ecx, eax */
    861     RECOMP_ICALL(0x38039DA0u); /* 0x3802B65E: call 0x38039da0 */ /* not lifted */
    862     RECOMP_FLAGS_IN();
    863     edx = ((int32_t)eax < 0) ? 0xFFFFFFFFu : 0; /* 0x3802B663: cdq  */
    864     { int64_t _dividend = ((int64_t)(int32_t)edx << 32) | eax; int32_t _dv = (int32_t)esi; /* 0x3802B664: idiv esi */
    865       if (_dv && !(_dv == -1 && _dividend == INT64_MIN)) { eax = (uint32_t)((int32_t)(_dividend / _dv)); edx = (uint32_t)((int32_t)(_dividend % _dv)); }
    866       else { eax = 0; edx = 0; } }
    867     ecx = MEM32(ebp + 0x8); /* 0x3802B666: mov ecx, dword ptr [ebp + 8] */
    868     esi = POP32_VAL(esp); /* 0x3802B669: pop esi */
    869     eax = (uint32_t)((int32_t)eax * (int32_t)MEM32(ebp + 0xC)); /* 0x3802B66A: imul eax, dword ptr [ebp + 0xc] */
    870     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
    871     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    872     eax = eax + ecx; /* 0x3802B66E: add eax, ecx */
    873     _flag_k = FK_ADD;
    874     ebp = POP32_VAL(esp); /* 0x3802B670: pop ebp */
    875     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802B671: ret 8 */
    876     RECOMP_REGS_OUT();
    877 }
    878 
    879 void sub_3802B680(void) {
    880     int _fpu_cmp = 0;
    881     uint32_t _cf = 0;
    882     int _df = 1;
    883     uint32_t _flag_k = FK_NONE;
    884     uint32_t _flag_a = 0, _flag_b = 0;
    885     uint32_t _itail_tgt = 0;
    886     RECOMP_REGS_LOCALS
    887     RECOMP_ENTER(0x3802B680u);
    888 
    889 L_3802B680:
    890     PUSH32(esp, ebp); /* 0x3802B680: push ebp */
    891     ebp = esp; /* 0x3802B681: mov ebp, esp */
    892     eax = MEM32(ecx + 0x8C); /* 0x3802B683: mov eax, dword ptr [ecx + 0x8c] */
    893     /* test eax, eax */ /* 0x3802B689: test eax, eax */
    894     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
    895     _cf = 0;
    896     _flag_k = FK_TEST;
    897     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802B6C6; /* 0x3802B68B: jne 0x3802b6c6 */
    898 L_3802B68D:
    899     eax = MEM32(ecx + 0x88); /* 0x3802B68D: mov eax, dword ptr [ecx + 0x88] */
    900     edx = MEM32(eax + 0x4); /* 0x3802B693: mov edx, dword ptr [eax + 4] */
    901     /* test edx, edx */ /* 0x3802B696: test edx, edx */
    902     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
    903     _cf = 0;
    904     _flag_k = FK_TEST;
    905     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B6B1; /* 0x3802B698: je 0x3802b6b1 */
    906 L_3802B69A:
    907     PUSH32(esp, esi); /* 0x3802B69A: push esi */
    908     esi = MEM32(eax + 0x8); /* 0x3802B69B: mov esi, dword ptr [eax + 8] */
    909     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
    910     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    911     esi = esi - edx; /* 0x3802B69E: sub esi, edx */
    912     _flag_k = FK_CMP;
    913     /* test esi, 0xFFFFFFFCu */ /* 0x3802B6A0: test esi, 0xfffffffc */
    914     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0xFFFFFFFCu);
    915     _cf = 0;
    916     _flag_k = FK_TEST;
    917     esi = POP32_VAL(esp); /* 0x3802B6A6: pop esi */
    918     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B6B1; /* 0x3802B6A7: je 0x3802b6b1 */
    919 L_3802B6A9:
    920     MEM32(ecx + 0x8C) = eax; /* 0x3802B6A9: mov dword ptr [ecx + 0x8c], eax */
    921     goto L_3802B6C0; /* 0x3802B6AF: jmp 0x3802b6c0 */
    922 L_3802B6B1:
    923     eax = MEM32(ecx + 0x98); /* 0x3802B6B1: mov eax, dword ptr [ecx + 0x98] */
    924     edx = MEM32(eax + 0x44); /* 0x3802B6B7: mov edx, dword ptr [eax + 0x44] */
    925     MEM32(ecx + 0x8C) = edx; /* 0x3802B6BA: mov dword ptr [ecx + 0x8c], edx */
    926 L_3802B6C0:
    927     eax = MEM32(ecx + 0x8C); /* 0x3802B6C0: mov eax, dword ptr [ecx + 0x8c] */
    928 L_3802B6C6:
    929     eax = MEM32(eax + 0x4); /* 0x3802B6C6: mov eax, dword ptr [eax + 4] */
    930     ecx = MEM32(ebp + 0x8); /* 0x3802B6C9: mov ecx, dword ptr [ebp + 8] */
    931     edx = MEM32(eax + ecx * 4); /* 0x3802B6CC: mov edx, dword ptr [eax + ecx*4] */
    932     eax = MEM32(edx + 0x8); /* 0x3802B6CF: mov eax, dword ptr [edx + 8] */
    933     ebp = POP32_VAL(esp); /* 0x3802B6D2: pop ebp */
    934     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802B6D3: ret 4 */
    935     RECOMP_REGS_OUT();
    936 }
    937 
    938 void sub_3802B6E0(void) {
    939     int _fpu_cmp = 0;
    940     uint32_t _cf = 0;
    941     int _df = 1;
    942     uint32_t _flag_k = FK_NONE;
    943     uint32_t _flag_a = 0, _flag_b = 0;
    944     uint32_t _itail_tgt = 0;
    945     RECOMP_REGS_LOCALS
    946     RECOMP_ENTER(0x3802B6E0u);
    947 
    948 L_3802B6E0:
    949     goto L_3802B6F0; /* 0x3802B6E0: jmp 0x3802b6f0 */
    950 L_3802B6F0:
    951     PUSH32(esp, ebp); /* 0x3802B6F0: push ebp */
    952     ebp = esp; /* 0x3802B6F1: mov ebp, esp */
    953     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x14u);
    954     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    955     esp = esp - 0x14u; /* 0x3802B6F3: sub esp, 0x14 */
    956     _flag_k = FK_CMP;
    957     fp_push(*(double*)ADDR(0x3804E928)); /* 0x3802B6F6: fld qword ptr [0x3804e928] */
    958     _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3802B6FC: fsin  */
    959     fp_push(*(float*)&MEM32(0x3804E8E4)); /* 0x3802B6FE: fld dword ptr [0x3804e8e4] */
    960     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B704: fst dword ptr [ebp - 4] */
    961     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802B707: fstp dword ptr [ebp - 0x14] */
    962     eax = MEM32(ebp + (-0x4)); /* 0x3802B70A: mov eax, dword ptr [ebp - 4] */
    963     ecx = MEM32(ebp + (-0x14)); /* 0x3802B70D: mov ecx, dword ptr [ebp - 0x14] */
    964     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3802B710: fstp dword ptr [ebp - 0x10] */
    965     edx = MEM32(ebp + (-0x10)); /* 0x3802B713: mov edx, dword ptr [ebp - 0x10] */
    966     fp_push(*(double*)ADDR(0x3804E928)); /* 0x3802B716: fld qword ptr [0x3804e928] */
    967     MEM32(0x3806EE00) = ecx; /* 0x3802B71C: mov dword ptr [0x3806ee00], ecx */
    968     _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3802B722: fcos  */
    969     MEM32(ebp + (-0xC)) = eax; /* 0x3802B724: mov dword ptr [ebp - 0xc], eax */
    970     MEM32(0x3806EE04) = edx; /* 0x3802B727: mov dword ptr [0x3806ee04], edx */
    971     MEM32(0x3806EE08) = eax; /* 0x3802B72D: mov dword ptr [0x3806ee08], eax */
    972     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802B732: fstp dword ptr [ebp - 8] */
    973     fp_push(*(double*)ADDR(0x3804EBD8)); /* 0x3802B735: fld qword ptr [0x3804ebd8] */
    974     _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3802B73B: fsin  */
    975     ecx = MEM32(ebp + (-0x8)); /* 0x3802B73D: mov ecx, dword ptr [ebp - 8] */
    976     MEM32(0x3806EE0C) = ecx; /* 0x3802B740: mov dword ptr [0x3806ee0c], ecx */
    977     fp_push(*(float*)&MEM32(0x3804E8E4)); /* 0x3802B746: fld dword ptr [0x3804e8e4] */
    978     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B74C: fst dword ptr [ebp - 4] */
    979     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802B74F: fstp dword ptr [ebp - 0x14] */
    980     edx = MEM32(ebp + (-0x4)); /* 0x3802B752: mov edx, dword ptr [ebp - 4] */
    981     eax = MEM32(ebp + (-0x14)); /* 0x3802B755: mov eax, dword ptr [ebp - 0x14] */
    982     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3802B758: fstp dword ptr [ebp - 0x10] */
    983     ecx = MEM32(ebp + (-0x10)); /* 0x3802B75B: mov ecx, dword ptr [ebp - 0x10] */
    984     fp_push(*(double*)ADDR(0x3804EBD8)); /* 0x3802B75E: fld qword ptr [0x3804ebd8] */
    985     MEM32(0x3806EE10) = eax; /* 0x3802B764: mov dword ptr [0x3806ee10], eax */
    986     _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3802B769: fcos  */
    987     MEM32(ebp + (-0xC)) = edx; /* 0x3802B76B: mov dword ptr [ebp - 0xc], edx */
    988     MEM32(0x3806EE14) = ecx; /* 0x3802B76E: mov dword ptr [0x3806ee14], ecx */
    989     MEM32(0x3806EE18) = edx; /* 0x3802B774: mov dword ptr [0x3806ee18], edx */
    990     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802B77A: fstp dword ptr [ebp - 8] */
    991     fp_push(*(double*)ADDR(0x3804EBD0)); /* 0x3802B77D: fld qword ptr [0x3804ebd0] */
    992     _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3802B783: fsin  */
    993     eax = MEM32(ebp + (-0x8)); /* 0x3802B785: mov eax, dword ptr [ebp - 8] */
    994     MEM32(0x3806EE1C) = eax; /* 0x3802B788: mov dword ptr [0x3806ee1c], eax */
    995     fp_push(*(float*)&MEM32(0x3804E8E4)); /* 0x3802B78D: fld dword ptr [0x3804e8e4] */
    996     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B793: fst dword ptr [ebp - 4] */
    997     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802B796: fstp dword ptr [ebp - 0x14] */
    998     ecx = MEM32(ebp + (-0x4)); /* 0x3802B799: mov ecx, dword ptr [ebp - 4] */
    999     edx = MEM32(ebp + (-0x14)); /* 0x3802B79C: mov edx, dword ptr [ebp - 0x14] */
   1000     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3802B79F: fstp dword ptr [ebp - 0x10] */
   1001     eax = MEM32(ebp + (-0x10)); /* 0x3802B7A2: mov eax, dword ptr [ebp - 0x10] */
   1002     fp_push(*(double*)ADDR(0x3804EBD0)); /* 0x3802B7A5: fld qword ptr [0x3804ebd0] */
   1003     MEM32(ebp + (-0xC)) = ecx; /* 0x3802B7AB: mov dword ptr [ebp - 0xc], ecx */
   1004     _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3802B7AE: fcos  */
   1005     MEM32(0x3806EE20) = edx; /* 0x3802B7B0: mov dword ptr [0x3806ee20], edx */
   1006     MEM32(0x3806EE28) = ecx; /* 0x3802B7B6: mov dword ptr [0x3806ee28], ecx */
   1007     MEM32(0x3806EE24) = eax; /* 0x3802B7BC: mov dword ptr [0x3806ee24], eax */
   1008     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802B7C1: fstp dword ptr [ebp - 8] */
   1009     fp_push(*(double*)ADDR(0x3804EBC8)); /* 0x3802B7C4: fld qword ptr [0x3804ebc8] */
   1010     _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3802B7CA: fsin  */
   1011     edx = MEM32(ebp + (-0x8)); /* 0x3802B7CC: mov edx, dword ptr [ebp - 8] */
   1012     MEM32(0x3806EE2C) = edx; /* 0x3802B7CF: mov dword ptr [0x3806ee2c], edx */
   1013     fp_push(*(float*)&MEM32(0x3804E8E4)); /* 0x3802B7D5: fld dword ptr [0x3804e8e4] */
   1014     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B7DB: fst dword ptr [ebp - 4] */
   1015     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802B7DE: fstp dword ptr [ebp - 0x14] */
   1016     ecx = MEM32(ebp + (-0x14)); /* 0x3802B7E1: mov ecx, dword ptr [ebp - 0x14] */
   1017     eax = MEM32(ebp + (-0x4)); /* 0x3802B7E4: mov eax, dword ptr [ebp - 4] */
   1018     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3802B7E7: fstp dword ptr [ebp - 0x10] */
   1019     edx = MEM32(ebp + (-0x10)); /* 0x3802B7EA: mov edx, dword ptr [ebp - 0x10] */
   1020     fp_push(*(double*)ADDR(0x3804EBC8)); /* 0x3802B7ED: fld qword ptr [0x3804ebc8] */
   1021     MEM32(0x3806EE30) = ecx; /* 0x3802B7F3: mov dword ptr [0x3806ee30], ecx */
   1022     _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3802B7F9: fcos  */
   1023     MEM32(ebp + (-0xC)) = eax; /* 0x3802B7FB: mov dword ptr [ebp - 0xc], eax */
   1024     MEM32(0x3806EE34) = edx; /* 0x3802B7FE: mov dword ptr [0x3806ee34], edx */
   1025     MEM32(0x3806EE38) = eax; /* 0x3802B804: mov dword ptr [0x3806ee38], eax */
   1026     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802B809: fstp dword ptr [ebp - 8] */
   1027     ecx = MEM32(ebp + (-0x8)); /* 0x3802B80C: mov ecx, dword ptr [ebp - 8] */
   1028     MEM32(0x3806EE3C) = ecx; /* 0x3802B80F: mov dword ptr [0x3806ee3c], ecx */
   1029     esp = ebp; /* 0x3802B815: mov esp, ebp */
   1030     ebp = POP32_VAL(esp); /* 0x3802B817: pop ebp */
   1031     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802B818: ret  */
   1032     RECOMP_REGS_OUT();
   1033 }
   1034 
   1035 void sub_3802B6F0(void) {
   1036     int _fpu_cmp = 0;
   1037     uint32_t _cf = 0;
   1038     int _df = 1;
   1039     uint32_t _flag_k = FK_NONE;
   1040     uint32_t _flag_a = 0, _flag_b = 0;
   1041     uint32_t _itail_tgt = 0;
   1042     RECOMP_REGS_LOCALS
   1043     RECOMP_ENTER(0x3802B6F0u);
   1044 
   1045 L_3802B6F0:
   1046     PUSH32(esp, ebp); /* 0x3802B6F0: push ebp */
   1047     ebp = esp; /* 0x3802B6F1: mov ebp, esp */
   1048     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x14u);
   1049     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1050     esp = esp - 0x14u; /* 0x3802B6F3: sub esp, 0x14 */
   1051     _flag_k = FK_CMP;
   1052     fp_push(*(double*)ADDR(0x3804E928)); /* 0x3802B6F6: fld qword ptr [0x3804e928] */
   1053     _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3802B6FC: fsin  */
   1054     fp_push(*(float*)&MEM32(0x3804E8E4)); /* 0x3802B6FE: fld dword ptr [0x3804e8e4] */
   1055     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B704: fst dword ptr [ebp - 4] */
   1056     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802B707: fstp dword ptr [ebp - 0x14] */
   1057     eax = MEM32(ebp + (-0x4)); /* 0x3802B70A: mov eax, dword ptr [ebp - 4] */
   1058     ecx = MEM32(ebp + (-0x14)); /* 0x3802B70D: mov ecx, dword ptr [ebp - 0x14] */
   1059     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3802B710: fstp dword ptr [ebp - 0x10] */
   1060     edx = MEM32(ebp + (-0x10)); /* 0x3802B713: mov edx, dword ptr [ebp - 0x10] */
   1061     fp_push(*(double*)ADDR(0x3804E928)); /* 0x3802B716: fld qword ptr [0x3804e928] */
   1062     MEM32(0x3806EE00) = ecx; /* 0x3802B71C: mov dword ptr [0x3806ee00], ecx */
   1063     _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3802B722: fcos  */
   1064     MEM32(ebp + (-0xC)) = eax; /* 0x3802B724: mov dword ptr [ebp - 0xc], eax */
   1065     MEM32(0x3806EE04) = edx; /* 0x3802B727: mov dword ptr [0x3806ee04], edx */
   1066     MEM32(0x3806EE08) = eax; /* 0x3802B72D: mov dword ptr [0x3806ee08], eax */
   1067     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802B732: fstp dword ptr [ebp - 8] */
   1068     fp_push(*(double*)ADDR(0x3804EBD8)); /* 0x3802B735: fld qword ptr [0x3804ebd8] */
   1069     _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3802B73B: fsin  */
   1070     ecx = MEM32(ebp + (-0x8)); /* 0x3802B73D: mov ecx, dword ptr [ebp - 8] */
   1071     MEM32(0x3806EE0C) = ecx; /* 0x3802B740: mov dword ptr [0x3806ee0c], ecx */
   1072     fp_push(*(float*)&MEM32(0x3804E8E4)); /* 0x3802B746: fld dword ptr [0x3804e8e4] */
   1073     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B74C: fst dword ptr [ebp - 4] */
   1074     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802B74F: fstp dword ptr [ebp - 0x14] */
   1075     edx = MEM32(ebp + (-0x4)); /* 0x3802B752: mov edx, dword ptr [ebp - 4] */
   1076     eax = MEM32(ebp + (-0x14)); /* 0x3802B755: mov eax, dword ptr [ebp - 0x14] */
   1077     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3802B758: fstp dword ptr [ebp - 0x10] */
   1078     ecx = MEM32(ebp + (-0x10)); /* 0x3802B75B: mov ecx, dword ptr [ebp - 0x10] */
   1079     fp_push(*(double*)ADDR(0x3804EBD8)); /* 0x3802B75E: fld qword ptr [0x3804ebd8] */
   1080     MEM32(0x3806EE10) = eax; /* 0x3802B764: mov dword ptr [0x3806ee10], eax */
   1081     _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3802B769: fcos  */
   1082     MEM32(ebp + (-0xC)) = edx; /* 0x3802B76B: mov dword ptr [ebp - 0xc], edx */
   1083     MEM32(0x3806EE14) = ecx; /* 0x3802B76E: mov dword ptr [0x3806ee14], ecx */
   1084     MEM32(0x3806EE18) = edx; /* 0x3802B774: mov dword ptr [0x3806ee18], edx */
   1085     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802B77A: fstp dword ptr [ebp - 8] */
   1086     fp_push(*(double*)ADDR(0x3804EBD0)); /* 0x3802B77D: fld qword ptr [0x3804ebd0] */
   1087     _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3802B783: fsin  */
   1088     eax = MEM32(ebp + (-0x8)); /* 0x3802B785: mov eax, dword ptr [ebp - 8] */
   1089     MEM32(0x3806EE1C) = eax; /* 0x3802B788: mov dword ptr [0x3806ee1c], eax */
   1090     fp_push(*(float*)&MEM32(0x3804E8E4)); /* 0x3802B78D: fld dword ptr [0x3804e8e4] */
   1091     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B793: fst dword ptr [ebp - 4] */
   1092     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802B796: fstp dword ptr [ebp - 0x14] */
   1093     ecx = MEM32(ebp + (-0x4)); /* 0x3802B799: mov ecx, dword ptr [ebp - 4] */
   1094     edx = MEM32(ebp + (-0x14)); /* 0x3802B79C: mov edx, dword ptr [ebp - 0x14] */
   1095     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3802B79F: fstp dword ptr [ebp - 0x10] */
   1096     eax = MEM32(ebp + (-0x10)); /* 0x3802B7A2: mov eax, dword ptr [ebp - 0x10] */
   1097     fp_push(*(double*)ADDR(0x3804EBD0)); /* 0x3802B7A5: fld qword ptr [0x3804ebd0] */
   1098     MEM32(ebp + (-0xC)) = ecx; /* 0x3802B7AB: mov dword ptr [ebp - 0xc], ecx */
   1099     _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3802B7AE: fcos  */
   1100     MEM32(0x3806EE20) = edx; /* 0x3802B7B0: mov dword ptr [0x3806ee20], edx */
   1101     MEM32(0x3806EE28) = ecx; /* 0x3802B7B6: mov dword ptr [0x3806ee28], ecx */
   1102     MEM32(0x3806EE24) = eax; /* 0x3802B7BC: mov dword ptr [0x3806ee24], eax */
   1103     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802B7C1: fstp dword ptr [ebp - 8] */
   1104     fp_push(*(double*)ADDR(0x3804EBC8)); /* 0x3802B7C4: fld qword ptr [0x3804ebc8] */
   1105     _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3802B7CA: fsin  */
   1106     edx = MEM32(ebp + (-0x8)); /* 0x3802B7CC: mov edx, dword ptr [ebp - 8] */
   1107     MEM32(0x3806EE2C) = edx; /* 0x3802B7CF: mov dword ptr [0x3806ee2c], edx */
   1108     fp_push(*(float*)&MEM32(0x3804E8E4)); /* 0x3802B7D5: fld dword ptr [0x3804e8e4] */
   1109     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x4)) = _v; } /* 0x3802B7DB: fst dword ptr [ebp - 4] */
   1110     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802B7DE: fstp dword ptr [ebp - 0x14] */
   1111     ecx = MEM32(ebp + (-0x14)); /* 0x3802B7E1: mov ecx, dword ptr [ebp - 0x14] */
   1112     eax = MEM32(ebp + (-0x4)); /* 0x3802B7E4: mov eax, dword ptr [ebp - 4] */
   1113     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x10)) = _v; } /* 0x3802B7E7: fstp dword ptr [ebp - 0x10] */
   1114     edx = MEM32(ebp + (-0x10)); /* 0x3802B7EA: mov edx, dword ptr [ebp - 0x10] */
   1115     fp_push(*(double*)ADDR(0x3804EBC8)); /* 0x3802B7ED: fld qword ptr [0x3804ebc8] */
   1116     MEM32(0x3806EE30) = ecx; /* 0x3802B7F3: mov dword ptr [0x3806ee30], ecx */
   1117     _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3802B7F9: fcos  */
   1118     MEM32(ebp + (-0xC)) = eax; /* 0x3802B7FB: mov dword ptr [ebp - 0xc], eax */
   1119     MEM32(0x3806EE34) = edx; /* 0x3802B7FE: mov dword ptr [0x3806ee34], edx */
   1120     MEM32(0x3806EE38) = eax; /* 0x3802B804: mov dword ptr [0x3806ee38], eax */
   1121     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802B809: fstp dword ptr [ebp - 8] */
   1122     ecx = MEM32(ebp + (-0x8)); /* 0x3802B80C: mov ecx, dword ptr [ebp - 8] */
   1123     MEM32(0x3806EE3C) = ecx; /* 0x3802B80F: mov dword ptr [0x3806ee3c], ecx */
   1124     esp = ebp; /* 0x3802B815: mov esp, ebp */
   1125     ebp = POP32_VAL(esp); /* 0x3802B817: pop ebp */
   1126     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802B818: ret  */
   1127     RECOMP_REGS_OUT();
   1128 }
   1129 
   1130 void sub_3802B820(void) {
   1131     int _fpu_cmp = 0;
   1132     uint32_t _cf = 0;
   1133     int _df = 1;
   1134     uint32_t _flag_k = FK_NONE;
   1135     uint32_t _flag_a = 0, _flag_b = 0;
   1136     uint32_t _itail_tgt = 0;
   1137     RECOMP_REGS_LOCALS
   1138     RECOMP_ENTER(0x3802B820u);
   1139 
   1140 L_3802B820:
   1141     PUSH32(esp, ebp); /* 0x3802B820: push ebp */
   1142     ebp = esp; /* 0x3802B821: mov ebp, esp */
   1143     PUSH32(esp, ebx); /* 0x3802B823: push ebx */
   1144     PUSH32(esp, esi); /* 0x3802B824: push esi */
   1145     esi = ecx; /* 0x3802B825: mov esi, ecx */
   1146     eax = MEM32(esi + 0x8C); /* 0x3802B827: mov eax, dword ptr [esi + 0x8c] */
   1147     /* test eax, eax */ /* 0x3802B82D: test eax, eax */
   1148     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   1149     _cf = 0;
   1150     _flag_k = FK_TEST;
   1151     PUSH32(esp, edi); /* 0x3802B82F: push edi */
   1152     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802B869; /* 0x3802B830: jne 0x3802b869 */
   1153 L_3802B832:
   1154     eax = MEM32(esi + 0x88); /* 0x3802B832: mov eax, dword ptr [esi + 0x88] */
   1155     ecx = MEM32(eax + 0x4); /* 0x3802B838: mov ecx, dword ptr [eax + 4] */
   1156     /* test ecx, ecx */ /* 0x3802B83B: test ecx, ecx */
   1157     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   1158     _cf = 0;
   1159     _flag_k = FK_TEST;
   1160     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B854; /* 0x3802B83D: je 0x3802b854 */
   1161 L_3802B83F:
   1162     edx = MEM32(eax + 0x8); /* 0x3802B83F: mov edx, dword ptr [eax + 8] */
   1163     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   1164     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1165     edx = edx - ecx; /* 0x3802B842: sub edx, ecx */
   1166     _flag_k = FK_CMP;
   1167     /* test edx, 0xFFFFFFFCu */ /* 0x3802B844: test edx, 0xfffffffc */
   1168     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0xFFFFFFFCu);
   1169     _cf = 0;
   1170     _flag_k = FK_TEST;
   1171     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B854; /* 0x3802B84A: je 0x3802b854 */
   1172 L_3802B84C:
   1173     MEM32(esi + 0x8C) = eax; /* 0x3802B84C: mov dword ptr [esi + 0x8c], eax */
   1174     goto L_3802B863; /* 0x3802B852: jmp 0x3802b863 */
   1175 L_3802B854:
   1176     eax = MEM32(esi + 0x98); /* 0x3802B854: mov eax, dword ptr [esi + 0x98] */
   1177     ecx = MEM32(eax + 0x44); /* 0x3802B85A: mov ecx, dword ptr [eax + 0x44] */
   1178     MEM32(esi + 0x8C) = ecx; /* 0x3802B85D: mov dword ptr [esi + 0x8c], ecx */
   1179 L_3802B863:
   1180     eax = MEM32(esi + 0x8C); /* 0x3802B863: mov eax, dword ptr [esi + 0x8c] */
   1181 L_3802B869:
   1182     ecx = MEM32(ebp + 0xC); /* 0x3802B869: mov ecx, dword ptr [ebp + 0xc] */
   1183     /* cmp ecx, 0xFFFFFFFFu */ /* 0x3802B86C: cmp ecx, -1 */
   1184     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0xFFFFFFFFu);
   1185     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1186     _flag_k = FK_CMP;
   1187     ebx = MEM32(ebp + 0x8); /* 0x3802B86F: mov ebx, dword ptr [ebp + 8] */
   1188     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802B893; /* 0x3802B872: je 0x3802b893 */
   1189 L_3802B874:
   1190     edx = MEM32(eax + 0x4); /* 0x3802B874: mov edx, dword ptr [eax + 4] */
   1191     eax = MEM32(esi + 0x5C); /* 0x3802B877: mov eax, dword ptr [esi + 0x5c] */
   1192     edi = MEM32(edx + ecx * 4); /* 0x3802B87A: mov edi, dword ptr [edx + ecx*4] */
   1193     PUSH32(esp, eax); /* 0x3802B87D: push eax */
   1194     PUSH32(esp, ebx); /* 0x3802B87E: push ebx */
   1195     ecx = edi; /* 0x3802B87F: mov ecx, edi */
   1196     RECOMP_ICALL(0x38031910u); /* 0x3802B881: call 0x38031910 */ /* not lifted */
   1197     RECOMP_FLAGS_IN();
   1198     /* test LO8(eax), LO8(eax) */ /* 0x3802B886: test al, al */
   1199     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   1200     _cf = 0;
   1201     _flag_k = FK_NARROW(FK_TEST, 24);
   1202     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B893; /* 0x3802B888: je 0x3802b893 */
   1203 L_3802B88A:
   1204     eax = edi; /* 0x3802B88A: mov eax, edi */
   1205     edi = POP32_VAL(esp); /* 0x3802B88C: pop edi */
   1206     esi = POP32_VAL(esp); /* 0x3802B88D: pop esi */
   1207     ebx = POP32_VAL(esp); /* 0x3802B88E: pop ebx */
   1208     ebp = POP32_VAL(esp); /* 0x3802B88F: pop ebp */
   1209     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802B890: ret 8 */
   1210 L_3802B893:
   1211     ecx = MEM32(esi + 0x60); /* 0x3802B893: mov ecx, dword ptr [esi + 0x60] */
   1212     PUSH32(esp, 0); /* 0x3802B896: push 0 */
   1213     PUSH32(esp, 0x3806C8F8u); /* 0x3802B898: push 0x3806c8f8 */
   1214     PUSH32(esp, 0x3806C8A0u); /* 0x3802B89D: push 0x3806c8a0 */
   1215     PUSH32(esp, 0); /* 0x3802B8A2: push 0 */
   1216     PUSH32(esp, ecx); /* 0x3802B8A4: push ecx */
   1217     RECOMP_ICALL(0x3804B682u); /* 0x3802B8A5: call 0x3804b682 */ /* not lifted */
   1218     RECOMP_FLAGS_IN();
   1219     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x14u);
   1220     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1221     esp = esp + 0x14u; /* 0x3802B8AA: add esp, 0x14 */
   1222     _flag_k = FK_ADD;
   1223     PUSH32(esp, ebx); /* 0x3802B8AD: push ebx */
   1224     ecx = eax; /* 0x3802B8AE: mov ecx, eax */
   1225     RECOMP_ICALL(0x38035750u); /* 0x3802B8B0: call 0x38035750 */ /* not lifted */
   1226     RECOMP_FLAGS_IN();
   1227     /* test eax, eax */ /* 0x3802B8B5: test eax, eax */
   1228     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   1229     _cf = 0;
   1230     _flag_k = FK_TEST;
   1231     if (TEST_S(_flag_a, _flag_b)) goto L_3802B8C8; /* 0x3802B8B7: jl 0x3802b8c8 */
   1232 L_3802B8B9:
   1233     PUSH32(esp, eax); /* 0x3802B8B9: push eax */
   1234     ecx = esi; /* 0x3802B8BA: mov ecx, esi */
   1235     RECOMP_ICALL(0x3802B990u); /* 0x3802B8BC: call 0x3802b990 */ /* not lifted */
   1236     RECOMP_FLAGS_IN();
   1237     edi = POP32_VAL(esp); /* 0x3802B8C1: pop edi */
   1238     esi = POP32_VAL(esp); /* 0x3802B8C2: pop esi */
   1239     ebx = POP32_VAL(esp); /* 0x3802B8C3: pop ebx */
   1240     ebp = POP32_VAL(esp); /* 0x3802B8C4: pop ebp */
   1241     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802B8C5: ret 8 */
   1242 L_3802B8C8:
   1243     edi = POP32_VAL(esp); /* 0x3802B8C8: pop edi */
   1244     esi = POP32_VAL(esp); /* 0x3802B8C9: pop esi */
   1245     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1246     eax = 0; /* 0x3802B8CA: xor eax, eax */
   1247     _cf = 0;
   1248     _flag_k = FK_TEST;
   1249     ebx = POP32_VAL(esp); /* 0x3802B8CC: pop ebx */
   1250     ebp = POP32_VAL(esp); /* 0x3802B8CD: pop ebp */
   1251     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802B8CE: ret 8 */
   1252     RECOMP_REGS_OUT();
   1253 }
   1254 
   1255 void sub_3802B8E0(void) {
   1256     int _fpu_cmp = 0;
   1257     uint32_t _cf = 0;
   1258     int _df = 1;
   1259     uint32_t _flag_k = FK_NONE;
   1260     uint32_t _flag_a = 0, _flag_b = 0;
   1261     uint32_t _itail_tgt = 0;
   1262     RECOMP_REGS_LOCALS
   1263     RECOMP_ENTER(0x3802B8E0u);
   1264 
   1265 L_3802B8E0:
   1266     PUSH32(esp, ebp); /* 0x3802B8E0: push ebp */
   1267     ebp = esp; /* 0x3802B8E1: mov ebp, esp */
   1268     eax = MEM32(ecx + 0x8C); /* 0x3802B8E3: mov eax, dword ptr [ecx + 0x8c] */
   1269     /* test eax, eax */ /* 0x3802B8E9: test eax, eax */
   1270     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   1271     _cf = 0;
   1272     _flag_k = FK_TEST;
   1273     PUSH32(esp, ebx); /* 0x3802B8EB: push ebx */
   1274     PUSH32(esp, esi); /* 0x3802B8EC: push esi */
   1275     PUSH32(esp, edi); /* 0x3802B8ED: push edi */
   1276     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B8F4; /* 0x3802B8EE: je 0x3802b8f4 */
   1277 L_3802B8F0:
   1278     ecx = eax; /* 0x3802B8F0: mov ecx, eax */
   1279     goto L_3802B92B; /* 0x3802B8F2: jmp 0x3802b92b */
   1280 L_3802B8F4:
   1281     eax = MEM32(ecx + 0x88); /* 0x3802B8F4: mov eax, dword ptr [ecx + 0x88] */
   1282     edx = MEM32(eax + 0x4); /* 0x3802B8FA: mov edx, dword ptr [eax + 4] */
   1283     /* test edx, edx */ /* 0x3802B8FD: test edx, edx */
   1284     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   1285     _cf = 0;
   1286     _flag_k = FK_TEST;
   1287     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B916; /* 0x3802B8FF: je 0x3802b916 */
   1288 L_3802B901:
   1289     esi = MEM32(eax + 0x8); /* 0x3802B901: mov esi, dword ptr [eax + 8] */
   1290     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
   1291     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1292     esi = esi - edx; /* 0x3802B904: sub esi, edx */
   1293     _flag_k = FK_CMP;
   1294     /* test esi, 0xFFFFFFFCu */ /* 0x3802B906: test esi, 0xfffffffc */
   1295     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0xFFFFFFFCu);
   1296     _cf = 0;
   1297     _flag_k = FK_TEST;
   1298     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B916; /* 0x3802B90C: je 0x3802b916 */
   1299 L_3802B90E:
   1300     MEM32(ecx + 0x8C) = eax; /* 0x3802B90E: mov dword ptr [ecx + 0x8c], eax */
   1301     goto L_3802B925; /* 0x3802B914: jmp 0x3802b925 */
   1302 L_3802B916:
   1303     eax = MEM32(ecx + 0x98); /* 0x3802B916: mov eax, dword ptr [ecx + 0x98] */
   1304     edx = MEM32(eax + 0x44); /* 0x3802B91C: mov edx, dword ptr [eax + 0x44] */
   1305     MEM32(ecx + 0x8C) = edx; /* 0x3802B91F: mov dword ptr [ecx + 0x8c], edx */
   1306 L_3802B925:
   1307     ecx = MEM32(ecx + 0x8C); /* 0x3802B925: mov ecx, dword ptr [ecx + 0x8c] */
   1308 L_3802B92B:
   1309     edx = MEM32(ecx + 0x4); /* 0x3802B92B: mov edx, dword ptr [ecx + 4] */
   1310     /* test edx, edx */ /* 0x3802B92E: test edx, edx */
   1311     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   1312     _cf = 0;
   1313     _flag_k = FK_TEST;
   1314     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802B936; /* 0x3802B930: jne 0x3802b936 */
   1315 L_3802B932:
   1316     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1317     ecx = 0; /* 0x3802B932: xor ecx, ecx */
   1318     _cf = 0;
   1319     _flag_k = FK_TEST;
   1320     goto L_3802B93E; /* 0x3802B934: jmp 0x3802b93e */
   1321 L_3802B936:
   1322     ecx = MEM32(ecx + 0x8); /* 0x3802B936: mov ecx, dword ptr [ecx + 8] */
   1323     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   1324     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1325     ecx = ecx - edx; /* 0x3802B939: sub ecx, edx */
   1326     _flag_k = FK_CMP;
   1327     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3802B93B: sar ecx, 2 */
   1328     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1329     ecx = (uint32_t)((int32_t)ecx >> 2u);
   1330 L_3802B93E:
   1331     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1332     esi = 0; /* 0x3802B93E: xor esi, esi */
   1333     _cf = 0;
   1334     _flag_k = FK_TEST;
   1335     /* test ecx, ecx */ /* 0x3802B940: test ecx, ecx */
   1336     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   1337     _cf = 0;
   1338     _flag_k = FK_TEST;
   1339     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B97F; /* 0x3802B942: jbe 0x3802b97f */
   1340 L_3802B944:
   1341     edi = MEM32(ebp + 0x8); /* 0x3802B944: mov edi, dword ptr [ebp + 8] */
   1342 L_3802B947:
   1343     eax = MEM32(edx); /* 0x3802B947: mov eax, dword ptr [edx] */
   1344     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1345     ebx = 0; /* 0x3802B949: xor ebx, ebx */
   1346     _cf = 0;
   1347     _flag_k = FK_TEST;
   1348     SET_LO16(ebx, MEM16(eax + 0x4C)); /* 0x3802B94B: mov bx, word ptr [eax + 0x4c] */
   1349     /* cmp edi, ebx */ /* 0x3802B94F: cmp edi, ebx */
   1350     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
   1351     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1352     _flag_k = FK_CMP;
   1353     if (CMP_L(_flag_a, _flag_b)) goto L_3802B977; /* 0x3802B951: jl 0x3802b977 */
   1354 L_3802B953:
   1355     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1356     ebx = 0; /* 0x3802B953: xor ebx, ebx */
   1357     _cf = 0;
   1358     _flag_k = FK_TEST;
   1359     SET_LO16(ebx, MEM16(eax + 0x50)); /* 0x3802B955: mov bx, word ptr [eax + 0x50] */
   1360     /* cmp edi, ebx */ /* 0x3802B959: cmp edi, ebx */
   1361     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
   1362     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1363     _flag_k = FK_CMP;
   1364     if (CMP_GE(_flag_a, _flag_b)) goto L_3802B977; /* 0x3802B95B: jge 0x3802b977 */
   1365 L_3802B95D:
   1366     edi = MEM32(ebp + 0xC); /* 0x3802B95D: mov edi, dword ptr [ebp + 0xc] */
   1367     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1368     ebx = 0; /* 0x3802B960: xor ebx, ebx */
   1369     _cf = 0;
   1370     _flag_k = FK_TEST;
   1371     SET_LO16(ebx, MEM16(eax + 0x4E)); /* 0x3802B962: mov bx, word ptr [eax + 0x4e] */
   1372     /* cmp edi, ebx */ /* 0x3802B966: cmp edi, ebx */
   1373     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
   1374     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1375     _flag_k = FK_CMP;
   1376     if (CMP_L(_flag_a, _flag_b)) goto L_3802B974; /* 0x3802B968: jl 0x3802b974 */
   1377 L_3802B96A:
   1378     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1379     ebx = 0; /* 0x3802B96A: xor ebx, ebx */
   1380     _cf = 0;
   1381     _flag_k = FK_TEST;
   1382     SET_LO16(ebx, MEM16(eax + 0x52)); /* 0x3802B96C: mov bx, word ptr [eax + 0x52] */
   1383     /* cmp edi, ebx */ /* 0x3802B970: cmp edi, ebx */
   1384     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
   1385     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1386     _flag_k = FK_CMP;
   1387     if (CMP_L(_flag_a, _flag_b)) goto L_3802B981; /* 0x3802B972: jl 0x3802b981 */
   1388 L_3802B974:
   1389     edi = MEM32(ebp + 0x8); /* 0x3802B974: mov edi, dword ptr [ebp + 8] */
   1390 L_3802B977:
   1391     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1);
   1392     esi = esi + 1; /* 0x3802B977: inc esi */
   1393     _flag_k = FK_INC;
   1394     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(4);
   1395     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1396     edx = edx + 4; /* 0x3802B978: add edx, 4 */
   1397     _flag_k = FK_ADD;
   1398     /* cmp esi, ecx */ /* 0x3802B97B: cmp esi, ecx */
   1399     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ecx);
   1400     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1401     _flag_k = FK_CMP;
   1402     RECOMP_BACKEDGE();
   1403     if (CMP_B(_flag_a, _flag_b)) goto L_3802B947; /* 0x3802B97D: jb 0x3802b947 */
   1404 L_3802B97F:
   1405     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1406     eax = 0; /* 0x3802B97F: xor eax, eax */
   1407     _cf = 0;
   1408     _flag_k = FK_TEST;
   1409 L_3802B981:
   1410     edi = POP32_VAL(esp); /* 0x3802B981: pop edi */
   1411     esi = POP32_VAL(esp); /* 0x3802B982: pop esi */
   1412     ebx = POP32_VAL(esp); /* 0x3802B983: pop ebx */
   1413     ebp = POP32_VAL(esp); /* 0x3802B984: pop ebp */
   1414     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802B985: ret 8 */
   1415     RECOMP_REGS_OUT();
   1416 }
   1417 
   1418 void sub_3802B990(void) {
   1419     int _fpu_cmp = 0;
   1420     uint32_t _cf = 0;
   1421     int _df = 1;
   1422     uint32_t _flag_k = FK_NONE;
   1423     uint32_t _flag_a = 0, _flag_b = 0;
   1424     uint32_t _itail_tgt = 0;
   1425     RECOMP_REGS_LOCALS
   1426     RECOMP_ENTER(0x3802B990u);
   1427 
   1428 L_3802B990:
   1429     PUSH32(esp, ebp); /* 0x3802B990: push ebp */
   1430     ebp = esp; /* 0x3802B991: mov ebp, esp */
   1431     eax = MEM32(ecx + 0x8C); /* 0x3802B993: mov eax, dword ptr [ecx + 0x8c] */
   1432     /* test eax, eax */ /* 0x3802B999: test eax, eax */
   1433     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   1434     _cf = 0;
   1435     _flag_k = FK_TEST;
   1436     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B9AA; /* 0x3802B99B: je 0x3802b9aa */
   1437 L_3802B99D:
   1438     eax = MEM32(eax + 0x4); /* 0x3802B99D: mov eax, dword ptr [eax + 4] */
   1439     ecx = MEM32(ebp + 0x8); /* 0x3802B9A0: mov ecx, dword ptr [ebp + 8] */
   1440     eax = MEM32(eax + ecx * 4); /* 0x3802B9A3: mov eax, dword ptr [eax + ecx*4] */
   1441     ebp = POP32_VAL(esp); /* 0x3802B9A6: pop ebp */
   1442     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802B9A7: ret 4 */
   1443 L_3802B9AA:
   1444     eax = MEM32(ecx + 0x88); /* 0x3802B9AA: mov eax, dword ptr [ecx + 0x88] */
   1445     edx = MEM32(eax + 0x4); /* 0x3802B9B0: mov edx, dword ptr [eax + 4] */
   1446     /* test edx, edx */ /* 0x3802B9B3: test edx, edx */
   1447     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   1448     _cf = 0;
   1449     _flag_k = FK_TEST;
   1450     if (TEST_Z(_flag_a, _flag_b)) goto L_3802B9C6; /* 0x3802B9B5: je 0x3802b9c6 */
   1451 L_3802B9B7:
   1452     PUSH32(esp, esi); /* 0x3802B9B7: push esi */
   1453     esi = MEM32(eax + 0x8); /* 0x3802B9B8: mov esi, dword ptr [eax + 8] */
   1454     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
   1455     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1456     esi = esi - edx; /* 0x3802B9BB: sub esi, edx */
   1457     _flag_k = FK_CMP;
   1458     /* test esi, 0xFFFFFFFCu */ /* 0x3802B9BD: test esi, 0xfffffffc */
   1459     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0xFFFFFFFCu);
   1460     _cf = 0;
   1461     _flag_k = FK_TEST;
   1462     esi = POP32_VAL(esp); /* 0x3802B9C3: pop esi */
   1463     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802B9CF; /* 0x3802B9C4: jne 0x3802b9cf */
   1464 L_3802B9C6:
   1465     edx = MEM32(ecx + 0x98); /* 0x3802B9C6: mov edx, dword ptr [ecx + 0x98] */
   1466     eax = MEM32(edx + 0x44); /* 0x3802B9CC: mov eax, dword ptr [edx + 0x44] */
   1467 L_3802B9CF:
   1468     edx = MEM32(ebp + 0x8); /* 0x3802B9CF: mov edx, dword ptr [ebp + 8] */
   1469     MEM32(ecx + 0x8C) = eax; /* 0x3802B9D2: mov dword ptr [ecx + 0x8c], eax */
   1470     ecx = eax; /* 0x3802B9D8: mov ecx, eax */
   1471     ecx = MEM32(ecx + 0x4); /* 0x3802B9DA: mov ecx, dword ptr [ecx + 4] */
   1472     eax = MEM32(ecx + edx * 4); /* 0x3802B9DD: mov eax, dword ptr [ecx + edx*4] */
   1473     ebp = POP32_VAL(esp); /* 0x3802B9E0: pop ebp */
   1474     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802B9E1: ret 4 */
   1475     RECOMP_REGS_OUT();
   1476 }
   1477 
   1478 void sub_3802B9F0(void) {
   1479     int _fpu_cmp = 0;
   1480     uint32_t _cf = 0;
   1481     int _df = 1;
   1482     uint32_t _flag_k = FK_NONE;
   1483     uint32_t _flag_a = 0, _flag_b = 0;
   1484     uint32_t _itail_tgt = 0;
   1485     RECOMP_REGS_LOCALS
   1486     RECOMP_ENTER(0x3802B9F0u);
   1487 
   1488 L_3802B9F0:
   1489     PUSH32(esp, ebp); /* 0x3802B9F0: push ebp */
   1490     ebp = esp; /* 0x3802B9F1: mov ebp, esp */
   1491     /* cmp MEM32(ebp + 0x8), 0xFFFFFFFFu */ /* 0x3802B9F3: cmp dword ptr [ebp + 8], -1 */
   1492     _flag_a = (uint32_t)(MEM32(ebp + 0x8)); _flag_b = (uint32_t)(0xFFFFFFFFu);
   1493     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1494     _flag_k = FK_CMP;
   1495     SET_LO8(eax, (CMP_EQ(_flag_a, _flag_b)) ? 1 : 0); /* 0x3802B9F7: sete al */
   1496     ebp = POP32_VAL(esp); /* 0x3802B9FA: pop ebp */
   1497     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802B9FB: ret 0xc */
   1498     RECOMP_REGS_OUT();
   1499 }
   1500 
   1501 void sub_3802BA00(void) {
   1502     int _fpu_cmp = 0;
   1503     uint32_t _cf = 0;
   1504     int _df = 1;
   1505     uint32_t _flag_k = FK_NONE;
   1506     uint32_t _flag_a = 0, _flag_b = 0;
   1507     uint32_t _itail_tgt = 0;
   1508     RECOMP_REGS_LOCALS
   1509     RECOMP_ENTER(0x3802BA00u);
   1510 
   1511 L_3802BA00:
   1512     PUSH32(esp, ebp); /* 0x3802BA00: push ebp */
   1513     ebp = esp; /* 0x3802BA01: mov ebp, esp */
   1514     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   1515     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1516     esp = esp - 0xCu; /* 0x3802BA03: sub esp, 0xc */
   1517     _flag_k = FK_CMP;
   1518     eax = MEM32(ebp + 0x8); /* 0x3802BA06: mov eax, dword ptr [ebp + 8] */
   1519     PUSH32(esp, ebx); /* 0x3802BA09: push ebx */
   1520     ebx = eax; /* 0x3802BA0A: mov ebx, eax */
   1521     PUSH32(esp, esi); /* 0x3802BA0C: push esi */
   1522     if (16u) _cf = (((ebx) >> 15) & 1u); /* 0x3802BA0D: shr ebx, 0x10 */
   1523     if (16u) { _flag_a = recomp_flags_pack((ebx >> 16u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1524     ebx = ebx >> 16u; /* 0x3802BA0D: shr ebx, 0x10 */
   1525     /* cmp LO16(eax), 0xFFFFu */ /* 0x3802BA10: cmp ax, 0xffff */
   1526     _flag_a = (uint32_t)(LO16(eax)) << 16; _flag_b = (uint32_t)(0xFFFFu) << 16;
   1527     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1528     _flag_k = FK_NARROW(FK_CMP, 16);
   1529     PUSH32(esp, edi); /* 0x3802BA14: push edi */
   1530     edi = ecx; /* 0x3802BA15: mov edi, ecx */
   1531     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BA9E; /* 0x3802BA17: je 0x3802ba9e */
   1532 L_3802BA1D:
   1533     /* cmp LO16(ebx), 0xFFFFFFFFu */ /* 0x3802BA1D: cmp bx, -1 */
   1534     _flag_a = (uint32_t)(LO16(ebx)) << 16; _flag_b = (uint32_t)(0xFFFFFFFFu) << 16;
   1535     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1536     _flag_k = FK_NARROW(FK_CMP, 16);
   1537     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BA9E; /* 0x3802BA21: je 0x3802ba9e */
   1538 L_3802BA23:
   1539     esi = MEM32(edi + 0x48); /* 0x3802BA23: mov esi, dword ptr [edi + 0x48] */
   1540     ecx = ebp + 0x8; /* 0x3802BA26: lea ecx, [ebp + 8] */
   1541     eax = (int32_t)(int16_t)LO16(eax); /* 0x3802BA29: movsx eax, ax */
   1542     PUSH32(esp, ecx); /* 0x3802BA2C: push ecx */
   1543     edx = ebp + (-0xC); /* 0x3802BA2D: lea edx, [ebp - 0xc] */
   1544     PUSH32(esp, edx); /* 0x3802BA30: push edx */
   1545     ecx = esi; /* 0x3802BA31: mov ecx, esi */
   1546     MEM32(ebp + 0x8) = eax; /* 0x3802BA33: mov dword ptr [ebp + 8], eax */
   1547     RECOMP_ICALL(0x3800FD90u); /* 0x3802BA36: call 0x3800fd90 */ /* not lifted */
   1548     RECOMP_FLAGS_IN();
   1549     eax = MEM32(eax); /* 0x3802BA3B: mov eax, dword ptr [eax] */
   1550     esi = MEM32(esi + 0x4); /* 0x3802BA3D: mov esi, dword ptr [esi + 4] */
   1551     /* cmp eax, esi */ /* 0x3802BA40: cmp eax, esi */
   1552     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   1553     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1554     _flag_k = FK_CMP;
   1555     MEM32(ebp + (-0x4)) = eax; /* 0x3802BA42: mov dword ptr [ebp - 4], eax */
   1556     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BA54; /* 0x3802BA45: je 0x3802ba54 */
   1557 L_3802BA47:
   1558     ecx = MEM32(ebp + 0x8); /* 0x3802BA47: mov ecx, dword ptr [ebp + 8] */
   1559     /* cmp ecx, MEM32(eax + 0xC) */ /* 0x3802BA4A: cmp ecx, dword ptr [eax + 0xc] */
   1560     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax + 0xC));
   1561     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1562     _flag_k = FK_CMP;
   1563     if (CMP_L(_flag_a, _flag_b)) goto L_3802BA54; /* 0x3802BA4D: jl 0x3802ba54 */
   1564 L_3802BA4F:
   1565     eax = ebp + (-0x4); /* 0x3802BA4F: lea eax, [ebp - 4] */
   1566     goto L_3802BA5A; /* 0x3802BA52: jmp 0x3802ba5a */
   1567 L_3802BA54:
   1568     MEM32(ebp + (-0x8)) = esi; /* 0x3802BA54: mov dword ptr [ebp - 8], esi */
   1569     eax = ebp + (-0x8); /* 0x3802BA57: lea eax, [ebp - 8] */
   1570 L_3802BA5A:
   1571     edx = MEM32(edi + 0x48); /* 0x3802BA5A: mov edx, dword ptr [edi + 0x48] */
   1572     eax = MEM32(eax); /* 0x3802BA5D: mov eax, dword ptr [eax] */
   1573     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3802BA5F: cmp eax, dword ptr [edx + 4] */
   1574     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   1575     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1576     _flag_k = FK_CMP;
   1577     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BA9E; /* 0x3802BA62: je 0x3802ba9e */
   1578 L_3802BA64:
   1579     esi = MEM32(eax + 0x10); /* 0x3802BA64: mov esi, dword ptr [eax + 0x10] */
   1580     ecx = MEM32(esi + 0x4); /* 0x3802BA67: mov ecx, dword ptr [esi + 4] */
   1581     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1582     eax = 0; /* 0x3802BA6A: xor eax, eax */
   1583     _cf = 0;
   1584     _flag_k = FK_TEST;
   1585     edx = ecx; /* 0x3802BA6C: mov edx, ecx */
   1586 L_3802BA6E:
   1587     /* test ecx, ecx */ /* 0x3802BA6E: test ecx, ecx */
   1588     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   1589     _cf = 0;
   1590     _flag_k = FK_TEST;
   1591     if (TEST_Z(_flag_a, _flag_b)) goto L_3802BA9E; /* 0x3802BA70: je 0x3802ba9e */
   1592 L_3802BA72:
   1593     edi = MEM32(esi + 0x8); /* 0x3802BA72: mov edi, dword ptr [esi + 8] */
   1594     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx);
   1595     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1596     edi = edi - ecx; /* 0x3802BA75: sub edi, ecx */
   1597     _flag_k = FK_CMP;
   1598     if (4u) _cf = (((edi) >> 3) & 1u); /* 0x3802BA77: sar edi, 4 */
   1599     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edi >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1600     edi = (uint32_t)((int32_t)edi >> 4u);
   1601     /* cmp eax, edi */ /* 0x3802BA7A: cmp eax, edi */
   1602     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   1603     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1604     _flag_k = FK_CMP;
   1605     if (CMP_AE(_flag_a, _flag_b)) goto L_3802BA9E; /* 0x3802BA7C: jae 0x3802ba9e */
   1606 L_3802BA7E:
   1607     edi = (int32_t)(int16_t)LO16(ebx); /* 0x3802BA7E: movsx edi, bx */
   1608     /* cmp MEM32(edx), edi */ /* 0x3802BA81: cmp dword ptr [edx], edi */
   1609     _flag_a = (uint32_t)(MEM32(edx)); _flag_b = (uint32_t)(edi);
   1610     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1611     _flag_k = FK_CMP;
   1612     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BA8B; /* 0x3802BA83: je 0x3802ba8b */
   1613 L_3802BA85:
   1614     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   1615     eax = eax + 1; /* 0x3802BA85: inc eax */
   1616     _flag_k = FK_INC;
   1617     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u);
   1618     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1619     edx = edx + 0x10u; /* 0x3802BA86: add edx, 0x10 */
   1620     _flag_k = FK_ADD;
   1621     RECOMP_BACKEDGE();
   1622     goto L_3802BA6E; /* 0x3802BA89: jmp 0x3802ba6e */
   1623 L_3802BA8B:
   1624     edx = MEM32(ebp + 0xC); /* 0x3802BA8B: mov edx, dword ptr [ebp + 0xc] */
   1625     esi = MEM32(edx); /* 0x3802BA8E: mov esi, dword ptr [edx] */
   1626     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802BA90: shl eax, 4 */
   1627     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1628     eax = eax << 4u; /* 0x3802BA90: shl eax, 4 */
   1629     MEM32(eax + ecx + 0x8) = esi; /* 0x3802BA93: mov dword ptr [eax + ecx + 8], esi */
   1630     edx = MEM32(edx + 0x4); /* 0x3802BA97: mov edx, dword ptr [edx + 4] */
   1631     MEM32(eax + ecx + 0xC) = edx; /* 0x3802BA9A: mov dword ptr [eax + ecx + 0xc], edx */
   1632 L_3802BA9E:
   1633     edi = POP32_VAL(esp); /* 0x3802BA9E: pop edi */
   1634     esi = POP32_VAL(esp); /* 0x3802BA9F: pop esi */
   1635     ebx = POP32_VAL(esp); /* 0x3802BAA0: pop ebx */
   1636     esp = ebp; /* 0x3802BAA1: mov esp, ebp */
   1637     ebp = POP32_VAL(esp); /* 0x3802BAA3: pop ebp */
   1638     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802BAA4: ret 8 */
   1639     RECOMP_REGS_OUT();
   1640 }
   1641 
   1642 void sub_3802BAB0(void) {
   1643     int _fpu_cmp = 0;
   1644     uint32_t _cf = 0;
   1645     int _df = 1;
   1646     uint32_t _flag_k = FK_NONE;
   1647     uint32_t _flag_a = 0, _flag_b = 0;
   1648     uint32_t _itail_tgt = 0;
   1649     RECOMP_REGS_LOCALS
   1650     RECOMP_ENTER(0x3802BAB0u);
   1651 
   1652 L_3802BAB0:
   1653     PUSH32(esp, ebp); /* 0x3802BAB0: push ebp */
   1654     ebp = esp; /* 0x3802BAB1: mov ebp, esp */
   1655     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   1656     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1657     esp = esp - 0xCu; /* 0x3802BAB3: sub esp, 0xc */
   1658     _flag_k = FK_CMP;
   1659     PUSH32(esp, ebx); /* 0x3802BAB6: push ebx */
   1660     PUSH32(esp, esi); /* 0x3802BAB7: push esi */
   1661     esi = MEM32(ebp + 0x10); /* 0x3802BAB8: mov esi, dword ptr [ebp + 0x10] */
   1662     eax = ecx + 0x54; /* 0x3802BABB: lea eax, [ecx + 0x54] */
   1663     edx = esi + 0x1; /* 0x3802BABE: lea edx, [esi + 1] */
   1664     PUSH32(esp, edi); /* 0x3802BAC1: push edi */
   1665     edi = MEM32(eax); /* 0x3802BAC2: mov edi, dword ptr [eax] */
   1666     MEM32(ebp + 0x10) = edx; /* 0x3802BAC4: mov dword ptr [ebp + 0x10], edx */
   1667     /* cmp edi, edx */ /* 0x3802BAC7: cmp edi, edx */
   1668     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edx);
   1669     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1670     _flag_k = FK_CMP;
   1671     edx = eax; /* 0x3802BAC9: mov edx, eax */
   1672     if (CMP_G(_flag_a, _flag_b)) goto L_3802BAD0; /* 0x3802BACB: jg 0x3802bad0 */
   1673 L_3802BACD:
   1674     edx = ebp + 0x10; /* 0x3802BACD: lea edx, [ebp + 0x10] */
   1675 L_3802BAD0:
   1676     /* test esi, esi */ /* 0x3802BAD0: test esi, esi */
   1677     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi);
   1678     _cf = 0;
   1679     _flag_k = FK_TEST;
   1680     edx = MEM32(edx); /* 0x3802BAD2: mov edx, dword ptr [edx] */
   1681     MEM32(eax) = edx; /* 0x3802BAD4: mov dword ptr [eax], edx */
   1682     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802BADD; /* 0x3802BAD6: jne 0x3802badd */
   1683 L_3802BAD8:
   1684     esi = edx; /* 0x3802BAD8: mov esi, edx */
   1685     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   1686     edx = edx + 1; /* 0x3802BADA: inc edx */
   1687     _flag_k = FK_INC;
   1688     MEM32(eax) = edx; /* 0x3802BADB: mov dword ptr [eax], edx */
   1689 L_3802BADD:
   1690     eax = MEM32(ebp + 0xC); /* 0x3802BADD: mov eax, dword ptr [ebp + 0xc] */
   1691     edx = ebp + (-0x8); /* 0x3802BAE0: lea edx, [ebp - 8] */
   1692     /* cmp edx, eax */ /* 0x3802BAE3: cmp edx, eax */
   1693     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   1694     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1695     _flag_k = FK_CMP;
   1696     MEM32(ebp + (-0xC)) = esi; /* 0x3802BAE5: mov dword ptr [ebp - 0xc], esi */
   1697     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BAF5; /* 0x3802BAE8: je 0x3802baf5 */
   1698 L_3802BAEA:
   1699     edx = MEM32(eax); /* 0x3802BAEA: mov edx, dword ptr [eax] */
   1700     eax = MEM32(eax + 0x4); /* 0x3802BAEC: mov eax, dword ptr [eax + 4] */
   1701     MEM32(ebp + (-0x8)) = edx; /* 0x3802BAEF: mov dword ptr [ebp - 8], edx */
   1702     MEM32(ebp + (-0x4)) = eax; /* 0x3802BAF2: mov dword ptr [ebp - 4], eax */
   1703 L_3802BAF5:
   1704     esi = MEM32(ecx + 0x50); /* 0x3802BAF5: mov esi, dword ptr [ecx + 0x50] */
   1705     ecx = MEM32(esi + 0x8); /* 0x3802BAF8: mov ecx, dword ptr [esi + 8] */
   1706     edx = MEM32(esi + 0xC); /* 0x3802BAFB: mov edx, dword ptr [esi + 0xc] */
   1707     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   1708     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1709     edx = edx - ecx; /* 0x3802BAFE: sub edx, ecx */
   1710     _flag_k = FK_CMP;
   1711     eax = 0x2AAAAAABu; /* 0x3802BB00: mov eax, 0x2aaaaaab */
   1712     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(edx); /* 0x3802BB05: imul edx */
   1713       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   1714       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   1715     if (1u) _cf = (((edx) >> 0) & 1u); /* 0x3802BB07: sar edx, 1 */
   1716     if (1u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 1u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1717     edx = (uint32_t)((int32_t)edx >> 1u);
   1718     eax = edx; /* 0x3802BB09: mov eax, edx */
   1719     if (31u) _cf = (((eax) >> 30) & 1u); /* 0x3802BB0B: shr eax, 0x1f */
   1720     if (31u) { _flag_a = recomp_flags_pack((eax >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1721     eax = eax >> 31u; /* 0x3802BB0B: shr eax, 0x1f */
   1722     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   1723     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1724     edx = edx + eax; /* 0x3802BB0E: add edx, eax */
   1725     _flag_k = FK_ADD;
   1726     /* cmp edx, 1 */ /* 0x3802BB10: cmp edx, 1 */
   1727     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   1728     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1729     _flag_k = FK_CMP;
   1730     edi = ecx; /* 0x3802BB13: mov edi, ecx */
   1731     if (CMP_AE(_flag_a, _flag_b)) goto L_3802BBE7; /* 0x3802BB15: jae 0x3802bbe7 */
   1732 L_3802BB1B:
   1733     ebx = MEM32(esi + 0x4); /* 0x3802BB1B: mov ebx, dword ptr [esi + 4] */
   1734     /* test ebx, ebx */ /* 0x3802BB1E: test ebx, ebx */
   1735     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(ebx);
   1736     _cf = 0;
   1737     _flag_k = FK_TEST;
   1738     if (TEST_Z(_flag_a, _flag_b)) goto L_3802BB3E; /* 0x3802BB20: je 0x3802bb3e */
   1739 L_3802BB22:
   1740     edx = ecx; /* 0x3802BB22: mov edx, ecx */
   1741     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ebx);
   1742     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1743     edx = edx - ebx; /* 0x3802BB24: sub edx, ebx */
   1744     _flag_k = FK_CMP;
   1745     eax = 0x2AAAAAABu; /* 0x3802BB26: mov eax, 0x2aaaaaab */
   1746     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(edx); /* 0x3802BB2B: imul edx */
   1747       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   1748       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   1749     if (1u) _cf = (((edx) >> 0) & 1u); /* 0x3802BB2D: sar edx, 1 */
   1750     if (1u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 1u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1751     edx = (uint32_t)((int32_t)edx >> 1u);
   1752     eax = edx; /* 0x3802BB2F: mov eax, edx */
   1753     if (31u) _cf = (((eax) >> 30) & 1u); /* 0x3802BB31: shr eax, 0x1f */
   1754     if (31u) { _flag_a = recomp_flags_pack((eax >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1755     eax = eax >> 31u; /* 0x3802BB31: shr eax, 0x1f */
   1756     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   1757     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1758     edx = edx + eax; /* 0x3802BB34: add edx, eax */
   1759     _flag_k = FK_ADD;
   1760     /* cmp edx, 1 */ /* 0x3802BB36: cmp edx, 1 */
   1761     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   1762     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1763     _flag_k = FK_CMP;
   1764     MEM32(ebp + 0x10) = edx; /* 0x3802BB39: mov dword ptr [ebp + 0x10], edx */
   1765     if (CMP_A(_flag_a, _flag_b)) goto L_3802BB45; /* 0x3802BB3C: ja 0x3802bb45 */
   1766 L_3802BB3E:
   1767     MEM32(ebp + 0x10) = 1; /* 0x3802BB3E: mov dword ptr [ebp + 0x10], 1 */
   1768 L_3802BB45:
   1769     /* test ebx, ebx */ /* 0x3802BB45: test ebx, ebx */
   1770     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(ebx);
   1771     _cf = 0;
   1772     _flag_k = FK_TEST;
   1773     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802BB4D; /* 0x3802BB47: jne 0x3802bb4d */
   1774 L_3802BB49:
   1775     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1776     edx = 0; /* 0x3802BB49: xor edx, edx */
   1777     _cf = 0;
   1778     _flag_k = FK_TEST;
   1779     goto L_3802BB5F; /* 0x3802BB4B: jmp 0x3802bb5f */
   1780 L_3802BB4D:
   1781     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
   1782     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1783     ecx = ecx - ebx; /* 0x3802BB4D: sub ecx, ebx */
   1784     _flag_k = FK_CMP;
   1785     eax = 0x2AAAAAABu; /* 0x3802BB4F: mov eax, 0x2aaaaaab */
   1786     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(ecx); /* 0x3802BB54: imul ecx */
   1787       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   1788       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   1789     if (1u) _cf = (((edx) >> 0) & 1u); /* 0x3802BB56: sar edx, 1 */
   1790     if (1u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 1u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1791     edx = (uint32_t)((int32_t)edx >> 1u);
   1792     ecx = edx; /* 0x3802BB58: mov ecx, edx */
   1793     if (31u) _cf = (((ecx) >> 30) & 1u); /* 0x3802BB5A: shr ecx, 0x1f */
   1794     if (31u) { _flag_a = recomp_flags_pack((ecx >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1795     ecx = ecx >> 31u; /* 0x3802BB5A: shr ecx, 0x1f */
   1796     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   1797     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1798     edx = edx + ecx; /* 0x3802BB5D: add edx, ecx */
   1799     _flag_k = FK_ADD;
   1800 L_3802BB5F:
   1801     eax = MEM32(ebp + 0x10); /* 0x3802BB5F: mov eax, dword ptr [ebp + 0x10] */
   1802     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   1803     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1804     eax = eax + edx; /* 0x3802BB62: add eax, edx */
   1805     _flag_k = FK_ADD;
   1806     /* test eax, eax */ /* 0x3802BB64: test eax, eax */
   1807     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   1808     _cf = 0;
   1809     _flag_k = FK_TEST;
   1810     MEM32(ebp + 0xC) = eax; /* 0x3802BB66: mov dword ptr [ebp + 0xc], eax */
   1811     if (TEST_NS(_flag_a, _flag_b)) goto L_3802BB6D; /* 0x3802BB69: jge 0x3802bb6d */
   1812 L_3802BB6B:
   1813     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   1814     eax = 0; /* 0x3802BB6B: xor eax, eax */
   1815     _cf = 0;
   1816     _flag_k = FK_TEST;
   1817 L_3802BB6D:
   1818     ecx = eax + eax * 2; /* 0x3802BB6D: lea ecx, [eax + eax*2] */
   1819     if (2u) _cf = (((ecx) >> 30) & 1u); /* 0x3802BB70: shl ecx, 2 */
   1820     if (2u) { _flag_a = recomp_flags_pack((ecx << 2u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1821     ecx = ecx << 2u; /* 0x3802BB70: shl ecx, 2 */
   1822     PUSH32(esp, ecx); /* 0x3802BB73: push ecx */
   1823     RECOMP_ICALL(0x3804B676u); /* 0x3802BB74: call 0x3804b676 */ /* not lifted */
   1824     RECOMP_FLAGS_IN();
   1825     edx = MEM32(esi + 0x4); /* 0x3802BB79: mov edx, dword ptr [esi + 4] */
   1826     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   1827     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1828     esp = esp + 4; /* 0x3802BB7C: add esp, 4 */
   1829     _flag_k = FK_ADD;
   1830     ebx = eax; /* 0x3802BB7F: mov ebx, eax */
   1831     PUSH32(esp, ebx); /* 0x3802BB81: push ebx */
   1832     PUSH32(esp, edi); /* 0x3802BB82: push edi */
   1833     PUSH32(esp, edx); /* 0x3802BB83: push edx */
   1834     ecx = esi; /* 0x3802BB84: mov ecx, esi */
   1835     RECOMP_ICALL(0x3802F200u); /* 0x3802BB86: call 0x3802f200 */ /* not lifted */
   1836     RECOMP_FLAGS_IN();
   1837     ecx = ebp + (-0xC); /* 0x3802BB8B: lea ecx, [ebp - 0xc] */
   1838     PUSH32(esp, ecx); /* 0x3802BB8E: push ecx */
   1839     PUSH32(esp, 1); /* 0x3802BB8F: push 1 */
   1840     PUSH32(esp, eax); /* 0x3802BB91: push eax */
   1841     ecx = esi; /* 0x3802BB92: mov ecx, esi */
   1842     MEM32(ebp + 0x10) = eax; /* 0x3802BB94: mov dword ptr [ebp + 0x10], eax */
   1843     RECOMP_ICALL(0x3802F240u); /* 0x3802BB97: call 0x3802f240 */ /* not lifted */
   1844     RECOMP_FLAGS_IN();
   1845     edx = MEM32(ebp + 0x10); /* 0x3802BB9C: mov edx, dword ptr [ebp + 0x10] */
   1846     eax = MEM32(esi + 0x8); /* 0x3802BB9F: mov eax, dword ptr [esi + 8] */
   1847     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0xCu);
   1848     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1849     edx = edx + 0xCu; /* 0x3802BBA2: add edx, 0xc */
   1850     _flag_k = FK_ADD;
   1851     PUSH32(esp, edx); /* 0x3802BBA5: push edx */
   1852     PUSH32(esp, eax); /* 0x3802BBA6: push eax */
   1853     PUSH32(esp, edi); /* 0x3802BBA7: push edi */
   1854     ecx = esi; /* 0x3802BBA8: mov ecx, esi */
   1855     RECOMP_ICALL(0x3802F200u); /* 0x3802BBAA: call 0x3802f200 */ /* not lifted */
   1856     RECOMP_FLAGS_IN();
   1857     eax = MEM32(esi + 0x4); /* 0x3802BBAF: mov eax, dword ptr [esi + 4] */
   1858     PUSH32(esp, eax); /* 0x3802BBB2: push eax */
   1859     MEM32(ebp + 0x10) = eax; /* 0x3802BBB3: mov dword ptr [ebp + 0x10], eax */
   1860     RECOMP_ICALL(0x3804B4F6u); /* 0x3802BBB6: call 0x3804b4f6 */ /* not lifted */
   1861     RECOMP_FLAGS_IN();
   1862     eax = MEM32(ebp + 0xC); /* 0x3802BBBB: mov eax, dword ptr [ebp + 0xc] */
   1863     ecx = eax + eax * 2; /* 0x3802BBBE: lea ecx, [eax + eax*2] */
   1864     edx = ebx + ecx * 4; /* 0x3802BBC1: lea edx, [ebx + ecx*4] */
   1865     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   1866     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1867     esp = esp + 4; /* 0x3802BBC4: add esp, 4 */
   1868     _flag_k = FK_ADD;
   1869     ecx = esi; /* 0x3802BBC7: mov ecx, esi */
   1870     MEM32(esi + 0xC) = edx; /* 0x3802BBC9: mov dword ptr [esi + 0xc], edx */
   1871     RECOMP_ICALL(0x3802DF80u); /* 0x3802BBCC: call 0x3802df80 */ /* not lifted */
   1872     RECOMP_FLAGS_IN();
   1873     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   1874     eax = eax + 1; /* 0x3802BBD1: inc eax */
   1875     _flag_k = FK_INC;
   1876     eax = eax + eax * 2; /* 0x3802BBD2: lea eax, [eax + eax*2] */
   1877     ecx = ebx + eax * 4; /* 0x3802BBD5: lea ecx, [ebx + eax*4] */
   1878     edi = POP32_VAL(esp); /* 0x3802BBD8: pop edi */
   1879     MEM32(esi + 0x4) = ebx; /* 0x3802BBD9: mov dword ptr [esi + 4], ebx */
   1880     MEM32(esi + 0x8) = ecx; /* 0x3802BBDC: mov dword ptr [esi + 8], ecx */
   1881     esi = POP32_VAL(esp); /* 0x3802BBDF: pop esi */
   1882     ebx = POP32_VAL(esp); /* 0x3802BBE0: pop ebx */
   1883     esp = ebp; /* 0x3802BBE1: mov esp, ebp */
   1884     ebp = POP32_VAL(esp); /* 0x3802BBE3: pop ebp */
   1885     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802BBE4: ret 0xc */
   1886 L_3802BBE7:
   1887     edx = ecx; /* 0x3802BBE7: mov edx, ecx */
   1888     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edi);
   1889     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1890     edx = edx - edi; /* 0x3802BBE9: sub edx, edi */
   1891     _flag_k = FK_CMP;
   1892     eax = 0x2AAAAAABu; /* 0x3802BBEB: mov eax, 0x2aaaaaab */
   1893     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(edx); /* 0x3802BBF0: imul edx */
   1894       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   1895       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   1896     if (1u) _cf = (((edx) >> 0) & 1u); /* 0x3802BBF2: sar edx, 1 */
   1897     if (1u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 1u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1898     edx = (uint32_t)((int32_t)edx >> 1u);
   1899     eax = edx; /* 0x3802BBF4: mov eax, edx */
   1900     if (31u) _cf = (((eax) >> 30) & 1u); /* 0x3802BBF6: shr eax, 0x1f */
   1901     if (31u) { _flag_a = recomp_flags_pack((eax >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1902     eax = eax >> 31u; /* 0x3802BBF6: shr eax, 0x1f */
   1903     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   1904     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1905     edx = edx + eax; /* 0x3802BBF9: add edx, eax */
   1906     _flag_k = FK_ADD;
   1907     /* cmp edx, 1 */ /* 0x3802BBFB: cmp edx, 1 */
   1908     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   1909     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1910     _flag_k = FK_CMP;
   1911     if (CMP_AE(_flag_a, _flag_b)) goto L_3802BC6F; /* 0x3802BBFE: jae 0x3802bc6f */
   1912 L_3802BC00:
   1913     edx = edi + 0xC; /* 0x3802BC00: lea edx, [edi + 0xc] */
   1914     PUSH32(esp, edx); /* 0x3802BC03: push edx */
   1915     PUSH32(esp, ecx); /* 0x3802BC04: push ecx */
   1916     PUSH32(esp, edi); /* 0x3802BC05: push edi */
   1917     ecx = esi; /* 0x3802BC06: mov ecx, esi */
   1918     RECOMP_ICALL(0x3802F200u); /* 0x3802BC08: call 0x3802f200 */ /* not lifted */
   1919     RECOMP_FLAGS_IN();
   1920     ebx = MEM32(esi + 0x8); /* 0x3802BC0D: mov ebx, dword ptr [esi + 8] */
   1921     eax = ebp + (-0xC); /* 0x3802BC10: lea eax, [ebp - 0xc] */
   1922     PUSH32(esp, eax); /* 0x3802BC13: push eax */
   1923     ecx = ebx; /* 0x3802BC14: mov ecx, ebx */
   1924     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
   1925     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1926     ecx = ecx - edi; /* 0x3802BC16: sub ecx, edi */
   1927     _flag_k = FK_CMP;
   1928     eax = 0x2AAAAAABu; /* 0x3802BC18: mov eax, 0x2aaaaaab */
   1929     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(ecx); /* 0x3802BC1D: imul ecx */
   1930       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   1931       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   1932     if (1u) _cf = (((edx) >> 0) & 1u); /* 0x3802BC1F: sar edx, 1 */
   1933     if (1u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 1u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1934     edx = (uint32_t)((int32_t)edx >> 1u);
   1935     ecx = edx; /* 0x3802BC21: mov ecx, edx */
   1936     if (31u) _cf = (((ecx) >> 30) & 1u); /* 0x3802BC23: shr ecx, 0x1f */
   1937     if (31u) { _flag_a = recomp_flags_pack((ecx >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   1938     ecx = ecx >> 31u; /* 0x3802BC23: shr ecx, 0x1f */
   1939     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   1940     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1941     edx = edx + ecx; /* 0x3802BC26: add edx, ecx */
   1942     _flag_k = FK_ADD;
   1943     eax = 1; /* 0x3802BC28: mov eax, 1 */
   1944     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   1945     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1946     eax = eax - edx; /* 0x3802BC2D: sub eax, edx */
   1947     _flag_k = FK_CMP;
   1948     PUSH32(esp, eax); /* 0x3802BC2F: push eax */
   1949     PUSH32(esp, ebx); /* 0x3802BC30: push ebx */
   1950     ecx = esi; /* 0x3802BC31: mov ecx, esi */
   1951     RECOMP_ICALL(0x3802F240u); /* 0x3802BC33: call 0x3802f240 */ /* not lifted */
   1952     RECOMP_FLAGS_IN();
   1953     eax = MEM32(esi + 0x8); /* 0x3802BC38: mov eax, dword ptr [esi + 8] */
   1954     /* cmp edi, eax */ /* 0x3802BC3B: cmp edi, eax */
   1955     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   1956     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1957     _flag_k = FK_CMP;
   1958     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BCCB; /* 0x3802BC3D: je 0x3802bccb */
   1959 L_3802BC43:
   1960     edx = MEM32(ebp + (-0xC)); /* 0x3802BC43: mov edx, dword ptr [ebp - 0xc] */
   1961     ecx = edi; /* 0x3802BC46: mov ecx, edi */
   1962     MEM32(ecx) = edx; /* 0x3802BC48: mov dword ptr [ecx], edx */
   1963     edx = MEM32(ebp + (-0x8)); /* 0x3802BC4A: mov edx, dword ptr [ebp - 8] */
   1964     MEM32(ecx + 0x4) = edx; /* 0x3802BC4D: mov dword ptr [ecx + 4], edx */
   1965     edx = MEM32(ebp + (-0x4)); /* 0x3802BC50: mov edx, dword ptr [ebp - 4] */
   1966     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(0xCu);
   1967     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1968     edi = edi + 0xCu; /* 0x3802BC53: add edi, 0xc */
   1969     _flag_k = FK_ADD;
   1970     /* cmp edi, eax */ /* 0x3802BC56: cmp edi, eax */
   1971     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   1972     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1973     _flag_k = FK_CMP;
   1974     MEM32(ecx + 0x8) = edx; /* 0x3802BC58: mov dword ptr [ecx + 8], edx */
   1975     RECOMP_BACKEDGE();
   1976     if (CMP_NE(_flag_a, _flag_b)) goto L_3802BC43; /* 0x3802BC5B: jne 0x3802bc43 */
   1977 L_3802BC5D:
   1978     eax = MEM32(esi + 0x8); /* 0x3802BC5D: mov eax, dword ptr [esi + 8] */
   1979     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xCu);
   1980     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1981     eax = eax + 0xCu; /* 0x3802BC60: add eax, 0xc */
   1982     _flag_k = FK_ADD;
   1983     edi = POP32_VAL(esp); /* 0x3802BC63: pop edi */
   1984     MEM32(esi + 0x8) = eax; /* 0x3802BC64: mov dword ptr [esi + 8], eax */
   1985     esi = POP32_VAL(esp); /* 0x3802BC67: pop esi */
   1986     ebx = POP32_VAL(esp); /* 0x3802BC68: pop ebx */
   1987     esp = ebp; /* 0x3802BC69: mov esp, ebp */
   1988     ebp = POP32_VAL(esp); /* 0x3802BC6B: pop ebp */
   1989     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802BC6C: ret 0xc */
   1990 L_3802BC6F:
   1991     PUSH32(esp, ecx); /* 0x3802BC6F: push ecx */
   1992     PUSH32(esp, ecx); /* 0x3802BC70: push ecx */
   1993     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0xFFFFFFF4u);
   1994     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1995     ecx = ecx + 0xFFFFFFF4u; /* 0x3802BC71: add ecx, -0xc */
   1996     _flag_k = FK_ADD;
   1997     PUSH32(esp, ecx); /* 0x3802BC74: push ecx */
   1998     ecx = esi; /* 0x3802BC75: mov ecx, esi */
   1999     RECOMP_ICALL(0x3802F200u); /* 0x3802BC77: call 0x3802f200 */ /* not lifted */
   2000     RECOMP_FLAGS_IN();
   2001     ecx = MEM32(esi + 0x8); /* 0x3802BC7C: mov ecx, dword ptr [esi + 8] */
   2002     eax = ecx + (-0xC); /* 0x3802BC7F: lea eax, [ecx - 0xc] */
   2003     /* cmp edi, eax */ /* 0x3802BC82: cmp edi, eax */
   2004     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   2005     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2006     _flag_k = FK_CMP;
   2007     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BCAA; /* 0x3802BC84: je 0x3802bcaa */
   2008 L_3802BC86:
   2009     goto L_3802BC8B; /* 0x3802BC86: jmp 0x3802bc8b */
   2010 L_3802BC88:
   2011     ecx = MEM32(ebp + 0x10); /* 0x3802BC88: mov ecx, dword ptr [ebp + 0x10] */
   2012 L_3802BC8B:
   2013     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xCu);
   2014     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2015     eax = eax - 0xCu; /* 0x3802BC8B: sub eax, 0xc */
   2016     _flag_k = FK_CMP;
   2017     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0xCu);
   2018     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2019     ecx = ecx - 0xCu; /* 0x3802BC8E: sub ecx, 0xc */
   2020     _flag_k = FK_CMP;
   2021     /* cmp eax, edi */ /* 0x3802BC91: cmp eax, edi */
   2022     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   2023     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2024     _flag_k = FK_CMP;
   2025     edx = eax; /* 0x3802BC93: mov edx, eax */
   2026     ebx = MEM32(edx); /* 0x3802BC95: mov ebx, dword ptr [edx] */
   2027     MEM32(ebp + 0x10) = ecx; /* 0x3802BC97: mov dword ptr [ebp + 0x10], ecx */
   2028     MEM32(ecx) = ebx; /* 0x3802BC9A: mov dword ptr [ecx], ebx */
   2029     ebx = MEM32(edx + 0x4); /* 0x3802BC9C: mov ebx, dword ptr [edx + 4] */
   2030     MEM32(ecx + 0x4) = ebx; /* 0x3802BC9F: mov dword ptr [ecx + 4], ebx */
   2031     edx = MEM32(edx + 0x8); /* 0x3802BCA2: mov edx, dword ptr [edx + 8] */
   2032     MEM32(ecx + 0x8) = edx; /* 0x3802BCA5: mov dword ptr [ecx + 8], edx */
   2033     RECOMP_BACKEDGE();
   2034     if (CMP_NE(_flag_a, _flag_b)) goto L_3802BC88; /* 0x3802BCA8: jne 0x3802bc88 */
   2035 L_3802BCAA:
   2036     eax = edi + 0xC; /* 0x3802BCAA: lea eax, [edi + 0xc] */
   2037     /* cmp edi, eax */ /* 0x3802BCAD: cmp edi, eax */
   2038     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   2039     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2040     _flag_k = FK_CMP;
   2041     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BCCB; /* 0x3802BCAF: je 0x3802bccb */
   2042 L_3802BCB1:
   2043     edx = MEM32(ebp + (-0xC)); /* 0x3802BCB1: mov edx, dword ptr [ebp - 0xc] */
   2044     ecx = edi; /* 0x3802BCB4: mov ecx, edi */
   2045     MEM32(ecx) = edx; /* 0x3802BCB6: mov dword ptr [ecx], edx */
   2046     edx = MEM32(ebp + (-0x8)); /* 0x3802BCB8: mov edx, dword ptr [ebp - 8] */
   2047     MEM32(ecx + 0x4) = edx; /* 0x3802BCBB: mov dword ptr [ecx + 4], edx */
   2048     edx = MEM32(ebp + (-0x4)); /* 0x3802BCBE: mov edx, dword ptr [ebp - 4] */
   2049     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(0xCu);
   2050     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2051     edi = edi + 0xCu; /* 0x3802BCC1: add edi, 0xc */
   2052     _flag_k = FK_ADD;
   2053     /* cmp edi, eax */ /* 0x3802BCC4: cmp edi, eax */
   2054     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   2055     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2056     _flag_k = FK_CMP;
   2057     MEM32(ecx + 0x8) = edx; /* 0x3802BCC6: mov dword ptr [ecx + 8], edx */
   2058     RECOMP_BACKEDGE();
   2059     if (CMP_NE(_flag_a, _flag_b)) goto L_3802BCB1; /* 0x3802BCC9: jne 0x3802bcb1 */
   2060 L_3802BCCB:
   2061     eax = MEM32(esi + 0x8); /* 0x3802BCCB: mov eax, dword ptr [esi + 8] */
   2062     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xCu);
   2063     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2064     eax = eax + 0xCu; /* 0x3802BCCE: add eax, 0xc */
   2065     _flag_k = FK_ADD;
   2066     edi = POP32_VAL(esp); /* 0x3802BCD1: pop edi */
   2067     MEM32(esi + 0x8) = eax; /* 0x3802BCD2: mov dword ptr [esi + 8], eax */
   2068     esi = POP32_VAL(esp); /* 0x3802BCD5: pop esi */
   2069     ebx = POP32_VAL(esp); /* 0x3802BCD6: pop ebx */
   2070     esp = ebp; /* 0x3802BCD7: mov esp, ebp */
   2071     ebp = POP32_VAL(esp); /* 0x3802BCD9: pop ebp */
   2072     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802BCDA: ret 0xc */
   2073     RECOMP_REGS_OUT();
   2074 }
   2075 
   2076 void sub_3802BCE0(void) {
   2077     int _fpu_cmp = 0;
   2078     uint32_t _cf = 0;
   2079     int _df = 1;
   2080     uint32_t _flag_k = FK_NONE;
   2081     uint32_t _flag_a = 0, _flag_b = 0;
   2082     uint32_t _itail_tgt = 0;
   2083     RECOMP_REGS_LOCALS
   2084     RECOMP_ENTER(0x3802BCE0u);
   2085 
   2086 L_3802BCE0:
   2087     eax = MEM32(ecx + 0x54); /* 0x3802BCE0: mov eax, dword ptr [ecx + 0x54] */
   2088     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802BCE3: ret  */
   2089     RECOMP_REGS_OUT();
   2090 }
   2091 
   2092 void sub_3802BCF0(void) {
   2093     int _fpu_cmp = 0;
   2094     uint32_t _cf = 0;
   2095     int _df = 1;
   2096     uint32_t _flag_k = FK_NONE;
   2097     uint32_t _flag_a = 0, _flag_b = 0;
   2098     uint32_t _itail_tgt = 0;
   2099     RECOMP_REGS_LOCALS
   2100     RECOMP_ENTER(0x3802BCF0u);
   2101 
   2102 L_3802BCF0:
   2103     PUSH32(esp, ebp); /* 0x3802BCF0: push ebp */
   2104     ebp = esp; /* 0x3802BCF1: mov ebp, esp */
   2105     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   2106     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2107     esp = esp - 0xCu; /* 0x3802BCF3: sub esp, 0xc */
   2108     _flag_k = FK_CMP;
   2109     eax = MEM32(ebp + 0x8); /* 0x3802BCF6: mov eax, dword ptr [ebp + 8] */
   2110     edx = MEM32(eax); /* 0x3802BCF9: mov edx, dword ptr [eax] */
   2111     MEM32(ebp + (-0xC)) = edx; /* 0x3802BCFB: mov dword ptr [ebp - 0xc], edx */
   2112     edx = MEM32(eax + 0x4); /* 0x3802BCFE: mov edx, dword ptr [eax + 4] */
   2113     eax = MEM32(eax + 0x8); /* 0x3802BD01: mov eax, dword ptr [eax + 8] */
   2114     MEM32(ebp + (-0x8)) = edx; /* 0x3802BD04: mov dword ptr [ebp - 8], edx */
   2115     MEM32(ebp + (-0x4)) = eax; /* 0x3802BD07: mov dword ptr [ebp - 4], eax */
   2116     RECOMP_ICALL(0x3802BF20u); /* 0x3802BD0A: call 0x3802bf20 */ /* not lifted */
   2117     RECOMP_FLAGS_IN();
   2118     edx = MEM32(eax); /* 0x3802BD0F: mov edx, dword ptr [eax] */
   2119     PUSH32(esp, 0); /* 0x3802BD11: push 0 */
   2120     PUSH32(esp, 0); /* 0x3802BD13: push 0 */
   2121     ecx = ebp + (-0xC); /* 0x3802BD15: lea ecx, [ebp - 0xc] */
   2122     PUSH32(esp, ecx); /* 0x3802BD18: push ecx */
   2123     ecx = eax; /* 0x3802BD19: mov ecx, eax */
   2124     RECOMP_ICALL(MEM32(edx + 0x20)); /* 0x3802BD1B: call dword ptr [edx + 0x20] */
   2125     RECOMP_FLAGS_IN();
   2126     _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   2127     _cf = (LO8(eax)) != 0;
   2128     SET_LO8(eax, (uint32_t)(-(int32_t)LO8(eax))); /* 0x3802BD1E: neg al */
   2129     _flag_k = FK_NARROW(FK_CMP, 24);
   2130     { uint32_t _sa = eax, _sb = eax, _sc = _cf; /* 0x3802BD20: sbb eax, eax */
   2131       eax = _sc ? 0xFFFFFFFFu : 0;
   2132       _flag_a = recomp_flags_sbb(_sa, _sb, _sc); _flag_b = 0;
   2133       _flag_k = FK_EFLAGS; _cf = _flag_a & 1u; }
   2134     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   2135     eax = eax + 1; /* 0x3802BD22: inc eax */
   2136     _flag_k = FK_INC;
   2137     esp = ebp; /* 0x3802BD23: mov esp, ebp */
   2138     ebp = POP32_VAL(esp); /* 0x3802BD25: pop ebp */
   2139     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802BD26: ret 4 */
   2140     RECOMP_REGS_OUT();
   2141 }
   2142 
   2143 void sub_3802BD30(void) {
   2144     int _fpu_cmp = 0;
   2145     uint32_t _cf = 0;
   2146     int _df = 1;
   2147     uint32_t _flag_k = FK_NONE;
   2148     uint32_t _flag_a = 0, _flag_b = 0;
   2149     uint32_t _itail_tgt = 0;
   2150     RECOMP_REGS_LOCALS
   2151     RECOMP_ENTER(0x3802BD30u);
   2152 
   2153 L_3802BD30:
   2154     PUSH32(esp, ebp); /* 0x3802BD30: push ebp */
   2155     ebp = esp; /* 0x3802BD31: mov ebp, esp */
   2156     PUSH32(esp, esi); /* 0x3802BD33: push esi */
   2157     esi = ecx; /* 0x3802BD34: mov esi, ecx */
   2158     SET_LO8(ecx, MEM8(0x3806EE5D)); /* 0x3802BD36: mov cl, byte ptr [0x3806ee5d] */
   2159     SET_LO8(eax, 1); /* 0x3802BD3C: mov al, 1 */
   2160     /* test LO8(eax), LO8(ecx) */ /* 0x3802BD3E: test al, cl */
   2161     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24;
   2162     _cf = 0;
   2163     _flag_k = FK_NARROW(FK_TEST, 24);
   2164     PUSH32(esp, edi); /* 0x3802BD40: push edi */
   2165     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802BD6E; /* 0x3802BD41: jne 0x3802bd6e */
   2166 L_3802BD43:
   2167     SET_LO8(edx, LO8(ecx)); /* 0x3802BD43: mov dl, cl */
   2168     _flag_a = (uint32_t)((LO8(edx) | LO8(eax))) << 24; _flag_b = (uint32_t)((LO8(edx) | LO8(eax))) << 24;
   2169     SET_LO8(edx, LO8(edx) | LO8(eax)); /* 0x3802BD45: or dl, al */
   2170     _cf = 0;
   2171     _flag_k = FK_NARROW(FK_TEST, 24);
   2172     PUSH32(esp, 0x3802BDE0u); /* 0x3802BD47: push 0x3802bde0 */
   2173     MEM8(0x3806EE5D) = (uint8_t)(LO8(edx)); /* 0x3802BD4C: mov byte ptr [0x3806ee5d], dl */
   2174     MEM32(0x3806EE68) = 0; /* 0x3802BD52: mov dword ptr [0x3806ee68], 0 */
   2175     MEM32(0x3806EE6C) = 0; /* 0x3802BD5C: mov dword ptr [0x3806ee6c], 0 */
   2176     RECOMP_ICALL(0x3804B54Cu); /* 0x3802BD66: call 0x3804b54c */ /* not lifted */
   2177     RECOMP_FLAGS_IN();
   2178     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   2179     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2180     esp = esp + 4; /* 0x3802BD6B: add esp, 4 */
   2181     _flag_k = FK_ADD;
   2182 L_3802BD6E:
   2183     ecx = MEM32(esi + 0x50); /* 0x3802BD6E: mov ecx, dword ptr [esi + 0x50] */
   2184     /* test ecx, ecx */ /* 0x3802BD71: test ecx, ecx */
   2185     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   2186     _cf = 0;
   2187     _flag_k = FK_TEST;
   2188     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802BD80; /* 0x3802BD73: jne 0x3802bd80 */
   2189 L_3802BD75:
   2190     edi = POP32_VAL(esp); /* 0x3802BD75: pop edi */
   2191     eax = 0x3806EE68u; /* 0x3802BD76: mov eax, 0x3806ee68 */
   2192     esi = POP32_VAL(esp); /* 0x3802BD7B: pop esi */
   2193     ebp = POP32_VAL(esp); /* 0x3802BD7C: pop ebp */
   2194     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802BD7D: ret 4 */
   2195 L_3802BD80:
   2196     edi = MEM32(ecx + 0x4); /* 0x3802BD80: mov edi, dword ptr [ecx + 4] */
   2197     edx = MEM32(ecx + 0x8); /* 0x3802BD83: mov edx, dword ptr [ecx + 8] */
   2198     eax = edi; /* 0x3802BD86: mov eax, edi */
   2199     /* cmp eax, edx */ /* 0x3802BD88: cmp eax, edx */
   2200     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   2201     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2202     _flag_k = FK_CMP;
   2203     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BD9A; /* 0x3802BD8A: je 0x3802bd9a */
   2204 L_3802BD8C:
   2205     esi = MEM32(ebp + 0x8); /* 0x3802BD8C: mov esi, dword ptr [ebp + 8] */
   2206 L_3802BD8F:
   2207     /* cmp MEM32(eax), esi */ /* 0x3802BD8F: cmp dword ptr [eax], esi */
   2208     _flag_a = (uint32_t)(MEM32(eax)); _flag_b = (uint32_t)(esi);
   2209     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2210     _flag_k = FK_CMP;
   2211     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BDC3; /* 0x3802BD91: je 0x3802bdc3 */
   2212 L_3802BD93:
   2213     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xCu);
   2214     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2215     eax = eax + 0xCu; /* 0x3802BD93: add eax, 0xc */
   2216     _flag_k = FK_ADD;
   2217     /* cmp eax, edx */ /* 0x3802BD96: cmp eax, edx */
   2218     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   2219     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2220     _flag_k = FK_CMP;
   2221     RECOMP_BACKEDGE();
   2222     if (CMP_NE(_flag_a, _flag_b)) goto L_3802BD8F; /* 0x3802BD98: jne 0x3802bd8f */
   2223 L_3802BD9A:
   2224     eax = MEM32(ecx + 0x4); /* 0x3802BD9A: mov eax, dword ptr [ecx + 4] */
   2225     /* test eax, eax */ /* 0x3802BD9D: test eax, eax */
   2226     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   2227     _cf = 0;
   2228     _flag_k = FK_TEST;
   2229     if (TEST_Z(_flag_a, _flag_b)) goto L_3802BDB8; /* 0x3802BD9F: je 0x3802bdb8 */
   2230 L_3802BDA1:
   2231     ecx = MEM32(ecx + 0x8); /* 0x3802BDA1: mov ecx, dword ptr [ecx + 8] */
   2232     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
   2233     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2234     ecx = ecx - eax; /* 0x3802BDA4: sub ecx, eax */
   2235     _flag_k = FK_CMP;
   2236     eax = 0x2AAAAAABu; /* 0x3802BDA6: mov eax, 0x2aaaaaab */
   2237     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(ecx); /* 0x3802BDAB: imul ecx */
   2238       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   2239       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   2240     if (1u) _cf = (((edx) >> 0) & 1u); /* 0x3802BDAD: sar edx, 1 */
   2241     if (1u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 1u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   2242     edx = (uint32_t)((int32_t)edx >> 1u);
   2243     eax = edx; /* 0x3802BDAF: mov eax, edx */
   2244     if (31u) _cf = (((eax) >> 30) & 1u); /* 0x3802BDB1: shr eax, 0x1f */
   2245     if (31u) { _flag_a = recomp_flags_pack((eax >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   2246     eax = eax >> 31u; /* 0x3802BDB1: shr eax, 0x1f */
   2247     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   2248     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2249     edx = edx + eax; /* 0x3802BDB4: add edx, eax */
   2250     _flag_k = FK_ADD;
   2251     if (/* add result */ recomp_cond(_flag_k, _flag_a, _flag_b, CC_NE)) goto L_3802BDCC; /* 0x3802BDB6: jne 0x3802bdcc */
   2252 L_3802BDB8:
   2253     edi = POP32_VAL(esp); /* 0x3802BDB8: pop edi */
   2254     eax = 0x3806EE68u; /* 0x3802BDB9: mov eax, 0x3806ee68 */
   2255     esi = POP32_VAL(esp); /* 0x3802BDBE: pop esi */
   2256     ebp = POP32_VAL(esp); /* 0x3802BDBF: pop ebp */
   2257     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802BDC0: ret 4 */
   2258 L_3802BDC3:
   2259     edi = POP32_VAL(esp); /* 0x3802BDC3: pop edi */
   2260     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   2261     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2262     eax = eax + 4; /* 0x3802BDC4: add eax, 4 */
   2263     _flag_k = FK_ADD;
   2264     esi = POP32_VAL(esp); /* 0x3802BDC7: pop esi */
   2265     ebp = POP32_VAL(esp); /* 0x3802BDC8: pop ebp */
   2266     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802BDC9: ret 4 */
   2267 L_3802BDCC:
   2268     eax = edi + 0x4; /* 0x3802BDCC: lea eax, [edi + 4] */
   2269     edi = POP32_VAL(esp); /* 0x3802BDCF: pop edi */
   2270     esi = POP32_VAL(esp); /* 0x3802BDD0: pop esi */
   2271     ebp = POP32_VAL(esp); /* 0x3802BDD1: pop ebp */
   2272     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802BDD2: ret 4 */
   2273     RECOMP_REGS_OUT();
   2274 }
   2275 
   2276 void sub_3802BDE0(void) {
   2277     int _fpu_cmp = 0;
   2278     uint32_t _cf = 0;
   2279     int _df = 1;
   2280     uint32_t _flag_k = FK_NONE;
   2281     uint32_t _flag_a = 0, _flag_b = 0;
   2282     uint32_t _itail_tgt = 0;
   2283     RECOMP_REGS_LOCALS
   2284     RECOMP_ENTER(0x3802BDE0u);
   2285 
   2286 L_3802BDE0:
   2287     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802BDE0: ret  */
   2288     RECOMP_REGS_OUT();
   2289 }
   2290 
   2291 void sub_3802BDF0(void) {
   2292     int _fpu_cmp = 0;
   2293     uint32_t _cf = 0;
   2294     int _df = 1;
   2295     uint32_t _flag_k = FK_NONE;
   2296     uint32_t _flag_a = 0, _flag_b = 0;
   2297     uint32_t _itail_tgt = 0;
   2298     RECOMP_REGS_LOCALS
   2299     RECOMP_ENTER(0x3802BDF0u);
   2300 
   2301 L_3802BDF0:
   2302     PUSH32(esp, ebp); /* 0x3802BDF0: push ebp */
   2303     ebp = esp; /* 0x3802BDF1: mov ebp, esp */
   2304     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   2305     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2306     esp = esp - 8; /* 0x3802BDF3: sub esp, 8 */
   2307     _flag_k = FK_CMP;
   2308     SET_LO8(eax, MEM8(0x3806EDC8)); /* 0x3802BDF6: mov al, byte ptr [0x3806edc8] */
   2309     /* test LO8(eax), 1 */ /* 0x3802BDFB: test al, 1 */
   2310     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   2311     _cf = 0;
   2312     _flag_k = FK_NARROW(FK_TEST, 24);
   2313     PUSH32(esp, ebx); /* 0x3802BDFD: push ebx */
   2314     PUSH32(esp, esi); /* 0x3802BDFE: push esi */
   2315     PUSH32(esp, edi); /* 0x3802BDFF: push edi */
   2316     edi = ecx; /* 0x3802BE00: mov edi, ecx */
   2317     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802BE28; /* 0x3802BE02: jne 0x3802be28 */
   2318 L_3802BE04:
   2319     SET_LO8(edx, LO8(eax)); /* 0x3802BE04: mov dl, al */
   2320     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   2321     eax = 0; /* 0x3802BE06: xor eax, eax */
   2322     _cf = 0;
   2323     _flag_k = FK_TEST;
   2324     _flag_a = (uint32_t)((LO8(edx) | 1)) << 24; _flag_b = (uint32_t)((LO8(edx) | 1)) << 24;
   2325     SET_LO8(edx, LO8(edx) | 1); /* 0x3802BE08: or dl, 1 */
   2326     _cf = 0;
   2327     _flag_k = FK_NARROW(FK_TEST, 24);
   2328     PUSH32(esp, 0x3802BED0u); /* 0x3802BE0B: push 0x3802bed0 */
   2329     MEM8(0x3806EDC8) = (uint8_t)(LO8(edx)); /* 0x3802BE10: mov byte ptr [0x3806edc8], dl */
   2330     MEM32(0x3806EDF0) = eax; /* 0x3802BE16: mov dword ptr [0x3806edf0], eax */
   2331     MEM32(0x3806EDF4) = eax; /* 0x3802BE1B: mov dword ptr [0x3806edf4], eax */
   2332     RECOMP_ICALL(0x3804B54Cu); /* 0x3802BE20: call 0x3804b54c */ /* not lifted */
   2333     RECOMP_FLAGS_IN();
   2334     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   2335     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2336     esp = esp + 4; /* 0x3802BE25: add esp, 4 */
   2337     _flag_k = FK_ADD;
   2338 L_3802BE28:
   2339     eax = MEM32(ebp + 0x8); /* 0x3802BE28: mov eax, dword ptr [ebp + 8] */
   2340     ebx = MEM32(ebp + 0xC); /* 0x3802BE2B: mov ebx, dword ptr [ebp + 0xc] */
   2341     /* cmp LO16(eax), LO16(ebx) */ /* 0x3802BE2E: cmp ax, bx */
   2342     _flag_a = (uint32_t)(LO16(eax)) << 16; _flag_b = (uint32_t)(LO16(ebx)) << 16;
   2343     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2344     _flag_k = FK_NARROW(FK_CMP, 16);
   2345     if (CMP_LE(_flag_a, _flag_b)) goto L_3802BE39; /* 0x3802BE31: jle 0x3802be39 */
   2346 L_3802BE33:
   2347     ecx = eax; /* 0x3802BE33: mov ecx, eax */
   2348     eax = ebx; /* 0x3802BE35: mov eax, ebx */
   2349     ebx = ecx; /* 0x3802BE37: mov ebx, ecx */
   2350 L_3802BE39:
   2351     esi = MEM32(edi + 0x48); /* 0x3802BE39: mov esi, dword ptr [edi + 0x48] */
   2352     ecx = ebp + 0x8; /* 0x3802BE3C: lea ecx, [ebp + 8] */
   2353     eax = (int32_t)(int16_t)LO16(eax); /* 0x3802BE3F: movsx eax, ax */
   2354     PUSH32(esp, ecx); /* 0x3802BE42: push ecx */
   2355     edx = ebp + (-0x8); /* 0x3802BE43: lea edx, [ebp - 8] */
   2356     PUSH32(esp, edx); /* 0x3802BE46: push edx */
   2357     ecx = esi; /* 0x3802BE47: mov ecx, esi */
   2358     MEM32(ebp + 0x8) = eax; /* 0x3802BE49: mov dword ptr [ebp + 8], eax */
   2359     RECOMP_ICALL(0x3800FD90u); /* 0x3802BE4C: call 0x3800fd90 */ /* not lifted */
   2360     RECOMP_FLAGS_IN();
   2361     eax = MEM32(eax); /* 0x3802BE51: mov eax, dword ptr [eax] */
   2362     esi = MEM32(esi + 0x4); /* 0x3802BE53: mov esi, dword ptr [esi + 4] */
   2363     /* cmp eax, esi */ /* 0x3802BE56: cmp eax, esi */
   2364     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   2365     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2366     _flag_k = FK_CMP;
   2367     MEM32(ebp + 0xC) = eax; /* 0x3802BE58: mov dword ptr [ebp + 0xc], eax */
   2368     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BE6A; /* 0x3802BE5B: je 0x3802be6a */
   2369 L_3802BE5D:
   2370     ecx = MEM32(ebp + 0x8); /* 0x3802BE5D: mov ecx, dword ptr [ebp + 8] */
   2371     /* cmp ecx, MEM32(eax + 0xC) */ /* 0x3802BE60: cmp ecx, dword ptr [eax + 0xc] */
   2372     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax + 0xC));
   2373     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2374     _flag_k = FK_CMP;
   2375     if (CMP_L(_flag_a, _flag_b)) goto L_3802BE6A; /* 0x3802BE63: jl 0x3802be6a */
   2376 L_3802BE65:
   2377     eax = ebp + 0xC; /* 0x3802BE65: lea eax, [ebp + 0xc] */
   2378     goto L_3802BE70; /* 0x3802BE68: jmp 0x3802be70 */
   2379 L_3802BE6A:
   2380     MEM32(ebp + (-0x4)) = esi; /* 0x3802BE6A: mov dword ptr [ebp - 4], esi */
   2381     eax = ebp + (-0x4); /* 0x3802BE6D: lea eax, [ebp - 4] */
   2382 L_3802BE70:
   2383     edx = MEM32(edi + 0x48); /* 0x3802BE70: mov edx, dword ptr [edi + 0x48] */
   2384     eax = MEM32(eax); /* 0x3802BE73: mov eax, dword ptr [eax] */
   2385     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3802BE75: cmp eax, dword ptr [edx + 4] */
   2386     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   2387     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2388     _flag_k = FK_CMP;
   2389     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BEBA; /* 0x3802BE78: je 0x3802beba */
   2390 L_3802BE7A:
   2391     edx = MEM32(eax + 0x10); /* 0x3802BE7A: mov edx, dword ptr [eax + 0x10] */
   2392     ecx = MEM32(edx + 0x4); /* 0x3802BE7D: mov ecx, dword ptr [edx + 4] */
   2393     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   2394     eax = 0; /* 0x3802BE80: xor eax, eax */
   2395     _cf = 0;
   2396     _flag_k = FK_TEST;
   2397     esi = ecx; /* 0x3802BE82: mov esi, ecx */
   2398 L_3802BE84:
   2399     /* test ecx, ecx */ /* 0x3802BE84: test ecx, ecx */
   2400     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   2401     _cf = 0;
   2402     _flag_k = FK_TEST;
   2403     if (TEST_Z(_flag_a, _flag_b)) goto L_3802BEBA; /* 0x3802BE86: je 0x3802beba */
   2404 L_3802BE88:
   2405     edi = MEM32(edx + 0x8); /* 0x3802BE88: mov edi, dword ptr [edx + 8] */
   2406     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx);
   2407     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2408     edi = edi - ecx; /* 0x3802BE8B: sub edi, ecx */
   2409     _flag_k = FK_CMP;
   2410     if (4u) _cf = (((edi) >> 3) & 1u); /* 0x3802BE8D: sar edi, 4 */
   2411     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edi >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   2412     edi = (uint32_t)((int32_t)edi >> 4u);
   2413     /* cmp eax, edi */ /* 0x3802BE90: cmp eax, edi */
   2414     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   2415     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2416     _flag_k = FK_CMP;
   2417     if (CMP_AE(_flag_a, _flag_b)) goto L_3802BEBA; /* 0x3802BE92: jae 0x3802beba */
   2418 L_3802BE94:
   2419     edi = (int32_t)(int16_t)LO16(ebx); /* 0x3802BE94: movsx edi, bx */
   2420     /* cmp MEM32(esi), edi */ /* 0x3802BE97: cmp dword ptr [esi], edi */
   2421     _flag_a = (uint32_t)(MEM32(esi)); _flag_b = (uint32_t)(edi);
   2422     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2423     _flag_k = FK_CMP;
   2424     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BEA1; /* 0x3802BE99: je 0x3802bea1 */
   2425 L_3802BE9B:
   2426     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   2427     eax = eax + 1; /* 0x3802BE9B: inc eax */
   2428     _flag_k = FK_INC;
   2429     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0x10u);
   2430     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2431     esi = esi + 0x10u; /* 0x3802BE9C: add esi, 0x10 */
   2432     _flag_k = FK_ADD;
   2433     RECOMP_BACKEDGE();
   2434     goto L_3802BE84; /* 0x3802BE9F: jmp 0x3802be84 */
   2435 L_3802BEA1:
   2436     ecx = MEM32(ebp + 0x10); /* 0x3802BEA1: mov ecx, dword ptr [ebp + 0x10] */
   2437     edi = POP32_VAL(esp); /* 0x3802BEA4: pop edi */
   2438     MEM8(ecx) = (uint8_t)(1); /* 0x3802BEA5: mov byte ptr [ecx], 1 */
   2439     edx = MEM32(edx + 0x4); /* 0x3802BEA8: mov edx, dword ptr [edx + 4] */
   2440     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802BEAB: shl eax, 4 */
   2441     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   2442     eax = eax << 4u; /* 0x3802BEAB: shl eax, 4 */
   2443     esi = POP32_VAL(esp); /* 0x3802BEAE: pop esi */
   2444     eax = eax + edx + 0x8; /* 0x3802BEAF: lea eax, [eax + edx + 8] */
   2445     ebx = POP32_VAL(esp); /* 0x3802BEB3: pop ebx */
   2446     esp = ebp; /* 0x3802BEB4: mov esp, ebp */
   2447     ebp = POP32_VAL(esp); /* 0x3802BEB6: pop ebp */
   2448     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802BEB7: ret 0xc */
   2449 L_3802BEBA:
   2450     eax = MEM32(ebp + 0x10); /* 0x3802BEBA: mov eax, dword ptr [ebp + 0x10] */
   2451     edi = POP32_VAL(esp); /* 0x3802BEBD: pop edi */
   2452     esi = POP32_VAL(esp); /* 0x3802BEBE: pop esi */
   2453     MEM8(eax) = (uint8_t)(0); /* 0x3802BEBF: mov byte ptr [eax], 0 */
   2454     eax = 0x3806EDF0u; /* 0x3802BEC2: mov eax, 0x3806edf0 */
   2455     ebx = POP32_VAL(esp); /* 0x3802BEC7: pop ebx */
   2456     esp = ebp; /* 0x3802BEC8: mov esp, ebp */
   2457     ebp = POP32_VAL(esp); /* 0x3802BECA: pop ebp */
   2458     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802BECB: ret 0xc */
   2459     RECOMP_REGS_OUT();
   2460 }
   2461 
   2462 void sub_3802BED0(void) {
   2463     int _fpu_cmp = 0;
   2464     uint32_t _cf = 0;
   2465     int _df = 1;
   2466     uint32_t _flag_k = FK_NONE;
   2467     uint32_t _flag_a = 0, _flag_b = 0;
   2468     uint32_t _itail_tgt = 0;
   2469     RECOMP_REGS_LOCALS
   2470     RECOMP_ENTER(0x3802BED0u);
   2471 
   2472 L_3802BED0:
   2473     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802BED0: ret  */
   2474     RECOMP_REGS_OUT();
   2475 }
   2476 
   2477 void sub_3802BEE0(void) {
   2478     int _fpu_cmp = 0;
   2479     uint32_t _cf = 0;
   2480     int _df = 1;
   2481     uint32_t _flag_k = FK_NONE;
   2482     uint32_t _flag_a = 0, _flag_b = 0;
   2483     uint32_t _itail_tgt = 0;
   2484     RECOMP_REGS_LOCALS
   2485     RECOMP_ENTER(0x3802BEE0u);
   2486 
   2487 L_3802BEE0:
   2488     PUSH32(esp, esi); /* 0x3802BEE0: push esi */
   2489     esi = MEM32(ecx + 0x58); /* 0x3802BEE1: mov esi, dword ptr [ecx + 0x58] */
   2490     RECOMP_ICALL(0x38029E80u); /* 0x3802BEE4: call 0x38029e80 */ /* not lifted */
   2491     RECOMP_FLAGS_IN();
   2492     ecx = eax; /* 0x3802BEE9: mov ecx, eax */
   2493     RECOMP_ICALL(0x38039DA0u); /* 0x3802BEEB: call 0x38039da0 */ /* not lifted */
   2494     RECOMP_FLAGS_IN();
   2495     edx = ((int32_t)eax < 0) ? 0xFFFFFFFFu : 0; /* 0x3802BEF0: cdq  */
   2496     { int64_t _dividend = ((int64_t)(int32_t)edx << 32) | eax; int32_t _dv = (int32_t)esi; /* 0x3802BEF1: idiv esi */
   2497       if (_dv && !(_dv == -1 && _dividend == INT64_MIN)) { eax = (uint32_t)((int32_t)(_dividend / _dv)); edx = (uint32_t)((int32_t)(_dividend % _dv)); }
   2498       else { eax = 0; edx = 0; } }
   2499     esi = POP32_VAL(esp); /* 0x3802BEF3: pop esi */
   2500     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802BEF4: ret  */
   2501     RECOMP_REGS_OUT();
   2502 }
   2503 
   2504 void sub_3802BF00(void) {
   2505     int _fpu_cmp = 0;
   2506     uint32_t _cf = 0;
   2507     int _df = 1;
   2508     uint32_t _flag_k = FK_NONE;
   2509     uint32_t _flag_a = 0, _flag_b = 0;
   2510     uint32_t _itail_tgt = 0;
   2511     RECOMP_REGS_LOCALS
   2512     RECOMP_ENTER(0x3802BF00u);
   2513 
   2514 L_3802BF00:
   2515     PUSH32(esp, esi); /* 0x3802BF00: push esi */
   2516     esi = MEM32(ecx + 0x58); /* 0x3802BF01: mov esi, dword ptr [ecx + 0x58] */
   2517     RECOMP_ICALL(0x38029E80u); /* 0x3802BF04: call 0x38029e80 */ /* not lifted */
   2518     RECOMP_FLAGS_IN();
   2519     ecx = eax; /* 0x3802BF09: mov ecx, eax */
   2520     RECOMP_ICALL(0x38039DB0u); /* 0x3802BF0B: call 0x38039db0 */ /* not lifted */
   2521     RECOMP_FLAGS_IN();
   2522     edx = ((int32_t)eax < 0) ? 0xFFFFFFFFu : 0; /* 0x3802BF10: cdq  */
   2523     { int64_t _dividend = ((int64_t)(int32_t)edx << 32) | eax; int32_t _dv = (int32_t)esi; /* 0x3802BF11: idiv esi */
   2524       if (_dv && !(_dv == -1 && _dividend == INT64_MIN)) { eax = (uint32_t)((int32_t)(_dividend / _dv)); edx = (uint32_t)((int32_t)(_dividend % _dv)); }
   2525       else { eax = 0; edx = 0; } }
   2526     esi = POP32_VAL(esp); /* 0x3802BF13: pop esi */
   2527     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802BF14: ret  */
   2528     RECOMP_REGS_OUT();
   2529 }
   2530 
   2531 void sub_3802BF20(void) {
   2532     int _fpu_cmp = 0;
   2533     uint32_t _cf = 0;
   2534     int _df = 1;
   2535     uint32_t _flag_k = FK_NONE;
   2536     uint32_t _flag_a = 0, _flag_b = 0;
   2537     uint32_t _itail_tgt = 0;
   2538     RECOMP_REGS_LOCALS
   2539     RECOMP_ENTER(0x3802BF20u);
   2540 
   2541 L_3802BF20:
   2542     eax = MEM32(ecx + 0x68); /* 0x3802BF20: mov eax, dword ptr [ecx + 0x68] */
   2543     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802BF23: ret  */
   2544     RECOMP_REGS_OUT();
   2545 }
   2546 
   2547 void sub_3802BF30(void) {
   2548     int _fpu_cmp = 0;
   2549     uint32_t _cf = 0;
   2550     int _df = 1;
   2551     uint32_t _flag_k = FK_NONE;
   2552     uint32_t _flag_a = 0, _flag_b = 0;
   2553     uint32_t _itail_tgt = 0;
   2554     RECOMP_REGS_LOCALS
   2555     RECOMP_ENTER(0x3802BF30u);
   2556 
   2557 L_3802BF30:
   2558     PUSH32(esp, ebp); /* 0x3802BF30: push ebp */
   2559     ebp = esp; /* 0x3802BF31: mov ebp, esp */
   2560     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   2561     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2562     esp = esp - 8; /* 0x3802BF33: sub esp, 8 */
   2563     _flag_k = FK_CMP;
   2564     SET_LO16(eax, MEM16(ebp + 0x8)); /* 0x3802BF36: mov ax, word ptr [ebp + 8] */
   2565     /* cmp LO16(eax), 0xFFFFu */ /* 0x3802BF3A: cmp ax, 0xffff */
   2566     _flag_a = (uint32_t)(LO16(eax)) << 16; _flag_b = (uint32_t)(0xFFFFu) << 16;
   2567     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2568     _flag_k = FK_NARROW(FK_CMP, 16);
   2569     PUSH32(esp, ebx); /* 0x3802BF3E: push ebx */
   2570     PUSH32(esp, esi); /* 0x3802BF3F: push esi */
   2571     PUSH32(esp, edi); /* 0x3802BF40: push edi */
   2572     edi = ecx; /* 0x3802BF41: mov edi, ecx */
   2573     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BFC1; /* 0x3802BF43: je 0x3802bfc1 */
   2574 L_3802BF45:
   2575     SET_LO16(ebx, MEM16(ebp + 0xC)); /* 0x3802BF45: mov bx, word ptr [ebp + 0xc] */
   2576     /* cmp LO16(ebx), 0xFFFFFFFFu */ /* 0x3802BF49: cmp bx, -1 */
   2577     _flag_a = (uint32_t)(LO16(ebx)) << 16; _flag_b = (uint32_t)(0xFFFFFFFFu) << 16;
   2578     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2579     _flag_k = FK_NARROW(FK_CMP, 16);
   2580     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BFC1; /* 0x3802BF4D: je 0x3802bfc1 */
   2581 L_3802BF4F:
   2582     esi = MEM32(edi + 0x48); /* 0x3802BF4F: mov esi, dword ptr [edi + 0x48] */
   2583     ecx = ebp + 0x8; /* 0x3802BF52: lea ecx, [ebp + 8] */
   2584     eax = (int32_t)(int16_t)LO16(eax); /* 0x3802BF55: movsx eax, ax */
   2585     PUSH32(esp, ecx); /* 0x3802BF58: push ecx */
   2586     edx = ebp + (-0x8); /* 0x3802BF59: lea edx, [ebp - 8] */
   2587     PUSH32(esp, edx); /* 0x3802BF5C: push edx */
   2588     ecx = esi; /* 0x3802BF5D: mov ecx, esi */
   2589     MEM32(ebp + 0x8) = eax; /* 0x3802BF5F: mov dword ptr [ebp + 8], eax */
   2590     RECOMP_ICALL(0x3800FD90u); /* 0x3802BF62: call 0x3800fd90 */ /* not lifted */
   2591     RECOMP_FLAGS_IN();
   2592     eax = MEM32(eax); /* 0x3802BF67: mov eax, dword ptr [eax] */
   2593     esi = MEM32(esi + 0x4); /* 0x3802BF69: mov esi, dword ptr [esi + 4] */
   2594     /* cmp eax, esi */ /* 0x3802BF6C: cmp eax, esi */
   2595     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   2596     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2597     _flag_k = FK_CMP;
   2598     MEM32(ebp + 0xC) = eax; /* 0x3802BF6E: mov dword ptr [ebp + 0xc], eax */
   2599     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BF80; /* 0x3802BF71: je 0x3802bf80 */
   2600 L_3802BF73:
   2601     ecx = MEM32(ebp + 0x8); /* 0x3802BF73: mov ecx, dword ptr [ebp + 8] */
   2602     /* cmp ecx, MEM32(eax + 0xC) */ /* 0x3802BF76: cmp ecx, dword ptr [eax + 0xc] */
   2603     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax + 0xC));
   2604     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2605     _flag_k = FK_CMP;
   2606     if (CMP_L(_flag_a, _flag_b)) goto L_3802BF80; /* 0x3802BF79: jl 0x3802bf80 */
   2607 L_3802BF7B:
   2608     eax = ebp + 0xC; /* 0x3802BF7B: lea eax, [ebp + 0xc] */
   2609     goto L_3802BF86; /* 0x3802BF7E: jmp 0x3802bf86 */
   2610 L_3802BF80:
   2611     MEM32(ebp + (-0x4)) = esi; /* 0x3802BF80: mov dword ptr [ebp - 4], esi */
   2612     eax = ebp + (-0x4); /* 0x3802BF83: lea eax, [ebp - 4] */
   2613 L_3802BF86:
   2614     edx = MEM32(edi + 0x48); /* 0x3802BF86: mov edx, dword ptr [edi + 0x48] */
   2615     eax = MEM32(eax); /* 0x3802BF89: mov eax, dword ptr [eax] */
   2616     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3802BF8B: cmp eax, dword ptr [edx + 4] */
   2617     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   2618     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2619     _flag_k = FK_CMP;
   2620     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BFC1; /* 0x3802BF8E: je 0x3802bfc1 */
   2621 L_3802BF90:
   2622     esi = MEM32(eax + 0x10); /* 0x3802BF90: mov esi, dword ptr [eax + 0x10] */
   2623     ecx = MEM32(esi + 0x4); /* 0x3802BF93: mov ecx, dword ptr [esi + 4] */
   2624     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   2625     eax = 0; /* 0x3802BF96: xor eax, eax */
   2626     _cf = 0;
   2627     _flag_k = FK_TEST;
   2628     edx = ecx; /* 0x3802BF98: mov edx, ecx */
   2629 L_3802BF9A:
   2630     /* test ecx, ecx */ /* 0x3802BF9A: test ecx, ecx */
   2631     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   2632     _cf = 0;
   2633     _flag_k = FK_TEST;
   2634     if (TEST_Z(_flag_a, _flag_b)) goto L_3802BFC1; /* 0x3802BF9C: je 0x3802bfc1 */
   2635 L_3802BF9E:
   2636     edi = MEM32(esi + 0x8); /* 0x3802BF9E: mov edi, dword ptr [esi + 8] */
   2637     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx);
   2638     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2639     edi = edi - ecx; /* 0x3802BFA1: sub edi, ecx */
   2640     _flag_k = FK_CMP;
   2641     if (4u) _cf = (((edi) >> 3) & 1u); /* 0x3802BFA3: sar edi, 4 */
   2642     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edi >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   2643     edi = (uint32_t)((int32_t)edi >> 4u);
   2644     /* cmp eax, edi */ /* 0x3802BFA6: cmp eax, edi */
   2645     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   2646     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2647     _flag_k = FK_CMP;
   2648     if (CMP_AE(_flag_a, _flag_b)) goto L_3802BFC1; /* 0x3802BFA8: jae 0x3802bfc1 */
   2649 L_3802BFAA:
   2650     edi = (int32_t)(int16_t)LO16(ebx); /* 0x3802BFAA: movsx edi, bx */
   2651     /* cmp MEM32(edx), edi */ /* 0x3802BFAD: cmp dword ptr [edx], edi */
   2652     _flag_a = (uint32_t)(MEM32(edx)); _flag_b = (uint32_t)(edi);
   2653     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2654     _flag_k = FK_CMP;
   2655     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802BFB7; /* 0x3802BFAF: je 0x3802bfb7 */
   2656 L_3802BFB1:
   2657     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   2658     eax = eax + 1; /* 0x3802BFB1: inc eax */
   2659     _flag_k = FK_INC;
   2660     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u);
   2661     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2662     edx = edx + 0x10u; /* 0x3802BFB2: add edx, 0x10 */
   2663     _flag_k = FK_ADD;
   2664     RECOMP_BACKEDGE();
   2665     goto L_3802BF9A; /* 0x3802BFB5: jmp 0x3802bf9a */
   2666 L_3802BFB7:
   2667     SET_LO8(edx, MEM8(ebp + 0x10)); /* 0x3802BFB7: mov dl, byte ptr [ebp + 0x10] */
   2668     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802BFBA: shl eax, 4 */
   2669     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   2670     eax = eax << 4u; /* 0x3802BFBA: shl eax, 4 */
   2671     MEM8(eax + ecx + 0x4) = (uint8_t)(LO8(edx)); /* 0x3802BFBD: mov byte ptr [eax + ecx + 4], dl */
   2672 L_3802BFC1:
   2673     edi = POP32_VAL(esp); /* 0x3802BFC1: pop edi */
   2674     esi = POP32_VAL(esp); /* 0x3802BFC2: pop esi */
   2675     ebx = POP32_VAL(esp); /* 0x3802BFC3: pop ebx */
   2676     esp = ebp; /* 0x3802BFC4: mov esp, ebp */
   2677     ebp = POP32_VAL(esp); /* 0x3802BFC6: pop ebp */
   2678     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802BFC7: ret 0xc */
   2679     RECOMP_REGS_OUT();
   2680 }
   2681 
   2682 void sub_3802BFD0(void) {
   2683     int _fpu_cmp = 0;
   2684     uint32_t _cf = 0;
   2685     int _df = 1;
   2686     uint32_t _flag_k = FK_NONE;
   2687     uint32_t _flag_a = 0, _flag_b = 0;
   2688     uint32_t _itail_tgt = 0;
   2689     RECOMP_REGS_LOCALS
   2690     RECOMP_ENTER(0x3802BFD0u);
   2691 
   2692 L_3802BFD0:
   2693     PUSH32(esp, ebp); /* 0x3802BFD0: push ebp */
   2694     ebp = esp; /* 0x3802BFD1: mov ebp, esp */
   2695     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   2696     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2697     esp = esp - 8; /* 0x3802BFD3: sub esp, 8 */
   2698     _flag_k = FK_CMP;
   2699     eax = MEM32(ebp + 0x8); /* 0x3802BFD6: mov eax, dword ptr [ebp + 8] */
   2700     /* cmp LO16(eax), 0xFFFFu */ /* 0x3802BFD9: cmp ax, 0xffff */
   2701     _flag_a = (uint32_t)(LO16(eax)) << 16; _flag_b = (uint32_t)(0xFFFFu) << 16;
   2702     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2703     _flag_k = FK_NARROW(FK_CMP, 16);
   2704     PUSH32(esp, ebx); /* 0x3802BFDD: push ebx */
   2705     PUSH32(esp, esi); /* 0x3802BFDE: push esi */
   2706     PUSH32(esp, edi); /* 0x3802BFDF: push edi */
   2707     edi = ecx; /* 0x3802BFE0: mov edi, ecx */
   2708     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C082; /* 0x3802BFE2: je 0x3802c082 */
   2709 L_3802BFE8:
   2710     ebx = MEM32(ebp + 0xC); /* 0x3802BFE8: mov ebx, dword ptr [ebp + 0xc] */
   2711     /* cmp LO16(ebx), 0xFFFFFFFFu */ /* 0x3802BFEB: cmp bx, -1 */
   2712     _flag_a = (uint32_t)(LO16(ebx)) << 16; _flag_b = (uint32_t)(0xFFFFFFFFu) << 16;
   2713     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2714     _flag_k = FK_NARROW(FK_CMP, 16);
   2715     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C082; /* 0x3802BFEF: je 0x3802c082 */
   2716 L_3802BFF5:
   2717     /* cmp LO16(eax), LO16(ebx) */ /* 0x3802BFF5: cmp ax, bx */
   2718     _flag_a = (uint32_t)(LO16(eax)) << 16; _flag_b = (uint32_t)(LO16(ebx)) << 16;
   2719     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2720     _flag_k = FK_NARROW(FK_CMP, 16);
   2721     if (CMP_LE(_flag_a, _flag_b)) goto L_3802C000; /* 0x3802BFF8: jle 0x3802c000 */
   2722 L_3802BFFA:
   2723     ecx = eax; /* 0x3802BFFA: mov ecx, eax */
   2724     eax = ebx; /* 0x3802BFFC: mov eax, ebx */
   2725     ebx = ecx; /* 0x3802BFFE: mov ebx, ecx */
   2726 L_3802C000:
   2727     esi = MEM32(edi + 0x48); /* 0x3802C000: mov esi, dword ptr [edi + 0x48] */
   2728     ecx = ebp + 0x8; /* 0x3802C003: lea ecx, [ebp + 8] */
   2729     eax = (int32_t)(int16_t)LO16(eax); /* 0x3802C006: movsx eax, ax */
   2730     PUSH32(esp, ecx); /* 0x3802C009: push ecx */
   2731     edx = ebp + (-0x8); /* 0x3802C00A: lea edx, [ebp - 8] */
   2732     PUSH32(esp, edx); /* 0x3802C00D: push edx */
   2733     ecx = esi; /* 0x3802C00E: mov ecx, esi */
   2734     MEM32(ebp + 0x8) = eax; /* 0x3802C010: mov dword ptr [ebp + 8], eax */
   2735     RECOMP_ICALL(0x3800FD90u); /* 0x3802C013: call 0x3800fd90 */ /* not lifted */
   2736     RECOMP_FLAGS_IN();
   2737     eax = MEM32(eax); /* 0x3802C018: mov eax, dword ptr [eax] */
   2738     esi = MEM32(esi + 0x4); /* 0x3802C01A: mov esi, dword ptr [esi + 4] */
   2739     /* cmp eax, esi */ /* 0x3802C01D: cmp eax, esi */
   2740     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   2741     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2742     _flag_k = FK_CMP;
   2743     MEM32(ebp + 0xC) = eax; /* 0x3802C01F: mov dword ptr [ebp + 0xc], eax */
   2744     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C031; /* 0x3802C022: je 0x3802c031 */
   2745 L_3802C024:
   2746     ecx = MEM32(ebp + 0x8); /* 0x3802C024: mov ecx, dword ptr [ebp + 8] */
   2747     /* cmp ecx, MEM32(eax + 0xC) */ /* 0x3802C027: cmp ecx, dword ptr [eax + 0xc] */
   2748     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax + 0xC));
   2749     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2750     _flag_k = FK_CMP;
   2751     if (CMP_L(_flag_a, _flag_b)) goto L_3802C031; /* 0x3802C02A: jl 0x3802c031 */
   2752 L_3802C02C:
   2753     eax = ebp + 0xC; /* 0x3802C02C: lea eax, [ebp + 0xc] */
   2754     goto L_3802C037; /* 0x3802C02F: jmp 0x3802c037 */
   2755 L_3802C031:
   2756     MEM32(ebp + (-0x4)) = esi; /* 0x3802C031: mov dword ptr [ebp - 4], esi */
   2757     eax = ebp + (-0x4); /* 0x3802C034: lea eax, [ebp - 4] */
   2758 L_3802C037:
   2759     edx = MEM32(edi + 0x48); /* 0x3802C037: mov edx, dword ptr [edi + 0x48] */
   2760     eax = MEM32(eax); /* 0x3802C03A: mov eax, dword ptr [eax] */
   2761     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3802C03C: cmp eax, dword ptr [edx + 4] */
   2762     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   2763     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2764     _flag_k = FK_CMP;
   2765     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C082; /* 0x3802C03F: je 0x3802c082 */
   2766 L_3802C041:
   2767     esi = MEM32(eax + 0x10); /* 0x3802C041: mov esi, dword ptr [eax + 0x10] */
   2768     ecx = MEM32(esi + 0x4); /* 0x3802C044: mov ecx, dword ptr [esi + 4] */
   2769     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   2770     eax = 0; /* 0x3802C047: xor eax, eax */
   2771     _cf = 0;
   2772     _flag_k = FK_TEST;
   2773     edx = ecx; /* 0x3802C049: mov edx, ecx */
   2774 L_3802C04B:
   2775     /* test ecx, ecx */ /* 0x3802C04B: test ecx, ecx */
   2776     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   2777     _cf = 0;
   2778     _flag_k = FK_TEST;
   2779     if (TEST_Z(_flag_a, _flag_b)) goto L_3802C082; /* 0x3802C04D: je 0x3802c082 */
   2780 L_3802C04F:
   2781     edi = MEM32(esi + 0x8); /* 0x3802C04F: mov edi, dword ptr [esi + 8] */
   2782     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx);
   2783     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2784     edi = edi - ecx; /* 0x3802C052: sub edi, ecx */
   2785     _flag_k = FK_CMP;
   2786     if (4u) _cf = (((edi) >> 3) & 1u); /* 0x3802C054: sar edi, 4 */
   2787     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edi >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   2788     edi = (uint32_t)((int32_t)edi >> 4u);
   2789     /* cmp eax, edi */ /* 0x3802C057: cmp eax, edi */
   2790     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   2791     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2792     _flag_k = FK_CMP;
   2793     if (CMP_AE(_flag_a, _flag_b)) goto L_3802C082; /* 0x3802C059: jae 0x3802c082 */
   2794 L_3802C05B:
   2795     edi = (int32_t)(int16_t)LO16(ebx); /* 0x3802C05B: movsx edi, bx */
   2796     /* cmp MEM32(edx), edi */ /* 0x3802C05E: cmp dword ptr [edx], edi */
   2797     _flag_a = (uint32_t)(MEM32(edx)); _flag_b = (uint32_t)(edi);
   2798     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2799     _flag_k = FK_CMP;
   2800     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C068; /* 0x3802C060: je 0x3802c068 */
   2801 L_3802C062:
   2802     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   2803     eax = eax + 1; /* 0x3802C062: inc eax */
   2804     _flag_k = FK_INC;
   2805     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u);
   2806     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2807     edx = edx + 0x10u; /* 0x3802C063: add edx, 0x10 */
   2808     _flag_k = FK_ADD;
   2809     RECOMP_BACKEDGE();
   2810     goto L_3802C04B; /* 0x3802C066: jmp 0x3802c04b */
   2811 L_3802C068:
   2812     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802C068: shl eax, 4 */
   2813     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   2814     eax = eax << 4u; /* 0x3802C068: shl eax, 4 */
   2815     SET_LO8(ebx, MEM8(eax + ecx + 0x4)); /* 0x3802C06B: mov bl, byte ptr [eax + ecx + 4] */
   2816     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   2817     edx = 0; /* 0x3802C06F: xor edx, edx */
   2818     _cf = 0;
   2819     _flag_k = FK_TEST;
   2820     /* cmp LO8(ebx), 1 */ /* 0x3802C071: cmp bl, 1 */
   2821     _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(1) << 24;
   2822     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2823     _flag_k = FK_NARROW(FK_CMP, 24);
   2824     edi = POP32_VAL(esp); /* 0x3802C074: pop edi */
   2825     SET_LO8(edx, (CMP_EQ(_flag_a, _flag_b)) ? 1 : 0); /* 0x3802C075: sete dl */
   2826     esi = POP32_VAL(esp); /* 0x3802C078: pop esi */
   2827     SET_LO8(eax, LO8(edx)); /* 0x3802C079: mov al, dl */
   2828     ebx = POP32_VAL(esp); /* 0x3802C07B: pop ebx */
   2829     esp = ebp; /* 0x3802C07C: mov esp, ebp */
   2830     ebp = POP32_VAL(esp); /* 0x3802C07E: pop ebp */
   2831     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802C07F: ret 8 */
   2832 L_3802C082:
   2833     edi = POP32_VAL(esp); /* 0x3802C082: pop edi */
   2834     esi = POP32_VAL(esp); /* 0x3802C083: pop esi */
   2835     _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24;
   2836     SET_LO8(eax, 0); /* 0x3802C084: xor al, al */
   2837     _cf = 0;
   2838     _flag_k = FK_NARROW(FK_TEST, 24);
   2839     ebx = POP32_VAL(esp); /* 0x3802C086: pop ebx */
   2840     esp = ebp; /* 0x3802C087: mov esp, ebp */
   2841     ebp = POP32_VAL(esp); /* 0x3802C089: pop ebp */
   2842     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802C08A: ret 8 */
   2843     RECOMP_REGS_OUT();
   2844 }
   2845 
   2846 void sub_3802C090(void) {
   2847     int _fpu_cmp = 0;
   2848     uint32_t _cf = 0;
   2849     int _df = 1;
   2850     uint32_t _flag_k = FK_NONE;
   2851     uint32_t _flag_a = 0, _flag_b = 0;
   2852     uint32_t _itail_tgt = 0;
   2853     RECOMP_REGS_LOCALS
   2854     RECOMP_ENTER(0x3802C090u);
   2855 
   2856 L_3802C090:
   2857     PUSH32(esp, ebp); /* 0x3802C090: push ebp */
   2858     ebp = esp; /* 0x3802C091: mov ebp, esp */
   2859     SET_LO8(eax, MEM8(0x3806EE5C)); /* 0x3802C093: mov al, byte ptr [0x3806ee5c] */
   2860     /* test LO8(eax), 1 */ /* 0x3802C098: test al, 1 */
   2861     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   2862     _cf = 0;
   2863     _flag_k = FK_NARROW(FK_TEST, 24);
   2864     PUSH32(esp, ebx); /* 0x3802C09A: push ebx */
   2865     PUSH32(esp, esi); /* 0x3802C09B: push esi */
   2866     PUSH32(esp, edi); /* 0x3802C09C: push edi */
   2867     esi = ecx; /* 0x3802C09D: mov esi, ecx */
   2868     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802C0D7; /* 0x3802C09F: jne 0x3802c0d7 */
   2869 L_3802C0A1:
   2870     SET_LO8(edx, LO8(eax)); /* 0x3802C0A1: mov dl, al */
   2871     _flag_a = (uint32_t)((LO8(edx) | 1)) << 24; _flag_b = (uint32_t)((LO8(edx) | 1)) << 24;
   2872     SET_LO8(edx, LO8(edx) | 1); /* 0x3802C0A3: or dl, 1 */
   2873     _cf = 0;
   2874     _flag_k = FK_NARROW(FK_TEST, 24);
   2875     PUSH32(esp, 0x3802C160u); /* 0x3802C0A6: push 0x3802c160 */
   2876     MEM8(0x3806EE5C) = (uint8_t)(LO8(edx)); /* 0x3802C0AB: mov byte ptr [0x3806ee5c], dl */
   2877     MEM32(0x3806EDB8) = 0; /* 0x3802C0B1: mov dword ptr [0x3806edb8], 0 */
   2878     MEM32(0x3806EDBC) = 0; /* 0x3802C0BB: mov dword ptr [0x3806edbc], 0 */
   2879     MEM32(0x3806EDC0) = 0; /* 0x3802C0C5: mov dword ptr [0x3806edc0], 0 */
   2880     RECOMP_ICALL(0x3804B54Cu); /* 0x3802C0CF: call 0x3804b54c */ /* not lifted */
   2881     RECOMP_FLAGS_IN();
   2882     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   2883     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2884     esp = esp + 4; /* 0x3802C0D4: add esp, 4 */
   2885     _flag_k = FK_ADD;
   2886 L_3802C0D7:
   2887     eax = MEM32(ebp + 0x10); /* 0x3802C0D7: mov eax, dword ptr [ebp + 0x10] */
   2888     edi = MEM32(ebp + 0xC); /* 0x3802C0DA: mov edi, dword ptr [ebp + 0xc] */
   2889     ebx = MEM32(ebp + 0x8); /* 0x3802C0DD: mov ebx, dword ptr [ebp + 8] */
   2890     PUSH32(esp, eax); /* 0x3802C0E0: push eax */
   2891     PUSH32(esp, edi); /* 0x3802C0E1: push edi */
   2892     PUSH32(esp, ebx); /* 0x3802C0E2: push ebx */
   2893     ecx = esi; /* 0x3802C0E3: mov ecx, esi */
   2894     RECOMP_ICALL(0x3802C170u); /* 0x3802C0E5: call 0x3802c170 */ /* not lifted */
   2895     RECOMP_FLAGS_IN();
   2896     /* test LO8(eax), LO8(eax) */ /* 0x3802C0EA: test al, al */
   2897     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   2898     _cf = 0;
   2899     _flag_k = FK_NARROW(FK_TEST, 24);
   2900     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802C0F5; /* 0x3802C0EC: jne 0x3802c0f5 */
   2901 L_3802C0EE:
   2902     edi = POP32_VAL(esp); /* 0x3802C0EE: pop edi */
   2903     esi = POP32_VAL(esp); /* 0x3802C0EF: pop esi */
   2904     ebx = POP32_VAL(esp); /* 0x3802C0F0: pop ebx */
   2905     ebp = POP32_VAL(esp); /* 0x3802C0F1: pop ebp */
   2906     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802C0F2: ret 0xc */
   2907 L_3802C0F5:
   2908     ecx = esi; /* 0x3802C0F5: mov ecx, esi */
   2909     RECOMP_ICALL(0x3802BF20u); /* 0x3802C0F7: call 0x3802bf20 */ /* not lifted */
   2910     RECOMP_FLAGS_IN();
   2911     /* test eax, eax */ /* 0x3802C0FC: test eax, eax */
   2912     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   2913     _cf = 0;
   2914     _flag_k = FK_TEST;
   2915     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802C109; /* 0x3802C0FE: jne 0x3802c109 */
   2916 L_3802C100:
   2917     edi = POP32_VAL(esp); /* 0x3802C100: pop edi */
   2918     esi = POP32_VAL(esp); /* 0x3802C101: pop esi */
   2919     _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24;
   2920     SET_LO8(eax, 0); /* 0x3802C102: xor al, al */
   2921     _cf = 0;
   2922     _flag_k = FK_NARROW(FK_TEST, 24);
   2923     ebx = POP32_VAL(esp); /* 0x3802C104: pop ebx */
   2924     ebp = POP32_VAL(esp); /* 0x3802C105: pop ebp */
   2925     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802C106: ret 0xc */
   2926 L_3802C109:
   2927     ecx = esi; /* 0x3802C109: mov ecx, esi */
   2928     RECOMP_ICALL(0x3802BF20u); /* 0x3802C10B: call 0x3802bf20 */ /* not lifted */
   2929     RECOMP_FLAGS_IN();
   2930     edx = MEM32(eax); /* 0x3802C110: mov edx, dword ptr [eax] */
   2931     PUSH32(esp, 0); /* 0x3802C112: push 0 */
   2932     PUSH32(esp, 1); /* 0x3802C114: push 1 */
   2933     PUSH32(esp, 0x3806EDB8u); /* 0x3802C116: push 0x3806edb8 */
   2934     PUSH32(esp, edi); /* 0x3802C11B: push edi */
   2935     PUSH32(esp, ebx); /* 0x3802C11C: push ebx */
   2936     ecx = eax; /* 0x3802C11D: mov ecx, eax */
   2937     RECOMP_ICALL(MEM32(edx + 0xC)); /* 0x3802C11F: call dword ptr [edx + 0xc] */
   2938     RECOMP_FLAGS_IN();
   2939     /* test LO8(eax), LO8(eax) */ /* 0x3802C122: test al, al */
   2940     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   2941     _cf = 0;
   2942     _flag_k = FK_NARROW(FK_TEST, 24);
   2943     if (TEST_Z(_flag_a, _flag_b)) goto L_3802C12F; /* 0x3802C124: je 0x3802c12f */
   2944 L_3802C126:
   2945     edi = POP32_VAL(esp); /* 0x3802C126: pop edi */
   2946     esi = POP32_VAL(esp); /* 0x3802C127: pop esi */
   2947     _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24;
   2948     SET_LO8(eax, 0); /* 0x3802C128: xor al, al */
   2949     _cf = 0;
   2950     _flag_k = FK_NARROW(FK_TEST, 24);
   2951     ebx = POP32_VAL(esp); /* 0x3802C12A: pop ebx */
   2952     ebp = POP32_VAL(esp); /* 0x3802C12B: pop ebp */
   2953     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802C12C: ret 0xc */
   2954 L_3802C12F:
   2955     ecx = esi; /* 0x3802C12F: mov ecx, esi */
   2956     RECOMP_ICALL(0x3802BF20u); /* 0x3802C131: call 0x3802bf20 */ /* not lifted */
   2957     RECOMP_FLAGS_IN();
   2958     edx = MEM32(eax); /* 0x3802C136: mov edx, dword ptr [eax] */
   2959     PUSH32(esp, 0); /* 0x3802C138: push 0 */
   2960     PUSH32(esp, 1); /* 0x3802C13A: push 1 */
   2961     PUSH32(esp, 0x3806EDB8u); /* 0x3802C13C: push 0x3806edb8 */
   2962     PUSH32(esp, ebx); /* 0x3802C141: push ebx */
   2963     PUSH32(esp, edi); /* 0x3802C142: push edi */
   2964     ecx = eax; /* 0x3802C143: mov ecx, eax */
   2965     RECOMP_ICALL(MEM32(edx + 0xC)); /* 0x3802C145: call dword ptr [edx + 0xc] */
   2966     RECOMP_FLAGS_IN();
   2967     _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   2968     _cf = (LO8(eax)) != 0;
   2969     SET_LO8(eax, (uint32_t)(-(int32_t)LO8(eax))); /* 0x3802C148: neg al */
   2970     _flag_k = FK_NARROW(FK_CMP, 24);
   2971     edi = POP32_VAL(esp); /* 0x3802C14A: pop edi */
   2972     { uint32_t _sa = LO8(eax), _sb = LO8(eax), _sc = _cf; /* 0x3802C14B: sbb al, al */
   2973       SET_LO8(eax, _sc ? 0xFFFFFFFFu : 0);
   2974       _flag_a = recomp_flags_sbb(_sa, _sb, _sc); _flag_b = 0;
   2975       _flag_k = FK_EFLAGS; _cf = _flag_a & 1u; }
   2976     esi = POP32_VAL(esp); /* 0x3802C14D: pop esi */
   2977     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   2978     SET_LO8(eax, LO8(eax) + 1); /* 0x3802C14E: inc al */
   2979     _flag_k = FK_NARROW(FK_INC, 24);
   2980     ebx = POP32_VAL(esp); /* 0x3802C150: pop ebx */
   2981     ebp = POP32_VAL(esp); /* 0x3802C151: pop ebp */
   2982     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802C152: ret 0xc */
   2983     RECOMP_REGS_OUT();
   2984 }
   2985 
   2986 void sub_3802C160(void) {
   2987     int _fpu_cmp = 0;
   2988     uint32_t _cf = 0;
   2989     int _df = 1;
   2990     uint32_t _flag_k = FK_NONE;
   2991     uint32_t _flag_a = 0, _flag_b = 0;
   2992     uint32_t _itail_tgt = 0;
   2993     RECOMP_REGS_LOCALS
   2994     RECOMP_ENTER(0x3802C160u);
   2995 
   2996 L_3802C160:
   2997     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802C160: ret  */
   2998     RECOMP_REGS_OUT();
   2999 }
   3000 
   3001 void sub_3802C170(void) {
   3002     int _fpu_cmp = 0;
   3003     uint32_t _cf = 0;
   3004     int _df = 1;
   3005     uint32_t _flag_k = FK_NONE;
   3006     uint32_t _flag_a = 0, _flag_b = 0;
   3007     uint32_t _itail_tgt = 0;
   3008     RECOMP_REGS_LOCALS
   3009     RECOMP_ENTER(0x3802C170u);
   3010 
   3011 L_3802C170:
   3012     PUSH32(esp, ebp); /* 0x3802C170: push ebp */
   3013     ebp = esp; /* 0x3802C171: mov ebp, esp */
   3014     PUSH32(esp, esi); /* 0x3802C173: push esi */
   3015     PUSH32(esp, edi); /* 0x3802C174: push edi */
   3016     edi = ecx; /* 0x3802C175: mov edi, ecx */
   3017     RECOMP_ICALL(0x3802D200u); /* 0x3802C177: call 0x3802d200 */ /* not lifted */
   3018     RECOMP_FLAGS_IN();
   3019     /* test LO8(eax), LO8(eax) */ /* 0x3802C17C: test al, al */
   3020     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   3021     _cf = 0;
   3022     _flag_k = FK_NARROW(FK_TEST, 24);
   3023     if (TEST_Z(_flag_a, _flag_b)) goto L_3802C1C9; /* 0x3802C17E: je 0x3802c1c9 */
   3024 L_3802C180:
   3025     eax = MEM32(ebp + 0x10); /* 0x3802C180: mov eax, dword ptr [ebp + 0x10] */
   3026     ecx = MEM32(ebp + 0x8); /* 0x3802C183: mov ecx, dword ptr [ebp + 8] */
   3027     PUSH32(esp, eax); /* 0x3802C186: push eax */
   3028     PUSH32(esp, ecx); /* 0x3802C187: push ecx */
   3029     ecx = edi; /* 0x3802C188: mov ecx, edi */
   3030     RECOMP_ICALL(0x3802B820u); /* 0x3802C18A: call 0x3802b820 */ /* not lifted */
   3031     RECOMP_FLAGS_IN();
   3032     /* test eax, eax */ /* 0x3802C18F: test eax, eax */
   3033     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   3034     _cf = 0;
   3035     _flag_k = FK_TEST;
   3036     if (TEST_Z(_flag_a, _flag_b)) goto L_3802C1C1; /* 0x3802C191: je 0x3802c1c1 */
   3037 L_3802C193:
   3038     esi = MEM32(eax + 0xC); /* 0x3802C193: mov esi, dword ptr [eax + 0xc] */
   3039     edx = MEM32(ebp + 0xC); /* 0x3802C196: mov edx, dword ptr [ebp + 0xc] */
   3040     PUSH32(esp, esi); /* 0x3802C199: push esi */
   3041     PUSH32(esp, edx); /* 0x3802C19A: push edx */
   3042     ecx = edi; /* 0x3802C19B: mov ecx, edi */
   3043     RECOMP_ICALL(0x3802B820u); /* 0x3802C19D: call 0x3802b820 */ /* not lifted */
   3044     RECOMP_FLAGS_IN();
   3045     /* test eax, eax */ /* 0x3802C1A2: test eax, eax */
   3046     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   3047     _cf = 0;
   3048     _flag_k = FK_TEST;
   3049     if (TEST_Z(_flag_a, _flag_b)) goto L_3802C1C1; /* 0x3802C1A4: je 0x3802c1c1 */
   3050 L_3802C1A6:
   3051     eax = MEM32(eax + 0xC); /* 0x3802C1A6: mov eax, dword ptr [eax + 0xc] */
   3052     /* cmp eax, esi */ /* 0x3802C1A9: cmp eax, esi */
   3053     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   3054     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3055     _flag_k = FK_CMP;
   3056     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C1C9; /* 0x3802C1AB: je 0x3802c1c9 */
   3057 L_3802C1AD:
   3058     PUSH32(esp, eax); /* 0x3802C1AD: push eax */
   3059     PUSH32(esp, esi); /* 0x3802C1AE: push esi */
   3060     ecx = edi; /* 0x3802C1AF: mov ecx, edi */
   3061     RECOMP_ICALL(0x3802BFD0u); /* 0x3802C1B1: call 0x3802bfd0 */ /* not lifted */
   3062     RECOMP_FLAGS_IN();
   3063     /* test LO8(eax), LO8(eax) */ /* 0x3802C1B6: test al, al */
   3064     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   3065     _cf = 0;
   3066     _flag_k = FK_NARROW(FK_TEST, 24);
   3067     edi = POP32_VAL(esp); /* 0x3802C1B8: pop edi */
   3068     SET_LO8(eax, (TEST_NZ(_flag_a, _flag_b)) ? 1 : 0); /* 0x3802C1B9: setne al */
   3069     esi = POP32_VAL(esp); /* 0x3802C1BC: pop esi */
   3070     ebp = POP32_VAL(esp); /* 0x3802C1BD: pop ebp */
   3071     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802C1BE: ret 0xc */
   3072 L_3802C1C1:
   3073     edi = POP32_VAL(esp); /* 0x3802C1C1: pop edi */
   3074     _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24;
   3075     SET_LO8(eax, 0); /* 0x3802C1C2: xor al, al */
   3076     _cf = 0;
   3077     _flag_k = FK_NARROW(FK_TEST, 24);
   3078     esi = POP32_VAL(esp); /* 0x3802C1C4: pop esi */
   3079     ebp = POP32_VAL(esp); /* 0x3802C1C5: pop ebp */
   3080     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802C1C6: ret 0xc */
   3081 L_3802C1C9:
   3082     edi = POP32_VAL(esp); /* 0x3802C1C9: pop edi */
   3083     SET_LO8(eax, 1); /* 0x3802C1CA: mov al, 1 */
   3084     esi = POP32_VAL(esp); /* 0x3802C1CC: pop esi */
   3085     ebp = POP32_VAL(esp); /* 0x3802C1CD: pop ebp */
   3086     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802C1CE: ret 0xc */
   3087     RECOMP_REGS_OUT();
   3088 }
   3089 
   3090 void sub_3802C1E0(void) {
   3091     int _fpu_cmp = 0;
   3092     uint32_t _cf = 0;
   3093     int _df = 1;
   3094     uint32_t _flag_k = FK_NONE;
   3095     uint32_t _flag_a = 0, _flag_b = 0;
   3096     uint32_t _itail_tgt = 0;
   3097     RECOMP_REGS_LOCALS
   3098     RECOMP_ENTER(0x3802C1E0u);
   3099 
   3100 L_3802C1E0:
   3101     PUSH32(esp, ebp); /* 0x3802C1E0: push ebp */
   3102     ebp = esp; /* 0x3802C1E1: mov ebp, esp */
   3103     edx = MEM32(ebp + 0x8); /* 0x3802C1E3: mov edx, dword ptr [ebp + 8] */
   3104     eax = edx; /* 0x3802C1E6: mov eax, edx */
   3105     if (16u) _cf = (((eax) >> 15) & 1u); /* 0x3802C1E8: shr eax, 0x10 */
   3106     if (16u) { _flag_a = recomp_flags_pack((eax >> 16u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   3107     eax = eax >> 16u; /* 0x3802C1E8: shr eax, 0x10 */
   3108     /* cmp LO16(edx), LO16(eax) */ /* 0x3802C1EB: cmp dx, ax */
   3109     _flag_a = (uint32_t)(LO16(edx)) << 16; _flag_b = (uint32_t)(LO16(eax)) << 16;
   3110     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3111     _flag_k = FK_NARROW(FK_CMP, 16);
   3112     PUSH32(esp, esi); /* 0x3802C1EE: push esi */
   3113     esi = edx; /* 0x3802C1EF: mov esi, edx */
   3114     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C202; /* 0x3802C1F1: je 0x3802c202 */
   3115 L_3802C1F3:
   3116     if (CMP_LE(_flag_a, _flag_b)) goto L_3802C1F9; /* 0x3802C1F3: jle 0x3802c1f9 */
   3117 L_3802C1F5:
   3118     esi = eax; /* 0x3802C1F5: mov esi, eax */
   3119     eax = edx; /* 0x3802C1F7: mov eax, edx */
   3120 L_3802C1F9:
   3121     PUSH32(esp, 1); /* 0x3802C1F9: push 1 */
   3122     PUSH32(esp, eax); /* 0x3802C1FB: push eax */
   3123     PUSH32(esp, esi); /* 0x3802C1FC: push esi */
   3124     RECOMP_ICALL(0x3802BF30u); /* 0x3802C1FD: call 0x3802bf30 */ /* not lifted */
   3125     RECOMP_FLAGS_IN();
   3126 L_3802C202:
   3127     esi = POP32_VAL(esp); /* 0x3802C202: pop esi */
   3128     ebp = POP32_VAL(esp); /* 0x3802C203: pop ebp */
   3129     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802C204: ret 4 */
   3130     RECOMP_REGS_OUT();
   3131 }
   3132 
   3133 void sub_3802C210(void) {
   3134     int _fpu_cmp = 0;
   3135     uint32_t _cf = 0;
   3136     int _df = 1;
   3137     uint32_t _flag_k = FK_NONE;
   3138     uint32_t _flag_a = 0, _flag_b = 0;
   3139     uint32_t _itail_tgt = 0;
   3140     RECOMP_REGS_LOCALS
   3141     RECOMP_ENTER(0x3802C210u);
   3142 
   3143 L_3802C210:
   3144     PUSH32(esp, ebp); /* 0x3802C210: push ebp */
   3145     ebp = esp; /* 0x3802C211: mov ebp, esp */
   3146     edx = MEM32(ebp + 0x8); /* 0x3802C213: mov edx, dword ptr [ebp + 8] */
   3147     eax = edx; /* 0x3802C216: mov eax, edx */
   3148     if (16u) _cf = (((eax) >> 15) & 1u); /* 0x3802C218: shr eax, 0x10 */
   3149     if (16u) { _flag_a = recomp_flags_pack((eax >> 16u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   3150     eax = eax >> 16u; /* 0x3802C218: shr eax, 0x10 */
   3151     /* cmp LO16(edx), LO16(eax) */ /* 0x3802C21B: cmp dx, ax */
   3152     _flag_a = (uint32_t)(LO16(edx)) << 16; _flag_b = (uint32_t)(LO16(eax)) << 16;
   3153     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3154     _flag_k = FK_NARROW(FK_CMP, 16);
   3155     PUSH32(esp, esi); /* 0x3802C21E: push esi */
   3156     esi = edx; /* 0x3802C21F: mov esi, edx */
   3157     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C232; /* 0x3802C221: je 0x3802c232 */
   3158 L_3802C223:
   3159     if (CMP_LE(_flag_a, _flag_b)) goto L_3802C229; /* 0x3802C223: jle 0x3802c229 */
   3160 L_3802C225:
   3161     esi = eax; /* 0x3802C225: mov esi, eax */
   3162     eax = edx; /* 0x3802C227: mov eax, edx */
   3163 L_3802C229:
   3164     PUSH32(esp, 0); /* 0x3802C229: push 0 */
   3165     PUSH32(esp, eax); /* 0x3802C22B: push eax */
   3166     PUSH32(esp, esi); /* 0x3802C22C: push esi */
   3167     RECOMP_ICALL(0x3802BF30u); /* 0x3802C22D: call 0x3802bf30 */ /* not lifted */
   3168     RECOMP_FLAGS_IN();
   3169 L_3802C232:
   3170     esi = POP32_VAL(esp); /* 0x3802C232: pop esi */
   3171     ebp = POP32_VAL(esp); /* 0x3802C233: pop ebp */
   3172     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802C234: ret 4 */
   3173     RECOMP_REGS_OUT();
   3174 }
   3175 
   3176 void sub_3802C240(void) {
   3177     int _fpu_cmp = 0;
   3178     uint32_t _cf = 0;
   3179     int _df = 1;
   3180     uint32_t _flag_k = FK_NONE;
   3181     uint32_t _flag_a = 0, _flag_b = 0;
   3182     uint32_t _itail_tgt = 0;
   3183     RECOMP_REGS_LOCALS
   3184     RECOMP_ENTER(0x3802C240u);
   3185 
   3186 L_3802C240:
   3187     PUSH32(esp, ebp); /* 0x3802C240: push ebp */
   3188     ebp = esp; /* 0x3802C241: mov ebp, esp */
   3189     eax = MEM32(ebp + 0xC); /* 0x3802C243: mov eax, dword ptr [ebp + 0xc] */
   3190     ecx = MEM32(eax + 0x4); /* 0x3802C246: mov ecx, dword ptr [eax + 4] */
   3191     eax = MEM32(ecx); /* 0x3802C249: mov eax, dword ptr [ecx] */
   3192     /* cmp eax, ecx */ /* 0x3802C24B: cmp eax, ecx */
   3193     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   3194     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3195     _flag_k = FK_CMP;
   3196     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C25D; /* 0x3802C24D: je 0x3802c25d */
   3197 L_3802C24F:
   3198     edx = MEM32(ebp + 0x8); /* 0x3802C24F: mov edx, dword ptr [ebp + 8] */
   3199 L_3802C252:
   3200     /* cmp edx, MEM32(eax + 0x8) */ /* 0x3802C252: cmp edx, dword ptr [eax + 8] */
   3201     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(eax + 0x8));
   3202     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3203     _flag_k = FK_CMP;
   3204     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C261; /* 0x3802C255: je 0x3802c261 */
   3205 L_3802C257:
   3206     eax = MEM32(eax); /* 0x3802C257: mov eax, dword ptr [eax] */
   3207     /* cmp eax, ecx */ /* 0x3802C259: cmp eax, ecx */
   3208     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   3209     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3210     _flag_k = FK_CMP;
   3211     RECOMP_BACKEDGE();
   3212     if (CMP_NE(_flag_a, _flag_b)) goto L_3802C252; /* 0x3802C25B: jne 0x3802c252 */
   3213 L_3802C25D:
   3214     _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24;
   3215     SET_LO8(eax, 0); /* 0x3802C25D: xor al, al */
   3216     _cf = 0;
   3217     _flag_k = FK_NARROW(FK_TEST, 24);
   3218     ebp = POP32_VAL(esp); /* 0x3802C25F: pop ebp */
   3219     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802C260: ret  */
   3220 L_3802C261:
   3221     SET_LO8(eax, 1); /* 0x3802C261: mov al, 1 */
   3222     ebp = POP32_VAL(esp); /* 0x3802C263: pop ebp */
   3223     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802C264: ret  */
   3224     RECOMP_REGS_OUT();
   3225 }
   3226 
   3227 void sub_3802C270(void) {
   3228     int _fpu_cmp = 0;
   3229     uint32_t _cf = 0;
   3230     int _df = 1;
   3231     uint32_t _flag_k = FK_NONE;
   3232     uint32_t _flag_a = 0, _flag_b = 0;
   3233     uint32_t _itail_tgt = 0;
   3234     RECOMP_REGS_LOCALS
   3235     RECOMP_ENTER(0x3802C270u);
   3236 
   3237 L_3802C270:
   3238     PUSH32(esp, ebp); /* 0x3802C270: push ebp */
   3239     ebp = esp; /* 0x3802C271: mov ebp, esp */
   3240     PUSH32(esp, 0xFFFFFFFFu); /* 0x3802C273: push -1 */
   3241     PUSH32(esp, 0x3804CA94u); /* 0x3802C275: push 0x3804ca94 */
   3242     eax = MEM32(FS_BASE + (0)); /* 0x3802C27A: mov eax, dword ptr fs:[0] */
   3243     PUSH32(esp, eax); /* 0x3802C280: push eax */
   3244     MEM32(FS_BASE + (0)) = esp; /* 0x3802C281: mov dword ptr fs:[0], esp */
   3245     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x25Cu);
   3246     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3247     esp = esp - 0x25Cu; /* 0x3802C288: sub esp, 0x25c */
   3248     _flag_k = FK_CMP;
   3249     PUSH32(esp, ebx); /* 0x3802C28E: push ebx */
   3250     PUSH32(esp, esi); /* 0x3802C28F: push esi */
   3251     esi = ecx; /* 0x3802C290: mov esi, ecx */
   3252     ebx = MEM32(esi + 0x8C); /* 0x3802C292: mov ebx, dword ptr [esi + 0x8c] */
   3253     PUSH32(esp, edi); /* 0x3802C298: push edi */
   3254     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3255     edi = 0; /* 0x3802C299: xor edi, edi */
   3256     _cf = 0;
   3257     _flag_k = FK_TEST;
   3258     /* cmp ebx, edi */ /* 0x3802C29B: cmp ebx, edi */
   3259     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(edi);
   3260     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3261     _flag_k = FK_CMP;
   3262     MEM32(ebp + (-0x78)) = esi; /* 0x3802C29D: mov dword ptr [ebp - 0x78], esi */
   3263     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C2A7; /* 0x3802C2A0: je 0x3802c2a7 */
   3264 L_3802C2A2:
   3265     MEM32(ebp + (-0x74)) = ebx; /* 0x3802C2A2: mov dword ptr [ebp - 0x74], ebx */
   3266     goto L_3802C2E3; /* 0x3802C2A5: jmp 0x3802c2e3 */
   3267 L_3802C2A7:
   3268     eax = MEM32(esi + 0x88); /* 0x3802C2A7: mov eax, dword ptr [esi + 0x88] */
   3269     ecx = MEM32(eax + 0x4); /* 0x3802C2AD: mov ecx, dword ptr [eax + 4] */
   3270     /* cmp ecx, edi */ /* 0x3802C2B0: cmp ecx, edi */
   3271     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
   3272     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3273     _flag_k = FK_CMP;
   3274     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C2C9; /* 0x3802C2B2: je 0x3802c2c9 */
   3275 L_3802C2B4:
   3276     edx = MEM32(eax + 0x8); /* 0x3802C2B4: mov edx, dword ptr [eax + 8] */
   3277     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   3278     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3279     edx = edx - ecx; /* 0x3802C2B7: sub edx, ecx */
   3280     _flag_k = FK_CMP;
   3281     /* test edx, 0xFFFFFFFCu */ /* 0x3802C2B9: test edx, 0xfffffffc */
   3282     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0xFFFFFFFCu);
   3283     _cf = 0;
   3284     _flag_k = FK_TEST;
   3285     if (TEST_Z(_flag_a, _flag_b)) goto L_3802C2C9; /* 0x3802C2BF: je 0x3802c2c9 */
   3286 L_3802C2C1:
   3287     MEM32(esi + 0x8C) = eax; /* 0x3802C2C1: mov dword ptr [esi + 0x8c], eax */
   3288     goto L_3802C2D8; /* 0x3802C2C7: jmp 0x3802c2d8 */
   3289 L_3802C2C9:
   3290     eax = MEM32(esi + 0x98); /* 0x3802C2C9: mov eax, dword ptr [esi + 0x98] */
   3291     ecx = MEM32(eax + 0x44); /* 0x3802C2CF: mov ecx, dword ptr [eax + 0x44] */
   3292     MEM32(esi + 0x8C) = ecx; /* 0x3802C2D2: mov dword ptr [esi + 0x8c], ecx */
   3293 L_3802C2D8:
   3294     edx = MEM32(esi + 0x8C); /* 0x3802C2D8: mov edx, dword ptr [esi + 0x8c] */
   3295     MEM32(ebp + (-0x74)) = edx; /* 0x3802C2DE: mov dword ptr [ebp - 0x74], edx */
   3296     ebx = edx; /* 0x3802C2E1: mov ebx, edx */
   3297 L_3802C2E3:
   3298     eax = MEM32(esi + 0x60); /* 0x3802C2E3: mov eax, dword ptr [esi + 0x60] */
   3299     PUSH32(esp, edi); /* 0x3802C2E6: push edi */
   3300     PUSH32(esp, 0x3806C8D8u); /* 0x3802C2E7: push 0x3806c8d8 */
   3301     PUSH32(esp, 0x3806C8A0u); /* 0x3802C2EC: push 0x3806c8a0 */
   3302     PUSH32(esp, edi); /* 0x3802C2F1: push edi */
   3303     PUSH32(esp, eax); /* 0x3802C2F2: push eax */
   3304     RECOMP_ICALL(0x3804B682u); /* 0x3802C2F3: call 0x3804b682 */ /* not lifted */
   3305     RECOMP_FLAGS_IN();
   3306     SET_LO8(ecx, MEM8(ebp + (-0x2D))); /* 0x3802C2F8: mov cl, byte ptr [ebp - 0x2d] */
   3307     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x14u);
   3308     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   3309     esp = esp + 0x14u; /* 0x3802C2FB: add esp, 0x14 */
   3310     _flag_k = FK_ADD;
   3311     PUSH32(esp, edi); /* 0x3802C2FE: push edi */
   3312     MEM8(ebp + (-0x48)) = (uint8_t)(LO8(ecx)); /* 0x3802C2FF: mov byte ptr [ebp - 0x48], cl */
   3313     PUSH32(esp, edi); /* 0x3802C302: push edi */
   3314     ecx = ebp + (-0x48); /* 0x3802C303: lea ecx, [ebp - 0x48] */
   3315     MEM32(ebp + (-0x7C)) = eax; /* 0x3802C306: mov dword ptr [ebp - 0x7c], eax */
   3316     RECOMP_ICALL(0x3802E0F0u); /* 0x3802C309: call 0x3802e0f0 */ /* not lifted */
   3317     RECOMP_FLAGS_IN();
   3318     MEM32(ebp + (-0x44)) = eax; /* 0x3802C30E: mov dword ptr [ebp - 0x44], eax */
   3319     MEM32(ebp + (-0x40)) = edi; /* 0x3802C311: mov dword ptr [ebp - 0x40], edi */
   3320     PUSH32(esp, 0x14u); /* 0x3802C314: push 0x14 */
   3321     MEM32(ebp + (-0x4)) = edi; /* 0x3802C316: mov dword ptr [ebp - 4], edi */
   3322     RECOMP_ICALL(0x3804B676u); /* 0x3802C319: call 0x3804b676 */ /* not lifted */
   3323     RECOMP_FLAGS_IN();
   3324     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   3325     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   3326     esp = esp + 4; /* 0x3802C31E: add esp, 4 */
   3327     _flag_k = FK_ADD;
   3328     MEM32(ebp + (-0x14)) = eax; /* 0x3802C321: mov dword ptr [ebp - 0x14], eax */
   3329     /* cmp eax, edi */ /* 0x3802C324: cmp eax, edi */
   3330     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   3331     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3332     _flag_k = FK_CMP;
   3333     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3802C326: mov byte ptr [ebp - 4], 1 */
   3334     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C341; /* 0x3802C32A: je 0x3802c341 */
   3335 L_3802C32C:
   3336     edx = ebp + (-0x2D); /* 0x3802C32C: lea edx, [ebp - 0x2d] */
   3337     PUSH32(esp, edx); /* 0x3802C32F: push edx */
   3338     PUSH32(esp, edi); /* 0x3802C330: push edi */
   3339     ecx = ebp + (-0xD); /* 0x3802C331: lea ecx, [ebp - 0xd] */
   3340     PUSH32(esp, ecx); /* 0x3802C334: push ecx */
   3341     ecx = eax; /* 0x3802C335: mov ecx, eax */
   3342     RECOMP_ICALL(0x380135E0u); /* 0x3802C337: call 0x380135e0 */ /* not lifted */
   3343     RECOMP_FLAGS_IN();
   3344     eax = MEM32(ebp + (-0x14)); /* 0x3802C33C: mov eax, dword ptr [ebp - 0x14] */
   3345     goto L_3802C343; /* 0x3802C33F: jmp 0x3802c343 */
   3346 L_3802C341:
   3347     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3348     eax = 0; /* 0x3802C341: xor eax, eax */
   3349     _cf = 0;
   3350     _flag_k = FK_TEST;
   3351 L_3802C343:
   3352     PUSH32(esp, 0x10u); /* 0x3802C343: push 0x10 */
   3353     MEM8(ebp + (-0x4)) = (uint8_t)(0); /* 0x3802C345: mov byte ptr [ebp - 4], 0 */
   3354     MEM32(esi + 0x48) = eax; /* 0x3802C349: mov dword ptr [esi + 0x48], eax */
   3355     RECOMP_ICALL(0x3804B676u); /* 0x3802C34C: call 0x3804b676 */ /* not lifted */
   3356     RECOMP_FLAGS_IN();
   3357     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   3358     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   3359     esp = esp + 4; /* 0x3802C351: add esp, 4 */
   3360     _flag_k = FK_ADD;
   3361     /* cmp eax, edi */ /* 0x3802C354: cmp eax, edi */
   3362     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   3363     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3364     _flag_k = FK_CMP;
   3365     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C368; /* 0x3802C356: je 0x3802c368 */
   3366 L_3802C358:
   3367     SET_LO8(edx, MEM8(ebp + (-0xD))); /* 0x3802C358: mov dl, byte ptr [ebp - 0xd] */
   3368     MEM8(eax) = (uint8_t)(LO8(edx)); /* 0x3802C35B: mov byte ptr [eax], dl */
   3369     MEM32(eax + 0x4) = edi; /* 0x3802C35D: mov dword ptr [eax + 4], edi */
   3370     MEM32(eax + 0x8) = edi; /* 0x3802C360: mov dword ptr [eax + 8], edi */
   3371     MEM32(eax + 0xC) = edi; /* 0x3802C363: mov dword ptr [eax + 0xc], edi */
   3372     goto L_3802C36A; /* 0x3802C366: jmp 0x3802c36a */
   3373 L_3802C368:
   3374     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3375     eax = 0; /* 0x3802C368: xor eax, eax */
   3376     _cf = 0;
   3377     _flag_k = FK_TEST;
   3378 L_3802C36A:
   3379     MEM32(esi + 0x50) = eax; /* 0x3802C36A: mov dword ptr [esi + 0x50], eax */
   3380     SET_LO8(eax, MEM8(ebp + (-0xD))); /* 0x3802C36D: mov al, byte ptr [ebp - 0xd] */
   3381     MEM8(ebp + (-0x6C)) = (uint8_t)(LO8(eax)); /* 0x3802C370: mov byte ptr [ebp - 0x6c], al */
   3382     MEM32(ebp + (-0x68)) = edi; /* 0x3802C373: mov dword ptr [ebp - 0x68], edi */
   3383     MEM32(ebp + (-0x64)) = edi; /* 0x3802C376: mov dword ptr [ebp - 0x64], edi */
   3384     MEM32(ebp + (-0x60)) = edi; /* 0x3802C379: mov dword ptr [ebp - 0x60], edi */
   3385     ecx = MEM32(esi + 0x5C); /* 0x3802C37C: mov ecx, dword ptr [esi + 0x5c] */
   3386     edx = MEM32(ecx + 0xC); /* 0x3802C37F: mov edx, dword ptr [ecx + 0xc] */
   3387     fp_push(*(float*)&MEM32(edx + 0x8264)); /* 0x3802C382: fld dword ptr [edx + 0x8264] */
   3388     eax = MEM32(ebx + 0x4); /* 0x3802C388: mov eax, dword ptr [ebx + 4] */
   3389     /* cmp eax, edi */ /* 0x3802C38B: cmp eax, edi */
   3390     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   3391     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3392     _flag_k = FK_CMP;
   3393     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x38)) = _v; } /* 0x3802C38D: fstp dword ptr [ebp - 0x38] */
   3394     MEM8(ebp + (-0x4)) = (uint8_t)(2); /* 0x3802C390: mov byte ptr [ebp - 4], 2 */
   3395     if (CMP_NE(_flag_a, _flag_b)) goto L_3802C39B; /* 0x3802C394: jne 0x3802c39b */
   3396 L_3802C396:
   3397     MEM32(ebp + (-0x4C)) = edi; /* 0x3802C396: mov dword ptr [ebp - 0x4c], edi */
   3398     goto L_3802C3A6; /* 0x3802C399: jmp 0x3802c3a6 */
   3399 L_3802C39B:
   3400     ecx = MEM32(ebx + 0x8); /* 0x3802C39B: mov ecx, dword ptr [ebx + 8] */
   3401     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
   3402     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3403     ecx = ecx - eax; /* 0x3802C39E: sub ecx, eax */
   3404     _flag_k = FK_CMP;
   3405     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3802C3A0: sar ecx, 2 */
   3406     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   3407     ecx = (uint32_t)((int32_t)ecx >> 2u);
   3408     MEM32(ebp + (-0x4C)) = ecx; /* 0x3802C3A3: mov dword ptr [ebp - 0x4c], ecx */
   3409 L_3802C3A6:
   3410     /* cmp MEM32(ebp + (-0x4C)), edi */ /* 0x3802C3A6: cmp dword ptr [ebp - 0x4c], edi */
   3411     _flag_a = (uint32_t)(MEM32(ebp + (-0x4C))); _flag_b = (uint32_t)(edi);
   3412     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3413     _flag_k = FK_CMP;
   3414     MEM32(ebp + (-0x3C)) = edi; /* 0x3802C3A9: mov dword ptr [ebp - 0x3c], edi */
   3415     if (CMP_BE(_flag_a, _flag_b)) goto L_3802CBE4; /* 0x3802C3AC: jbe 0x3802cbe4 */
   3416 L_3802C3B2:
   3417     goto L_3802C3B7; /* 0x3802C3B2: jmp 0x3802c3b7 */
   3418 L_3802C3B4:
   3419     ebx = MEM32(ebp + (-0x74)); /* 0x3802C3B4: mov ebx, dword ptr [ebp - 0x74] */
   3420 L_3802C3B7:
   3421     eax = MEM32(ebp + (-0x64)); /* 0x3802C3B7: mov eax, dword ptr [ebp - 0x64] */
   3422     ecx = MEM32(ebp + (-0x68)); /* 0x3802C3BA: mov ecx, dword ptr [ebp - 0x68] */
   3423     PUSH32(esp, eax); /* 0x3802C3BD: push eax */
   3424     PUSH32(esp, ecx); /* 0x3802C3BE: push ecx */
   3425     ecx = ebp + (-0x6C); /* 0x3802C3BF: lea ecx, [ebp - 0x6c] */
   3426     RECOMP_ICALL(0x3802D8B0u); /* 0x3802C3C2: call 0x3802d8b0 */ /* not lifted */
   3427     RECOMP_FLAGS_IN();
   3428     eax = MEM32(ebp + (-0x44)); /* 0x3802C3C7: mov eax, dword ptr [ebp - 0x44] */
   3429     ecx = MEM32(eax); /* 0x3802C3CA: mov ecx, dword ptr [eax] */
   3430     PUSH32(esp, eax); /* 0x3802C3CC: push eax */
   3431     PUSH32(esp, ecx); /* 0x3802C3CD: push ecx */
   3432     edx = ebp + (-0x13C); /* 0x3802C3CE: lea edx, [ebp - 0x13c] */
   3433     PUSH32(esp, edx); /* 0x3802C3D4: push edx */
   3434     ecx = ebp + (-0x48); /* 0x3802C3D5: lea ecx, [ebp - 0x48] */
   3435     RECOMP_ICALL(0x3802D5D0u); /* 0x3802C3D8: call 0x3802d5d0 */ /* not lifted */
   3436     RECOMP_FLAGS_IN();
   3437     eax = MEM32(ebx + 0x4); /* 0x3802C3DD: mov eax, dword ptr [ebx + 4] */
   3438     ecx = MEM32(ebp + (-0x3C)); /* 0x3802C3E0: mov ecx, dword ptr [ebp - 0x3c] */
   3439     esi = MEM32(eax + ecx * 4); /* 0x3802C3E3: mov esi, dword ptr [eax + ecx*4] */
   3440     edx = MEM32(esi + 0x44); /* 0x3802C3E6: mov edx, dword ptr [esi + 0x44] */
   3441     MEM32(ebp + (-0xF8)) = edx; /* 0x3802C3E9: mov dword ptr [ebp - 0xf8], edx */
   3442     MEM32(ebp + (-0xF4)) = edi; /* 0x3802C3EF: mov dword ptr [ebp - 0xf4], edi */
   3443     fp_push_i64((int64_t)MEM64(ebp + (-0xF8))); /* 0x3802C3F5: fild qword ptr [ebp - 0xf8] */
   3444     MEM32(ebp + (-0x34)) = esi; /* 0x3802C3FB: mov dword ptr [ebp - 0x34], esi */
   3445     _st[0] *= (double)*(float*)ADDR(0x3804EAC0); /* 0x3802C3FE: fmul dword ptr [0x3804eac0] */
   3446     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x3802C404: fcom dword ptr [0x3804e8e4] */
   3447     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802C40A: fnstsw ax */
   3448     /* test HI8(eax), 1 */ /* 0x3802C40C: test ah, 1 */
   3449     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   3450     _cf = 0;
   3451     _flag_k = FK_NARROW(FK_TEST, 24);
   3452     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802C426; /* 0x3802C40F: jne 0x3802c426 */
   3453 L_3802C411:
   3454     _fpu_cmp = FPU_CMP(_st[0], *(double*)ADDR(0x3804E8F8)); /* 0x3802C411: fcom qword ptr [0x3804e8f8] */
   3455     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802C417: fnstsw ax */
   3456     /* test HI8(eax), 1 */ /* 0x3802C419: test ah, 1 */
   3457     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   3458     _cf = 0;
   3459     _flag_k = FK_NARROW(FK_TEST, 24);
   3460     if (TEST_Z(_flag_a, _flag_b)) goto L_3802C426; /* 0x3802C41C: je 0x3802c426 */
   3461 L_3802C41E:
   3462     _st[0] *= (double)*(float*)ADDR(0x3804E8BC); /* 0x3802C41E: fmul dword ptr [0x3804e8bc] */
   3463     goto L_3802C447; /* 0x3802C424: jmp 0x3802c447 */
   3464 L_3802C426:
   3465     _st[0] *= (double)*(float*)ADDR(0x3804E8F4); /* 0x3802C426: fmul dword ptr [0x3804e8f4] */
   3466     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   3467     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3468     esp = esp - 8; /* 0x3802C42C: sub esp, 8 */
   3469     _flag_k = FK_CMP;
   3470     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802C42F: fst dword ptr [ebp - 0x14] */
   3471     { double _v = fp_pop(); *(double*)ADDR(esp) = _v; } /* 0x3802C432: fstp qword ptr [esp] */
   3472     RECOMP_ICALL(MEM32(0x3804E0AC)); /* 0x3802C435: call dword ptr [0x3804e0ac] */
   3473     RECOMP_FLAGS_IN();
   3474     _st[0] = (double)*(float*)ADDR(ebp + (-0x14)) - _st[0]; /* 0x3802C43B: fsubr dword ptr [ebp - 0x14] */
   3475     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   3476     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   3477     esp = esp + 8; /* 0x3802C43E: add esp, 8 */
   3478     _flag_k = FK_ADD;
   3479     _st[0] *= (double)*(float*)ADDR(0x3804E8F0); /* 0x3802C441: fmul dword ptr [0x3804e8f0] */
   3480 L_3802C447:
   3481     fp_push(_st[0]); /* 0x3802C447: fld st(0) */
   3482     ecx = esi + 0x6C; /* 0x3802C449: lea ecx, [esi + 0x6c] */
   3483     _st[0] = sin(_st[0]); _fpu_cmp = 1; /* 0x3802C44C: fsin  */
   3484     fp_push(*(float*)&MEM32(0x3804E8E4)); /* 0x3802C44E: fld dword ptr [0x3804e8e4] */
   3485     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802C454: fst dword ptr [ebp - 0x14] */
   3486     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x98)) = _v; } /* 0x3802C457: fstp dword ptr [ebp - 0x98] */
   3487     eax = MEM32(ebp + (-0x14)); /* 0x3802C45D: mov eax, dword ptr [ebp - 0x14] */
   3488     MEM32(ebp + (-0x90)) = eax; /* 0x3802C460: mov dword ptr [ebp - 0x90], eax */
   3489     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x94)) = _v; } /* 0x3802C466: fstp dword ptr [ebp - 0x94] */
   3490     _st[0] = cos(_st[0]); _fpu_cmp = 1; /* 0x3802C46C: fcos  */
   3491     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8C)) = _v; } /* 0x3802C46E: fstp dword ptr [ebp - 0x8c] */
   3492     edx = MEM32(ecx); /* 0x3802C474: mov edx, dword ptr [ecx] */
   3493     eax = MEM32(ecx + 0x4); /* 0x3802C476: mov eax, dword ptr [ecx + 4] */
   3494     ecx = MEM32(ecx + 0x8); /* 0x3802C479: mov ecx, dword ptr [ecx + 8] */
   3495     MEM32(ebp + (-0xA4)) = edx; /* 0x3802C47C: mov dword ptr [ebp - 0xa4], edx */
   3496     fp_push(*(float*)&MEM32(ebp + (-0xA4))); /* 0x3802C482: fld dword ptr [ebp - 0xa4] */
   3497     _st[0] *= (double)*(float*)ADDR(ebp + (-0x38)); /* 0x3802C488: fmul dword ptr [ebp - 0x38] */
   3498     MEM32(ebp + (-0xA0)) = eax; /* 0x3802C48B: mov dword ptr [ebp - 0xa0], eax */
   3499     fp_push(*(float*)&MEM32(ebp + (-0xA0))); /* 0x3802C491: fld dword ptr [ebp - 0xa0] */
   3500     MEM32(ebp + (-0x9C)) = ecx; /* 0x3802C497: mov dword ptr [ebp - 0x9c], ecx */
   3501     _st[0] *= (double)*(float*)ADDR(ebp + (-0x38)); /* 0x3802C49D: fmul dword ptr [ebp - 0x38] */
   3502     PUSH32(esp, ecx); /* 0x3802C4A0: push ecx */
   3503     fp_push(*(float*)&MEM32(ebp + (-0x9C))); /* 0x3802C4A1: fld dword ptr [ebp - 0x9c] */
   3504     _st[0] *= (double)*(float*)ADDR(ebp + (-0x38)); /* 0x3802C4A7: fmul dword ptr [ebp - 0x38] */
   3505     _st[0] = -_st[0]; /* 0x3802C4AA: fchs  */
   3506     { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x3802C4AC: fstp dword ptr [esp] */
   3507     PUSH32(esp, ecx); /* 0x3802C4AF: push ecx */
   3508     _st[0] = -_st[0]; /* 0x3802C4B0: fchs  */
   3509     { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x3802C4B2: fstp dword ptr [esp] */
   3510     PUSH32(esp, ecx); /* 0x3802C4B5: push ecx */
   3511     ecx = ebp + (-0x190); /* 0x3802C4B6: lea ecx, [ebp - 0x190] */
   3512     _st[0] = -_st[0]; /* 0x3802C4BC: fchs  */
   3513     { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x3802C4BE: fstp dword ptr [esp] */
   3514     RECOMP_ICALL(MEM32(0x3804E4D8)); /* 0x3802C4C1: call dword ptr [0x3804e4d8] */
   3515     RECOMP_FLAGS_IN();
   3516     edx = eax; /* 0x3802C4C7: mov edx, eax */
   3517     ecx = MEM32(edx); /* 0x3802C4C9: mov ecx, dword ptr [edx] */
   3518     MEM32(ebp + (-0x20)) = ecx; /* 0x3802C4CB: mov dword ptr [ebp - 0x20], ecx */
   3519     ecx = MEM32(edx + 0x4); /* 0x3802C4CE: mov ecx, dword ptr [edx + 4] */
   3520     MEM32(ebp + (-0x1C)) = ecx; /* 0x3802C4D1: mov dword ptr [ebp - 0x1c], ecx */
   3521     edx = MEM32(edx + 0x8); /* 0x3802C4D4: mov edx, dword ptr [edx + 8] */
   3522     MEM32(ebp + (-0x18)) = edx; /* 0x3802C4D7: mov dword ptr [ebp - 0x18], edx */
   3523     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3524     ecx = 0; /* 0x3802C4DA: xor ecx, ecx */
   3525     _cf = 0;
   3526     _flag_k = FK_TEST;
   3527     SET_LO16(ecx, MEM16(esi + 0x50)); /* 0x3802C4DC: mov cx, word ptr [esi + 0x50] */
   3528     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3529     edx = 0; /* 0x3802C4E0: xor edx, edx */
   3530     _cf = 0;
   3531     _flag_k = FK_TEST;
   3532     SET_LO16(edx, MEM16(esi + 0x4C)); /* 0x3802C4E2: mov dx, word ptr [esi + 0x4c] */
   3533     MEM32(ebp + (-0x100)) = 0; /* 0x3802C4E6: mov dword ptr [ebp - 0x100], 0 */
   3534     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   3535     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3536     ecx = ecx - edx; /* 0x3802C4F0: sub ecx, edx */
   3537     _flag_k = FK_CMP;
   3538     MEM32(ebp + (-0x14)) = ecx; /* 0x3802C4F2: mov dword ptr [ebp - 0x14], ecx */
   3539     fp_push((double)(int32_t)MEM32(ebp + (-0x14))); /* 0x3802C4F5: fild dword ptr [ebp - 0x14] */
   3540     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3541     ecx = 0; /* 0x3802C4F8: xor ecx, ecx */
   3542     _cf = 0;
   3543     _flag_k = FK_TEST;
   3544     SET_LO16(ecx, MEM16(esi + 0x52)); /* 0x3802C4FA: mov cx, word ptr [esi + 0x52] */
   3545     _st[0] *= (double)*(float*)ADDR(ebp + (-0x38)); /* 0x3802C4FE: fmul dword ptr [ebp - 0x38] */
   3546     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3547     edx = 0; /* 0x3802C501: xor edx, edx */
   3548     _cf = 0;
   3549     _flag_k = FK_TEST;
   3550     SET_LO16(edx, MEM16(esi + 0x4E)); /* 0x3802C503: mov dx, word ptr [esi + 0x4e] */
   3551     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   3552     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3553     ecx = ecx - edx; /* 0x3802C507: sub ecx, edx */
   3554     _flag_k = FK_CMP;
   3555     edx = MEM32(eax); /* 0x3802C509: mov edx, dword ptr [eax] */
   3556     MEM32(ebp + (-0x14)) = ecx; /* 0x3802C50B: mov dword ptr [ebp - 0x14], ecx */
   3557     fp_push((double)(int32_t)MEM32(ebp + (-0x14))); /* 0x3802C50E: fild dword ptr [ebp - 0x14] */
   3558     MEM32(ebp + (-0x110)) = edx; /* 0x3802C511: mov dword ptr [ebp - 0x110], edx */
   3559     edx = MEM32(eax + 0x8); /* 0x3802C517: mov edx, dword ptr [eax + 8] */
   3560     _st[0] *= (double)*(float*)ADDR(ebp + (-0x38)); /* 0x3802C51A: fmul dword ptr [ebp - 0x38] */
   3561     MEM32(ebp + (-0x108)) = edx; /* 0x3802C51D: mov dword ptr [ebp - 0x108], edx */
   3562     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x14)) = _v; } /* 0x3802C523: fstp dword ptr [ebp - 0x14] */
   3563     ecx = MEM32(ebp + (-0x14)); /* 0x3802C526: mov ecx, dword ptr [ebp - 0x14] */
   3564     MEM32(ebp + (-0xFC)) = ecx; /* 0x3802C529: mov dword ptr [ebp - 0xfc], ecx */
   3565     ecx = MEM32(eax + 0x4); /* 0x3802C52F: mov ecx, dword ptr [eax + 4] */
   3566     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x104)) = _v; } /* 0x3802C532: fstp dword ptr [ebp - 0x104] */
   3567     eax = ebp + (-0x104); /* 0x3802C538: lea eax, [ebp - 0x104] */
   3568     MEM32(ebp + (-0x10C)) = ecx; /* 0x3802C53E: mov dword ptr [ebp - 0x10c], ecx */
   3569     PUSH32(esp, eax); /* 0x3802C544: push eax */
   3570     ecx = ebp + (-0x110); /* 0x3802C545: lea ecx, [ebp - 0x110] */
   3571     RECOMP_ICALL(MEM32(0x3804E4E8)); /* 0x3802C54B: call dword ptr [0x3804e4e8] */
   3572     RECOMP_FLAGS_IN();
   3573     fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x3802C551: fld dword ptr [ebp - 0x20] */
   3574     ecx = MEM32(eax); /* 0x3802C554: mov ecx, dword ptr [eax] */
   3575     _st[0] -= (double)*(float*)ADDR(0x3804E8CC); /* 0x3802C556: fsub dword ptr [0x3804e8cc] */
   3576     MEM32(ebp + (-0x2C)) = ecx; /* 0x3802C55C: mov dword ptr [ebp - 0x2c], ecx */
   3577     edx = MEM32(eax + 0x4); /* 0x3802C55F: mov edx, dword ptr [eax + 4] */
   3578     MEM32(ebp + (-0x28)) = edx; /* 0x3802C562: mov dword ptr [ebp - 0x28], edx */
   3579     eax = MEM32(eax + 0x8); /* 0x3802C565: mov eax, dword ptr [eax + 8] */
   3580     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x3802C568: fstp dword ptr [ebp - 0x20] */
   3581     MEM32(ebp + (-0x24)) = eax; /* 0x3802C56B: mov dword ptr [ebp - 0x24], eax */
   3582     fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x3802C56E: fld dword ptr [ebp - 0x18] */
   3583     ecx = MEM32(ebp + (-0x1C)); /* 0x3802C571: mov ecx, dword ptr [ebp - 0x1c] */
   3584     _st[0] -= (double)*(float*)ADDR(0x3804E8CC); /* 0x3802C574: fsub dword ptr [0x3804e8cc] */
   3585     MEM32(ebp + (-0x1C)) = ecx; /* 0x3802C57A: mov dword ptr [ebp - 0x1c], ecx */
   3586     eax = ebp + (-0x20); /* 0x3802C57D: lea eax, [ebp - 0x20] */
   3587     PUSH32(esp, eax); /* 0x3802C580: push eax */
   3588     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x3802C581: fstp dword ptr [ebp - 0x18] */
   3589     ecx = ebp + (-0x184); /* 0x3802C584: lea ecx, [ebp - 0x184] */
   3590     fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x3802C58A: fld dword ptr [ebp - 0x2c] */
   3591     PUSH32(esp, ecx); /* 0x3802C58D: push ecx */
   3592     _st[0] -= (double)*(float*)ADDR(0x3804E8CC); /* 0x3802C58E: fsub dword ptr [0x3804e8cc] */
   3593     ecx = ebp + (-0x98); /* 0x3802C594: lea ecx, [ebp - 0x98] */
   3594     MEM32(ebp + (-0x28)) = edx; /* 0x3802C59A: mov dword ptr [ebp - 0x28], edx */
   3595     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x2C)) = _v; } /* 0x3802C59D: fstp dword ptr [ebp - 0x2c] */
   3596     fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x3802C5A0: fld dword ptr [ebp - 0x24] */
   3597     _st[0] -= (double)*(float*)ADDR(0x3804E8CC); /* 0x3802C5A3: fsub dword ptr [0x3804e8cc] */
   3598     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x3802C5A9: fstp dword ptr [ebp - 0x24] */
   3599     RECOMP_ICALL(MEM32(0x3804E4FC)); /* 0x3802C5AC: call dword ptr [0x3804e4fc] */
   3600     RECOMP_FLAGS_IN();
   3601     edx = MEM32(eax); /* 0x3802C5B2: mov edx, dword ptr [eax] */
   3602     MEM32(ebp + (-0xB0)) = edx; /* 0x3802C5B4: mov dword ptr [ebp - 0xb0], edx */
   3603     ecx = MEM32(eax + 0x4); /* 0x3802C5BA: mov ecx, dword ptr [eax + 4] */
   3604     MEM32(ebp + (-0xAC)) = ecx; /* 0x3802C5BD: mov dword ptr [ebp - 0xac], ecx */
   3605     edx = MEM32(eax + 0x8); /* 0x3802C5C3: mov edx, dword ptr [eax + 8] */
   3606     eax = ebp + (-0xB0); /* 0x3802C5C6: lea eax, [ebp - 0xb0] */
   3607     PUSH32(esp, eax); /* 0x3802C5CC: push eax */
   3608     ecx = ebp + (-0x19C); /* 0x3802C5CD: lea ecx, [ebp - 0x19c] */
   3609     PUSH32(esp, ecx); /* 0x3802C5D3: push ecx */
   3610     ecx = ebp + (-0x98); /* 0x3802C5D4: lea ecx, [ebp - 0x98] */
   3611     MEM32(ebp + (-0xA8)) = edx; /* 0x3802C5DA: mov dword ptr [ebp - 0xa8], edx */
   3612     RECOMP_ICALL(MEM32(0x3804E4FC)); /* 0x3802C5E0: call dword ptr [0x3804e4fc] */
   3613     RECOMP_FLAGS_IN();
   3614     fp_push(*(float*)&MEM32(ebp + (-0x8C))); /* 0x3802C5E6: fld dword ptr [ebp - 0x8c] */
   3615     edx = MEM32(eax); /* 0x3802C5EC: mov edx, dword ptr [eax] */
   3616     _st[0] += _st[0]; /* 0x3802C5EE: fadd st(0), st(0) */
   3617     MEM32(ebp + (-0xE0)) = edx; /* 0x3802C5F0: mov dword ptr [ebp - 0xe0], edx */
   3618     ecx = MEM32(eax + 0x4); /* 0x3802C5F6: mov ecx, dword ptr [eax + 4] */
   3619     MEM32(ebp + (-0xDC)) = ecx; /* 0x3802C5F9: mov dword ptr [ebp - 0xdc], ecx */
   3620     edx = MEM32(eax + 0x8); /* 0x3802C5FF: mov edx, dword ptr [eax + 8] */
   3621     PUSH32(esp, ecx); /* 0x3802C602: push ecx */
   3622     ecx = ebp + (-0xB0); /* 0x3802C603: lea ecx, [ebp - 0xb0] */
   3623     { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x3802C609: fstp dword ptr [esp] */
   3624     MEM32(ebp + (-0xD8)) = edx; /* 0x3802C60C: mov dword ptr [ebp - 0xd8], edx */
   3625     RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x3802C612: call dword ptr [0x3804e4d4] */
   3626     RECOMP_FLAGS_IN();
   3627     PUSH32(esp, 0x40000000u); /* 0x3802C618: push 0x40000000 */
   3628     ecx = ebp + (-0xE0); /* 0x3802C61D: lea ecx, [ebp - 0xe0] */
   3629     RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x3802C623: call dword ptr [0x3804e4d4] */
   3630     RECOMP_FLAGS_IN();
   3631     eax = ebp + (-0xB0); /* 0x3802C629: lea eax, [ebp - 0xb0] */
   3632     PUSH32(esp, eax); /* 0x3802C62F: push eax */
   3633     ecx = ebp + (-0x20); /* 0x3802C630: lea ecx, [ebp - 0x20] */
   3634     RECOMP_ICALL(MEM32(0x3804E4E8)); /* 0x3802C633: call dword ptr [0x3804e4e8] */
   3635     RECOMP_FLAGS_IN();
   3636     ecx = ebp + (-0xE0); /* 0x3802C639: lea ecx, [ebp - 0xe0] */
   3637     PUSH32(esp, ecx); /* 0x3802C63F: push ecx */
   3638     ecx = ebp + (-0x20); /* 0x3802C640: lea ecx, [ebp - 0x20] */
   3639     RECOMP_ICALL(MEM32(0x3804E4E8)); /* 0x3802C643: call dword ptr [0x3804e4e8] */
   3640     RECOMP_FLAGS_IN();
   3641     edx = ebp + (-0x2C); /* 0x3802C649: lea edx, [ebp - 0x2c] */
   3642     PUSH32(esp, edx); /* 0x3802C64C: push edx */
   3643     eax = ebp + (-0x178); /* 0x3802C64D: lea eax, [ebp - 0x178] */
   3644     PUSH32(esp, eax); /* 0x3802C653: push eax */
   3645     ecx = ebp + (-0x98); /* 0x3802C654: lea ecx, [ebp - 0x98] */
   3646     RECOMP_ICALL(MEM32(0x3804E4FC)); /* 0x3802C65A: call dword ptr [0x3804e4fc] */
   3647     RECOMP_FLAGS_IN();
   3648     ecx = MEM32(eax); /* 0x3802C660: mov ecx, dword ptr [eax] */
   3649     MEM32(ebp + (-0xC4)) = ecx; /* 0x3802C662: mov dword ptr [ebp - 0xc4], ecx */
   3650     edx = MEM32(eax + 0x4); /* 0x3802C668: mov edx, dword ptr [eax + 4] */
   3651     MEM32(ebp + (-0xC0)) = edx; /* 0x3802C66B: mov dword ptr [ebp - 0xc0], edx */
   3652     eax = MEM32(eax + 0x8); /* 0x3802C671: mov eax, dword ptr [eax + 8] */
   3653     ecx = ebp + (-0xC4); /* 0x3802C674: lea ecx, [ebp - 0xc4] */
   3654     PUSH32(esp, ecx); /* 0x3802C67A: push ecx */
   3655     edx = ebp + (-0x1A8); /* 0x3802C67B: lea edx, [ebp - 0x1a8] */
   3656     PUSH32(esp, edx); /* 0x3802C681: push edx */
   3657     ecx = ebp + (-0x98); /* 0x3802C682: lea ecx, [ebp - 0x98] */
   3658     MEM32(ebp + (-0xBC)) = eax; /* 0x3802C688: mov dword ptr [ebp - 0xbc], eax */
   3659     RECOMP_ICALL(MEM32(0x3804E4FC)); /* 0x3802C68E: call dword ptr [0x3804e4fc] */
   3660     RECOMP_FLAGS_IN();
   3661     fp_push(*(float*)&MEM32(ebp + (-0x8C))); /* 0x3802C694: fld dword ptr [ebp - 0x8c] */
   3662     ecx = MEM32(eax); /* 0x3802C69A: mov ecx, dword ptr [eax] */
   3663     _st[0] += _st[0]; /* 0x3802C69C: fadd st(0), st(0) */
   3664     MEM32(ebp + (-0xD4)) = ecx; /* 0x3802C69E: mov dword ptr [ebp - 0xd4], ecx */
   3665     edx = MEM32(eax + 0x4); /* 0x3802C6A4: mov edx, dword ptr [eax + 4] */
   3666     MEM32(ebp + (-0xD0)) = edx; /* 0x3802C6A7: mov dword ptr [ebp - 0xd0], edx */
   3667     eax = MEM32(eax + 0x8); /* 0x3802C6AD: mov eax, dword ptr [eax + 8] */
   3668     PUSH32(esp, ecx); /* 0x3802C6B0: push ecx */
   3669     { float _v = (float)fp_pop(); *(float*)ADDR(esp) = _v; } /* 0x3802C6B1: fstp dword ptr [esp] */
   3670     MEM32(ebp + (-0xCC)) = eax; /* 0x3802C6B4: mov dword ptr [ebp - 0xcc], eax */
   3671     ecx = ebp + (-0xC4); /* 0x3802C6BA: lea ecx, [ebp - 0xc4] */
   3672     RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x3802C6C0: call dword ptr [0x3804e4d4] */
   3673     RECOMP_FLAGS_IN();
   3674     PUSH32(esp, 0x40000000u); /* 0x3802C6C6: push 0x40000000 */
   3675     ecx = ebp + (-0xD4); /* 0x3802C6CB: lea ecx, [ebp - 0xd4] */
   3676     RECOMP_ICALL(MEM32(0x3804E4D4)); /* 0x3802C6D1: call dword ptr [0x3804e4d4] */
   3677     RECOMP_FLAGS_IN();
   3678     ecx = ebp + (-0xC4); /* 0x3802C6D7: lea ecx, [ebp - 0xc4] */
   3679     PUSH32(esp, ecx); /* 0x3802C6DD: push ecx */
   3680     ecx = ebp + (-0x2C); /* 0x3802C6DE: lea ecx, [ebp - 0x2c] */
   3681     RECOMP_ICALL(MEM32(0x3804E4E8)); /* 0x3802C6E1: call dword ptr [0x3804e4e8] */
   3682     RECOMP_FLAGS_IN();
   3683     edx = ebp + (-0xD4); /* 0x3802C6E7: lea edx, [ebp - 0xd4] */
   3684     PUSH32(esp, edx); /* 0x3802C6ED: push edx */
   3685     ecx = ebp + (-0x2C); /* 0x3802C6EE: lea ecx, [ebp - 0x2c] */
   3686     RECOMP_ICALL(MEM32(0x3804E4E8)); /* 0x3802C6F1: call dword ptr [0x3804e4e8] */
   3687     RECOMP_FLAGS_IN();
   3688     eax = MEM32(esi + 0x44); /* 0x3802C6F7: mov eax, dword ptr [esi + 0x44] */
   3689     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   3690     eax = eax - 1; /* 0x3802C6FA: dec eax */
   3691     _flag_k = FK_DEC;
   3692     if (/* dec result */ CMP_EQ(_flag_a, _flag_b)) goto L_3802C75D; /* 0x3802C6FB: je 0x3802c75d */
   3693 L_3802C6FD:
   3694     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   3695     eax = eax - 1; /* 0x3802C6FD: dec eax */
   3696     _flag_k = FK_DEC;
   3697     if (/* dec result */ CMP_EQ(_flag_a, _flag_b)) goto L_3802C737; /* 0x3802C6FE: je 0x3802c737 */
   3698 L_3802C700:
   3699     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   3700     eax = eax - 1; /* 0x3802C700: dec eax */
   3701     _flag_k = FK_DEC;
   3702     if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3802C769; /* 0x3802C701: jne 0x3802c769 */
   3703 L_3802C703:
   3704     ebx = MEM32(ebp + (-0x2C)); /* 0x3802C703: mov ebx, dword ptr [ebp - 0x2c] */
   3705     eax = MEM32(ebp + (-0x20)); /* 0x3802C706: mov eax, dword ptr [ebp - 0x20] */
   3706     edx = MEM32(ebp + (-0x18)); /* 0x3802C709: mov edx, dword ptr [ebp - 0x18] */
   3707     ecx = MEM32(ebp + (-0x1C)); /* 0x3802C70C: mov ecx, dword ptr [ebp - 0x1c] */
   3708     MEM32(ebp + (-0x20)) = ebx; /* 0x3802C70F: mov dword ptr [ebp - 0x20], ebx */
   3709     ebx = MEM32(ebp + (-0x28)); /* 0x3802C712: mov ebx, dword ptr [ebp - 0x28] */
   3710     MEM32(ebp + (-0x1C)) = ebx; /* 0x3802C715: mov dword ptr [ebp - 0x1c], ebx */
   3711     ebx = MEM32(ebp + (-0x24)); /* 0x3802C718: mov ebx, dword ptr [ebp - 0x24] */
   3712     MEM32(ebp + (-0x18)) = ebx; /* 0x3802C71B: mov dword ptr [ebp - 0x18], ebx */
   3713     fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x3802C71E: fld dword ptr [ebp - 0x18] */
   3714     MEM32(ebp + (-0x2C)) = eax; /* 0x3802C721: mov dword ptr [ebp - 0x2c], eax */
   3715     eax = edx; /* 0x3802C724: mov eax, edx */
   3716     MEM32(ebp + (-0x15C)) = edx; /* 0x3802C726: mov dword ptr [ebp - 0x15c], edx */
   3717     MEM32(ebp + (-0x28)) = ecx; /* 0x3802C72C: mov dword ptr [ebp - 0x28], ecx */
   3718     MEM32(ebp + (-0x24)) = edx; /* 0x3802C72F: mov dword ptr [ebp - 0x24], edx */
   3719     MEM32(ebp + (-0x18)) = eax; /* 0x3802C732: mov dword ptr [ebp - 0x18], eax */
   3720     goto L_3802C766; /* 0x3802C735: jmp 0x3802c766 */
   3721 L_3802C737:
   3722     ebx = MEM32(ebp + (-0x2C)); /* 0x3802C737: mov ebx, dword ptr [ebp - 0x2c] */
   3723     eax = MEM32(ebp + (-0x20)); /* 0x3802C73A: mov eax, dword ptr [ebp - 0x20] */
   3724     ecx = MEM32(ebp + (-0x1C)); /* 0x3802C73D: mov ecx, dword ptr [ebp - 0x1c] */
   3725     edx = MEM32(ebp + (-0x18)); /* 0x3802C740: mov edx, dword ptr [ebp - 0x18] */
   3726     MEM32(ebp + (-0x20)) = ebx; /* 0x3802C743: mov dword ptr [ebp - 0x20], ebx */
   3727     ebx = MEM32(ebp + (-0x28)); /* 0x3802C746: mov ebx, dword ptr [ebp - 0x28] */
   3728     MEM32(ebp + (-0x1C)) = ebx; /* 0x3802C749: mov dword ptr [ebp - 0x1c], ebx */
   3729     ebx = MEM32(ebp + (-0x24)); /* 0x3802C74C: mov ebx, dword ptr [ebp - 0x24] */
   3730     MEM32(ebp + (-0x18)) = ebx; /* 0x3802C74F: mov dword ptr [ebp - 0x18], ebx */
   3731     MEM32(ebp + (-0x2C)) = eax; /* 0x3802C752: mov dword ptr [ebp - 0x2c], eax */
   3732     MEM32(ebp + (-0x28)) = ecx; /* 0x3802C755: mov dword ptr [ebp - 0x28], ecx */
   3733     MEM32(ebp + (-0x24)) = edx; /* 0x3802C758: mov dword ptr [ebp - 0x24], edx */
   3734     goto L_3802C769; /* 0x3802C75B: jmp 0x3802c769 */
   3735 L_3802C75D:
   3736     ecx = MEM32(ebp + (-0x24)); /* 0x3802C75D: mov ecx, dword ptr [ebp - 0x24] */
   3737     fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x3802C760: fld dword ptr [ebp - 0x18] */
   3738     MEM32(ebp + (-0x18)) = ecx; /* 0x3802C763: mov dword ptr [ebp - 0x18], ecx */
   3739 L_3802C766:
   3740     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x3802C766: fstp dword ptr [ebp - 0x24] */
   3741 L_3802C769:
   3742     fp_push(*(float*)&MEM32(ebp + (-0x20))); /* 0x3802C769: fld dword ptr [ebp - 0x20] */
   3743     _st[0] += (double)*(float*)ADDR(esi + 0x54); /* 0x3802C76C: fadd dword ptr [esi + 0x54] */
   3744     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x20)) = _v; } /* 0x3802C76F: fstp dword ptr [ebp - 0x20] */
   3745     edx = MEM32(ebp + (-0x20)); /* 0x3802C772: mov edx, dword ptr [ebp - 0x20] */
   3746     fp_push(*(float*)&MEM32(ebp + (-0x1C))); /* 0x3802C775: fld dword ptr [ebp - 0x1c] */
   3747     MEM32(ebp + (-0x138)) = edx; /* 0x3802C778: mov dword ptr [ebp - 0x138], edx */
   3748     _st[0] += (double)*(float*)ADDR(esi + 0x58); /* 0x3802C77E: fadd dword ptr [esi + 0x58] */
   3749     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x1C)) = _v; } /* 0x3802C781: fstp dword ptr [ebp - 0x1c] */
   3750     eax = MEM32(ebp + (-0x1C)); /* 0x3802C784: mov eax, dword ptr [ebp - 0x1c] */
   3751     fp_push(*(float*)&MEM32(ebp + (-0x18))); /* 0x3802C787: fld dword ptr [ebp - 0x18] */
   3752     MEM32(ebp + (-0x134)) = eax; /* 0x3802C78A: mov dword ptr [ebp - 0x134], eax */
   3753     _st[0] += (double)*(float*)ADDR(esi + 0x5C); /* 0x3802C790: fadd dword ptr [esi + 0x5c] */
   3754     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x18)) = _v; } /* 0x3802C793: fstp dword ptr [ebp - 0x18] */
   3755     ecx = MEM32(ebp + (-0x18)); /* 0x3802C796: mov ecx, dword ptr [ebp - 0x18] */
   3756     fp_push(*(float*)&MEM32(ebp + (-0x2C))); /* 0x3802C799: fld dword ptr [ebp - 0x2c] */
   3757     MEM32(ebp + (-0x130)) = ecx; /* 0x3802C79C: mov dword ptr [ebp - 0x130], ecx */
   3758     _st[0] += (double)*(float*)ADDR(esi + 0x54); /* 0x3802C7A2: fadd dword ptr [esi + 0x54] */
   3759     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x2C)) = _v; } /* 0x3802C7A5: fstp dword ptr [ebp - 0x2c] */
   3760     edx = MEM32(ebp + (-0x2C)); /* 0x3802C7A8: mov edx, dword ptr [ebp - 0x2c] */
   3761     fp_push(*(float*)&MEM32(ebp + (-0x28))); /* 0x3802C7AB: fld dword ptr [ebp - 0x28] */
   3762     MEM32(ebp + (-0x12C)) = edx; /* 0x3802C7AE: mov dword ptr [ebp - 0x12c], edx */
   3763     _st[0] += (double)*(float*)ADDR(esi + 0x58); /* 0x3802C7B4: fadd dword ptr [esi + 0x58] */
   3764     edx = ebp + (-0x138); /* 0x3802C7B7: lea edx, [ebp - 0x138] */
   3765     PUSH32(esp, edx); /* 0x3802C7BD: push edx */
   3766     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x3802C7BE: fstp dword ptr [ebp - 0x28] */
   3767     fp_push(*(float*)&MEM32(ebp + (-0x24))); /* 0x3802C7C1: fld dword ptr [ebp - 0x24] */
   3768     _st[0] += (double)*(float*)ADDR(esi + 0x5C); /* 0x3802C7C4: fadd dword ptr [esi + 0x5c] */
   3769     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x24)) = _v; } /* 0x3802C7C7: fstp dword ptr [ebp - 0x24] */
   3770     ecx = MEM32(ebp + (-0x24)); /* 0x3802C7CA: mov ecx, dword ptr [ebp - 0x24] */
   3771     fp_push(*(float*)&MEM32(esi + 0x40)); /* 0x3802C7CD: fld dword ptr [esi + 0x40] */
   3772     MEM32(ebp + (-0x124)) = ecx; /* 0x3802C7D0: mov dword ptr [ebp - 0x124], ecx */
   3773     _st[0] -= (double)*(float*)ADDR(esi + 0x3C); /* 0x3802C7D6: fsub dword ptr [esi + 0x3c] */
   3774     ecx = ebp + (-0x6C); /* 0x3802C7D9: lea ecx, [ebp - 0x6c] */
   3775     _st[0] += (double)*(float*)ADDR(ebp + (-0x1C)); /* 0x3802C7DC: fadd dword ptr [ebp - 0x1c] */
   3776     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x28)) = _v; } /* 0x3802C7DF: fstp dword ptr [ebp - 0x28] */
   3777     eax = MEM32(ebp + (-0x28)); /* 0x3802C7E2: mov eax, dword ptr [ebp - 0x28] */
   3778     MEM32(ebp + (-0x128)) = eax; /* 0x3802C7E5: mov dword ptr [ebp - 0x128], eax */
   3779     eax = MEM32(ebp + (-0x64)); /* 0x3802C7EB: mov eax, dword ptr [ebp - 0x64] */
   3780     PUSH32(esp, eax); /* 0x3802C7EE: push eax */
   3781     RECOMP_ICALL(0x3802D690u); /* 0x3802C7EF: call 0x3802d690 */ /* not lifted */
   3782     RECOMP_FLAGS_IN();
   3783     SET_LO8(ecx, MEM8(ebp + (-0xD))); /* 0x3802C7F4: mov cl, byte ptr [ebp - 0xd] */
   3784     MEM8(ebp + (-0x5C)) = (uint8_t)(LO8(ecx)); /* 0x3802C7F7: mov byte ptr [ebp - 0x5c], cl */
   3785     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3786     ecx = 0; /* 0x3802C7FA: xor ecx, ecx */
   3787     _cf = 0;
   3788     _flag_k = FK_TEST;
   3789     MEM32(ebp + (-0x58)) = edi; /* 0x3802C7FC: mov dword ptr [ebp - 0x58], edi */
   3790     MEM32(ebp + (-0x54)) = ecx; /* 0x3802C7FF: mov dword ptr [ebp - 0x54], ecx */
   3791     MEM32(ebp + (-0x50)) = edi; /* 0x3802C802: mov dword ptr [ebp - 0x50], edi */
   3792     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3793     eax = 0; /* 0x3802C805: xor eax, eax */
   3794     _cf = 0;
   3795     _flag_k = FK_TEST;
   3796     /* cmp MEM16(esi + 0x7C), LO16(edi) */ /* 0x3802C807: cmp word ptr [esi + 0x7c], di */
   3797     _flag_a = (uint32_t)(MEM16(esi + 0x7C)) << 16; _flag_b = (uint32_t)(LO16(edi)) << 16;
   3798     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3799     _flag_k = FK_NARROW(FK_CMP, 16);
   3800     MEM8(ebp + (-0x4)) = (uint8_t)(3); /* 0x3802C80B: mov byte ptr [ebp - 4], 3 */
   3801     MEM32(ebp + (-0x14)) = eax; /* 0x3802C80F: mov dword ptr [ebp - 0x14], eax */
   3802     if (CMP_BE(_flag_a, _flag_b)) goto L_3802CA06; /* 0x3802C812: jbe 0x3802ca06 */
   3803 L_3802C818:
   3804     edx = MEM32(esi + 0x80); /* 0x3802C818: mov edx, dword ptr [esi + 0x80] */
   3805     SET_LO16(ebx, MEM16(edx + eax * 4)); /* 0x3802C81E: mov bx, word ptr [edx + eax*4] */
   3806     /* cmp LO16(ebx), 0xFFFFFFFFu */ /* 0x3802C822: cmp bx, -1 */
   3807     _flag_a = (uint32_t)(LO16(ebx)) << 16; _flag_b = (uint32_t)(0xFFFFFFFFu) << 16;
   3808     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3809     _flag_k = FK_NARROW(FK_CMP, 16);
   3810     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C9F1; /* 0x3802C826: je 0x3802c9f1 */
   3811 L_3802C82C:
   3812     eax = MEM32(ebp + (-0x3C)); /* 0x3802C82C: mov eax, dword ptr [ebp - 0x3c] */
   3813     esi = (int32_t)(int16_t)LO16(ebx); /* 0x3802C82F: movsx esi, bx */
   3814     /* cmp esi, eax */ /* 0x3802C832: cmp esi, eax */
   3815     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   3816     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3817     _flag_k = FK_CMP;
   3818     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C9EE; /* 0x3802C834: je 0x3802c9ee */
   3819 L_3802C83A:
   3820     eax = MEM32(ebp + (-0x58)); /* 0x3802C83A: mov eax, dword ptr [ebp - 0x58] */
   3821     edx = eax; /* 0x3802C83D: mov edx, eax */
   3822     /* cmp edx, ecx */ /* 0x3802C83F: cmp edx, ecx */
   3823     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   3824     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3825     _flag_k = FK_CMP;
   3826     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C854; /* 0x3802C841: je 0x3802c854 */
   3827 L_3802C843:
   3828     /* cmp MEM32(eax), esi */ /* 0x3802C843: cmp dword ptr [eax], esi */
   3829     _flag_a = (uint32_t)(MEM32(eax)); _flag_b = (uint32_t)(esi);
   3830     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3831     _flag_k = FK_CMP;
   3832     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C850; /* 0x3802C845: je 0x3802c850 */
   3833 L_3802C847:
   3834     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   3835     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   3836     eax = eax + 4; /* 0x3802C847: add eax, 4 */
   3837     _flag_k = FK_ADD;
   3838     /* cmp eax, ecx */ /* 0x3802C84A: cmp eax, ecx */
   3839     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   3840     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3841     _flag_k = FK_CMP;
   3842     RECOMP_BACKEDGE();
   3843     if (CMP_NE(_flag_a, _flag_b)) goto L_3802C843; /* 0x3802C84C: jne 0x3802c843 */
   3844 L_3802C84E:
   3845     goto L_3802C854; /* 0x3802C84E: jmp 0x3802c854 */
   3846 L_3802C850:
   3847     /* cmp eax, ecx */ /* 0x3802C850: cmp eax, ecx */
   3848     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   3849     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3850     _flag_k = FK_CMP;
   3851     if (CMP_NE(_flag_a, _flag_b)) goto L_3802C873; /* 0x3802C852: jne 0x3802c873 */
   3852 L_3802C854:
   3853     /* cmp esi, MEM32(ebp + (-0x4C)) */ /* 0x3802C854: cmp esi, dword ptr [ebp - 0x4c] */
   3854     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(ebp + (-0x4C)));
   3855     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3856     _flag_k = FK_CMP;
   3857     if (CMP_AE(_flag_a, _flag_b)) goto L_3802C9EE; /* 0x3802C857: jae 0x3802c9ee */
   3858 L_3802C85D:
   3859     eax = ebp + (-0xB4); /* 0x3802C85D: lea eax, [ebp - 0xb4] */
   3860     PUSH32(esp, eax); /* 0x3802C863: push eax */
   3861     PUSH32(esp, ecx); /* 0x3802C864: push ecx */
   3862     ecx = ebp + (-0x5C); /* 0x3802C865: lea ecx, [ebp - 0x5c] */
   3863     MEM32(ebp + (-0xB4)) = esi; /* 0x3802C868: mov dword ptr [ebp - 0xb4], esi */
   3864     RECOMP_ICALL(0x38009460u); /* 0x3802C86E: call 0x38009460 */ /* not lifted */
   3865     RECOMP_FLAGS_IN();
   3866 L_3802C873:
   3867     ecx = MEM32(ebp + (-0x78)); /* 0x3802C873: mov ecx, dword ptr [ebp - 0x78] */
   3868     PUSH32(esp, esi); /* 0x3802C876: push esi */
   3869     RECOMP_ICALL(0x3802B990u); /* 0x3802C877: call 0x3802b990 */ /* not lifted */
   3870     RECOMP_FLAGS_IN();
   3871     eax = MEM32(eax + 0x78); /* 0x3802C87C: mov eax, dword ptr [eax + 0x78] */
   3872     /* cmp eax, edi */ /* 0x3802C87F: cmp eax, edi */
   3873     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   3874     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3875     _flag_k = FK_CMP;
   3876     MEM32(ebp + (-0xC8)) = eax; /* 0x3802C881: mov dword ptr [ebp - 0xc8], eax */
   3877     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C8B4; /* 0x3802C887: je 0x3802c8b4 */
   3878 L_3802C889:
   3879     ecx = ebp + (-0x48); /* 0x3802C889: lea ecx, [ebp - 0x48] */
   3880     PUSH32(esp, ecx); /* 0x3802C88C: push ecx */
   3881     PUSH32(esp, eax); /* 0x3802C88D: push eax */
   3882     RECOMP_ICALL(0x3802C240u); /* 0x3802C88E: call 0x3802c240 */ /* not lifted */
   3883     RECOMP_FLAGS_IN();
   3884     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   3885     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   3886     esp = esp + 8; /* 0x3802C893: add esp, 8 */
   3887     _flag_k = FK_ADD;
   3888     /* test LO8(eax), LO8(eax) */ /* 0x3802C896: test al, al */
   3889     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   3890     _cf = 0;
   3891     _flag_k = FK_NARROW(FK_TEST, 24);
   3892     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802C8B4; /* 0x3802C898: jne 0x3802c8b4 */
   3893 L_3802C89A:
   3894     eax = MEM32(ebp + (-0x44)); /* 0x3802C89A: mov eax, dword ptr [ebp - 0x44] */
   3895     edx = ebp + (-0xC8); /* 0x3802C89D: lea edx, [ebp - 0xc8] */
   3896     PUSH32(esp, edx); /* 0x3802C8A3: push edx */
   3897     PUSH32(esp, eax); /* 0x3802C8A4: push eax */
   3898     ecx = ebp + (-0x144); /* 0x3802C8A5: lea ecx, [ebp - 0x144] */
   3899     PUSH32(esp, ecx); /* 0x3802C8AB: push ecx */
   3900     ecx = ebp + (-0x48); /* 0x3802C8AC: lea ecx, [ebp - 0x48] */
   3901     RECOMP_ICALL(0x3801CB70u); /* 0x3802C8AF: call 0x3801cb70 */ /* not lifted */
   3902     RECOMP_FLAGS_IN();
   3903 L_3802C8B4:
   3904     eax = MEM32(ebp + (-0x3C)); /* 0x3802C8B4: mov eax, dword ptr [ebp - 0x3c] */
   3905     /* cmp esi, eax */ /* 0x3802C8B7: cmp esi, eax */
   3906     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   3907     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3908     _flag_k = FK_CMP;
   3909     MEM32(ebp + (-0x70)) = eax; /* 0x3802C8B9: mov dword ptr [ebp - 0x70], eax */
   3910     if (CMP_GE(_flag_a, _flag_b)) goto L_3802C8C3; /* 0x3802C8BC: jge 0x3802c8c3 */
   3911 L_3802C8BE:
   3912     MEM32(ebp + (-0x70)) = esi; /* 0x3802C8BE: mov dword ptr [ebp - 0x70], esi */
   3913     ebx = eax; /* 0x3802C8C1: mov ebx, eax */
   3914 L_3802C8C3:
   3915     esi = MEM32(ebp + (-0x78)); /* 0x3802C8C3: mov esi, dword ptr [ebp - 0x78] */
   3916     ecx = MEM32(esi + 0x48); /* 0x3802C8C6: mov ecx, dword ptr [esi + 0x48] */
   3917     edx = ebp + (-0x70); /* 0x3802C8C9: lea edx, [ebp - 0x70] */
   3918     PUSH32(esp, edx); /* 0x3802C8CC: push edx */
   3919     eax = ebp + (-0x148); /* 0x3802C8CD: lea eax, [ebp - 0x148] */
   3920     PUSH32(esp, eax); /* 0x3802C8D3: push eax */
   3921     RECOMP_ICALL(0x38027C40u); /* 0x3802C8D4: call 0x38027c40 */ /* not lifted */
   3922     RECOMP_FLAGS_IN();
   3923     ecx = MEM32(esi + 0x48); /* 0x3802C8D9: mov ecx, dword ptr [esi + 0x48] */
   3924     eax = MEM32(eax); /* 0x3802C8DC: mov eax, dword ptr [eax] */
   3925     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802C8DE: cmp eax, dword ptr [ecx + 4] */
   3926     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   3927     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3928     _flag_k = FK_CMP;
   3929     if (CMP_NE(_flag_a, _flag_b)) goto L_3802C97A; /* 0x3802C8E1: jne 0x3802c97a */
   3930 L_3802C8E7:
   3931     PUSH32(esp, 0x10u); /* 0x3802C8E7: push 0x10 */
   3932     RECOMP_ICALL(0x3804B676u); /* 0x3802C8E9: call 0x3804b676 */ /* not lifted */
   3933     RECOMP_FLAGS_IN();
   3934     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   3935     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   3936     esp = esp + 4; /* 0x3802C8EE: add esp, 4 */
   3937     _flag_k = FK_ADD;
   3938     /* cmp eax, edi */ /* 0x3802C8F1: cmp eax, edi */
   3939     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   3940     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3941     _flag_k = FK_CMP;
   3942     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C905; /* 0x3802C8F3: je 0x3802c905 */
   3943 L_3802C8F5:
   3944     SET_LO8(ecx, MEM8(ebp + (-0xD))); /* 0x3802C8F5: mov cl, byte ptr [ebp - 0xd] */
   3945     MEM8(eax) = (uint8_t)(LO8(ecx)); /* 0x3802C8F8: mov byte ptr [eax], cl */
   3946     MEM32(eax + 0x4) = edi; /* 0x3802C8FA: mov dword ptr [eax + 4], edi */
   3947     MEM32(eax + 0x8) = edi; /* 0x3802C8FD: mov dword ptr [eax + 8], edi */
   3948     MEM32(eax + 0xC) = edi; /* 0x3802C900: mov dword ptr [eax + 0xc], edi */
   3949     goto L_3802C907; /* 0x3802C903: jmp 0x3802c907 */
   3950 L_3802C905:
   3951     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3952     eax = 0; /* 0x3802C905: xor eax, eax */
   3953     _cf = 0;
   3954     _flag_k = FK_TEST;
   3955 L_3802C907:
   3956     edx = MEM32(ebp + (-0x70)); /* 0x3802C907: mov edx, dword ptr [ebp - 0x70] */
   3957     ecx = MEM32(esi + 0x48); /* 0x3802C90A: mov ecx, dword ptr [esi + 0x48] */
   3958     MEM32(ebp + (-0xEC)) = eax; /* 0x3802C90D: mov dword ptr [ebp - 0xec], eax */
   3959     eax = ebp + (-0xF0); /* 0x3802C913: lea eax, [ebp - 0xf0] */
   3960     MEM32(ebp + (-0xF0)) = edx; /* 0x3802C919: mov dword ptr [ebp - 0xf0], edx */
   3961     PUSH32(esp, eax); /* 0x3802C91F: push eax */
   3962     edx = ebp + (-0x16C); /* 0x3802C920: lea edx, [ebp - 0x16c] */
   3963     PUSH32(esp, edx); /* 0x3802C926: push edx */
   3964     RECOMP_ICALL(0x3802DA60u); /* 0x3802C927: call 0x3802da60 */ /* not lifted */
   3965     RECOMP_FLAGS_IN();
   3966     esi = MEM32(eax); /* 0x3802C92C: mov esi, dword ptr [eax] */
   3967     eax = MEM32(eax + 0x4); /* 0x3802C92E: mov eax, dword ptr [eax + 4] */
   3968     MEM32(ebp + (-0xB4)) = eax; /* 0x3802C931: mov dword ptr [ebp - 0xb4], eax */
   3969     eax = (int32_t)(int16_t)LO16(ebx); /* 0x3802C937: movsx eax, bx */
   3970     ecx = ebp + (-0xE8); /* 0x3802C93A: lea ecx, [ebp - 0xe8] */
   3971     PUSH32(esp, ecx); /* 0x3802C940: push ecx */
   3972     ecx = ebp + (-0x150); /* 0x3802C941: lea ecx, [ebp - 0x150] */
   3973     MEM32(ebp + (-0xE8)) = edi; /* 0x3802C947: mov dword ptr [ebp - 0xe8], edi */
   3974     MEM32(ebp + (-0xE4)) = edi; /* 0x3802C94D: mov dword ptr [ebp - 0xe4], edi */
   3975     MEM32(ebp + (-0x158)) = eax; /* 0x3802C953: mov dword ptr [ebp - 0x158], eax */
   3976     MEM8(ebp + (-0x154)) = (uint8_t)(0); /* 0x3802C959: mov byte ptr [ebp - 0x154], 0 */
   3977     RECOMP_ICALL(0x3801E100u); /* 0x3802C960: call 0x3801e100 */ /* not lifted */
   3978     RECOMP_FLAGS_IN();
   3979     ecx = MEM32(esi + 0x10); /* 0x3802C965: mov ecx, dword ptr [esi + 0x10] */
   3980     eax = MEM32(ecx + 0x8); /* 0x3802C968: mov eax, dword ptr [ecx + 8] */
   3981     edx = ebp + (-0x158); /* 0x3802C96B: lea edx, [ebp - 0x158] */
   3982     PUSH32(esp, edx); /* 0x3802C971: push edx */
   3983     PUSH32(esp, eax); /* 0x3802C972: push eax */
   3984     RECOMP_ICALL(0x3802DD60u); /* 0x3802C973: call 0x3802dd60 */ /* not lifted */
   3985     RECOMP_FLAGS_IN();
   3986     goto L_3802C9EB; /* 0x3802C978: jmp 0x3802c9eb */
   3987 L_3802C97A:
   3988     ecx = MEM32(eax + 0x10); /* 0x3802C97A: mov ecx, dword ptr [eax + 0x10] */
   3989     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3990     esi = 0; /* 0x3802C97D: xor esi, esi */
   3991     _cf = 0;
   3992     _flag_k = FK_TEST;
   3993     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   3994     edx = 0; /* 0x3802C97F: xor edx, edx */
   3995     _cf = 0;
   3996     _flag_k = FK_TEST;
   3997 L_3802C981:
   3998     eax = MEM32(ecx + 0x4); /* 0x3802C981: mov eax, dword ptr [ecx + 4] */
   3999     /* cmp eax, edi */ /* 0x3802C984: cmp eax, edi */
   4000     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   4001     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4002     _flag_k = FK_CMP;
   4003     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C9A6; /* 0x3802C986: je 0x3802c9a6 */
   4004 L_3802C988:
   4005     edi = MEM32(ecx + 0x8); /* 0x3802C988: mov edi, dword ptr [ecx + 8] */
   4006     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   4007     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4008     edi = edi - eax; /* 0x3802C98B: sub edi, eax */
   4009     _flag_k = FK_CMP;
   4010     if (4u) _cf = (((edi) >> 3) & 1u); /* 0x3802C98D: sar edi, 4 */
   4011     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edi >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   4012     edi = (uint32_t)((int32_t)edi >> 4u);
   4013     /* cmp esi, edi */ /* 0x3802C990: cmp esi, edi */
   4014     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edi);
   4015     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4016     _flag_k = FK_CMP;
   4017     if (CMP_AE(_flag_a, _flag_b)) goto L_3802C9A4; /* 0x3802C992: jae 0x3802c9a4 */
   4018 L_3802C994:
   4019     edi = (int32_t)(int16_t)LO16(ebx); /* 0x3802C994: movsx edi, bx */
   4020     /* cmp MEM32(edx + eax), edi */ /* 0x3802C997: cmp dword ptr [edx + eax], edi */
   4021     _flag_a = (uint32_t)(MEM32(edx + eax)); _flag_b = (uint32_t)(edi);
   4022     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4023     _flag_k = FK_CMP;
   4024     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802C9A4; /* 0x3802C99A: je 0x3802c9a4 */
   4025 L_3802C99C:
   4026     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1);
   4027     esi = esi + 1; /* 0x3802C99C: inc esi */
   4028     _flag_k = FK_INC;
   4029     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u);
   4030     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4031     edx = edx + 0x10u; /* 0x3802C99D: add edx, 0x10 */
   4032     _flag_k = FK_ADD;
   4033     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4034     edi = 0; /* 0x3802C9A0: xor edi, edi */
   4035     _cf = 0;
   4036     _flag_k = FK_TEST;
   4037     RECOMP_BACKEDGE();
   4038     goto L_3802C981; /* 0x3802C9A2: jmp 0x3802c981 */
   4039 L_3802C9A4:
   4040     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4041     edi = 0; /* 0x3802C9A4: xor edi, edi */
   4042     _cf = 0;
   4043     _flag_k = FK_TEST;
   4044 L_3802C9A6:
   4045     edx = MEM32(ecx + 0x4); /* 0x3802C9A6: mov edx, dword ptr [ecx + 4] */
   4046     /* cmp edx, edi */ /* 0x3802C9A9: cmp edx, edi */
   4047     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edi);
   4048     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4049     _flag_k = FK_CMP;
   4050     if (CMP_NE(_flag_a, _flag_b)) goto L_3802C9B1; /* 0x3802C9AB: jne 0x3802c9b1 */
   4051 L_3802C9AD:
   4052     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4053     eax = 0; /* 0x3802C9AD: xor eax, eax */
   4054     _cf = 0;
   4055     _flag_k = FK_TEST;
   4056     goto L_3802C9B9; /* 0x3802C9AF: jmp 0x3802c9b9 */
   4057 L_3802C9B1:
   4058     eax = MEM32(ecx + 0x8); /* 0x3802C9B1: mov eax, dword ptr [ecx + 8] */
   4059     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   4060     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4061     eax = eax - edx; /* 0x3802C9B4: sub eax, edx */
   4062     _flag_k = FK_CMP;
   4063     if (4u) _cf = (((eax) >> 3) & 1u); /* 0x3802C9B6: sar eax, 4 */
   4064     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   4065     eax = (uint32_t)((int32_t)eax >> 4u);
   4066 L_3802C9B9:
   4067     /* cmp esi, eax */ /* 0x3802C9B9: cmp esi, eax */
   4068     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   4069     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4070     _flag_k = FK_CMP;
   4071     if (CMP_NE(_flag_a, _flag_b)) goto L_3802C9EB; /* 0x3802C9BB: jne 0x3802c9eb */
   4072 L_3802C9BD:
   4073     eax = (int32_t)(int16_t)LO16(ebx); /* 0x3802C9BD: movsx eax, bx */
   4074     edx = ebp + (-0x120); /* 0x3802C9C0: lea edx, [ebp - 0x120] */
   4075     PUSH32(esp, edx); /* 0x3802C9C6: push edx */
   4076     MEM32(ebp + (-0x120)) = eax; /* 0x3802C9C7: mov dword ptr [ebp - 0x120], eax */
   4077     MEM8(ebp + (-0x11C)) = (uint8_t)(0); /* 0x3802C9CD: mov byte ptr [ebp - 0x11c], 0 */
   4078     MEM32(ebp + (-0x118)) = edi; /* 0x3802C9D4: mov dword ptr [ebp - 0x118], edi */
   4079     MEM32(ebp + (-0x114)) = edi; /* 0x3802C9DA: mov dword ptr [ebp - 0x114], edi */
   4080     eax = MEM32(ecx + 0x8); /* 0x3802C9E0: mov eax, dword ptr [ecx + 8] */
   4081     PUSH32(esp, 1); /* 0x3802C9E3: push 1 */
   4082     PUSH32(esp, eax); /* 0x3802C9E5: push eax */
   4083     RECOMP_ICALL(0x3802E830u); /* 0x3802C9E6: call 0x3802e830 */ /* not lifted */
   4084     RECOMP_FLAGS_IN();
   4085 L_3802C9EB:
   4086     ecx = MEM32(ebp + (-0x54)); /* 0x3802C9EB: mov ecx, dword ptr [ebp - 0x54] */
   4087 L_3802C9EE:
   4088     esi = MEM32(ebp + (-0x34)); /* 0x3802C9EE: mov esi, dword ptr [ebp - 0x34] */
   4089 L_3802C9F1:
   4090     eax = MEM32(ebp + (-0x14)); /* 0x3802C9F1: mov eax, dword ptr [ebp - 0x14] */
   4091     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4092     edx = 0; /* 0x3802C9F4: xor edx, edx */
   4093     _cf = 0;
   4094     _flag_k = FK_TEST;
   4095     SET_LO16(edx, MEM16(esi + 0x7C)); /* 0x3802C9F6: mov dx, word ptr [esi + 0x7c] */
   4096     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   4097     eax = eax + 1; /* 0x3802C9FA: inc eax */
   4098     _flag_k = FK_INC;
   4099     MEM32(ebp + (-0x14)) = eax; /* 0x3802C9FB: mov dword ptr [ebp - 0x14], eax */
   4100     /* cmp eax, edx */ /* 0x3802C9FE: cmp eax, edx */
   4101     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   4102     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4103     _flag_k = FK_CMP;
   4104     RECOMP_BACKEDGE();
   4105     if (CMP_L(_flag_a, _flag_b)) goto L_3802C818; /* 0x3802CA00: jl 0x3802c818 */
   4106 L_3802CA06:
   4107     /* cmp MEM32(ebp + (-0x40)), 2 */ /* 0x3802CA06: cmp dword ptr [ebp - 0x40], 2 */
   4108     _flag_a = (uint32_t)(MEM32(ebp + (-0x40))); _flag_b = (uint32_t)(2);
   4109     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4110     _flag_k = FK_CMP;
   4111     if (CMP_B(_flag_a, _flag_b)) goto L_3802CB3A; /* 0x3802CA0A: jb 0x3802cb3a */
   4112 L_3802CA10:
   4113     eax = ebp + (-0x48); /* 0x3802CA10: lea eax, [ebp - 0x48] */
   4114     PUSH32(esp, eax); /* 0x3802CA13: push eax */
   4115     ecx = ebp + (-0x88); /* 0x3802CA14: lea ecx, [ebp - 0x88] */
   4116     RECOMP_ICALL(0x3802D500u); /* 0x3802CA1A: call 0x3802d500 */ /* not lifted */
   4117     RECOMP_FLAGS_IN();
   4118     PUSH32(esp, 0x3801C720u); /* 0x3802CA1F: push 0x3801c720 */
   4119     PUSH32(esp, 0x3802D530u); /* 0x3802CA24: push 0x3802d530 */
   4120     PUSH32(esp, 0x10u); /* 0x3802CA29: push 0x10 */
   4121     PUSH32(esp, 0xCu); /* 0x3802CA2B: push 0xc */
   4122     ecx = ebp + (-0x268); /* 0x3802CA2D: lea ecx, [ebp - 0x268] */
   4123     PUSH32(esp, ecx); /* 0x3802CA33: push ecx */
   4124     MEM8(ebp + (-0x4)) = (uint8_t)(4); /* 0x3802CA34: mov byte ptr [ebp - 4], 4 */
   4125     RECOMP_ICALL(0x3804B6CFu); /* 0x3802CA38: call 0x3804b6cf */ /* not lifted */
   4126     RECOMP_FLAGS_IN();
   4127     eax = MEM32(ebp + (-0x40)); /* 0x3802CA3D: mov eax, dword ptr [ebp - 0x40] */
   4128     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4129     ebx = 0; /* 0x3802CA40: xor ebx, ebx */
   4130     _cf = 0;
   4131     _flag_k = FK_TEST;
   4132     /* cmp eax, edi */ /* 0x3802CA42: cmp eax, edi */
   4133     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   4134     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4135     _flag_k = FK_CMP;
   4136     MEM8(ebp + (-0x4)) = (uint8_t)(5); /* 0x3802CA44: mov byte ptr [ebp - 4], 5 */
   4137     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802CB12; /* 0x3802CA48: je 0x3802cb12 */
   4138 L_3802CA4E:
   4139     goto L_3802CA52; /* 0x3802CA4E: jmp 0x3802ca52 */
   4140 L_3802CA50:
   4141     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4142     edi = 0; /* 0x3802CA50: xor edi, edi */
   4143     _cf = 0;
   4144     _flag_k = FK_TEST;
   4145 L_3802CA52:
   4146     edx = MEM32(ebp + (-0x44)); /* 0x3802CA52: mov edx, dword ptr [ebp - 0x44] */
   4147     eax = MEM32(edx); /* 0x3802CA55: mov eax, dword ptr [edx] */
   4148     PUSH32(esp, eax); /* 0x3802CA57: push eax */
   4149     eax = ebp + (-0x48); /* 0x3802CA58: lea eax, [ebp - 0x48] */
   4150     PUSH32(esp, eax); /* 0x3802CA5B: push eax */
   4151     ecx = ebp + (-0x140); /* 0x3802CA5C: lea ecx, [ebp - 0x140] */
   4152     PUSH32(esp, ecx); /* 0x3802CA62: push ecx */
   4153     ecx = ebp + (-0x88); /* 0x3802CA63: lea ecx, [ebp - 0x88] */
   4154     RECOMP_ICALL(0x380354C0u); /* 0x3802CA69: call 0x380354c0 */ /* not lifted */
   4155     RECOMP_FLAGS_IN();
   4156     edx = MEM32(eax); /* 0x3802CA6E: mov edx, dword ptr [eax] */
   4157     PUSH32(esp, edx); /* 0x3802CA70: push edx */
   4158     ecx = ebp + (-0x88); /* 0x3802CA71: lea ecx, [ebp - 0x88] */
   4159     RECOMP_ICALL(0x3802DFD0u); /* 0x3802CA77: call 0x3802dfd0 */ /* not lifted */
   4160     RECOMP_FLAGS_IN();
   4161     /* test ebx, ebx */ /* 0x3802CA7C: test ebx, ebx */
   4162     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(ebx);
   4163     _cf = 0;
   4164     _flag_k = FK_TEST;
   4165     if (TEST_Z(_flag_a, _flag_b)) goto L_3802CACA; /* 0x3802CA7E: jbe 0x3802caca */
   4166 L_3802CA80:
   4167     esi = ebp + (-0x268); /* 0x3802CA80: lea esi, [ebp - 0x268] */
   4168 L_3802CA86:
   4169     eax = MEM32(esi + 0x8); /* 0x3802CA86: mov eax, dword ptr [esi + 8] */
   4170     /* test eax, eax */ /* 0x3802CA89: test eax, eax */
   4171     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   4172     _cf = 0;
   4173     _flag_k = FK_TEST;
   4174     if (TEST_Z(_flag_a, _flag_b)) goto L_3802CAB1; /* 0x3802CA8B: je 0x3802cab1 */
   4175 L_3802CA8D:
   4176     eax = ebp + (-0x88); /* 0x3802CA8D: lea eax, [ebp - 0x88] */
   4177     PUSH32(esp, eax); /* 0x3802CA93: push eax */
   4178     ecx = esi; /* 0x3802CA94: mov ecx, esi */
   4179     RECOMP_ICALL(0x3802E030u); /* 0x3802CA96: call 0x3802e030 */ /* not lifted */
   4180     RECOMP_FLAGS_IN();
   4181     ecx = ebp + (-0x88); /* 0x3802CA9B: lea ecx, [ebp - 0x88] */
   4182     PUSH32(esp, ecx); /* 0x3802CAA1: push ecx */
   4183     ecx = esi; /* 0x3802CAA2: mov ecx, esi */
   4184     RECOMP_ICALL(0x3802DFA0u); /* 0x3802CAA4: call 0x3802dfa0 */ /* not lifted */
   4185     RECOMP_FLAGS_IN();
   4186     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(1);
   4187     edi = edi + 1; /* 0x3802CAA9: inc edi */
   4188     _flag_k = FK_INC;
   4189     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0xCu);
   4190     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4191     esi = esi + 0xCu; /* 0x3802CAAA: add esi, 0xc */
   4192     _flag_k = FK_ADD;
   4193     /* cmp edi, ebx */ /* 0x3802CAAD: cmp edi, ebx */
   4194     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
   4195     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4196     _flag_k = FK_CMP;
   4197     RECOMP_BACKEDGE();
   4198     if (CMP_B(_flag_a, _flag_b)) goto L_3802CA86; /* 0x3802CAAF: jb 0x3802ca86 */
   4199 L_3802CAB1:
   4200     /* cmp edi, 0xFu */ /* 0x3802CAB1: cmp edi, 0xf */
   4201     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(0xFu);
   4202     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4203     _flag_k = FK_CMP;
   4204     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CACA; /* 0x3802CAB4: jne 0x3802caca */
   4205 L_3802CAB6:
   4206     edx = ebp + (-0x88); /* 0x3802CAB6: lea edx, [ebp - 0x88] */
   4207     PUSH32(esp, edx); /* 0x3802CABC: push edx */
   4208     ecx = ebp + (-0x1B4); /* 0x3802CABD: lea ecx, [ebp - 0x1b4] */
   4209     RECOMP_ICALL(0x3802E030u); /* 0x3802CAC3: call 0x3802e030 */ /* not lifted */
   4210     RECOMP_FLAGS_IN();
   4211     goto L_3802CAE5; /* 0x3802CAC8: jmp 0x3802cae5 */
   4212 L_3802CACA:
   4213     eax = ebp + (-0x88); /* 0x3802CACA: lea eax, [ebp - 0x88] */
   4214     ecx = edi + edi * 2; /* 0x3802CAD0: lea ecx, [edi + edi*2] */
   4215     PUSH32(esp, eax); /* 0x3802CAD3: push eax */
   4216     ecx = ebp + ecx * 4 + (-0x268); /* 0x3802CAD4: lea ecx, [ebp + ecx*4 - 0x268] */
   4217     RECOMP_ICALL(0x3802DFA0u); /* 0x3802CADB: call 0x3802dfa0 */ /* not lifted */
   4218     RECOMP_FLAGS_IN();
   4219     /* cmp edi, ebx */ /* 0x3802CAE0: cmp edi, ebx */
   4220     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
   4221     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4222     _flag_k = FK_CMP;
   4223     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CAE5; /* 0x3802CAE2: jne 0x3802cae5 */
   4224 L_3802CAE4:
   4225     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(1);
   4226     ebx = ebx + 1; /* 0x3802CAE4: inc ebx */
   4227     _flag_k = FK_INC;
   4228 L_3802CAE5:
   4229     eax = MEM32(ebp + (-0x40)); /* 0x3802CAE5: mov eax, dword ptr [ebp - 0x40] */
   4230     /* test eax, eax */ /* 0x3802CAE8: test eax, eax */
   4231     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   4232     _cf = 0;
   4233     _flag_k = FK_TEST;
   4234     RECOMP_BACKEDGE();
   4235     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802CA50; /* 0x3802CAEA: jne 0x3802ca50 */
   4236 L_3802CAF0:
   4237     /* test ebx, ebx */ /* 0x3802CAF0: test ebx, ebx */
   4238     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(ebx);
   4239     _cf = 0;
   4240     _flag_k = FK_TEST;
   4241     if (TEST_Z(_flag_a, _flag_b)) goto L_3802CB0D; /* 0x3802CAF2: jbe 0x3802cb0d */
   4242 L_3802CAF4:
   4243     edx = ebx + ebx * 2; /* 0x3802CAF4: lea edx, [ebx + ebx*2] */
   4244     esi = ebp + edx * 4 + (-0x268); /* 0x3802CAF7: lea esi, [ebp + edx*4 - 0x268] */
   4245 L_3802CAFE:
   4246     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0xCu);
   4247     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4248     esi = esi - 0xCu; /* 0x3802CAFE: sub esi, 0xc */
   4249     _flag_k = FK_CMP;
   4250     PUSH32(esp, esi); /* 0x3802CB01: push esi */
   4251     ecx = ebp + (-0x48); /* 0x3802CB02: lea ecx, [ebp - 0x48] */
   4252     RECOMP_ICALL(0x3802E030u); /* 0x3802CB05: call 0x3802e030 */ /* not lifted */
   4253     RECOMP_FLAGS_IN();
   4254     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(1);
   4255     ebx = ebx - 1; /* 0x3802CB0A: dec ebx */
   4256     _flag_k = FK_DEC;
   4257     RECOMP_BACKEDGE();
   4258     if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3802CAFE; /* 0x3802CB0B: jne 0x3802cafe */
   4259 L_3802CB0D:
   4260     esi = MEM32(ebp + (-0x34)); /* 0x3802CB0D: mov esi, dword ptr [ebp - 0x34] */
   4261     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4262     edi = 0; /* 0x3802CB10: xor edi, edi */
   4263     _cf = 0;
   4264     _flag_k = FK_TEST;
   4265 L_3802CB12:
   4266     PUSH32(esp, 0x3801C720u); /* 0x3802CB12: push 0x3801c720 */
   4267     PUSH32(esp, 0x10u); /* 0x3802CB17: push 0x10 */
   4268     PUSH32(esp, 0xCu); /* 0x3802CB19: push 0xc */
   4269     eax = ebp + (-0x268); /* 0x3802CB1B: lea eax, [ebp - 0x268] */
   4270     PUSH32(esp, eax); /* 0x3802CB21: push eax */
   4271     MEM8(ebp + (-0x4)) = (uint8_t)(4); /* 0x3802CB22: mov byte ptr [ebp - 4], 4 */
   4272     RECOMP_ICALL(0x3804B582u); /* 0x3802CB26: call 0x3804b582 */ /* not lifted */
   4273     RECOMP_FLAGS_IN();
   4274     ecx = ebp + (-0x88); /* 0x3802CB2B: lea ecx, [ebp - 0x88] */
   4275     MEM8(ebp + (-0x4)) = (uint8_t)(3); /* 0x3802CB31: mov byte ptr [ebp - 4], 3 */
   4276     RECOMP_ICALL(0x3801C720u); /* 0x3802CB35: call 0x3801c720 */ /* not lifted */
   4277     RECOMP_FLAGS_IN();
   4278 L_3802CB3A:
   4279     edx = MEM32(ebp + (-0x44)); /* 0x3802CB3A: mov edx, dword ptr [ebp - 0x44] */
   4280     eax = MEM32(edx); /* 0x3802CB3D: mov eax, dword ptr [edx] */
   4281     /* cmp eax, edx */ /* 0x3802CB3F: cmp eax, edx */
   4282     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   4283     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4284     _flag_k = FK_CMP;
   4285     ecx = 4; /* 0x3802CB41: mov ecx, 4 */
   4286     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802CB56; /* 0x3802CB46: je 0x3802cb56 */
   4287 L_3802CB48:
   4288     /* cmp ecx, MEM32(eax + 0x8) */ /* 0x3802CB48: cmp ecx, dword ptr [eax + 8] */
   4289     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax + 0x8));
   4290     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4291     _flag_k = FK_CMP;
   4292     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CB56; /* 0x3802CB4B: jne 0x3802cb56 */
   4293 L_3802CB4D:
   4294     eax = MEM32(eax); /* 0x3802CB4D: mov eax, dword ptr [eax] */
   4295     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(2);
   4296     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4297     ecx = ecx + 2; /* 0x3802CB4F: add ecx, 2 */
   4298     _flag_k = FK_ADD;
   4299     /* cmp eax, edx */ /* 0x3802CB52: cmp eax, edx */
   4300     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   4301     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4302     _flag_k = FK_CMP;
   4303     RECOMP_BACKEDGE();
   4304     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CB48; /* 0x3802CB54: jne 0x3802cb48 */
   4305 L_3802CB56:
   4306     MEM32(esi + 0x78) = ecx; /* 0x3802CB56: mov dword ptr [esi + 0x78], ecx */
   4307     SET_LO8(ecx, MEM8(ebp + (-0x5C))); /* 0x3802CB59: mov cl, byte ptr [ebp - 0x5c] */
   4308     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x10u);
   4309     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4310     esp = esp - 0x10u; /* 0x3802CB5C: sub esp, 0x10 */
   4311     _flag_k = FK_CMP;
   4312     esi = esp; /* 0x3802CB5F: mov esi, esp */
   4313     MEM8(esi) = (uint8_t)(LO8(ecx)); /* 0x3802CB61: mov byte ptr [esi], cl */
   4314     ecx = MEM32(ebp + (-0x58)); /* 0x3802CB63: mov ecx, dword ptr [ebp - 0x58] */
   4315     /* cmp ecx, edi */ /* 0x3802CB66: cmp ecx, edi */
   4316     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
   4317     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4318     _flag_k = FK_CMP;
   4319     MEM32(ebp + (-0xB4)) = esp; /* 0x3802CB68: mov dword ptr [ebp - 0xb4], esp */
   4320     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CB74; /* 0x3802CB6E: jne 0x3802cb74 */
   4321 L_3802CB70:
   4322     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4323     eax = 0; /* 0x3802CB70: xor eax, eax */
   4324     _cf = 0;
   4325     _flag_k = FK_TEST;
   4326     goto L_3802CB7C; /* 0x3802CB72: jmp 0x3802cb7c */
   4327 L_3802CB74:
   4328     eax = MEM32(ebp + (-0x54)); /* 0x3802CB74: mov eax, dword ptr [ebp - 0x54] */
   4329     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   4330     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4331     eax = eax - ecx; /* 0x3802CB77: sub eax, ecx */
   4332     _flag_k = FK_CMP;
   4333     if (2u) _cf = (((eax) >> 1) & 1u); /* 0x3802CB79: sar eax, 2 */
   4334     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   4335     eax = (uint32_t)((int32_t)eax >> 2u);
   4336 L_3802CB7C:
   4337     /* cmp eax, edi */ /* 0x3802CB7C: cmp eax, edi */
   4338     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   4339     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4340     _flag_k = FK_CMP;
   4341     if (CMP_GE(_flag_a, _flag_b)) goto L_3802CB82; /* 0x3802CB7E: jge 0x3802cb82 */
   4342 L_3802CB80:
   4343     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4344     eax = 0; /* 0x3802CB80: xor eax, eax */
   4345     _cf = 0;
   4346     _flag_k = FK_TEST;
   4347 L_3802CB82:
   4348     edx = eax * 4; /* 0x3802CB82: lea edx, [eax*4] */
   4349     PUSH32(esp, edx); /* 0x3802CB89: push edx */
   4350     RECOMP_ICALL(0x3804B676u); /* 0x3802CB8A: call 0x3804b676 */ /* not lifted */
   4351     RECOMP_FLAGS_IN();
   4352     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   4353     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4354     esp = esp + 4; /* 0x3802CB8F: add esp, 4 */
   4355     _flag_k = FK_ADD;
   4356     PUSH32(esp, eax); /* 0x3802CB92: push eax */
   4357     MEM32(esi + 0x4) = eax; /* 0x3802CB93: mov dword ptr [esi + 4], eax */
   4358     eax = MEM32(ebp + (-0x54)); /* 0x3802CB96: mov eax, dword ptr [ebp - 0x54] */
   4359     ecx = MEM32(ebp + (-0x58)); /* 0x3802CB99: mov ecx, dword ptr [ebp - 0x58] */
   4360     PUSH32(esp, eax); /* 0x3802CB9C: push eax */
   4361     PUSH32(esp, ecx); /* 0x3802CB9D: push ecx */
   4362     ecx = esi; /* 0x3802CB9E: mov ecx, esi */
   4363     RECOMP_ICALL(0x3800A100u); /* 0x3802CBA0: call 0x3800a100 */ /* not lifted */
   4364     RECOMP_FLAGS_IN();
   4365     ecx = MEM32(ebp + (-0x7C)); /* 0x3802CBA5: mov ecx, dword ptr [ebp - 0x7c] */
   4366     edx = ebp + (-0x6C); /* 0x3802CBA8: lea edx, [ebp - 0x6c] */
   4367     MEM32(esi + 0x8) = eax; /* 0x3802CBAB: mov dword ptr [esi + 8], eax */
   4368     MEM32(esi + 0xC) = eax; /* 0x3802CBAE: mov dword ptr [esi + 0xc], eax */
   4369     esi = MEM32(ebp + (-0x3C)); /* 0x3802CBB1: mov esi, dword ptr [ebp - 0x3c] */
   4370     PUSH32(esp, edx); /* 0x3802CBB4: push edx */
   4371     PUSH32(esp, esi); /* 0x3802CBB5: push esi */
   4372     RECOMP_ICALL(MEM32(0x3804E790)); /* 0x3802CBB6: call dword ptr [0x3804e790] */
   4373     RECOMP_FLAGS_IN();
   4374     eax = MEM32(ebp + (-0x58)); /* 0x3802CBBC: mov eax, dword ptr [ebp - 0x58] */
   4375     PUSH32(esp, eax); /* 0x3802CBBF: push eax */
   4376     MEM8(ebp + (-0x4)) = (uint8_t)(2); /* 0x3802CBC0: mov byte ptr [ebp - 4], 2 */
   4377     RECOMP_ICALL(0x3804B4F6u); /* 0x3802CBC4: call 0x3804b4f6 */ /* not lifted */
   4378     RECOMP_FLAGS_IN();
   4379     eax = MEM32(ebp + (-0x4C)); /* 0x3802CBC9: mov eax, dword ptr [ebp - 0x4c] */
   4380     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   4381     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4382     esp = esp + 4; /* 0x3802CBCC: add esp, 4 */
   4383     _flag_k = FK_ADD;
   4384     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1);
   4385     esi = esi + 1; /* 0x3802CBCF: inc esi */
   4386     _flag_k = FK_INC;
   4387     /* cmp esi, eax */ /* 0x3802CBD0: cmp esi, eax */
   4388     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   4389     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4390     _flag_k = FK_CMP;
   4391     MEM32(ebp + (-0x58)) = edi; /* 0x3802CBD2: mov dword ptr [ebp - 0x58], edi */
   4392     MEM32(ebp + (-0x54)) = edi; /* 0x3802CBD5: mov dword ptr [ebp - 0x54], edi */
   4393     MEM32(ebp + (-0x50)) = edi; /* 0x3802CBD8: mov dword ptr [ebp - 0x50], edi */
   4394     MEM32(ebp + (-0x3C)) = esi; /* 0x3802CBDB: mov dword ptr [ebp - 0x3c], esi */
   4395     RECOMP_BACKEDGE();
   4396     if (CMP_B(_flag_a, _flag_b)) goto L_3802C3B4; /* 0x3802CBDE: jb 0x3802c3b4 */
   4397 L_3802CBE4:
   4398     ecx = MEM32(ebp + (-0x7C)); /* 0x3802CBE4: mov ecx, dword ptr [ebp - 0x7c] */
   4399     RECOMP_ICALL(MEM32(0x3804E78C)); /* 0x3802CBE7: call dword ptr [0x3804e78c] */
   4400     RECOMP_FLAGS_IN();
   4401     ecx = MEM32(ebp + (-0x64)); /* 0x3802CBED: mov ecx, dword ptr [ebp - 0x64] */
   4402     edx = MEM32(ebp + (-0x68)); /* 0x3802CBF0: mov edx, dword ptr [ebp - 0x68] */
   4403     PUSH32(esp, ecx); /* 0x3802CBF3: push ecx */
   4404     PUSH32(esp, edx); /* 0x3802CBF4: push edx */
   4405     ecx = ebp + (-0x6C); /* 0x3802CBF5: lea ecx, [ebp - 0x6c] */
   4406     MEM8(ebp + (-0x4)) = (uint8_t)(0); /* 0x3802CBF8: mov byte ptr [ebp - 4], 0 */
   4407     RECOMP_ICALL(0x38042760u); /* 0x3802CBFC: call 0x38042760 */ /* not lifted */
   4408     RECOMP_FLAGS_IN();
   4409     eax = MEM32(ebp + (-0x68)); /* 0x3802CC01: mov eax, dword ptr [ebp - 0x68] */
   4410     PUSH32(esp, eax); /* 0x3802CC04: push eax */
   4411     RECOMP_ICALL(0x3804B4F6u); /* 0x3802CC05: call 0x3804b4f6 */ /* not lifted */
   4412     RECOMP_FLAGS_IN();
   4413     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   4414     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4415     esp = esp + 4; /* 0x3802CC0A: add esp, 4 */
   4416     _flag_k = FK_ADD;
   4417     ecx = ebp + (-0x48); /* 0x3802CC0D: lea ecx, [ebp - 0x48] */
   4418     MEM32(ebp + (-0x68)) = edi; /* 0x3802CC10: mov dword ptr [ebp - 0x68], edi */
   4419     MEM32(ebp + (-0x64)) = edi; /* 0x3802CC13: mov dword ptr [ebp - 0x64], edi */
   4420     MEM32(ebp + (-0x60)) = edi; /* 0x3802CC16: mov dword ptr [ebp - 0x60], edi */
   4421     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3802CC19: mov dword ptr [ebp - 4], 0xffffffff */
   4422     RECOMP_ICALL(0x3801C720u); /* 0x3802CC20: call 0x3801c720 */ /* not lifted */
   4423     RECOMP_FLAGS_IN();
   4424     ecx = MEM32(ebp + (-0xC)); /* 0x3802CC25: mov ecx, dword ptr [ebp - 0xc] */
   4425     edi = POP32_VAL(esp); /* 0x3802CC28: pop edi */
   4426     esi = POP32_VAL(esp); /* 0x3802CC29: pop esi */
   4427     MEM32(FS_BASE + (0)) = ecx; /* 0x3802CC2A: mov dword ptr fs:[0], ecx */
   4428     ebx = POP32_VAL(esp); /* 0x3802CC31: pop ebx */
   4429     esp = ebp; /* 0x3802CC32: mov esp, ebp */
   4430     ebp = POP32_VAL(esp); /* 0x3802CC34: pop ebp */
   4431     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802CC35: ret  */
   4432     RECOMP_REGS_OUT();
   4433 }
   4434 
   4435 void sub_3802CC40(void) {
   4436     int _fpu_cmp = 0;
   4437     uint32_t _cf = 0;
   4438     int _df = 1;
   4439     uint32_t _flag_k = FK_NONE;
   4440     uint32_t _flag_a = 0, _flag_b = 0;
   4441     uint32_t _itail_tgt = 0;
   4442     RECOMP_REGS_LOCALS
   4443     RECOMP_ENTER(0x3802CC40u);
   4444 
   4445 L_3802CC40:
   4446     PUSH32(esp, ebp); /* 0x3802CC40: push ebp */
   4447     ebp = esp; /* 0x3802CC41: mov ebp, esp */
   4448     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   4449     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4450     esp = esp - 8; /* 0x3802CC43: sub esp, 8 */
   4451     _flag_k = FK_CMP;
   4452     PUSH32(esp, esi); /* 0x3802CC46: push esi */
   4453     PUSH32(esp, edi); /* 0x3802CC47: push edi */
   4454     edi = MEM32(ebp + 0x8); /* 0x3802CC48: mov edi, dword ptr [ebp + 8] */
   4455     eax = MEM32(edi + 0xC); /* 0x3802CC4B: mov eax, dword ptr [edi + 0xc] */
   4456     esi = ecx; /* 0x3802CC4E: mov esi, ecx */
   4457     ecx = MEM32(esi + 0x90); /* 0x3802CC50: mov ecx, dword ptr [esi + 0x90] */
   4458     edx = ebp + 0x8; /* 0x3802CC56: lea edx, [ebp + 8] */
   4459     PUSH32(esp, edx); /* 0x3802CC59: push edx */
   4460     MEM32(ebp + 0x8) = eax; /* 0x3802CC5A: mov dword ptr [ebp + 8], eax */
   4461     eax = MEM32(ecx + 0x8); /* 0x3802CC5D: mov eax, dword ptr [ecx + 8] */
   4462     PUSH32(esp, 1); /* 0x3802CC60: push 1 */
   4463     PUSH32(esp, eax); /* 0x3802CC62: push eax */
   4464     RECOMP_ICALL(0x38009C60u); /* 0x3802CC63: call 0x38009c60 */ /* not lifted */
   4465     RECOMP_FLAGS_IN();
   4466     eax = MEM32(esi + 0x88); /* 0x3802CC68: mov eax, dword ptr [esi + 0x88] */
   4467     ecx = MEM32(eax + 0x4); /* 0x3802CC6E: mov ecx, dword ptr [eax + 4] */
   4468     /* test ecx, ecx */ /* 0x3802CC71: test ecx, ecx */
   4469     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   4470     _cf = 0;
   4471     _flag_k = FK_TEST;
   4472     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802CC79; /* 0x3802CC73: jne 0x3802cc79 */
   4473 L_3802CC75:
   4474     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4475     eax = 0; /* 0x3802CC75: xor eax, eax */
   4476     _cf = 0;
   4477     _flag_k = FK_TEST;
   4478     goto L_3802CC81; /* 0x3802CC77: jmp 0x3802cc81 */
   4479 L_3802CC79:
   4480     eax = MEM32(eax + 0x8); /* 0x3802CC79: mov eax, dword ptr [eax + 8] */
   4481     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   4482     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4483     eax = eax - ecx; /* 0x3802CC7C: sub eax, ecx */
   4484     _flag_k = FK_CMP;
   4485     if (2u) _cf = (((eax) >> 1) & 1u); /* 0x3802CC7E: sar eax, 2 */
   4486     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   4487     eax = (uint32_t)((int32_t)eax >> 2u);
   4488 L_3802CC81:
   4489     MEM32(edi + 0xC) = eax; /* 0x3802CC81: mov dword ptr [edi + 0xc], eax */
   4490     esi = MEM32(esi + 0x88); /* 0x3802CC84: mov esi, dword ptr [esi + 0x88] */
   4491     MEM32(ebp + 0x8) = edi; /* 0x3802CC8A: mov dword ptr [ebp + 8], edi */
   4492     eax = MEM32(esi + 0x8); /* 0x3802CC8D: mov eax, dword ptr [esi + 8] */
   4493     ecx = MEM32(esi + 0xC); /* 0x3802CC90: mov ecx, dword ptr [esi + 0xc] */
   4494     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
   4495     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4496     ecx = ecx - eax; /* 0x3802CC93: sub ecx, eax */
   4497     _flag_k = FK_CMP;
   4498     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3802CC95: sar ecx, 2 */
   4499     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   4500     ecx = (uint32_t)((int32_t)ecx >> 2u);
   4501     /* cmp ecx, 1 */ /* 0x3802CC98: cmp ecx, 1 */
   4502     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   4503     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4504     _flag_k = FK_CMP;
   4505     edi = eax; /* 0x3802CC9B: mov edi, eax */
   4506     if (CMP_AE(_flag_a, _flag_b)) goto L_3802CD49; /* 0x3802CC9D: jae 0x3802cd49 */
   4507 L_3802CCA3:
   4508     edx = MEM32(esi + 0x4); /* 0x3802CCA3: mov edx, dword ptr [esi + 4] */
   4509     /* test edx, edx */ /* 0x3802CCA6: test edx, edx */
   4510     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   4511     _cf = 0;
   4512     _flag_k = FK_TEST;
   4513     if (TEST_Z(_flag_a, _flag_b)) goto L_3802CCB6; /* 0x3802CCA8: je 0x3802ccb6 */
   4514 L_3802CCAA:
   4515     ecx = eax; /* 0x3802CCAA: mov ecx, eax */
   4516     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   4517     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4518     ecx = ecx - edx; /* 0x3802CCAC: sub ecx, edx */
   4519     _flag_k = FK_CMP;
   4520     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3802CCAE: sar ecx, 2 */
   4521     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   4522     ecx = (uint32_t)((int32_t)ecx >> 2u);
   4523     /* cmp ecx, 1 */ /* 0x3802CCB1: cmp ecx, 1 */
   4524     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   4525     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4526     _flag_k = FK_CMP;
   4527     if (CMP_A(_flag_a, _flag_b)) goto L_3802CCBB; /* 0x3802CCB4: ja 0x3802ccbb */
   4528 L_3802CCB6:
   4529     ecx = 1; /* 0x3802CCB6: mov ecx, 1 */
   4530 L_3802CCBB:
   4531     /* test edx, edx */ /* 0x3802CCBB: test edx, edx */
   4532     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   4533     _cf = 0;
   4534     _flag_k = FK_TEST;
   4535     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802CCC3; /* 0x3802CCBD: jne 0x3802ccc3 */
   4536 L_3802CCBF:
   4537     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4538     eax = 0; /* 0x3802CCBF: xor eax, eax */
   4539     _cf = 0;
   4540     _flag_k = FK_TEST;
   4541     goto L_3802CCC8; /* 0x3802CCC1: jmp 0x3802ccc8 */
   4542 L_3802CCC3:
   4543     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   4544     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4545     eax = eax - edx; /* 0x3802CCC3: sub eax, edx */
   4546     _flag_k = FK_CMP;
   4547     if (2u) _cf = (((eax) >> 1) & 1u); /* 0x3802CCC5: sar eax, 2 */
   4548     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   4549     eax = (uint32_t)((int32_t)eax >> 2u);
   4550 L_3802CCC8:
   4551     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   4552     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4553     eax = eax + ecx; /* 0x3802CCC8: add eax, ecx */
   4554     _flag_k = FK_ADD;
   4555     /* test eax, eax */ /* 0x3802CCCA: test eax, eax */
   4556     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   4557     _cf = 0;
   4558     _flag_k = FK_TEST;
   4559     MEM32(ebp + (-0x8)) = eax; /* 0x3802CCCC: mov dword ptr [ebp - 8], eax */
   4560     if (TEST_NS(_flag_a, _flag_b)) goto L_3802CCD3; /* 0x3802CCCF: jge 0x3802ccd3 */
   4561 L_3802CCD1:
   4562     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4563     eax = 0; /* 0x3802CCD1: xor eax, eax */
   4564     _cf = 0;
   4565     _flag_k = FK_TEST;
   4566 L_3802CCD3:
   4567     edx = eax * 4; /* 0x3802CCD3: lea edx, [eax*4] */
   4568     PUSH32(esp, ebx); /* 0x3802CCDA: push ebx */
   4569     PUSH32(esp, edx); /* 0x3802CCDB: push edx */
   4570     RECOMP_ICALL(0x3804B676u); /* 0x3802CCDC: call 0x3804b676 */ /* not lifted */
   4571     RECOMP_FLAGS_IN();
   4572     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   4573     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4574     esp = esp + 4; /* 0x3802CCE1: add esp, 4 */
   4575     _flag_k = FK_ADD;
   4576     ebx = eax; /* 0x3802CCE4: mov ebx, eax */
   4577     eax = MEM32(esi + 0x4); /* 0x3802CCE6: mov eax, dword ptr [esi + 4] */
   4578     PUSH32(esp, ebx); /* 0x3802CCE9: push ebx */
   4579     PUSH32(esp, edi); /* 0x3802CCEA: push edi */
   4580     PUSH32(esp, eax); /* 0x3802CCEB: push eax */
   4581     ecx = esi; /* 0x3802CCEC: mov ecx, esi */
   4582     RECOMP_ICALL(0x3800A100u); /* 0x3802CCEE: call 0x3800a100 */ /* not lifted */
   4583     RECOMP_FLAGS_IN();
   4584     ecx = ebp + 0x8; /* 0x3802CCF3: lea ecx, [ebp + 8] */
   4585     PUSH32(esp, ecx); /* 0x3802CCF6: push ecx */
   4586     PUSH32(esp, 1); /* 0x3802CCF7: push 1 */
   4587     PUSH32(esp, eax); /* 0x3802CCF9: push eax */
   4588     ecx = esi; /* 0x3802CCFA: mov ecx, esi */
   4589     MEM32(ebp + (-0x4)) = eax; /* 0x3802CCFC: mov dword ptr [ebp - 4], eax */
   4590     RECOMP_ICALL(0x3800FE10u); /* 0x3802CCFF: call 0x3800fe10 */ /* not lifted */
   4591     RECOMP_FLAGS_IN();
   4592     edx = MEM32(ebp + (-0x4)); /* 0x3802CD04: mov edx, dword ptr [ebp - 4] */
   4593     eax = MEM32(esi + 0x8); /* 0x3802CD07: mov eax, dword ptr [esi + 8] */
   4594     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(4);
   4595     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4596     edx = edx + 4; /* 0x3802CD0A: add edx, 4 */
   4597     _flag_k = FK_ADD;
   4598     PUSH32(esp, edx); /* 0x3802CD0D: push edx */
   4599     PUSH32(esp, eax); /* 0x3802CD0E: push eax */
   4600     PUSH32(esp, edi); /* 0x3802CD0F: push edi */
   4601     ecx = esi; /* 0x3802CD10: mov ecx, esi */
   4602     RECOMP_ICALL(0x3800A100u); /* 0x3802CD12: call 0x3800a100 */ /* not lifted */
   4603     RECOMP_FLAGS_IN();
   4604     eax = MEM32(esi + 0x4); /* 0x3802CD17: mov eax, dword ptr [esi + 4] */
   4605     PUSH32(esp, eax); /* 0x3802CD1A: push eax */
   4606     MEM32(ebp + (-0x4)) = eax; /* 0x3802CD1B: mov dword ptr [ebp - 4], eax */
   4607     RECOMP_ICALL(0x3804B4F6u); /* 0x3802CD1E: call 0x3804b4f6 */ /* not lifted */
   4608     RECOMP_FLAGS_IN();
   4609     ecx = MEM32(ebp + (-0x8)); /* 0x3802CD23: mov ecx, dword ptr [ebp - 8] */
   4610     edx = ebx + ecx * 4; /* 0x3802CD26: lea edx, [ebx + ecx*4] */
   4611     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   4612     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4613     esp = esp + 4; /* 0x3802CD29: add esp, 4 */
   4614     _flag_k = FK_ADD;
   4615     ecx = esi; /* 0x3802CD2C: mov ecx, esi */
   4616     MEM32(esi + 0xC) = edx; /* 0x3802CD2E: mov dword ptr [esi + 0xc], edx */
   4617     RECOMP_ICALL(0x3802D4B0u); /* 0x3802CD31: call 0x3802d4b0 */ /* not lifted */
   4618     RECOMP_FLAGS_IN();
   4619     eax = ebx + eax * 4 + 0x4; /* 0x3802CD36: lea eax, [ebx + eax*4 + 4] */
   4620     MEM32(esi + 0x4) = ebx; /* 0x3802CD3A: mov dword ptr [esi + 4], ebx */
   4621     ebx = POP32_VAL(esp); /* 0x3802CD3D: pop ebx */
   4622     edi = POP32_VAL(esp); /* 0x3802CD3E: pop edi */
   4623     MEM32(esi + 0x8) = eax; /* 0x3802CD3F: mov dword ptr [esi + 8], eax */
   4624     esi = POP32_VAL(esp); /* 0x3802CD42: pop esi */
   4625     esp = ebp; /* 0x3802CD43: mov esp, ebp */
   4626     ebp = POP32_VAL(esp); /* 0x3802CD45: pop ebp */
   4627     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802CD46: ret 4 */
   4628 L_3802CD49:
   4629     ecx = eax; /* 0x3802CD49: mov ecx, eax */
   4630     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
   4631     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4632     ecx = ecx - edi; /* 0x3802CD4B: sub ecx, edi */
   4633     _flag_k = FK_CMP;
   4634     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3802CD4D: sar ecx, 2 */
   4635     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   4636     ecx = (uint32_t)((int32_t)ecx >> 2u);
   4637     /* cmp ecx, 1 */ /* 0x3802CD50: cmp ecx, 1 */
   4638     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   4639     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4640     _flag_k = FK_CMP;
   4641     if (CMP_AE(_flag_a, _flag_b)) goto L_3802CDA4; /* 0x3802CD53: jae 0x3802cda4 */
   4642 L_3802CD55:
   4643     edx = edi + 0x4; /* 0x3802CD55: lea edx, [edi + 4] */
   4644     PUSH32(esp, edx); /* 0x3802CD58: push edx */
   4645     PUSH32(esp, eax); /* 0x3802CD59: push eax */
   4646     PUSH32(esp, edi); /* 0x3802CD5A: push edi */
   4647     ecx = esi; /* 0x3802CD5B: mov ecx, esi */
   4648     RECOMP_ICALL(0x3800A100u); /* 0x3802CD5D: call 0x3800a100 */ /* not lifted */
   4649     RECOMP_FLAGS_IN();
   4650     eax = MEM32(esi + 0x8); /* 0x3802CD62: mov eax, dword ptr [esi + 8] */
   4651     edx = eax; /* 0x3802CD65: mov edx, eax */
   4652     ecx = ebp + 0x8; /* 0x3802CD67: lea ecx, [ebp + 8] */
   4653     PUSH32(esp, ecx); /* 0x3802CD6A: push ecx */
   4654     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edi);
   4655     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4656     edx = edx - edi; /* 0x3802CD6B: sub edx, edi */
   4657     _flag_k = FK_CMP;
   4658     if (2u) _cf = (((edx) >> 1) & 1u); /* 0x3802CD6D: sar edx, 2 */
   4659     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   4660     edx = (uint32_t)((int32_t)edx >> 2u);
   4661     ecx = 1; /* 0x3802CD70: mov ecx, 1 */
   4662     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   4663     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4664     ecx = ecx - edx; /* 0x3802CD75: sub ecx, edx */
   4665     _flag_k = FK_CMP;
   4666     PUSH32(esp, ecx); /* 0x3802CD77: push ecx */
   4667     PUSH32(esp, eax); /* 0x3802CD78: push eax */
   4668     ecx = esi; /* 0x3802CD79: mov ecx, esi */
   4669     RECOMP_ICALL(0x3800FE10u); /* 0x3802CD7B: call 0x3800fe10 */ /* not lifted */
   4670     RECOMP_FLAGS_IN();
   4671     eax = MEM32(esi + 0x8); /* 0x3802CD80: mov eax, dword ptr [esi + 8] */
   4672     /* cmp edi, eax */ /* 0x3802CD83: cmp edi, eax */
   4673     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   4674     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4675     _flag_k = FK_CMP;
   4676     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802CDDF; /* 0x3802CD85: je 0x3802cddf */
   4677 L_3802CD87:
   4678     edx = MEM32(ebp + 0x8); /* 0x3802CD87: mov edx, dword ptr [ebp + 8] */
   4679     MEM32(edi) = edx; /* 0x3802CD8A: mov dword ptr [edi], edx */
   4680     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(4);
   4681     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4682     edi = edi + 4; /* 0x3802CD8C: add edi, 4 */
   4683     _flag_k = FK_ADD;
   4684     /* cmp edi, eax */ /* 0x3802CD8F: cmp edi, eax */
   4685     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   4686     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4687     _flag_k = FK_CMP;
   4688     RECOMP_BACKEDGE();
   4689     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CD87; /* 0x3802CD91: jne 0x3802cd87 */
   4690 L_3802CD93:
   4691     eax = MEM32(esi + 0x8); /* 0x3802CD93: mov eax, dword ptr [esi + 8] */
   4692     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   4693     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4694     eax = eax + 4; /* 0x3802CD96: add eax, 4 */
   4695     _flag_k = FK_ADD;
   4696     edi = POP32_VAL(esp); /* 0x3802CD99: pop edi */
   4697     MEM32(esi + 0x8) = eax; /* 0x3802CD9A: mov dword ptr [esi + 8], eax */
   4698     esi = POP32_VAL(esp); /* 0x3802CD9D: pop esi */
   4699     esp = ebp; /* 0x3802CD9E: mov esp, ebp */
   4700     ebp = POP32_VAL(esp); /* 0x3802CDA0: pop ebp */
   4701     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802CDA1: ret 4 */
   4702 L_3802CDA4:
   4703     PUSH32(esp, eax); /* 0x3802CDA4: push eax */
   4704     PUSH32(esp, eax); /* 0x3802CDA5: push eax */
   4705     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xFFFFFFFCu);
   4706     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4707     eax = eax + 0xFFFFFFFCu; /* 0x3802CDA6: add eax, -4 */
   4708     _flag_k = FK_ADD;
   4709     PUSH32(esp, eax); /* 0x3802CDA9: push eax */
   4710     ecx = esi; /* 0x3802CDAA: mov ecx, esi */
   4711     RECOMP_ICALL(0x3800A100u); /* 0x3802CDAC: call 0x3800a100 */ /* not lifted */
   4712     RECOMP_FLAGS_IN();
   4713     ecx = MEM32(esi + 0x8); /* 0x3802CDB1: mov ecx, dword ptr [esi + 8] */
   4714     eax = ecx + (-0x4); /* 0x3802CDB4: lea eax, [ecx - 4] */
   4715     /* cmp edi, eax */ /* 0x3802CDB7: cmp edi, eax */
   4716     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   4717     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4718     _flag_k = FK_CMP;
   4719     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802CDCA; /* 0x3802CDB9: je 0x3802cdca */
   4720 L_3802CDBB:
   4721     edx = MEM32(eax + (-0x4)); /* 0x3802CDBB: mov edx, dword ptr [eax - 4] */
   4722     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   4723     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4724     eax = eax - 4; /* 0x3802CDBE: sub eax, 4 */
   4725     _flag_k = FK_CMP;
   4726     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4);
   4727     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4728     ecx = ecx - 4; /* 0x3802CDC1: sub ecx, 4 */
   4729     _flag_k = FK_CMP;
   4730     /* cmp eax, edi */ /* 0x3802CDC4: cmp eax, edi */
   4731     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   4732     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4733     _flag_k = FK_CMP;
   4734     MEM32(ecx) = edx; /* 0x3802CDC6: mov dword ptr [ecx], edx */
   4735     RECOMP_BACKEDGE();
   4736     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CDBB; /* 0x3802CDC8: jne 0x3802cdbb */
   4737 L_3802CDCA:
   4738     ecx = edi + 0x4; /* 0x3802CDCA: lea ecx, [edi + 4] */
   4739     /* cmp edi, ecx */ /* 0x3802CDCD: cmp edi, ecx */
   4740     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx);
   4741     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4742     _flag_k = FK_CMP;
   4743     eax = edi; /* 0x3802CDCF: mov eax, edi */
   4744     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802CDDF; /* 0x3802CDD1: je 0x3802cddf */
   4745 L_3802CDD3:
   4746     edx = MEM32(ebp + 0x8); /* 0x3802CDD3: mov edx, dword ptr [ebp + 8] */
   4747     MEM32(eax) = edx; /* 0x3802CDD6: mov dword ptr [eax], edx */
   4748     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   4749     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4750     eax = eax + 4; /* 0x3802CDD8: add eax, 4 */
   4751     _flag_k = FK_ADD;
   4752     /* cmp eax, ecx */ /* 0x3802CDDB: cmp eax, ecx */
   4753     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   4754     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4755     _flag_k = FK_CMP;
   4756     RECOMP_BACKEDGE();
   4757     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CDD3; /* 0x3802CDDD: jne 0x3802cdd3 */
   4758 L_3802CDDF:
   4759     eax = MEM32(esi + 0x8); /* 0x3802CDDF: mov eax, dword ptr [esi + 8] */
   4760     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   4761     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4762     eax = eax + 4; /* 0x3802CDE2: add eax, 4 */
   4763     _flag_k = FK_ADD;
   4764     edi = POP32_VAL(esp); /* 0x3802CDE5: pop edi */
   4765     MEM32(esi + 0x8) = eax; /* 0x3802CDE6: mov dword ptr [esi + 8], eax */
   4766     esi = POP32_VAL(esp); /* 0x3802CDE9: pop esi */
   4767     esp = ebp; /* 0x3802CDEA: mov esp, ebp */
   4768     ebp = POP32_VAL(esp); /* 0x3802CDEC: pop ebp */
   4769     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802CDED: ret 4 */
   4770     RECOMP_REGS_OUT();
   4771 }
   4772 
   4773 void sub_3802CDF0(void) {
   4774     int _fpu_cmp = 0;
   4775     uint32_t _cf = 0;
   4776     int _df = 1;
   4777     uint32_t _flag_k = FK_NONE;
   4778     uint32_t _flag_a = 0, _flag_b = 0;
   4779     uint32_t _itail_tgt = 0;
   4780     RECOMP_REGS_LOCALS
   4781     RECOMP_ENTER(0x3802CDF0u);
   4782 
   4783 L_3802CDF0:
   4784     PUSH32(esp, ebp); /* 0x3802CDF0: push ebp */
   4785     ebp = esp; /* 0x3802CDF1: mov ebp, esp */
   4786     PUSH32(esp, 0xFFFFFFFFu); /* 0x3802CDF3: push -1 */
   4787     PUSH32(esp, 0x3804CAA9u); /* 0x3802CDF5: push 0x3804caa9 */
   4788     eax = MEM32(FS_BASE + (0)); /* 0x3802CDFA: mov eax, dword ptr fs:[0] */
   4789     PUSH32(esp, eax); /* 0x3802CE00: push eax */
   4790     MEM32(FS_BASE + (0)) = esp; /* 0x3802CE01: mov dword ptr fs:[0], esp */
   4791     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x14u);
   4792     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4793     esp = esp - 0x14u; /* 0x3802CE08: sub esp, 0x14 */
   4794     _flag_k = FK_CMP;
   4795     SET_LO8(eax, MEM8(0x3806EDF8)); /* 0x3802CE0B: mov al, byte ptr [0x3806edf8] */
   4796     /* test LO8(eax), 1 */ /* 0x3802CE10: test al, 1 */
   4797     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   4798     _cf = 0;
   4799     _flag_k = FK_NARROW(FK_TEST, 24);
   4800     PUSH32(esp, ebx); /* 0x3802CE12: push ebx */
   4801     PUSH32(esp, esi); /* 0x3802CE13: push esi */
   4802     PUSH32(esp, edi); /* 0x3802CE14: push edi */
   4803     esi = ecx; /* 0x3802CE15: mov esi, ecx */
   4804     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802CE4F; /* 0x3802CE17: jne 0x3802ce4f */
   4805 L_3802CE19:
   4806     SET_LO8(edx, LO8(eax)); /* 0x3802CE19: mov dl, al */
   4807     SET_LO8(eax, MEM8(ebp + (-0xD))); /* 0x3802CE1B: mov al, byte ptr [ebp - 0xd] */
   4808     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4809     edi = 0; /* 0x3802CE1E: xor edi, edi */
   4810     _cf = 0;
   4811     _flag_k = FK_TEST;
   4812     _flag_a = (uint32_t)((LO8(edx) | 1)) << 24; _flag_b = (uint32_t)((LO8(edx) | 1)) << 24;
   4813     SET_LO8(edx, LO8(edx) | 1); /* 0x3802CE20: or dl, 1 */
   4814     _cf = 0;
   4815     _flag_k = FK_NARROW(FK_TEST, 24);
   4816     PUSH32(esp, 0x3802D090u); /* 0x3802CE23: push 0x3802d090 */
   4817     MEM8(0x3806EDF8) = (uint8_t)(LO8(edx)); /* 0x3802CE28: mov byte ptr [0x3806edf8], dl */
   4818     MEM8(0x3806EDA8) = (uint8_t)(LO8(eax)); /* 0x3802CE2E: mov byte ptr [0x3806eda8], al */
   4819     MEM32(0x3806EDAC) = edi; /* 0x3802CE33: mov dword ptr [0x3806edac], edi */
   4820     MEM32(0x3806EDB0) = edi; /* 0x3802CE39: mov dword ptr [0x3806edb0], edi */
   4821     MEM32(0x3806EDB4) = edi; /* 0x3802CE3F: mov dword ptr [0x3806edb4], edi */
   4822     RECOMP_ICALL(0x3804B54Cu); /* 0x3802CE45: call 0x3804b54c */ /* not lifted */
   4823     RECOMP_FLAGS_IN();
   4824     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   4825     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4826     esp = esp + 4; /* 0x3802CE4A: add esp, 4 */
   4827     _flag_k = FK_ADD;
   4828     goto L_3802CE51; /* 0x3802CE4D: jmp 0x3802ce51 */
   4829 L_3802CE4F:
   4830     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4831     edi = 0; /* 0x3802CE4F: xor edi, edi */
   4832     _cf = 0;
   4833     _flag_k = FK_TEST;
   4834 L_3802CE51:
   4835     ecx = ebp + (-0x20); /* 0x3802CE51: lea ecx, [ebp - 0x20] */
   4836     PUSH32(esp, ecx); /* 0x3802CE54: push ecx */
   4837     ecx = esi; /* 0x3802CE55: mov ecx, esi */
   4838     RECOMP_ICALL(0x38029620u); /* 0x3802CE57: call 0x38029620 */ /* not lifted */
   4839     RECOMP_FLAGS_IN();
   4840     ecx = eax; /* 0x3802CE5C: mov ecx, eax */
   4841     RECOMP_ICALL(0x3802CF80u); /* 0x3802CE5E: call 0x3802cf80 */ /* not lifted */
   4842     RECOMP_FLAGS_IN();
   4843     esi = eax; /* 0x3802CE63: mov esi, eax */
   4844     edx = MEM32(0x3804E07C); /* 0x3802CE65: mov edx, dword ptr [0x3804e07c] */
   4845     ecx = MEM32(esi + 0x8); /* 0x3802CE6B: mov ecx, dword ptr [esi + 8] */
   4846     eax = MEM32(edx); /* 0x3802CE6E: mov eax, dword ptr [edx] */
   4847     ebx = ecx; /* 0x3802CE70: mov ebx, ecx */
   4848     /* cmp eax, ebx */ /* 0x3802CE72: cmp eax, ebx */
   4849     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
   4850     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4851     _flag_k = FK_CMP;
   4852     MEM32(ebp + (-0x4)) = edi; /* 0x3802CE74: mov dword ptr [ebp - 4], edi */
   4853     if (CMP_AE(_flag_a, _flag_b)) goto L_3802CE7B; /* 0x3802CE77: jae 0x3802ce7b */
   4854 L_3802CE79:
   4855     ebx = eax; /* 0x3802CE79: mov ebx, eax */
   4856 L_3802CE7B:
   4857     /* cmp esi, 0x3806EDA8u */ /* 0x3802CE7B: cmp esi, 0x3806eda8 */
   4858     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0x3806EDA8u);
   4859     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4860     _flag_k = FK_CMP;
   4861     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CEA2; /* 0x3802CE81: jne 0x3802cea2 */
   4862 L_3802CE83:
   4863     PUSH32(esp, eax); /* 0x3802CE83: push eax */
   4864     PUSH32(esp, ebx); /* 0x3802CE84: push ebx */
   4865     ecx = 0x3806EDA8u; /* 0x3802CE85: mov ecx, 0x3806eda8 */
   4866     RECOMP_ICALL(MEM32(0x3804E01C)); /* 0x3802CE8A: call dword ptr [0x3804e01c] */
   4867     RECOMP_FLAGS_IN();
   4868     PUSH32(esp, edi); /* 0x3802CE90: push edi */
   4869     PUSH32(esp, edi); /* 0x3802CE91: push edi */
   4870     ecx = 0x3806EDA8u; /* 0x3802CE92: mov ecx, 0x3806eda8 */
   4871     RECOMP_ICALL(MEM32(0x3804E01C)); /* 0x3802CE97: call dword ptr [0x3804e01c] */
   4872     RECOMP_FLAGS_IN();
   4873     goto L_3802CF34; /* 0x3802CE9D: jmp 0x3802cf34 */
   4874 L_3802CEA2:
   4875     /* cmp ebx, edi */ /* 0x3802CEA2: cmp ebx, edi */
   4876     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(edi);
   4877     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4878     _flag_k = FK_CMP;
   4879     if (CMP_BE(_flag_a, _flag_b)) goto L_3802CEF1; /* 0x3802CEA4: jbe 0x3802cef1 */
   4880 L_3802CEA6:
   4881     /* cmp ebx, ecx */ /* 0x3802CEA6: cmp ebx, ecx */
   4882     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(ecx);
   4883     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4884     _flag_k = FK_CMP;
   4885     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CEF1; /* 0x3802CEA8: jne 0x3802cef1 */
   4886 L_3802CEAA:
   4887     eax = MEM32(esi + 0x4); /* 0x3802CEAA: mov eax, dword ptr [esi + 4] */
   4888     /* cmp eax, edi */ /* 0x3802CEAD: cmp eax, edi */
   4889     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   4890     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4891     _flag_k = FK_CMP;
   4892     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CEB6; /* 0x3802CEAF: jne 0x3802ceb6 */
   4893 L_3802CEB1:
   4894     eax = MEM32(0x3804E080); /* 0x3802CEB1: mov eax, dword ptr [0x3804e080] */
   4895 L_3802CEB6:
   4896     /* cmp MEM8(eax + (-0x1)), 0xFEu */ /* 0x3802CEB6: cmp byte ptr [eax - 1], 0xfe */
   4897     _flag_a = (uint32_t)(MEM8(eax + (-0x1))) << 24; _flag_b = (uint32_t)(0xFEu) << 24;
   4898     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4899     _flag_k = FK_NARROW(FK_CMP, 24);
   4900     if (CMP_AE(_flag_a, _flag_b)) goto L_3802CEF1; /* 0x3802CEBA: jae 0x3802cef1 */
   4901 L_3802CEBC:
   4902     PUSH32(esp, 1); /* 0x3802CEBC: push 1 */
   4903     ecx = 0x3806EDA8u; /* 0x3802CEBE: mov ecx, 0x3806eda8 */
   4904     RECOMP_ICALL(MEM32(0x3804E05C)); /* 0x3802CEC3: call dword ptr [0x3804e05c] */
   4905     RECOMP_FLAGS_IN();
   4906     eax = MEM32(esi + 0x4); /* 0x3802CEC9: mov eax, dword ptr [esi + 4] */
   4907     /* cmp eax, edi */ /* 0x3802CECC: cmp eax, edi */
   4908     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   4909     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4910     _flag_k = FK_CMP;
   4911     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CED5; /* 0x3802CECE: jne 0x3802ced5 */
   4912 L_3802CED0:
   4913     eax = MEM32(0x3804E080); /* 0x3802CED0: mov eax, dword ptr [0x3804e080] */
   4914 L_3802CED5:
   4915     MEM32(0x3806EDAC) = eax; /* 0x3802CED5: mov dword ptr [0x3806edac], eax */
   4916     ecx = MEM32(esi + 0x8); /* 0x3802CEDA: mov ecx, dword ptr [esi + 8] */
   4917     MEM32(0x3806EDB0) = ecx; /* 0x3802CEDD: mov dword ptr [0x3806edb0], ecx */
   4918     edx = MEM32(esi + 0xC); /* 0x3802CEE3: mov edx, dword ptr [esi + 0xc] */
   4919     MEM32(0x3806EDB4) = edx; /* 0x3802CEE6: mov dword ptr [0x3806edb4], edx */
   4920     _flag_a = (uint32_t)(MEM8(eax + (-0x1))) << 24; _flag_b = (uint32_t)(1) << 24;
   4921     MEM8(eax + (-0x1)) = (uint8_t)(MEM8(eax + (-0x1)) + 1); /* 0x3802CEEC: inc byte ptr [eax - 1] */
   4922     _flag_k = FK_NARROW(FK_INC, 24);
   4923     goto L_3802CF34; /* 0x3802CEEF: jmp 0x3802cf34 */
   4924 L_3802CEF1:
   4925     PUSH32(esp, 1); /* 0x3802CEF1: push 1 */
   4926     PUSH32(esp, ebx); /* 0x3802CEF3: push ebx */
   4927     ecx = 0x3806EDA8u; /* 0x3802CEF4: mov ecx, 0x3806eda8 */
   4928     RECOMP_ICALL(MEM32(0x3804E024)); /* 0x3802CEF9: call dword ptr [0x3804e024] */
   4929     RECOMP_FLAGS_IN();
   4930     /* test LO8(eax), LO8(eax) */ /* 0x3802CEFF: test al, al */
   4931     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   4932     _cf = 0;
   4933     _flag_k = FK_NARROW(FK_TEST, 24);
   4934     if (TEST_Z(_flag_a, _flag_b)) goto L_3802CF34; /* 0x3802CF01: je 0x3802cf34 */
   4935 L_3802CF03:
   4936     esi = MEM32(esi + 0x4); /* 0x3802CF03: mov esi, dword ptr [esi + 4] */
   4937     /* cmp esi, edi */ /* 0x3802CF06: cmp esi, edi */
   4938     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edi);
   4939     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4940     _flag_k = FK_CMP;
   4941     if (CMP_NE(_flag_a, _flag_b)) goto L_3802CF10; /* 0x3802CF08: jne 0x3802cf10 */
   4942 L_3802CF0A:
   4943     esi = MEM32(0x3804E080); /* 0x3802CF0A: mov esi, dword ptr [0x3804e080] */
   4944 L_3802CF10:
   4945     edi = MEM32(0x3806EDAC); /* 0x3802CF10: mov edi, dword ptr [0x3806edac] */
   4946     ecx = ebx; /* 0x3802CF16: mov ecx, ebx */
   4947     eax = ecx; /* 0x3802CF18: mov eax, ecx */
   4948     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3802CF1A: shr ecx, 2 */
   4949     if (2u) { _flag_a = recomp_flags_pack((ecx >> 2u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   4950     ecx = ecx >> 2u; /* 0x3802CF1A: shr ecx, 2 */
   4951     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3802CF1D: 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; }
   4952     ecx = eax; /* 0x3802CF1F: mov ecx, eax */
   4953     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(3);
   4954     ecx = ecx & 3; /* 0x3802CF21: and ecx, 3 */
   4955     _cf = 0;
   4956     _flag_k = FK_TEST;
   4957     if (ecx) { uint32_t _n = ecx, _b = _n * 1u; /* 0x3802CF24: rep movsb byte ptr es:[edi], byte ptr [esi] */ if (_df > 0) { memmove((void*)ADDR(edi), (void*)ADDR(esi), _b); esi += _b; edi += _b; } else { memmove((void*)ADDR(edi - _b + 1u), (void*)ADDR(esi - _b + 1u), _b); esi -= _b; edi -= _b; } ecx = 0; }
   4958     PUSH32(esp, ebx); /* 0x3802CF26: push ebx */
   4959     ecx = 0x3806EDA8u; /* 0x3802CF27: mov ecx, 0x3806eda8 */
   4960     RECOMP_ICALL(MEM32(0x3804E054)); /* 0x3802CF2C: call dword ptr [0x3804e054] */
   4961     RECOMP_FLAGS_IN();
   4962     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   4963     edi = 0; /* 0x3802CF32: xor edi, edi */
   4964     _cf = 0;
   4965     _flag_k = FK_TEST;
   4966 L_3802CF34:
   4967     eax = MEM32(ebp + (-0x1C)); /* 0x3802CF34: mov eax, dword ptr [ebp - 0x1c] */
   4968     /* cmp eax, edi */ /* 0x3802CF37: cmp eax, edi */
   4969     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   4970     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4971     _flag_k = FK_CMP;
   4972     edi = POP32_VAL(esp); /* 0x3802CF39: pop edi */
   4973     esi = POP32_VAL(esp); /* 0x3802CF3A: pop esi */
   4974     ebx = POP32_VAL(esp); /* 0x3802CF3B: pop ebx */
   4975     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802CF6B; /* 0x3802CF3C: je 0x3802cf6b */
   4976 L_3802CF3E:
   4977     ecx = eax + (-0x1); /* 0x3802CF3E: lea ecx, [eax - 1] */
   4978     SET_LO8(eax, MEM8(ecx)); /* 0x3802CF41: mov al, byte ptr [ecx] */
   4979     /* test LO8(eax), LO8(eax) */ /* 0x3802CF43: test al, al */
   4980     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   4981     _cf = 0;
   4982     _flag_k = FK_NARROW(FK_TEST, 24);
   4983     if (TEST_Z(_flag_a, _flag_b)) goto L_3802CF62; /* 0x3802CF45: je 0x3802cf62 */
   4984 L_3802CF47:
   4985     /* cmp LO8(eax), 0xFFu */ /* 0x3802CF47: cmp al, 0xff */
   4986     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   4987     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4988     _flag_k = FK_NARROW(FK_CMP, 24);
   4989     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802CF62; /* 0x3802CF49: je 0x3802cf62 */
   4990 L_3802CF4B:
   4991     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   4992     SET_LO8(eax, LO8(eax) - 1); /* 0x3802CF4B: dec al */
   4993     _flag_k = FK_NARROW(FK_DEC, 24);
   4994     MEM8(ecx) = (uint8_t)(LO8(eax)); /* 0x3802CF4D: mov byte ptr [ecx], al */
   4995     eax = 0x3806EDA8u; /* 0x3802CF4F: mov eax, 0x3806eda8 */
   4996     ecx = MEM32(ebp + (-0xC)); /* 0x3802CF54: mov ecx, dword ptr [ebp - 0xc] */
   4997     MEM32(FS_BASE + (0)) = ecx; /* 0x3802CF57: mov dword ptr fs:[0], ecx */
   4998     esp = ebp; /* 0x3802CF5E: mov esp, ebp */
   4999     ebp = POP32_VAL(esp); /* 0x3802CF60: pop ebp */
   5000     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802CF61: ret  */
   5001 L_3802CF62:
   5002     PUSH32(esp, ecx); /* 0x3802CF62: push ecx */
   5003     RECOMP_ICALL(0x3804B4F6u); /* 0x3802CF63: call 0x3804b4f6 */ /* not lifted */
   5004     RECOMP_FLAGS_IN();
   5005     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5006     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5007     esp = esp + 4; /* 0x3802CF68: add esp, 4 */
   5008     _flag_k = FK_ADD;
   5009 L_3802CF6B:
   5010     ecx = MEM32(ebp + (-0xC)); /* 0x3802CF6B: mov ecx, dword ptr [ebp - 0xc] */
   5011     eax = 0x3806EDA8u; /* 0x3802CF6E: mov eax, 0x3806eda8 */
   5012     MEM32(FS_BASE + (0)) = ecx; /* 0x3802CF73: mov dword ptr fs:[0], ecx */
   5013     esp = ebp; /* 0x3802CF7A: mov esp, ebp */
   5014     ebp = POP32_VAL(esp); /* 0x3802CF7C: pop ebp */
   5015     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802CF7D: ret  */
   5016     RECOMP_REGS_OUT();
   5017 }
   5018 
   5019 void sub_3802CF34(void) {
   5020     int _fpu_cmp = 0;
   5021     uint32_t _cf = 0;
   5022     int _df = 1;
   5023     uint32_t _flag_k = FK_NONE;
   5024     uint32_t _flag_a = 0, _flag_b = 0;
   5025     uint32_t _itail_tgt = 0;
   5026     RECOMP_REGS_LOCALS
   5027     RECOMP_ENTER(0x3802CF34u);
   5028 
   5029 L_3802CF34:
   5030     eax = MEM32(ebp + (-0x1C)); /* 0x3802CF34: mov eax, dword ptr [ebp - 0x1c] */
   5031     /* cmp eax, edi */ /* 0x3802CF37: cmp eax, edi */
   5032     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   5033     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5034     _flag_k = FK_CMP;
   5035     edi = POP32_VAL(esp); /* 0x3802CF39: pop edi */
   5036     esi = POP32_VAL(esp); /* 0x3802CF3A: pop esi */
   5037     ebx = POP32_VAL(esp); /* 0x3802CF3B: pop ebx */
   5038     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802CF6B; /* 0x3802CF3C: je 0x3802cf6b */
   5039 L_3802CF3E:
   5040     ecx = eax + (-0x1); /* 0x3802CF3E: lea ecx, [eax - 1] */
   5041     SET_LO8(eax, MEM8(ecx)); /* 0x3802CF41: mov al, byte ptr [ecx] */
   5042     /* test LO8(eax), LO8(eax) */ /* 0x3802CF43: test al, al */
   5043     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   5044     _cf = 0;
   5045     _flag_k = FK_NARROW(FK_TEST, 24);
   5046     if (TEST_Z(_flag_a, _flag_b)) goto L_3802CF62; /* 0x3802CF45: je 0x3802cf62 */
   5047 L_3802CF47:
   5048     /* cmp LO8(eax), 0xFFu */ /* 0x3802CF47: cmp al, 0xff */
   5049     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   5050     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5051     _flag_k = FK_NARROW(FK_CMP, 24);
   5052     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802CF62; /* 0x3802CF49: je 0x3802cf62 */
   5053 L_3802CF4B:
   5054     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   5055     SET_LO8(eax, LO8(eax) - 1); /* 0x3802CF4B: dec al */
   5056     _flag_k = FK_NARROW(FK_DEC, 24);
   5057     MEM8(ecx) = (uint8_t)(LO8(eax)); /* 0x3802CF4D: mov byte ptr [ecx], al */
   5058     eax = 0x3806EDA8u; /* 0x3802CF4F: mov eax, 0x3806eda8 */
   5059     ecx = MEM32(ebp + (-0xC)); /* 0x3802CF54: mov ecx, dword ptr [ebp - 0xc] */
   5060     MEM32(FS_BASE + (0)) = ecx; /* 0x3802CF57: mov dword ptr fs:[0], ecx */
   5061     esp = ebp; /* 0x3802CF5E: mov esp, ebp */
   5062     ebp = POP32_VAL(esp); /* 0x3802CF60: pop ebp */
   5063     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802CF61: ret  */
   5064 L_3802CF62:
   5065     PUSH32(esp, ecx); /* 0x3802CF62: push ecx */
   5066     RECOMP_ICALL(0x3804B4F6u); /* 0x3802CF63: call 0x3804b4f6 */ /* not lifted */
   5067     RECOMP_FLAGS_IN();
   5068     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5069     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5070     esp = esp + 4; /* 0x3802CF68: add esp, 4 */
   5071     _flag_k = FK_ADD;
   5072 L_3802CF6B:
   5073     ecx = MEM32(ebp + (-0xC)); /* 0x3802CF6B: mov ecx, dword ptr [ebp - 0xc] */
   5074     eax = 0x3806EDA8u; /* 0x3802CF6E: mov eax, 0x3806eda8 */
   5075     MEM32(FS_BASE + (0)) = ecx; /* 0x3802CF73: mov dword ptr fs:[0], ecx */
   5076     esp = ebp; /* 0x3802CF7A: mov esp, ebp */
   5077     ebp = POP32_VAL(esp); /* 0x3802CF7C: pop ebp */
   5078     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802CF7D: ret  */
   5079     RECOMP_REGS_OUT();
   5080 }
   5081 
   5082 void sub_3802CF80(void) {
   5083     int _fpu_cmp = 0;
   5084     uint32_t _cf = 0;
   5085     int _df = 1;
   5086     uint32_t _flag_k = FK_NONE;
   5087     uint32_t _flag_a = 0, _flag_b = 0;
   5088     uint32_t _itail_tgt = 0;
   5089     RECOMP_REGS_LOCALS
   5090     RECOMP_ENTER(0x3802CF80u);
   5091 
   5092 L_3802CF80:
   5093     PUSH32(esp, ebp); /* 0x3802CF80: push ebp */
   5094     ebp = esp; /* 0x3802CF81: mov ebp, esp */
   5095     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x404u);
   5096     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5097     esp = esp - 0x404u; /* 0x3802CF83: sub esp, 0x404 */
   5098     _flag_k = FK_CMP;
   5099     eax = MEM32(ecx + 0x14); /* 0x3802CF89: mov eax, dword ptr [ecx + 0x14] */
   5100     edx = MEM32(ecx + 0x10); /* 0x3802CF8C: mov edx, dword ptr [ecx + 0x10] */
   5101     PUSH32(esp, ebx); /* 0x3802CF8F: push ebx */
   5102     PUSH32(esp, esi); /* 0x3802CF90: push esi */
   5103     PUSH32(esp, edi); /* 0x3802CF91: push edi */
   5104     PUSH32(esp, eax); /* 0x3802CF92: push eax */
   5105     eax = MEM32(ecx + 0xC); /* 0x3802CF93: mov eax, dword ptr [ecx + 0xc] */
   5106     PUSH32(esp, edx); /* 0x3802CF96: push edx */
   5107     edx = MEM32(ecx + 0x8); /* 0x3802CF97: mov edx, dword ptr [ecx + 8] */
   5108     PUSH32(esp, eax); /* 0x3802CF9A: push eax */
   5109     eax = MEM32(ecx + 0x4); /* 0x3802CF9B: mov eax, dword ptr [ecx + 4] */
   5110     ecx = MEM32(ecx); /* 0x3802CF9E: mov ecx, dword ptr [ecx] */
   5111     PUSH32(esp, edx); /* 0x3802CFA0: push edx */
   5112     PUSH32(esp, eax); /* 0x3802CFA1: push eax */
   5113     PUSH32(esp, ecx); /* 0x3802CFA2: push ecx */
   5114     edx = ebp + (-0x404); /* 0x3802CFA3: lea edx, [ebp - 0x404] */
   5115     PUSH32(esp, 0x3806CA90u); /* 0x3802CFA9: push 0x3806ca90 */
   5116     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5117     esi = 0; /* 0x3802CFAE: xor esi, esi */
   5118     _cf = 0;
   5119     _flag_k = FK_TEST;
   5120     PUSH32(esp, edx); /* 0x3802CFB0: push edx */
   5121     MEM32(ebp + (-0x4)) = esi; /* 0x3802CFB1: mov dword ptr [ebp - 4], esi */
   5122     RECOMP_ICALL(MEM32(0x3804E09C)); /* 0x3802CFB4: call dword ptr [0x3804e09c] */
   5123     RECOMP_FLAGS_IN();
   5124     ebx = MEM32(ebp + 0x8); /* 0x3802CFBA: mov ebx, dword ptr [ebp + 8] */
   5125     SET_LO8(eax, MEM8(ebp + 0xB)); /* 0x3802CFBD: mov al, byte ptr [ebp + 0xb] */
   5126     _flag_a = (uint32_t)((ecx | 0xFFFFFFFFu)); _flag_b = (uint32_t)((ecx | 0xFFFFFFFFu));
   5127     ecx = ecx | 0xFFFFFFFFu; /* 0x3802CFC0: or ecx, 0xffffffff */
   5128     _cf = 0;
   5129     _flag_k = FK_TEST;
   5130     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x20u);
   5131     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5132     esp = esp + 0x20u; /* 0x3802CFC3: add esp, 0x20 */
   5133     _flag_k = FK_ADD;
   5134     MEM8(ebx) = (uint8_t)(LO8(eax)); /* 0x3802CFC6: mov byte ptr [ebx], al */
   5135     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5136     eax = 0; /* 0x3802CFC8: xor eax, eax */
   5137     _cf = 0;
   5138     _flag_k = FK_TEST;
   5139     edi = ebp + (-0x404); /* 0x3802CFCA: lea edi, [ebp - 0x404] */
   5140     if (ecx) { uint32_t _a = 0, _b = 0; while (ecx) { _a = LO8(eax); _b = MEM8(edi); edi += _df; ecx--; if (_a == _b) break; } _flag_a = _a; _flag_b = _b; _cf = (uint32_t)CMP_B(_a, _b); _flag_k = FK_CMP; } /* 0x3802CFD0: repne scasb al, byte ptr es:[edi] */
   5141     ecx = ~ecx; /* 0x3802CFD2: not ecx */
   5142     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   5143     ecx = ecx - 1; /* 0x3802CFD4: dec ecx */
   5144     _flag_k = FK_DEC;
   5145     edi = ecx; /* 0x3802CFD5: mov edi, ecx */
   5146     /* cmp edi, 0xFFFFFFFDu */ /* 0x3802CFD7: cmp edi, -3 */
   5147     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(0xFFFFFFFDu);
   5148     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5149     _flag_k = FK_CMP;
   5150     MEM32(ebx + 0x4) = esi; /* 0x3802CFDA: mov dword ptr [ebx + 4], esi */
   5151     MEM32(ebx + 0x8) = esi; /* 0x3802CFDD: mov dword ptr [ebx + 8], esi */
   5152     MEM32(ebx + 0xC) = esi; /* 0x3802CFE0: mov dword ptr [ebx + 0xc], esi */
   5153     MEM32(ebp + 0x8) = edi; /* 0x3802CFE3: mov dword ptr [ebp + 8], edi */
   5154     if (CMP_BE(_flag_a, _flag_b)) goto L_3802CFEE; /* 0x3802CFE6: jbe 0x3802cfee */
   5155 L_3802CFE8:
   5156     RECOMP_ICALL(MEM32(0x3804E058)); /* 0x3802CFE8: call dword ptr [0x3804e058] */
   5157     RECOMP_FLAGS_IN();
   5158 L_3802CFEE:
   5159     eax = MEM32(ebx + 0x4); /* 0x3802CFEE: mov eax, dword ptr [ebx + 4] */
   5160     /* cmp eax, esi */ /* 0x3802CFF1: cmp eax, esi */
   5161     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   5162     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5163     _flag_k = FK_CMP;
   5164     MEM32(ebx + 0x8) = esi; /* 0x3802CFF3: mov dword ptr [ebx + 8], esi */
   5165     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D01C; /* 0x3802CFF6: je 0x3802d01c */
   5166 L_3802CFF8:
   5167     SET_LO8(eax, MEM8(eax + (-0x1))); /* 0x3802CFF8: mov al, byte ptr [eax - 1] */
   5168     /* test LO8(eax), LO8(eax) */ /* 0x3802CFFB: test al, al */
   5169     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   5170     _cf = 0;
   5171     _flag_k = FK_NARROW(FK_TEST, 24);
   5172     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D01C; /* 0x3802CFFD: je 0x3802d01c */
   5173 L_3802CFFF:
   5174     /* cmp LO8(eax), 0xFFu */ /* 0x3802CFFF: cmp al, 0xff */
   5175     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   5176     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5177     _flag_k = FK_NARROW(FK_CMP, 24);
   5178     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D01C; /* 0x3802D001: je 0x3802d01c */
   5179 L_3802D003:
   5180     /* cmp edi, esi */ /* 0x3802D003: cmp edi, esi */
   5181     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(esi);
   5182     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5183     _flag_k = FK_CMP;
   5184     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D04B; /* 0x3802D005: jne 0x3802d04b */
   5185 L_3802D007:
   5186     PUSH32(esp, 1); /* 0x3802D007: push 1 */
   5187     ecx = ebx; /* 0x3802D009: mov ecx, ebx */
   5188     RECOMP_ICALL(MEM32(0x3804E05C)); /* 0x3802D00B: call dword ptr [0x3804e05c] */
   5189     RECOMP_FLAGS_IN();
   5190     edi = POP32_VAL(esp); /* 0x3802D011: pop edi */
   5191     esi = POP32_VAL(esp); /* 0x3802D012: pop esi */
   5192     eax = ebx; /* 0x3802D013: mov eax, ebx */
   5193     ebx = POP32_VAL(esp); /* 0x3802D015: pop ebx */
   5194     esp = ebp; /* 0x3802D016: mov esp, ebp */
   5195     ebp = POP32_VAL(esp); /* 0x3802D018: pop ebp */
   5196     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802D019: ret 4 */
   5197 L_3802D01C:
   5198     /* cmp edi, esi */ /* 0x3802D01C: cmp edi, esi */
   5199     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(esi);
   5200     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5201     _flag_k = FK_CMP;
   5202     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D035; /* 0x3802D01E: jne 0x3802d035 */
   5203 L_3802D020:
   5204     PUSH32(esp, 1); /* 0x3802D020: push 1 */
   5205     ecx = ebx; /* 0x3802D022: mov ecx, ebx */
   5206     RECOMP_ICALL(MEM32(0x3804E05C)); /* 0x3802D024: call dword ptr [0x3804e05c] */
   5207     RECOMP_FLAGS_IN();
   5208     edi = POP32_VAL(esp); /* 0x3802D02A: pop edi */
   5209     esi = POP32_VAL(esp); /* 0x3802D02B: pop esi */
   5210     eax = ebx; /* 0x3802D02C: mov eax, ebx */
   5211     ebx = POP32_VAL(esp); /* 0x3802D02E: pop ebx */
   5212     esp = ebp; /* 0x3802D02F: mov esp, ebp */
   5213     ebp = POP32_VAL(esp); /* 0x3802D031: pop ebp */
   5214     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802D032: ret 4 */
   5215 L_3802D035:
   5216     eax = MEM32(ebx + 0xC); /* 0x3802D035: mov eax, dword ptr [ebx + 0xc] */
   5217     /* cmp eax, 0x1Fu */ /* 0x3802D038: cmp eax, 0x1f */
   5218     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x1Fu);
   5219     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5220     _flag_k = FK_CMP;
   5221     if (CMP_A(_flag_a, _flag_b)) goto L_3802D041; /* 0x3802D03B: ja 0x3802d041 */
   5222 L_3802D03D:
   5223     /* cmp eax, edi */ /* 0x3802D03D: cmp eax, edi */
   5224     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   5225     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5226     _flag_k = FK_CMP;
   5227     if (CMP_AE(_flag_a, _flag_b)) goto L_3802D054; /* 0x3802D03F: jae 0x3802d054 */
   5228 L_3802D041:
   5229     PUSH32(esp, 1); /* 0x3802D041: push 1 */
   5230     ecx = ebx; /* 0x3802D043: mov ecx, ebx */
   5231     RECOMP_ICALL(MEM32(0x3804E05C)); /* 0x3802D045: call dword ptr [0x3804e05c] */
   5232     RECOMP_FLAGS_IN();
   5233 L_3802D04B:
   5234     PUSH32(esp, edi); /* 0x3802D04B: push edi */
   5235     ecx = ebx; /* 0x3802D04C: mov ecx, ebx */
   5236     RECOMP_ICALL(MEM32(0x3804E050)); /* 0x3802D04E: call dword ptr [0x3804e050] */
   5237     RECOMP_FLAGS_IN();
   5238 L_3802D054:
   5239     eax = MEM32(ebp + 0x8); /* 0x3802D054: mov eax, dword ptr [ebp + 8] */
   5240     ecx = edi; /* 0x3802D057: mov ecx, edi */
   5241     edi = MEM32(ebx + 0x4); /* 0x3802D059: mov edi, dword ptr [ebx + 4] */
   5242     edx = ecx; /* 0x3802D05C: mov edx, ecx */
   5243     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3802D05E: shr ecx, 2 */
   5244     if (2u) { _flag_a = recomp_flags_pack((ecx >> 2u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   5245     ecx = ecx >> 2u; /* 0x3802D05E: shr ecx, 2 */
   5246     esi = ebp + (-0x404); /* 0x3802D061: lea esi, [ebp - 0x404] */
   5247     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3802D067: 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; }
   5248     ecx = edx; /* 0x3802D069: mov ecx, edx */
   5249     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(3);
   5250     ecx = ecx & 3; /* 0x3802D06B: and ecx, 3 */
   5251     _cf = 0;
   5252     _flag_k = FK_TEST;
   5253     if (ecx) { uint32_t _n = ecx, _b = _n * 1u; /* 0x3802D06E: rep movsb byte ptr es:[edi], byte ptr [esi] */ if (_df > 0) { memmove((void*)ADDR(edi), (void*)ADDR(esi), _b); esi += _b; edi += _b; } else { memmove((void*)ADDR(edi - _b + 1u), (void*)ADDR(esi - _b + 1u), _b); esi -= _b; edi -= _b; } ecx = 0; }
   5254     ecx = MEM32(ebx + 0x4); /* 0x3802D070: mov ecx, dword ptr [ebx + 4] */
   5255     MEM32(ebx + 0x8) = eax; /* 0x3802D073: mov dword ptr [ebx + 8], eax */
   5256     edi = POP32_VAL(esp); /* 0x3802D076: pop edi */
   5257     MEM8(ecx + eax) = (uint8_t)(0); /* 0x3802D077: mov byte ptr [ecx + eax], 0 */
   5258     esi = POP32_VAL(esp); /* 0x3802D07B: pop esi */
   5259     eax = ebx; /* 0x3802D07C: mov eax, ebx */
   5260     ebx = POP32_VAL(esp); /* 0x3802D07E: pop ebx */
   5261     esp = ebp; /* 0x3802D07F: mov esp, ebp */
   5262     ebp = POP32_VAL(esp); /* 0x3802D081: pop ebp */
   5263     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802D082: ret 4 */
   5264     RECOMP_REGS_OUT();
   5265 }
   5266 
   5267 void sub_3802D090(void) {
   5268     int _fpu_cmp = 0;
   5269     uint32_t _cf = 0;
   5270     int _df = 1;
   5271     uint32_t _flag_k = FK_NONE;
   5272     uint32_t _flag_a = 0, _flag_b = 0;
   5273     uint32_t _itail_tgt = 0;
   5274     RECOMP_REGS_LOCALS
   5275     RECOMP_ENTER(0x3802D090u);
   5276 
   5277 L_3802D090:
   5278     ecx = MEM32(0x3806EDAC); /* 0x3802D090: mov ecx, dword ptr [0x3806edac] */
   5279     /* test ecx, ecx */ /* 0x3802D096: test ecx, ecx */
   5280     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   5281     _cf = 0;
   5282     _flag_k = FK_TEST;
   5283     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D0B6; /* 0x3802D098: je 0x3802d0b6 */
   5284 L_3802D09A:
   5285     SET_LO8(eax, MEM8(ecx + (-0x1))); /* 0x3802D09A: mov al, byte ptr [ecx - 1] */
   5286     /* test LO8(eax), LO8(eax) */ /* 0x3802D09D: test al, al */
   5287     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   5288     _cf = 0;
   5289     _flag_k = FK_NARROW(FK_TEST, 24);
   5290     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D0AC; /* 0x3802D09F: je 0x3802d0ac */
   5291 L_3802D0A1:
   5292     /* cmp LO8(eax), 0xFFu */ /* 0x3802D0A1: cmp al, 0xff */
   5293     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   5294     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5295     _flag_k = FK_NARROW(FK_CMP, 24);
   5296     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D0AC; /* 0x3802D0A3: je 0x3802d0ac */
   5297 L_3802D0A5:
   5298     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   5299     SET_LO8(eax, LO8(eax) - 1); /* 0x3802D0A5: dec al */
   5300     _flag_k = FK_NARROW(FK_DEC, 24);
   5301     MEM8(ecx + (-0x1)) = (uint8_t)(LO8(eax)); /* 0x3802D0A7: mov byte ptr [ecx - 1], al */
   5302     goto L_3802D0B6; /* 0x3802D0AA: jmp 0x3802d0b6 */
   5303 L_3802D0AC:
   5304     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   5305     ecx = ecx - 1; /* 0x3802D0AC: dec ecx */
   5306     _flag_k = FK_DEC;
   5307     PUSH32(esp, ecx); /* 0x3802D0AD: push ecx */
   5308     RECOMP_ICALL(0x3804B4F6u); /* 0x3802D0AE: call 0x3804b4f6 */ /* not lifted */
   5309     RECOMP_FLAGS_IN();
   5310     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5311     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5312     esp = esp + 4; /* 0x3802D0B3: add esp, 4 */
   5313     _flag_k = FK_ADD;
   5314 L_3802D0B6:
   5315     MEM32(0x3806EDAC) = 0; /* 0x3802D0B6: mov dword ptr [0x3806edac], 0 */
   5316     MEM32(0x3806EDB0) = 0; /* 0x3802D0C0: mov dword ptr [0x3806edb0], 0 */
   5317     MEM32(0x3806EDB4) = 0; /* 0x3802D0CA: mov dword ptr [0x3806edb4], 0 */
   5318     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802D0D4: ret  */
   5319     RECOMP_REGS_OUT();
   5320 }
   5321 
   5322 void sub_3802D0E0(void) {
   5323     int _fpu_cmp = 0;
   5324     uint32_t _cf = 0;
   5325     int _df = 1;
   5326     uint32_t _flag_k = FK_NONE;
   5327     uint32_t _flag_a = 0, _flag_b = 0;
   5328     uint32_t _itail_tgt = 0;
   5329     RECOMP_REGS_LOCALS
   5330     RECOMP_ENTER(0x3802D0E0u);
   5331 
   5332 L_3802D0E0:
   5333     PUSH32(esp, ebp); /* 0x3802D0E0: push ebp */
   5334     ebp = esp; /* 0x3802D0E1: mov ebp, esp */
   5335     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x30u);
   5336     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5337     esp = esp - 0x30u; /* 0x3802D0E3: sub esp, 0x30 */
   5338     _flag_k = FK_CMP;
   5339     PUSH32(esp, esi); /* 0x3802D0E6: push esi */
   5340     esi = MEM32(ebp + 0x8); /* 0x3802D0E7: mov esi, dword ptr [ebp + 8] */
   5341     eax = esi; /* 0x3802D0EA: mov eax, esi */
   5342     edx = MEM32(eax); /* 0x3802D0EC: mov edx, dword ptr [eax] */
   5343     MEM32(ebp + (-0xC)) = edx; /* 0x3802D0EE: mov dword ptr [ebp - 0xc], edx */
   5344     fp_push(*(float*)&MEM32(ebp + (-0xC))); /* 0x3802D0F1: fld dword ptr [ebp - 0xc] */
   5345     edx = MEM32(eax + 0x4); /* 0x3802D0F4: mov edx, dword ptr [eax + 4] */
   5346     { float _v = (float)_st[0]; *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3802D0F7: fst dword ptr [ebp - 0xc] */
   5347     eax = MEM32(eax + 0x8); /* 0x3802D0FA: mov eax, dword ptr [eax + 8] */
   5348     MEM32(ebp + (-0x8)) = edx; /* 0x3802D0FD: mov dword ptr [ebp - 8], edx */
   5349     fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3802D100: fld dword ptr [ebp - 8] */
   5350     _st[0] += (double)*(float*)ADDR(0x3804EBF0); /* 0x3802D103: fadd dword ptr [0x3804ebf0] */
   5351     edx = eax; /* 0x3802D109: mov edx, eax */
   5352     MEM32(ebp + (-0x4)) = eax; /* 0x3802D10B: mov dword ptr [ebp - 4], eax */
   5353     eax = MEM32(ebp + (-0xC)); /* 0x3802D10E: mov eax, dword ptr [ebp - 0xc] */
   5354     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802D111: fstp dword ptr [ebp - 8] */
   5355     MEM32(ebp + (-0x4)) = edx; /* 0x3802D114: mov dword ptr [ebp - 4], edx */
   5356     edx = MEM32(ebp + (-0x8)); /* 0x3802D117: mov edx, dword ptr [ebp - 8] */
   5357     MEM32(ebp + (-0xC)) = eax; /* 0x3802D11A: mov dword ptr [ebp - 0xc], eax */
   5358     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0xC)) = _v; } /* 0x3802D11D: fstp dword ptr [ebp - 0xc] */
   5359     MEM32(ebp + (-0x8)) = edx; /* 0x3802D120: mov dword ptr [ebp - 8], edx */
   5360     fp_push(*(float*)&MEM32(ebp + (-0x8))); /* 0x3802D123: fld dword ptr [ebp - 8] */
   5361     _st[0] -= (double)*(float*)ADDR(0x3804ED5C); /* 0x3802D126: fsub dword ptr [0x3804ed5c] */
   5362     PUSH32(esp, edi); /* 0x3802D12C: push edi */
   5363     edi = MEM32(ebp + (-0x4)); /* 0x3802D12D: mov edi, dword ptr [ebp - 4] */
   5364     MEM32(ebp + (-0x18)) = eax; /* 0x3802D130: mov dword ptr [ebp - 0x18], eax */
   5365     MEM32(ebp + (-0x14)) = edx; /* 0x3802D133: mov dword ptr [ebp - 0x14], edx */
   5366     { float _v = (float)fp_pop(); *(float*)ADDR(ebp + (-0x8)) = _v; } /* 0x3802D136: fstp dword ptr [ebp - 8] */
   5367     edx = MEM32(ebp + (-0xC)); /* 0x3802D139: mov edx, dword ptr [ebp - 0xc] */
   5368     eax = edi; /* 0x3802D13C: mov eax, edi */
   5369     MEM32(ebp + (-0x4)) = edi; /* 0x3802D13E: mov dword ptr [ebp - 4], edi */
   5370     MEM32(ebp + (-0x4)) = eax; /* 0x3802D141: mov dword ptr [ebp - 4], eax */
   5371     eax = MEM32(ebp + (-0x8)); /* 0x3802D144: mov eax, dword ptr [ebp - 8] */
   5372     MEM32(ebp + (-0x30)) = edx; /* 0x3802D147: mov dword ptr [ebp - 0x30], edx */
   5373     edx = edi; /* 0x3802D14A: mov edx, edi */
   5374     MEM32(ebp + (-0x10)) = edi; /* 0x3802D14C: mov dword ptr [ebp - 0x10], edi */
   5375     MEM32(ebp + (-0x24)) = 0; /* 0x3802D14F: mov dword ptr [ebp - 0x24], 0 */
   5376     MEM32(ebp + (-0x20)) = 0; /* 0x3802D156: mov dword ptr [ebp - 0x20], 0 */
   5377     MEM32(ebp + (-0x1C)) = 0; /* 0x3802D15D: mov dword ptr [ebp - 0x1c], 0 */
   5378     MEM32(ebp + (-0x2C)) = eax; /* 0x3802D164: mov dword ptr [ebp - 0x2c], eax */
   5379     MEM32(ebp + (-0x28)) = edx; /* 0x3802D167: mov dword ptr [ebp - 0x28], edx */
   5380     RECOMP_ICALL(0x3802BF20u); /* 0x3802D16A: call 0x3802bf20 */ /* not lifted */
   5381     RECOMP_FLAGS_IN();
   5382     edx = MEM32(eax); /* 0x3802D16F: mov edx, dword ptr [eax] */
   5383     PUSH32(esp, 0); /* 0x3802D171: push 0 */
   5384     PUSH32(esp, 0); /* 0x3802D173: push 0 */
   5385     ecx = ebp + (-0x24); /* 0x3802D175: lea ecx, [ebp - 0x24] */
   5386     PUSH32(esp, ecx); /* 0x3802D178: push ecx */
   5387     PUSH32(esp, esi); /* 0x3802D179: push esi */
   5388     ecx = ebp + (-0x30); /* 0x3802D17A: lea ecx, [ebp - 0x30] */
   5389     PUSH32(esp, ecx); /* 0x3802D17D: push ecx */
   5390     ecx = ebp + (-0x18); /* 0x3802D17E: lea ecx, [ebp - 0x18] */
   5391     PUSH32(esp, ecx); /* 0x3802D181: push ecx */
   5392     ecx = eax; /* 0x3802D182: mov ecx, eax */
   5393     RECOMP_ICALL(MEM32(edx + 0x10)); /* 0x3802D184: call dword ptr [edx + 0x10] */
   5394     RECOMP_FLAGS_IN();
   5395     /* test LO8(eax), LO8(eax) */ /* 0x3802D187: test al, al */
   5396     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   5397     _cf = 0;
   5398     _flag_k = FK_NARROW(FK_TEST, 24);
   5399     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D19E; /* 0x3802D189: jne 0x3802d19e */
   5400 L_3802D18B:
   5401     eax = MEM32(ebp + (-0x18)); /* 0x3802D18B: mov eax, dword ptr [ebp - 0x18] */
   5402     ecx = MEM32(ebp + (-0x14)); /* 0x3802D18E: mov ecx, dword ptr [ebp - 0x14] */
   5403     edx = esi; /* 0x3802D191: mov edx, esi */
   5404     MEM32(edx) = eax; /* 0x3802D193: mov dword ptr [edx], eax */
   5405     eax = MEM32(ebp + (-0x10)); /* 0x3802D195: mov eax, dword ptr [ebp - 0x10] */
   5406     MEM32(edx + 0x4) = ecx; /* 0x3802D198: mov dword ptr [edx + 4], ecx */
   5407     MEM32(edx + 0x8) = eax; /* 0x3802D19B: mov dword ptr [edx + 8], eax */
   5408 L_3802D19E:
   5409     fp_push(*(float*)&MEM32(esi)); /* 0x3802D19E: fld dword ptr [esi] */
   5410     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ebp + (-0x18))); /* 0x3802D1A0: fcomp dword ptr [ebp - 0x18] */
   5411     fp_pop();
   5412     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802D1A3: fnstsw ax */
   5413     /* test HI8(eax), 0x40u */ /* 0x3802D1A5: test ah, 0x40 */
   5414     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24;
   5415     _cf = 0;
   5416     _flag_k = FK_NARROW(FK_TEST, 24);
   5417     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D1D7; /* 0x3802D1A8: je 0x3802d1d7 */
   5418 L_3802D1AA:
   5419     fp_push(*(float*)&MEM32(esi + 0x4)); /* 0x3802D1AA: fld dword ptr [esi + 4] */
   5420     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ebp + (-0x14))); /* 0x3802D1AD: fcomp dword ptr [ebp - 0x14] */
   5421     fp_pop();
   5422     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802D1B0: fnstsw ax */
   5423     /* test HI8(eax), 0x40u */ /* 0x3802D1B2: test ah, 0x40 */
   5424     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24;
   5425     _cf = 0;
   5426     _flag_k = FK_NARROW(FK_TEST, 24);
   5427     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D1D7; /* 0x3802D1B5: je 0x3802d1d7 */
   5428 L_3802D1B7:
   5429     fp_push(*(float*)&MEM32(esi + 0x8)); /* 0x3802D1B7: fld dword ptr [esi + 8] */
   5430     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ebp + (-0x10))); /* 0x3802D1BA: fcomp dword ptr [ebp - 0x10] */
   5431     fp_pop();
   5432     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802D1BD: fnstsw ax */
   5433     /* test HI8(eax), 0x40u */ /* 0x3802D1BF: test ah, 0x40 */
   5434     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24;
   5435     _cf = 0;
   5436     _flag_k = FK_NARROW(FK_TEST, 24);
   5437     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D1D7; /* 0x3802D1C2: je 0x3802d1d7 */
   5438 L_3802D1C4:
   5439     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5440     eax = 0; /* 0x3802D1C4: xor eax, eax */
   5441     _cf = 0;
   5442     _flag_k = FK_TEST;
   5443     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5444     ecx = 0; /* 0x3802D1C6: xor ecx, ecx */
   5445     _cf = 0;
   5446     _flag_k = FK_TEST;
   5447     /* test eax, eax */ /* 0x3802D1C8: test eax, eax */
   5448     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   5449     _cf = 0;
   5450     _flag_k = FK_TEST;
   5451     SET_LO8(ecx, (TEST_NZ(_flag_a, _flag_b)) ? 1 : 0); /* 0x3802D1CA: setne cl */
   5452     edi = POP32_VAL(esp); /* 0x3802D1CD: pop edi */
   5453     SET_LO8(eax, LO8(ecx)); /* 0x3802D1CE: mov al, cl */
   5454     esi = POP32_VAL(esp); /* 0x3802D1D0: pop esi */
   5455     esp = ebp; /* 0x3802D1D1: mov esp, ebp */
   5456     ebp = POP32_VAL(esp); /* 0x3802D1D3: pop ebp */
   5457     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802D1D4: ret 4 */
   5458 L_3802D1D7:
   5459     eax = 1; /* 0x3802D1D7: mov eax, 1 */
   5460     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5461     ecx = 0; /* 0x3802D1DC: xor ecx, ecx */
   5462     _cf = 0;
   5463     _flag_k = FK_TEST;
   5464     /* test eax, eax */ /* 0x3802D1DE: test eax, eax */
   5465     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   5466     _cf = 0;
   5467     _flag_k = FK_TEST;
   5468     SET_LO8(ecx, (TEST_NZ(_flag_a, _flag_b)) ? 1 : 0); /* 0x3802D1E0: setne cl */
   5469     edi = POP32_VAL(esp); /* 0x3802D1E3: pop edi */
   5470     SET_LO8(eax, LO8(ecx)); /* 0x3802D1E4: mov al, cl */
   5471     esi = POP32_VAL(esp); /* 0x3802D1E6: pop esi */
   5472     esp = ebp; /* 0x3802D1E7: mov esp, ebp */
   5473     ebp = POP32_VAL(esp); /* 0x3802D1E9: pop ebp */
   5474     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802D1EA: ret 4 */
   5475     RECOMP_REGS_OUT();
   5476 }
   5477 
   5478 void sub_3802D1F0(void) {
   5479     int _fpu_cmp = 0;
   5480     uint32_t _cf = 0;
   5481     int _df = 1;
   5482     uint32_t _flag_k = FK_NONE;
   5483     uint32_t _flag_a = 0, _flag_b = 0;
   5484     uint32_t _itail_tgt = 0;
   5485     RECOMP_REGS_LOCALS
   5486     RECOMP_ENTER(0x3802D1F0u);
   5487 
   5488 L_3802D1F0:
   5489     RECOMP_ICALL(0x38029E80u); /* 0x3802D1F0: call 0x38029e80 */ /* not lifted */
   5490     RECOMP_FLAGS_IN();
   5491     ecx = eax; /* 0x3802D1F5: mov ecx, eax */
   5492     goto L_38039DC0; /* 0x3802D1F7: jmp 0x38039dc0 */
   5493 L_38039DC0:
   5494     eax = MEM32(ecx + 0xC); /* 0x38039DC0: mov eax, dword ptr [ecx + 0xc] */
   5495     edx = MEM32(eax + 0x18); /* 0x38039DC3: mov edx, dword ptr [eax + 0x18] */
   5496     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5497     ecx = 0; /* 0x38039DC6: xor ecx, ecx */
   5498     _cf = 0;
   5499     _flag_k = FK_TEST;
   5500     /* test edx, edx */ /* 0x38039DC8: test edx, edx */
   5501     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   5502     _cf = 0;
   5503     _flag_k = FK_TEST;
   5504     SET_LO8(ecx, (TEST_Z(_flag_a, _flag_b)) ? 1 : 0); /* 0x38039DCA: sete cl */
   5505     SET_LO8(eax, LO8(ecx)); /* 0x38039DCD: mov al, cl */
   5506     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38039DCF: ret  */
   5507     RECOMP_REGS_OUT();
   5508 }
   5509 
   5510 void sub_3802D200(void) {
   5511     int _fpu_cmp = 0;
   5512     uint32_t _cf = 0;
   5513     int _df = 1;
   5514     uint32_t _flag_k = FK_NONE;
   5515     uint32_t _flag_a = 0, _flag_b = 0;
   5516     uint32_t _itail_tgt = 0;
   5517     RECOMP_REGS_LOCALS
   5518     RECOMP_ENTER(0x3802D200u);
   5519 
   5520 L_3802D200:
   5521     RECOMP_ICALL(0x38029E80u); /* 0x3802D200: call 0x38029e80 */ /* not lifted */
   5522     RECOMP_FLAGS_IN();
   5523     ecx = eax; /* 0x3802D205: mov ecx, eax */
   5524     goto L_38039DD0; /* 0x3802D207: jmp 0x38039dd0 */
   5525 L_38039DD0:
   5526     eax = MEM32(ecx + 0xC); /* 0x38039DD0: mov eax, dword ptr [ecx + 0xc] */
   5527     edx = MEM32(eax + 0x18); /* 0x38039DD3: mov edx, dword ptr [eax + 0x18] */
   5528     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5529     ecx = 0; /* 0x38039DD6: xor ecx, ecx */
   5530     _cf = 0;
   5531     _flag_k = FK_TEST;
   5532     /* cmp edx, 1 */ /* 0x38039DD8: cmp edx, 1 */
   5533     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   5534     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5535     _flag_k = FK_CMP;
   5536     SET_LO8(ecx, (CMP_EQ(_flag_a, _flag_b)) ? 1 : 0); /* 0x38039DDB: sete cl */
   5537     SET_LO8(eax, LO8(ecx)); /* 0x38039DDE: mov al, cl */
   5538     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x38039DE0: ret  */
   5539     RECOMP_REGS_OUT();
   5540 }
   5541 
   5542 void sub_3802D210(void) {
   5543     int _fpu_cmp = 0;
   5544     uint32_t _cf = 0;
   5545     int _df = 1;
   5546     uint32_t _flag_k = FK_NONE;
   5547     uint32_t _flag_a = 0, _flag_b = 0;
   5548     uint32_t _itail_tgt = 0;
   5549     RECOMP_REGS_LOCALS
   5550     RECOMP_ENTER(0x3802D210u);
   5551 
   5552 L_3802D210:
   5553     eax = MEM32(ecx + 0x8C); /* 0x3802D210: mov eax, dword ptr [ecx + 0x8c] */
   5554     /* test eax, eax */ /* 0x3802D216: test eax, eax */
   5555     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   5556     _cf = 0;
   5557     _flag_k = FK_TEST;
   5558     PUSH32(esp, ebx); /* 0x3802D218: push ebx */
   5559     PUSH32(esp, esi); /* 0x3802D219: push esi */
   5560     PUSH32(esp, edi); /* 0x3802D21A: push edi */
   5561     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D221; /* 0x3802D21B: je 0x3802d221 */
   5562 L_3802D21D:
   5563     ebx = eax; /* 0x3802D21D: mov ebx, eax */
   5564     goto L_3802D258; /* 0x3802D21F: jmp 0x3802d258 */
   5565 L_3802D221:
   5566     eax = MEM32(ecx + 0x88); /* 0x3802D221: mov eax, dword ptr [ecx + 0x88] */
   5567     edx = MEM32(eax + 0x4); /* 0x3802D227: mov edx, dword ptr [eax + 4] */
   5568     /* test edx, edx */ /* 0x3802D22A: test edx, edx */
   5569     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   5570     _cf = 0;
   5571     _flag_k = FK_TEST;
   5572     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D243; /* 0x3802D22C: je 0x3802d243 */
   5573 L_3802D22E:
   5574     esi = MEM32(eax + 0x8); /* 0x3802D22E: mov esi, dword ptr [eax + 8] */
   5575     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
   5576     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5577     esi = esi - edx; /* 0x3802D231: sub esi, edx */
   5578     _flag_k = FK_CMP;
   5579     /* test esi, 0xFFFFFFFCu */ /* 0x3802D233: test esi, 0xfffffffc */
   5580     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0xFFFFFFFCu);
   5581     _cf = 0;
   5582     _flag_k = FK_TEST;
   5583     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D243; /* 0x3802D239: je 0x3802d243 */
   5584 L_3802D23B:
   5585     MEM32(ecx + 0x8C) = eax; /* 0x3802D23B: mov dword ptr [ecx + 0x8c], eax */
   5586     goto L_3802D252; /* 0x3802D241: jmp 0x3802d252 */
   5587 L_3802D243:
   5588     eax = MEM32(ecx + 0x98); /* 0x3802D243: mov eax, dword ptr [ecx + 0x98] */
   5589     edx = MEM32(eax + 0x44); /* 0x3802D249: mov edx, dword ptr [eax + 0x44] */
   5590     MEM32(ecx + 0x8C) = edx; /* 0x3802D24C: mov dword ptr [ecx + 0x8c], edx */
   5591 L_3802D252:
   5592     ebx = MEM32(ecx + 0x8C); /* 0x3802D252: mov ebx, dword ptr [ecx + 0x8c] */
   5593 L_3802D258:
   5594     eax = MEM32(ebx + 0x4); /* 0x3802D258: mov eax, dword ptr [ebx + 4] */
   5595     /* test eax, eax */ /* 0x3802D25B: test eax, eax */
   5596     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   5597     _cf = 0;
   5598     _flag_k = FK_TEST;
   5599     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D263; /* 0x3802D25D: jne 0x3802d263 */
   5600 L_3802D25F:
   5601     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5602     esi = 0; /* 0x3802D25F: xor esi, esi */
   5603     _cf = 0;
   5604     _flag_k = FK_TEST;
   5605     goto L_3802D26B; /* 0x3802D261: jmp 0x3802d26b */
   5606 L_3802D263:
   5607     esi = MEM32(ebx + 0x8); /* 0x3802D263: mov esi, dword ptr [ebx + 8] */
   5608     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   5609     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5610     esi = esi - eax; /* 0x3802D266: sub esi, eax */
   5611     _flag_k = FK_CMP;
   5612     if (2u) _cf = (((esi) >> 1) & 1u); /* 0x3802D268: sar esi, 2 */
   5613     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)esi >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   5614     esi = (uint32_t)((int32_t)esi >> 2u);
   5615 L_3802D26B:
   5616     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5617     edi = 0; /* 0x3802D26B: xor edi, edi */
   5618     _cf = 0;
   5619     _flag_k = FK_TEST;
   5620     /* test esi, esi */ /* 0x3802D26D: test esi, esi */
   5621     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi);
   5622     _cf = 0;
   5623     _flag_k = FK_TEST;
   5624     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D2A5; /* 0x3802D26F: jbe 0x3802d2a5 */
   5625 L_3802D271:
   5626     eax = MEM32(ebx + 0x4); /* 0x3802D271: mov eax, dword ptr [ebx + 4] */
   5627     edx = MEM32(eax + edi * 4); /* 0x3802D274: mov edx, dword ptr [eax + edi*4] */
   5628     fp_push(*(float*)&MEM32(edx + 0x20)); /* 0x3802D277: fld dword ptr [edx + 0x20] */
   5629     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E4)); /* 0x3802D27A: fcomp dword ptr [0x3804e8e4] */
   5630     fp_pop();
   5631     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802D280: fnstsw ax */
   5632     /* test HI8(eax), 0x41u */ /* 0x3802D282: test ah, 0x41 */
   5633     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24;
   5634     _cf = 0;
   5635     _flag_k = FK_NARROW(FK_TEST, 24);
   5636     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D2A0; /* 0x3802D285: jne 0x3802d2a0 */
   5637 L_3802D287:
   5638     fp_push(*(float*)&MEM32(edx + 0x20)); /* 0x3802D287: fld dword ptr [edx + 0x20] */
   5639     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(ecx + 0x9C)); /* 0x3802D28A: fcomp dword ptr [ecx + 0x9c] */
   5640     fp_pop();
   5641     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802D290: fnstsw ax */
   5642     /* test HI8(eax), 0x41u */ /* 0x3802D292: test ah, 0x41 */
   5643     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24;
   5644     _cf = 0;
   5645     _flag_k = FK_NARROW(FK_TEST, 24);
   5646     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D2A0; /* 0x3802D295: jne 0x3802d2a0 */
   5647 L_3802D297:
   5648     fp_push(*(float*)&MEM32(edx + 0x20)); /* 0x3802D297: fld dword ptr [edx + 0x20] */
   5649     { float _v = (float)fp_pop(); *(float*)ADDR(ecx + 0x9C) = _v; } /* 0x3802D29A: fstp dword ptr [ecx + 0x9c] */
   5650 L_3802D2A0:
   5651     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(1);
   5652     edi = edi + 1; /* 0x3802D2A0: inc edi */
   5653     _flag_k = FK_INC;
   5654     /* cmp edi, esi */ /* 0x3802D2A1: cmp edi, esi */
   5655     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(esi);
   5656     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5657     _flag_k = FK_CMP;
   5658     RECOMP_BACKEDGE();
   5659     if (CMP_B(_flag_a, _flag_b)) goto L_3802D271; /* 0x3802D2A3: jb 0x3802d271 */
   5660 L_3802D2A5:
   5661     edi = POP32_VAL(esp); /* 0x3802D2A5: pop edi */
   5662     esi = POP32_VAL(esp); /* 0x3802D2A6: pop esi */
   5663     ebx = POP32_VAL(esp); /* 0x3802D2A7: pop ebx */
   5664     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802D2A8: ret  */
   5665     RECOMP_REGS_OUT();
   5666 }
   5667 
   5668 void sub_3802D2B0(void) {
   5669     int _fpu_cmp = 0;
   5670     uint32_t _cf = 0;
   5671     int _df = 1;
   5672     uint32_t _flag_k = FK_NONE;
   5673     uint32_t _flag_a = 0, _flag_b = 0;
   5674     uint32_t _itail_tgt = 0;
   5675     RECOMP_REGS_LOCALS
   5676     RECOMP_ENTER(0x3802D2B0u);
   5677 
   5678 L_3802D2B0:
   5679     PUSH32(esp, ebp); /* 0x3802D2B0: push ebp */
   5680     ebp = esp; /* 0x3802D2B1: mov ebp, esp */
   5681     PUSH32(esp, esi); /* 0x3802D2B3: push esi */
   5682     PUSH32(esp, edi); /* 0x3802D2B4: push edi */
   5683     edi = MEM32(ebp + 0x8); /* 0x3802D2B5: mov edi, dword ptr [ebp + 8] */
   5684     fp_push(*(float*)&MEM32(edi + 0x4)); /* 0x3802D2B8: fld dword ptr [edi + 4] */
   5685     esi = ecx; /* 0x3802D2BB: mov esi, ecx */
   5686     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(esi + 0x9C)); /* 0x3802D2BD: fcomp dword ptr [esi + 0x9c] */
   5687     fp_pop();
   5688     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802D2C3: fnstsw ax */
   5689     /* test HI8(eax), 0x41u */ /* 0x3802D2C5: test ah, 0x41 */
   5690     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x41u) << 24;
   5691     _cf = 0;
   5692     _flag_k = FK_NARROW(FK_TEST, 24);
   5693     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D2E1; /* 0x3802D2C8: jne 0x3802d2e1 */
   5694 L_3802D2CA:
   5695     eax = MEM32(0x3804E234); /* 0x3802D2CA: mov eax, dword ptr [0x3804e234] */
   5696     fp_push(*(float*)&MEM32(0x3804F678)); /* 0x3802D2CF: fld dword ptr [0x3804f678] */
   5697     edi = POP32_VAL(esp); /* 0x3802D2D5: pop edi */
   5698     MEM32(eax) = 0; /* 0x3802D2D6: mov dword ptr [eax], 0 */
   5699     esi = POP32_VAL(esp); /* 0x3802D2DC: pop esi */
   5700     ebp = POP32_VAL(esp); /* 0x3802D2DD: pop ebp */
   5701     RECOMP_FLAGS_OUT(); esp += 24; { RECOMP_REGS_OUT(); return; } /* 0x3802D2DE: ret 0x14 */
   5702 L_3802D2E1:
   5703     edx = MEM32(ebp + 0x18); /* 0x3802D2E1: mov edx, dword ptr [ebp + 0x18] */
   5704     /* cmp edx, 0xFFFFFFFFu */ /* 0x3802D2E4: cmp edx, -1 */
   5705     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0xFFFFFFFFu);
   5706     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5707     _flag_k = FK_CMP;
   5708     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D306; /* 0x3802D2E7: jne 0x3802d306 */
   5709 L_3802D2E9:
   5710     ecx = esi; /* 0x3802D2E9: mov ecx, esi */
   5711     RECOMP_ICALL(0x3802BF20u); /* 0x3802D2EB: call 0x3802bf20 */ /* not lifted */
   5712     RECOMP_FLAGS_IN();
   5713     edx = MEM32(eax); /* 0x3802D2F0: mov edx, dword ptr [eax] */
   5714     PUSH32(esp, 0); /* 0x3802D2F2: push 0 */
   5715     PUSH32(esp, 0); /* 0x3802D2F4: push 0 */
   5716     PUSH32(esp, edi); /* 0x3802D2F6: push edi */
   5717     ecx = eax; /* 0x3802D2F7: mov ecx, eax */
   5718     RECOMP_ICALL(MEM32(edx + 0x20)); /* 0x3802D2F9: call dword ptr [edx + 0x20] */
   5719     RECOMP_FLAGS_IN();
   5720     PUSH32(esp, edi); /* 0x3802D2FC: push edi */
   5721     ecx = esi; /* 0x3802D2FD: mov ecx, esi */
   5722     RECOMP_ICALL(0x3802B4D0u); /* 0x3802D2FF: call 0x3802b4d0 */ /* not lifted */
   5723     RECOMP_FLAGS_IN();
   5724     edx = eax; /* 0x3802D304: mov edx, eax */
   5725 L_3802D306:
   5726     fp_push(*(float*)&MEM32(ebp + 0x14)); /* 0x3802D306: fld dword ptr [ebp + 0x14] */
   5727     _fpu_cmp = FPU_CMP(_st[0], (double)*(float*)ADDR(0x3804E8E0)); /* 0x3802D309: fcomp dword ptr [0x3804e8e0] */
   5728     fp_pop();
   5729     eax = (eax & 0xFFFF0000u) | ((_fpu_cmp >= 0x10000) ? (uint32_t)(_fpu_cmp & 0x4700) : _fpu_cmp == 2 ? 0x4500u : _fpu_cmp < 0 ? 0x0100u : _fpu_cmp == 0 ? 0x4000u : 0x0000u); /* 0x3802D30F: fnstsw ax */
   5730     /* test HI8(eax), 0x40u */ /* 0x3802D311: test ah, 0x40 */
   5731     _flag_a = (uint32_t)(HI8(eax)) << 24; _flag_b = (uint32_t)(0x40u) << 24;
   5732     _cf = 0;
   5733     _flag_k = FK_NARROW(FK_TEST, 24);
   5734     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D31C; /* 0x3802D314: je 0x3802d31c */
   5735 L_3802D316:
   5736     eax = MEM32(edi + 0x4); /* 0x3802D316: mov eax, dword ptr [edi + 4] */
   5737     MEM32(ebp + 0x14) = eax; /* 0x3802D319: mov dword ptr [ebp + 0x14], eax */
   5738 L_3802D31C:
   5739     eax = MEM32(esi + 0x8C); /* 0x3802D31C: mov eax, dword ptr [esi + 0x8c] */
   5740     /* test eax, eax */ /* 0x3802D322: test eax, eax */
   5741     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   5742     _cf = 0;
   5743     _flag_k = FK_TEST;
   5744     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D32A; /* 0x3802D324: je 0x3802d32a */
   5745 L_3802D326:
   5746     esi = eax; /* 0x3802D326: mov esi, eax */
   5747     goto L_3802D357; /* 0x3802D328: jmp 0x3802d357 */
   5748 L_3802D32A:
   5749     eax = MEM32(esi + 0x88); /* 0x3802D32A: mov eax, dword ptr [esi + 0x88] */
   5750     ecx = MEM32(eax + 0x4); /* 0x3802D330: mov ecx, dword ptr [eax + 4] */
   5751     /* test ecx, ecx */ /* 0x3802D333: test ecx, ecx */
   5752     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   5753     _cf = 0;
   5754     _flag_k = FK_TEST;
   5755     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D346; /* 0x3802D335: je 0x3802d346 */
   5756 L_3802D337:
   5757     PUSH32(esp, ebx); /* 0x3802D337: push ebx */
   5758     ebx = MEM32(eax + 0x8); /* 0x3802D338: mov ebx, dword ptr [eax + 8] */
   5759     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(ecx);
   5760     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5761     ebx = ebx - ecx; /* 0x3802D33B: sub ebx, ecx */
   5762     _flag_k = FK_CMP;
   5763     /* test ebx, 0xFFFFFFFCu */ /* 0x3802D33D: test ebx, 0xfffffffc */
   5764     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0xFFFFFFFCu);
   5765     _cf = 0;
   5766     _flag_k = FK_TEST;
   5767     ebx = POP32_VAL(esp); /* 0x3802D343: pop ebx */
   5768     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D34F; /* 0x3802D344: jne 0x3802d34f */
   5769 L_3802D346:
   5770     ecx = MEM32(esi + 0x98); /* 0x3802D346: mov ecx, dword ptr [esi + 0x98] */
   5771     eax = MEM32(ecx + 0x44); /* 0x3802D34C: mov eax, dword ptr [ecx + 0x44] */
   5772 L_3802D34F:
   5773     MEM32(esi + 0x8C) = eax; /* 0x3802D34F: mov dword ptr [esi + 0x8c], eax */
   5774     esi = eax; /* 0x3802D355: mov esi, eax */
   5775 L_3802D357:
   5776     ecx = MEM32(esi + 0x4); /* 0x3802D357: mov ecx, dword ptr [esi + 4] */
   5777     ecx = MEM32(ecx + edx * 4); /* 0x3802D35A: mov ecx, dword ptr [ecx + edx*4] */
   5778     edx = MEM32(ebp + 0x14); /* 0x3802D35D: mov edx, dword ptr [ebp + 0x14] */
   5779     eax = MEM32(ebp + 0x10); /* 0x3802D360: mov eax, dword ptr [ebp + 0x10] */
   5780     PUSH32(esp, edx); /* 0x3802D363: push edx */
   5781     edx = MEM32(ebp + 0xC); /* 0x3802D364: mov edx, dword ptr [ebp + 0xc] */
   5782     PUSH32(esp, eax); /* 0x3802D367: push eax */
   5783     PUSH32(esp, edx); /* 0x3802D368: push edx */
   5784     PUSH32(esp, edi); /* 0x3802D369: push edi */
   5785     RECOMP_ICALL(0x3803F0E0u); /* 0x3802D36A: call 0x3803f0e0 */ /* not lifted */
   5786     RECOMP_FLAGS_IN();
   5787     edi = POP32_VAL(esp); /* 0x3802D36F: pop edi */
   5788     esi = POP32_VAL(esp); /* 0x3802D370: pop esi */
   5789     ebp = POP32_VAL(esp); /* 0x3802D371: pop ebp */
   5790     RECOMP_FLAGS_OUT(); esp += 24; { RECOMP_REGS_OUT(); return; } /* 0x3802D372: ret 0x14 */
   5791     RECOMP_REGS_OUT();
   5792 }
   5793 
   5794 void sub_3802D380(void) {
   5795     int _fpu_cmp = 0;
   5796     uint32_t _cf = 0;
   5797     int _df = 1;
   5798     uint32_t _flag_k = FK_NONE;
   5799     uint32_t _flag_a = 0, _flag_b = 0;
   5800     uint32_t _itail_tgt = 0;
   5801     RECOMP_REGS_LOCALS
   5802     RECOMP_ENTER(0x3802D380u);
   5803 
   5804 L_3802D380:
   5805     PUSH32(esp, ebx); /* 0x3802D380: push ebx */
   5806     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5807     eax = 0; /* 0x3802D381: xor eax, eax */
   5808     _cf = 0;
   5809     _flag_k = FK_TEST;
   5810     PUSH32(esp, esi); /* 0x3802D383: push esi */
   5811     esi = ecx; /* 0x3802D384: mov esi, ecx */
   5812     MEM32(esi + 0x3C) = eax; /* 0x3802D386: mov dword ptr [esi + 0x3c], eax */
   5813     MEM32(esi + 0x40) = eax; /* 0x3802D389: mov dword ptr [esi + 0x40], eax */
   5814     MEM32(esi + 0x44) = eax; /* 0x3802D38C: mov dword ptr [esi + 0x44], eax */
   5815     eax = MEM32(esi + 0x74); /* 0x3802D38F: mov eax, dword ptr [esi + 0x74] */
   5816     ebx = MEM32(eax + 0x8); /* 0x3802D392: mov ebx, dword ptr [eax + 8] */
   5817     PUSH32(esp, edi); /* 0x3802D395: push edi */
   5818     edi = MEM32(eax + 0x4); /* 0x3802D396: mov edi, dword ptr [eax + 4] */
   5819     /* cmp edi, ebx */ /* 0x3802D399: cmp edi, ebx */
   5820     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
   5821     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5822     _flag_k = FK_CMP;
   5823     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D3AF; /* 0x3802D39B: je 0x3802d3af */
   5824 L_3802D39D:
   5825     ecx = MEM32(edi + 0x4); /* 0x3802D39D: mov ecx, dword ptr [edi + 4] */
   5826     eax = MEM32(esi); /* 0x3802D3A0: mov eax, dword ptr [esi] */
   5827     PUSH32(esp, ecx); /* 0x3802D3A2: push ecx */
   5828     ecx = esi; /* 0x3802D3A3: mov ecx, esi */
   5829     RECOMP_ICALL(MEM32(eax + 0x5C)); /* 0x3802D3A5: call dword ptr [eax + 0x5c] */
   5830     RECOMP_FLAGS_IN();
   5831     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(8);
   5832     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5833     edi = edi + 8; /* 0x3802D3A8: add edi, 8 */
   5834     _flag_k = FK_ADD;
   5835     /* cmp edi, ebx */ /* 0x3802D3AB: cmp edi, ebx */
   5836     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
   5837     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5838     _flag_k = FK_CMP;
   5839     RECOMP_BACKEDGE();
   5840     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D39D; /* 0x3802D3AD: jne 0x3802d39d */
   5841 L_3802D3AF:
   5842     edi = POP32_VAL(esp); /* 0x3802D3AF: pop edi */
   5843     esi = POP32_VAL(esp); /* 0x3802D3B0: pop esi */
   5844     ebx = POP32_VAL(esp); /* 0x3802D3B1: pop ebx */
   5845     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802D3B2: ret  */
   5846     RECOMP_REGS_OUT();
   5847 }
   5848 
   5849 void sub_3802D3C0(void) {
   5850     int _fpu_cmp = 0;
   5851     uint32_t _cf = 0;
   5852     int _df = 1;
   5853     uint32_t _flag_k = FK_NONE;
   5854     uint32_t _flag_a = 0, _flag_b = 0;
   5855     uint32_t _itail_tgt = 0;
   5856     RECOMP_REGS_LOCALS
   5857     RECOMP_ENTER(0x3802D3C0u);
   5858 
   5859 L_3802D3C0:
   5860     PUSH32(esp, ebp); /* 0x3802D3C0: push ebp */
   5861     ebp = esp; /* 0x3802D3C1: mov ebp, esp */
   5862     eax = MEM32(ebp + 0x8); /* 0x3802D3C3: mov eax, dword ptr [ebp + 8] */
   5863     /* test eax, eax */ /* 0x3802D3C6: test eax, eax */
   5864     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   5865     _cf = 0;
   5866     _flag_k = FK_TEST;
   5867     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D3CD; /* 0x3802D3C8: je 0x3802d3cd */
   5868 L_3802D3CA:
   5869     _flag_a = (uint32_t)(MEM32(ecx + 0x3C)); _flag_b = (uint32_t)(1);
   5870     MEM32(ecx + 0x3C) = MEM32(ecx + 0x3C) + 1; /* 0x3802D3CA: inc dword ptr [ecx + 0x3c] */
   5871     _flag_k = FK_INC;
   5872 L_3802D3CD:
   5873     ebp = POP32_VAL(esp); /* 0x3802D3CD: pop ebp */
   5874     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802D3CE: ret 4 */
   5875     RECOMP_REGS_OUT();
   5876 }
   5877 
   5878 void sub_3802D3E0(void) {
   5879     int _fpu_cmp = 0;
   5880     uint32_t _cf = 0;
   5881     int _df = 1;
   5882     uint32_t _flag_k = FK_NONE;
   5883     uint32_t _flag_a = 0, _flag_b = 0;
   5884     uint32_t _itail_tgt = 0;
   5885     RECOMP_REGS_LOCALS
   5886     RECOMP_ENTER(0x3802D3E0u);
   5887 
   5888 L_3802D3E0:
   5889     eax = MEM32(ecx + 0x98); /* 0x3802D3E0: mov eax, dword ptr [ecx + 0x98] */
   5890     /* test eax, eax */ /* 0x3802D3E6: test eax, eax */
   5891     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   5892     _cf = 0;
   5893     _flag_k = FK_TEST;
   5894     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D3EE; /* 0x3802D3E8: je 0x3802d3ee */
   5895 L_3802D3EA:
   5896     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x20u);
   5897     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5898     eax = eax + 0x20u; /* 0x3802D3EA: add eax, 0x20 */
   5899     _flag_k = FK_ADD;
   5900     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802D3ED: ret  */
   5901 L_3802D3EE:
   5902     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5903     eax = 0; /* 0x3802D3EE: xor eax, eax */
   5904     _cf = 0;
   5905     _flag_k = FK_TEST;
   5906     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802D3F0: ret  */
   5907     RECOMP_REGS_OUT();
   5908 }
   5909 
   5910 void sub_3802D400(void) {
   5911     int _fpu_cmp = 0;
   5912     uint32_t _cf = 0;
   5913     int _df = 1;
   5914     uint32_t _flag_k = FK_NONE;
   5915     uint32_t _flag_a = 0, _flag_b = 0;
   5916     uint32_t _itail_tgt = 0;
   5917     RECOMP_REGS_LOCALS
   5918     RECOMP_ENTER(0x3802D400u);
   5919 
   5920 L_3802D400:
   5921     PUSH32(esp, ebp); /* 0x3802D400: push ebp */
   5922     ebp = esp; /* 0x3802D401: mov ebp, esp */
   5923     edx = MEM32(ecx + 0xA4); /* 0x3802D403: mov edx, dword ptr [ecx + 0xa4] */
   5924     eax = MEM32(ebp + 0x8); /* 0x3802D409: mov eax, dword ptr [ebp + 8] */
   5925     MEM32(eax) = edx; /* 0x3802D40C: mov dword ptr [eax], edx */
   5926     ecx = MEM32(ecx + 0xA8); /* 0x3802D40E: mov ecx, dword ptr [ecx + 0xa8] */
   5927     MEM32(eax + 0x4) = ecx; /* 0x3802D414: mov dword ptr [eax + 4], ecx */
   5928     ebp = POP32_VAL(esp); /* 0x3802D417: pop ebp */
   5929     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802D418: ret 4 */
   5930     RECOMP_REGS_OUT();
   5931 }
   5932 
   5933 void sub_3802D420(void) {
   5934     int _fpu_cmp = 0;
   5935     uint32_t _cf = 0;
   5936     int _df = 1;
   5937     uint32_t _flag_k = FK_NONE;
   5938     uint32_t _flag_a = 0, _flag_b = 0;
   5939     uint32_t _itail_tgt = 0;
   5940     RECOMP_REGS_LOCALS
   5941     RECOMP_ENTER(0x3802D420u);
   5942 
   5943 L_3802D420:
   5944     PUSH32(esp, ebp); /* 0x3802D420: push ebp */
   5945     ebp = esp; /* 0x3802D421: mov ebp, esp */
   5946     eax = ecx; /* 0x3802D423: mov eax, ecx */
   5947     ecx = MEM32(ebp + 0x8); /* 0x3802D425: mov ecx, dword ptr [ebp + 8] */
   5948     SET_LO8(edx, MEM8(ecx)); /* 0x3802D428: mov dl, byte ptr [ecx] */
   5949     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5950     ecx = 0; /* 0x3802D42A: xor ecx, ecx */
   5951     _cf = 0;
   5952     _flag_k = FK_TEST;
   5953     MEM8(eax) = (uint8_t)(LO8(edx)); /* 0x3802D42C: mov byte ptr [eax], dl */
   5954     MEM32(eax + 0x4) = ecx; /* 0x3802D42E: mov dword ptr [eax + 4], ecx */
   5955     MEM32(eax + 0x8) = ecx; /* 0x3802D431: mov dword ptr [eax + 8], ecx */
   5956     MEM32(eax + 0xC) = ecx; /* 0x3802D434: mov dword ptr [eax + 0xc], ecx */
   5957     ebp = POP32_VAL(esp); /* 0x3802D437: pop ebp */
   5958     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802D438: ret 4 */
   5959     RECOMP_REGS_OUT();
   5960 }
   5961 
   5962 void sub_3802D440(void) {
   5963     int _fpu_cmp = 0;
   5964     uint32_t _cf = 0;
   5965     int _df = 1;
   5966     uint32_t _flag_k = FK_NONE;
   5967     uint32_t _flag_a = 0, _flag_b = 0;
   5968     uint32_t _itail_tgt = 0;
   5969     RECOMP_REGS_LOCALS
   5970     RECOMP_ENTER(0x3802D440u);
   5971 
   5972 L_3802D440:
   5973     PUSH32(esp, ebp); /* 0x3802D440: push ebp */
   5974     ebp = esp; /* 0x3802D441: mov ebp, esp */
   5975     eax = MEM32(ebp + 0xC); /* 0x3802D443: mov eax, dword ptr [ebp + 0xc] */
   5976     edx = MEM32(ebp + 0x8); /* 0x3802D446: mov edx, dword ptr [ebp + 8] */
   5977     PUSH32(esp, ebx); /* 0x3802D449: push ebx */
   5978     PUSH32(esp, esi); /* 0x3802D44A: push esi */
   5979     esi = ecx; /* 0x3802D44B: mov esi, ecx */
   5980     SET_LO8(ecx, MEM8(eax)); /* 0x3802D44D: mov cl, byte ptr [eax] */
   5981     MEM8(esi) = (uint8_t)(LO8(ecx)); /* 0x3802D44F: mov byte ptr [esi], cl */
   5982     SET_LO8(eax, MEM8(edx)); /* 0x3802D451: mov al, byte ptr [edx] */
   5983     PUSH32(esp, edi); /* 0x3802D453: push edi */
   5984     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5985     ebx = 0; /* 0x3802D454: xor ebx, ebx */
   5986     _cf = 0;
   5987     _flag_k = FK_TEST;
   5988     PUSH32(esp, 0x18u); /* 0x3802D456: push 0x18 */
   5989     MEM8(esi + 0x1) = (uint8_t)(LO8(eax)); /* 0x3802D458: mov byte ptr [esi + 1], al */
   5990     MEM8(esi + 0xC) = (uint8_t)(LO8(ebx)); /* 0x3802D45B: mov byte ptr [esi + 0xc], bl */
   5991     RECOMP_ICALL(0x3804B676u); /* 0x3802D45E: call 0x3804b676 */ /* not lifted */
   5992     RECOMP_FLAGS_IN();
   5993     MEM32(eax + 0x4) = ebx; /* 0x3802D463: mov dword ptr [eax + 4], ebx */
   5994     MEM8(eax + 0x15) = (uint8_t)(LO8(ebx)); /* 0x3802D466: mov byte ptr [eax + 0x15], bl */
   5995     SET_LO8(ecx, 1); /* 0x3802D469: mov cl, 1 */
   5996     MEM8(eax + 0x14) = (uint8_t)(LO8(ecx)); /* 0x3802D46B: mov byte ptr [eax + 0x14], cl */
   5997     MEM32(esi + 0x8) = eax; /* 0x3802D46E: mov dword ptr [esi + 8], eax */
   5998     MEM8(eax + 0x15) = (uint8_t)(LO8(ecx)); /* 0x3802D471: mov byte ptr [eax + 0x15], cl */
   5999     ecx = MEM32(esi + 0x8); /* 0x3802D474: mov ecx, dword ptr [esi + 8] */
   6000     MEM32(ecx) = ebx; /* 0x3802D477: mov dword ptr [ecx], ebx */
   6001     edx = MEM32(esi + 0x8); /* 0x3802D479: mov edx, dword ptr [esi + 8] */
   6002     MEM32(edx + 0x8) = ebx; /* 0x3802D47C: mov dword ptr [edx + 8], ebx */
   6003     edi = MEM32(esi + 0x8); /* 0x3802D47F: mov edi, dword ptr [esi + 8] */
   6004     PUSH32(esp, 0x18u); /* 0x3802D482: push 0x18 */
   6005     RECOMP_ICALL(0x3804B676u); /* 0x3802D484: call 0x3804b676 */ /* not lifted */
   6006     RECOMP_FLAGS_IN();
   6007     MEM32(eax + 0x4) = edi; /* 0x3802D489: mov dword ptr [eax + 4], edi */
   6008     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3802D48C: mov byte ptr [eax + 0x14], bl */
   6009     MEM8(eax + 0x15) = (uint8_t)(LO8(ebx)); /* 0x3802D48F: mov byte ptr [eax + 0x15], bl */
   6010     MEM32(esi + 0x4) = eax; /* 0x3802D492: mov dword ptr [esi + 4], eax */
   6011     MEM32(eax) = eax; /* 0x3802D495: mov dword ptr [eax], eax */
   6012     eax = MEM32(esi + 0x4); /* 0x3802D497: mov eax, dword ptr [esi + 4] */
   6013     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   6014     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6015     esp = esp + 8; /* 0x3802D49A: add esp, 8 */
   6016     _flag_k = FK_ADD;
   6017     MEM32(eax + 0x8) = eax; /* 0x3802D49D: mov dword ptr [eax + 8], eax */
   6018     edi = POP32_VAL(esp); /* 0x3802D4A0: pop edi */
   6019     MEM32(esi + 0x10) = ebx; /* 0x3802D4A1: mov dword ptr [esi + 0x10], ebx */
   6020     eax = esi; /* 0x3802D4A4: mov eax, esi */
   6021     esi = POP32_VAL(esp); /* 0x3802D4A6: pop esi */
   6022     ebx = POP32_VAL(esp); /* 0x3802D4A7: pop ebx */
   6023     ebp = POP32_VAL(esp); /* 0x3802D4A8: pop ebp */
   6024     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802D4A9: ret 8 */
   6025     RECOMP_REGS_OUT();
   6026 }
   6027 
   6028 void sub_3802D4B0(void) {
   6029     int _fpu_cmp = 0;
   6030     uint32_t _cf = 0;
   6031     int _df = 1;
   6032     uint32_t _flag_k = FK_NONE;
   6033     uint32_t _flag_a = 0, _flag_b = 0;
   6034     uint32_t _itail_tgt = 0;
   6035     RECOMP_REGS_LOCALS
   6036     RECOMP_ENTER(0x3802D4B0u);
   6037 
   6038 L_3802D4B0:
   6039     edx = MEM32(ecx + 0x4); /* 0x3802D4B0: mov edx, dword ptr [ecx + 4] */
   6040     /* test edx, edx */ /* 0x3802D4B3: test edx, edx */
   6041     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   6042     _cf = 0;
   6043     _flag_k = FK_TEST;
   6044     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D4BA; /* 0x3802D4B5: jne 0x3802d4ba */
   6045 L_3802D4B7:
   6046     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   6047     eax = 0; /* 0x3802D4B7: xor eax, eax */
   6048     _cf = 0;
   6049     _flag_k = FK_TEST;
   6050     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802D4B9: ret  */
   6051 L_3802D4BA:
   6052     eax = MEM32(ecx + 0x8); /* 0x3802D4BA: mov eax, dword ptr [ecx + 8] */
   6053     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   6054     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6055     eax = eax - edx; /* 0x3802D4BD: sub eax, edx */
   6056     _flag_k = FK_CMP;
   6057     if (2u) _cf = (((eax) >> 1) & 1u); /* 0x3802D4BF: sar eax, 2 */
   6058     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6059     eax = (uint32_t)((int32_t)eax >> 2u);
   6060     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802D4C2: ret  */
   6061     RECOMP_REGS_OUT();
   6062 }
   6063 
   6064 void sub_3802D4D0(void) {
   6065     int _fpu_cmp = 0;
   6066     uint32_t _cf = 0;
   6067     int _df = 1;
   6068     uint32_t _flag_k = FK_NONE;
   6069     uint32_t _flag_a = 0, _flag_b = 0;
   6070     uint32_t _itail_tgt = 0;
   6071     RECOMP_REGS_LOCALS
   6072     RECOMP_ENTER(0x3802D4D0u);
   6073 
   6074 L_3802D4D0:
   6075     PUSH32(esp, ebp); /* 0x3802D4D0: push ebp */
   6076     ebp = esp; /* 0x3802D4D1: mov ebp, esp */
   6077     PUSH32(esp, ecx); /* 0x3802D4D3: push ecx */
   6078     PUSH32(esp, esi); /* 0x3802D4D4: push esi */
   6079     esi = ecx; /* 0x3802D4D5: mov esi, ecx */
   6080     eax = MEM32(esi + 0x4); /* 0x3802D4D7: mov eax, dword ptr [esi + 4] */
   6081     PUSH32(esp, eax); /* 0x3802D4DA: push eax */
   6082     MEM32(ebp + (-0x4)) = eax; /* 0x3802D4DB: mov dword ptr [ebp - 4], eax */
   6083     RECOMP_ICALL(0x3804B4F6u); /* 0x3802D4DE: call 0x3804b4f6 */ /* not lifted */
   6084     RECOMP_FLAGS_IN();
   6085     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6086     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6087     esp = esp + 4; /* 0x3802D4E3: add esp, 4 */
   6088     _flag_k = FK_ADD;
   6089     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   6090     eax = 0; /* 0x3802D4E6: xor eax, eax */
   6091     _cf = 0;
   6092     _flag_k = FK_TEST;
   6093     MEM32(esi + 0x4) = eax; /* 0x3802D4E8: mov dword ptr [esi + 4], eax */
   6094     MEM32(esi + 0x8) = eax; /* 0x3802D4EB: mov dword ptr [esi + 8], eax */
   6095     MEM32(esi + 0xC) = eax; /* 0x3802D4EE: mov dword ptr [esi + 0xc], eax */
   6096     esi = POP32_VAL(esp); /* 0x3802D4F1: pop esi */
   6097     esp = ebp; /* 0x3802D4F2: mov esp, ebp */
   6098     ebp = POP32_VAL(esp); /* 0x3802D4F4: pop ebp */
   6099     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802D4F5: ret  */
   6100     RECOMP_REGS_OUT();
   6101 }
   6102 
   6103 void sub_3802D500(void) {
   6104     int _fpu_cmp = 0;
   6105     uint32_t _cf = 0;
   6106     int _df = 1;
   6107     uint32_t _flag_k = FK_NONE;
   6108     uint32_t _flag_a = 0, _flag_b = 0;
   6109     uint32_t _itail_tgt = 0;
   6110     RECOMP_REGS_LOCALS
   6111     RECOMP_ENTER(0x3802D500u);
   6112 
   6113 L_3802D500:
   6114     PUSH32(esp, ebp); /* 0x3802D500: push ebp */
   6115     ebp = esp; /* 0x3802D501: mov ebp, esp */
   6116     eax = MEM32(ebp + 0x8); /* 0x3802D503: mov eax, dword ptr [ebp + 8] */
   6117     PUSH32(esp, esi); /* 0x3802D506: push esi */
   6118     esi = ecx; /* 0x3802D507: mov esi, ecx */
   6119     SET_LO8(ecx, MEM8(eax)); /* 0x3802D509: mov cl, byte ptr [eax] */
   6120     PUSH32(esp, 0xCu); /* 0x3802D50B: push 0xc */
   6121     MEM8(esi) = (uint8_t)(LO8(ecx)); /* 0x3802D50D: mov byte ptr [esi], cl */
   6122     RECOMP_ICALL(0x3804B676u); /* 0x3802D50F: call 0x3804b676 */ /* not lifted */
   6123     RECOMP_FLAGS_IN();
   6124     MEM32(eax) = eax; /* 0x3802D514: mov dword ptr [eax], eax */
   6125     MEM32(eax + 0x4) = eax; /* 0x3802D516: mov dword ptr [eax + 4], eax */
   6126     MEM32(esi + 0x4) = eax; /* 0x3802D519: mov dword ptr [esi + 4], eax */
   6127     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6128     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6129     esp = esp + 4; /* 0x3802D51C: add esp, 4 */
   6130     _flag_k = FK_ADD;
   6131     MEM32(esi + 0x8) = 0; /* 0x3802D51F: mov dword ptr [esi + 8], 0 */
   6132     eax = esi; /* 0x3802D526: mov eax, esi */
   6133     esi = POP32_VAL(esp); /* 0x3802D528: pop esi */
   6134     ebp = POP32_VAL(esp); /* 0x3802D529: pop ebp */
   6135     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802D52A: ret 4 */
   6136     RECOMP_REGS_OUT();
   6137 }
   6138 
   6139 void sub_3802D530(void) {
   6140     int _fpu_cmp = 0;
   6141     uint32_t _cf = 0;
   6142     int _df = 1;
   6143     uint32_t _flag_k = FK_NONE;
   6144     uint32_t _flag_a = 0, _flag_b = 0;
   6145     uint32_t _itail_tgt = 0;
   6146     RECOMP_REGS_LOCALS
   6147     RECOMP_ENTER(0x3802D530u);
   6148 
   6149 L_3802D530:
   6150     PUSH32(esp, ebp); /* 0x3802D530: push ebp */
   6151     ebp = esp; /* 0x3802D531: mov ebp, esp */
   6152     PUSH32(esp, ecx); /* 0x3802D533: push ecx */
   6153     SET_LO8(eax, MEM8(ebp + (-0x1))); /* 0x3802D534: mov al, byte ptr [ebp - 1] */
   6154     PUSH32(esp, esi); /* 0x3802D537: push esi */
   6155     esi = ecx; /* 0x3802D538: mov esi, ecx */
   6156     PUSH32(esp, 0xCu); /* 0x3802D53A: push 0xc */
   6157     MEM8(esi) = (uint8_t)(LO8(eax)); /* 0x3802D53C: mov byte ptr [esi], al */
   6158     RECOMP_ICALL(0x3804B676u); /* 0x3802D53E: call 0x3804b676 */ /* not lifted */
   6159     RECOMP_FLAGS_IN();
   6160     MEM32(eax) = eax; /* 0x3802D543: mov dword ptr [eax], eax */
   6161     MEM32(eax + 0x4) = eax; /* 0x3802D545: mov dword ptr [eax + 4], eax */
   6162     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6163     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6164     esp = esp + 4; /* 0x3802D548: add esp, 4 */
   6165     _flag_k = FK_ADD;
   6166     MEM32(esi + 0x4) = eax; /* 0x3802D54B: mov dword ptr [esi + 4], eax */
   6167     MEM32(esi + 0x8) = 0; /* 0x3802D54E: mov dword ptr [esi + 8], 0 */
   6168     esi = POP32_VAL(esp); /* 0x3802D555: pop esi */
   6169     esp = ebp; /* 0x3802D556: mov esp, ebp */
   6170     ebp = POP32_VAL(esp); /* 0x3802D558: pop ebp */
   6171     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802D559: ret  */
   6172     RECOMP_REGS_OUT();
   6173 }
   6174 
   6175 void sub_3802D560(void) {
   6176     int _fpu_cmp = 0;
   6177     uint32_t _cf = 0;
   6178     int _df = 1;
   6179     uint32_t _flag_k = FK_NONE;
   6180     uint32_t _flag_a = 0, _flag_b = 0;
   6181     uint32_t _itail_tgt = 0;
   6182     RECOMP_REGS_LOCALS
   6183     RECOMP_ENTER(0x3802D560u);
   6184 
   6185 L_3802D560:
   6186     PUSH32(esp, ebp); /* 0x3802D560: push ebp */
   6187     ebp = esp; /* 0x3802D561: mov ebp, esp */
   6188     PUSH32(esp, ecx); /* 0x3802D563: push ecx */
   6189     eax = MEM32(ebp + 0x10); /* 0x3802D564: mov eax, dword ptr [ebp + 0x10] */
   6190     PUSH32(esp, ebx); /* 0x3802D567: push ebx */
   6191     ebx = MEM32(ebp + 0xC); /* 0x3802D568: mov ebx, dword ptr [ebp + 0xc] */
   6192     /* cmp ebx, eax */ /* 0x3802D56B: cmp ebx, eax */
   6193     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(eax);
   6194     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6195     _flag_k = FK_CMP;
   6196     MEM32(ebp + (-0x4)) = ecx; /* 0x3802D56D: mov dword ptr [ebp - 4], ecx */
   6197     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D5BC; /* 0x3802D570: je 0x3802d5bc */
   6198 L_3802D572:
   6199     PUSH32(esp, esi); /* 0x3802D572: push esi */
   6200     PUSH32(esp, edi); /* 0x3802D573: push edi */
   6201     edi = MEM32(ebp + 0x8); /* 0x3802D574: mov edi, dword ptr [ebp + 8] */
   6202 L_3802D577:
   6203     esi = MEM32(edi + 0x4); /* 0x3802D577: mov esi, dword ptr [edi + 4] */
   6204     PUSH32(esp, 0xCu); /* 0x3802D57A: push 0xc */
   6205     RECOMP_ICALL(0x3804B676u); /* 0x3802D57C: call 0x3804b676 */ /* not lifted */
   6206     RECOMP_FLAGS_IN();
   6207     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6208     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6209     esp = esp + 4; /* 0x3802D581: add esp, 4 */
   6210     _flag_k = FK_ADD;
   6211     /* test edi, edi */ /* 0x3802D584: test edi, edi */
   6212     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
   6213     _cf = 0;
   6214     _flag_k = FK_TEST;
   6215     ecx = edi; /* 0x3802D586: mov ecx, edi */
   6216     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D58C; /* 0x3802D588: jne 0x3802d58c */
   6217 L_3802D58A:
   6218     ecx = eax; /* 0x3802D58A: mov ecx, eax */
   6219 L_3802D58C:
   6220     /* test esi, esi */ /* 0x3802D58C: test esi, esi */
   6221     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi);
   6222     _cf = 0;
   6223     _flag_k = FK_TEST;
   6224     MEM32(eax) = ecx; /* 0x3802D58E: mov dword ptr [eax], ecx */
   6225     ecx = esi; /* 0x3802D590: mov ecx, esi */
   6226     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D596; /* 0x3802D592: jne 0x3802d596 */
   6227 L_3802D594:
   6228     ecx = eax; /* 0x3802D594: mov ecx, eax */
   6229 L_3802D596:
   6230     MEM32(eax + 0x4) = ecx; /* 0x3802D596: mov dword ptr [eax + 4], ecx */
   6231     MEM32(edi + 0x4) = eax; /* 0x3802D599: mov dword ptr [edi + 4], eax */
   6232     ecx = MEM32(eax + 0x4); /* 0x3802D59C: mov ecx, dword ptr [eax + 4] */
   6233     MEM32(ecx) = eax; /* 0x3802D59F: mov dword ptr [ecx], eax */
   6234     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(8);
   6235     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6236     eax = eax + 8; /* 0x3802D5A1: add eax, 8 */
   6237     _flag_k = FK_ADD;
   6238     /* test eax, eax */ /* 0x3802D5A4: test eax, eax */
   6239     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6240     _cf = 0;
   6241     _flag_k = FK_TEST;
   6242     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D5AD; /* 0x3802D5A6: je 0x3802d5ad */
   6243 L_3802D5A8:
   6244     edx = MEM32(ebx + 0x8); /* 0x3802D5A8: mov edx, dword ptr [ebx + 8] */
   6245     MEM32(eax) = edx; /* 0x3802D5AB: mov dword ptr [eax], edx */
   6246 L_3802D5AD:
   6247     eax = MEM32(ebp + (-0x4)); /* 0x3802D5AD: mov eax, dword ptr [ebp - 4] */
   6248     _flag_a = (uint32_t)(MEM32(eax + 0x8)); _flag_b = (uint32_t)(1);
   6249     MEM32(eax + 0x8) = MEM32(eax + 0x8) + 1; /* 0x3802D5B0: inc dword ptr [eax + 8] */
   6250     _flag_k = FK_INC;
   6251     ebx = MEM32(ebx); /* 0x3802D5B3: mov ebx, dword ptr [ebx] */
   6252     /* cmp ebx, MEM32(ebp + 0x10) */ /* 0x3802D5B5: cmp ebx, dword ptr [ebp + 0x10] */
   6253     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(MEM32(ebp + 0x10));
   6254     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6255     _flag_k = FK_CMP;
   6256     RECOMP_BACKEDGE();
   6257     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D577; /* 0x3802D5B8: jne 0x3802d577 */
   6258 L_3802D5BA:
   6259     edi = POP32_VAL(esp); /* 0x3802D5BA: pop edi */
   6260     esi = POP32_VAL(esp); /* 0x3802D5BB: pop esi */
   6261 L_3802D5BC:
   6262     ebx = POP32_VAL(esp); /* 0x3802D5BC: pop ebx */
   6263     esp = ebp; /* 0x3802D5BD: mov esp, ebp */
   6264     ebp = POP32_VAL(esp); /* 0x3802D5BF: pop ebp */
   6265     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802D5C0: ret 0xc */
   6266     RECOMP_REGS_OUT();
   6267 }
   6268 
   6269 void sub_3802D5D0(void) {
   6270     int _fpu_cmp = 0;
   6271     uint32_t _cf = 0;
   6272     int _df = 1;
   6273     uint32_t _flag_k = FK_NONE;
   6274     uint32_t _flag_a = 0, _flag_b = 0;
   6275     uint32_t _itail_tgt = 0;
   6276     RECOMP_REGS_LOCALS
   6277     RECOMP_ENTER(0x3802D5D0u);
   6278 
   6279 L_3802D5D0:
   6280     PUSH32(esp, ebp); /* 0x3802D5D0: push ebp */
   6281     ebp = esp; /* 0x3802D5D1: mov ebp, esp */
   6282     PUSH32(esp, ebx); /* 0x3802D5D3: push ebx */
   6283     ebx = MEM32(ebp + 0x10); /* 0x3802D5D4: mov ebx, dword ptr [ebp + 0x10] */
   6284     PUSH32(esp, esi); /* 0x3802D5D7: push esi */
   6285     esi = MEM32(ebp + 0xC); /* 0x3802D5D8: mov esi, dword ptr [ebp + 0xc] */
   6286     /* cmp esi, ebx */ /* 0x3802D5DB: cmp esi, ebx */
   6287     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx);
   6288     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6289     _flag_k = FK_CMP;
   6290     PUSH32(esp, edi); /* 0x3802D5DD: push edi */
   6291     edi = ecx; /* 0x3802D5DE: mov edi, ecx */
   6292     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D609; /* 0x3802D5E0: je 0x3802d609 */
   6293 L_3802D5E2:
   6294     eax = esi; /* 0x3802D5E2: mov eax, esi */
   6295     ecx = MEM32(eax + 0x4); /* 0x3802D5E4: mov ecx, dword ptr [eax + 4] */
   6296     edx = MEM32(eax); /* 0x3802D5E7: mov edx, dword ptr [eax] */
   6297     esi = MEM32(esi); /* 0x3802D5E9: mov esi, dword ptr [esi] */
   6298     MEM32(ecx) = edx; /* 0x3802D5EB: mov dword ptr [ecx], edx */
   6299     ecx = MEM32(eax); /* 0x3802D5ED: mov ecx, dword ptr [eax] */
   6300     edx = MEM32(eax + 0x4); /* 0x3802D5EF: mov edx, dword ptr [eax + 4] */
   6301     PUSH32(esp, eax); /* 0x3802D5F2: push eax */
   6302     MEM32(ecx + 0x4) = edx; /* 0x3802D5F3: mov dword ptr [ecx + 4], edx */
   6303     RECOMP_ICALL(0x3804B4F6u); /* 0x3802D5F6: call 0x3804b4f6 */ /* not lifted */
   6304     RECOMP_FLAGS_IN();
   6305     ecx = MEM32(edi + 0x8); /* 0x3802D5FB: mov ecx, dword ptr [edi + 8] */
   6306     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6307     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6308     esp = esp + 4; /* 0x3802D5FE: add esp, 4 */
   6309     _flag_k = FK_ADD;
   6310     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   6311     ecx = ecx - 1; /* 0x3802D601: dec ecx */
   6312     _flag_k = FK_DEC;
   6313     /* cmp esi, ebx */ /* 0x3802D602: cmp esi, ebx */
   6314     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx);
   6315     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6316     _flag_k = FK_CMP;
   6317     MEM32(edi + 0x8) = ecx; /* 0x3802D604: mov dword ptr [edi + 8], ecx */
   6318     RECOMP_BACKEDGE();
   6319     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D5E2; /* 0x3802D607: jne 0x3802d5e2 */
   6320 L_3802D609:
   6321     eax = MEM32(ebp + 0x8); /* 0x3802D609: mov eax, dword ptr [ebp + 8] */
   6322     edi = POP32_VAL(esp); /* 0x3802D60C: pop edi */
   6323     MEM32(eax) = esi; /* 0x3802D60D: mov dword ptr [eax], esi */
   6324     esi = POP32_VAL(esp); /* 0x3802D60F: pop esi */
   6325     ebx = POP32_VAL(esp); /* 0x3802D610: pop ebx */
   6326     ebp = POP32_VAL(esp); /* 0x3802D611: pop ebp */
   6327     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802D612: ret 0xc */
   6328     RECOMP_REGS_OUT();
   6329 }
   6330 
   6331 void sub_3802D620(void) {
   6332     int _fpu_cmp = 0;
   6333     uint32_t _cf = 0;
   6334     int _df = 1;
   6335     uint32_t _flag_k = FK_NONE;
   6336     uint32_t _flag_a = 0, _flag_b = 0;
   6337     uint32_t _itail_tgt = 0;
   6338     RECOMP_REGS_LOCALS
   6339     RECOMP_ENTER(0x3802D620u);
   6340 
   6341 L_3802D620:
   6342     PUSH32(esp, ebp); /* 0x3802D620: push ebp */
   6343     ebp = esp; /* 0x3802D621: mov ebp, esp */
   6344     PUSH32(esp, ecx); /* 0x3802D623: push ecx */
   6345     eax = MEM32(ebp + 0x10); /* 0x3802D624: mov eax, dword ptr [ebp + 0x10] */
   6346     PUSH32(esp, ebx); /* 0x3802D627: push ebx */
   6347     ebx = MEM32(ebp + 0xC); /* 0x3802D628: mov ebx, dword ptr [ebp + 0xc] */
   6348     /* cmp ebx, eax */ /* 0x3802D62B: cmp ebx, eax */
   6349     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(eax);
   6350     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6351     _flag_k = FK_CMP;
   6352     MEM32(ebp + (-0x4)) = ecx; /* 0x3802D62D: mov dword ptr [ebp - 4], ecx */
   6353     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D686; /* 0x3802D630: je 0x3802d686 */
   6354 L_3802D632:
   6355     PUSH32(esp, esi); /* 0x3802D632: push esi */
   6356     esi = MEM32(ebp + 0x8); /* 0x3802D633: mov esi, dword ptr [ebp + 8] */
   6357     PUSH32(esp, edi); /* 0x3802D636: push edi */
   6358 L_3802D637:
   6359     edi = MEM32(esi + 0x4); /* 0x3802D637: mov edi, dword ptr [esi + 4] */
   6360     PUSH32(esp, 0x14u); /* 0x3802D63A: push 0x14 */
   6361     RECOMP_ICALL(0x3804B676u); /* 0x3802D63C: call 0x3804b676 */ /* not lifted */
   6362     RECOMP_FLAGS_IN();
   6363     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6364     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6365     esp = esp + 4; /* 0x3802D641: add esp, 4 */
   6366     _flag_k = FK_ADD;
   6367     /* test esi, esi */ /* 0x3802D644: test esi, esi */
   6368     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi);
   6369     _cf = 0;
   6370     _flag_k = FK_TEST;
   6371     ecx = esi; /* 0x3802D646: mov ecx, esi */
   6372     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D64C; /* 0x3802D648: jne 0x3802d64c */
   6373 L_3802D64A:
   6374     ecx = eax; /* 0x3802D64A: mov ecx, eax */
   6375 L_3802D64C:
   6376     /* test edi, edi */ /* 0x3802D64C: test edi, edi */
   6377     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
   6378     _cf = 0;
   6379     _flag_k = FK_TEST;
   6380     MEM32(eax) = ecx; /* 0x3802D64E: mov dword ptr [eax], ecx */
   6381     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D654; /* 0x3802D650: jne 0x3802d654 */
   6382 L_3802D652:
   6383     edi = eax; /* 0x3802D652: mov edi, eax */
   6384 L_3802D654:
   6385     MEM32(eax + 0x4) = edi; /* 0x3802D654: mov dword ptr [eax + 4], edi */
   6386     MEM32(esi + 0x4) = eax; /* 0x3802D657: mov dword ptr [esi + 4], eax */
   6387     ecx = MEM32(eax + 0x4); /* 0x3802D65A: mov ecx, dword ptr [eax + 4] */
   6388     MEM32(ecx) = eax; /* 0x3802D65D: mov dword ptr [ecx], eax */
   6389     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(8);
   6390     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6391     eax = eax + 8; /* 0x3802D65F: add eax, 8 */
   6392     _flag_k = FK_ADD;
   6393     /* test eax, eax */ /* 0x3802D662: test eax, eax */
   6394     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6395     _cf = 0;
   6396     _flag_k = FK_TEST;
   6397     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D677; /* 0x3802D664: je 0x3802d677 */
   6398 L_3802D666:
   6399     edx = MEM32(ebx + 0x8); /* 0x3802D666: mov edx, dword ptr [ebx + 8] */
   6400     MEM32(eax) = edx; /* 0x3802D669: mov dword ptr [eax], edx */
   6401     ecx = MEM32(ebx + 0xC); /* 0x3802D66B: mov ecx, dword ptr [ebx + 0xc] */
   6402     MEM32(eax + 0x4) = ecx; /* 0x3802D66E: mov dword ptr [eax + 4], ecx */
   6403     edx = MEM32(ebx + 0x10); /* 0x3802D671: mov edx, dword ptr [ebx + 0x10] */
   6404     MEM32(eax + 0x8) = edx; /* 0x3802D674: mov dword ptr [eax + 8], edx */
   6405 L_3802D677:
   6406     eax = MEM32(ebp + (-0x4)); /* 0x3802D677: mov eax, dword ptr [ebp - 4] */
   6407     _flag_a = (uint32_t)(MEM32(eax + 0x8)); _flag_b = (uint32_t)(1);
   6408     MEM32(eax + 0x8) = MEM32(eax + 0x8) + 1; /* 0x3802D67A: inc dword ptr [eax + 8] */
   6409     _flag_k = FK_INC;
   6410     ebx = MEM32(ebx); /* 0x3802D67D: mov ebx, dword ptr [ebx] */
   6411     /* cmp ebx, MEM32(ebp + 0x10) */ /* 0x3802D67F: cmp ebx, dword ptr [ebp + 0x10] */
   6412     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(MEM32(ebp + 0x10));
   6413     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6414     _flag_k = FK_CMP;
   6415     RECOMP_BACKEDGE();
   6416     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D637; /* 0x3802D682: jne 0x3802d637 */
   6417 L_3802D684:
   6418     edi = POP32_VAL(esp); /* 0x3802D684: pop edi */
   6419     esi = POP32_VAL(esp); /* 0x3802D685: pop esi */
   6420 L_3802D686:
   6421     ebx = POP32_VAL(esp); /* 0x3802D686: pop ebx */
   6422     esp = ebp; /* 0x3802D687: mov esp, ebp */
   6423     ebp = POP32_VAL(esp); /* 0x3802D689: pop ebp */
   6424     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802D68A: ret 0xc */
   6425     RECOMP_REGS_OUT();
   6426 }
   6427 
   6428 void sub_3802D690(void) {
   6429     int _fpu_cmp = 0;
   6430     uint32_t _cf = 0;
   6431     int _df = 1;
   6432     uint32_t _flag_k = FK_NONE;
   6433     uint32_t _flag_a = 0, _flag_b = 0;
   6434     uint32_t _itail_tgt = 0;
   6435     RECOMP_REGS_LOCALS
   6436     RECOMP_ENTER(0x3802D690u);
   6437 
   6438 L_3802D690:
   6439     PUSH32(esp, ebp); /* 0x3802D690: push ebp */
   6440     ebp = esp; /* 0x3802D691: mov ebp, esp */
   6441     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   6442     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6443     esp = esp - 0xCu; /* 0x3802D693: sub esp, 0xc */
   6444     _flag_k = FK_CMP;
   6445     PUSH32(esp, ebx); /* 0x3802D696: push ebx */
   6446     ebx = ecx; /* 0x3802D697: mov ebx, ecx */
   6447     PUSH32(esp, esi); /* 0x3802D699: push esi */
   6448     esi = MEM32(ebp + 0x8); /* 0x3802D69A: mov esi, dword ptr [ebp + 8] */
   6449     PUSH32(esp, edi); /* 0x3802D69D: push edi */
   6450     edi = MEM32(ebx + 0x4); /* 0x3802D69E: mov edi, dword ptr [ebx + 4] */
   6451     ecx = esi; /* 0x3802D6A1: mov ecx, esi */
   6452     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
   6453     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6454     ecx = ecx - edi; /* 0x3802D6A3: sub ecx, edi */
   6455     _flag_k = FK_CMP;
   6456     eax = 0x2AAAAAABu; /* 0x3802D6A5: mov eax, 0x2aaaaaab */
   6457     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(ecx); /* 0x3802D6AA: imul ecx */
   6458       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   6459       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   6460     ecx = MEM32(ebx + 0x8); /* 0x3802D6AC: mov ecx, dword ptr [ebx + 8] */
   6461     if (2u) _cf = (((edx) >> 1) & 1u); /* 0x3802D6AF: sar edx, 2 */
   6462     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6463     edx = (uint32_t)((int32_t)edx >> 2u);
   6464     eax = edx; /* 0x3802D6B2: mov eax, edx */
   6465     if (31u) _cf = (((eax) >> 30) & 1u); /* 0x3802D6B4: shr eax, 0x1f */
   6466     if (31u) { _flag_a = recomp_flags_pack((eax >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6467     eax = eax >> 31u; /* 0x3802D6B4: shr eax, 0x1f */
   6468     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   6469     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6470     edx = edx + eax; /* 0x3802D6B7: add edx, eax */
   6471     _flag_k = FK_ADD;
   6472     MEM32(ebp + (-0xC)) = edx; /* 0x3802D6B9: mov dword ptr [ebp - 0xc], edx */
   6473     edx = MEM32(ebx + 0xC); /* 0x3802D6BC: mov edx, dword ptr [ebx + 0xc] */
   6474     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   6475     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6476     edx = edx - ecx; /* 0x3802D6BF: sub edx, ecx */
   6477     _flag_k = FK_CMP;
   6478     eax = 0x2AAAAAABu; /* 0x3802D6C1: mov eax, 0x2aaaaaab */
   6479     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(edx); /* 0x3802D6C6: imul edx */
   6480       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   6481       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   6482     if (2u) _cf = (((edx) >> 1) & 1u); /* 0x3802D6C8: sar edx, 2 */
   6483     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6484     edx = (uint32_t)((int32_t)edx >> 2u);
   6485     eax = edx; /* 0x3802D6CB: mov eax, edx */
   6486     if (31u) _cf = (((eax) >> 30) & 1u); /* 0x3802D6CD: shr eax, 0x1f */
   6487     if (31u) { _flag_a = recomp_flags_pack((eax >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6488     eax = eax >> 31u; /* 0x3802D6CD: shr eax, 0x1f */
   6489     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   6490     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6491     edx = edx + eax; /* 0x3802D6D0: add edx, eax */
   6492     _flag_k = FK_ADD;
   6493     /* cmp edx, 1 */ /* 0x3802D6D2: cmp edx, 1 */
   6494     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   6495     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6496     _flag_k = FK_CMP;
   6497     if (CMP_AE(_flag_a, _flag_b)) goto L_3802D7CB; /* 0x3802D6D5: jae 0x3802d7cb */
   6498 L_3802D6DB:
   6499     /* test edi, edi */ /* 0x3802D6DB: test edi, edi */
   6500     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
   6501     _cf = 0;
   6502     _flag_k = FK_TEST;
   6503     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D6FC; /* 0x3802D6DD: je 0x3802d6fc */
   6504 L_3802D6DF:
   6505     edx = ecx; /* 0x3802D6DF: mov edx, ecx */
   6506     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edi);
   6507     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6508     edx = edx - edi; /* 0x3802D6E1: sub edx, edi */
   6509     _flag_k = FK_CMP;
   6510     eax = 0x2AAAAAABu; /* 0x3802D6E3: mov eax, 0x2aaaaaab */
   6511     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(edx); /* 0x3802D6E8: imul edx */
   6512       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   6513       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   6514     if (2u) _cf = (((edx) >> 1) & 1u); /* 0x3802D6EA: sar edx, 2 */
   6515     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6516     edx = (uint32_t)((int32_t)edx >> 2u);
   6517     eax = edx; /* 0x3802D6ED: mov eax, edx */
   6518     if (31u) _cf = (((eax) >> 30) & 1u); /* 0x3802D6EF: shr eax, 0x1f */
   6519     if (31u) { _flag_a = recomp_flags_pack((eax >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6520     eax = eax >> 31u; /* 0x3802D6EF: shr eax, 0x1f */
   6521     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   6522     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6523     edx = edx + eax; /* 0x3802D6F2: add edx, eax */
   6524     _flag_k = FK_ADD;
   6525     /* cmp edx, 1 */ /* 0x3802D6F4: cmp edx, 1 */
   6526     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   6527     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6528     _flag_k = FK_CMP;
   6529     MEM32(ebp + 0x8) = edx; /* 0x3802D6F7: mov dword ptr [ebp + 8], edx */
   6530     if (CMP_A(_flag_a, _flag_b)) goto L_3802D703; /* 0x3802D6FA: ja 0x3802d703 */
   6531 L_3802D6FC:
   6532     MEM32(ebp + 0x8) = 1; /* 0x3802D6FC: mov dword ptr [ebp + 8], 1 */
   6533 L_3802D703:
   6534     /* test edi, edi */ /* 0x3802D703: test edi, edi */
   6535     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
   6536     _cf = 0;
   6537     _flag_k = FK_TEST;
   6538     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802D70B; /* 0x3802D705: jne 0x3802d70b */
   6539 L_3802D707:
   6540     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   6541     edx = 0; /* 0x3802D707: xor edx, edx */
   6542     _cf = 0;
   6543     _flag_k = FK_TEST;
   6544     goto L_3802D71E; /* 0x3802D709: jmp 0x3802d71e */
   6545 L_3802D70B:
   6546     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
   6547     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6548     ecx = ecx - edi; /* 0x3802D70B: sub ecx, edi */
   6549     _flag_k = FK_CMP;
   6550     eax = 0x2AAAAAABu; /* 0x3802D70D: mov eax, 0x2aaaaaab */
   6551     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(ecx); /* 0x3802D712: imul ecx */
   6552       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   6553       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   6554     if (2u) _cf = (((edx) >> 1) & 1u); /* 0x3802D714: sar edx, 2 */
   6555     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6556     edx = (uint32_t)((int32_t)edx >> 2u);
   6557     ecx = edx; /* 0x3802D717: mov ecx, edx */
   6558     if (31u) _cf = (((ecx) >> 30) & 1u); /* 0x3802D719: shr ecx, 0x1f */
   6559     if (31u) { _flag_a = recomp_flags_pack((ecx >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6560     ecx = ecx >> 31u; /* 0x3802D719: shr ecx, 0x1f */
   6561     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   6562     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6563     edx = edx + ecx; /* 0x3802D71C: add edx, ecx */
   6564     _flag_k = FK_ADD;
   6565 L_3802D71E:
   6566     eax = MEM32(ebp + 0x8); /* 0x3802D71E: mov eax, dword ptr [ebp + 8] */
   6567     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   6568     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6569     eax = eax + edx; /* 0x3802D721: add eax, edx */
   6570     _flag_k = FK_ADD;
   6571     /* test eax, eax */ /* 0x3802D723: test eax, eax */
   6572     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6573     _cf = 0;
   6574     _flag_k = FK_TEST;
   6575     MEM32(ebp + (-0x4)) = eax; /* 0x3802D725: mov dword ptr [ebp - 4], eax */
   6576     if (TEST_NS(_flag_a, _flag_b)) goto L_3802D72C; /* 0x3802D728: jge 0x3802d72c */
   6577 L_3802D72A:
   6578     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   6579     eax = 0; /* 0x3802D72A: xor eax, eax */
   6580     _cf = 0;
   6581     _flag_k = FK_TEST;
   6582 L_3802D72C:
   6583     ecx = eax + eax * 2; /* 0x3802D72C: lea ecx, [eax + eax*2] */
   6584     if (3u) _cf = (((ecx) >> 29) & 1u); /* 0x3802D72F: shl ecx, 3 */
   6585     if (3u) { _flag_a = recomp_flags_pack((ecx << 3u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6586     ecx = ecx << 3u; /* 0x3802D72F: shl ecx, 3 */
   6587     PUSH32(esp, ecx); /* 0x3802D732: push ecx */
   6588     RECOMP_ICALL(0x3804B676u); /* 0x3802D733: call 0x3804b676 */ /* not lifted */
   6589     RECOMP_FLAGS_IN();
   6590     edi = MEM32(ebx + 0x4); /* 0x3802D738: mov edi, dword ptr [ebx + 4] */
   6591     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6592     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6593     esp = esp + 4; /* 0x3802D73B: add esp, 4 */
   6594     _flag_k = FK_ADD;
   6595     /* cmp edi, esi */ /* 0x3802D73E: cmp edi, esi */
   6596     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(esi);
   6597     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6598     _flag_k = FK_CMP;
   6599     MEM32(ebp + (-0x8)) = eax; /* 0x3802D740: mov dword ptr [ebp - 8], eax */
   6600     MEM32(ebp + 0x8) = eax; /* 0x3802D743: mov dword ptr [ebp + 8], eax */
   6601     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D765; /* 0x3802D746: je 0x3802d765 */
   6602 L_3802D748:
   6603     edx = MEM32(ebp + 0x8); /* 0x3802D748: mov edx, dword ptr [ebp + 8] */
   6604     PUSH32(esp, edi); /* 0x3802D74B: push edi */
   6605     PUSH32(esp, edx); /* 0x3802D74C: push edx */
   6606     RECOMP_ICALL(0x3802F390u); /* 0x3802D74D: call 0x3802f390 */ /* not lifted */
   6607     RECOMP_FLAGS_IN();
   6608     edx = MEM32(ebp + 0x8); /* 0x3802D752: mov edx, dword ptr [ebp + 8] */
   6609     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x18u);
   6610     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6611     edx = edx + 0x18u; /* 0x3802D755: add edx, 0x18 */
   6612     _flag_k = FK_ADD;
   6613     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(0x18u);
   6614     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6615     edi = edi + 0x18u; /* 0x3802D758: add edi, 0x18 */
   6616     _flag_k = FK_ADD;
   6617     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   6618     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6619     esp = esp + 8; /* 0x3802D75B: add esp, 8 */
   6620     _flag_k = FK_ADD;
   6621     /* cmp edi, esi */ /* 0x3802D75E: cmp edi, esi */
   6622     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(esi);
   6623     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6624     _flag_k = FK_CMP;
   6625     MEM32(ebp + 0x8) = edx; /* 0x3802D760: mov dword ptr [ebp + 8], edx */
   6626     RECOMP_BACKEDGE();
   6627     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D748; /* 0x3802D763: jne 0x3802d748 */
   6628 L_3802D765:
   6629     eax = MEM32(ebp + 0xC); /* 0x3802D765: mov eax, dword ptr [ebp + 0xc] */
   6630     ecx = MEM32(ebp + 0x8); /* 0x3802D768: mov ecx, dword ptr [ebp + 8] */
   6631     PUSH32(esp, eax); /* 0x3802D76B: push eax */
   6632     PUSH32(esp, ecx); /* 0x3802D76C: push ecx */
   6633     RECOMP_ICALL(0x3802F390u); /* 0x3802D76D: call 0x3802f390 */ /* not lifted */
   6634     RECOMP_FLAGS_IN();
   6635     edx = MEM32(ebp + 0x8); /* 0x3802D772: mov edx, dword ptr [ebp + 8] */
   6636     eax = MEM32(ebx + 0x8); /* 0x3802D775: mov eax, dword ptr [ebx + 8] */
   6637     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   6638     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6639     esp = esp + 8; /* 0x3802D778: add esp, 8 */
   6640     _flag_k = FK_ADD;
   6641     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x18u);
   6642     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6643     edx = edx + 0x18u; /* 0x3802D77B: add edx, 0x18 */
   6644     _flag_k = FK_ADD;
   6645     PUSH32(esp, edx); /* 0x3802D77E: push edx */
   6646     PUSH32(esp, eax); /* 0x3802D77F: push eax */
   6647     PUSH32(esp, esi); /* 0x3802D780: push esi */
   6648     ecx = ebx; /* 0x3802D781: mov ecx, ebx */
   6649     RECOMP_ICALL(0x3802EB10u); /* 0x3802D783: call 0x3802eb10 */ /* not lifted */
   6650     RECOMP_FLAGS_IN();
   6651     ecx = MEM32(ebx + 0x8); /* 0x3802D788: mov ecx, dword ptr [ebx + 8] */
   6652     edx = MEM32(ebx + 0x4); /* 0x3802D78B: mov edx, dword ptr [ebx + 4] */
   6653     PUSH32(esp, ecx); /* 0x3802D78E: push ecx */
   6654     PUSH32(esp, edx); /* 0x3802D78F: push edx */
   6655     ecx = ebx; /* 0x3802D790: mov ecx, ebx */
   6656     RECOMP_ICALL(0x38042760u); /* 0x3802D792: call 0x38042760 */ /* not lifted */
   6657     RECOMP_FLAGS_IN();
   6658     eax = MEM32(ebx + 0x4); /* 0x3802D797: mov eax, dword ptr [ebx + 4] */
   6659     PUSH32(esp, eax); /* 0x3802D79A: push eax */
   6660     RECOMP_ICALL(0x3804B4F6u); /* 0x3802D79B: call 0x3804b4f6 */ /* not lifted */
   6661     RECOMP_FLAGS_IN();
   6662     eax = MEM32(ebp + (-0x4)); /* 0x3802D7A0: mov eax, dword ptr [ebp - 4] */
   6663     esi = MEM32(ebp + (-0x8)); /* 0x3802D7A3: mov esi, dword ptr [ebp - 8] */
   6664     ecx = eax + eax * 2; /* 0x3802D7A6: lea ecx, [eax + eax*2] */
   6665     edx = esi + ecx * 8; /* 0x3802D7A9: lea edx, [esi + ecx*8] */
   6666     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6667     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6668     esp = esp + 4; /* 0x3802D7AC: add esp, 4 */
   6669     _flag_k = FK_ADD;
   6670     ecx = ebx; /* 0x3802D7AF: mov ecx, ebx */
   6671     MEM32(ebx + 0xC) = edx; /* 0x3802D7B1: mov dword ptr [ebx + 0xc], edx */
   6672     RECOMP_ICALL(0x3802EAE0u); /* 0x3802D7B4: call 0x3802eae0 */ /* not lifted */
   6673     RECOMP_FLAGS_IN();
   6674     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   6675     eax = eax + 1; /* 0x3802D7B9: inc eax */
   6676     _flag_k = FK_INC;
   6677     eax = eax + eax * 2; /* 0x3802D7BA: lea eax, [eax + eax*2] */
   6678     ecx = esi + eax * 8; /* 0x3802D7BD: lea ecx, [esi + eax*8] */
   6679     MEM32(ebx + 0x8) = ecx; /* 0x3802D7C0: mov dword ptr [ebx + 8], ecx */
   6680     MEM32(ebx + 0x4) = esi; /* 0x3802D7C3: mov dword ptr [ebx + 4], esi */
   6681     goto L_3802D88D; /* 0x3802D7C6: jmp 0x3802d88d */
   6682 L_3802D7CB:
   6683     edx = ecx; /* 0x3802D7CB: mov edx, ecx */
   6684     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(esi);
   6685     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6686     edx = edx - esi; /* 0x3802D7CD: sub edx, esi */
   6687     _flag_k = FK_CMP;
   6688     eax = 0x2AAAAAABu; /* 0x3802D7CF: mov eax, 0x2aaaaaab */
   6689     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(edx); /* 0x3802D7D4: imul edx */
   6690       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   6691       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   6692     if (2u) _cf = (((edx) >> 1) & 1u); /* 0x3802D7D6: sar edx, 2 */
   6693     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6694     edx = (uint32_t)((int32_t)edx >> 2u);
   6695     eax = edx; /* 0x3802D7D9: mov eax, edx */
   6696     if (31u) _cf = (((eax) >> 30) & 1u); /* 0x3802D7DB: shr eax, 0x1f */
   6697     if (31u) { _flag_a = recomp_flags_pack((eax >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6698     eax = eax >> 31u; /* 0x3802D7DB: shr eax, 0x1f */
   6699     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   6700     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6701     edx = edx + eax; /* 0x3802D7DE: add edx, eax */
   6702     _flag_k = FK_ADD;
   6703     /* cmp edx, 1 */ /* 0x3802D7E0: cmp edx, 1 */
   6704     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   6705     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6706     _flag_k = FK_CMP;
   6707     if (CMP_AE(_flag_a, _flag_b)) goto L_3802D83C; /* 0x3802D7E3: jae 0x3802d83c */
   6708 L_3802D7E5:
   6709     edx = esi + 0x18; /* 0x3802D7E5: lea edx, [esi + 0x18] */
   6710     PUSH32(esp, edx); /* 0x3802D7E8: push edx */
   6711     PUSH32(esp, ecx); /* 0x3802D7E9: push ecx */
   6712     PUSH32(esp, esi); /* 0x3802D7EA: push esi */
   6713     ecx = ebx; /* 0x3802D7EB: mov ecx, ebx */
   6714     RECOMP_ICALL(0x3802EB10u); /* 0x3802D7ED: call 0x3802eb10 */ /* not lifted */
   6715     RECOMP_FLAGS_IN();
   6716     edi = MEM32(ebx + 0x8); /* 0x3802D7F2: mov edi, dword ptr [ebx + 8] */
   6717     eax = MEM32(ebp + 0xC); /* 0x3802D7F5: mov eax, dword ptr [ebp + 0xc] */
   6718     PUSH32(esp, eax); /* 0x3802D7F8: push eax */
   6719     ecx = edi; /* 0x3802D7F9: mov ecx, edi */
   6720     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(esi);
   6721     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6722     ecx = ecx - esi; /* 0x3802D7FB: sub ecx, esi */
   6723     _flag_k = FK_CMP;
   6724     eax = 0x2AAAAAABu; /* 0x3802D7FD: mov eax, 0x2aaaaaab */
   6725     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(ecx); /* 0x3802D802: imul ecx */
   6726       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   6727       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   6728     if (2u) _cf = (((edx) >> 1) & 1u); /* 0x3802D804: sar edx, 2 */
   6729     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6730     edx = (uint32_t)((int32_t)edx >> 2u);
   6731     ecx = edx; /* 0x3802D807: mov ecx, edx */
   6732     if (31u) _cf = (((ecx) >> 30) & 1u); /* 0x3802D809: shr ecx, 0x1f */
   6733     if (31u) { _flag_a = recomp_flags_pack((ecx >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6734     ecx = ecx >> 31u; /* 0x3802D809: shr ecx, 0x1f */
   6735     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   6736     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6737     edx = edx + ecx; /* 0x3802D80C: add edx, ecx */
   6738     _flag_k = FK_ADD;
   6739     eax = 1; /* 0x3802D80E: mov eax, 1 */
   6740     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   6741     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6742     eax = eax - edx; /* 0x3802D813: sub eax, edx */
   6743     _flag_k = FK_CMP;
   6744     PUSH32(esp, eax); /* 0x3802D815: push eax */
   6745     PUSH32(esp, edi); /* 0x3802D816: push edi */
   6746     ecx = ebx; /* 0x3802D817: mov ecx, ebx */
   6747     RECOMP_ICALL(0x3802EB50u); /* 0x3802D819: call 0x3802eb50 */ /* not lifted */
   6748     RECOMP_FLAGS_IN();
   6749     edx = MEM32(ebx + 0x8); /* 0x3802D81E: mov edx, dword ptr [ebx + 8] */
   6750     /* cmp esi, edx */ /* 0x3802D821: cmp esi, edx */
   6751     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
   6752     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6753     _flag_k = FK_CMP;
   6754     eax = esi; /* 0x3802D823: mov eax, esi */
   6755     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D889; /* 0x3802D825: je 0x3802d889 */
   6756 L_3802D827:
   6757     esi = MEM32(ebp + 0xC); /* 0x3802D827: mov esi, dword ptr [ebp + 0xc] */
   6758     edi = eax; /* 0x3802D82A: mov edi, eax */
   6759     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x18u);
   6760     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6761     eax = eax + 0x18u; /* 0x3802D82C: add eax, 0x18 */
   6762     _flag_k = FK_ADD;
   6763     /* cmp eax, edx */ /* 0x3802D82F: cmp eax, edx */
   6764     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   6765     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6766     _flag_k = FK_CMP;
   6767     ecx = 6; /* 0x3802D831: mov ecx, 6 */
   6768     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3802D836: 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; }
   6769     RECOMP_BACKEDGE();
   6770     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D827; /* 0x3802D838: jne 0x3802d827 */
   6771 L_3802D83A:
   6772     goto L_3802D889; /* 0x3802D83A: jmp 0x3802d889 */
   6773 L_3802D83C:
   6774     PUSH32(esp, ecx); /* 0x3802D83C: push ecx */
   6775     PUSH32(esp, ecx); /* 0x3802D83D: push ecx */
   6776     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0xFFFFFFE8u);
   6777     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6778     ecx = ecx + 0xFFFFFFE8u; /* 0x3802D83E: add ecx, -0x18 */
   6779     _flag_k = FK_ADD;
   6780     PUSH32(esp, ecx); /* 0x3802D841: push ecx */
   6781     ecx = ebx; /* 0x3802D842: mov ecx, ebx */
   6782     RECOMP_ICALL(0x3802EB10u); /* 0x3802D844: call 0x3802eb10 */ /* not lifted */
   6783     RECOMP_FLAGS_IN();
   6784     edx = MEM32(ebx + 0x8); /* 0x3802D849: mov edx, dword ptr [ebx + 8] */
   6785     eax = edx + (-0x18); /* 0x3802D84C: lea eax, [edx - 0x18] */
   6786     /* cmp esi, eax */ /* 0x3802D84F: cmp esi, eax */
   6787     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   6788     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6789     _flag_k = FK_CMP;
   6790     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D86D; /* 0x3802D851: je 0x3802d86d */
   6791 L_3802D853:
   6792     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x18u);
   6793     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6794     eax = eax - 0x18u; /* 0x3802D853: sub eax, 0x18 */
   6795     _flag_k = FK_CMP;
   6796     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x18u);
   6797     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6798     edx = edx - 0x18u; /* 0x3802D856: sub edx, 0x18 */
   6799     _flag_k = FK_CMP;
   6800     ecx = 6; /* 0x3802D859: mov ecx, 6 */
   6801     esi = eax; /* 0x3802D85E: mov esi, eax */
   6802     edi = edx; /* 0x3802D860: mov edi, edx */
   6803     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3802D862: 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; }
   6804     ecx = MEM32(ebp + 0x8); /* 0x3802D864: mov ecx, dword ptr [ebp + 8] */
   6805     /* cmp eax, ecx */ /* 0x3802D867: cmp eax, ecx */
   6806     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   6807     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6808     _flag_k = FK_CMP;
   6809     RECOMP_BACKEDGE();
   6810     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D853; /* 0x3802D869: jne 0x3802d853 */
   6811 L_3802D86B:
   6812     esi = ecx; /* 0x3802D86B: mov esi, ecx */
   6813 L_3802D86D:
   6814     edx = esi + 0x18; /* 0x3802D86D: lea edx, [esi + 0x18] */
   6815     /* cmp esi, edx */ /* 0x3802D870: cmp esi, edx */
   6816     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
   6817     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6818     _flag_k = FK_CMP;
   6819     eax = esi; /* 0x3802D872: mov eax, esi */
   6820     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D889; /* 0x3802D874: je 0x3802d889 */
   6821 L_3802D876:
   6822     esi = MEM32(ebp + 0xC); /* 0x3802D876: mov esi, dword ptr [ebp + 0xc] */
   6823     edi = eax; /* 0x3802D879: mov edi, eax */
   6824     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x18u);
   6825     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6826     eax = eax + 0x18u; /* 0x3802D87B: add eax, 0x18 */
   6827     _flag_k = FK_ADD;
   6828     /* cmp eax, edx */ /* 0x3802D87E: cmp eax, edx */
   6829     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   6830     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6831     _flag_k = FK_CMP;
   6832     ecx = 6; /* 0x3802D880: mov ecx, 6 */
   6833     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3802D885: 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; }
   6834     RECOMP_BACKEDGE();
   6835     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D876; /* 0x3802D887: jne 0x3802d876 */
   6836 L_3802D889:
   6837     _flag_a = (uint32_t)(MEM32(ebx + 0x8)); _flag_b = (uint32_t)(0x18u);
   6838     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6839     MEM32(ebx + 0x8) = MEM32(ebx + 0x8) + 0x18u; /* 0x3802D889: add dword ptr [ebx + 8], 0x18 */
   6840     _flag_k = FK_ADD;
   6841 L_3802D88D:
   6842     eax = MEM32(ebp + (-0xC)); /* 0x3802D88D: mov eax, dword ptr [ebp - 0xc] */
   6843     edx = MEM32(ebx + 0x4); /* 0x3802D890: mov edx, dword ptr [ebx + 4] */
   6844     edi = POP32_VAL(esp); /* 0x3802D893: pop edi */
   6845     ecx = eax + eax * 2; /* 0x3802D894: lea ecx, [eax + eax*2] */
   6846     esi = POP32_VAL(esp); /* 0x3802D897: pop esi */
   6847     eax = edx + ecx * 8; /* 0x3802D898: lea eax, [edx + ecx*8] */
   6848     ebx = POP32_VAL(esp); /* 0x3802D89B: pop ebx */
   6849     esp = ebp; /* 0x3802D89C: mov esp, ebp */
   6850     ebp = POP32_VAL(esp); /* 0x3802D89E: pop ebp */
   6851     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802D89F: ret 8 */
   6852     RECOMP_REGS_OUT();
   6853 }
   6854 
   6855 void sub_3802D88D(void) {
   6856     int _fpu_cmp = 0;
   6857     uint32_t _cf = 0;
   6858     int _df = 1;
   6859     uint32_t _flag_k = FK_NONE;
   6860     uint32_t _flag_a = 0, _flag_b = 0;
   6861     uint32_t _itail_tgt = 0;
   6862     RECOMP_REGS_LOCALS
   6863     RECOMP_ENTER(0x3802D88Du);
   6864 
   6865 L_3802D88D:
   6866     eax = MEM32(ebp + (-0xC)); /* 0x3802D88D: mov eax, dword ptr [ebp - 0xc] */
   6867     edx = MEM32(ebx + 0x4); /* 0x3802D890: mov edx, dword ptr [ebx + 4] */
   6868     edi = POP32_VAL(esp); /* 0x3802D893: pop edi */
   6869     ecx = eax + eax * 2; /* 0x3802D894: lea ecx, [eax + eax*2] */
   6870     esi = POP32_VAL(esp); /* 0x3802D897: pop esi */
   6871     eax = edx + ecx * 8; /* 0x3802D898: lea eax, [edx + ecx*8] */
   6872     ebx = POP32_VAL(esp); /* 0x3802D89B: pop ebx */
   6873     esp = ebp; /* 0x3802D89C: mov esp, ebp */
   6874     ebp = POP32_VAL(esp); /* 0x3802D89E: pop ebp */
   6875     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802D89F: ret 8 */
   6876     RECOMP_REGS_OUT();
   6877 }
   6878 
   6879 void sub_3802D8B0(void) {
   6880     int _fpu_cmp = 0;
   6881     uint32_t _cf = 0;
   6882     int _df = 1;
   6883     uint32_t _flag_k = FK_NONE;
   6884     uint32_t _flag_a = 0, _flag_b = 0;
   6885     uint32_t _itail_tgt = 0;
   6886     RECOMP_REGS_LOCALS
   6887     RECOMP_ENTER(0x3802D8B0u);
   6888 
   6889 L_3802D8B0:
   6890     PUSH32(esp, ebp); /* 0x3802D8B0: push ebp */
   6891     ebp = esp; /* 0x3802D8B1: mov ebp, esp */
   6892     PUSH32(esp, ecx); /* 0x3802D8B3: push ecx */
   6893     eax = MEM32(ecx + 0x8); /* 0x3802D8B4: mov eax, dword ptr [ecx + 8] */
   6894     edx = MEM32(ebp + 0xC); /* 0x3802D8B7: mov edx, dword ptr [ebp + 0xc] */
   6895     /* cmp edx, eax */ /* 0x3802D8BA: cmp edx, eax */
   6896     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   6897     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6898     _flag_k = FK_CMP;
   6899     PUSH32(esp, ebx); /* 0x3802D8BC: push ebx */
   6900     ebx = MEM32(ebp + 0x8); /* 0x3802D8BD: mov ebx, dword ptr [ebp + 8] */
   6901     MEM32(ebp + (-0x4)) = ecx; /* 0x3802D8C0: mov dword ptr [ebp - 4], ecx */
   6902     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D8E1; /* 0x3802D8C3: je 0x3802d8e1 */
   6903 L_3802D8C5:
   6904     PUSH32(esp, esi); /* 0x3802D8C5: push esi */
   6905     PUSH32(esp, edi); /* 0x3802D8C6: push edi */
   6906 L_3802D8C7:
   6907     esi = edx; /* 0x3802D8C7: mov esi, edx */
   6908     edi = ebx; /* 0x3802D8C9: mov edi, ebx */
   6909     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x18u);
   6910     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6911     edx = edx + 0x18u; /* 0x3802D8CB: add edx, 0x18 */
   6912     _flag_k = FK_ADD;
   6913     ecx = 6; /* 0x3802D8CE: mov ecx, 6 */
   6914     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0x18u);
   6915     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6916     ebx = ebx + 0x18u; /* 0x3802D8D3: add ebx, 0x18 */
   6917     _flag_k = FK_ADD;
   6918     /* cmp edx, eax */ /* 0x3802D8D6: cmp edx, eax */
   6919     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   6920     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6921     _flag_k = FK_CMP;
   6922     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3802D8D8: 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; }
   6923     RECOMP_BACKEDGE();
   6924     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D8C7; /* 0x3802D8DA: jne 0x3802d8c7 */
   6925 L_3802D8DC:
   6926     ecx = MEM32(ebp + (-0x4)); /* 0x3802D8DC: mov ecx, dword ptr [ebp - 4] */
   6927     edi = POP32_VAL(esp); /* 0x3802D8DF: pop edi */
   6928     esi = POP32_VAL(esp); /* 0x3802D8E0: pop esi */
   6929 L_3802D8E1:
   6930     eax = MEM32(ecx + 0x8); /* 0x3802D8E1: mov eax, dword ptr [ecx + 8] */
   6931     MEM32(ebp + 0xC) = eax; /* 0x3802D8E4: mov dword ptr [ebp + 0xc], eax */
   6932     eax = MEM32(ebp + 0x8); /* 0x3802D8E7: mov eax, dword ptr [ebp + 8] */
   6933     MEM32(ecx + 0x8) = ebx; /* 0x3802D8EA: mov dword ptr [ecx + 8], ebx */
   6934     ebx = POP32_VAL(esp); /* 0x3802D8ED: pop ebx */
   6935     esp = ebp; /* 0x3802D8EE: mov esp, ebp */
   6936     ebp = POP32_VAL(esp); /* 0x3802D8F0: pop ebp */
   6937     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802D8F1: ret 8 */
   6938     RECOMP_REGS_OUT();
   6939 }
   6940 
   6941 void sub_3802D900(void) {
   6942     int _fpu_cmp = 0;
   6943     uint32_t _cf = 0;
   6944     int _df = 1;
   6945     uint32_t _flag_k = FK_NONE;
   6946     uint32_t _flag_a = 0, _flag_b = 0;
   6947     uint32_t _itail_tgt = 0;
   6948     RECOMP_REGS_LOCALS
   6949     RECOMP_ENTER(0x3802D900u);
   6950 
   6951 L_3802D900:
   6952     PUSH32(esp, ebp); /* 0x3802D900: push ebp */
   6953     ebp = esp; /* 0x3802D901: mov ebp, esp */
   6954     PUSH32(esp, ebx); /* 0x3802D903: push ebx */
   6955     ebx = MEM32(ebp + 0x10); /* 0x3802D904: mov ebx, dword ptr [ebp + 0x10] */
   6956     PUSH32(esp, esi); /* 0x3802D907: push esi */
   6957     esi = ecx; /* 0x3802D908: mov esi, ecx */
   6958     eax = MEM32(esi + 0x10); /* 0x3802D90A: mov eax, dword ptr [esi + 0x10] */
   6959     /* test eax, eax */ /* 0x3802D90D: test eax, eax */
   6960     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6961     _cf = 0;
   6962     _flag_k = FK_TEST;
   6963     ecx = MEM32(ebp + 0xC); /* 0x3802D90F: mov ecx, dword ptr [ebp + 0xc] */
   6964     PUSH32(esp, edi); /* 0x3802D912: push edi */
   6965     if (TEST_Z(_flag_a, _flag_b)) goto L_3802D975; /* 0x3802D913: je 0x3802d975 */
   6966 L_3802D915:
   6967     eax = MEM32(esi + 0x4); /* 0x3802D915: mov eax, dword ptr [esi + 4] */
   6968     /* cmp ecx, MEM32(eax) */ /* 0x3802D918: cmp ecx, dword ptr [eax] */
   6969     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax));
   6970     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6971     _flag_k = FK_CMP;
   6972     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D975; /* 0x3802D91A: jne 0x3802d975 */
   6973 L_3802D91C:
   6974     /* cmp ebx, eax */ /* 0x3802D91C: cmp ebx, eax */
   6975     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(eax);
   6976     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6977     _flag_k = FK_CMP;
   6978     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D975; /* 0x3802D91E: jne 0x3802d975 */
   6979 L_3802D920:
   6980     ebx = MEM32(eax + 0x4); /* 0x3802D920: mov ebx, dword ptr [eax + 4] */
   6981     /* cmp ebx, MEM32(esi + 0x8) */ /* 0x3802D923: cmp ebx, dword ptr [esi + 8] */
   6982     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   6983     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6984     _flag_k = FK_CMP;
   6985     edi = ebx; /* 0x3802D926: mov edi, ebx */
   6986     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D949; /* 0x3802D928: je 0x3802d949 */
   6987 L_3802D92A:
   6988     eax = MEM32(edi + 0x8); /* 0x3802D92A: mov eax, dword ptr [edi + 8] */
   6989     PUSH32(esp, eax); /* 0x3802D92D: push eax */
   6990     ecx = esi; /* 0x3802D92E: mov ecx, esi */
   6991     RECOMP_ICALL(0x3802E330u); /* 0x3802D930: call 0x3802e330 */ /* not lifted */
   6992     RECOMP_FLAGS_IN();
   6993     edi = MEM32(edi); /* 0x3802D935: mov edi, dword ptr [edi] */
   6994     PUSH32(esp, ebx); /* 0x3802D937: push ebx */
   6995     RECOMP_ICALL(0x3804B4F6u); /* 0x3802D938: call 0x3804b4f6 */ /* not lifted */
   6996     RECOMP_FLAGS_IN();
   6997     eax = MEM32(esi + 0x8); /* 0x3802D93D: mov eax, dword ptr [esi + 8] */
   6998     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6999     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7000     esp = esp + 4; /* 0x3802D940: add esp, 4 */
   7001     _flag_k = FK_ADD;
   7002     /* cmp edi, eax */ /* 0x3802D943: cmp edi, eax */
   7003     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   7004     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7005     _flag_k = FK_CMP;
   7006     ebx = edi; /* 0x3802D945: mov ebx, edi */
   7007     RECOMP_BACKEDGE();
   7008     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D92A; /* 0x3802D947: jne 0x3802d92a */
   7009 L_3802D949:
   7010     ecx = MEM32(esi + 0x4); /* 0x3802D949: mov ecx, dword ptr [esi + 4] */
   7011     edx = MEM32(esi + 0x8); /* 0x3802D94C: mov edx, dword ptr [esi + 8] */
   7012     MEM32(ecx + 0x4) = edx; /* 0x3802D94F: mov dword ptr [ecx + 4], edx */
   7013     eax = MEM32(esi + 0x4); /* 0x3802D952: mov eax, dword ptr [esi + 4] */
   7014     MEM32(esi + 0x10) = 0; /* 0x3802D955: mov dword ptr [esi + 0x10], 0 */
   7015     MEM32(eax) = eax; /* 0x3802D95C: mov dword ptr [eax], eax */
   7016     eax = MEM32(esi + 0x4); /* 0x3802D95E: mov eax, dword ptr [esi + 4] */
   7017     MEM32(eax + 0x8) = eax; /* 0x3802D961: mov dword ptr [eax + 8], eax */
   7018     eax = MEM32(esi + 0x4); /* 0x3802D964: mov eax, dword ptr [esi + 4] */
   7019     ecx = MEM32(eax); /* 0x3802D967: mov ecx, dword ptr [eax] */
   7020     eax = MEM32(ebp + 0x8); /* 0x3802D969: mov eax, dword ptr [ebp + 8] */
   7021     edi = POP32_VAL(esp); /* 0x3802D96C: pop edi */
   7022     esi = POP32_VAL(esp); /* 0x3802D96D: pop esi */
   7023     MEM32(eax) = ecx; /* 0x3802D96E: mov dword ptr [eax], ecx */
   7024     ebx = POP32_VAL(esp); /* 0x3802D970: pop ebx */
   7025     ebp = POP32_VAL(esp); /* 0x3802D971: pop ebp */
   7026     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802D972: ret 0xc */
   7027 L_3802D975:
   7028     /* cmp ecx, ebx */ /* 0x3802D975: cmp ecx, ebx */
   7029     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
   7030     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7031     _flag_k = FK_CMP;
   7032     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802D996; /* 0x3802D977: je 0x3802d996 */
   7033 L_3802D979:
   7034     edi = ecx; /* 0x3802D979: mov edi, ecx */
   7035     ecx = ebp + 0xC; /* 0x3802D97B: lea ecx, [ebp + 0xc] */
   7036     RECOMP_ICALL(0x38035590u); /* 0x3802D97E: call 0x38035590 */ /* not lifted */
   7037     RECOMP_FLAGS_IN();
   7038     PUSH32(esp, edi); /* 0x3802D983: push edi */
   7039     ecx = ebp + 0x10; /* 0x3802D984: lea ecx, [ebp + 0x10] */
   7040     PUSH32(esp, ecx); /* 0x3802D987: push ecx */
   7041     ecx = esi; /* 0x3802D988: mov ecx, esi */
   7042     RECOMP_ICALL(0x3800F9D0u); /* 0x3802D98A: call 0x3800f9d0 */ /* not lifted */
   7043     RECOMP_FLAGS_IN();
   7044     ecx = MEM32(ebp + 0xC); /* 0x3802D98F: mov ecx, dword ptr [ebp + 0xc] */
   7045     /* cmp ecx, ebx */ /* 0x3802D992: cmp ecx, ebx */
   7046     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
   7047     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7048     _flag_k = FK_CMP;
   7049     RECOMP_BACKEDGE();
   7050     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D979; /* 0x3802D994: jne 0x3802d979 */
   7051 L_3802D996:
   7052     eax = MEM32(ebp + 0x8); /* 0x3802D996: mov eax, dword ptr [ebp + 8] */
   7053     edi = POP32_VAL(esp); /* 0x3802D999: pop edi */
   7054     esi = POP32_VAL(esp); /* 0x3802D99A: pop esi */
   7055     MEM32(eax) = ecx; /* 0x3802D99B: mov dword ptr [eax], ecx */
   7056     ebx = POP32_VAL(esp); /* 0x3802D99D: pop ebx */
   7057     ebp = POP32_VAL(esp); /* 0x3802D99E: pop ebp */
   7058     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802D99F: ret 0xc */
   7059     RECOMP_REGS_OUT();
   7060 }
   7061 
   7062 void sub_3802D9B0(void) {
   7063     int _fpu_cmp = 0;
   7064     uint32_t _cf = 0;
   7065     int _df = 1;
   7066     uint32_t _flag_k = FK_NONE;
   7067     uint32_t _flag_a = 0, _flag_b = 0;
   7068     uint32_t _itail_tgt = 0;
   7069     RECOMP_REGS_LOCALS
   7070     RECOMP_ENTER(0x3802D9B0u);
   7071 
   7072 L_3802D9B0:
   7073     PUSH32(esp, ebp); /* 0x3802D9B0: push ebp */
   7074     ebp = esp; /* 0x3802D9B1: mov ebp, esp */
   7075     PUSH32(esp, ebx); /* 0x3802D9B3: push ebx */
   7076     ebx = MEM32(ebp + 0x10); /* 0x3802D9B4: mov ebx, dword ptr [ebp + 0x10] */
   7077     PUSH32(esp, esi); /* 0x3802D9B7: push esi */
   7078     esi = ecx; /* 0x3802D9B8: mov esi, ecx */
   7079     eax = MEM32(esi + 0x10); /* 0x3802D9BA: mov eax, dword ptr [esi + 0x10] */
   7080     /* test eax, eax */ /* 0x3802D9BD: test eax, eax */
   7081     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   7082     _cf = 0;
   7083     _flag_k = FK_TEST;
   7084     ecx = MEM32(ebp + 0xC); /* 0x3802D9BF: mov ecx, dword ptr [ebp + 0xc] */
   7085     PUSH32(esp, edi); /* 0x3802D9C2: push edi */
   7086     if (TEST_Z(_flag_a, _flag_b)) goto L_3802DA2D; /* 0x3802D9C3: je 0x3802da2d */
   7087 L_3802D9C5:
   7088     eax = MEM32(esi + 0x4); /* 0x3802D9C5: mov eax, dword ptr [esi + 4] */
   7089     /* cmp ecx, MEM32(eax) */ /* 0x3802D9C8: cmp ecx, dword ptr [eax] */
   7090     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax));
   7091     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7092     _flag_k = FK_CMP;
   7093     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DA2D; /* 0x3802D9CA: jne 0x3802da2d */
   7094 L_3802D9CC:
   7095     /* cmp ebx, eax */ /* 0x3802D9CC: cmp ebx, eax */
   7096     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(eax);
   7097     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7098     _flag_k = FK_CMP;
   7099     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DA2D; /* 0x3802D9CE: jne 0x3802da2d */
   7100 L_3802D9D0:
   7101     ebx = MEM32(eax + 0x4); /* 0x3802D9D0: mov ebx, dword ptr [eax + 4] */
   7102     /* cmp ebx, MEM32(esi + 0x8) */ /* 0x3802D9D3: cmp ebx, dword ptr [esi + 8] */
   7103     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   7104     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7105     _flag_k = FK_CMP;
   7106     edi = ebx; /* 0x3802D9D6: mov edi, ebx */
   7107     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DA01; /* 0x3802D9D8: je 0x3802da01 */
   7108 L_3802D9DA:
   7109     eax = MEM32(edi + 0x8); /* 0x3802D9DA: mov eax, dword ptr [edi + 8] */
   7110     PUSH32(esp, eax); /* 0x3802D9DD: push eax */
   7111     ecx = esi; /* 0x3802D9DE: mov ecx, esi */
   7112     RECOMP_ICALL(0x3802E740u); /* 0x3802D9E0: call 0x3802e740 */ /* not lifted */
   7113     RECOMP_FLAGS_IN();
   7114     edi = MEM32(edi); /* 0x3802D9E5: mov edi, dword ptr [edi] */
   7115     ecx = ebx + 0xC; /* 0x3802D9E7: lea ecx, [ebx + 0xc] */
   7116     RECOMP_ICALL(0x3802F5E0u); /* 0x3802D9EA: call 0x3802f5e0 */ /* not lifted */
   7117     RECOMP_FLAGS_IN();
   7118     PUSH32(esp, ebx); /* 0x3802D9EF: push ebx */
   7119     RECOMP_ICALL(0x3804B4F6u); /* 0x3802D9F0: call 0x3804b4f6 */ /* not lifted */
   7120     RECOMP_FLAGS_IN();
   7121     eax = MEM32(esi + 0x8); /* 0x3802D9F5: mov eax, dword ptr [esi + 8] */
   7122     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   7123     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7124     esp = esp + 4; /* 0x3802D9F8: add esp, 4 */
   7125     _flag_k = FK_ADD;
   7126     /* cmp edi, eax */ /* 0x3802D9FB: cmp edi, eax */
   7127     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   7128     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7129     _flag_k = FK_CMP;
   7130     ebx = edi; /* 0x3802D9FD: mov ebx, edi */
   7131     RECOMP_BACKEDGE();
   7132     if (CMP_NE(_flag_a, _flag_b)) goto L_3802D9DA; /* 0x3802D9FF: jne 0x3802d9da */
   7133 L_3802DA01:
   7134     ecx = MEM32(esi + 0x4); /* 0x3802DA01: mov ecx, dword ptr [esi + 4] */
   7135     edx = MEM32(esi + 0x8); /* 0x3802DA04: mov edx, dword ptr [esi + 8] */
   7136     MEM32(ecx + 0x4) = edx; /* 0x3802DA07: mov dword ptr [ecx + 4], edx */
   7137     eax = MEM32(esi + 0x4); /* 0x3802DA0A: mov eax, dword ptr [esi + 4] */
   7138     MEM32(esi + 0x10) = 0; /* 0x3802DA0D: mov dword ptr [esi + 0x10], 0 */
   7139     MEM32(eax) = eax; /* 0x3802DA14: mov dword ptr [eax], eax */
   7140     eax = MEM32(esi + 0x4); /* 0x3802DA16: mov eax, dword ptr [esi + 4] */
   7141     MEM32(eax + 0x8) = eax; /* 0x3802DA19: mov dword ptr [eax + 8], eax */
   7142     eax = MEM32(esi + 0x4); /* 0x3802DA1C: mov eax, dword ptr [esi + 4] */
   7143     ecx = MEM32(eax); /* 0x3802DA1F: mov ecx, dword ptr [eax] */
   7144     eax = MEM32(ebp + 0x8); /* 0x3802DA21: mov eax, dword ptr [ebp + 8] */
   7145     edi = POP32_VAL(esp); /* 0x3802DA24: pop edi */
   7146     esi = POP32_VAL(esp); /* 0x3802DA25: pop esi */
   7147     MEM32(eax) = ecx; /* 0x3802DA26: mov dword ptr [eax], ecx */
   7148     ebx = POP32_VAL(esp); /* 0x3802DA28: pop ebx */
   7149     ebp = POP32_VAL(esp); /* 0x3802DA29: pop ebp */
   7150     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802DA2A: ret 0xc */
   7151 L_3802DA2D:
   7152     /* cmp ecx, ebx */ /* 0x3802DA2D: cmp ecx, ebx */
   7153     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
   7154     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7155     _flag_k = FK_CMP;
   7156     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DA4E; /* 0x3802DA2F: je 0x3802da4e */
   7157 L_3802DA31:
   7158     edi = ecx; /* 0x3802DA31: mov edi, ecx */
   7159     ecx = ebp + 0xC; /* 0x3802DA33: lea ecx, [ebp + 0xc] */
   7160     RECOMP_ICALL(0x3802F270u); /* 0x3802DA36: call 0x3802f270 */ /* not lifted */
   7161     RECOMP_FLAGS_IN();
   7162     PUSH32(esp, edi); /* 0x3802DA3B: push edi */
   7163     ecx = ebp + 0x10; /* 0x3802DA3C: lea ecx, [ebp + 0x10] */
   7164     PUSH32(esp, ecx); /* 0x3802DA3F: push ecx */
   7165     ecx = esi; /* 0x3802DA40: mov ecx, esi */
   7166     RECOMP_ICALL(0x3802E370u); /* 0x3802DA42: call 0x3802e370 */ /* not lifted */
   7167     RECOMP_FLAGS_IN();
   7168     ecx = MEM32(ebp + 0xC); /* 0x3802DA47: mov ecx, dword ptr [ebp + 0xc] */
   7169     /* cmp ecx, ebx */ /* 0x3802DA4A: cmp ecx, ebx */
   7170     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
   7171     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7172     _flag_k = FK_CMP;
   7173     RECOMP_BACKEDGE();
   7174     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DA31; /* 0x3802DA4C: jne 0x3802da31 */
   7175 L_3802DA4E:
   7176     eax = MEM32(ebp + 0x8); /* 0x3802DA4E: mov eax, dword ptr [ebp + 8] */
   7177     edi = POP32_VAL(esp); /* 0x3802DA51: pop edi */
   7178     esi = POP32_VAL(esp); /* 0x3802DA52: pop esi */
   7179     MEM32(eax) = ecx; /* 0x3802DA53: mov dword ptr [eax], ecx */
   7180     ebx = POP32_VAL(esp); /* 0x3802DA55: pop ebx */
   7181     ebp = POP32_VAL(esp); /* 0x3802DA56: pop ebp */
   7182     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802DA57: ret 0xc */
   7183     RECOMP_REGS_OUT();
   7184 }
   7185 
   7186 void sub_3802DA60(void) {
   7187     int _fpu_cmp = 0;
   7188     uint32_t _cf = 0;
   7189     int _df = 1;
   7190     uint32_t _flag_k = FK_NONE;
   7191     uint32_t _flag_a = 0, _flag_b = 0;
   7192     uint32_t _itail_tgt = 0;
   7193     RECOMP_REGS_LOCALS
   7194     RECOMP_ENTER(0x3802DA60u);
   7195 
   7196 L_3802DA60:
   7197     PUSH32(esp, ebp); /* 0x3802DA60: push ebp */
   7198     ebp = esp; /* 0x3802DA61: mov ebp, esp */
   7199     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   7200     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7201     esp = esp - 0xCu; /* 0x3802DA63: sub esp, 0xc */
   7202     _flag_k = FK_CMP;
   7203     PUSH32(esp, ebx); /* 0x3802DA66: push ebx */
   7204     PUSH32(esp, esi); /* 0x3802DA67: push esi */
   7205     PUSH32(esp, edi); /* 0x3802DA68: push edi */
   7206     edi = ecx; /* 0x3802DA69: mov edi, ecx */
   7207     ecx = MEM32(edi + 0x4); /* 0x3802DA6B: mov ecx, dword ptr [edi + 4] */
   7208     ebx = MEM32(ecx + 0x4); /* 0x3802DA6E: mov ebx, dword ptr [ecx + 4] */
   7209     edx = MEM32(edi + 0x8); /* 0x3802DA71: mov edx, dword ptr [edi + 8] */
   7210     /* cmp ebx, edx */ /* 0x3802DA74: cmp ebx, edx */
   7211     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(edx);
   7212     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7213     _flag_k = FK_CMP;
   7214     esi = ecx; /* 0x3802DA76: mov esi, ecx */
   7215     SET_LO8(eax, 1); /* 0x3802DA78: mov al, 1 */
   7216     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DA9E; /* 0x3802DA7A: je 0x3802da9e */
   7217 L_3802DA7C:
   7218     eax = MEM32(ebp + 0xC); /* 0x3802DA7C: mov eax, dword ptr [ebp + 0xc] */
   7219     eax = MEM32(eax); /* 0x3802DA7F: mov eax, dword ptr [eax] */
   7220     MEM32(ebp + (-0x8)) = eax; /* 0x3802DA81: mov dword ptr [ebp - 8], eax */
   7221 L_3802DA84:
   7222     eax = MEM32(ebp + (-0x8)); /* 0x3802DA84: mov eax, dword ptr [ebp - 8] */
   7223     /* cmp eax, MEM32(ebx + 0xC) */ /* 0x3802DA87: cmp eax, dword ptr [ebx + 0xc] */
   7224     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ebx + 0xC));
   7225     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7226     _flag_k = FK_CMP;
   7227     esi = ebx; /* 0x3802DA8A: mov esi, ebx */
   7228     SET_LO8(eax, (CMP_L(_flag_a, _flag_b)) ? 1 : 0); /* 0x3802DA8C: setl al */
   7229     /* test LO8(eax), LO8(eax) */ /* 0x3802DA8F: test al, al */
   7230     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   7231     _cf = 0;
   7232     _flag_k = FK_NARROW(FK_TEST, 24);
   7233     if (TEST_Z(_flag_a, _flag_b)) goto L_3802DA97; /* 0x3802DA91: je 0x3802da97 */
   7234 L_3802DA93:
   7235     ebx = MEM32(ebx); /* 0x3802DA93: mov ebx, dword ptr [ebx] */
   7236     goto L_3802DA9A; /* 0x3802DA95: jmp 0x3802da9a */
   7237 L_3802DA97:
   7238     ebx = MEM32(ebx + 0x8); /* 0x3802DA97: mov ebx, dword ptr [ebx + 8] */
   7239 L_3802DA9A:
   7240     /* cmp ebx, edx */ /* 0x3802DA9A: cmp ebx, edx */
   7241     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(edx);
   7242     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7243     _flag_k = FK_CMP;
   7244     RECOMP_BACKEDGE();
   7245     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DA84; /* 0x3802DA9C: jne 0x3802da84 */
   7246 L_3802DA9E:
   7247     SET_LO8(edx, MEM8(edi + 0xC)); /* 0x3802DA9E: mov dl, byte ptr [edi + 0xc] */
   7248     /* test LO8(edx), LO8(edx) */ /* 0x3802DAA1: test dl, dl */
   7249     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   7250     _cf = 0;
   7251     _flag_k = FK_NARROW(FK_TEST, 24);
   7252     if (TEST_Z(_flag_a, _flag_b)) goto L_3802DC19; /* 0x3802DAA3: je 0x3802dc19 */
   7253 L_3802DAA9:
   7254     PUSH32(esp, 0); /* 0x3802DAA9: push 0 */
   7255     PUSH32(esp, esi); /* 0x3802DAAB: push esi */
   7256     ecx = edi; /* 0x3802DAAC: mov ecx, edi */
   7257     RECOMP_ICALL(0x3802F160u); /* 0x3802DAAE: call 0x3802f160 */ /* not lifted */
   7258     RECOMP_FLAGS_IN();
   7259     ecx = MEM32(edi + 0x8); /* 0x3802DAB3: mov ecx, dword ptr [edi + 8] */
   7260     MEM32(eax) = ecx; /* 0x3802DAB6: mov dword ptr [eax], ecx */
   7261     edx = MEM32(edi + 0x8); /* 0x3802DAB8: mov edx, dword ptr [edi + 8] */
   7262     ecx = MEM32(ebp + 0xC); /* 0x3802DABB: mov ecx, dword ptr [ebp + 0xc] */
   7263     MEM32(ebp + (-0x4)) = eax; /* 0x3802DABE: mov dword ptr [ebp - 4], eax */
   7264     MEM32(eax + 0x8) = edx; /* 0x3802DAC1: mov dword ptr [eax + 8], edx */
   7265     PUSH32(esp, ecx); /* 0x3802DAC4: push ecx */
   7266     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xCu);
   7267     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7268     eax = eax + 0xCu; /* 0x3802DAC5: add eax, 0xc */
   7269     _flag_k = FK_ADD;
   7270     PUSH32(esp, eax); /* 0x3802DAC8: push eax */
   7271     RECOMP_ICALL(0x3802F370u); /* 0x3802DAC9: call 0x3802f370 */ /* not lifted */
   7272     RECOMP_FLAGS_IN();
   7273     ecx = MEM32(edi + 0x10); /* 0x3802DACE: mov ecx, dword ptr [edi + 0x10] */
   7274     eax = MEM32(edi + 0x4); /* 0x3802DAD1: mov eax, dword ptr [edi + 4] */
   7275     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   7276     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7277     esp = esp + 8; /* 0x3802DAD4: add esp, 8 */
   7278     _flag_k = FK_ADD;
   7279     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   7280     ecx = ecx + 1; /* 0x3802DAD7: inc ecx */
   7281     _flag_k = FK_INC;
   7282     /* cmp esi, eax */ /* 0x3802DAD8: cmp esi, eax */
   7283     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   7284     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7285     _flag_k = FK_CMP;
   7286     MEM32(edi + 0x10) = ecx; /* 0x3802DADA: mov dword ptr [edi + 0x10], ecx */
   7287     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DB01; /* 0x3802DADD: je 0x3802db01 */
   7288 L_3802DADF:
   7289     /* cmp ebx, MEM32(edi + 0x8) */ /* 0x3802DADF: cmp ebx, dword ptr [edi + 8] */
   7290     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   7291     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7292     _flag_k = FK_CMP;
   7293     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DB01; /* 0x3802DAE2: jne 0x3802db01 */
   7294 L_3802DAE4:
   7295     edx = MEM32(ebp + 0xC); /* 0x3802DAE4: mov edx, dword ptr [ebp + 0xc] */
   7296     eax = MEM32(edx); /* 0x3802DAE7: mov eax, dword ptr [edx] */
   7297     /* cmp eax, MEM32(esi + 0xC) */ /* 0x3802DAE9: cmp eax, dword ptr [esi + 0xc] */
   7298     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(esi + 0xC));
   7299     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7300     _flag_k = FK_CMP;
   7301     if (CMP_L(_flag_a, _flag_b)) goto L_3802DB01; /* 0x3802DAEC: jl 0x3802db01 */
   7302 L_3802DAEE:
   7303     ebx = MEM32(ebp + (-0x4)); /* 0x3802DAEE: mov ebx, dword ptr [ebp - 4] */
   7304     MEM32(esi + 0x8) = ebx; /* 0x3802DAF1: mov dword ptr [esi + 8], ebx */
   7305     eax = MEM32(edi + 0x4); /* 0x3802DAF4: mov eax, dword ptr [edi + 4] */
   7306     /* cmp esi, MEM32(eax + 0x8) */ /* 0x3802DAF7: cmp esi, dword ptr [eax + 8] */
   7307     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(eax + 0x8));
   7308     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7309     _flag_k = FK_CMP;
   7310     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DB24; /* 0x3802DAFA: jne 0x3802db24 */
   7311 L_3802DAFC:
   7312     MEM32(eax + 0x8) = ebx; /* 0x3802DAFC: mov dword ptr [eax + 8], ebx */
   7313     goto L_3802DB24; /* 0x3802DAFF: jmp 0x3802db24 */
   7314 L_3802DB01:
   7315     ecx = MEM32(ebp + (-0x4)); /* 0x3802DB01: mov ecx, dword ptr [ebp - 4] */
   7316     MEM32(esi) = ecx; /* 0x3802DB04: mov dword ptr [esi], ecx */
   7317     eax = MEM32(edi + 0x4); /* 0x3802DB06: mov eax, dword ptr [edi + 4] */
   7318     /* cmp esi, eax */ /* 0x3802DB09: cmp esi, eax */
   7319     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   7320     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7321     _flag_k = FK_CMP;
   7322     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DB18; /* 0x3802DB0B: jne 0x3802db18 */
   7323 L_3802DB0D:
   7324     MEM32(eax + 0x4) = ecx; /* 0x3802DB0D: mov dword ptr [eax + 4], ecx */
   7325     edx = MEM32(edi + 0x4); /* 0x3802DB10: mov edx, dword ptr [edi + 4] */
   7326     MEM32(edx + 0x8) = ecx; /* 0x3802DB13: mov dword ptr [edx + 8], ecx */
   7327     goto L_3802DB21; /* 0x3802DB16: jmp 0x3802db21 */
   7328 L_3802DB18:
   7329     /* cmp esi, MEM32(eax) */ /* 0x3802DB18: cmp esi, dword ptr [eax] */
   7330     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(eax));
   7331     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7332     _flag_k = FK_CMP;
   7333     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DB21; /* 0x3802DB1A: jne 0x3802db21 */
   7334 L_3802DB1C:
   7335     ecx = MEM32(ebp + (-0x4)); /* 0x3802DB1C: mov ecx, dword ptr [ebp - 4] */
   7336     MEM32(eax) = ecx; /* 0x3802DB1F: mov dword ptr [eax], ecx */
   7337 L_3802DB21:
   7338     ebx = MEM32(ebp + (-0x4)); /* 0x3802DB21: mov ebx, dword ptr [ebp - 4] */
   7339 L_3802DB24:
   7340     edx = MEM32(edi + 0x4); /* 0x3802DB24: mov edx, dword ptr [edi + 4] */
   7341     /* cmp ebx, MEM32(edx + 0x4) */ /* 0x3802DB27: cmp ebx, dword ptr [edx + 4] */
   7342     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   7343     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7344     _flag_k = FK_CMP;
   7345     esi = ebx; /* 0x3802DB2A: mov esi, ebx */
   7346     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DBF7; /* 0x3802DB2C: je 0x3802dbf7 */
   7347 L_3802DB32:
   7348     eax = MEM32(esi + 0x4); /* 0x3802DB32: mov eax, dword ptr [esi + 4] */
   7349     SET_LO8(ecx, MEM8(eax + 0x14)); /* 0x3802DB35: mov cl, byte ptr [eax + 0x14] */
   7350     /* test LO8(ecx), LO8(ecx) */ /* 0x3802DB38: test cl, cl */
   7351     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24;
   7352     _cf = 0;
   7353     _flag_k = FK_NARROW(FK_TEST, 24);
   7354     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802DBF7; /* 0x3802DB3A: jne 0x3802dbf7 */
   7355 L_3802DB40:
   7356     edx = MEM32(eax + 0x4); /* 0x3802DB40: mov edx, dword ptr [eax + 4] */
   7357     ecx = MEM32(edx); /* 0x3802DB43: mov ecx, dword ptr [edx] */
   7358     /* cmp eax, ecx */ /* 0x3802DB45: cmp eax, ecx */
   7359     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   7360     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7361     _flag_k = FK_CMP;
   7362     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DB9D; /* 0x3802DB47: jne 0x3802db9d */
   7363 L_3802DB49:
   7364     ecx = MEM32(edx + 0x8); /* 0x3802DB49: mov ecx, dword ptr [edx + 8] */
   7365     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3802DB4C: mov dl, byte ptr [ecx + 0x14] */
   7366     /* test LO8(edx), LO8(edx) */ /* 0x3802DB4F: test dl, dl */
   7367     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   7368     _cf = 0;
   7369     _flag_k = FK_NARROW(FK_TEST, 24);
   7370     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802DB6D; /* 0x3802DB51: jne 0x3802db6d */
   7371 L_3802DB53:
   7372     MEM8(eax + 0x14) = (uint8_t)(1); /* 0x3802DB53: mov byte ptr [eax + 0x14], 1 */
   7373     MEM8(ecx + 0x14) = (uint8_t)(1); /* 0x3802DB57: mov byte ptr [ecx + 0x14], 1 */
   7374     eax = MEM32(esi + 0x4); /* 0x3802DB5B: mov eax, dword ptr [esi + 4] */
   7375     ecx = MEM32(eax + 0x4); /* 0x3802DB5E: mov ecx, dword ptr [eax + 4] */
   7376     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3802DB61: mov byte ptr [ecx + 0x14], 0 */
   7377     edx = MEM32(esi + 0x4); /* 0x3802DB65: mov edx, dword ptr [esi + 4] */
   7378     esi = MEM32(edx + 0x4); /* 0x3802DB68: mov esi, dword ptr [edx + 4] */
   7379     goto L_3802DBEB; /* 0x3802DB6B: jmp 0x3802dbeb */
   7380 L_3802DB6D:
   7381     /* cmp esi, MEM32(eax + 0x8) */ /* 0x3802DB6D: cmp esi, dword ptr [eax + 8] */
   7382     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(eax + 0x8));
   7383     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7384     _flag_k = FK_CMP;
   7385     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DB7C; /* 0x3802DB70: jne 0x3802db7c */
   7386 L_3802DB72:
   7387     esi = eax; /* 0x3802DB72: mov esi, eax */
   7388     PUSH32(esp, esi); /* 0x3802DB74: push esi */
   7389     ecx = edi; /* 0x3802DB75: mov ecx, edi */
   7390     RECOMP_ICALL(0x3803B270u); /* 0x3802DB77: call 0x3803b270 */ /* not lifted */
   7391     RECOMP_FLAGS_IN();
   7392 L_3802DB7C:
   7393     eax = MEM32(esi + 0x4); /* 0x3802DB7C: mov eax, dword ptr [esi + 4] */
   7394     MEM8(eax + 0x14) = (uint8_t)(1); /* 0x3802DB7F: mov byte ptr [eax + 0x14], 1 */
   7395     ecx = MEM32(esi + 0x4); /* 0x3802DB83: mov ecx, dword ptr [esi + 4] */
   7396     edx = MEM32(ecx + 0x4); /* 0x3802DB86: mov edx, dword ptr [ecx + 4] */
   7397     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3802DB89: mov byte ptr [edx + 0x14], 0 */
   7398     eax = MEM32(esi + 0x4); /* 0x3802DB8D: mov eax, dword ptr [esi + 4] */
   7399     ecx = MEM32(eax + 0x4); /* 0x3802DB90: mov ecx, dword ptr [eax + 4] */
   7400     PUSH32(esp, ecx); /* 0x3802DB93: push ecx */
   7401     ecx = edi; /* 0x3802DB94: mov ecx, edi */
   7402     RECOMP_ICALL(0x3802F100u); /* 0x3802DB96: call 0x3802f100 */ /* not lifted */
   7403     RECOMP_FLAGS_IN();
   7404     goto L_3802DBEB; /* 0x3802DB9B: jmp 0x3802dbeb */
   7405 L_3802DB9D:
   7406     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3802DB9D: mov dl, byte ptr [ecx + 0x14] */
   7407     /* test LO8(edx), LO8(edx) */ /* 0x3802DBA0: test dl, dl */
   7408     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   7409     _cf = 0;
   7410     _flag_k = FK_NARROW(FK_TEST, 24);
   7411     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802DBBE; /* 0x3802DBA2: jne 0x3802dbbe */
   7412 L_3802DBA4:
   7413     MEM8(eax + 0x14) = (uint8_t)(1); /* 0x3802DBA4: mov byte ptr [eax + 0x14], 1 */
   7414     MEM8(ecx + 0x14) = (uint8_t)(1); /* 0x3802DBA8: mov byte ptr [ecx + 0x14], 1 */
   7415     edx = MEM32(esi + 0x4); /* 0x3802DBAC: mov edx, dword ptr [esi + 4] */
   7416     eax = MEM32(edx + 0x4); /* 0x3802DBAF: mov eax, dword ptr [edx + 4] */
   7417     MEM8(eax + 0x14) = (uint8_t)(0); /* 0x3802DBB2: mov byte ptr [eax + 0x14], 0 */
   7418     ecx = MEM32(esi + 0x4); /* 0x3802DBB6: mov ecx, dword ptr [esi + 4] */
   7419     esi = MEM32(ecx + 0x4); /* 0x3802DBB9: mov esi, dword ptr [ecx + 4] */
   7420     goto L_3802DBEB; /* 0x3802DBBC: jmp 0x3802dbeb */
   7421 L_3802DBBE:
   7422     /* cmp esi, MEM32(eax) */ /* 0x3802DBBE: cmp esi, dword ptr [eax] */
   7423     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(eax));
   7424     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7425     _flag_k = FK_CMP;
   7426     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DBCC; /* 0x3802DBC0: jne 0x3802dbcc */
   7427 L_3802DBC2:
   7428     esi = eax; /* 0x3802DBC2: mov esi, eax */
   7429     PUSH32(esp, esi); /* 0x3802DBC4: push esi */
   7430     ecx = edi; /* 0x3802DBC5: mov ecx, edi */
   7431     RECOMP_ICALL(0x3802F100u); /* 0x3802DBC7: call 0x3802f100 */ /* not lifted */
   7432     RECOMP_FLAGS_IN();
   7433 L_3802DBCC:
   7434     edx = MEM32(esi + 0x4); /* 0x3802DBCC: mov edx, dword ptr [esi + 4] */
   7435     MEM8(edx + 0x14) = (uint8_t)(1); /* 0x3802DBCF: mov byte ptr [edx + 0x14], 1 */
   7436     eax = MEM32(esi + 0x4); /* 0x3802DBD3: mov eax, dword ptr [esi + 4] */
   7437     ecx = MEM32(eax + 0x4); /* 0x3802DBD6: mov ecx, dword ptr [eax + 4] */
   7438     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3802DBD9: mov byte ptr [ecx + 0x14], 0 */
   7439     edx = MEM32(esi + 0x4); /* 0x3802DBDD: mov edx, dword ptr [esi + 4] */
   7440     eax = MEM32(edx + 0x4); /* 0x3802DBE0: mov eax, dword ptr [edx + 4] */
   7441     PUSH32(esp, eax); /* 0x3802DBE3: push eax */
   7442     ecx = edi; /* 0x3802DBE4: mov ecx, edi */
   7443     RECOMP_ICALL(0x3803B270u); /* 0x3802DBE6: call 0x3803b270 */ /* not lifted */
   7444     RECOMP_FLAGS_IN();
   7445 L_3802DBEB:
   7446     ecx = MEM32(edi + 0x4); /* 0x3802DBEB: mov ecx, dword ptr [edi + 4] */
   7447     /* cmp esi, MEM32(ecx + 0x4) */ /* 0x3802DBEE: cmp esi, dword ptr [ecx + 4] */
   7448     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   7449     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7450     _flag_k = FK_CMP;
   7451     RECOMP_BACKEDGE();
   7452     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DB32; /* 0x3802DBF1: jne 0x3802db32 */
   7453 L_3802DBF7:
   7454     edx = MEM32(edi + 0x4); /* 0x3802DBF7: mov edx, dword ptr [edi + 4] */
   7455     eax = MEM32(edx + 0x4); /* 0x3802DBFA: mov eax, dword ptr [edx + 4] */
   7456     MEM8(eax + 0x14) = (uint8_t)(1); /* 0x3802DBFD: mov byte ptr [eax + 0x14], 1 */
   7457     eax = MEM32(ebp + 0x8); /* 0x3802DC01: mov eax, dword ptr [ebp + 8] */
   7458     edi = POP32_VAL(esp); /* 0x3802DC04: pop edi */
   7459     MEM8(ebp + (-0x8)) = (uint8_t)(1); /* 0x3802DC05: mov byte ptr [ebp - 8], 1 */
   7460     ecx = MEM32(ebp + (-0x8)); /* 0x3802DC09: mov ecx, dword ptr [ebp - 8] */
   7461     MEM32(eax) = ebx; /* 0x3802DC0C: mov dword ptr [eax], ebx */
   7462     esi = POP32_VAL(esp); /* 0x3802DC0E: pop esi */
   7463     MEM32(eax + 0x4) = ecx; /* 0x3802DC0F: mov dword ptr [eax + 4], ecx */
   7464     ebx = POP32_VAL(esp); /* 0x3802DC12: pop ebx */
   7465     esp = ebp; /* 0x3802DC13: mov esp, ebp */
   7466     ebp = POP32_VAL(esp); /* 0x3802DC15: pop ebp */
   7467     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802DC16: ret 8 */
   7468 L_3802DC19:
   7469     /* test LO8(eax), LO8(eax) */ /* 0x3802DC19: test al, al */
   7470     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   7471     _cf = 0;
   7472     _flag_k = FK_NARROW(FK_TEST, 24);
   7473     edx = esi; /* 0x3802DC1B: mov edx, esi */
   7474     MEM32(ebp + (-0x8)) = edx; /* 0x3802DC1D: mov dword ptr [ebp - 8], edx */
   7475     if (TEST_Z(_flag_a, _flag_b)) goto L_3802DC5C; /* 0x3802DC20: je 0x3802dc5c */
   7476 L_3802DC22:
   7477     /* cmp esi, MEM32(ecx) */ /* 0x3802DC22: cmp esi, dword ptr [ecx] */
   7478     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(ecx));
   7479     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7480     _flag_k = FK_CMP;
   7481     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DC51; /* 0x3802DC24: jne 0x3802dc51 */
   7482 L_3802DC26:
   7483     edx = MEM32(ebp + 0xC); /* 0x3802DC26: mov edx, dword ptr [ebp + 0xc] */
   7484     PUSH32(esp, edx); /* 0x3802DC29: push edx */
   7485     PUSH32(esp, esi); /* 0x3802DC2A: push esi */
   7486     PUSH32(esp, ebx); /* 0x3802DC2B: push ebx */
   7487     eax = ebp + 0xC; /* 0x3802DC2C: lea eax, [ebp + 0xc] */
   7488     PUSH32(esp, eax); /* 0x3802DC2F: push eax */
   7489     ecx = edi; /* 0x3802DC30: mov ecx, edi */
   7490     RECOMP_ICALL(0x38024A00u); /* 0x3802DC32: call 0x38024a00 */ /* not lifted */
   7491     RECOMP_FLAGS_IN();
   7492     ecx = MEM32(eax); /* 0x3802DC37: mov ecx, dword ptr [eax] */
   7493     eax = MEM32(ebp + 0x8); /* 0x3802DC39: mov eax, dword ptr [ebp + 8] */
   7494     edi = POP32_VAL(esp); /* 0x3802DC3C: pop edi */
   7495     MEM32(eax) = ecx; /* 0x3802DC3D: mov dword ptr [eax], ecx */
   7496     MEM8(ebp + (-0x8)) = (uint8_t)(1); /* 0x3802DC3F: mov byte ptr [ebp - 8], 1 */
   7497     ecx = MEM32(ebp + (-0x8)); /* 0x3802DC43: mov ecx, dword ptr [ebp - 8] */
   7498     esi = POP32_VAL(esp); /* 0x3802DC46: pop esi */
   7499     MEM32(eax + 0x4) = ecx; /* 0x3802DC47: mov dword ptr [eax + 4], ecx */
   7500     ebx = POP32_VAL(esp); /* 0x3802DC4A: pop ebx */
   7501     esp = ebp; /* 0x3802DC4B: mov esp, ebp */
   7502     ebp = POP32_VAL(esp); /* 0x3802DC4D: pop ebp */
   7503     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802DC4E: ret 8 */
   7504 L_3802DC51:
   7505     ecx = ebp + (-0x8); /* 0x3802DC51: lea ecx, [ebp - 8] */
   7506     RECOMP_ICALL(0x38013690u); /* 0x3802DC54: call 0x38013690 */ /* not lifted */
   7507     RECOMP_FLAGS_IN();
   7508     edx = MEM32(ebp + (-0x8)); /* 0x3802DC59: mov edx, dword ptr [ebp - 8] */
   7509 L_3802DC5C:
   7510     ecx = MEM32(edx + 0xC); /* 0x3802DC5C: mov ecx, dword ptr [edx + 0xc] */
   7511     eax = MEM32(ebp + 0xC); /* 0x3802DC5F: mov eax, dword ptr [ebp + 0xc] */
   7512     /* cmp ecx, MEM32(eax) */ /* 0x3802DC62: cmp ecx, dword ptr [eax] */
   7513     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax));
   7514     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7515     _flag_k = FK_CMP;
   7516     if (CMP_GE(_flag_a, _flag_b)) goto L_3802DC8E; /* 0x3802DC64: jge 0x3802dc8e */
   7517 L_3802DC66:
   7518     PUSH32(esp, eax); /* 0x3802DC66: push eax */
   7519     PUSH32(esp, esi); /* 0x3802DC67: push esi */
   7520     PUSH32(esp, ebx); /* 0x3802DC68: push ebx */
   7521     edx = ebp + 0xC; /* 0x3802DC69: lea edx, [ebp + 0xc] */
   7522     PUSH32(esp, edx); /* 0x3802DC6C: push edx */
   7523     ecx = edi; /* 0x3802DC6D: mov ecx, edi */
   7524     RECOMP_ICALL(0x38024A00u); /* 0x3802DC6F: call 0x38024a00 */ /* not lifted */
   7525     RECOMP_FLAGS_IN();
   7526     ecx = MEM32(eax); /* 0x3802DC74: mov ecx, dword ptr [eax] */
   7527     eax = MEM32(ebp + 0x8); /* 0x3802DC76: mov eax, dword ptr [ebp + 8] */
   7528     edi = POP32_VAL(esp); /* 0x3802DC79: pop edi */
   7529     MEM32(eax) = ecx; /* 0x3802DC7A: mov dword ptr [eax], ecx */
   7530     MEM8(ebp + (-0x8)) = (uint8_t)(1); /* 0x3802DC7C: mov byte ptr [ebp - 8], 1 */
   7531     ecx = MEM32(ebp + (-0x8)); /* 0x3802DC80: mov ecx, dword ptr [ebp - 8] */
   7532     esi = POP32_VAL(esp); /* 0x3802DC83: pop esi */
   7533     MEM32(eax + 0x4) = ecx; /* 0x3802DC84: mov dword ptr [eax + 4], ecx */
   7534     ebx = POP32_VAL(esp); /* 0x3802DC87: pop ebx */
   7535     esp = ebp; /* 0x3802DC88: mov esp, ebp */
   7536     ebp = POP32_VAL(esp); /* 0x3802DC8A: pop ebp */
   7537     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802DC8B: ret 8 */
   7538 L_3802DC8E:
   7539     eax = MEM32(ebp + 0x8); /* 0x3802DC8E: mov eax, dword ptr [ebp + 8] */
   7540     edi = POP32_VAL(esp); /* 0x3802DC91: pop edi */
   7541     MEM32(eax) = edx; /* 0x3802DC92: mov dword ptr [eax], edx */
   7542     MEM8(ebp + (-0x8)) = (uint8_t)(0); /* 0x3802DC94: mov byte ptr [ebp - 8], 0 */
   7543     edx = MEM32(ebp + (-0x8)); /* 0x3802DC98: mov edx, dword ptr [ebp - 8] */
   7544     esi = POP32_VAL(esp); /* 0x3802DC9B: pop esi */
   7545     MEM32(eax + 0x4) = edx; /* 0x3802DC9C: mov dword ptr [eax + 4], edx */
   7546     ebx = POP32_VAL(esp); /* 0x3802DC9F: pop ebx */
   7547     esp = ebp; /* 0x3802DCA0: mov esp, ebp */
   7548     ebp = POP32_VAL(esp); /* 0x3802DCA2: pop ebp */
   7549     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802DCA3: ret 8 */
   7550     RECOMP_REGS_OUT();
   7551 }
   7552 
   7553 void sub_3802DCB0(void) {
   7554     int _fpu_cmp = 0;
   7555     uint32_t _cf = 0;
   7556     int _df = 1;
   7557     uint32_t _flag_k = FK_NONE;
   7558     uint32_t _flag_a = 0, _flag_b = 0;
   7559     uint32_t _itail_tgt = 0;
   7560     RECOMP_REGS_LOCALS
   7561     RECOMP_ENTER(0x3802DCB0u);
   7562 
   7563 L_3802DCB0:
   7564     PUSH32(esp, ebp); /* 0x3802DCB0: push ebp */
   7565     ebp = esp; /* 0x3802DCB1: mov ebp, esp */
   7566     PUSH32(esp, ebx); /* 0x3802DCB3: push ebx */
   7567     ebx = MEM32(ebp + 0x10); /* 0x3802DCB4: mov ebx, dword ptr [ebp + 0x10] */
   7568     PUSH32(esp, esi); /* 0x3802DCB7: push esi */
   7569     esi = ecx; /* 0x3802DCB8: mov esi, ecx */
   7570     eax = MEM32(esi + 0x10); /* 0x3802DCBA: mov eax, dword ptr [esi + 0x10] */
   7571     /* test eax, eax */ /* 0x3802DCBD: test eax, eax */
   7572     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   7573     _cf = 0;
   7574     _flag_k = FK_TEST;
   7575     ecx = MEM32(ebp + 0xC); /* 0x3802DCBF: mov ecx, dword ptr [ebp + 0xc] */
   7576     PUSH32(esp, edi); /* 0x3802DCC2: push edi */
   7577     if (TEST_Z(_flag_a, _flag_b)) goto L_3802DD25; /* 0x3802DCC3: je 0x3802dd25 */
   7578 L_3802DCC5:
   7579     eax = MEM32(esi + 0x4); /* 0x3802DCC5: mov eax, dword ptr [esi + 4] */
   7580     /* cmp ecx, MEM32(eax) */ /* 0x3802DCC8: cmp ecx, dword ptr [eax] */
   7581     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax));
   7582     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7583     _flag_k = FK_CMP;
   7584     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DD25; /* 0x3802DCCA: jne 0x3802dd25 */
   7585 L_3802DCCC:
   7586     /* cmp ebx, eax */ /* 0x3802DCCC: cmp ebx, eax */
   7587     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(eax);
   7588     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7589     _flag_k = FK_CMP;
   7590     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DD25; /* 0x3802DCCE: jne 0x3802dd25 */
   7591 L_3802DCD0:
   7592     ebx = MEM32(eax + 0x4); /* 0x3802DCD0: mov ebx, dword ptr [eax + 4] */
   7593     /* cmp ebx, MEM32(esi + 0x8) */ /* 0x3802DCD3: cmp ebx, dword ptr [esi + 8] */
   7594     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   7595     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7596     _flag_k = FK_CMP;
   7597     edi = ebx; /* 0x3802DCD6: mov edi, ebx */
   7598     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DCF9; /* 0x3802DCD8: je 0x3802dcf9 */
   7599 L_3802DCDA:
   7600     eax = MEM32(edi + 0x8); /* 0x3802DCDA: mov eax, dword ptr [edi + 8] */
   7601     PUSH32(esp, eax); /* 0x3802DCDD: push eax */
   7602     ecx = esi; /* 0x3802DCDE: mov ecx, esi */
   7603     RECOMP_ICALL(0x3802E7F0u); /* 0x3802DCE0: call 0x3802e7f0 */ /* not lifted */
   7604     RECOMP_FLAGS_IN();
   7605     edi = MEM32(edi); /* 0x3802DCE5: mov edi, dword ptr [edi] */
   7606     PUSH32(esp, ebx); /* 0x3802DCE7: push ebx */
   7607     RECOMP_ICALL(0x3804B4F6u); /* 0x3802DCE8: call 0x3804b4f6 */ /* not lifted */
   7608     RECOMP_FLAGS_IN();
   7609     eax = MEM32(esi + 0x8); /* 0x3802DCED: mov eax, dword ptr [esi + 8] */
   7610     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   7611     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7612     esp = esp + 4; /* 0x3802DCF0: add esp, 4 */
   7613     _flag_k = FK_ADD;
   7614     /* cmp edi, eax */ /* 0x3802DCF3: cmp edi, eax */
   7615     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   7616     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7617     _flag_k = FK_CMP;
   7618     ebx = edi; /* 0x3802DCF5: mov ebx, edi */
   7619     RECOMP_BACKEDGE();
   7620     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DCDA; /* 0x3802DCF7: jne 0x3802dcda */
   7621 L_3802DCF9:
   7622     ecx = MEM32(esi + 0x4); /* 0x3802DCF9: mov ecx, dword ptr [esi + 4] */
   7623     edx = MEM32(esi + 0x8); /* 0x3802DCFC: mov edx, dword ptr [esi + 8] */
   7624     MEM32(ecx + 0x4) = edx; /* 0x3802DCFF: mov dword ptr [ecx + 4], edx */
   7625     eax = MEM32(esi + 0x4); /* 0x3802DD02: mov eax, dword ptr [esi + 4] */
   7626     MEM32(esi + 0x10) = 0; /* 0x3802DD05: mov dword ptr [esi + 0x10], 0 */
   7627     MEM32(eax) = eax; /* 0x3802DD0C: mov dword ptr [eax], eax */
   7628     eax = MEM32(esi + 0x4); /* 0x3802DD0E: mov eax, dword ptr [esi + 4] */
   7629     MEM32(eax + 0x8) = eax; /* 0x3802DD11: mov dword ptr [eax + 8], eax */
   7630     eax = MEM32(esi + 0x4); /* 0x3802DD14: mov eax, dword ptr [esi + 4] */
   7631     ecx = MEM32(eax); /* 0x3802DD17: mov ecx, dword ptr [eax] */
   7632     eax = MEM32(ebp + 0x8); /* 0x3802DD19: mov eax, dword ptr [ebp + 8] */
   7633     edi = POP32_VAL(esp); /* 0x3802DD1C: pop edi */
   7634     esi = POP32_VAL(esp); /* 0x3802DD1D: pop esi */
   7635     MEM32(eax) = ecx; /* 0x3802DD1E: mov dword ptr [eax], ecx */
   7636     ebx = POP32_VAL(esp); /* 0x3802DD20: pop ebx */
   7637     ebp = POP32_VAL(esp); /* 0x3802DD21: pop ebp */
   7638     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802DD22: ret 0xc */
   7639 L_3802DD25:
   7640     /* cmp ecx, ebx */ /* 0x3802DD25: cmp ecx, ebx */
   7641     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
   7642     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7643     _flag_k = FK_CMP;
   7644     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DD46; /* 0x3802DD27: je 0x3802dd46 */
   7645 L_3802DD29:
   7646     edi = ecx; /* 0x3802DD29: mov edi, ecx */
   7647     ecx = ebp + 0xC; /* 0x3802DD2B: lea ecx, [ebp + 0xc] */
   7648     RECOMP_ICALL(0x38035590u); /* 0x3802DD2E: call 0x38035590 */ /* not lifted */
   7649     RECOMP_FLAGS_IN();
   7650     PUSH32(esp, edi); /* 0x3802DD33: push edi */
   7651     ecx = ebp + 0x10; /* 0x3802DD34: lea ecx, [ebp + 0x10] */
   7652     PUSH32(esp, ecx); /* 0x3802DD37: push ecx */
   7653     ecx = esi; /* 0x3802DD38: mov ecx, esi */
   7654     RECOMP_ICALL(0x3800F9D0u); /* 0x3802DD3A: call 0x3800f9d0 */ /* not lifted */
   7655     RECOMP_FLAGS_IN();
   7656     ecx = MEM32(ebp + 0xC); /* 0x3802DD3F: mov ecx, dword ptr [ebp + 0xc] */
   7657     /* cmp ecx, ebx */ /* 0x3802DD42: cmp ecx, ebx */
   7658     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
   7659     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7660     _flag_k = FK_CMP;
   7661     RECOMP_BACKEDGE();
   7662     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DD29; /* 0x3802DD44: jne 0x3802dd29 */
   7663 L_3802DD46:
   7664     eax = MEM32(ebp + 0x8); /* 0x3802DD46: mov eax, dword ptr [ebp + 8] */
   7665     edi = POP32_VAL(esp); /* 0x3802DD49: pop edi */
   7666     esi = POP32_VAL(esp); /* 0x3802DD4A: pop esi */
   7667     MEM32(eax) = ecx; /* 0x3802DD4B: mov dword ptr [eax], ecx */
   7668     ebx = POP32_VAL(esp); /* 0x3802DD4D: pop ebx */
   7669     ebp = POP32_VAL(esp); /* 0x3802DD4E: pop ebp */
   7670     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802DD4F: ret 0xc */
   7671     RECOMP_REGS_OUT();
   7672 }
   7673 
   7674 void sub_3802DD60(void) {
   7675     int _fpu_cmp = 0;
   7676     uint32_t _cf = 0;
   7677     int _df = 1;
   7678     uint32_t _flag_k = FK_NONE;
   7679     uint32_t _flag_a = 0, _flag_b = 0;
   7680     uint32_t _itail_tgt = 0;
   7681     RECOMP_REGS_LOCALS
   7682     RECOMP_ENTER(0x3802DD60u);
   7683 
   7684 L_3802DD60:
   7685     PUSH32(esp, ebp); /* 0x3802DD60: push ebp */
   7686     ebp = esp; /* 0x3802DD61: mov ebp, esp */
   7687     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   7688     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7689     esp = esp - 0xCu; /* 0x3802DD63: sub esp, 0xc */
   7690     _flag_k = FK_CMP;
   7691     PUSH32(esp, ebx); /* 0x3802DD66: push ebx */
   7692     PUSH32(esp, esi); /* 0x3802DD67: push esi */
   7693     esi = ecx; /* 0x3802DD68: mov esi, ecx */
   7694     edx = MEM32(esi + 0x4); /* 0x3802DD6A: mov edx, dword ptr [esi + 4] */
   7695     ecx = MEM32(esi + 0xC); /* 0x3802DD6D: mov ecx, dword ptr [esi + 0xc] */
   7696     PUSH32(esp, edi); /* 0x3802DD70: push edi */
   7697     edi = MEM32(ebp + 0x8); /* 0x3802DD71: mov edi, dword ptr [ebp + 8] */
   7698     eax = edi; /* 0x3802DD74: mov eax, edi */
   7699     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   7700     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7701     eax = eax - edx; /* 0x3802DD76: sub eax, edx */
   7702     _flag_k = FK_CMP;
   7703     if (4u) _cf = (((eax) >> 3) & 1u); /* 0x3802DD78: sar eax, 4 */
   7704     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7705     eax = (uint32_t)((int32_t)eax >> 4u);
   7706     MEM32(ebp + (-0xC)) = eax; /* 0x3802DD7B: mov dword ptr [ebp - 0xc], eax */
   7707     eax = MEM32(esi + 0x8); /* 0x3802DD7E: mov eax, dword ptr [esi + 8] */
   7708     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
   7709     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7710     ecx = ecx - eax; /* 0x3802DD81: sub ecx, eax */
   7711     _flag_k = FK_CMP;
   7712     if (4u) _cf = (((ecx) >> 3) & 1u); /* 0x3802DD83: sar ecx, 4 */
   7713     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7714     ecx = (uint32_t)((int32_t)ecx >> 4u);
   7715     /* cmp ecx, 1 */ /* 0x3802DD86: cmp ecx, 1 */
   7716     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   7717     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7718     _flag_k = FK_CMP;
   7719     if (CMP_AE(_flag_a, _flag_b)) goto L_3802DE64; /* 0x3802DD89: jae 0x3802de64 */
   7720 L_3802DD8F:
   7721     /* test edx, edx */ /* 0x3802DD8F: test edx, edx */
   7722     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   7723     _cf = 0;
   7724     _flag_k = FK_TEST;
   7725     if (TEST_Z(_flag_a, _flag_b)) goto L_3802DD9F; /* 0x3802DD91: je 0x3802dd9f */
   7726 L_3802DD93:
   7727     ecx = eax; /* 0x3802DD93: mov ecx, eax */
   7728     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   7729     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7730     ecx = ecx - edx; /* 0x3802DD95: sub ecx, edx */
   7731     _flag_k = FK_CMP;
   7732     if (4u) _cf = (((ecx) >> 3) & 1u); /* 0x3802DD97: sar ecx, 4 */
   7733     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7734     ecx = (uint32_t)((int32_t)ecx >> 4u);
   7735     /* cmp ecx, 1 */ /* 0x3802DD9A: cmp ecx, 1 */
   7736     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   7737     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7738     _flag_k = FK_CMP;
   7739     if (CMP_A(_flag_a, _flag_b)) goto L_3802DDA4; /* 0x3802DD9D: ja 0x3802dda4 */
   7740 L_3802DD9F:
   7741     ecx = 1; /* 0x3802DD9F: mov ecx, 1 */
   7742 L_3802DDA4:
   7743     /* test edx, edx */ /* 0x3802DDA4: test edx, edx */
   7744     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   7745     _cf = 0;
   7746     _flag_k = FK_TEST;
   7747     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802DDAC; /* 0x3802DDA6: jne 0x3802ddac */
   7748 L_3802DDA8:
   7749     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   7750     eax = 0; /* 0x3802DDA8: xor eax, eax */
   7751     _cf = 0;
   7752     _flag_k = FK_TEST;
   7753     goto L_3802DDB1; /* 0x3802DDAA: jmp 0x3802ddb1 */
   7754 L_3802DDAC:
   7755     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   7756     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7757     eax = eax - edx; /* 0x3802DDAC: sub eax, edx */
   7758     _flag_k = FK_CMP;
   7759     if (4u) _cf = (((eax) >> 3) & 1u); /* 0x3802DDAE: sar eax, 4 */
   7760     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7761     eax = (uint32_t)((int32_t)eax >> 4u);
   7762 L_3802DDB1:
   7763     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   7764     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7765     eax = eax + ecx; /* 0x3802DDB1: add eax, ecx */
   7766     _flag_k = FK_ADD;
   7767     /* test eax, eax */ /* 0x3802DDB3: test eax, eax */
   7768     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   7769     _cf = 0;
   7770     _flag_k = FK_TEST;
   7771     MEM32(ebp + (-0x4)) = eax; /* 0x3802DDB5: mov dword ptr [ebp - 4], eax */
   7772     if (TEST_NS(_flag_a, _flag_b)) goto L_3802DDBC; /* 0x3802DDB8: jge 0x3802ddbc */
   7773 L_3802DDBA:
   7774     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   7775     eax = 0; /* 0x3802DDBA: xor eax, eax */
   7776     _cf = 0;
   7777     _flag_k = FK_TEST;
   7778 L_3802DDBC:
   7779     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802DDBC: shl eax, 4 */
   7780     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7781     eax = eax << 4u; /* 0x3802DDBC: shl eax, 4 */
   7782     PUSH32(esp, eax); /* 0x3802DDBF: push eax */
   7783     RECOMP_ICALL(0x3804B676u); /* 0x3802DDC0: call 0x3804b676 */ /* not lifted */
   7784     RECOMP_FLAGS_IN();
   7785     ebx = MEM32(esi + 0x4); /* 0x3802DDC5: mov ebx, dword ptr [esi + 4] */
   7786     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   7787     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7788     esp = esp + 4; /* 0x3802DDC8: add esp, 4 */
   7789     _flag_k = FK_ADD;
   7790     /* cmp ebx, edi */ /* 0x3802DDCB: cmp ebx, edi */
   7791     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(edi);
   7792     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7793     _flag_k = FK_CMP;
   7794     MEM32(ebp + (-0x8)) = eax; /* 0x3802DDCD: mov dword ptr [ebp - 8], eax */
   7795     MEM32(ebp + 0x8) = eax; /* 0x3802DDD0: mov dword ptr [ebp + 8], eax */
   7796     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DDF2; /* 0x3802DDD3: je 0x3802ddf2 */
   7797 L_3802DDD5:
   7798     edx = MEM32(ebp + 0x8); /* 0x3802DDD5: mov edx, dword ptr [ebp + 8] */
   7799     PUSH32(esp, ebx); /* 0x3802DDD8: push ebx */
   7800     PUSH32(esp, edx); /* 0x3802DDD9: push edx */
   7801     RECOMP_ICALL(0x3802F580u); /* 0x3802DDDA: call 0x3802f580 */ /* not lifted */
   7802     RECOMP_FLAGS_IN();
   7803     edx = MEM32(ebp + 0x8); /* 0x3802DDDF: mov edx, dword ptr [ebp + 8] */
   7804     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u);
   7805     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7806     edx = edx + 0x10u; /* 0x3802DDE2: add edx, 0x10 */
   7807     _flag_k = FK_ADD;
   7808     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0x10u);
   7809     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7810     ebx = ebx + 0x10u; /* 0x3802DDE5: add ebx, 0x10 */
   7811     _flag_k = FK_ADD;
   7812     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   7813     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7814     esp = esp + 8; /* 0x3802DDE8: add esp, 8 */
   7815     _flag_k = FK_ADD;
   7816     /* cmp ebx, edi */ /* 0x3802DDEB: cmp ebx, edi */
   7817     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(edi);
   7818     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7819     _flag_k = FK_CMP;
   7820     MEM32(ebp + 0x8) = edx; /* 0x3802DDED: mov dword ptr [ebp + 8], edx */
   7821     RECOMP_BACKEDGE();
   7822     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DDD5; /* 0x3802DDF0: jne 0x3802ddd5 */
   7823 L_3802DDF2:
   7824     eax = MEM32(ebp + 0xC); /* 0x3802DDF2: mov eax, dword ptr [ebp + 0xc] */
   7825     ecx = MEM32(ebp + 0x8); /* 0x3802DDF5: mov ecx, dword ptr [ebp + 8] */
   7826     PUSH32(esp, eax); /* 0x3802DDF8: push eax */
   7827     PUSH32(esp, ecx); /* 0x3802DDF9: push ecx */
   7828     RECOMP_ICALL(0x3802F580u); /* 0x3802DDFA: call 0x3802f580 */ /* not lifted */
   7829     RECOMP_FLAGS_IN();
   7830     edx = MEM32(ebp + 0x8); /* 0x3802DDFF: mov edx, dword ptr [ebp + 8] */
   7831     eax = MEM32(esi + 0x8); /* 0x3802DE02: mov eax, dword ptr [esi + 8] */
   7832     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   7833     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7834     esp = esp + 8; /* 0x3802DE05: add esp, 8 */
   7835     _flag_k = FK_ADD;
   7836     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u);
   7837     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7838     edx = edx + 0x10u; /* 0x3802DE08: add edx, 0x10 */
   7839     _flag_k = FK_ADD;
   7840     PUSH32(esp, edx); /* 0x3802DE0B: push edx */
   7841     PUSH32(esp, eax); /* 0x3802DE0C: push eax */
   7842     PUSH32(esp, edi); /* 0x3802DE0D: push edi */
   7843     ecx = esi; /* 0x3802DE0E: mov ecx, esi */
   7844     RECOMP_ICALL(0x3802F190u); /* 0x3802DE10: call 0x3802f190 */ /* not lifted */
   7845     RECOMP_FLAGS_IN();
   7846     ecx = MEM32(esi + 0x8); /* 0x3802DE15: mov ecx, dword ptr [esi + 8] */
   7847     edx = MEM32(esi + 0x4); /* 0x3802DE18: mov edx, dword ptr [esi + 4] */
   7848     PUSH32(esp, ecx); /* 0x3802DE1B: push ecx */
   7849     PUSH32(esp, edx); /* 0x3802DE1C: push edx */
   7850     ecx = esi; /* 0x3802DE1D: mov ecx, esi */
   7851     RECOMP_ICALL(0x38042760u); /* 0x3802DE1F: call 0x38042760 */ /* not lifted */
   7852     RECOMP_FLAGS_IN();
   7853     eax = MEM32(esi + 0x4); /* 0x3802DE24: mov eax, dword ptr [esi + 4] */
   7854     PUSH32(esp, eax); /* 0x3802DE27: push eax */
   7855     RECOMP_ICALL(0x3804B4F6u); /* 0x3802DE28: call 0x3804b4f6 */ /* not lifted */
   7856     RECOMP_FLAGS_IN();
   7857     eax = MEM32(ebp + (-0x4)); /* 0x3802DE2D: mov eax, dword ptr [ebp - 4] */
   7858     edi = MEM32(ebp + (-0x8)); /* 0x3802DE30: mov edi, dword ptr [ebp - 8] */
   7859     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802DE33: shl eax, 4 */
   7860     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7861     eax = eax << 4u; /* 0x3802DE33: shl eax, 4 */
   7862     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   7863     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7864     eax = eax + edi; /* 0x3802DE36: add eax, edi */
   7865     _flag_k = FK_ADD;
   7866     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   7867     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7868     esp = esp + 4; /* 0x3802DE38: add esp, 4 */
   7869     _flag_k = FK_ADD;
   7870     ecx = esi; /* 0x3802DE3B: mov ecx, esi */
   7871     MEM32(esi + 0xC) = eax; /* 0x3802DE3D: mov dword ptr [esi + 0xc], eax */
   7872     RECOMP_ICALL(0x3802DF60u); /* 0x3802DE40: call 0x3802df60 */ /* not lifted */
   7873     RECOMP_FLAGS_IN();
   7874     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   7875     eax = eax + 1; /* 0x3802DE45: inc eax */
   7876     _flag_k = FK_INC;
   7877     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802DE46: shl eax, 4 */
   7878     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7879     eax = eax << 4u; /* 0x3802DE46: shl eax, 4 */
   7880     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   7881     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7882     eax = eax + edi; /* 0x3802DE49: add eax, edi */
   7883     _flag_k = FK_ADD;
   7884     MEM32(esi + 0x8) = eax; /* 0x3802DE4B: mov dword ptr [esi + 8], eax */
   7885     eax = MEM32(ebp + (-0xC)); /* 0x3802DE4E: mov eax, dword ptr [ebp - 0xc] */
   7886     MEM32(esi + 0x4) = edi; /* 0x3802DE51: mov dword ptr [esi + 4], edi */
   7887     ecx = edi; /* 0x3802DE54: mov ecx, edi */
   7888     edi = POP32_VAL(esp); /* 0x3802DE56: pop edi */
   7889     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802DE57: shl eax, 4 */
   7890     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7891     eax = eax << 4u; /* 0x3802DE57: shl eax, 4 */
   7892     esi = POP32_VAL(esp); /* 0x3802DE5A: pop esi */
   7893     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   7894     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7895     eax = eax + ecx; /* 0x3802DE5B: add eax, ecx */
   7896     _flag_k = FK_ADD;
   7897     ebx = POP32_VAL(esp); /* 0x3802DE5D: pop ebx */
   7898     esp = ebp; /* 0x3802DE5E: mov esp, ebp */
   7899     ebp = POP32_VAL(esp); /* 0x3802DE60: pop ebp */
   7900     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802DE61: ret 8 */
   7901 L_3802DE64:
   7902     ecx = eax; /* 0x3802DE64: mov ecx, eax */
   7903     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
   7904     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7905     ecx = ecx - edi; /* 0x3802DE66: sub ecx, edi */
   7906     _flag_k = FK_CMP;
   7907     if (4u) _cf = (((ecx) >> 3) & 1u); /* 0x3802DE68: sar ecx, 4 */
   7908     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7909     ecx = (uint32_t)((int32_t)ecx >> 4u);
   7910     /* cmp ecx, 1 */ /* 0x3802DE6B: cmp ecx, 1 */
   7911     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   7912     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7913     _flag_k = FK_CMP;
   7914     if (CMP_AE(_flag_a, _flag_b)) goto L_3802DECA; /* 0x3802DE6E: jae 0x3802deca */
   7915 L_3802DE70:
   7916     edx = edi + 0x10; /* 0x3802DE70: lea edx, [edi + 0x10] */
   7917     PUSH32(esp, edx); /* 0x3802DE73: push edx */
   7918     PUSH32(esp, eax); /* 0x3802DE74: push eax */
   7919     PUSH32(esp, edi); /* 0x3802DE75: push edi */
   7920     ecx = esi; /* 0x3802DE76: mov ecx, esi */
   7921     RECOMP_ICALL(0x3802F190u); /* 0x3802DE78: call 0x3802f190 */ /* not lifted */
   7922     RECOMP_FLAGS_IN();
   7923     eax = MEM32(esi + 0x8); /* 0x3802DE7D: mov eax, dword ptr [esi + 8] */
   7924     ecx = MEM32(ebp + 0xC); /* 0x3802DE80: mov ecx, dword ptr [ebp + 0xc] */
   7925     PUSH32(esp, ecx); /* 0x3802DE83: push ecx */
   7926     edx = eax; /* 0x3802DE84: mov edx, eax */
   7927     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edi);
   7928     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7929     edx = edx - edi; /* 0x3802DE86: sub edx, edi */
   7930     _flag_k = FK_CMP;
   7931     if (4u) _cf = (((edx) >> 3) & 1u); /* 0x3802DE88: sar edx, 4 */
   7932     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7933     edx = (uint32_t)((int32_t)edx >> 4u);
   7934     ecx = 1; /* 0x3802DE8B: mov ecx, 1 */
   7935     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   7936     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7937     ecx = ecx - edx; /* 0x3802DE90: sub ecx, edx */
   7938     _flag_k = FK_CMP;
   7939     PUSH32(esp, ecx); /* 0x3802DE92: push ecx */
   7940     PUSH32(esp, eax); /* 0x3802DE93: push eax */
   7941     ecx = esi; /* 0x3802DE94: mov ecx, esi */
   7942     RECOMP_ICALL(0x3802F1D0u); /* 0x3802DE96: call 0x3802f1d0 */ /* not lifted */
   7943     RECOMP_FLAGS_IN();
   7944     eax = MEM32(esi + 0x8); /* 0x3802DE9B: mov eax, dword ptr [esi + 8] */
   7945     /* cmp edi, eax */ /* 0x3802DE9E: cmp edi, eax */
   7946     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   7947     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7948     _flag_k = FK_CMP;
   7949     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DF34; /* 0x3802DEA0: je 0x3802df34 */
   7950 L_3802DEA6:
   7951     edx = MEM32(ebp + 0xC); /* 0x3802DEA6: mov edx, dword ptr [ebp + 0xc] */
   7952     ebx = MEM32(edx); /* 0x3802DEA9: mov ebx, dword ptr [edx] */
   7953     ecx = edi; /* 0x3802DEAB: mov ecx, edi */
   7954     MEM32(ecx) = ebx; /* 0x3802DEAD: mov dword ptr [ecx], ebx */
   7955     ebx = MEM32(edx + 0x4); /* 0x3802DEAF: mov ebx, dword ptr [edx + 4] */
   7956     MEM32(ecx + 0x4) = ebx; /* 0x3802DEB2: mov dword ptr [ecx + 4], ebx */
   7957     ebx = MEM32(edx + 0x8); /* 0x3802DEB5: mov ebx, dword ptr [edx + 8] */
   7958     MEM32(ecx + 0x8) = ebx; /* 0x3802DEB8: mov dword ptr [ecx + 8], ebx */
   7959     edx = MEM32(edx + 0xC); /* 0x3802DEBB: mov edx, dword ptr [edx + 0xc] */
   7960     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(0x10u);
   7961     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7962     edi = edi + 0x10u; /* 0x3802DEBE: add edi, 0x10 */
   7963     _flag_k = FK_ADD;
   7964     /* cmp edi, eax */ /* 0x3802DEC1: cmp edi, eax */
   7965     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   7966     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7967     _flag_k = FK_CMP;
   7968     MEM32(ecx + 0xC) = edx; /* 0x3802DEC3: mov dword ptr [ecx + 0xc], edx */
   7969     RECOMP_BACKEDGE();
   7970     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DEA6; /* 0x3802DEC6: jne 0x3802dea6 */
   7971 L_3802DEC8:
   7972     goto L_3802DF34; /* 0x3802DEC8: jmp 0x3802df34 */
   7973 L_3802DECA:
   7974     PUSH32(esp, eax); /* 0x3802DECA: push eax */
   7975     PUSH32(esp, eax); /* 0x3802DECB: push eax */
   7976     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xFFFFFFF0u);
   7977     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7978     eax = eax + 0xFFFFFFF0u; /* 0x3802DECC: add eax, -0x10 */
   7979     _flag_k = FK_ADD;
   7980     PUSH32(esp, eax); /* 0x3802DECF: push eax */
   7981     ecx = esi; /* 0x3802DED0: mov ecx, esi */
   7982     RECOMP_ICALL(0x3802F190u); /* 0x3802DED2: call 0x3802f190 */ /* not lifted */
   7983     RECOMP_FLAGS_IN();
   7984     ecx = MEM32(esi + 0x8); /* 0x3802DED7: mov ecx, dword ptr [esi + 8] */
   7985     eax = ecx + (-0x10); /* 0x3802DEDA: lea eax, [ecx - 0x10] */
   7986     /* cmp edi, eax */ /* 0x3802DEDD: cmp edi, eax */
   7987     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   7988     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7989     _flag_k = FK_CMP;
   7990     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DF0B; /* 0x3802DEDF: je 0x3802df0b */
   7991 L_3802DEE1:
   7992     goto L_3802DEE6; /* 0x3802DEE1: jmp 0x3802dee6 */
   7993 L_3802DEE3:
   7994     ecx = MEM32(ebp + 0x8); /* 0x3802DEE3: mov ecx, dword ptr [ebp + 8] */
   7995 L_3802DEE6:
   7996     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x10u);
   7997     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7998     eax = eax - 0x10u; /* 0x3802DEE6: sub eax, 0x10 */
   7999     _flag_k = FK_CMP;
   8000     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0x10u);
   8001     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8002     ecx = ecx - 0x10u; /* 0x3802DEE9: sub ecx, 0x10 */
   8003     _flag_k = FK_CMP;
   8004     /* cmp eax, edi */ /* 0x3802DEEC: cmp eax, edi */
   8005     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   8006     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8007     _flag_k = FK_CMP;
   8008     edx = eax; /* 0x3802DEEE: mov edx, eax */
   8009     ebx = MEM32(edx); /* 0x3802DEF0: mov ebx, dword ptr [edx] */
   8010     MEM32(ebp + 0x8) = ecx; /* 0x3802DEF2: mov dword ptr [ebp + 8], ecx */
   8011     MEM32(ecx) = ebx; /* 0x3802DEF5: mov dword ptr [ecx], ebx */
   8012     ebx = MEM32(edx + 0x4); /* 0x3802DEF7: mov ebx, dword ptr [edx + 4] */
   8013     MEM32(ecx + 0x4) = ebx; /* 0x3802DEFA: mov dword ptr [ecx + 4], ebx */
   8014     ebx = MEM32(edx + 0x8); /* 0x3802DEFD: mov ebx, dword ptr [edx + 8] */
   8015     MEM32(ecx + 0x8) = ebx; /* 0x3802DF00: mov dword ptr [ecx + 8], ebx */
   8016     edx = MEM32(edx + 0xC); /* 0x3802DF03: mov edx, dword ptr [edx + 0xc] */
   8017     MEM32(ecx + 0xC) = edx; /* 0x3802DF06: mov dword ptr [ecx + 0xc], edx */
   8018     RECOMP_BACKEDGE();
   8019     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DEE3; /* 0x3802DF09: jne 0x3802dee3 */
   8020 L_3802DF0B:
   8021     eax = edi + 0x10; /* 0x3802DF0B: lea eax, [edi + 0x10] */
   8022     /* cmp edi, eax */ /* 0x3802DF0E: cmp edi, eax */
   8023     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   8024     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8025     _flag_k = FK_CMP;
   8026     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802DF34; /* 0x3802DF10: je 0x3802df34 */
   8027 L_3802DF12:
   8028     ecx = MEM32(ebp + 0xC); /* 0x3802DF12: mov ecx, dword ptr [ebp + 0xc] */
   8029     ebx = MEM32(ecx); /* 0x3802DF15: mov ebx, dword ptr [ecx] */
   8030     edx = edi; /* 0x3802DF17: mov edx, edi */
   8031     MEM32(edx) = ebx; /* 0x3802DF19: mov dword ptr [edx], ebx */
   8032     ebx = MEM32(ecx + 0x4); /* 0x3802DF1B: mov ebx, dword ptr [ecx + 4] */
   8033     MEM32(edx + 0x4) = ebx; /* 0x3802DF1E: mov dword ptr [edx + 4], ebx */
   8034     ebx = MEM32(ecx + 0x8); /* 0x3802DF21: mov ebx, dword ptr [ecx + 8] */
   8035     MEM32(edx + 0x8) = ebx; /* 0x3802DF24: mov dword ptr [edx + 8], ebx */
   8036     ecx = MEM32(ecx + 0xC); /* 0x3802DF27: mov ecx, dword ptr [ecx + 0xc] */
   8037     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(0x10u);
   8038     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8039     edi = edi + 0x10u; /* 0x3802DF2A: add edi, 0x10 */
   8040     _flag_k = FK_ADD;
   8041     /* cmp edi, eax */ /* 0x3802DF2D: cmp edi, eax */
   8042     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   8043     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8044     _flag_k = FK_CMP;
   8045     MEM32(edx + 0xC) = ecx; /* 0x3802DF2F: mov dword ptr [edx + 0xc], ecx */
   8046     RECOMP_BACKEDGE();
   8047     if (CMP_NE(_flag_a, _flag_b)) goto L_3802DF12; /* 0x3802DF32: jne 0x3802df12 */
   8048 L_3802DF34:
   8049     eax = MEM32(esi + 0x8); /* 0x3802DF34: mov eax, dword ptr [esi + 8] */
   8050     ecx = MEM32(esi + 0x4); /* 0x3802DF37: mov ecx, dword ptr [esi + 4] */
   8051     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x10u);
   8052     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8053     eax = eax + 0x10u; /* 0x3802DF3A: add eax, 0x10 */
   8054     _flag_k = FK_ADD;
   8055     MEM32(esi + 0x8) = eax; /* 0x3802DF3D: mov dword ptr [esi + 8], eax */
   8056     eax = MEM32(ebp + (-0xC)); /* 0x3802DF40: mov eax, dword ptr [ebp - 0xc] */
   8057     edi = POP32_VAL(esp); /* 0x3802DF43: pop edi */
   8058     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802DF44: shl eax, 4 */
   8059     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   8060     eax = eax << 4u; /* 0x3802DF44: shl eax, 4 */
   8061     esi = POP32_VAL(esp); /* 0x3802DF47: pop esi */
   8062     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   8063     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8064     eax = eax + ecx; /* 0x3802DF48: add eax, ecx */
   8065     _flag_k = FK_ADD;
   8066     ebx = POP32_VAL(esp); /* 0x3802DF4A: pop ebx */
   8067     esp = ebp; /* 0x3802DF4B: mov esp, ebp */
   8068     ebp = POP32_VAL(esp); /* 0x3802DF4D: pop ebp */
   8069     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802DF4E: ret 8 */
   8070     RECOMP_REGS_OUT();
   8071 }
   8072 
   8073 void sub_3802DF60(void) {
   8074     int _fpu_cmp = 0;
   8075     uint32_t _cf = 0;
   8076     int _df = 1;
   8077     uint32_t _flag_k = FK_NONE;
   8078     uint32_t _flag_a = 0, _flag_b = 0;
   8079     uint32_t _itail_tgt = 0;
   8080     RECOMP_REGS_LOCALS
   8081     RECOMP_ENTER(0x3802DF60u);
   8082 
   8083 L_3802DF60:
   8084     edx = MEM32(ecx + 0x4); /* 0x3802DF60: mov edx, dword ptr [ecx + 4] */
   8085     /* test edx, edx */ /* 0x3802DF63: test edx, edx */
   8086     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   8087     _cf = 0;
   8088     _flag_k = FK_TEST;
   8089     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802DF6A; /* 0x3802DF65: jne 0x3802df6a */
   8090 L_3802DF67:
   8091     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   8092     eax = 0; /* 0x3802DF67: xor eax, eax */
   8093     _cf = 0;
   8094     _flag_k = FK_TEST;
   8095     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802DF69: ret  */
   8096 L_3802DF6A:
   8097     eax = MEM32(ecx + 0x8); /* 0x3802DF6A: mov eax, dword ptr [ecx + 8] */
   8098     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   8099     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8100     eax = eax - edx; /* 0x3802DF6D: sub eax, edx */
   8101     _flag_k = FK_CMP;
   8102     if (4u) _cf = (((eax) >> 3) & 1u); /* 0x3802DF6F: sar eax, 4 */
   8103     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   8104     eax = (uint32_t)((int32_t)eax >> 4u);
   8105     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802DF72: ret  */
   8106     RECOMP_REGS_OUT();
   8107 }
   8108 
   8109 void sub_3802DF80(void) {
   8110     int _fpu_cmp = 0;
   8111     uint32_t _cf = 0;
   8112     int _df = 1;
   8113     uint32_t _flag_k = FK_NONE;
   8114     uint32_t _flag_a = 0, _flag_b = 0;
   8115     uint32_t _itail_tgt = 0;
   8116     RECOMP_REGS_LOCALS
   8117     RECOMP_ENTER(0x3802DF80u);
   8118 
   8119 L_3802DF80:
   8120     eax = MEM32(ecx + 0x4); /* 0x3802DF80: mov eax, dword ptr [ecx + 4] */
   8121     /* test eax, eax */ /* 0x3802DF83: test eax, eax */
   8122     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   8123     _cf = 0;
   8124     _flag_k = FK_TEST;
   8125     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802DF88; /* 0x3802DF85: jne 0x3802df88 */
   8126 L_3802DF87:
   8127     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802DF87: ret  */
   8128 L_3802DF88:
   8129     ecx = MEM32(ecx + 0x8); /* 0x3802DF88: mov ecx, dword ptr [ecx + 8] */
   8130     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
   8131     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8132     ecx = ecx - eax; /* 0x3802DF8B: sub ecx, eax */
   8133     _flag_k = FK_CMP;
   8134     eax = 0x2AAAAAABu; /* 0x3802DF8D: mov eax, 0x2aaaaaab */
   8135     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(ecx); /* 0x3802DF92: imul ecx */
   8136       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
   8137       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
   8138     if (1u) _cf = (((edx) >> 0) & 1u); /* 0x3802DF94: sar edx, 1 */
   8139     if (1u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 1u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   8140     edx = (uint32_t)((int32_t)edx >> 1u);
   8141     eax = edx; /* 0x3802DF96: mov eax, edx */
   8142     if (31u) _cf = (((eax) >> 30) & 1u); /* 0x3802DF98: shr eax, 0x1f */
   8143     if (31u) { _flag_a = recomp_flags_pack((eax >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   8144     eax = eax >> 31u; /* 0x3802DF98: shr eax, 0x1f */
   8145     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   8146     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8147     edx = edx + eax; /* 0x3802DF9B: add edx, eax */
   8148     _flag_k = FK_ADD;
   8149     eax = edx; /* 0x3802DF9D: mov eax, edx */
   8150     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802DF9F: ret  */
   8151     RECOMP_REGS_OUT();
   8152 }
   8153 
   8154 void sub_3802DFA0(void) {
   8155     int _fpu_cmp = 0;
   8156     uint32_t _cf = 0;
   8157     int _df = 1;
   8158     uint32_t _flag_k = FK_NONE;
   8159     uint32_t _flag_a = 0, _flag_b = 0;
   8160     uint32_t _itail_tgt = 0;
   8161     RECOMP_REGS_LOCALS
   8162     RECOMP_ENTER(0x3802DFA0u);
   8163 
   8164 L_3802DFA0:
   8165     PUSH32(esp, ebp); /* 0x3802DFA0: push ebp */
   8166     ebp = esp; /* 0x3802DFA1: mov ebp, esp */
   8167     eax = MEM32(ebp + 0x8); /* 0x3802DFA3: mov eax, dword ptr [ebp + 8] */
   8168     edx = MEM32(ecx + 0x4); /* 0x3802DFA6: mov edx, dword ptr [ecx + 4] */
   8169     PUSH32(esp, esi); /* 0x3802DFA9: push esi */
   8170     esi = MEM32(eax + 0x4); /* 0x3802DFAA: mov esi, dword ptr [eax + 4] */
   8171     MEM32(ecx + 0x4) = esi; /* 0x3802DFAD: mov dword ptr [ecx + 4], esi */
   8172     MEM32(eax + 0x4) = edx; /* 0x3802DFB0: mov dword ptr [eax + 4], edx */
   8173     esi = MEM32(eax + 0x8); /* 0x3802DFB3: mov esi, dword ptr [eax + 8] */
   8174     edx = MEM32(ecx + 0x8); /* 0x3802DFB6: mov edx, dword ptr [ecx + 8] */
   8175     MEM32(ecx + 0x8) = esi; /* 0x3802DFB9: mov dword ptr [ecx + 8], esi */
   8176     MEM32(eax + 0x8) = edx; /* 0x3802DFBC: mov dword ptr [eax + 8], edx */
   8177     esi = POP32_VAL(esp); /* 0x3802DFBF: pop esi */
   8178     ebp = POP32_VAL(esp); /* 0x3802DFC0: pop ebp */
   8179     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802DFC1: ret 4 */
   8180     RECOMP_REGS_OUT();
   8181 }
   8182 
   8183 void sub_3802DFD0(void) {
   8184     int _fpu_cmp = 0;
   8185     uint32_t _cf = 0;
   8186     int _df = 1;
   8187     uint32_t _flag_k = FK_NONE;
   8188     uint32_t _flag_a = 0, _flag_b = 0;
   8189     uint32_t _itail_tgt = 0;
   8190     RECOMP_REGS_LOCALS
   8191     RECOMP_ENTER(0x3802DFD0u);
   8192 
   8193 L_3802DFD0:
   8194     PUSH32(esp, ebp); /* 0x3802DFD0: push ebp */
   8195     ebp = esp; /* 0x3802DFD1: mov ebp, esp */
   8196     edx = MEM32(ebp + 0x8); /* 0x3802DFD3: mov edx, dword ptr [ebp + 8] */
   8197     PUSH32(esp, esi); /* 0x3802DFD6: push esi */
   8198     esi = MEM32(ebp + 0x10); /* 0x3802DFD7: mov esi, dword ptr [ebp + 0x10] */
   8199     /* cmp edx, esi */ /* 0x3802DFDA: cmp edx, esi */
   8200     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(esi);
   8201     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8202     _flag_k = FK_CMP;
   8203     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E01C; /* 0x3802DFDC: je 0x3802e01c */
   8204 L_3802DFDE:
   8205     eax = MEM32(esi); /* 0x3802DFDE: mov eax, dword ptr [esi] */
   8206     /* cmp edx, eax */ /* 0x3802DFE0: cmp edx, eax */
   8207     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   8208     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8209     _flag_k = FK_CMP;
   8210     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E01C; /* 0x3802DFE2: je 0x3802e01c */
   8211 L_3802DFE4:
   8212     MEM32(ebp + 0x8) = esi; /* 0x3802DFE4: mov dword ptr [ebp + 8], esi */
   8213     esi = MEM32(eax + 0x4); /* 0x3802DFE7: mov esi, dword ptr [eax + 4] */
   8214     MEM32(esi) = edx; /* 0x3802DFEA: mov dword ptr [esi], edx */
   8215     esi = MEM32(ebp + 0x8); /* 0x3802DFEC: mov esi, dword ptr [ebp + 8] */
   8216     esi = MEM32(esi + 0x4); /* 0x3802DFEF: mov esi, dword ptr [esi + 4] */
   8217     MEM32(esi) = eax; /* 0x3802DFF2: mov dword ptr [esi], eax */
   8218     esi = MEM32(edx + 0x4); /* 0x3802DFF4: mov esi, dword ptr [edx + 4] */
   8219     PUSH32(esp, edi); /* 0x3802DFF7: push edi */
   8220     edi = MEM32(ebp + 0x8); /* 0x3802DFF8: mov edi, dword ptr [ebp + 8] */
   8221     MEM32(esi) = edi; /* 0x3802DFFB: mov dword ptr [esi], edi */
   8222     esi = MEM32(edx + 0x4); /* 0x3802DFFD: mov esi, dword ptr [edx + 4] */
   8223     edi = MEM32(eax + 0x4); /* 0x3802E000: mov edi, dword ptr [eax + 4] */
   8224     MEM32(edx + 0x4) = edi; /* 0x3802E003: mov dword ptr [edx + 4], edi */
   8225     edx = MEM32(ebp + 0x8); /* 0x3802E006: mov edx, dword ptr [ebp + 8] */
   8226     edi = MEM32(edx + 0x4); /* 0x3802E009: mov edi, dword ptr [edx + 4] */
   8227     MEM32(eax + 0x4) = edi; /* 0x3802E00C: mov dword ptr [eax + 4], edi */
   8228     eax = MEM32(ebp + 0xC); /* 0x3802E00F: mov eax, dword ptr [ebp + 0xc] */
   8229     MEM32(edx + 0x4) = esi; /* 0x3802E012: mov dword ptr [edx + 4], esi */
   8230     _flag_a = (uint32_t)(MEM32(ecx + 0x8)); _flag_b = (uint32_t)(1);
   8231     MEM32(ecx + 0x8) = MEM32(ecx + 0x8) + 1; /* 0x3802E015: inc dword ptr [ecx + 8] */
   8232     _flag_k = FK_INC;
   8233     _flag_a = (uint32_t)(MEM32(eax + 0x8)); _flag_b = (uint32_t)(1);
   8234     MEM32(eax + 0x8) = MEM32(eax + 0x8) - 1; /* 0x3802E018: dec dword ptr [eax + 8] */
   8235     _flag_k = FK_DEC;
   8236     edi = POP32_VAL(esp); /* 0x3802E01B: pop edi */
   8237 L_3802E01C:
   8238     esi = POP32_VAL(esp); /* 0x3802E01C: pop esi */
   8239     ebp = POP32_VAL(esp); /* 0x3802E01D: pop ebp */
   8240     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802E01E: ret 0xc */
   8241     RECOMP_REGS_OUT();
   8242 }
   8243 
   8244 void sub_3802E030(void) {
   8245     int _fpu_cmp = 0;
   8246     uint32_t _cf = 0;
   8247     int _df = 1;
   8248     uint32_t _flag_k = FK_NONE;
   8249     uint32_t _flag_a = 0, _flag_b = 0;
   8250     uint32_t _itail_tgt = 0;
   8251     RECOMP_REGS_LOCALS
   8252     RECOMP_ENTER(0x3802E030u);
   8253 
   8254 L_3802E030:
   8255     PUSH32(esp, ebp); /* 0x3802E030: push ebp */
   8256     ebp = esp; /* 0x3802E031: mov ebp, esp */
   8257     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   8258     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8259     esp = esp - 8; /* 0x3802E033: sub esp, 8 */
   8260     _flag_k = FK_CMP;
   8261     edx = MEM32(ebp + 0x8); /* 0x3802E036: mov edx, dword ptr [ebp + 8] */
   8262     /* cmp edx, ecx */ /* 0x3802E039: cmp edx, ecx */
   8263     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   8264     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8265     _flag_k = FK_CMP;
   8266     MEM32(ebp + (-0x8)) = ecx; /* 0x3802E03B: mov dword ptr [ebp - 8], ecx */
   8267     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E0E9; /* 0x3802E03E: je 0x3802e0e9 */
   8268 L_3802E044:
   8269     PUSH32(esp, ebx); /* 0x3802E044: push ebx */
   8270     ebx = MEM32(edx + 0x4); /* 0x3802E045: mov ebx, dword ptr [edx + 4] */
   8271     PUSH32(esp, esi); /* 0x3802E048: push esi */
   8272     esi = MEM32(ebx); /* 0x3802E049: mov esi, dword ptr [ebx] */
   8273     PUSH32(esp, edi); /* 0x3802E04B: push edi */
   8274     edi = MEM32(ecx + 0x4); /* 0x3802E04C: mov edi, dword ptr [ecx + 4] */
   8275     eax = MEM32(edi); /* 0x3802E04F: mov eax, dword ptr [edi] */
   8276     /* cmp eax, edi */ /* 0x3802E051: cmp eax, edi */
   8277     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   8278     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8279     _flag_k = FK_CMP;
   8280     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E0A0; /* 0x3802E053: je 0x3802e0a0 */
   8281 L_3802E055:
   8282     /* cmp esi, ebx */ /* 0x3802E055: cmp esi, ebx */
   8283     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx);
   8284     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8285     _flag_k = FK_CMP;
   8286     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E0D1; /* 0x3802E057: je 0x3802e0d1 */
   8287 L_3802E059:
   8288     edx = MEM32(esi + 0x8); /* 0x3802E059: mov edx, dword ptr [esi + 8] */
   8289     /* cmp edx, MEM32(eax + 0x8) */ /* 0x3802E05C: cmp edx, dword ptr [eax + 8] */
   8290     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(eax + 0x8));
   8291     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8292     _flag_k = FK_CMP;
   8293     if (CMP_AE(_flag_a, _flag_b)) goto L_3802E09A; /* 0x3802E05F: jae 0x3802e09a */
   8294 L_3802E061:
   8295     edx = MEM32(esi); /* 0x3802E061: mov edx, dword ptr [esi] */
   8296     ecx = MEM32(edx + 0x4); /* 0x3802E063: mov ecx, dword ptr [edx + 4] */
   8297     MEM32(ebp + (-0x4)) = esi; /* 0x3802E066: mov dword ptr [ebp - 4], esi */
   8298     MEM32(ecx) = eax; /* 0x3802E069: mov dword ptr [ecx], eax */
   8299     ecx = MEM32(ebp + (-0x4)); /* 0x3802E06B: mov ecx, dword ptr [ebp - 4] */
   8300     ecx = MEM32(ecx + 0x4); /* 0x3802E06E: mov ecx, dword ptr [ecx + 4] */
   8301     MEM32(ecx) = edx; /* 0x3802E071: mov dword ptr [ecx], edx */
   8302     ecx = MEM32(eax + 0x4); /* 0x3802E073: mov ecx, dword ptr [eax + 4] */
   8303     esi = MEM32(ebp + (-0x4)); /* 0x3802E076: mov esi, dword ptr [ebp - 4] */
   8304     MEM32(ecx) = esi; /* 0x3802E079: mov dword ptr [ecx], esi */
   8305     esi = MEM32(edx + 0x4); /* 0x3802E07B: mov esi, dword ptr [edx + 4] */
   8306     ecx = MEM32(eax + 0x4); /* 0x3802E07E: mov ecx, dword ptr [eax + 4] */
   8307     MEM32(eax + 0x4) = esi; /* 0x3802E081: mov dword ptr [eax + 4], esi */
   8308     esi = MEM32(ebp + (-0x4)); /* 0x3802E084: mov esi, dword ptr [ebp - 4] */
   8309     esi = MEM32(esi + 0x4); /* 0x3802E087: mov esi, dword ptr [esi + 4] */
   8310     MEM32(edx + 0x4) = esi; /* 0x3802E08A: mov dword ptr [edx + 4], esi */
   8311     esi = MEM32(ebp + (-0x4)); /* 0x3802E08D: mov esi, dword ptr [ebp - 4] */
   8312     MEM32(esi + 0x4) = ecx; /* 0x3802E090: mov dword ptr [esi + 4], ecx */
   8313     ecx = MEM32(ebp + (-0x8)); /* 0x3802E093: mov ecx, dword ptr [ebp - 8] */
   8314     esi = edx; /* 0x3802E096: mov esi, edx */
   8315     goto L_3802E09C; /* 0x3802E098: jmp 0x3802e09c */
   8316 L_3802E09A:
   8317     eax = MEM32(eax); /* 0x3802E09A: mov eax, dword ptr [eax] */
   8318 L_3802E09C:
   8319     /* cmp eax, edi */ /* 0x3802E09C: cmp eax, edi */
   8320     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   8321     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8322     _flag_k = FK_CMP;
   8323     RECOMP_BACKEDGE();
   8324     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E055; /* 0x3802E09E: jne 0x3802e055 */
   8325 L_3802E0A0:
   8326     /* cmp esi, ebx */ /* 0x3802E0A0: cmp esi, ebx */
   8327     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx);
   8328     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8329     _flag_k = FK_CMP;
   8330     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E0D1; /* 0x3802E0A2: je 0x3802e0d1 */
   8331 L_3802E0A4:
   8332     edx = MEM32(ebx + 0x4); /* 0x3802E0A4: mov edx, dword ptr [ebx + 4] */
   8333     MEM32(ebp + (-0x4)) = esi; /* 0x3802E0A7: mov dword ptr [ebp - 4], esi */
   8334     MEM32(edx) = edi; /* 0x3802E0AA: mov dword ptr [edx], edi */
   8335     eax = MEM32(ebp + (-0x4)); /* 0x3802E0AC: mov eax, dword ptr [ebp - 4] */
   8336     edx = MEM32(eax + 0x4); /* 0x3802E0AF: mov edx, dword ptr [eax + 4] */
   8337     MEM32(edx) = ebx; /* 0x3802E0B2: mov dword ptr [edx], ebx */
   8338     eax = MEM32(edi + 0x4); /* 0x3802E0B4: mov eax, dword ptr [edi + 4] */
   8339     edx = MEM32(ebp + (-0x4)); /* 0x3802E0B7: mov edx, dword ptr [ebp - 4] */
   8340     MEM32(eax) = edx; /* 0x3802E0BA: mov dword ptr [eax], edx */
   8341     edx = MEM32(ebx + 0x4); /* 0x3802E0BC: mov edx, dword ptr [ebx + 4] */
   8342     eax = MEM32(edi + 0x4); /* 0x3802E0BF: mov eax, dword ptr [edi + 4] */
   8343     MEM32(edi + 0x4) = edx; /* 0x3802E0C2: mov dword ptr [edi + 4], edx */
   8344     edx = MEM32(ebp + (-0x4)); /* 0x3802E0C5: mov edx, dword ptr [ebp - 4] */
   8345     esi = MEM32(edx + 0x4); /* 0x3802E0C8: mov esi, dword ptr [edx + 4] */
   8346     MEM32(ebx + 0x4) = esi; /* 0x3802E0CB: mov dword ptr [ebx + 4], esi */
   8347     MEM32(edx + 0x4) = eax; /* 0x3802E0CE: mov dword ptr [edx + 4], eax */
   8348 L_3802E0D1:
   8349     eax = MEM32(ebp + 0x8); /* 0x3802E0D1: mov eax, dword ptr [ebp + 8] */
   8350     edx = MEM32(eax + 0x8); /* 0x3802E0D4: mov edx, dword ptr [eax + 8] */
   8351     esi = MEM32(ecx + 0x8); /* 0x3802E0D7: mov esi, dword ptr [ecx + 8] */
   8352     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
   8353     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8354     esi = esi + edx; /* 0x3802E0DA: add esi, edx */
   8355     _flag_k = FK_ADD;
   8356     edi = POP32_VAL(esp); /* 0x3802E0DC: pop edi */
   8357     MEM32(ecx + 0x8) = esi; /* 0x3802E0DD: mov dword ptr [ecx + 8], esi */
   8358     esi = POP32_VAL(esp); /* 0x3802E0E0: pop esi */
   8359     MEM32(eax + 0x8) = 0; /* 0x3802E0E1: mov dword ptr [eax + 8], 0 */
   8360     ebx = POP32_VAL(esp); /* 0x3802E0E8: pop ebx */
   8361 L_3802E0E9:
   8362     esp = ebp; /* 0x3802E0E9: mov esp, ebp */
   8363     ebp = POP32_VAL(esp); /* 0x3802E0EB: pop ebp */
   8364     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802E0EC: ret 4 */
   8365     RECOMP_REGS_OUT();
   8366 }
   8367 
   8368 void sub_3802E0F0(void) {
   8369     int _fpu_cmp = 0;
   8370     uint32_t _cf = 0;
   8371     int _df = 1;
   8372     uint32_t _flag_k = FK_NONE;
   8373     uint32_t _flag_a = 0, _flag_b = 0;
   8374     uint32_t _itail_tgt = 0;
   8375     RECOMP_REGS_LOCALS
   8376     RECOMP_ENTER(0x3802E0F0u);
   8377 
   8378 L_3802E0F0:
   8379     PUSH32(esp, ebp); /* 0x3802E0F0: push ebp */
   8380     ebp = esp; /* 0x3802E0F1: mov ebp, esp */
   8381     PUSH32(esp, 0xCu); /* 0x3802E0F3: push 0xc */
   8382     RECOMP_ICALL(0x3804B676u); /* 0x3802E0F5: call 0x3804b676 */ /* not lifted */
   8383     RECOMP_FLAGS_IN();
   8384     ecx = MEM32(ebp + 0x8); /* 0x3802E0FA: mov ecx, dword ptr [ebp + 8] */
   8385     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   8386     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8387     esp = esp + 4; /* 0x3802E0FD: add esp, 4 */
   8388     _flag_k = FK_ADD;
   8389     /* test ecx, ecx */ /* 0x3802E100: test ecx, ecx */
   8390     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   8391     _cf = 0;
   8392     _flag_k = FK_TEST;
   8393     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E106; /* 0x3802E102: jne 0x3802e106 */
   8394 L_3802E104:
   8395     ecx = eax; /* 0x3802E104: mov ecx, eax */
   8396 L_3802E106:
   8397     MEM32(eax) = ecx; /* 0x3802E106: mov dword ptr [eax], ecx */
   8398     ecx = MEM32(ebp + 0xC); /* 0x3802E108: mov ecx, dword ptr [ebp + 0xc] */
   8399     /* test ecx, ecx */ /* 0x3802E10B: test ecx, ecx */
   8400     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   8401     _cf = 0;
   8402     _flag_k = FK_TEST;
   8403     if (TEST_Z(_flag_a, _flag_b)) goto L_3802E116; /* 0x3802E10D: je 0x3802e116 */
   8404 L_3802E10F:
   8405     MEM32(eax + 0x4) = ecx; /* 0x3802E10F: mov dword ptr [eax + 4], ecx */
   8406     ebp = POP32_VAL(esp); /* 0x3802E112: pop ebp */
   8407     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E113: ret 8 */
   8408 L_3802E116:
   8409     MEM32(eax + 0x4) = eax; /* 0x3802E116: mov dword ptr [eax + 4], eax */
   8410     ebp = POP32_VAL(esp); /* 0x3802E119: pop ebp */
   8411     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E11A: ret 8 */
   8412     RECOMP_REGS_OUT();
   8413 }
   8414 
   8415 void sub_3802E120(void) {
   8416     int _fpu_cmp = 0;
   8417     uint32_t _cf = 0;
   8418     int _df = 1;
   8419     uint32_t _flag_k = FK_NONE;
   8420     uint32_t _flag_a = 0, _flag_b = 0;
   8421     uint32_t _itail_tgt = 0;
   8422     RECOMP_REGS_LOCALS
   8423     RECOMP_ENTER(0x3802E120u);
   8424 
   8425 L_3802E120:
   8426     PUSH32(esp, ebp); /* 0x3802E120: push ebp */
   8427     ebp = esp; /* 0x3802E121: mov ebp, esp */
   8428     PUSH32(esp, ebx); /* 0x3802E123: push ebx */
   8429     ebx = MEM32(ebp + 0x10); /* 0x3802E124: mov ebx, dword ptr [ebp + 0x10] */
   8430     PUSH32(esp, esi); /* 0x3802E127: push esi */
   8431     esi = ecx; /* 0x3802E128: mov esi, ecx */
   8432     eax = MEM32(esi + 0x10); /* 0x3802E12A: mov eax, dword ptr [esi + 0x10] */
   8433     /* test eax, eax */ /* 0x3802E12D: test eax, eax */
   8434     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   8435     _cf = 0;
   8436     _flag_k = FK_TEST;
   8437     ecx = MEM32(ebp + 0xC); /* 0x3802E12F: mov ecx, dword ptr [ebp + 0xc] */
   8438     PUSH32(esp, edi); /* 0x3802E132: push edi */
   8439     if (TEST_Z(_flag_a, _flag_b)) goto L_3802E19D; /* 0x3802E133: je 0x3802e19d */
   8440 L_3802E135:
   8441     eax = MEM32(esi + 0x4); /* 0x3802E135: mov eax, dword ptr [esi + 4] */
   8442     /* cmp ecx, MEM32(eax) */ /* 0x3802E138: cmp ecx, dword ptr [eax] */
   8443     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax));
   8444     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8445     _flag_k = FK_CMP;
   8446     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E19D; /* 0x3802E13A: jne 0x3802e19d */
   8447 L_3802E13C:
   8448     /* cmp ebx, eax */ /* 0x3802E13C: cmp ebx, eax */
   8449     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(eax);
   8450     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8451     _flag_k = FK_CMP;
   8452     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E19D; /* 0x3802E13E: jne 0x3802e19d */
   8453 L_3802E140:
   8454     ebx = MEM32(eax + 0x4); /* 0x3802E140: mov ebx, dword ptr [eax + 4] */
   8455     /* cmp ebx, MEM32(esi + 0x8) */ /* 0x3802E143: cmp ebx, dword ptr [esi + 8] */
   8456     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8457     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8458     _flag_k = FK_CMP;
   8459     edi = ebx; /* 0x3802E146: mov edi, ebx */
   8460     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E171; /* 0x3802E148: je 0x3802e171 */
   8461 L_3802E14A:
   8462     eax = MEM32(edi + 0x8); /* 0x3802E14A: mov eax, dword ptr [edi + 8] */
   8463     PUSH32(esp, eax); /* 0x3802E14D: push eax */
   8464     ecx = esi; /* 0x3802E14E: mov ecx, esi */
   8465     RECOMP_ICALL(0x3802EFF0u); /* 0x3802E150: call 0x3802eff0 */ /* not lifted */
   8466     RECOMP_FLAGS_IN();
   8467     edi = MEM32(edi); /* 0x3802E155: mov edi, dword ptr [edi] */
   8468     ecx = ebx + 0xC; /* 0x3802E157: lea ecx, [ebx + 0xc] */
   8469     RECOMP_ICALL(0x3802F610u); /* 0x3802E15A: call 0x3802f610 */ /* not lifted */
   8470     RECOMP_FLAGS_IN();
   8471     PUSH32(esp, ebx); /* 0x3802E15F: push ebx */
   8472     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E160: call 0x3804b4f6 */ /* not lifted */
   8473     RECOMP_FLAGS_IN();
   8474     eax = MEM32(esi + 0x8); /* 0x3802E165: mov eax, dword ptr [esi + 8] */
   8475     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   8476     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8477     esp = esp + 4; /* 0x3802E168: add esp, 4 */
   8478     _flag_k = FK_ADD;
   8479     /* cmp edi, eax */ /* 0x3802E16B: cmp edi, eax */
   8480     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   8481     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8482     _flag_k = FK_CMP;
   8483     ebx = edi; /* 0x3802E16D: mov ebx, edi */
   8484     RECOMP_BACKEDGE();
   8485     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E14A; /* 0x3802E16F: jne 0x3802e14a */
   8486 L_3802E171:
   8487     ecx = MEM32(esi + 0x4); /* 0x3802E171: mov ecx, dword ptr [esi + 4] */
   8488     edx = MEM32(esi + 0x8); /* 0x3802E174: mov edx, dword ptr [esi + 8] */
   8489     MEM32(ecx + 0x4) = edx; /* 0x3802E177: mov dword ptr [ecx + 4], edx */
   8490     eax = MEM32(esi + 0x4); /* 0x3802E17A: mov eax, dword ptr [esi + 4] */
   8491     MEM32(esi + 0x10) = 0; /* 0x3802E17D: mov dword ptr [esi + 0x10], 0 */
   8492     MEM32(eax) = eax; /* 0x3802E184: mov dword ptr [eax], eax */
   8493     eax = MEM32(esi + 0x4); /* 0x3802E186: mov eax, dword ptr [esi + 4] */
   8494     MEM32(eax + 0x8) = eax; /* 0x3802E189: mov dword ptr [eax + 8], eax */
   8495     eax = MEM32(esi + 0x4); /* 0x3802E18C: mov eax, dword ptr [esi + 4] */
   8496     ecx = MEM32(eax); /* 0x3802E18F: mov ecx, dword ptr [eax] */
   8497     eax = MEM32(ebp + 0x8); /* 0x3802E191: mov eax, dword ptr [ebp + 8] */
   8498     edi = POP32_VAL(esp); /* 0x3802E194: pop edi */
   8499     esi = POP32_VAL(esp); /* 0x3802E195: pop esi */
   8500     MEM32(eax) = ecx; /* 0x3802E196: mov dword ptr [eax], ecx */
   8501     ebx = POP32_VAL(esp); /* 0x3802E198: pop ebx */
   8502     ebp = POP32_VAL(esp); /* 0x3802E199: pop ebp */
   8503     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802E19A: ret 0xc */
   8504 L_3802E19D:
   8505     /* cmp ecx, ebx */ /* 0x3802E19D: cmp ecx, ebx */
   8506     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
   8507     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8508     _flag_k = FK_CMP;
   8509     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E1BE; /* 0x3802E19F: je 0x3802e1be */
   8510 L_3802E1A1:
   8511     edi = ecx; /* 0x3802E1A1: mov edi, ecx */
   8512     ecx = ebp + 0xC; /* 0x3802E1A3: lea ecx, [ebp + 0xc] */
   8513     RECOMP_ICALL(0x3802F2C0u); /* 0x3802E1A6: call 0x3802f2c0 */ /* not lifted */
   8514     RECOMP_FLAGS_IN();
   8515     PUSH32(esp, edi); /* 0x3802E1AB: push edi */
   8516     ecx = ebp + 0x10; /* 0x3802E1AC: lea ecx, [ebp + 0x10] */
   8517     PUSH32(esp, ecx); /* 0x3802E1AF: push ecx */
   8518     ecx = esi; /* 0x3802E1B0: mov ecx, esi */
   8519     RECOMP_ICALL(0x3802EB90u); /* 0x3802E1B2: call 0x3802eb90 */ /* not lifted */
   8520     RECOMP_FLAGS_IN();
   8521     ecx = MEM32(ebp + 0xC); /* 0x3802E1B7: mov ecx, dword ptr [ebp + 0xc] */
   8522     /* cmp ecx, ebx */ /* 0x3802E1BA: cmp ecx, ebx */
   8523     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
   8524     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8525     _flag_k = FK_CMP;
   8526     RECOMP_BACKEDGE();
   8527     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E1A1; /* 0x3802E1BC: jne 0x3802e1a1 */
   8528 L_3802E1BE:
   8529     eax = MEM32(ebp + 0x8); /* 0x3802E1BE: mov eax, dword ptr [ebp + 8] */
   8530     edi = POP32_VAL(esp); /* 0x3802E1C1: pop edi */
   8531     esi = POP32_VAL(esp); /* 0x3802E1C2: pop esi */
   8532     MEM32(eax) = ecx; /* 0x3802E1C3: mov dword ptr [eax], ecx */
   8533     ebx = POP32_VAL(esp); /* 0x3802E1C5: pop ebx */
   8534     ebp = POP32_VAL(esp); /* 0x3802E1C6: pop ebp */
   8535     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802E1C7: ret 0xc */
   8536     RECOMP_REGS_OUT();
   8537 }
   8538 
   8539 void sub_3802E1D0(void) {
   8540     int _fpu_cmp = 0;
   8541     uint32_t _cf = 0;
   8542     int _df = 1;
   8543     uint32_t _flag_k = FK_NONE;
   8544     uint32_t _flag_a = 0, _flag_b = 0;
   8545     uint32_t _itail_tgt = 0;
   8546     RECOMP_REGS_LOCALS
   8547     RECOMP_ENTER(0x3802E1D0u);
   8548 
   8549 L_3802E1D0:
   8550     PUSH32(esp, ebp); /* 0x3802E1D0: push ebp */
   8551     ebp = esp; /* 0x3802E1D1: mov ebp, esp */
   8552     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   8553     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8554     esp = esp - 0xCu; /* 0x3802E1D3: sub esp, 0xc */
   8555     _flag_k = FK_CMP;
   8556     PUSH32(esp, ebx); /* 0x3802E1D6: push ebx */
   8557     PUSH32(esp, esi); /* 0x3802E1D7: push esi */
   8558     esi = ecx; /* 0x3802E1D8: mov esi, ecx */
   8559     eax = MEM32(esi + 0x4); /* 0x3802E1DA: mov eax, dword ptr [esi + 4] */
   8560     ecx = MEM32(ebp + 0x8); /* 0x3802E1DD: mov ecx, dword ptr [ebp + 8] */
   8561     edx = MEM32(ecx + 0x4); /* 0x3802E1E0: mov edx, dword ptr [ecx + 4] */
   8562     ebx = MEM32(edx + 0x4); /* 0x3802E1E3: mov ebx, dword ptr [edx + 4] */
   8563     MEM32(ebp + (-0xC)) = eax; /* 0x3802E1E6: mov dword ptr [ebp - 0xc], eax */
   8564     eax = MEM32(esi + 0x8); /* 0x3802E1E9: mov eax, dword ptr [esi + 8] */
   8565     MEM32(ebp + (-0x8)) = eax; /* 0x3802E1EC: mov dword ptr [ebp - 8], eax */
   8566     SET_LO8(eax, MEM8(ebx + 0x5D)); /* 0x3802E1EF: mov al, byte ptr [ebx + 0x5d] */
   8567     /* test LO8(eax), LO8(eax) */ /* 0x3802E1F2: test al, al */
   8568     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   8569     _cf = 0;
   8570     _flag_k = FK_NARROW(FK_TEST, 24);
   8571     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E25B; /* 0x3802E1F4: jne 0x3802e25b */
   8572 L_3802E1F6:
   8573     SET_LO8(ecx, MEM8(ebx + 0x5C)); /* 0x3802E1F6: mov cl, byte ptr [ebx + 0x5c] */
   8574     PUSH32(esp, edi); /* 0x3802E1F9: push edi */
   8575     PUSH32(esp, 0x60u); /* 0x3802E1FA: push 0x60 */
   8576     MEM8(ebp + (-0x1)) = (uint8_t)(LO8(ecx)); /* 0x3802E1FC: mov byte ptr [ebp - 1], cl */
   8577     RECOMP_ICALL(0x3804B676u); /* 0x3802E1FF: call 0x3804b676 */ /* not lifted */
   8578     RECOMP_FLAGS_IN();
   8579     edx = MEM32(ebp + (-0xC)); /* 0x3802E204: mov edx, dword ptr [ebp - 0xc] */
   8580     edi = eax; /* 0x3802E207: mov edi, eax */
   8581     SET_LO8(eax, MEM8(ebp + (-0x1))); /* 0x3802E209: mov al, byte ptr [ebp - 1] */
   8582     ecx = ebx + 0xC; /* 0x3802E20C: lea ecx, [ebx + 0xc] */
   8583     MEM32(edi + 0x4) = edx; /* 0x3802E20F: mov dword ptr [edi + 4], edx */
   8584     PUSH32(esp, ecx); /* 0x3802E212: push ecx */
   8585     edx = edi + 0xC; /* 0x3802E213: lea edx, [edi + 0xc] */
   8586     PUSH32(esp, edx); /* 0x3802E216: push edx */
   8587     MEM8(edi + 0x5C) = (uint8_t)(LO8(eax)); /* 0x3802E217: mov byte ptr [edi + 0x5c], al */
   8588     MEM8(edi + 0x5D) = (uint8_t)(0); /* 0x3802E21A: mov byte ptr [edi + 0x5d], 0 */
   8589     RECOMP_ICALL(0x3802F3B0u); /* 0x3802E21E: call 0x3802f3b0 */ /* not lifted */
   8590     RECOMP_FLAGS_IN();
   8591     eax = MEM32(esi + 0x8); /* 0x3802E223: mov eax, dword ptr [esi + 8] */
   8592     edx = MEM32(ebp + (-0x8)); /* 0x3802E226: mov edx, dword ptr [ebp - 8] */
   8593     MEM32(edi) = eax; /* 0x3802E229: mov dword ptr [edi], eax */
   8594     ecx = MEM32(esi + 0x8); /* 0x3802E22B: mov ecx, dword ptr [esi + 8] */
   8595     MEM32(edi + 0x8) = ecx; /* 0x3802E22E: mov dword ptr [edi + 8], ecx */
   8596     eax = MEM32(esi + 0x8); /* 0x3802E231: mov eax, dword ptr [esi + 8] */
   8597     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   8598     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8599     esp = esp + 0xCu; /* 0x3802E234: add esp, 0xc */
   8600     _flag_k = FK_ADD;
   8601     /* cmp edx, eax */ /* 0x3802E237: cmp edx, eax */
   8602     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   8603     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8604     _flag_k = FK_CMP;
   8605     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E23E; /* 0x3802E239: jne 0x3802e23e */
   8606 L_3802E23B:
   8607     MEM32(ebp + (-0x8)) = edi; /* 0x3802E23B: mov dword ptr [ebp - 8], edi */
   8608 L_3802E23E:
   8609     eax = MEM32(ebx); /* 0x3802E23E: mov eax, dword ptr [ebx] */
   8610     PUSH32(esp, edi); /* 0x3802E240: push edi */
   8611     PUSH32(esp, eax); /* 0x3802E241: push eax */
   8612     ecx = esi; /* 0x3802E242: mov ecx, esi */
   8613     RECOMP_ICALL(0x3802EF60u); /* 0x3802E244: call 0x3802ef60 */ /* not lifted */
   8614     RECOMP_FLAGS_IN();
   8615     MEM32(edi) = eax; /* 0x3802E249: mov dword ptr [edi], eax */
   8616     ecx = MEM32(ebx + 0x8); /* 0x3802E24B: mov ecx, dword ptr [ebx + 8] */
   8617     PUSH32(esp, edi); /* 0x3802E24E: push edi */
   8618     PUSH32(esp, ecx); /* 0x3802E24F: push ecx */
   8619     ecx = esi; /* 0x3802E250: mov ecx, esi */
   8620     RECOMP_ICALL(0x3802EF60u); /* 0x3802E252: call 0x3802ef60 */ /* not lifted */
   8621     RECOMP_FLAGS_IN();
   8622     MEM32(edi + 0x8) = eax; /* 0x3802E257: mov dword ptr [edi + 8], eax */
   8623     edi = POP32_VAL(esp); /* 0x3802E25A: pop edi */
   8624 L_3802E25B:
   8625     edx = MEM32(esi + 0x4); /* 0x3802E25B: mov edx, dword ptr [esi + 4] */
   8626     eax = MEM32(ebp + (-0x8)); /* 0x3802E25E: mov eax, dword ptr [ebp - 8] */
   8627     ecx = MEM32(ebp + 0x8); /* 0x3802E261: mov ecx, dword ptr [ebp + 8] */
   8628     MEM32(edx + 0x4) = eax; /* 0x3802E264: mov dword ptr [edx + 4], eax */
   8629     edx = MEM32(ecx + 0x10); /* 0x3802E267: mov edx, dword ptr [ecx + 0x10] */
   8630     ecx = MEM32(esi + 0x8); /* 0x3802E26A: mov ecx, dword ptr [esi + 8] */
   8631     MEM32(esi + 0x10) = edx; /* 0x3802E26D: mov dword ptr [esi + 0x10], edx */
   8632     edx = MEM32(esi + 0x4); /* 0x3802E270: mov edx, dword ptr [esi + 4] */
   8633     eax = MEM32(edx + 0x4); /* 0x3802E273: mov eax, dword ptr [edx + 4] */
   8634     /* cmp eax, ecx */ /* 0x3802E276: cmp eax, ecx */
   8635     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   8636     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8637     _flag_k = FK_CMP;
   8638     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E2B7; /* 0x3802E278: je 0x3802e2b7 */
   8639 L_3802E27A:
   8640     ecx = MEM32(eax); /* 0x3802E27A: mov ecx, dword ptr [eax] */
   8641     SET_LO8(ebx, MEM8(ecx + 0x5D)); /* 0x3802E27C: mov bl, byte ptr [ecx + 0x5d] */
   8642     /* test LO8(ebx), LO8(ebx) */ /* 0x3802E27F: test bl, bl */
   8643     _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   8644     _cf = 0;
   8645     _flag_k = FK_NARROW(FK_TEST, 24);
   8646     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E28E; /* 0x3802E281: jne 0x3802e28e */
   8647 L_3802E283:
   8648     eax = ecx; /* 0x3802E283: mov eax, ecx */
   8649     ecx = MEM32(eax); /* 0x3802E285: mov ecx, dword ptr [eax] */
   8650     SET_LO8(ebx, MEM8(ecx + 0x5D)); /* 0x3802E287: mov bl, byte ptr [ecx + 0x5d] */
   8651     /* test LO8(ebx), LO8(ebx) */ /* 0x3802E28A: test bl, bl */
   8652     _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   8653     _cf = 0;
   8654     _flag_k = FK_NARROW(FK_TEST, 24);
   8655     RECOMP_BACKEDGE();
   8656     if (TEST_Z(_flag_a, _flag_b)) goto L_3802E283; /* 0x3802E28C: je 0x3802e283 */
   8657 L_3802E28E:
   8658     MEM32(edx) = eax; /* 0x3802E28E: mov dword ptr [edx], eax */
   8659     esi = MEM32(esi + 0x4); /* 0x3802E290: mov esi, dword ptr [esi + 4] */
   8660     ecx = MEM32(esi + 0x4); /* 0x3802E293: mov ecx, dword ptr [esi + 4] */
   8661     eax = MEM32(ecx + 0x8); /* 0x3802E296: mov eax, dword ptr [ecx + 8] */
   8662     SET_LO8(edx, MEM8(eax + 0x5D)); /* 0x3802E299: mov dl, byte ptr [eax + 0x5d] */
   8663     /* test LO8(edx), LO8(edx) */ /* 0x3802E29C: test dl, dl */
   8664     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   8665     _cf = 0;
   8666     _flag_k = FK_NARROW(FK_TEST, 24);
   8667     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E2AC; /* 0x3802E29E: jne 0x3802e2ac */
   8668 L_3802E2A0:
   8669     ecx = eax; /* 0x3802E2A0: mov ecx, eax */
   8670     eax = MEM32(ecx + 0x8); /* 0x3802E2A2: mov eax, dword ptr [ecx + 8] */
   8671     SET_LO8(edx, MEM8(eax + 0x5D)); /* 0x3802E2A5: mov dl, byte ptr [eax + 0x5d] */
   8672     /* test LO8(edx), LO8(edx) */ /* 0x3802E2A8: test dl, dl */
   8673     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   8674     _cf = 0;
   8675     _flag_k = FK_NARROW(FK_TEST, 24);
   8676     RECOMP_BACKEDGE();
   8677     if (TEST_Z(_flag_a, _flag_b)) goto L_3802E2A0; /* 0x3802E2AA: je 0x3802e2a0 */
   8678 L_3802E2AC:
   8679     MEM32(esi + 0x8) = ecx; /* 0x3802E2AC: mov dword ptr [esi + 8], ecx */
   8680     esi = POP32_VAL(esp); /* 0x3802E2AF: pop esi */
   8681     ebx = POP32_VAL(esp); /* 0x3802E2B0: pop ebx */
   8682     esp = ebp; /* 0x3802E2B1: mov esp, ebp */
   8683     ebp = POP32_VAL(esp); /* 0x3802E2B3: pop ebp */
   8684     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802E2B4: ret 4 */
   8685 L_3802E2B7:
   8686     MEM32(edx) = edx; /* 0x3802E2B7: mov dword ptr [edx], edx */
   8687     esi = MEM32(esi + 0x4); /* 0x3802E2B9: mov esi, dword ptr [esi + 4] */
   8688     MEM32(esi + 0x8) = esi; /* 0x3802E2BC: mov dword ptr [esi + 8], esi */
   8689     esi = POP32_VAL(esp); /* 0x3802E2BF: pop esi */
   8690     ebx = POP32_VAL(esp); /* 0x3802E2C0: pop ebx */
   8691     esp = ebp; /* 0x3802E2C1: mov esp, ebp */
   8692     ebp = POP32_VAL(esp); /* 0x3802E2C3: pop ebp */
   8693     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802E2C4: ret 4 */
   8694     RECOMP_REGS_OUT();
   8695 }
   8696 
   8697 void sub_3802E2D0(void) {
   8698     int _fpu_cmp = 0;
   8699     uint32_t _cf = 0;
   8700     int _df = 1;
   8701     uint32_t _flag_k = FK_NONE;
   8702     uint32_t _flag_a = 0, _flag_b = 0;
   8703     uint32_t _itail_tgt = 0;
   8704     RECOMP_REGS_LOCALS
   8705     RECOMP_ENTER(0x3802E2D0u);
   8706 
   8707 L_3802E2D0:
   8708     PUSH32(esp, ebp); /* 0x3802E2D0: push ebp */
   8709     ebp = esp; /* 0x3802E2D1: mov ebp, esp */
   8710     edx = MEM32(ecx + 0x4); /* 0x3802E2D3: mov edx, dword ptr [ecx + 4] */
   8711     ecx = MEM32(ecx + 0x8); /* 0x3802E2D6: mov ecx, dword ptr [ecx + 8] */
   8712     PUSH32(esp, ebx); /* 0x3802E2D9: push ebx */
   8713     PUSH32(esp, esi); /* 0x3802E2DA: push esi */
   8714     esi = MEM32(edx + 0x4); /* 0x3802E2DB: mov esi, dword ptr [edx + 4] */
   8715     eax = esi; /* 0x3802E2DE: mov eax, esi */
   8716     /* cmp eax, ecx */ /* 0x3802E2E0: cmp eax, ecx */
   8717     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   8718     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8719     _flag_k = FK_CMP;
   8720     PUSH32(esp, edi); /* 0x3802E2E2: push edi */
   8721     ebx = edx; /* 0x3802E2E3: mov ebx, edx */
   8722     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E2FE; /* 0x3802E2E5: je 0x3802e2fe */
   8723 L_3802E2E7:
   8724     edi = MEM32(ebp + 0xC); /* 0x3802E2E7: mov edi, dword ptr [ebp + 0xc] */
   8725     edi = MEM32(edi); /* 0x3802E2EA: mov edi, dword ptr [edi] */
   8726 L_3802E2EC:
   8727     /* cmp edi, MEM32(eax + 0xC) */ /* 0x3802E2EC: cmp edi, dword ptr [eax + 0xc] */
   8728     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(eax + 0xC));
   8729     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8730     _flag_k = FK_CMP;
   8731     if (CMP_AE(_flag_a, _flag_b)) goto L_3802E2F7; /* 0x3802E2EF: jae 0x3802e2f7 */
   8732 L_3802E2F1:
   8733     ebx = eax; /* 0x3802E2F1: mov ebx, eax */
   8734     eax = MEM32(eax); /* 0x3802E2F3: mov eax, dword ptr [eax] */
   8735     goto L_3802E2FA; /* 0x3802E2F5: jmp 0x3802e2fa */
   8736 L_3802E2F7:
   8737     eax = MEM32(eax + 0x8); /* 0x3802E2F7: mov eax, dword ptr [eax + 8] */
   8738 L_3802E2FA:
   8739     /* cmp eax, ecx */ /* 0x3802E2FA: cmp eax, ecx */
   8740     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   8741     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8742     _flag_k = FK_CMP;
   8743     RECOMP_BACKEDGE();
   8744     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E2EC; /* 0x3802E2FC: jne 0x3802e2ec */
   8745 L_3802E2FE:
   8746     eax = esi; /* 0x3802E2FE: mov eax, esi */
   8747     /* cmp eax, ecx */ /* 0x3802E300: cmp eax, ecx */
   8748     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   8749     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8750     _flag_k = FK_CMP;
   8751     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E31B; /* 0x3802E302: je 0x3802e31b */
   8752 L_3802E304:
   8753     esi = MEM32(ebp + 0xC); /* 0x3802E304: mov esi, dword ptr [ebp + 0xc] */
   8754     esi = MEM32(esi); /* 0x3802E307: mov esi, dword ptr [esi] */
   8755 L_3802E309:
   8756     /* cmp MEM32(eax + 0xC), esi */ /* 0x3802E309: cmp dword ptr [eax + 0xc], esi */
   8757     _flag_a = (uint32_t)(MEM32(eax + 0xC)); _flag_b = (uint32_t)(esi);
   8758     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8759     _flag_k = FK_CMP;
   8760     if (CMP_AE(_flag_a, _flag_b)) goto L_3802E313; /* 0x3802E30C: jae 0x3802e313 */
   8761 L_3802E30E:
   8762     eax = MEM32(eax + 0x8); /* 0x3802E30E: mov eax, dword ptr [eax + 8] */
   8763     goto L_3802E317; /* 0x3802E311: jmp 0x3802e317 */
   8764 L_3802E313:
   8765     edx = eax; /* 0x3802E313: mov edx, eax */
   8766     eax = MEM32(eax); /* 0x3802E315: mov eax, dword ptr [eax] */
   8767 L_3802E317:
   8768     /* cmp eax, ecx */ /* 0x3802E317: cmp eax, ecx */
   8769     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   8770     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8771     _flag_k = FK_CMP;
   8772     RECOMP_BACKEDGE();
   8773     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E309; /* 0x3802E319: jne 0x3802e309 */
   8774 L_3802E31B:
   8775     eax = MEM32(ebp + 0x8); /* 0x3802E31B: mov eax, dword ptr [ebp + 8] */
   8776     edi = POP32_VAL(esp); /* 0x3802E31E: pop edi */
   8777     MEM32(eax) = edx; /* 0x3802E31F: mov dword ptr [eax], edx */
   8778     esi = POP32_VAL(esp); /* 0x3802E321: pop esi */
   8779     MEM32(eax + 0x4) = ebx; /* 0x3802E322: mov dword ptr [eax + 4], ebx */
   8780     ebx = POP32_VAL(esp); /* 0x3802E325: pop ebx */
   8781     ebp = POP32_VAL(esp); /* 0x3802E326: pop ebp */
   8782     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E327: ret 8 */
   8783     RECOMP_REGS_OUT();
   8784 }
   8785 
   8786 void sub_3802E330(void) {
   8787     int _fpu_cmp = 0;
   8788     uint32_t _cf = 0;
   8789     int _df = 1;
   8790     uint32_t _flag_k = FK_NONE;
   8791     uint32_t _flag_a = 0, _flag_b = 0;
   8792     uint32_t _itail_tgt = 0;
   8793     RECOMP_REGS_LOCALS
   8794     RECOMP_ENTER(0x3802E330u);
   8795 
   8796 L_3802E330:
   8797     PUSH32(esp, ebp); /* 0x3802E330: push ebp */
   8798     ebp = esp; /* 0x3802E331: mov ebp, esp */
   8799     PUSH32(esp, ebx); /* 0x3802E333: push ebx */
   8800     PUSH32(esp, esi); /* 0x3802E334: push esi */
   8801     ebx = ecx; /* 0x3802E335: mov ebx, ecx */
   8802     eax = MEM32(ebx + 0x8); /* 0x3802E337: mov eax, dword ptr [ebx + 8] */
   8803     PUSH32(esp, edi); /* 0x3802E33A: push edi */
   8804     edi = MEM32(ebp + 0x8); /* 0x3802E33B: mov edi, dword ptr [ebp + 8] */
   8805     /* cmp edi, eax */ /* 0x3802E33E: cmp edi, eax */
   8806     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   8807     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8808     _flag_k = FK_CMP;
   8809     esi = edi; /* 0x3802E340: mov esi, edi */
   8810     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E363; /* 0x3802E342: je 0x3802e363 */
   8811 L_3802E344:
   8812     eax = MEM32(esi + 0x8); /* 0x3802E344: mov eax, dword ptr [esi + 8] */
   8813     PUSH32(esp, eax); /* 0x3802E347: push eax */
   8814     ecx = ebx; /* 0x3802E348: mov ecx, ebx */
   8815     RECOMP_ICALL(0x3802E330u); /* 0x3802E34A: call 0x3802e330 */ /* not lifted */
   8816     RECOMP_FLAGS_IN();
   8817     esi = MEM32(esi); /* 0x3802E34F: mov esi, dword ptr [esi] */
   8818     PUSH32(esp, edi); /* 0x3802E351: push edi */
   8819     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E352: call 0x3804b4f6 */ /* not lifted */
   8820     RECOMP_FLAGS_IN();
   8821     eax = MEM32(ebx + 0x8); /* 0x3802E357: mov eax, dword ptr [ebx + 8] */
   8822     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   8823     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8824     esp = esp + 4; /* 0x3802E35A: add esp, 4 */
   8825     _flag_k = FK_ADD;
   8826     /* cmp esi, eax */ /* 0x3802E35D: cmp esi, eax */
   8827     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   8828     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8829     _flag_k = FK_CMP;
   8830     edi = esi; /* 0x3802E35F: mov edi, esi */
   8831     RECOMP_BACKEDGE();
   8832     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E344; /* 0x3802E361: jne 0x3802e344 */
   8833 L_3802E363:
   8834     edi = POP32_VAL(esp); /* 0x3802E363: pop edi */
   8835     esi = POP32_VAL(esp); /* 0x3802E364: pop esi */
   8836     ebx = POP32_VAL(esp); /* 0x3802E365: pop ebx */
   8837     ebp = POP32_VAL(esp); /* 0x3802E366: pop ebp */
   8838     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802E367: ret 4 */
   8839     RECOMP_REGS_OUT();
   8840 }
   8841 
   8842 void sub_3802E370(void) {
   8843     int _fpu_cmp = 0;
   8844     uint32_t _cf = 0;
   8845     int _df = 1;
   8846     uint32_t _flag_k = FK_NONE;
   8847     uint32_t _flag_a = 0, _flag_b = 0;
   8848     uint32_t _itail_tgt = 0;
   8849     RECOMP_REGS_LOCALS
   8850     RECOMP_ENTER(0x3802E370u);
   8851 
   8852 L_3802E370:
   8853     PUSH32(esp, ebp); /* 0x3802E370: push ebp */
   8854     ebp = esp; /* 0x3802E371: mov ebp, esp */
   8855     PUSH32(esp, ecx); /* 0x3802E373: push ecx */
   8856     PUSH32(esp, ebx); /* 0x3802E374: push ebx */
   8857     PUSH32(esp, esi); /* 0x3802E375: push esi */
   8858     esi = MEM32(ebp + 0xC); /* 0x3802E376: mov esi, dword ptr [ebp + 0xc] */
   8859     PUSH32(esp, edi); /* 0x3802E379: push edi */
   8860     edi = ecx; /* 0x3802E37A: mov edi, ecx */
   8861     ecx = ebp + 0xC; /* 0x3802E37C: lea ecx, [ebp + 0xc] */
   8862     RECOMP_ICALL(0x3802F270u); /* 0x3802E37F: call 0x3802f270 */ /* not lifted */
   8863     RECOMP_FLAGS_IN();
   8864     edx = MEM32(esi); /* 0x3802E384: mov edx, dword ptr [esi] */
   8865     eax = MEM32(edi + 0x8); /* 0x3802E386: mov eax, dword ptr [edi + 8] */
   8866     /* cmp edx, eax */ /* 0x3802E389: cmp edx, eax */
   8867     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   8868     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8869     _flag_k = FK_CMP;
   8870     MEM32(ebp + (-0x4)) = esi; /* 0x3802E38B: mov dword ptr [ebp - 4], esi */
   8871     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E3B0; /* 0x3802E38E: jne 0x3802e3b0 */
   8872 L_3802E390:
   8873     eax = MEM32(esi + 0x8); /* 0x3802E390: mov eax, dword ptr [esi + 8] */
   8874 L_3802E393:
   8875     ecx = MEM32(ebp + (-0x4)); /* 0x3802E393: mov ecx, dword ptr [ebp - 4] */
   8876     edx = MEM32(ecx + 0x4); /* 0x3802E396: mov edx, dword ptr [ecx + 4] */
   8877     MEM32(eax + 0x4) = edx; /* 0x3802E399: mov dword ptr [eax + 4], edx */
   8878     ecx = MEM32(edi + 0x4); /* 0x3802E39C: mov ecx, dword ptr [edi + 4] */
   8879     /* cmp MEM32(ecx + 0x4), esi */ /* 0x3802E39F: cmp dword ptr [ecx + 4], esi */
   8880     _flag_a = (uint32_t)(MEM32(ecx + 0x4)); _flag_b = (uint32_t)(esi);
   8881     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8882     _flag_k = FK_CMP;
   8883     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E433; /* 0x3802E3A2: jne 0x3802e433 */
   8884 L_3802E3A8:
   8885     MEM32(ecx + 0x4) = eax; /* 0x3802E3A8: mov dword ptr [ecx + 4], eax */
   8886     goto L_3802E441; /* 0x3802E3AB: jmp 0x3802e441 */
   8887 L_3802E3B0:
   8888     ecx = MEM32(esi + 0x8); /* 0x3802E3B0: mov ecx, dword ptr [esi + 8] */
   8889     /* cmp ecx, eax */ /* 0x3802E3B3: cmp ecx, eax */
   8890     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
   8891     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8892     _flag_k = FK_CMP;
   8893     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E3BB; /* 0x3802E3B5: jne 0x3802e3bb */
   8894 L_3802E3B7:
   8895     eax = edx; /* 0x3802E3B7: mov eax, edx */
   8896     RECOMP_BACKEDGE();
   8897     goto L_3802E393; /* 0x3802E3B9: jmp 0x3802e393 */
   8898 L_3802E3BB:
   8899     eax = MEM32(ecx); /* 0x3802E3BB: mov eax, dword ptr [ecx] */
   8900     SET_LO8(ebx, MEM8(eax + 0x25)); /* 0x3802E3BD: mov bl, byte ptr [eax + 0x25] */
   8901     /* test LO8(ebx), LO8(ebx) */ /* 0x3802E3C0: test bl, bl */
   8902     _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   8903     _cf = 0;
   8904     _flag_k = FK_NARROW(FK_TEST, 24);
   8905     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E3CF; /* 0x3802E3C2: jne 0x3802e3cf */
   8906 L_3802E3C4:
   8907     ecx = eax; /* 0x3802E3C4: mov ecx, eax */
   8908     eax = MEM32(ecx); /* 0x3802E3C6: mov eax, dword ptr [ecx] */
   8909     SET_LO8(ebx, MEM8(eax + 0x25)); /* 0x3802E3C8: mov bl, byte ptr [eax + 0x25] */
   8910     /* test LO8(ebx), LO8(ebx) */ /* 0x3802E3CB: test bl, bl */
   8911     _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   8912     _cf = 0;
   8913     _flag_k = FK_NARROW(FK_TEST, 24);
   8914     RECOMP_BACKEDGE();
   8915     if (TEST_Z(_flag_a, _flag_b)) goto L_3802E3C4; /* 0x3802E3CD: je 0x3802e3c4 */
   8916 L_3802E3CF:
   8917     /* cmp ecx, esi */ /* 0x3802E3CF: cmp ecx, esi */
   8918     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(esi);
   8919     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8920     _flag_k = FK_CMP;
   8921     eax = MEM32(ecx + 0x8); /* 0x3802E3D1: mov eax, dword ptr [ecx + 8] */
   8922     MEM32(ebp + (-0x4)) = ecx; /* 0x3802E3D4: mov dword ptr [ebp - 4], ecx */
   8923     RECOMP_BACKEDGE();
   8924     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E393; /* 0x3802E3D7: je 0x3802e393 */
   8925 L_3802E3D9:
   8926     MEM32(edx + 0x4) = ecx; /* 0x3802E3D9: mov dword ptr [edx + 4], ecx */
   8927     edx = MEM32(esi); /* 0x3802E3DC: mov edx, dword ptr [esi] */
   8928     MEM32(ecx) = edx; /* 0x3802E3DE: mov dword ptr [ecx], edx */
   8929     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E3E0: cmp ecx, dword ptr [esi + 8] */
   8930     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8931     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8932     _flag_k = FK_CMP;
   8933     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E3EA; /* 0x3802E3E3: jne 0x3802e3ea */
   8934 L_3802E3E5:
   8935     MEM32(eax + 0x4) = ecx; /* 0x3802E3E5: mov dword ptr [eax + 4], ecx */
   8936     goto L_3802E401; /* 0x3802E3E8: jmp 0x3802e401 */
   8937 L_3802E3EA:
   8938     edx = MEM32(ecx + 0x4); /* 0x3802E3EA: mov edx, dword ptr [ecx + 4] */
   8939     MEM32(eax + 0x4) = edx; /* 0x3802E3ED: mov dword ptr [eax + 4], edx */
   8940     edx = MEM32(ecx + 0x4); /* 0x3802E3F0: mov edx, dword ptr [ecx + 4] */
   8941     MEM32(edx) = eax; /* 0x3802E3F3: mov dword ptr [edx], eax */
   8942     edx = MEM32(esi + 0x8); /* 0x3802E3F5: mov edx, dword ptr [esi + 8] */
   8943     MEM32(ecx + 0x8) = edx; /* 0x3802E3F8: mov dword ptr [ecx + 8], edx */
   8944     edx = MEM32(esi + 0x8); /* 0x3802E3FB: mov edx, dword ptr [esi + 8] */
   8945     MEM32(edx + 0x4) = ecx; /* 0x3802E3FE: mov dword ptr [edx + 4], ecx */
   8946 L_3802E401:
   8947     edx = MEM32(edi + 0x4); /* 0x3802E401: mov edx, dword ptr [edi + 4] */
   8948     /* cmp MEM32(edx + 0x4), esi */ /* 0x3802E404: cmp dword ptr [edx + 4], esi */
   8949     _flag_a = (uint32_t)(MEM32(edx + 0x4)); _flag_b = (uint32_t)(esi);
   8950     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8951     _flag_k = FK_CMP;
   8952     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E40E; /* 0x3802E407: jne 0x3802e40e */
   8953 L_3802E409:
   8954     MEM32(edx + 0x4) = ecx; /* 0x3802E409: mov dword ptr [edx + 4], ecx */
   8955     goto L_3802E41C; /* 0x3802E40C: jmp 0x3802e41c */
   8956 L_3802E40E:
   8957     edx = MEM32(esi + 0x4); /* 0x3802E40E: mov edx, dword ptr [esi + 4] */
   8958     /* cmp MEM32(edx), esi */ /* 0x3802E411: cmp dword ptr [edx], esi */
   8959     _flag_a = (uint32_t)(MEM32(edx)); _flag_b = (uint32_t)(esi);
   8960     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8961     _flag_k = FK_CMP;
   8962     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E419; /* 0x3802E413: jne 0x3802e419 */
   8963 L_3802E415:
   8964     MEM32(edx) = ecx; /* 0x3802E415: mov dword ptr [edx], ecx */
   8965     goto L_3802E41C; /* 0x3802E417: jmp 0x3802e41c */
   8966 L_3802E419:
   8967     MEM32(edx + 0x8) = ecx; /* 0x3802E419: mov dword ptr [edx + 8], ecx */
   8968 L_3802E41C:
   8969     edx = MEM32(esi + 0x4); /* 0x3802E41C: mov edx, dword ptr [esi + 4] */
   8970     MEM32(ecx + 0x4) = edx; /* 0x3802E41F: mov dword ptr [ecx + 4], edx */
   8971     SET_LO8(ebx, MEM8(esi + 0x24)); /* 0x3802E422: mov bl, byte ptr [esi + 0x24] */
   8972     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E425: mov dl, byte ptr [ecx + 0x24] */
   8973     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E428: mov byte ptr [ecx + 0x24], bl */
   8974     MEM8(esi + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E42B: mov byte ptr [esi + 0x24], dl */
   8975     MEM32(ebp + (-0x4)) = esi; /* 0x3802E42E: mov dword ptr [ebp - 4], esi */
   8976     goto L_3802E498; /* 0x3802E431: jmp 0x3802e498 */
   8977 L_3802E433:
   8978     ecx = MEM32(esi + 0x4); /* 0x3802E433: mov ecx, dword ptr [esi + 4] */
   8979     /* cmp MEM32(ecx), esi */ /* 0x3802E436: cmp dword ptr [ecx], esi */
   8980     _flag_a = (uint32_t)(MEM32(ecx)); _flag_b = (uint32_t)(esi);
   8981     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8982     _flag_k = FK_CMP;
   8983     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E43E; /* 0x3802E438: jne 0x3802e43e */
   8984 L_3802E43A:
   8985     MEM32(ecx) = eax; /* 0x3802E43A: mov dword ptr [ecx], eax */
   8986     goto L_3802E441; /* 0x3802E43C: jmp 0x3802e441 */
   8987 L_3802E43E:
   8988     MEM32(ecx + 0x8) = eax; /* 0x3802E43E: mov dword ptr [ecx + 8], eax */
   8989 L_3802E441:
   8990     ebx = MEM32(edi + 0x4); /* 0x3802E441: mov ebx, dword ptr [edi + 4] */
   8991     /* cmp MEM32(ebx), esi */ /* 0x3802E444: cmp dword ptr [ebx], esi */
   8992     _flag_a = (uint32_t)(MEM32(ebx)); _flag_b = (uint32_t)(esi);
   8993     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8994     _flag_k = FK_CMP;
   8995     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E46B; /* 0x3802E446: jne 0x3802e46b */
   8996 L_3802E448:
   8997     ecx = MEM32(esi + 0x8); /* 0x3802E448: mov ecx, dword ptr [esi + 8] */
   8998     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3802E44B: cmp ecx, dword ptr [edi + 8] */
   8999     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9000     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9001     _flag_k = FK_CMP;
   9002     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E455; /* 0x3802E44E: jne 0x3802e455 */
   9003 L_3802E450:
   9004     edx = MEM32(esi + 0x4); /* 0x3802E450: mov edx, dword ptr [esi + 4] */
   9005     goto L_3802E469; /* 0x3802E453: jmp 0x3802e469 */
   9006 L_3802E455:
   9007     ecx = MEM32(eax); /* 0x3802E455: mov ecx, dword ptr [eax] */
   9008     /* cmp MEM8(ecx + 0x25), 0 */ /* 0x3802E457: cmp byte ptr [ecx + 0x25], 0 */
   9009     _flag_a = (uint32_t)(MEM8(ecx + 0x25)) << 24; _flag_b = (uint32_t)(0) << 24;
   9010     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9011     _flag_k = FK_NARROW(FK_CMP, 24);
   9012     edx = eax; /* 0x3802E45B: mov edx, eax */
   9013     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E469; /* 0x3802E45D: jne 0x3802e469 */
   9014 L_3802E45F:
   9015     edx = ecx; /* 0x3802E45F: mov edx, ecx */
   9016     ecx = MEM32(edx); /* 0x3802E461: mov ecx, dword ptr [edx] */
   9017     /* cmp MEM8(ecx + 0x25), 0 */ /* 0x3802E463: cmp byte ptr [ecx + 0x25], 0 */
   9018     _flag_a = (uint32_t)(MEM8(ecx + 0x25)) << 24; _flag_b = (uint32_t)(0) << 24;
   9019     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9020     _flag_k = FK_NARROW(FK_CMP, 24);
   9021     RECOMP_BACKEDGE();
   9022     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E45F; /* 0x3802E467: je 0x3802e45f */
   9023 L_3802E469:
   9024     MEM32(ebx) = edx; /* 0x3802E469: mov dword ptr [ebx], edx */
   9025 L_3802E46B:
   9026     ebx = MEM32(edi + 0x4); /* 0x3802E46B: mov ebx, dword ptr [edi + 4] */
   9027     /* cmp MEM32(ebx + 0x8), esi */ /* 0x3802E46E: cmp dword ptr [ebx + 8], esi */
   9028     _flag_a = (uint32_t)(MEM32(ebx + 0x8)); _flag_b = (uint32_t)(esi);
   9029     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9030     _flag_k = FK_CMP;
   9031     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E498; /* 0x3802E471: jne 0x3802e498 */
   9032 L_3802E473:
   9033     ecx = MEM32(esi); /* 0x3802E473: mov ecx, dword ptr [esi] */
   9034     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3802E475: cmp ecx, dword ptr [edi + 8] */
   9035     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9036     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9037     _flag_k = FK_CMP;
   9038     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E47F; /* 0x3802E478: jne 0x3802e47f */
   9039 L_3802E47A:
   9040     edx = MEM32(esi + 0x4); /* 0x3802E47A: mov edx, dword ptr [esi + 4] */
   9041     goto L_3802E495; /* 0x3802E47D: jmp 0x3802e495 */
   9042 L_3802E47F:
   9043     ecx = MEM32(eax + 0x8); /* 0x3802E47F: mov ecx, dword ptr [eax + 8] */
   9044     /* cmp MEM8(ecx + 0x25), 0 */ /* 0x3802E482: cmp byte ptr [ecx + 0x25], 0 */
   9045     _flag_a = (uint32_t)(MEM8(ecx + 0x25)) << 24; _flag_b = (uint32_t)(0) << 24;
   9046     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9047     _flag_k = FK_NARROW(FK_CMP, 24);
   9048     edx = eax; /* 0x3802E486: mov edx, eax */
   9049     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E495; /* 0x3802E488: jne 0x3802e495 */
   9050 L_3802E48A:
   9051     edx = ecx; /* 0x3802E48A: mov edx, ecx */
   9052     ecx = MEM32(edx + 0x8); /* 0x3802E48C: mov ecx, dword ptr [edx + 8] */
   9053     /* cmp MEM8(ecx + 0x25), 0 */ /* 0x3802E48F: cmp byte ptr [ecx + 0x25], 0 */
   9054     _flag_a = (uint32_t)(MEM8(ecx + 0x25)) << 24; _flag_b = (uint32_t)(0) << 24;
   9055     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9056     _flag_k = FK_NARROW(FK_CMP, 24);
   9057     RECOMP_BACKEDGE();
   9058     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E48A; /* 0x3802E493: je 0x3802e48a */
   9059 L_3802E495:
   9060     MEM32(ebx + 0x8) = edx; /* 0x3802E495: mov dword ptr [ebx + 8], edx */
   9061 L_3802E498:
   9062     esi = MEM32(ebp + (-0x4)); /* 0x3802E498: mov esi, dword ptr [ebp - 4] */
   9063     SET_LO8(ecx, MEM8(esi + 0x24)); /* 0x3802E49B: mov cl, byte ptr [esi + 0x24] */
   9064     SET_LO8(ebx, 1); /* 0x3802E49E: mov bl, 1 */
   9065     /* cmp LO8(ecx), LO8(ebx) */ /* 0x3802E4A0: cmp cl, bl */
   9066     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9067     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9068     _flag_k = FK_NARROW(FK_CMP, 24);
   9069     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E708; /* 0x3802E4A2: jne 0x3802e708 */
   9070 L_3802E4A8:
   9071     ecx = MEM32(edi + 0x4); /* 0x3802E4A8: mov ecx, dword ptr [edi + 4] */
   9072     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E4AB: cmp eax, dword ptr [ecx + 4] */
   9073     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   9074     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9075     _flag_k = FK_CMP;
   9076     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4AE: je 0x3802e702 */
   9077 L_3802E4B4:
   9078     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
   9079     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9080     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9081     _flag_k = FK_NARROW(FK_CMP, 24);
   9082     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
   9083 L_3802E4BD:
   9084     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
   9085     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
   9086     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
   9087     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   9088     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9089     _flag_k = FK_CMP;
   9090     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
   9091 L_3802E4C6:
   9092     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
   9093     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
   9094     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
   9095     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   9096     _cf = 0;
   9097     _flag_k = FK_NARROW(FK_TEST, 24);
   9098     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
   9099 L_3802E4D0:
   9100     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
   9101     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
   9102     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
   9103     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
   9104     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
   9105     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
   9106     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
   9107     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
   9108     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
   9109     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9110     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9111     _flag_k = FK_CMP;
   9112     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
   9113 L_3802E4EC:
   9114     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
   9115 L_3802E4EF:
   9116     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
   9117     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
   9118     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
   9119     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
   9120     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9121     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9122     _flag_k = FK_CMP;
   9123     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
   9124 L_3802E4FD:
   9125     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
   9126     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
   9127 L_3802E502:
   9128     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
   9129     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
   9130     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   9131     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9132     _flag_k = FK_CMP;
   9133     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
   9134 L_3802E509:
   9135     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
   9136     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
   9137 L_3802E50D:
   9138     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
   9139 L_3802E510:
   9140     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
   9141     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
   9142     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
   9143     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
   9144 L_3802E51B:
   9145     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
   9146     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
   9147     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9148     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9149     _flag_k = FK_NARROW(FK_CMP, 24);
   9150     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
   9151 L_3802E526:
   9152     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
   9153     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
   9154     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9155     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9156     _flag_k = FK_NARROW(FK_CMP, 24);
   9157     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
   9158 L_3802E532:
   9159     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
   9160 L_3802E534:
   9161     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
   9162     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
   9163     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   9164     _cf = 0;
   9165     _flag_k = FK_NARROW(FK_TEST, 24);
   9166     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
   9167 L_3802E53B:
   9168     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
   9169     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
   9170     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
   9171     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
   9172     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
   9173     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
   9174     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
   9175     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
   9176     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
   9177     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9178     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9179     _flag_k = FK_CMP;
   9180     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
   9181 L_3802E557:
   9182     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
   9183 L_3802E55A:
   9184     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
   9185     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
   9186     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
   9187     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
   9188     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9189     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9190     _flag_k = FK_CMP;
   9191     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
   9192 L_3802E568:
   9193     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
   9194     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
   9195 L_3802E56D:
   9196     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
   9197     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
   9198     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9199     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9200     _flag_k = FK_CMP;
   9201     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
   9202 L_3802E575:
   9203     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
   9204     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
   9205 L_3802E57A:
   9206     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
   9207 L_3802E57C:
   9208     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
   9209     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
   9210     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
   9211     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
   9212 L_3802E587:
   9213     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
   9214     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
   9215     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9216     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9217     _flag_k = FK_NARROW(FK_CMP, 24);
   9218     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
   9219 L_3802E593:
   9220     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
   9221     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
   9222     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9223     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9224     _flag_k = FK_NARROW(FK_CMP, 24);
   9225     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
   9226 L_3802E59E:
   9227     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
   9228     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
   9229     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
   9230     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
   9231     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   9232     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9233     _flag_k = FK_CMP;
   9234     RECOMP_BACKEDGE();
   9235     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
   9236 L_3802E5B1:
   9237     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
   9238 L_3802E5B6:
   9239     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
   9240     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
   9241     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9242     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9243     _flag_k = FK_NARROW(FK_CMP, 24);
   9244     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
   9245 L_3802E5BE:
   9246     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
   9247     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
   9248     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
   9249     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
   9250     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
   9251     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
   9252     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
   9253     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
   9254     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9255     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9256     _flag_k = FK_CMP;
   9257     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
   9258 L_3802E5D6:
   9259     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
   9260 L_3802E5D9:
   9261     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
   9262     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
   9263     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
   9264     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
   9265     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9266     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9267     _flag_k = FK_CMP;
   9268     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
   9269 L_3802E5E7:
   9270     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
   9271     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
   9272 L_3802E5EC:
   9273     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
   9274     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
   9275     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9276     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9277     _flag_k = FK_CMP;
   9278     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
   9279 L_3802E5F4:
   9280     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
   9281     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
   9282 L_3802E5F9:
   9283     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
   9284 L_3802E5FB:
   9285     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
   9286     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
   9287     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
   9288     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
   9289 L_3802E607:
   9290     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
   9291     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
   9292     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
   9293     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
   9294     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
   9295     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
   9296     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
   9297     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
   9298     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
   9299     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
   9300     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
   9301     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
   9302     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
   9303     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9304     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9305     _flag_k = FK_CMP;
   9306     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
   9307 L_3802E62E:
   9308     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
   9309 L_3802E631:
   9310     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
   9311     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
   9312     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
   9313     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
   9314     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9315     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9316     _flag_k = FK_CMP;
   9317     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
   9318 L_3802E63F:
   9319     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
   9320     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
   9321     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
   9322 L_3802E649:
   9323     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
   9324     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
   9325     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   9326     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9327     _flag_k = FK_CMP;
   9328     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
   9329 L_3802E650:
   9330     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
   9331     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
   9332     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
   9333 L_3802E659:
   9334     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
   9335     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
   9336     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
   9337 L_3802E663:
   9338     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
   9339     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
   9340     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9341     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9342     _flag_k = FK_NARROW(FK_CMP, 24);
   9343     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
   9344 L_3802E66A:
   9345     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
   9346     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
   9347     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
   9348     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
   9349     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
   9350     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
   9351     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
   9352     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
   9353     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9354     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9355     _flag_k = FK_CMP;
   9356     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
   9357 L_3802E683:
   9358     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
   9359 L_3802E686:
   9360     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
   9361     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
   9362     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
   9363     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
   9364     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9365     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9366     _flag_k = FK_CMP;
   9367     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
   9368 L_3802E694:
   9369     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
   9370     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
   9371 L_3802E699:
   9372     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
   9373     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
   9374     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   9375     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9376     _flag_k = FK_CMP;
   9377     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
   9378 L_3802E6A0:
   9379     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
   9380     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
   9381 L_3802E6A4:
   9382     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
   9383 L_3802E6A7:
   9384     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
   9385     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
   9386     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
   9387     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
   9388 L_3802E6B1:
   9389     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
   9390     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
   9391     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
   9392     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
   9393     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
   9394     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
   9395     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
   9396     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
   9397     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
   9398     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
   9399     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
   9400     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
   9401     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
   9402     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9403     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9404     _flag_k = FK_CMP;
   9405     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
   9406 L_3802E6D7:
   9407     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
   9408 L_3802E6DA:
   9409     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
   9410     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
   9411     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
   9412     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
   9413     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9414     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9415     _flag_k = FK_CMP;
   9416     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
   9417 L_3802E6E8:
   9418     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
   9419     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
   9420 L_3802E6ED:
   9421     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
   9422     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
   9423     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9424     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9425     _flag_k = FK_CMP;
   9426     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
   9427 L_3802E6F5:
   9428     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
   9429     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
   9430 L_3802E6FA:
   9431     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
   9432 L_3802E6FC:
   9433     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
   9434 L_3802E6FF:
   9435     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
   9436 L_3802E702:
   9437     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
   9438     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
   9439 L_3802E708:
   9440     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
   9441     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
   9442     RECOMP_FLAGS_IN();
   9443     PUSH32(esp, esi); /* 0x3802E710: push esi */
   9444     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
   9445     RECOMP_FLAGS_IN();
   9446     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
   9447     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
   9448     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   9449     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   9450     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
   9451     _flag_k = FK_ADD;
   9452     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   9453     eax = eax - 1; /* 0x3802E71F: dec eax */
   9454     _flag_k = FK_DEC;
   9455     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
   9456     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
   9457     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
   9458     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
   9459     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
   9460     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
   9461     esp = ebp; /* 0x3802E72B: mov esp, ebp */
   9462     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
   9463     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
   9464     RECOMP_REGS_OUT();
   9465 }
   9466 
   9467 void sub_3802E441(void) {
   9468     int _fpu_cmp = 0;
   9469     uint32_t _cf = 0;
   9470     int _df = 1;
   9471     uint32_t _flag_k = FK_NONE;
   9472     uint32_t _flag_a = 0, _flag_b = 0;
   9473     uint32_t _itail_tgt = 0;
   9474     RECOMP_REGS_LOCALS
   9475     RECOMP_ENTER(0x3802E441u);
   9476 
   9477 L_3802E441:
   9478     ebx = MEM32(edi + 0x4); /* 0x3802E441: mov ebx, dword ptr [edi + 4] */
   9479     /* cmp MEM32(ebx), esi */ /* 0x3802E444: cmp dword ptr [ebx], esi */
   9480     _flag_a = (uint32_t)(MEM32(ebx)); _flag_b = (uint32_t)(esi);
   9481     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9482     _flag_k = FK_CMP;
   9483     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E46B; /* 0x3802E446: jne 0x3802e46b */
   9484 L_3802E448:
   9485     ecx = MEM32(esi + 0x8); /* 0x3802E448: mov ecx, dword ptr [esi + 8] */
   9486     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3802E44B: cmp ecx, dword ptr [edi + 8] */
   9487     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9488     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9489     _flag_k = FK_CMP;
   9490     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E455; /* 0x3802E44E: jne 0x3802e455 */
   9491 L_3802E450:
   9492     edx = MEM32(esi + 0x4); /* 0x3802E450: mov edx, dword ptr [esi + 4] */
   9493     goto L_3802E469; /* 0x3802E453: jmp 0x3802e469 */
   9494 L_3802E455:
   9495     ecx = MEM32(eax); /* 0x3802E455: mov ecx, dword ptr [eax] */
   9496     /* cmp MEM8(ecx + 0x25), 0 */ /* 0x3802E457: cmp byte ptr [ecx + 0x25], 0 */
   9497     _flag_a = (uint32_t)(MEM8(ecx + 0x25)) << 24; _flag_b = (uint32_t)(0) << 24;
   9498     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9499     _flag_k = FK_NARROW(FK_CMP, 24);
   9500     edx = eax; /* 0x3802E45B: mov edx, eax */
   9501     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E469; /* 0x3802E45D: jne 0x3802e469 */
   9502 L_3802E45F:
   9503     edx = ecx; /* 0x3802E45F: mov edx, ecx */
   9504     ecx = MEM32(edx); /* 0x3802E461: mov ecx, dword ptr [edx] */
   9505     /* cmp MEM8(ecx + 0x25), 0 */ /* 0x3802E463: cmp byte ptr [ecx + 0x25], 0 */
   9506     _flag_a = (uint32_t)(MEM8(ecx + 0x25)) << 24; _flag_b = (uint32_t)(0) << 24;
   9507     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9508     _flag_k = FK_NARROW(FK_CMP, 24);
   9509     RECOMP_BACKEDGE();
   9510     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E45F; /* 0x3802E467: je 0x3802e45f */
   9511 L_3802E469:
   9512     MEM32(ebx) = edx; /* 0x3802E469: mov dword ptr [ebx], edx */
   9513 L_3802E46B:
   9514     ebx = MEM32(edi + 0x4); /* 0x3802E46B: mov ebx, dword ptr [edi + 4] */
   9515     /* cmp MEM32(ebx + 0x8), esi */ /* 0x3802E46E: cmp dword ptr [ebx + 8], esi */
   9516     _flag_a = (uint32_t)(MEM32(ebx + 0x8)); _flag_b = (uint32_t)(esi);
   9517     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9518     _flag_k = FK_CMP;
   9519     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E498; /* 0x3802E471: jne 0x3802e498 */
   9520 L_3802E473:
   9521     ecx = MEM32(esi); /* 0x3802E473: mov ecx, dword ptr [esi] */
   9522     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3802E475: cmp ecx, dword ptr [edi + 8] */
   9523     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9524     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9525     _flag_k = FK_CMP;
   9526     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E47F; /* 0x3802E478: jne 0x3802e47f */
   9527 L_3802E47A:
   9528     edx = MEM32(esi + 0x4); /* 0x3802E47A: mov edx, dword ptr [esi + 4] */
   9529     goto L_3802E495; /* 0x3802E47D: jmp 0x3802e495 */
   9530 L_3802E47F:
   9531     ecx = MEM32(eax + 0x8); /* 0x3802E47F: mov ecx, dword ptr [eax + 8] */
   9532     /* cmp MEM8(ecx + 0x25), 0 */ /* 0x3802E482: cmp byte ptr [ecx + 0x25], 0 */
   9533     _flag_a = (uint32_t)(MEM8(ecx + 0x25)) << 24; _flag_b = (uint32_t)(0) << 24;
   9534     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9535     _flag_k = FK_NARROW(FK_CMP, 24);
   9536     edx = eax; /* 0x3802E486: mov edx, eax */
   9537     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E495; /* 0x3802E488: jne 0x3802e495 */
   9538 L_3802E48A:
   9539     edx = ecx; /* 0x3802E48A: mov edx, ecx */
   9540     ecx = MEM32(edx + 0x8); /* 0x3802E48C: mov ecx, dword ptr [edx + 8] */
   9541     /* cmp MEM8(ecx + 0x25), 0 */ /* 0x3802E48F: cmp byte ptr [ecx + 0x25], 0 */
   9542     _flag_a = (uint32_t)(MEM8(ecx + 0x25)) << 24; _flag_b = (uint32_t)(0) << 24;
   9543     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9544     _flag_k = FK_NARROW(FK_CMP, 24);
   9545     RECOMP_BACKEDGE();
   9546     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E48A; /* 0x3802E493: je 0x3802e48a */
   9547 L_3802E495:
   9548     MEM32(ebx + 0x8) = edx; /* 0x3802E495: mov dword ptr [ebx + 8], edx */
   9549 L_3802E498:
   9550     esi = MEM32(ebp + (-0x4)); /* 0x3802E498: mov esi, dword ptr [ebp - 4] */
   9551     SET_LO8(ecx, MEM8(esi + 0x24)); /* 0x3802E49B: mov cl, byte ptr [esi + 0x24] */
   9552     SET_LO8(ebx, 1); /* 0x3802E49E: mov bl, 1 */
   9553     /* cmp LO8(ecx), LO8(ebx) */ /* 0x3802E4A0: cmp cl, bl */
   9554     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9555     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9556     _flag_k = FK_NARROW(FK_CMP, 24);
   9557     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E708; /* 0x3802E4A2: jne 0x3802e708 */
   9558 L_3802E4A8:
   9559     ecx = MEM32(edi + 0x4); /* 0x3802E4A8: mov ecx, dword ptr [edi + 4] */
   9560     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E4AB: cmp eax, dword ptr [ecx + 4] */
   9561     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   9562     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9563     _flag_k = FK_CMP;
   9564     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4AE: je 0x3802e702 */
   9565 L_3802E4B4:
   9566     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
   9567     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9568     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9569     _flag_k = FK_NARROW(FK_CMP, 24);
   9570     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
   9571 L_3802E4BD:
   9572     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
   9573     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
   9574     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
   9575     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   9576     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9577     _flag_k = FK_CMP;
   9578     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
   9579 L_3802E4C6:
   9580     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
   9581     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
   9582     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
   9583     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   9584     _cf = 0;
   9585     _flag_k = FK_NARROW(FK_TEST, 24);
   9586     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
   9587 L_3802E4D0:
   9588     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
   9589     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
   9590     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
   9591     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
   9592     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
   9593     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
   9594     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
   9595     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
   9596     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
   9597     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9598     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9599     _flag_k = FK_CMP;
   9600     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
   9601 L_3802E4EC:
   9602     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
   9603 L_3802E4EF:
   9604     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
   9605     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
   9606     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
   9607     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
   9608     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9609     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9610     _flag_k = FK_CMP;
   9611     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
   9612 L_3802E4FD:
   9613     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
   9614     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
   9615 L_3802E502:
   9616     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
   9617     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
   9618     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   9619     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9620     _flag_k = FK_CMP;
   9621     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
   9622 L_3802E509:
   9623     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
   9624     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
   9625 L_3802E50D:
   9626     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
   9627 L_3802E510:
   9628     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
   9629     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
   9630     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
   9631     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
   9632 L_3802E51B:
   9633     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
   9634     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
   9635     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9636     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9637     _flag_k = FK_NARROW(FK_CMP, 24);
   9638     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
   9639 L_3802E526:
   9640     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
   9641     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
   9642     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9643     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9644     _flag_k = FK_NARROW(FK_CMP, 24);
   9645     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
   9646 L_3802E532:
   9647     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
   9648 L_3802E534:
   9649     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
   9650     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
   9651     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   9652     _cf = 0;
   9653     _flag_k = FK_NARROW(FK_TEST, 24);
   9654     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
   9655 L_3802E53B:
   9656     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
   9657     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
   9658     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
   9659     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
   9660     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
   9661     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
   9662     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
   9663     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
   9664     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
   9665     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9666     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9667     _flag_k = FK_CMP;
   9668     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
   9669 L_3802E557:
   9670     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
   9671 L_3802E55A:
   9672     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
   9673     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
   9674     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
   9675     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
   9676     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9677     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9678     _flag_k = FK_CMP;
   9679     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
   9680 L_3802E568:
   9681     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
   9682     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
   9683 L_3802E56D:
   9684     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
   9685     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
   9686     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9687     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9688     _flag_k = FK_CMP;
   9689     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
   9690 L_3802E575:
   9691     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
   9692     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
   9693 L_3802E57A:
   9694     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
   9695 L_3802E57C:
   9696     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
   9697     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
   9698     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
   9699     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
   9700 L_3802E587:
   9701     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
   9702     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
   9703     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9704     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9705     _flag_k = FK_NARROW(FK_CMP, 24);
   9706     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
   9707 L_3802E593:
   9708     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
   9709     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
   9710     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9711     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9712     _flag_k = FK_NARROW(FK_CMP, 24);
   9713     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
   9714 L_3802E59E:
   9715     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
   9716     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
   9717     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
   9718     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
   9719     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   9720     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9721     _flag_k = FK_CMP;
   9722     RECOMP_BACKEDGE();
   9723     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
   9724 L_3802E5B1:
   9725     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
   9726 L_3802E5B6:
   9727     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
   9728     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
   9729     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9730     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9731     _flag_k = FK_NARROW(FK_CMP, 24);
   9732     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
   9733 L_3802E5BE:
   9734     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
   9735     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
   9736     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
   9737     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
   9738     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
   9739     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
   9740     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
   9741     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
   9742     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9743     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9744     _flag_k = FK_CMP;
   9745     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
   9746 L_3802E5D6:
   9747     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
   9748 L_3802E5D9:
   9749     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
   9750     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
   9751     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
   9752     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
   9753     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9754     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9755     _flag_k = FK_CMP;
   9756     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
   9757 L_3802E5E7:
   9758     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
   9759     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
   9760 L_3802E5EC:
   9761     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
   9762     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
   9763     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9764     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9765     _flag_k = FK_CMP;
   9766     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
   9767 L_3802E5F4:
   9768     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
   9769     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
   9770 L_3802E5F9:
   9771     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
   9772 L_3802E5FB:
   9773     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
   9774     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
   9775     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
   9776     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
   9777 L_3802E607:
   9778     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
   9779     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
   9780     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
   9781     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
   9782     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
   9783     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
   9784     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
   9785     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
   9786     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
   9787     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
   9788     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
   9789     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
   9790     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
   9791     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9792     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9793     _flag_k = FK_CMP;
   9794     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
   9795 L_3802E62E:
   9796     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
   9797 L_3802E631:
   9798     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
   9799     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
   9800     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
   9801     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
   9802     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9803     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9804     _flag_k = FK_CMP;
   9805     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
   9806 L_3802E63F:
   9807     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
   9808     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
   9809     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
   9810 L_3802E649:
   9811     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
   9812     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
   9813     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   9814     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9815     _flag_k = FK_CMP;
   9816     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
   9817 L_3802E650:
   9818     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
   9819     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
   9820     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
   9821 L_3802E659:
   9822     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
   9823     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
   9824     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
   9825 L_3802E663:
   9826     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
   9827     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
   9828     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   9829     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9830     _flag_k = FK_NARROW(FK_CMP, 24);
   9831     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
   9832 L_3802E66A:
   9833     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
   9834     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
   9835     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
   9836     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
   9837     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
   9838     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
   9839     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
   9840     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
   9841     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9842     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9843     _flag_k = FK_CMP;
   9844     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
   9845 L_3802E683:
   9846     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
   9847 L_3802E686:
   9848     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
   9849     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
   9850     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
   9851     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
   9852     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9853     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9854     _flag_k = FK_CMP;
   9855     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
   9856 L_3802E694:
   9857     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
   9858     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
   9859 L_3802E699:
   9860     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
   9861     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
   9862     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   9863     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9864     _flag_k = FK_CMP;
   9865     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
   9866 L_3802E6A0:
   9867     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
   9868     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
   9869 L_3802E6A4:
   9870     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
   9871 L_3802E6A7:
   9872     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
   9873     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
   9874     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
   9875     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
   9876 L_3802E6B1:
   9877     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
   9878     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
   9879     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
   9880     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
   9881     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
   9882     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
   9883     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
   9884     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
   9885     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
   9886     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
   9887     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
   9888     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
   9889     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
   9890     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9891     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9892     _flag_k = FK_CMP;
   9893     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
   9894 L_3802E6D7:
   9895     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
   9896 L_3802E6DA:
   9897     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
   9898     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
   9899     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
   9900     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
   9901     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   9902     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9903     _flag_k = FK_CMP;
   9904     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
   9905 L_3802E6E8:
   9906     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
   9907     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
   9908 L_3802E6ED:
   9909     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
   9910     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
   9911     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9912     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9913     _flag_k = FK_CMP;
   9914     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
   9915 L_3802E6F5:
   9916     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
   9917     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
   9918 L_3802E6FA:
   9919     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
   9920 L_3802E6FC:
   9921     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
   9922 L_3802E6FF:
   9923     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
   9924 L_3802E702:
   9925     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
   9926     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
   9927 L_3802E708:
   9928     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
   9929     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
   9930     RECOMP_FLAGS_IN();
   9931     PUSH32(esp, esi); /* 0x3802E710: push esi */
   9932     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
   9933     RECOMP_FLAGS_IN();
   9934     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
   9935     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
   9936     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   9937     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   9938     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
   9939     _flag_k = FK_ADD;
   9940     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   9941     eax = eax - 1; /* 0x3802E71F: dec eax */
   9942     _flag_k = FK_DEC;
   9943     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
   9944     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
   9945     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
   9946     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
   9947     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
   9948     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
   9949     esp = ebp; /* 0x3802E72B: mov esp, ebp */
   9950     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
   9951     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
   9952     RECOMP_REGS_OUT();
   9953 }
   9954 
   9955 void sub_3802E469(void) {
   9956     int _fpu_cmp = 0;
   9957     uint32_t _cf = 0;
   9958     int _df = 1;
   9959     uint32_t _flag_k = FK_NONE;
   9960     uint32_t _flag_a = 0, _flag_b = 0;
   9961     uint32_t _itail_tgt = 0;
   9962     RECOMP_REGS_LOCALS
   9963     RECOMP_ENTER(0x3802E469u);
   9964 
   9965 L_3802E469:
   9966     MEM32(ebx) = edx; /* 0x3802E469: mov dword ptr [ebx], edx */
   9967     ebx = MEM32(edi + 0x4); /* 0x3802E46B: mov ebx, dword ptr [edi + 4] */
   9968     /* cmp MEM32(ebx + 0x8), esi */ /* 0x3802E46E: cmp dword ptr [ebx + 8], esi */
   9969     _flag_a = (uint32_t)(MEM32(ebx + 0x8)); _flag_b = (uint32_t)(esi);
   9970     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9971     _flag_k = FK_CMP;
   9972     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E498; /* 0x3802E471: jne 0x3802e498 */
   9973 L_3802E473:
   9974     ecx = MEM32(esi); /* 0x3802E473: mov ecx, dword ptr [esi] */
   9975     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3802E475: cmp ecx, dword ptr [edi + 8] */
   9976     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9977     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9978     _flag_k = FK_CMP;
   9979     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E47F; /* 0x3802E478: jne 0x3802e47f */
   9980 L_3802E47A:
   9981     edx = MEM32(esi + 0x4); /* 0x3802E47A: mov edx, dword ptr [esi + 4] */
   9982     goto L_3802E495; /* 0x3802E47D: jmp 0x3802e495 */
   9983 L_3802E47F:
   9984     ecx = MEM32(eax + 0x8); /* 0x3802E47F: mov ecx, dword ptr [eax + 8] */
   9985     /* cmp MEM8(ecx + 0x25), 0 */ /* 0x3802E482: cmp byte ptr [ecx + 0x25], 0 */
   9986     _flag_a = (uint32_t)(MEM8(ecx + 0x25)) << 24; _flag_b = (uint32_t)(0) << 24;
   9987     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9988     _flag_k = FK_NARROW(FK_CMP, 24);
   9989     edx = eax; /* 0x3802E486: mov edx, eax */
   9990     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E495; /* 0x3802E488: jne 0x3802e495 */
   9991 L_3802E48A:
   9992     edx = ecx; /* 0x3802E48A: mov edx, ecx */
   9993     ecx = MEM32(edx + 0x8); /* 0x3802E48C: mov ecx, dword ptr [edx + 8] */
   9994     /* cmp MEM8(ecx + 0x25), 0 */ /* 0x3802E48F: cmp byte ptr [ecx + 0x25], 0 */
   9995     _flag_a = (uint32_t)(MEM8(ecx + 0x25)) << 24; _flag_b = (uint32_t)(0) << 24;
   9996     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9997     _flag_k = FK_NARROW(FK_CMP, 24);
   9998     RECOMP_BACKEDGE();
   9999     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E48A; /* 0x3802E493: je 0x3802e48a */
  10000 L_3802E495:
  10001     MEM32(ebx + 0x8) = edx; /* 0x3802E495: mov dword ptr [ebx + 8], edx */
  10002 L_3802E498:
  10003     esi = MEM32(ebp + (-0x4)); /* 0x3802E498: mov esi, dword ptr [ebp - 4] */
  10004     SET_LO8(ecx, MEM8(esi + 0x24)); /* 0x3802E49B: mov cl, byte ptr [esi + 0x24] */
  10005     SET_LO8(ebx, 1); /* 0x3802E49E: mov bl, 1 */
  10006     /* cmp LO8(ecx), LO8(ebx) */ /* 0x3802E4A0: cmp cl, bl */
  10007     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10008     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10009     _flag_k = FK_NARROW(FK_CMP, 24);
  10010     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E708; /* 0x3802E4A2: jne 0x3802e708 */
  10011 L_3802E4A8:
  10012     ecx = MEM32(edi + 0x4); /* 0x3802E4A8: mov ecx, dword ptr [edi + 4] */
  10013     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E4AB: cmp eax, dword ptr [ecx + 4] */
  10014     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  10015     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10016     _flag_k = FK_CMP;
  10017     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4AE: je 0x3802e702 */
  10018 L_3802E4B4:
  10019     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
  10020     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10021     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10022     _flag_k = FK_NARROW(FK_CMP, 24);
  10023     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
  10024 L_3802E4BD:
  10025     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
  10026     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
  10027     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
  10028     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  10029     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10030     _flag_k = FK_CMP;
  10031     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
  10032 L_3802E4C6:
  10033     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
  10034     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
  10035     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
  10036     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  10037     _cf = 0;
  10038     _flag_k = FK_NARROW(FK_TEST, 24);
  10039     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
  10040 L_3802E4D0:
  10041     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
  10042     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
  10043     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
  10044     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
  10045     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
  10046     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
  10047     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
  10048     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
  10049     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
  10050     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10051     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10052     _flag_k = FK_CMP;
  10053     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
  10054 L_3802E4EC:
  10055     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
  10056 L_3802E4EF:
  10057     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
  10058     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
  10059     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
  10060     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
  10061     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10062     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10063     _flag_k = FK_CMP;
  10064     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
  10065 L_3802E4FD:
  10066     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
  10067     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
  10068 L_3802E502:
  10069     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
  10070     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
  10071     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  10072     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10073     _flag_k = FK_CMP;
  10074     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
  10075 L_3802E509:
  10076     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
  10077     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
  10078 L_3802E50D:
  10079     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
  10080 L_3802E510:
  10081     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
  10082     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
  10083     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
  10084     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
  10085 L_3802E51B:
  10086     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
  10087     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
  10088     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10089     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10090     _flag_k = FK_NARROW(FK_CMP, 24);
  10091     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
  10092 L_3802E526:
  10093     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
  10094     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
  10095     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10096     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10097     _flag_k = FK_NARROW(FK_CMP, 24);
  10098     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
  10099 L_3802E532:
  10100     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
  10101 L_3802E534:
  10102     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
  10103     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
  10104     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  10105     _cf = 0;
  10106     _flag_k = FK_NARROW(FK_TEST, 24);
  10107     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
  10108 L_3802E53B:
  10109     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
  10110     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
  10111     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
  10112     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
  10113     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
  10114     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
  10115     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
  10116     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
  10117     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
  10118     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10119     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10120     _flag_k = FK_CMP;
  10121     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
  10122 L_3802E557:
  10123     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
  10124 L_3802E55A:
  10125     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
  10126     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
  10127     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
  10128     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
  10129     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10130     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10131     _flag_k = FK_CMP;
  10132     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
  10133 L_3802E568:
  10134     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
  10135     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
  10136 L_3802E56D:
  10137     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
  10138     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
  10139     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10140     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10141     _flag_k = FK_CMP;
  10142     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
  10143 L_3802E575:
  10144     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
  10145     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
  10146 L_3802E57A:
  10147     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
  10148 L_3802E57C:
  10149     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
  10150     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
  10151     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
  10152     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
  10153 L_3802E587:
  10154     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
  10155     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
  10156     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10157     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10158     _flag_k = FK_NARROW(FK_CMP, 24);
  10159     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
  10160 L_3802E593:
  10161     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
  10162     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
  10163     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10164     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10165     _flag_k = FK_NARROW(FK_CMP, 24);
  10166     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
  10167 L_3802E59E:
  10168     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
  10169     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
  10170     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
  10171     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
  10172     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  10173     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10174     _flag_k = FK_CMP;
  10175     RECOMP_BACKEDGE();
  10176     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
  10177 L_3802E5B1:
  10178     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
  10179 L_3802E5B6:
  10180     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
  10181     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
  10182     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10183     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10184     _flag_k = FK_NARROW(FK_CMP, 24);
  10185     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
  10186 L_3802E5BE:
  10187     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
  10188     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
  10189     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
  10190     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
  10191     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
  10192     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
  10193     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
  10194     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
  10195     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10196     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10197     _flag_k = FK_CMP;
  10198     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
  10199 L_3802E5D6:
  10200     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
  10201 L_3802E5D9:
  10202     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
  10203     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
  10204     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
  10205     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
  10206     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10207     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10208     _flag_k = FK_CMP;
  10209     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
  10210 L_3802E5E7:
  10211     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
  10212     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
  10213 L_3802E5EC:
  10214     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
  10215     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
  10216     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10217     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10218     _flag_k = FK_CMP;
  10219     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
  10220 L_3802E5F4:
  10221     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
  10222     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
  10223 L_3802E5F9:
  10224     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
  10225 L_3802E5FB:
  10226     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  10227     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  10228     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  10229     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  10230 L_3802E607:
  10231     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  10232     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  10233     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  10234     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  10235     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  10236     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  10237     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  10238     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  10239     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  10240     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  10241     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  10242     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  10243     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  10244     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10245     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10246     _flag_k = FK_CMP;
  10247     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  10248 L_3802E62E:
  10249     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  10250 L_3802E631:
  10251     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  10252     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  10253     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  10254     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  10255     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10256     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10257     _flag_k = FK_CMP;
  10258     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  10259 L_3802E63F:
  10260     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  10261     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  10262     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  10263 L_3802E649:
  10264     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  10265     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  10266     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  10267     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10268     _flag_k = FK_CMP;
  10269     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  10270 L_3802E650:
  10271     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  10272     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  10273     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  10274 L_3802E659:
  10275     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  10276     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  10277     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  10278 L_3802E663:
  10279     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
  10280     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
  10281     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10282     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10283     _flag_k = FK_NARROW(FK_CMP, 24);
  10284     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
  10285 L_3802E66A:
  10286     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
  10287     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
  10288     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
  10289     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
  10290     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
  10291     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
  10292     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
  10293     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
  10294     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10295     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10296     _flag_k = FK_CMP;
  10297     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
  10298 L_3802E683:
  10299     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
  10300 L_3802E686:
  10301     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
  10302     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
  10303     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
  10304     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
  10305     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10306     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10307     _flag_k = FK_CMP;
  10308     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
  10309 L_3802E694:
  10310     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
  10311     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
  10312 L_3802E699:
  10313     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
  10314     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
  10315     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  10316     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10317     _flag_k = FK_CMP;
  10318     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
  10319 L_3802E6A0:
  10320     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
  10321     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
  10322 L_3802E6A4:
  10323     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
  10324 L_3802E6A7:
  10325     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
  10326     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
  10327     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
  10328     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
  10329 L_3802E6B1:
  10330     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
  10331     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
  10332     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
  10333     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
  10334     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
  10335     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
  10336     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
  10337     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
  10338     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
  10339     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
  10340     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
  10341     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
  10342     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
  10343     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10344     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10345     _flag_k = FK_CMP;
  10346     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
  10347 L_3802E6D7:
  10348     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
  10349 L_3802E6DA:
  10350     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
  10351     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
  10352     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
  10353     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
  10354     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10355     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10356     _flag_k = FK_CMP;
  10357     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
  10358 L_3802E6E8:
  10359     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
  10360     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
  10361 L_3802E6ED:
  10362     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
  10363     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
  10364     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10365     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10366     _flag_k = FK_CMP;
  10367     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
  10368 L_3802E6F5:
  10369     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
  10370     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
  10371 L_3802E6FA:
  10372     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
  10373 L_3802E6FC:
  10374     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  10375 L_3802E6FF:
  10376     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  10377 L_3802E702:
  10378     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  10379     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  10380 L_3802E708:
  10381     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  10382     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  10383     RECOMP_FLAGS_IN();
  10384     PUSH32(esp, esi); /* 0x3802E710: push esi */
  10385     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  10386     RECOMP_FLAGS_IN();
  10387     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  10388     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  10389     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  10390     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  10391     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  10392     _flag_k = FK_ADD;
  10393     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  10394     eax = eax - 1; /* 0x3802E71F: dec eax */
  10395     _flag_k = FK_DEC;
  10396     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  10397     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  10398     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  10399     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  10400     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  10401     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  10402     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  10403     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  10404     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  10405     RECOMP_REGS_OUT();
  10406 }
  10407 
  10408 void sub_3802E495(void) {
  10409     int _fpu_cmp = 0;
  10410     uint32_t _cf = 0;
  10411     int _df = 1;
  10412     uint32_t _flag_k = FK_NONE;
  10413     uint32_t _flag_a = 0, _flag_b = 0;
  10414     uint32_t _itail_tgt = 0;
  10415     RECOMP_REGS_LOCALS
  10416     RECOMP_ENTER(0x3802E495u);
  10417 
  10418 L_3802E495:
  10419     MEM32(ebx + 0x8) = edx; /* 0x3802E495: mov dword ptr [ebx + 8], edx */
  10420     esi = MEM32(ebp + (-0x4)); /* 0x3802E498: mov esi, dword ptr [ebp - 4] */
  10421     SET_LO8(ecx, MEM8(esi + 0x24)); /* 0x3802E49B: mov cl, byte ptr [esi + 0x24] */
  10422     SET_LO8(ebx, 1); /* 0x3802E49E: mov bl, 1 */
  10423     /* cmp LO8(ecx), LO8(ebx) */ /* 0x3802E4A0: cmp cl, bl */
  10424     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10425     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10426     _flag_k = FK_NARROW(FK_CMP, 24);
  10427     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E708; /* 0x3802E4A2: jne 0x3802e708 */
  10428 L_3802E4A8:
  10429     ecx = MEM32(edi + 0x4); /* 0x3802E4A8: mov ecx, dword ptr [edi + 4] */
  10430     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E4AB: cmp eax, dword ptr [ecx + 4] */
  10431     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  10432     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10433     _flag_k = FK_CMP;
  10434     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4AE: je 0x3802e702 */
  10435 L_3802E4B4:
  10436     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
  10437     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10438     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10439     _flag_k = FK_NARROW(FK_CMP, 24);
  10440     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
  10441 L_3802E4BD:
  10442     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
  10443     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
  10444     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
  10445     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  10446     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10447     _flag_k = FK_CMP;
  10448     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
  10449 L_3802E4C6:
  10450     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
  10451     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
  10452     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
  10453     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  10454     _cf = 0;
  10455     _flag_k = FK_NARROW(FK_TEST, 24);
  10456     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
  10457 L_3802E4D0:
  10458     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
  10459     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
  10460     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
  10461     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
  10462     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
  10463     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
  10464     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
  10465     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
  10466     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
  10467     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10468     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10469     _flag_k = FK_CMP;
  10470     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
  10471 L_3802E4EC:
  10472     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
  10473 L_3802E4EF:
  10474     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
  10475     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
  10476     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
  10477     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
  10478     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10479     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10480     _flag_k = FK_CMP;
  10481     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
  10482 L_3802E4FD:
  10483     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
  10484     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
  10485 L_3802E502:
  10486     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
  10487     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
  10488     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  10489     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10490     _flag_k = FK_CMP;
  10491     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
  10492 L_3802E509:
  10493     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
  10494     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
  10495 L_3802E50D:
  10496     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
  10497 L_3802E510:
  10498     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
  10499     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
  10500     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
  10501     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
  10502 L_3802E51B:
  10503     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
  10504     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
  10505     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10506     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10507     _flag_k = FK_NARROW(FK_CMP, 24);
  10508     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
  10509 L_3802E526:
  10510     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
  10511     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
  10512     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10513     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10514     _flag_k = FK_NARROW(FK_CMP, 24);
  10515     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
  10516 L_3802E532:
  10517     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
  10518 L_3802E534:
  10519     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
  10520     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
  10521     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  10522     _cf = 0;
  10523     _flag_k = FK_NARROW(FK_TEST, 24);
  10524     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
  10525 L_3802E53B:
  10526     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
  10527     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
  10528     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
  10529     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
  10530     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
  10531     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
  10532     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
  10533     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
  10534     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
  10535     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10536     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10537     _flag_k = FK_CMP;
  10538     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
  10539 L_3802E557:
  10540     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
  10541 L_3802E55A:
  10542     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
  10543     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
  10544     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
  10545     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
  10546     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10547     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10548     _flag_k = FK_CMP;
  10549     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
  10550 L_3802E568:
  10551     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
  10552     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
  10553 L_3802E56D:
  10554     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
  10555     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
  10556     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10557     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10558     _flag_k = FK_CMP;
  10559     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
  10560 L_3802E575:
  10561     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
  10562     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
  10563 L_3802E57A:
  10564     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
  10565 L_3802E57C:
  10566     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
  10567     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
  10568     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
  10569     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
  10570 L_3802E587:
  10571     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
  10572     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
  10573     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10574     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10575     _flag_k = FK_NARROW(FK_CMP, 24);
  10576     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
  10577 L_3802E593:
  10578     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
  10579     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
  10580     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10581     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10582     _flag_k = FK_NARROW(FK_CMP, 24);
  10583     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
  10584 L_3802E59E:
  10585     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
  10586     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
  10587     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
  10588     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
  10589     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  10590     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10591     _flag_k = FK_CMP;
  10592     RECOMP_BACKEDGE();
  10593     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
  10594 L_3802E5B1:
  10595     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
  10596 L_3802E5B6:
  10597     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
  10598     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
  10599     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10600     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10601     _flag_k = FK_NARROW(FK_CMP, 24);
  10602     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
  10603 L_3802E5BE:
  10604     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
  10605     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
  10606     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
  10607     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
  10608     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
  10609     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
  10610     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
  10611     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
  10612     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10613     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10614     _flag_k = FK_CMP;
  10615     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
  10616 L_3802E5D6:
  10617     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
  10618 L_3802E5D9:
  10619     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
  10620     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
  10621     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
  10622     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
  10623     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10624     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10625     _flag_k = FK_CMP;
  10626     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
  10627 L_3802E5E7:
  10628     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
  10629     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
  10630 L_3802E5EC:
  10631     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
  10632     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
  10633     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10634     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10635     _flag_k = FK_CMP;
  10636     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
  10637 L_3802E5F4:
  10638     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
  10639     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
  10640 L_3802E5F9:
  10641     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
  10642 L_3802E5FB:
  10643     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  10644     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  10645     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  10646     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  10647 L_3802E607:
  10648     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  10649     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  10650     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  10651     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  10652     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  10653     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  10654     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  10655     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  10656     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  10657     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  10658     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  10659     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  10660     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  10661     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10662     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10663     _flag_k = FK_CMP;
  10664     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  10665 L_3802E62E:
  10666     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  10667 L_3802E631:
  10668     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  10669     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  10670     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  10671     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  10672     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10673     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10674     _flag_k = FK_CMP;
  10675     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  10676 L_3802E63F:
  10677     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  10678     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  10679     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  10680 L_3802E649:
  10681     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  10682     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  10683     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  10684     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10685     _flag_k = FK_CMP;
  10686     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  10687 L_3802E650:
  10688     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  10689     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  10690     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  10691 L_3802E659:
  10692     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  10693     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  10694     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  10695 L_3802E663:
  10696     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
  10697     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
  10698     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10699     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10700     _flag_k = FK_NARROW(FK_CMP, 24);
  10701     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
  10702 L_3802E66A:
  10703     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
  10704     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
  10705     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
  10706     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
  10707     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
  10708     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
  10709     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
  10710     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
  10711     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10712     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10713     _flag_k = FK_CMP;
  10714     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
  10715 L_3802E683:
  10716     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
  10717 L_3802E686:
  10718     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
  10719     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
  10720     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
  10721     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
  10722     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10723     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10724     _flag_k = FK_CMP;
  10725     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
  10726 L_3802E694:
  10727     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
  10728     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
  10729 L_3802E699:
  10730     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
  10731     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
  10732     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  10733     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10734     _flag_k = FK_CMP;
  10735     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
  10736 L_3802E6A0:
  10737     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
  10738     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
  10739 L_3802E6A4:
  10740     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
  10741 L_3802E6A7:
  10742     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
  10743     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
  10744     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
  10745     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
  10746 L_3802E6B1:
  10747     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
  10748     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
  10749     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
  10750     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
  10751     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
  10752     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
  10753     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
  10754     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
  10755     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
  10756     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
  10757     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
  10758     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
  10759     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
  10760     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10761     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10762     _flag_k = FK_CMP;
  10763     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
  10764 L_3802E6D7:
  10765     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
  10766 L_3802E6DA:
  10767     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
  10768     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
  10769     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
  10770     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
  10771     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10772     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10773     _flag_k = FK_CMP;
  10774     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
  10775 L_3802E6E8:
  10776     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
  10777     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
  10778 L_3802E6ED:
  10779     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
  10780     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
  10781     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10782     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10783     _flag_k = FK_CMP;
  10784     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
  10785 L_3802E6F5:
  10786     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
  10787     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
  10788 L_3802E6FA:
  10789     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
  10790 L_3802E6FC:
  10791     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  10792 L_3802E6FF:
  10793     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  10794 L_3802E702:
  10795     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  10796     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  10797 L_3802E708:
  10798     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  10799     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  10800     RECOMP_FLAGS_IN();
  10801     PUSH32(esp, esi); /* 0x3802E710: push esi */
  10802     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  10803     RECOMP_FLAGS_IN();
  10804     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  10805     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  10806     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  10807     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  10808     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  10809     _flag_k = FK_ADD;
  10810     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  10811     eax = eax - 1; /* 0x3802E71F: dec eax */
  10812     _flag_k = FK_DEC;
  10813     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  10814     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  10815     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  10816     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  10817     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  10818     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  10819     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  10820     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  10821     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  10822     RECOMP_REGS_OUT();
  10823 }
  10824 
  10825 void sub_3802E4B4(void) {
  10826     int _fpu_cmp = 0;
  10827     uint32_t _cf = 0;
  10828     int _df = 1;
  10829     uint32_t _flag_k = FK_NONE;
  10830     uint32_t _flag_a = 0, _flag_b = 0;
  10831     uint32_t _itail_tgt = 0;
  10832     RECOMP_REGS_LOCALS
  10833     RECOMP_ENTER(0x3802E4B4u);
  10834 
  10835 L_3802E4B4:
  10836     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
  10837     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10838     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10839     _flag_k = FK_NARROW(FK_CMP, 24);
  10840     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
  10841 L_3802E4BD:
  10842     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
  10843     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
  10844     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
  10845     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  10846     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10847     _flag_k = FK_CMP;
  10848     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
  10849 L_3802E4C6:
  10850     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
  10851     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
  10852     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
  10853     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  10854     _cf = 0;
  10855     _flag_k = FK_NARROW(FK_TEST, 24);
  10856     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
  10857 L_3802E4D0:
  10858     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
  10859     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
  10860     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
  10861     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
  10862     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
  10863     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
  10864     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
  10865     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
  10866     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
  10867     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10868     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10869     _flag_k = FK_CMP;
  10870     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
  10871 L_3802E4EC:
  10872     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
  10873 L_3802E4EF:
  10874     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
  10875     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
  10876     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
  10877     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
  10878     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10879     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10880     _flag_k = FK_CMP;
  10881     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
  10882 L_3802E4FD:
  10883     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
  10884     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
  10885 L_3802E502:
  10886     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
  10887     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
  10888     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  10889     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10890     _flag_k = FK_CMP;
  10891     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
  10892 L_3802E509:
  10893     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
  10894     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
  10895 L_3802E50D:
  10896     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
  10897 L_3802E510:
  10898     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
  10899     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
  10900     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
  10901     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
  10902 L_3802E51B:
  10903     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
  10904     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
  10905     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10906     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10907     _flag_k = FK_NARROW(FK_CMP, 24);
  10908     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
  10909 L_3802E526:
  10910     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
  10911     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
  10912     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10913     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10914     _flag_k = FK_NARROW(FK_CMP, 24);
  10915     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
  10916 L_3802E532:
  10917     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
  10918 L_3802E534:
  10919     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
  10920     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
  10921     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  10922     _cf = 0;
  10923     _flag_k = FK_NARROW(FK_TEST, 24);
  10924     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
  10925 L_3802E53B:
  10926     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
  10927     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
  10928     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
  10929     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
  10930     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
  10931     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
  10932     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
  10933     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
  10934     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
  10935     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10936     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10937     _flag_k = FK_CMP;
  10938     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
  10939 L_3802E557:
  10940     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
  10941 L_3802E55A:
  10942     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
  10943     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
  10944     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
  10945     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
  10946     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  10947     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10948     _flag_k = FK_CMP;
  10949     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
  10950 L_3802E568:
  10951     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
  10952     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
  10953 L_3802E56D:
  10954     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
  10955     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
  10956     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10957     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10958     _flag_k = FK_CMP;
  10959     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
  10960 L_3802E575:
  10961     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
  10962     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
  10963 L_3802E57A:
  10964     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
  10965 L_3802E57C:
  10966     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
  10967     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
  10968     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
  10969     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
  10970 L_3802E587:
  10971     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
  10972     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
  10973     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10974     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10975     _flag_k = FK_NARROW(FK_CMP, 24);
  10976     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
  10977 L_3802E593:
  10978     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
  10979     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
  10980     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  10981     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10982     _flag_k = FK_NARROW(FK_CMP, 24);
  10983     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
  10984 L_3802E59E:
  10985     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
  10986     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
  10987     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
  10988     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
  10989     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  10990     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10991     _flag_k = FK_CMP;
  10992     RECOMP_BACKEDGE();
  10993     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
  10994 L_3802E5B1:
  10995     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
  10996 L_3802E5B6:
  10997     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
  10998     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
  10999     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11000     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11001     _flag_k = FK_NARROW(FK_CMP, 24);
  11002     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
  11003 L_3802E5BE:
  11004     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
  11005     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
  11006     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
  11007     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
  11008     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
  11009     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
  11010     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
  11011     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
  11012     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11013     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11014     _flag_k = FK_CMP;
  11015     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
  11016 L_3802E5D6:
  11017     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
  11018 L_3802E5D9:
  11019     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
  11020     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
  11021     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
  11022     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
  11023     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11024     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11025     _flag_k = FK_CMP;
  11026     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
  11027 L_3802E5E7:
  11028     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
  11029     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
  11030 L_3802E5EC:
  11031     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
  11032     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
  11033     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  11034     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11035     _flag_k = FK_CMP;
  11036     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
  11037 L_3802E5F4:
  11038     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
  11039     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
  11040 L_3802E5F9:
  11041     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
  11042 L_3802E5FB:
  11043     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  11044     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  11045     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  11046     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  11047 L_3802E607:
  11048     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  11049     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  11050     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  11051     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  11052     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  11053     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  11054     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  11055     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  11056     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  11057     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  11058     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  11059     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  11060     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  11061     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11062     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11063     _flag_k = FK_CMP;
  11064     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  11065 L_3802E62E:
  11066     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  11067 L_3802E631:
  11068     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  11069     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  11070     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  11071     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  11072     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11073     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11074     _flag_k = FK_CMP;
  11075     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  11076 L_3802E63F:
  11077     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  11078     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  11079     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  11080 L_3802E649:
  11081     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  11082     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  11083     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  11084     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11085     _flag_k = FK_CMP;
  11086     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  11087 L_3802E650:
  11088     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  11089     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  11090     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  11091 L_3802E659:
  11092     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  11093     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  11094     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  11095 L_3802E663:
  11096     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
  11097     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
  11098     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11099     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11100     _flag_k = FK_NARROW(FK_CMP, 24);
  11101     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
  11102 L_3802E66A:
  11103     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
  11104     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
  11105     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
  11106     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
  11107     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
  11108     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
  11109     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
  11110     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
  11111     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11112     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11113     _flag_k = FK_CMP;
  11114     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
  11115 L_3802E683:
  11116     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
  11117 L_3802E686:
  11118     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
  11119     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
  11120     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
  11121     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
  11122     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11123     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11124     _flag_k = FK_CMP;
  11125     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
  11126 L_3802E694:
  11127     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
  11128     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
  11129 L_3802E699:
  11130     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
  11131     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
  11132     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  11133     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11134     _flag_k = FK_CMP;
  11135     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
  11136 L_3802E6A0:
  11137     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
  11138     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
  11139 L_3802E6A4:
  11140     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
  11141 L_3802E6A7:
  11142     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
  11143     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
  11144     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
  11145     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
  11146 L_3802E6B1:
  11147     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
  11148     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
  11149     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
  11150     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
  11151     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
  11152     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
  11153     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
  11154     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
  11155     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
  11156     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
  11157     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
  11158     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
  11159     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
  11160     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11161     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11162     _flag_k = FK_CMP;
  11163     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
  11164 L_3802E6D7:
  11165     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
  11166 L_3802E6DA:
  11167     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
  11168     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
  11169     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
  11170     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
  11171     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11172     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11173     _flag_k = FK_CMP;
  11174     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
  11175 L_3802E6E8:
  11176     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
  11177     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
  11178 L_3802E6ED:
  11179     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
  11180     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
  11181     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  11182     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11183     _flag_k = FK_CMP;
  11184     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
  11185 L_3802E6F5:
  11186     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
  11187     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
  11188 L_3802E6FA:
  11189     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
  11190 L_3802E6FC:
  11191     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  11192 L_3802E6FF:
  11193     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  11194 L_3802E702:
  11195     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  11196     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  11197     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  11198     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  11199     RECOMP_FLAGS_IN();
  11200     PUSH32(esp, esi); /* 0x3802E710: push esi */
  11201     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  11202     RECOMP_FLAGS_IN();
  11203     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  11204     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  11205     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  11206     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11207     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  11208     _flag_k = FK_ADD;
  11209     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  11210     eax = eax - 1; /* 0x3802E71F: dec eax */
  11211     _flag_k = FK_DEC;
  11212     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  11213     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  11214     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  11215     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  11216     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  11217     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  11218     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  11219     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  11220     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  11221     RECOMP_REGS_OUT();
  11222 }
  11223 
  11224 void sub_3802E510(void) {
  11225     int _fpu_cmp = 0;
  11226     uint32_t _cf = 0;
  11227     int _df = 1;
  11228     uint32_t _flag_k = FK_NONE;
  11229     uint32_t _flag_a = 0, _flag_b = 0;
  11230     uint32_t _itail_tgt = 0;
  11231     RECOMP_REGS_LOCALS
  11232     RECOMP_ENTER(0x3802E510u);
  11233 
  11234     goto L_3802E510;
  11235 L_3802E4B4:
  11236     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
  11237     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11238     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11239     _flag_k = FK_NARROW(FK_CMP, 24);
  11240     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
  11241 L_3802E4BD:
  11242     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
  11243     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
  11244     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
  11245     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  11246     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11247     _flag_k = FK_CMP;
  11248     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
  11249 L_3802E4C6:
  11250     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
  11251     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
  11252     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
  11253     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  11254     _cf = 0;
  11255     _flag_k = FK_NARROW(FK_TEST, 24);
  11256     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
  11257 L_3802E4D0:
  11258     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
  11259     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
  11260     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
  11261     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
  11262     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
  11263     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
  11264     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
  11265     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
  11266     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
  11267     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11268     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11269     _flag_k = FK_CMP;
  11270     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
  11271 L_3802E4EC:
  11272     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
  11273 L_3802E4EF:
  11274     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
  11275     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
  11276     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
  11277     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
  11278     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11279     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11280     _flag_k = FK_CMP;
  11281     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
  11282 L_3802E4FD:
  11283     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
  11284     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
  11285 L_3802E502:
  11286     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
  11287     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
  11288     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  11289     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11290     _flag_k = FK_CMP;
  11291     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
  11292 L_3802E509:
  11293     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
  11294     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
  11295 L_3802E50D:
  11296     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
  11297 L_3802E510:
  11298     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
  11299     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
  11300     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
  11301     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
  11302 L_3802E51B:
  11303     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
  11304     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
  11305     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11306     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11307     _flag_k = FK_NARROW(FK_CMP, 24);
  11308     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
  11309 L_3802E526:
  11310     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
  11311     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
  11312     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11313     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11314     _flag_k = FK_NARROW(FK_CMP, 24);
  11315     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
  11316 L_3802E532:
  11317     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
  11318 L_3802E534:
  11319     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
  11320     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
  11321     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  11322     _cf = 0;
  11323     _flag_k = FK_NARROW(FK_TEST, 24);
  11324     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
  11325 L_3802E53B:
  11326     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
  11327     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
  11328     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
  11329     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
  11330     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
  11331     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
  11332     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
  11333     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
  11334     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
  11335     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11336     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11337     _flag_k = FK_CMP;
  11338     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
  11339 L_3802E557:
  11340     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
  11341 L_3802E55A:
  11342     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
  11343     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
  11344     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
  11345     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
  11346     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11347     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11348     _flag_k = FK_CMP;
  11349     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
  11350 L_3802E568:
  11351     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
  11352     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
  11353 L_3802E56D:
  11354     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
  11355     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
  11356     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  11357     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11358     _flag_k = FK_CMP;
  11359     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
  11360 L_3802E575:
  11361     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
  11362     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
  11363 L_3802E57A:
  11364     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
  11365 L_3802E57C:
  11366     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
  11367     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
  11368     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
  11369     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
  11370 L_3802E587:
  11371     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
  11372     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
  11373     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11374     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11375     _flag_k = FK_NARROW(FK_CMP, 24);
  11376     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
  11377 L_3802E593:
  11378     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
  11379     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
  11380     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11381     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11382     _flag_k = FK_NARROW(FK_CMP, 24);
  11383     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
  11384 L_3802E59E:
  11385     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
  11386     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
  11387     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
  11388     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
  11389     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  11390     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11391     _flag_k = FK_CMP;
  11392     RECOMP_BACKEDGE();
  11393     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
  11394 L_3802E5B1:
  11395     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
  11396 L_3802E5B6:
  11397     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
  11398     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
  11399     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11400     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11401     _flag_k = FK_NARROW(FK_CMP, 24);
  11402     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
  11403 L_3802E5BE:
  11404     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
  11405     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
  11406     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
  11407     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
  11408     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
  11409     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
  11410     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
  11411     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
  11412     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11413     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11414     _flag_k = FK_CMP;
  11415     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
  11416 L_3802E5D6:
  11417     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
  11418 L_3802E5D9:
  11419     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
  11420     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
  11421     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
  11422     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
  11423     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11424     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11425     _flag_k = FK_CMP;
  11426     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
  11427 L_3802E5E7:
  11428     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
  11429     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
  11430 L_3802E5EC:
  11431     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
  11432     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
  11433     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  11434     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11435     _flag_k = FK_CMP;
  11436     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
  11437 L_3802E5F4:
  11438     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
  11439     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
  11440 L_3802E5F9:
  11441     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
  11442 L_3802E5FB:
  11443     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  11444     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  11445     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  11446     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  11447 L_3802E607:
  11448     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  11449     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  11450     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  11451     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  11452     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  11453     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  11454     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  11455     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  11456     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  11457     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  11458     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  11459     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  11460     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  11461     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11462     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11463     _flag_k = FK_CMP;
  11464     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  11465 L_3802E62E:
  11466     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  11467 L_3802E631:
  11468     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  11469     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  11470     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  11471     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  11472     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11473     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11474     _flag_k = FK_CMP;
  11475     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  11476 L_3802E63F:
  11477     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  11478     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  11479     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  11480 L_3802E649:
  11481     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  11482     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  11483     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  11484     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11485     _flag_k = FK_CMP;
  11486     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  11487 L_3802E650:
  11488     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  11489     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  11490     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  11491 L_3802E659:
  11492     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  11493     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  11494     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  11495 L_3802E663:
  11496     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
  11497     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
  11498     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11499     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11500     _flag_k = FK_NARROW(FK_CMP, 24);
  11501     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
  11502 L_3802E66A:
  11503     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
  11504     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
  11505     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
  11506     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
  11507     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
  11508     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
  11509     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
  11510     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
  11511     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11512     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11513     _flag_k = FK_CMP;
  11514     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
  11515 L_3802E683:
  11516     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
  11517 L_3802E686:
  11518     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
  11519     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
  11520     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
  11521     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
  11522     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11523     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11524     _flag_k = FK_CMP;
  11525     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
  11526 L_3802E694:
  11527     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
  11528     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
  11529 L_3802E699:
  11530     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
  11531     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
  11532     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  11533     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11534     _flag_k = FK_CMP;
  11535     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
  11536 L_3802E6A0:
  11537     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
  11538     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
  11539 L_3802E6A4:
  11540     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
  11541 L_3802E6A7:
  11542     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
  11543     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
  11544     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
  11545     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
  11546 L_3802E6B1:
  11547     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
  11548     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
  11549     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
  11550     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
  11551     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
  11552     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
  11553     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
  11554     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
  11555     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
  11556     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
  11557     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
  11558     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
  11559     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
  11560     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11561     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11562     _flag_k = FK_CMP;
  11563     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
  11564 L_3802E6D7:
  11565     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
  11566 L_3802E6DA:
  11567     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
  11568     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
  11569     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
  11570     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
  11571     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11572     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11573     _flag_k = FK_CMP;
  11574     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
  11575 L_3802E6E8:
  11576     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
  11577     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
  11578 L_3802E6ED:
  11579     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
  11580     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
  11581     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  11582     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11583     _flag_k = FK_CMP;
  11584     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
  11585 L_3802E6F5:
  11586     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
  11587     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
  11588 L_3802E6FA:
  11589     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
  11590 L_3802E6FC:
  11591     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  11592 L_3802E6FF:
  11593     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  11594 L_3802E702:
  11595     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  11596     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  11597     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  11598     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  11599     RECOMP_FLAGS_IN();
  11600     PUSH32(esp, esi); /* 0x3802E710: push esi */
  11601     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  11602     RECOMP_FLAGS_IN();
  11603     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  11604     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  11605     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  11606     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11607     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  11608     _flag_k = FK_ADD;
  11609     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  11610     eax = eax - 1; /* 0x3802E71F: dec eax */
  11611     _flag_k = FK_DEC;
  11612     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  11613     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  11614     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  11615     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  11616     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  11617     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  11618     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  11619     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  11620     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  11621     RECOMP_REGS_OUT();
  11622 }
  11623 
  11624 void sub_3802E51B(void) {
  11625     int _fpu_cmp = 0;
  11626     uint32_t _cf = 0;
  11627     int _df = 1;
  11628     uint32_t _flag_k = FK_NONE;
  11629     uint32_t _flag_a = 0, _flag_b = 0;
  11630     uint32_t _itail_tgt = 0;
  11631     RECOMP_REGS_LOCALS
  11632     RECOMP_ENTER(0x3802E51Bu);
  11633 
  11634     goto L_3802E51B;
  11635 L_3802E4B4:
  11636     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
  11637     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11638     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11639     _flag_k = FK_NARROW(FK_CMP, 24);
  11640     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
  11641 L_3802E4BD:
  11642     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
  11643     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
  11644     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
  11645     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  11646     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11647     _flag_k = FK_CMP;
  11648     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
  11649 L_3802E4C6:
  11650     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
  11651     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
  11652     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
  11653     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  11654     _cf = 0;
  11655     _flag_k = FK_NARROW(FK_TEST, 24);
  11656     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
  11657 L_3802E4D0:
  11658     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
  11659     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
  11660     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
  11661     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
  11662     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
  11663     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
  11664     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
  11665     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
  11666     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
  11667     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11668     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11669     _flag_k = FK_CMP;
  11670     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
  11671 L_3802E4EC:
  11672     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
  11673 L_3802E4EF:
  11674     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
  11675     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
  11676     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
  11677     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
  11678     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11679     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11680     _flag_k = FK_CMP;
  11681     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
  11682 L_3802E4FD:
  11683     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
  11684     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
  11685 L_3802E502:
  11686     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
  11687     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
  11688     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  11689     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11690     _flag_k = FK_CMP;
  11691     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
  11692 L_3802E509:
  11693     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
  11694     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
  11695 L_3802E50D:
  11696     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
  11697 L_3802E510:
  11698     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
  11699     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
  11700     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
  11701     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
  11702 L_3802E51B:
  11703     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
  11704     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
  11705     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11706     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11707     _flag_k = FK_NARROW(FK_CMP, 24);
  11708     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
  11709 L_3802E526:
  11710     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
  11711     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
  11712     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11713     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11714     _flag_k = FK_NARROW(FK_CMP, 24);
  11715     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
  11716 L_3802E532:
  11717     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
  11718 L_3802E534:
  11719     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
  11720     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
  11721     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  11722     _cf = 0;
  11723     _flag_k = FK_NARROW(FK_TEST, 24);
  11724     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
  11725 L_3802E53B:
  11726     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
  11727     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
  11728     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
  11729     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
  11730     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
  11731     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
  11732     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
  11733     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
  11734     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
  11735     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11736     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11737     _flag_k = FK_CMP;
  11738     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
  11739 L_3802E557:
  11740     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
  11741 L_3802E55A:
  11742     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
  11743     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
  11744     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
  11745     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
  11746     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11747     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11748     _flag_k = FK_CMP;
  11749     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
  11750 L_3802E568:
  11751     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
  11752     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
  11753 L_3802E56D:
  11754     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
  11755     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
  11756     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  11757     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11758     _flag_k = FK_CMP;
  11759     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
  11760 L_3802E575:
  11761     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
  11762     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
  11763 L_3802E57A:
  11764     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
  11765 L_3802E57C:
  11766     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
  11767     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
  11768     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
  11769     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
  11770 L_3802E587:
  11771     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
  11772     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
  11773     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11774     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11775     _flag_k = FK_NARROW(FK_CMP, 24);
  11776     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
  11777 L_3802E593:
  11778     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
  11779     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
  11780     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11781     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11782     _flag_k = FK_NARROW(FK_CMP, 24);
  11783     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
  11784 L_3802E59E:
  11785     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
  11786     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
  11787     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
  11788     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
  11789     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  11790     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11791     _flag_k = FK_CMP;
  11792     RECOMP_BACKEDGE();
  11793     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
  11794 L_3802E5B1:
  11795     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
  11796 L_3802E5B6:
  11797     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
  11798     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
  11799     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11800     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11801     _flag_k = FK_NARROW(FK_CMP, 24);
  11802     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
  11803 L_3802E5BE:
  11804     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
  11805     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
  11806     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
  11807     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
  11808     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
  11809     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
  11810     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
  11811     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
  11812     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11813     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11814     _flag_k = FK_CMP;
  11815     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
  11816 L_3802E5D6:
  11817     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
  11818 L_3802E5D9:
  11819     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
  11820     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
  11821     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
  11822     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
  11823     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11824     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11825     _flag_k = FK_CMP;
  11826     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
  11827 L_3802E5E7:
  11828     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
  11829     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
  11830 L_3802E5EC:
  11831     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
  11832     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
  11833     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  11834     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11835     _flag_k = FK_CMP;
  11836     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
  11837 L_3802E5F4:
  11838     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
  11839     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
  11840 L_3802E5F9:
  11841     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
  11842 L_3802E5FB:
  11843     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  11844     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  11845     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  11846     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  11847 L_3802E607:
  11848     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  11849     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  11850     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  11851     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  11852     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  11853     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  11854     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  11855     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  11856     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  11857     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  11858     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  11859     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  11860     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  11861     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11862     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11863     _flag_k = FK_CMP;
  11864     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  11865 L_3802E62E:
  11866     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  11867 L_3802E631:
  11868     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  11869     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  11870     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  11871     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  11872     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11873     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11874     _flag_k = FK_CMP;
  11875     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  11876 L_3802E63F:
  11877     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  11878     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  11879     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  11880 L_3802E649:
  11881     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  11882     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  11883     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  11884     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11885     _flag_k = FK_CMP;
  11886     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  11887 L_3802E650:
  11888     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  11889     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  11890     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  11891 L_3802E659:
  11892     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  11893     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  11894     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  11895 L_3802E663:
  11896     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
  11897     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
  11898     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11899     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11900     _flag_k = FK_NARROW(FK_CMP, 24);
  11901     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
  11902 L_3802E66A:
  11903     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
  11904     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
  11905     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
  11906     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
  11907     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
  11908     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
  11909     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
  11910     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
  11911     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11912     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11913     _flag_k = FK_CMP;
  11914     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
  11915 L_3802E683:
  11916     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
  11917 L_3802E686:
  11918     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
  11919     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
  11920     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
  11921     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
  11922     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11923     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11924     _flag_k = FK_CMP;
  11925     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
  11926 L_3802E694:
  11927     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
  11928     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
  11929 L_3802E699:
  11930     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
  11931     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
  11932     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  11933     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11934     _flag_k = FK_CMP;
  11935     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
  11936 L_3802E6A0:
  11937     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
  11938     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
  11939 L_3802E6A4:
  11940     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
  11941 L_3802E6A7:
  11942     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
  11943     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
  11944     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
  11945     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
  11946 L_3802E6B1:
  11947     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
  11948     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
  11949     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
  11950     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
  11951     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
  11952     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
  11953     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
  11954     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
  11955     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
  11956     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
  11957     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
  11958     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
  11959     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
  11960     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  11961     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11962     _flag_k = FK_CMP;
  11963     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
  11964 L_3802E6D7:
  11965     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
  11966 L_3802E6DA:
  11967     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
  11968     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
  11969     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
  11970     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
  11971     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  11972     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11973     _flag_k = FK_CMP;
  11974     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
  11975 L_3802E6E8:
  11976     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
  11977     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
  11978 L_3802E6ED:
  11979     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
  11980     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
  11981     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  11982     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11983     _flag_k = FK_CMP;
  11984     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
  11985 L_3802E6F5:
  11986     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
  11987     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
  11988 L_3802E6FA:
  11989     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
  11990 L_3802E6FC:
  11991     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  11992 L_3802E6FF:
  11993     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  11994 L_3802E702:
  11995     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  11996     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  11997     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  11998     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  11999     RECOMP_FLAGS_IN();
  12000     PUSH32(esp, esi); /* 0x3802E710: push esi */
  12001     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  12002     RECOMP_FLAGS_IN();
  12003     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  12004     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  12005     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12006     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12007     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  12008     _flag_k = FK_ADD;
  12009     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  12010     eax = eax - 1; /* 0x3802E71F: dec eax */
  12011     _flag_k = FK_DEC;
  12012     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  12013     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  12014     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  12015     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  12016     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  12017     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  12018     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  12019     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  12020     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  12021     RECOMP_REGS_OUT();
  12022 }
  12023 
  12024 void sub_3802E534(void) {
  12025     int _fpu_cmp = 0;
  12026     uint32_t _cf = 0;
  12027     int _df = 1;
  12028     uint32_t _flag_k = FK_NONE;
  12029     uint32_t _flag_a = 0, _flag_b = 0;
  12030     uint32_t _itail_tgt = 0;
  12031     RECOMP_REGS_LOCALS
  12032     RECOMP_ENTER(0x3802E534u);
  12033 
  12034     goto L_3802E534;
  12035 L_3802E4B4:
  12036     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
  12037     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12038     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12039     _flag_k = FK_NARROW(FK_CMP, 24);
  12040     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
  12041 L_3802E4BD:
  12042     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
  12043     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
  12044     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
  12045     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  12046     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12047     _flag_k = FK_CMP;
  12048     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
  12049 L_3802E4C6:
  12050     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
  12051     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
  12052     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
  12053     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  12054     _cf = 0;
  12055     _flag_k = FK_NARROW(FK_TEST, 24);
  12056     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
  12057 L_3802E4D0:
  12058     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
  12059     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
  12060     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
  12061     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
  12062     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
  12063     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
  12064     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
  12065     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
  12066     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
  12067     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12068     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12069     _flag_k = FK_CMP;
  12070     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
  12071 L_3802E4EC:
  12072     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
  12073 L_3802E4EF:
  12074     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
  12075     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
  12076     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
  12077     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
  12078     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12079     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12080     _flag_k = FK_CMP;
  12081     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
  12082 L_3802E4FD:
  12083     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
  12084     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
  12085 L_3802E502:
  12086     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
  12087     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
  12088     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  12089     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12090     _flag_k = FK_CMP;
  12091     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
  12092 L_3802E509:
  12093     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
  12094     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
  12095 L_3802E50D:
  12096     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
  12097 L_3802E510:
  12098     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
  12099     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
  12100     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
  12101     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
  12102 L_3802E51B:
  12103     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
  12104     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
  12105     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12106     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12107     _flag_k = FK_NARROW(FK_CMP, 24);
  12108     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
  12109 L_3802E526:
  12110     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
  12111     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
  12112     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12113     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12114     _flag_k = FK_NARROW(FK_CMP, 24);
  12115     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
  12116 L_3802E532:
  12117     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
  12118 L_3802E534:
  12119     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
  12120     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
  12121     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  12122     _cf = 0;
  12123     _flag_k = FK_NARROW(FK_TEST, 24);
  12124     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
  12125 L_3802E53B:
  12126     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
  12127     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
  12128     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
  12129     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
  12130     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
  12131     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
  12132     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
  12133     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
  12134     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
  12135     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12136     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12137     _flag_k = FK_CMP;
  12138     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
  12139 L_3802E557:
  12140     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
  12141 L_3802E55A:
  12142     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
  12143     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
  12144     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
  12145     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
  12146     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12147     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12148     _flag_k = FK_CMP;
  12149     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
  12150 L_3802E568:
  12151     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
  12152     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
  12153 L_3802E56D:
  12154     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
  12155     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
  12156     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  12157     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12158     _flag_k = FK_CMP;
  12159     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
  12160 L_3802E575:
  12161     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
  12162     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
  12163 L_3802E57A:
  12164     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
  12165 L_3802E57C:
  12166     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
  12167     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
  12168     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
  12169     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
  12170 L_3802E587:
  12171     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
  12172     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
  12173     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12174     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12175     _flag_k = FK_NARROW(FK_CMP, 24);
  12176     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
  12177 L_3802E593:
  12178     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
  12179     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
  12180     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12181     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12182     _flag_k = FK_NARROW(FK_CMP, 24);
  12183     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
  12184 L_3802E59E:
  12185     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
  12186     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
  12187     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
  12188     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
  12189     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  12190     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12191     _flag_k = FK_CMP;
  12192     RECOMP_BACKEDGE();
  12193     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
  12194 L_3802E5B1:
  12195     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
  12196 L_3802E5B6:
  12197     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
  12198     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
  12199     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12200     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12201     _flag_k = FK_NARROW(FK_CMP, 24);
  12202     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
  12203 L_3802E5BE:
  12204     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
  12205     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
  12206     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
  12207     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
  12208     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
  12209     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
  12210     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
  12211     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
  12212     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12213     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12214     _flag_k = FK_CMP;
  12215     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
  12216 L_3802E5D6:
  12217     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
  12218 L_3802E5D9:
  12219     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
  12220     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
  12221     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
  12222     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
  12223     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12224     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12225     _flag_k = FK_CMP;
  12226     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
  12227 L_3802E5E7:
  12228     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
  12229     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
  12230 L_3802E5EC:
  12231     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
  12232     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
  12233     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  12234     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12235     _flag_k = FK_CMP;
  12236     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
  12237 L_3802E5F4:
  12238     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
  12239     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
  12240 L_3802E5F9:
  12241     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
  12242 L_3802E5FB:
  12243     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  12244     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  12245     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  12246     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  12247 L_3802E607:
  12248     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  12249     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  12250     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  12251     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  12252     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  12253     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  12254     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  12255     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  12256     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  12257     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  12258     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  12259     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  12260     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  12261     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12262     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12263     _flag_k = FK_CMP;
  12264     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  12265 L_3802E62E:
  12266     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  12267 L_3802E631:
  12268     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  12269     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  12270     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  12271     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  12272     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12273     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12274     _flag_k = FK_CMP;
  12275     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  12276 L_3802E63F:
  12277     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  12278     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  12279     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  12280 L_3802E649:
  12281     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  12282     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  12283     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  12284     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12285     _flag_k = FK_CMP;
  12286     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  12287 L_3802E650:
  12288     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  12289     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  12290     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  12291 L_3802E659:
  12292     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  12293     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  12294     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  12295 L_3802E663:
  12296     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
  12297     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
  12298     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12299     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12300     _flag_k = FK_NARROW(FK_CMP, 24);
  12301     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
  12302 L_3802E66A:
  12303     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
  12304     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
  12305     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
  12306     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
  12307     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
  12308     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
  12309     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
  12310     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
  12311     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12312     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12313     _flag_k = FK_CMP;
  12314     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
  12315 L_3802E683:
  12316     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
  12317 L_3802E686:
  12318     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
  12319     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
  12320     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
  12321     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
  12322     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12323     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12324     _flag_k = FK_CMP;
  12325     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
  12326 L_3802E694:
  12327     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
  12328     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
  12329 L_3802E699:
  12330     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
  12331     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
  12332     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  12333     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12334     _flag_k = FK_CMP;
  12335     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
  12336 L_3802E6A0:
  12337     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
  12338     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
  12339 L_3802E6A4:
  12340     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
  12341 L_3802E6A7:
  12342     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
  12343     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
  12344     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
  12345     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
  12346 L_3802E6B1:
  12347     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
  12348     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
  12349     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
  12350     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
  12351     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
  12352     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
  12353     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
  12354     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
  12355     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
  12356     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
  12357     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
  12358     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
  12359     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
  12360     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12361     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12362     _flag_k = FK_CMP;
  12363     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
  12364 L_3802E6D7:
  12365     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
  12366 L_3802E6DA:
  12367     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
  12368     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
  12369     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
  12370     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
  12371     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12372     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12373     _flag_k = FK_CMP;
  12374     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
  12375 L_3802E6E8:
  12376     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
  12377     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
  12378 L_3802E6ED:
  12379     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
  12380     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
  12381     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  12382     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12383     _flag_k = FK_CMP;
  12384     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
  12385 L_3802E6F5:
  12386     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
  12387     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
  12388 L_3802E6FA:
  12389     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
  12390 L_3802E6FC:
  12391     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  12392 L_3802E6FF:
  12393     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  12394 L_3802E702:
  12395     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  12396     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  12397     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  12398     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  12399     RECOMP_FLAGS_IN();
  12400     PUSH32(esp, esi); /* 0x3802E710: push esi */
  12401     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  12402     RECOMP_FLAGS_IN();
  12403     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  12404     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  12405     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12406     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12407     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  12408     _flag_k = FK_ADD;
  12409     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  12410     eax = eax - 1; /* 0x3802E71F: dec eax */
  12411     _flag_k = FK_DEC;
  12412     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  12413     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  12414     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  12415     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  12416     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  12417     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  12418     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  12419     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  12420     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  12421     RECOMP_REGS_OUT();
  12422 }
  12423 
  12424 void sub_3802E57C(void) {
  12425     int _fpu_cmp = 0;
  12426     uint32_t _cf = 0;
  12427     int _df = 1;
  12428     uint32_t _flag_k = FK_NONE;
  12429     uint32_t _flag_a = 0, _flag_b = 0;
  12430     uint32_t _itail_tgt = 0;
  12431     RECOMP_REGS_LOCALS
  12432     RECOMP_ENTER(0x3802E57Cu);
  12433 
  12434     goto L_3802E57C;
  12435 L_3802E4B4:
  12436     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
  12437     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12438     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12439     _flag_k = FK_NARROW(FK_CMP, 24);
  12440     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
  12441 L_3802E4BD:
  12442     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
  12443     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
  12444     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
  12445     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  12446     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12447     _flag_k = FK_CMP;
  12448     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
  12449 L_3802E4C6:
  12450     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
  12451     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
  12452     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
  12453     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  12454     _cf = 0;
  12455     _flag_k = FK_NARROW(FK_TEST, 24);
  12456     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
  12457 L_3802E4D0:
  12458     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
  12459     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
  12460     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
  12461     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
  12462     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
  12463     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
  12464     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
  12465     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
  12466     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
  12467     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12468     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12469     _flag_k = FK_CMP;
  12470     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
  12471 L_3802E4EC:
  12472     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
  12473 L_3802E4EF:
  12474     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
  12475     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
  12476     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
  12477     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
  12478     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12479     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12480     _flag_k = FK_CMP;
  12481     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
  12482 L_3802E4FD:
  12483     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
  12484     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
  12485 L_3802E502:
  12486     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
  12487     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
  12488     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  12489     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12490     _flag_k = FK_CMP;
  12491     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
  12492 L_3802E509:
  12493     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
  12494     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
  12495 L_3802E50D:
  12496     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
  12497 L_3802E510:
  12498     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
  12499     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
  12500     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
  12501     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
  12502 L_3802E51B:
  12503     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
  12504     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
  12505     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12506     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12507     _flag_k = FK_NARROW(FK_CMP, 24);
  12508     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
  12509 L_3802E526:
  12510     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
  12511     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
  12512     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12513     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12514     _flag_k = FK_NARROW(FK_CMP, 24);
  12515     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
  12516 L_3802E532:
  12517     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
  12518 L_3802E534:
  12519     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
  12520     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
  12521     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  12522     _cf = 0;
  12523     _flag_k = FK_NARROW(FK_TEST, 24);
  12524     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
  12525 L_3802E53B:
  12526     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
  12527     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
  12528     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
  12529     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
  12530     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
  12531     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
  12532     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
  12533     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
  12534     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
  12535     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12536     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12537     _flag_k = FK_CMP;
  12538     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
  12539 L_3802E557:
  12540     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
  12541 L_3802E55A:
  12542     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
  12543     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
  12544     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
  12545     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
  12546     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12547     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12548     _flag_k = FK_CMP;
  12549     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
  12550 L_3802E568:
  12551     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
  12552     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
  12553 L_3802E56D:
  12554     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
  12555     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
  12556     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  12557     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12558     _flag_k = FK_CMP;
  12559     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
  12560 L_3802E575:
  12561     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
  12562     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
  12563 L_3802E57A:
  12564     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
  12565 L_3802E57C:
  12566     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
  12567     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
  12568     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
  12569     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
  12570 L_3802E587:
  12571     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
  12572     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
  12573     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12574     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12575     _flag_k = FK_NARROW(FK_CMP, 24);
  12576     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
  12577 L_3802E593:
  12578     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
  12579     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
  12580     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12581     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12582     _flag_k = FK_NARROW(FK_CMP, 24);
  12583     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
  12584 L_3802E59E:
  12585     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
  12586     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
  12587     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
  12588     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
  12589     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  12590     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12591     _flag_k = FK_CMP;
  12592     RECOMP_BACKEDGE();
  12593     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
  12594 L_3802E5B1:
  12595     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
  12596 L_3802E5B6:
  12597     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
  12598     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
  12599     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12600     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12601     _flag_k = FK_NARROW(FK_CMP, 24);
  12602     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
  12603 L_3802E5BE:
  12604     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
  12605     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
  12606     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
  12607     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
  12608     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
  12609     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
  12610     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
  12611     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
  12612     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12613     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12614     _flag_k = FK_CMP;
  12615     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
  12616 L_3802E5D6:
  12617     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
  12618 L_3802E5D9:
  12619     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
  12620     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
  12621     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
  12622     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
  12623     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12624     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12625     _flag_k = FK_CMP;
  12626     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
  12627 L_3802E5E7:
  12628     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
  12629     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
  12630 L_3802E5EC:
  12631     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
  12632     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
  12633     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  12634     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12635     _flag_k = FK_CMP;
  12636     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
  12637 L_3802E5F4:
  12638     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
  12639     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
  12640 L_3802E5F9:
  12641     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
  12642 L_3802E5FB:
  12643     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  12644     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  12645     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  12646     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  12647 L_3802E607:
  12648     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  12649     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  12650     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  12651     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  12652     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  12653     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  12654     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  12655     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  12656     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  12657     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  12658     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  12659     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  12660     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  12661     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12662     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12663     _flag_k = FK_CMP;
  12664     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  12665 L_3802E62E:
  12666     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  12667 L_3802E631:
  12668     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  12669     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  12670     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  12671     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  12672     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12673     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12674     _flag_k = FK_CMP;
  12675     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  12676 L_3802E63F:
  12677     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  12678     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  12679     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  12680 L_3802E649:
  12681     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  12682     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  12683     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  12684     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12685     _flag_k = FK_CMP;
  12686     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  12687 L_3802E650:
  12688     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  12689     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  12690     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  12691 L_3802E659:
  12692     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  12693     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  12694     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  12695 L_3802E663:
  12696     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
  12697     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
  12698     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12699     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12700     _flag_k = FK_NARROW(FK_CMP, 24);
  12701     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
  12702 L_3802E66A:
  12703     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
  12704     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
  12705     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
  12706     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
  12707     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
  12708     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
  12709     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
  12710     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
  12711     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12712     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12713     _flag_k = FK_CMP;
  12714     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
  12715 L_3802E683:
  12716     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
  12717 L_3802E686:
  12718     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
  12719     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
  12720     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
  12721     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
  12722     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12723     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12724     _flag_k = FK_CMP;
  12725     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
  12726 L_3802E694:
  12727     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
  12728     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
  12729 L_3802E699:
  12730     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
  12731     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
  12732     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  12733     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12734     _flag_k = FK_CMP;
  12735     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
  12736 L_3802E6A0:
  12737     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
  12738     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
  12739 L_3802E6A4:
  12740     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
  12741 L_3802E6A7:
  12742     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
  12743     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
  12744     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
  12745     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
  12746 L_3802E6B1:
  12747     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
  12748     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
  12749     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
  12750     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
  12751     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
  12752     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
  12753     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
  12754     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
  12755     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
  12756     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
  12757     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
  12758     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
  12759     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
  12760     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12761     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12762     _flag_k = FK_CMP;
  12763     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
  12764 L_3802E6D7:
  12765     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
  12766 L_3802E6DA:
  12767     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
  12768     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
  12769     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
  12770     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
  12771     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12772     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12773     _flag_k = FK_CMP;
  12774     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
  12775 L_3802E6E8:
  12776     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
  12777     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
  12778 L_3802E6ED:
  12779     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
  12780     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
  12781     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  12782     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12783     _flag_k = FK_CMP;
  12784     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
  12785 L_3802E6F5:
  12786     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
  12787     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
  12788 L_3802E6FA:
  12789     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
  12790 L_3802E6FC:
  12791     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  12792 L_3802E6FF:
  12793     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  12794 L_3802E702:
  12795     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  12796     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  12797     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  12798     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  12799     RECOMP_FLAGS_IN();
  12800     PUSH32(esp, esi); /* 0x3802E710: push esi */
  12801     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  12802     RECOMP_FLAGS_IN();
  12803     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  12804     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  12805     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12806     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12807     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  12808     _flag_k = FK_ADD;
  12809     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  12810     eax = eax - 1; /* 0x3802E71F: dec eax */
  12811     _flag_k = FK_DEC;
  12812     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  12813     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  12814     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  12815     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  12816     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  12817     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  12818     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  12819     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  12820     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  12821     RECOMP_REGS_OUT();
  12822 }
  12823 
  12824 void sub_3802E587(void) {
  12825     int _fpu_cmp = 0;
  12826     uint32_t _cf = 0;
  12827     int _df = 1;
  12828     uint32_t _flag_k = FK_NONE;
  12829     uint32_t _flag_a = 0, _flag_b = 0;
  12830     uint32_t _itail_tgt = 0;
  12831     RECOMP_REGS_LOCALS
  12832     RECOMP_ENTER(0x3802E587u);
  12833 
  12834     goto L_3802E587;
  12835 L_3802E4B4:
  12836     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
  12837     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12838     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12839     _flag_k = FK_NARROW(FK_CMP, 24);
  12840     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
  12841 L_3802E4BD:
  12842     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
  12843     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
  12844     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
  12845     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  12846     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12847     _flag_k = FK_CMP;
  12848     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
  12849 L_3802E4C6:
  12850     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
  12851     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
  12852     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
  12853     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  12854     _cf = 0;
  12855     _flag_k = FK_NARROW(FK_TEST, 24);
  12856     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
  12857 L_3802E4D0:
  12858     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
  12859     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
  12860     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
  12861     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
  12862     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
  12863     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
  12864     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
  12865     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
  12866     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
  12867     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12868     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12869     _flag_k = FK_CMP;
  12870     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
  12871 L_3802E4EC:
  12872     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
  12873 L_3802E4EF:
  12874     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
  12875     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
  12876     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
  12877     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
  12878     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12879     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12880     _flag_k = FK_CMP;
  12881     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
  12882 L_3802E4FD:
  12883     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
  12884     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
  12885 L_3802E502:
  12886     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
  12887     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
  12888     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  12889     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12890     _flag_k = FK_CMP;
  12891     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
  12892 L_3802E509:
  12893     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
  12894     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
  12895 L_3802E50D:
  12896     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
  12897 L_3802E510:
  12898     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
  12899     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
  12900     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
  12901     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
  12902 L_3802E51B:
  12903     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
  12904     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
  12905     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12906     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12907     _flag_k = FK_NARROW(FK_CMP, 24);
  12908     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
  12909 L_3802E526:
  12910     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
  12911     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
  12912     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12913     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12914     _flag_k = FK_NARROW(FK_CMP, 24);
  12915     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
  12916 L_3802E532:
  12917     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
  12918 L_3802E534:
  12919     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
  12920     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
  12921     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  12922     _cf = 0;
  12923     _flag_k = FK_NARROW(FK_TEST, 24);
  12924     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
  12925 L_3802E53B:
  12926     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
  12927     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
  12928     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
  12929     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
  12930     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
  12931     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
  12932     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
  12933     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
  12934     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
  12935     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  12936     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12937     _flag_k = FK_CMP;
  12938     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
  12939 L_3802E557:
  12940     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
  12941 L_3802E55A:
  12942     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
  12943     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
  12944     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
  12945     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
  12946     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  12947     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12948     _flag_k = FK_CMP;
  12949     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
  12950 L_3802E568:
  12951     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
  12952     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
  12953 L_3802E56D:
  12954     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
  12955     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
  12956     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  12957     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12958     _flag_k = FK_CMP;
  12959     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
  12960 L_3802E575:
  12961     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
  12962     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
  12963 L_3802E57A:
  12964     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
  12965 L_3802E57C:
  12966     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
  12967     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
  12968     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
  12969     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
  12970 L_3802E587:
  12971     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
  12972     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
  12973     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12974     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12975     _flag_k = FK_NARROW(FK_CMP, 24);
  12976     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
  12977 L_3802E593:
  12978     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
  12979     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
  12980     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  12981     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12982     _flag_k = FK_NARROW(FK_CMP, 24);
  12983     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
  12984 L_3802E59E:
  12985     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
  12986     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
  12987     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
  12988     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
  12989     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  12990     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12991     _flag_k = FK_CMP;
  12992     RECOMP_BACKEDGE();
  12993     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
  12994 L_3802E5B1:
  12995     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
  12996 L_3802E5B6:
  12997     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
  12998     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
  12999     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  13000     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13001     _flag_k = FK_NARROW(FK_CMP, 24);
  13002     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
  13003 L_3802E5BE:
  13004     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
  13005     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
  13006     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
  13007     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
  13008     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
  13009     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
  13010     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
  13011     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
  13012     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13013     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13014     _flag_k = FK_CMP;
  13015     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
  13016 L_3802E5D6:
  13017     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
  13018 L_3802E5D9:
  13019     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
  13020     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
  13021     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
  13022     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
  13023     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13024     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13025     _flag_k = FK_CMP;
  13026     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
  13027 L_3802E5E7:
  13028     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
  13029     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
  13030 L_3802E5EC:
  13031     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
  13032     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
  13033     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  13034     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13035     _flag_k = FK_CMP;
  13036     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
  13037 L_3802E5F4:
  13038     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
  13039     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
  13040 L_3802E5F9:
  13041     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
  13042 L_3802E5FB:
  13043     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  13044     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  13045     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  13046     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  13047 L_3802E607:
  13048     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  13049     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  13050     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  13051     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  13052     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  13053     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  13054     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  13055     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  13056     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  13057     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  13058     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  13059     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  13060     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  13061     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13062     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13063     _flag_k = FK_CMP;
  13064     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  13065 L_3802E62E:
  13066     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  13067 L_3802E631:
  13068     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  13069     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  13070     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  13071     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  13072     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13073     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13074     _flag_k = FK_CMP;
  13075     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  13076 L_3802E63F:
  13077     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  13078     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  13079     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  13080 L_3802E649:
  13081     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  13082     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  13083     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  13084     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13085     _flag_k = FK_CMP;
  13086     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  13087 L_3802E650:
  13088     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  13089     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  13090     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  13091 L_3802E659:
  13092     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  13093     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  13094     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  13095 L_3802E663:
  13096     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
  13097     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
  13098     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  13099     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13100     _flag_k = FK_NARROW(FK_CMP, 24);
  13101     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
  13102 L_3802E66A:
  13103     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
  13104     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
  13105     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
  13106     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
  13107     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
  13108     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
  13109     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
  13110     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
  13111     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13112     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13113     _flag_k = FK_CMP;
  13114     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
  13115 L_3802E683:
  13116     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
  13117 L_3802E686:
  13118     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
  13119     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
  13120     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
  13121     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
  13122     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13123     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13124     _flag_k = FK_CMP;
  13125     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
  13126 L_3802E694:
  13127     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
  13128     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
  13129 L_3802E699:
  13130     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
  13131     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
  13132     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  13133     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13134     _flag_k = FK_CMP;
  13135     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
  13136 L_3802E6A0:
  13137     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
  13138     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
  13139 L_3802E6A4:
  13140     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
  13141 L_3802E6A7:
  13142     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
  13143     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
  13144     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
  13145     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
  13146 L_3802E6B1:
  13147     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
  13148     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
  13149     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
  13150     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
  13151     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
  13152     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
  13153     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
  13154     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
  13155     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
  13156     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
  13157     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
  13158     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
  13159     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
  13160     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13161     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13162     _flag_k = FK_CMP;
  13163     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
  13164 L_3802E6D7:
  13165     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
  13166 L_3802E6DA:
  13167     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
  13168     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
  13169     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
  13170     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
  13171     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13172     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13173     _flag_k = FK_CMP;
  13174     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
  13175 L_3802E6E8:
  13176     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
  13177     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
  13178 L_3802E6ED:
  13179     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
  13180     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
  13181     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  13182     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13183     _flag_k = FK_CMP;
  13184     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
  13185 L_3802E6F5:
  13186     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
  13187     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
  13188 L_3802E6FA:
  13189     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
  13190 L_3802E6FC:
  13191     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  13192 L_3802E6FF:
  13193     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  13194 L_3802E702:
  13195     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  13196     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  13197     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  13198     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  13199     RECOMP_FLAGS_IN();
  13200     PUSH32(esp, esi); /* 0x3802E710: push esi */
  13201     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  13202     RECOMP_FLAGS_IN();
  13203     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  13204     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  13205     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  13206     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13207     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  13208     _flag_k = FK_ADD;
  13209     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  13210     eax = eax - 1; /* 0x3802E71F: dec eax */
  13211     _flag_k = FK_DEC;
  13212     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  13213     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  13214     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  13215     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  13216     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  13217     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  13218     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  13219     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  13220     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  13221     RECOMP_REGS_OUT();
  13222 }
  13223 
  13224 void sub_3802E59E(void) {
  13225     int _fpu_cmp = 0;
  13226     uint32_t _cf = 0;
  13227     int _df = 1;
  13228     uint32_t _flag_k = FK_NONE;
  13229     uint32_t _flag_a = 0, _flag_b = 0;
  13230     uint32_t _itail_tgt = 0;
  13231     RECOMP_REGS_LOCALS
  13232     RECOMP_ENTER(0x3802E59Eu);
  13233 
  13234     goto L_3802E59E;
  13235 L_3802E4B4:
  13236     /* cmp MEM8(eax + 0x24), LO8(ebx) */ /* 0x3802E4B4: cmp byte ptr [eax + 0x24], bl */
  13237     _flag_a = (uint32_t)(MEM8(eax + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  13238     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13239     _flag_k = FK_NARROW(FK_CMP, 24);
  13240     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E702; /* 0x3802E4B7: jne 0x3802e702 */
  13241 L_3802E4BD:
  13242     edx = MEM32(eax + 0x4); /* 0x3802E4BD: mov edx, dword ptr [eax + 4] */
  13243     ecx = MEM32(edx); /* 0x3802E4C0: mov ecx, dword ptr [edx] */
  13244     /* cmp eax, ecx */ /* 0x3802E4C2: cmp eax, ecx */
  13245     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  13246     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13247     _flag_k = FK_CMP;
  13248     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E534; /* 0x3802E4C4: jne 0x3802e534 */
  13249 L_3802E4C6:
  13250     ecx = MEM32(edx + 0x8); /* 0x3802E4C6: mov ecx, dword ptr [edx + 8] */
  13251     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E4C9: mov dl, byte ptr [ecx + 0x24] */
  13252     /* test LO8(edx), LO8(edx) */ /* 0x3802E4CC: test dl, dl */
  13253     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  13254     _cf = 0;
  13255     _flag_k = FK_NARROW(FK_TEST, 24);
  13256     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E51B; /* 0x3802E4CE: jne 0x3802e51b */
  13257 L_3802E4D0:
  13258     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E4D0: mov byte ptr [ecx + 0x24], bl */
  13259     edx = MEM32(eax + 0x4); /* 0x3802E4D3: mov edx, dword ptr [eax + 4] */
  13260     MEM8(edx + 0x24) = (uint8_t)(0); /* 0x3802E4D6: mov byte ptr [edx + 0x24], 0 */
  13261     ecx = MEM32(eax + 0x4); /* 0x3802E4DA: mov ecx, dword ptr [eax + 4] */
  13262     edx = MEM32(ecx + 0x8); /* 0x3802E4DD: mov edx, dword ptr [ecx + 8] */
  13263     esi = MEM32(edx); /* 0x3802E4E0: mov esi, dword ptr [edx] */
  13264     MEM32(ecx + 0x8) = esi; /* 0x3802E4E2: mov dword ptr [ecx + 8], esi */
  13265     esi = MEM32(edx); /* 0x3802E4E5: mov esi, dword ptr [edx] */
  13266     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E4E7: cmp esi, dword ptr [edi + 8] */
  13267     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13268     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13269     _flag_k = FK_CMP;
  13270     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E4EF; /* 0x3802E4EA: je 0x3802e4ef */
  13271 L_3802E4EC:
  13272     MEM32(esi + 0x4) = ecx; /* 0x3802E4EC: mov dword ptr [esi + 4], ecx */
  13273 L_3802E4EF:
  13274     esi = MEM32(ecx + 0x4); /* 0x3802E4EF: mov esi, dword ptr [ecx + 4] */
  13275     MEM32(edx + 0x4) = esi; /* 0x3802E4F2: mov dword ptr [edx + 4], esi */
  13276     esi = MEM32(edi + 0x4); /* 0x3802E4F5: mov esi, dword ptr [edi + 4] */
  13277     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E4F8: cmp ecx, dword ptr [esi + 4] */
  13278     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13279     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13280     _flag_k = FK_CMP;
  13281     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E502; /* 0x3802E4FB: jne 0x3802e502 */
  13282 L_3802E4FD:
  13283     MEM32(esi + 0x4) = edx; /* 0x3802E4FD: mov dword ptr [esi + 4], edx */
  13284     goto L_3802E510; /* 0x3802E500: jmp 0x3802e510 */
  13285 L_3802E502:
  13286     esi = MEM32(ecx + 0x4); /* 0x3802E502: mov esi, dword ptr [ecx + 4] */
  13287     /* cmp ecx, MEM32(esi) */ /* 0x3802E505: cmp ecx, dword ptr [esi] */
  13288     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  13289     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13290     _flag_k = FK_CMP;
  13291     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E50D; /* 0x3802E507: jne 0x3802e50d */
  13292 L_3802E509:
  13293     MEM32(esi) = edx; /* 0x3802E509: mov dword ptr [esi], edx */
  13294     goto L_3802E510; /* 0x3802E50B: jmp 0x3802e510 */
  13295 L_3802E50D:
  13296     MEM32(esi + 0x8) = edx; /* 0x3802E50D: mov dword ptr [esi + 8], edx */
  13297 L_3802E510:
  13298     MEM32(edx) = ecx; /* 0x3802E510: mov dword ptr [edx], ecx */
  13299     MEM32(ecx + 0x4) = edx; /* 0x3802E512: mov dword ptr [ecx + 4], edx */
  13300     ecx = MEM32(eax + 0x4); /* 0x3802E515: mov ecx, dword ptr [eax + 4] */
  13301     ecx = MEM32(ecx + 0x8); /* 0x3802E518: mov ecx, dword ptr [ecx + 8] */
  13302 L_3802E51B:
  13303     edx = MEM32(ecx); /* 0x3802E51B: mov edx, dword ptr [ecx] */
  13304     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E51D: cmp byte ptr [edx + 0x24], bl */
  13305     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  13306     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13307     _flag_k = FK_NARROW(FK_CMP, 24);
  13308     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E520: jne 0x3802e5b6 */
  13309 L_3802E526:
  13310     edx = MEM32(ecx + 0x8); /* 0x3802E526: mov edx, dword ptr [ecx + 8] */
  13311     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E529: cmp byte ptr [edx + 0x24], bl */
  13312     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  13313     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13314     _flag_k = FK_NARROW(FK_CMP, 24);
  13315     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5B6; /* 0x3802E52C: jne 0x3802e5b6 */
  13316 L_3802E532:
  13317     goto L_3802E59E; /* 0x3802E532: jmp 0x3802e59e */
  13318 L_3802E534:
  13319     SET_LO8(edx, MEM8(ecx + 0x24)); /* 0x3802E534: mov dl, byte ptr [ecx + 0x24] */
  13320     /* test LO8(edx), LO8(edx) */ /* 0x3802E537: test dl, dl */
  13321     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  13322     _cf = 0;
  13323     _flag_k = FK_NARROW(FK_TEST, 24);
  13324     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E587; /* 0x3802E539: jne 0x3802e587 */
  13325 L_3802E53B:
  13326     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E53B: mov byte ptr [ecx + 0x24], bl */
  13327     ecx = MEM32(eax + 0x4); /* 0x3802E53E: mov ecx, dword ptr [eax + 4] */
  13328     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E541: mov byte ptr [ecx + 0x24], 0 */
  13329     ecx = MEM32(eax + 0x4); /* 0x3802E545: mov ecx, dword ptr [eax + 4] */
  13330     edx = MEM32(ecx); /* 0x3802E548: mov edx, dword ptr [ecx] */
  13331     esi = MEM32(edx + 0x8); /* 0x3802E54A: mov esi, dword ptr [edx + 8] */
  13332     MEM32(ecx) = esi; /* 0x3802E54D: mov dword ptr [ecx], esi */
  13333     esi = MEM32(edx + 0x8); /* 0x3802E54F: mov esi, dword ptr [edx + 8] */
  13334     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E552: cmp esi, dword ptr [edi + 8] */
  13335     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13336     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13337     _flag_k = FK_CMP;
  13338     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E55A; /* 0x3802E555: je 0x3802e55a */
  13339 L_3802E557:
  13340     MEM32(esi + 0x4) = ecx; /* 0x3802E557: mov dword ptr [esi + 4], ecx */
  13341 L_3802E55A:
  13342     esi = MEM32(ecx + 0x4); /* 0x3802E55A: mov esi, dword ptr [ecx + 4] */
  13343     MEM32(edx + 0x4) = esi; /* 0x3802E55D: mov dword ptr [edx + 4], esi */
  13344     esi = MEM32(edi + 0x4); /* 0x3802E560: mov esi, dword ptr [edi + 4] */
  13345     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E563: cmp ecx, dword ptr [esi + 4] */
  13346     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13347     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13348     _flag_k = FK_CMP;
  13349     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E56D; /* 0x3802E566: jne 0x3802e56d */
  13350 L_3802E568:
  13351     MEM32(esi + 0x4) = edx; /* 0x3802E568: mov dword ptr [esi + 4], edx */
  13352     goto L_3802E57C; /* 0x3802E56B: jmp 0x3802e57c */
  13353 L_3802E56D:
  13354     esi = MEM32(ecx + 0x4); /* 0x3802E56D: mov esi, dword ptr [ecx + 4] */
  13355     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E570: cmp ecx, dword ptr [esi + 8] */
  13356     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  13357     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13358     _flag_k = FK_CMP;
  13359     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E57A; /* 0x3802E573: jne 0x3802e57a */
  13360 L_3802E575:
  13361     MEM32(esi + 0x8) = edx; /* 0x3802E575: mov dword ptr [esi + 8], edx */
  13362     goto L_3802E57C; /* 0x3802E578: jmp 0x3802e57c */
  13363 L_3802E57A:
  13364     MEM32(esi) = edx; /* 0x3802E57A: mov dword ptr [esi], edx */
  13365 L_3802E57C:
  13366     MEM32(edx + 0x8) = ecx; /* 0x3802E57C: mov dword ptr [edx + 8], ecx */
  13367     MEM32(ecx + 0x4) = edx; /* 0x3802E57F: mov dword ptr [ecx + 4], edx */
  13368     edx = MEM32(eax + 0x4); /* 0x3802E582: mov edx, dword ptr [eax + 4] */
  13369     ecx = MEM32(edx); /* 0x3802E585: mov ecx, dword ptr [edx] */
  13370 L_3802E587:
  13371     edx = MEM32(ecx + 0x8); /* 0x3802E587: mov edx, dword ptr [ecx + 8] */
  13372     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E58A: cmp byte ptr [edx + 0x24], bl */
  13373     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  13374     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13375     _flag_k = FK_NARROW(FK_CMP, 24);
  13376     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E58D: jne 0x3802e663 */
  13377 L_3802E593:
  13378     edx = MEM32(ecx); /* 0x3802E593: mov edx, dword ptr [ecx] */
  13379     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E595: cmp byte ptr [edx + 0x24], bl */
  13380     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  13381     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13382     _flag_k = FK_NARROW(FK_CMP, 24);
  13383     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E663; /* 0x3802E598: jne 0x3802e663 */
  13384 L_3802E59E:
  13385     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E59E: mov byte ptr [ecx + 0x24], 0 */
  13386     ecx = MEM32(edi + 0x4); /* 0x3802E5A2: mov ecx, dword ptr [edi + 4] */
  13387     eax = MEM32(eax + 0x4); /* 0x3802E5A5: mov eax, dword ptr [eax + 4] */
  13388     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3802E5A8: cmp eax, dword ptr [ecx + 4] */
  13389     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  13390     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13391     _flag_k = FK_CMP;
  13392     RECOMP_BACKEDGE();
  13393     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E4B4; /* 0x3802E5AB: jne 0x3802e4b4 */
  13394 L_3802E5B1:
  13395     goto L_3802E702; /* 0x3802E5B1: jmp 0x3802e702 */
  13396 L_3802E5B6:
  13397     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
  13398     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
  13399     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  13400     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13401     _flag_k = FK_NARROW(FK_CMP, 24);
  13402     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
  13403 L_3802E5BE:
  13404     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
  13405     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
  13406     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
  13407     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
  13408     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
  13409     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
  13410     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
  13411     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
  13412     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13413     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13414     _flag_k = FK_CMP;
  13415     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
  13416 L_3802E5D6:
  13417     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
  13418 L_3802E5D9:
  13419     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
  13420     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
  13421     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
  13422     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
  13423     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13424     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13425     _flag_k = FK_CMP;
  13426     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
  13427 L_3802E5E7:
  13428     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
  13429     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
  13430 L_3802E5EC:
  13431     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
  13432     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
  13433     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  13434     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13435     _flag_k = FK_CMP;
  13436     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
  13437 L_3802E5F4:
  13438     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
  13439     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
  13440 L_3802E5F9:
  13441     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
  13442 L_3802E5FB:
  13443     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  13444     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  13445     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  13446     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  13447 L_3802E607:
  13448     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  13449     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  13450     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  13451     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  13452     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  13453     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  13454     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  13455     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  13456     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  13457     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  13458     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  13459     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  13460     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  13461     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13462     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13463     _flag_k = FK_CMP;
  13464     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  13465 L_3802E62E:
  13466     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  13467 L_3802E631:
  13468     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  13469     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  13470     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  13471     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  13472     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13473     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13474     _flag_k = FK_CMP;
  13475     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  13476 L_3802E63F:
  13477     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  13478     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  13479     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  13480 L_3802E649:
  13481     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  13482     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  13483     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  13484     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13485     _flag_k = FK_CMP;
  13486     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  13487 L_3802E650:
  13488     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  13489     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  13490     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  13491 L_3802E659:
  13492     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  13493     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  13494     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  13495 L_3802E663:
  13496     edx = MEM32(ecx); /* 0x3802E663: mov edx, dword ptr [ecx] */
  13497     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E665: cmp byte ptr [edx + 0x24], bl */
  13498     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  13499     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13500     _flag_k = FK_NARROW(FK_CMP, 24);
  13501     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6B1; /* 0x3802E668: jne 0x3802e6b1 */
  13502 L_3802E66A:
  13503     edx = MEM32(ecx + 0x8); /* 0x3802E66A: mov edx, dword ptr [ecx + 8] */
  13504     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E66D: mov byte ptr [edx + 0x24], bl */
  13505     edx = MEM32(ecx + 0x8); /* 0x3802E670: mov edx, dword ptr [ecx + 8] */
  13506     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E673: mov byte ptr [ecx + 0x24], 0 */
  13507     esi = MEM32(edx); /* 0x3802E677: mov esi, dword ptr [edx] */
  13508     MEM32(ecx + 0x8) = esi; /* 0x3802E679: mov dword ptr [ecx + 8], esi */
  13509     esi = MEM32(edx); /* 0x3802E67C: mov esi, dword ptr [edx] */
  13510     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E67E: cmp esi, dword ptr [edi + 8] */
  13511     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13512     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13513     _flag_k = FK_CMP;
  13514     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E686; /* 0x3802E681: je 0x3802e686 */
  13515 L_3802E683:
  13516     MEM32(esi + 0x4) = ecx; /* 0x3802E683: mov dword ptr [esi + 4], ecx */
  13517 L_3802E686:
  13518     esi = MEM32(ecx + 0x4); /* 0x3802E686: mov esi, dword ptr [ecx + 4] */
  13519     MEM32(edx + 0x4) = esi; /* 0x3802E689: mov dword ptr [edx + 4], esi */
  13520     esi = MEM32(edi + 0x4); /* 0x3802E68C: mov esi, dword ptr [edi + 4] */
  13521     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E68F: cmp ecx, dword ptr [esi + 4] */
  13522     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13523     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13524     _flag_k = FK_CMP;
  13525     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E699; /* 0x3802E692: jne 0x3802e699 */
  13526 L_3802E694:
  13527     MEM32(esi + 0x4) = edx; /* 0x3802E694: mov dword ptr [esi + 4], edx */
  13528     goto L_3802E6A7; /* 0x3802E697: jmp 0x3802e6a7 */
  13529 L_3802E699:
  13530     esi = MEM32(ecx + 0x4); /* 0x3802E699: mov esi, dword ptr [ecx + 4] */
  13531     /* cmp ecx, MEM32(esi) */ /* 0x3802E69C: cmp ecx, dword ptr [esi] */
  13532     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  13533     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13534     _flag_k = FK_CMP;
  13535     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6A4; /* 0x3802E69E: jne 0x3802e6a4 */
  13536 L_3802E6A0:
  13537     MEM32(esi) = edx; /* 0x3802E6A0: mov dword ptr [esi], edx */
  13538     goto L_3802E6A7; /* 0x3802E6A2: jmp 0x3802e6a7 */
  13539 L_3802E6A4:
  13540     MEM32(esi + 0x8) = edx; /* 0x3802E6A4: mov dword ptr [esi + 8], edx */
  13541 L_3802E6A7:
  13542     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
  13543     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
  13544     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
  13545     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
  13546 L_3802E6B1:
  13547     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
  13548     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
  13549     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
  13550     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
  13551     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
  13552     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
  13553     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
  13554     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
  13555     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
  13556     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
  13557     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
  13558     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
  13559     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
  13560     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13561     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13562     _flag_k = FK_CMP;
  13563     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
  13564 L_3802E6D7:
  13565     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
  13566 L_3802E6DA:
  13567     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
  13568     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
  13569     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
  13570     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
  13571     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13572     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13573     _flag_k = FK_CMP;
  13574     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
  13575 L_3802E6E8:
  13576     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
  13577     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
  13578 L_3802E6ED:
  13579     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
  13580     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
  13581     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  13582     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13583     _flag_k = FK_CMP;
  13584     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
  13585 L_3802E6F5:
  13586     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
  13587     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
  13588 L_3802E6FA:
  13589     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
  13590 L_3802E6FC:
  13591     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  13592 L_3802E6FF:
  13593     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  13594 L_3802E702:
  13595     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  13596     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  13597     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  13598     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  13599     RECOMP_FLAGS_IN();
  13600     PUSH32(esp, esi); /* 0x3802E710: push esi */
  13601     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  13602     RECOMP_FLAGS_IN();
  13603     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  13604     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  13605     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  13606     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13607     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  13608     _flag_k = FK_ADD;
  13609     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  13610     eax = eax - 1; /* 0x3802E71F: dec eax */
  13611     _flag_k = FK_DEC;
  13612     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  13613     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  13614     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  13615     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  13616     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  13617     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  13618     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  13619     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  13620     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  13621     RECOMP_REGS_OUT();
  13622 }
  13623 
  13624 void sub_3802E5B6(void) {
  13625     int _fpu_cmp = 0;
  13626     uint32_t _cf = 0;
  13627     int _df = 1;
  13628     uint32_t _flag_k = FK_NONE;
  13629     uint32_t _flag_a = 0, _flag_b = 0;
  13630     uint32_t _itail_tgt = 0;
  13631     RECOMP_REGS_LOCALS
  13632     RECOMP_ENTER(0x3802E5B6u);
  13633 
  13634 L_3802E5B6:
  13635     edx = MEM32(ecx + 0x8); /* 0x3802E5B6: mov edx, dword ptr [ecx + 8] */
  13636     /* cmp MEM8(edx + 0x24), LO8(ebx) */ /* 0x3802E5B9: cmp byte ptr [edx + 0x24], bl */
  13637     _flag_a = (uint32_t)(MEM8(edx + 0x24)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  13638     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13639     _flag_k = FK_NARROW(FK_CMP, 24);
  13640     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E607; /* 0x3802E5BC: jne 0x3802e607 */
  13641 L_3802E5BE:
  13642     edx = MEM32(ecx); /* 0x3802E5BE: mov edx, dword ptr [ecx] */
  13643     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E5C0: mov byte ptr [edx + 0x24], bl */
  13644     edx = MEM32(ecx); /* 0x3802E5C3: mov edx, dword ptr [ecx] */
  13645     MEM8(ecx + 0x24) = (uint8_t)(0); /* 0x3802E5C5: mov byte ptr [ecx + 0x24], 0 */
  13646     esi = MEM32(edx + 0x8); /* 0x3802E5C9: mov esi, dword ptr [edx + 8] */
  13647     MEM32(ecx) = esi; /* 0x3802E5CC: mov dword ptr [ecx], esi */
  13648     esi = MEM32(edx + 0x8); /* 0x3802E5CE: mov esi, dword ptr [edx + 8] */
  13649     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E5D1: cmp esi, dword ptr [edi + 8] */
  13650     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13651     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13652     _flag_k = FK_CMP;
  13653     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E5D9; /* 0x3802E5D4: je 0x3802e5d9 */
  13654 L_3802E5D6:
  13655     MEM32(esi + 0x4) = ecx; /* 0x3802E5D6: mov dword ptr [esi + 4], ecx */
  13656 L_3802E5D9:
  13657     esi = MEM32(ecx + 0x4); /* 0x3802E5D9: mov esi, dword ptr [ecx + 4] */
  13658     MEM32(edx + 0x4) = esi; /* 0x3802E5DC: mov dword ptr [edx + 4], esi */
  13659     esi = MEM32(edi + 0x4); /* 0x3802E5DF: mov esi, dword ptr [edi + 4] */
  13660     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E5E2: cmp ecx, dword ptr [esi + 4] */
  13661     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13662     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13663     _flag_k = FK_CMP;
  13664     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5EC; /* 0x3802E5E5: jne 0x3802e5ec */
  13665 L_3802E5E7:
  13666     MEM32(esi + 0x4) = edx; /* 0x3802E5E7: mov dword ptr [esi + 4], edx */
  13667     goto L_3802E5FB; /* 0x3802E5EA: jmp 0x3802e5fb */
  13668 L_3802E5EC:
  13669     esi = MEM32(ecx + 0x4); /* 0x3802E5EC: mov esi, dword ptr [ecx + 4] */
  13670     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E5EF: cmp ecx, dword ptr [esi + 8] */
  13671     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  13672     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13673     _flag_k = FK_CMP;
  13674     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E5F9; /* 0x3802E5F2: jne 0x3802e5f9 */
  13675 L_3802E5F4:
  13676     MEM32(esi + 0x8) = edx; /* 0x3802E5F4: mov dword ptr [esi + 8], edx */
  13677     goto L_3802E5FB; /* 0x3802E5F7: jmp 0x3802e5fb */
  13678 L_3802E5F9:
  13679     MEM32(esi) = edx; /* 0x3802E5F9: mov dword ptr [esi], edx */
  13680 L_3802E5FB:
  13681     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  13682     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  13683     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  13684     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  13685 L_3802E607:
  13686     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  13687     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  13688     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  13689     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  13690     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  13691     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  13692     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  13693     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  13694     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  13695     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  13696     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  13697     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  13698     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  13699     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13700     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13701     _flag_k = FK_CMP;
  13702     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  13703 L_3802E62E:
  13704     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  13705 L_3802E631:
  13706     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  13707     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  13708     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  13709     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  13710     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13711     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13712     _flag_k = FK_CMP;
  13713     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  13714 L_3802E63F:
  13715     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  13716     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  13717     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  13718 L_3802E649:
  13719     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  13720     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  13721     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  13722     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13723     _flag_k = FK_CMP;
  13724     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  13725 L_3802E650:
  13726     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  13727     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  13728     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  13729 L_3802E659:
  13730     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  13731     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  13732     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  13733 L_3802E6FF:
  13734     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  13735     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  13736     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  13737     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  13738     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  13739     RECOMP_FLAGS_IN();
  13740     PUSH32(esp, esi); /* 0x3802E710: push esi */
  13741     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  13742     RECOMP_FLAGS_IN();
  13743     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  13744     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  13745     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  13746     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13747     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  13748     _flag_k = FK_ADD;
  13749     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  13750     eax = eax - 1; /* 0x3802E71F: dec eax */
  13751     _flag_k = FK_DEC;
  13752     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  13753     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  13754     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  13755     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  13756     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  13757     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  13758     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  13759     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  13760     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  13761     RECOMP_REGS_OUT();
  13762 }
  13763 
  13764 void sub_3802E5FB(void) {
  13765     int _fpu_cmp = 0;
  13766     uint32_t _cf = 0;
  13767     int _df = 1;
  13768     uint32_t _flag_k = FK_NONE;
  13769     uint32_t _flag_a = 0, _flag_b = 0;
  13770     uint32_t _itail_tgt = 0;
  13771     RECOMP_REGS_LOCALS
  13772     RECOMP_ENTER(0x3802E5FBu);
  13773 
  13774 L_3802E5FB:
  13775     MEM32(edx + 0x8) = ecx; /* 0x3802E5FB: mov dword ptr [edx + 8], ecx */
  13776     MEM32(ecx + 0x4) = edx; /* 0x3802E5FE: mov dword ptr [ecx + 4], edx */
  13777     ecx = MEM32(eax + 0x4); /* 0x3802E601: mov ecx, dword ptr [eax + 4] */
  13778     ecx = MEM32(ecx + 0x8); /* 0x3802E604: mov ecx, dword ptr [ecx + 8] */
  13779     edx = MEM32(eax + 0x4); /* 0x3802E607: mov edx, dword ptr [eax + 4] */
  13780     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E60A: mov dl, byte ptr [edx + 0x24] */
  13781     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E60D: mov byte ptr [ecx + 0x24], dl */
  13782     edx = MEM32(eax + 0x4); /* 0x3802E610: mov edx, dword ptr [eax + 4] */
  13783     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E613: mov byte ptr [edx + 0x24], bl */
  13784     ecx = MEM32(ecx + 0x8); /* 0x3802E616: mov ecx, dword ptr [ecx + 8] */
  13785     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E619: mov byte ptr [ecx + 0x24], bl */
  13786     ecx = MEM32(eax + 0x4); /* 0x3802E61C: mov ecx, dword ptr [eax + 4] */
  13787     edx = MEM32(ecx + 0x8); /* 0x3802E61F: mov edx, dword ptr [ecx + 8] */
  13788     esi = MEM32(edx); /* 0x3802E622: mov esi, dword ptr [edx] */
  13789     MEM32(ecx + 0x8) = esi; /* 0x3802E624: mov dword ptr [ecx + 8], esi */
  13790     esi = MEM32(edx); /* 0x3802E627: mov esi, dword ptr [edx] */
  13791     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E629: cmp esi, dword ptr [edi + 8] */
  13792     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13793     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13794     _flag_k = FK_CMP;
  13795     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E631; /* 0x3802E62C: je 0x3802e631 */
  13796 L_3802E62E:
  13797     MEM32(esi + 0x4) = ecx; /* 0x3802E62E: mov dword ptr [esi + 4], ecx */
  13798 L_3802E631:
  13799     esi = MEM32(ecx + 0x4); /* 0x3802E631: mov esi, dword ptr [ecx + 4] */
  13800     MEM32(edx + 0x4) = esi; /* 0x3802E634: mov dword ptr [edx + 4], esi */
  13801     esi = MEM32(edi + 0x4); /* 0x3802E637: mov esi, dword ptr [edi + 4] */
  13802     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E63A: cmp ecx, dword ptr [esi + 4] */
  13803     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13804     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13805     _flag_k = FK_CMP;
  13806     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E649; /* 0x3802E63D: jne 0x3802e649 */
  13807 L_3802E63F:
  13808     MEM32(esi + 0x4) = edx; /* 0x3802E63F: mov dword ptr [esi + 4], edx */
  13809     MEM32(edx) = ecx; /* 0x3802E642: mov dword ptr [edx], ecx */
  13810     goto L_3802E6FF; /* 0x3802E644: jmp 0x3802e6ff */
  13811 L_3802E649:
  13812     esi = MEM32(ecx + 0x4); /* 0x3802E649: mov esi, dword ptr [ecx + 4] */
  13813     /* cmp ecx, MEM32(esi) */ /* 0x3802E64C: cmp ecx, dword ptr [esi] */
  13814     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
  13815     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13816     _flag_k = FK_CMP;
  13817     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E659; /* 0x3802E64E: jne 0x3802e659 */
  13818 L_3802E650:
  13819     MEM32(esi) = edx; /* 0x3802E650: mov dword ptr [esi], edx */
  13820     MEM32(edx) = ecx; /* 0x3802E652: mov dword ptr [edx], ecx */
  13821     goto L_3802E6FF; /* 0x3802E654: jmp 0x3802e6ff */
  13822 L_3802E659:
  13823     MEM32(esi + 0x8) = edx; /* 0x3802E659: mov dword ptr [esi + 8], edx */
  13824     MEM32(edx) = ecx; /* 0x3802E65C: mov dword ptr [edx], ecx */
  13825     goto L_3802E6FF; /* 0x3802E65E: jmp 0x3802e6ff */
  13826 L_3802E6FF:
  13827     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  13828     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  13829     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  13830     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  13831     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  13832     RECOMP_FLAGS_IN();
  13833     PUSH32(esp, esi); /* 0x3802E710: push esi */
  13834     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  13835     RECOMP_FLAGS_IN();
  13836     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  13837     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  13838     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  13839     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13840     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  13841     _flag_k = FK_ADD;
  13842     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  13843     eax = eax - 1; /* 0x3802E71F: dec eax */
  13844     _flag_k = FK_DEC;
  13845     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  13846     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  13847     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  13848     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  13849     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  13850     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  13851     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  13852     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  13853     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  13854     RECOMP_REGS_OUT();
  13855 }
  13856 
  13857 void sub_3802E6A7(void) {
  13858     int _fpu_cmp = 0;
  13859     uint32_t _cf = 0;
  13860     int _df = 1;
  13861     uint32_t _flag_k = FK_NONE;
  13862     uint32_t _flag_a = 0, _flag_b = 0;
  13863     uint32_t _itail_tgt = 0;
  13864     RECOMP_REGS_LOCALS
  13865     RECOMP_ENTER(0x3802E6A7u);
  13866 
  13867 L_3802E6A7:
  13868     MEM32(edx) = ecx; /* 0x3802E6A7: mov dword ptr [edx], ecx */
  13869     MEM32(ecx + 0x4) = edx; /* 0x3802E6A9: mov dword ptr [ecx + 4], edx */
  13870     ecx = MEM32(eax + 0x4); /* 0x3802E6AC: mov ecx, dword ptr [eax + 4] */
  13871     ecx = MEM32(ecx); /* 0x3802E6AF: mov ecx, dword ptr [ecx] */
  13872     edx = MEM32(eax + 0x4); /* 0x3802E6B1: mov edx, dword ptr [eax + 4] */
  13873     SET_LO8(edx, MEM8(edx + 0x24)); /* 0x3802E6B4: mov dl, byte ptr [edx + 0x24] */
  13874     MEM8(ecx + 0x24) = (uint8_t)(LO8(edx)); /* 0x3802E6B7: mov byte ptr [ecx + 0x24], dl */
  13875     edx = MEM32(eax + 0x4); /* 0x3802E6BA: mov edx, dword ptr [eax + 4] */
  13876     MEM8(edx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6BD: mov byte ptr [edx + 0x24], bl */
  13877     ecx = MEM32(ecx); /* 0x3802E6C0: mov ecx, dword ptr [ecx] */
  13878     MEM8(ecx + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E6C2: mov byte ptr [ecx + 0x24], bl */
  13879     ecx = MEM32(eax + 0x4); /* 0x3802E6C5: mov ecx, dword ptr [eax + 4] */
  13880     edx = MEM32(ecx); /* 0x3802E6C8: mov edx, dword ptr [ecx] */
  13881     esi = MEM32(edx + 0x8); /* 0x3802E6CA: mov esi, dword ptr [edx + 8] */
  13882     MEM32(ecx) = esi; /* 0x3802E6CD: mov dword ptr [ecx], esi */
  13883     esi = MEM32(edx + 0x8); /* 0x3802E6CF: mov esi, dword ptr [edx + 8] */
  13884     /* cmp esi, MEM32(edi + 0x8) */ /* 0x3802E6D2: cmp esi, dword ptr [edi + 8] */
  13885     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  13886     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13887     _flag_k = FK_CMP;
  13888     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E6DA; /* 0x3802E6D5: je 0x3802e6da */
  13889 L_3802E6D7:
  13890     MEM32(esi + 0x4) = ecx; /* 0x3802E6D7: mov dword ptr [esi + 4], ecx */
  13891 L_3802E6DA:
  13892     esi = MEM32(ecx + 0x4); /* 0x3802E6DA: mov esi, dword ptr [ecx + 4] */
  13893     MEM32(edx + 0x4) = esi; /* 0x3802E6DD: mov dword ptr [edx + 4], esi */
  13894     esi = MEM32(edi + 0x4); /* 0x3802E6E0: mov esi, dword ptr [edi + 4] */
  13895     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x3802E6E3: cmp ecx, dword ptr [esi + 4] */
  13896     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
  13897     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13898     _flag_k = FK_CMP;
  13899     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6ED; /* 0x3802E6E6: jne 0x3802e6ed */
  13900 L_3802E6E8:
  13901     MEM32(esi + 0x4) = edx; /* 0x3802E6E8: mov dword ptr [esi + 4], edx */
  13902     goto L_3802E6FC; /* 0x3802E6EB: jmp 0x3802e6fc */
  13903 L_3802E6ED:
  13904     esi = MEM32(ecx + 0x4); /* 0x3802E6ED: mov esi, dword ptr [ecx + 4] */
  13905     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x3802E6F0: cmp ecx, dword ptr [esi + 8] */
  13906     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  13907     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13908     _flag_k = FK_CMP;
  13909     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E6FA; /* 0x3802E6F3: jne 0x3802e6fa */
  13910 L_3802E6F5:
  13911     MEM32(esi + 0x8) = edx; /* 0x3802E6F5: mov dword ptr [esi + 8], edx */
  13912     goto L_3802E6FC; /* 0x3802E6F8: jmp 0x3802e6fc */
  13913 L_3802E6FA:
  13914     MEM32(esi) = edx; /* 0x3802E6FA: mov dword ptr [esi], edx */
  13915 L_3802E6FC:
  13916     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  13917     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  13918     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  13919     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  13920     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  13921     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  13922     RECOMP_FLAGS_IN();
  13923     PUSH32(esp, esi); /* 0x3802E710: push esi */
  13924     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  13925     RECOMP_FLAGS_IN();
  13926     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  13927     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  13928     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  13929     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13930     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  13931     _flag_k = FK_ADD;
  13932     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  13933     eax = eax - 1; /* 0x3802E71F: dec eax */
  13934     _flag_k = FK_DEC;
  13935     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  13936     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  13937     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  13938     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  13939     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  13940     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  13941     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  13942     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  13943     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  13944     RECOMP_REGS_OUT();
  13945 }
  13946 
  13947 void sub_3802E6FC(void) {
  13948     int _fpu_cmp = 0;
  13949     uint32_t _cf = 0;
  13950     int _df = 1;
  13951     uint32_t _flag_k = FK_NONE;
  13952     uint32_t _flag_a = 0, _flag_b = 0;
  13953     uint32_t _itail_tgt = 0;
  13954     RECOMP_REGS_LOCALS
  13955     RECOMP_ENTER(0x3802E6FCu);
  13956 
  13957 L_3802E6FC:
  13958     MEM32(edx + 0x8) = ecx; /* 0x3802E6FC: mov dword ptr [edx + 8], ecx */
  13959     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  13960     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  13961     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  13962     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  13963     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  13964     RECOMP_FLAGS_IN();
  13965     PUSH32(esp, esi); /* 0x3802E710: push esi */
  13966     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  13967     RECOMP_FLAGS_IN();
  13968     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  13969     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  13970     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  13971     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13972     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  13973     _flag_k = FK_ADD;
  13974     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  13975     eax = eax - 1; /* 0x3802E71F: dec eax */
  13976     _flag_k = FK_DEC;
  13977     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  13978     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  13979     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  13980     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  13981     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  13982     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  13983     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  13984     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  13985     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  13986     RECOMP_REGS_OUT();
  13987 }
  13988 
  13989 void sub_3802E6FF(void) {
  13990     int _fpu_cmp = 0;
  13991     uint32_t _cf = 0;
  13992     int _df = 1;
  13993     uint32_t _flag_k = FK_NONE;
  13994     uint32_t _flag_a = 0, _flag_b = 0;
  13995     uint32_t _itail_tgt = 0;
  13996     RECOMP_REGS_LOCALS
  13997     RECOMP_ENTER(0x3802E6FFu);
  13998 
  13999 L_3802E6FF:
  14000     MEM32(ecx + 0x4) = edx; /* 0x3802E6FF: mov dword ptr [ecx + 4], edx */
  14001     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  14002     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  14003     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  14004     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  14005     RECOMP_FLAGS_IN();
  14006     PUSH32(esp, esi); /* 0x3802E710: push esi */
  14007     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  14008     RECOMP_FLAGS_IN();
  14009     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  14010     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  14011     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14012     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14013     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  14014     _flag_k = FK_ADD;
  14015     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  14016     eax = eax - 1; /* 0x3802E71F: dec eax */
  14017     _flag_k = FK_DEC;
  14018     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  14019     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  14020     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  14021     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  14022     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  14023     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  14024     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  14025     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  14026     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  14027     RECOMP_REGS_OUT();
  14028 }
  14029 
  14030 void sub_3802E702(void) {
  14031     int _fpu_cmp = 0;
  14032     uint32_t _cf = 0;
  14033     int _df = 1;
  14034     uint32_t _flag_k = FK_NONE;
  14035     uint32_t _flag_a = 0, _flag_b = 0;
  14036     uint32_t _itail_tgt = 0;
  14037     RECOMP_REGS_LOCALS
  14038     RECOMP_ENTER(0x3802E702u);
  14039 
  14040 L_3802E702:
  14041     esi = MEM32(ebp + (-0x4)); /* 0x3802E702: mov esi, dword ptr [ebp - 4] */
  14042     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E705: mov byte ptr [eax + 0x24], bl */
  14043     ecx = esi + 0xC; /* 0x3802E708: lea ecx, [esi + 0xc] */
  14044     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E70B: call 0x3802f5e0 */ /* not lifted */
  14045     RECOMP_FLAGS_IN();
  14046     PUSH32(esp, esi); /* 0x3802E710: push esi */
  14047     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E711: call 0x3804b4f6 */ /* not lifted */
  14048     RECOMP_FLAGS_IN();
  14049     eax = MEM32(edi + 0x10); /* 0x3802E716: mov eax, dword ptr [edi + 0x10] */
  14050     edx = MEM32(ebp + 0xC); /* 0x3802E719: mov edx, dword ptr [ebp + 0xc] */
  14051     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14052     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14053     esp = esp + 4; /* 0x3802E71C: add esp, 4 */
  14054     _flag_k = FK_ADD;
  14055     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  14056     eax = eax - 1; /* 0x3802E71F: dec eax */
  14057     _flag_k = FK_DEC;
  14058     MEM32(edi + 0x10) = eax; /* 0x3802E720: mov dword ptr [edi + 0x10], eax */
  14059     eax = MEM32(ebp + 0x8); /* 0x3802E723: mov eax, dword ptr [ebp + 8] */
  14060     edi = POP32_VAL(esp); /* 0x3802E726: pop edi */
  14061     esi = POP32_VAL(esp); /* 0x3802E727: pop esi */
  14062     MEM32(eax) = edx; /* 0x3802E728: mov dword ptr [eax], edx */
  14063     ebx = POP32_VAL(esp); /* 0x3802E72A: pop ebx */
  14064     esp = ebp; /* 0x3802E72B: mov esp, ebp */
  14065     ebp = POP32_VAL(esp); /* 0x3802E72D: pop ebp */
  14066     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3802E72E: ret 8 */
  14067     RECOMP_REGS_OUT();
  14068 }
  14069 
  14070 void sub_3802E740(void) {
  14071     int _fpu_cmp = 0;
  14072     uint32_t _cf = 0;
  14073     int _df = 1;
  14074     uint32_t _flag_k = FK_NONE;
  14075     uint32_t _flag_a = 0, _flag_b = 0;
  14076     uint32_t _itail_tgt = 0;
  14077     RECOMP_REGS_LOCALS
  14078     RECOMP_ENTER(0x3802E740u);
  14079 
  14080 L_3802E740:
  14081     PUSH32(esp, ebp); /* 0x3802E740: push ebp */
  14082     ebp = esp; /* 0x3802E741: mov ebp, esp */
  14083     PUSH32(esp, ebx); /* 0x3802E743: push ebx */
  14084     PUSH32(esp, esi); /* 0x3802E744: push esi */
  14085     ebx = ecx; /* 0x3802E745: mov ebx, ecx */
  14086     eax = MEM32(ebx + 0x8); /* 0x3802E747: mov eax, dword ptr [ebx + 8] */
  14087     PUSH32(esp, edi); /* 0x3802E74A: push edi */
  14088     edi = MEM32(ebp + 0x8); /* 0x3802E74B: mov edi, dword ptr [ebp + 8] */
  14089     /* cmp edi, eax */ /* 0x3802E74E: cmp edi, eax */
  14090     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
  14091     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14092     _flag_k = FK_CMP;
  14093     esi = edi; /* 0x3802E750: mov esi, edi */
  14094     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E77B; /* 0x3802E752: je 0x3802e77b */
  14095 L_3802E754:
  14096     eax = MEM32(esi + 0x8); /* 0x3802E754: mov eax, dword ptr [esi + 8] */
  14097     PUSH32(esp, eax); /* 0x3802E757: push eax */
  14098     ecx = ebx; /* 0x3802E758: mov ecx, ebx */
  14099     RECOMP_ICALL(0x3802E740u); /* 0x3802E75A: call 0x3802e740 */ /* not lifted */
  14100     RECOMP_FLAGS_IN();
  14101     esi = MEM32(esi); /* 0x3802E75F: mov esi, dword ptr [esi] */
  14102     ecx = edi + 0xC; /* 0x3802E761: lea ecx, [edi + 0xc] */
  14103     RECOMP_ICALL(0x3802F5E0u); /* 0x3802E764: call 0x3802f5e0 */ /* not lifted */
  14104     RECOMP_FLAGS_IN();
  14105     PUSH32(esp, edi); /* 0x3802E769: push edi */
  14106     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E76A: call 0x3804b4f6 */ /* not lifted */
  14107     RECOMP_FLAGS_IN();
  14108     eax = MEM32(ebx + 0x8); /* 0x3802E76F: mov eax, dword ptr [ebx + 8] */
  14109     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14110     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14111     esp = esp + 4; /* 0x3802E772: add esp, 4 */
  14112     _flag_k = FK_ADD;
  14113     /* cmp esi, eax */ /* 0x3802E775: cmp esi, eax */
  14114     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
  14115     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14116     _flag_k = FK_CMP;
  14117     edi = esi; /* 0x3802E777: mov edi, esi */
  14118     RECOMP_BACKEDGE();
  14119     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E754; /* 0x3802E779: jne 0x3802e754 */
  14120 L_3802E77B:
  14121     edi = POP32_VAL(esp); /* 0x3802E77B: pop edi */
  14122     esi = POP32_VAL(esp); /* 0x3802E77C: pop esi */
  14123     ebx = POP32_VAL(esp); /* 0x3802E77D: pop ebx */
  14124     ebp = POP32_VAL(esp); /* 0x3802E77E: pop ebp */
  14125     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802E77F: ret 4 */
  14126     RECOMP_REGS_OUT();
  14127 }
  14128 
  14129 void sub_3802E790(void) {
  14130     int _fpu_cmp = 0;
  14131     uint32_t _cf = 0;
  14132     int _df = 1;
  14133     uint32_t _flag_k = FK_NONE;
  14134     uint32_t _flag_a = 0, _flag_b = 0;
  14135     uint32_t _itail_tgt = 0;
  14136     RECOMP_REGS_LOCALS
  14137     RECOMP_ENTER(0x3802E790u);
  14138 
  14139 L_3802E790:
  14140     PUSH32(esp, ebx); /* 0x3802E790: push ebx */
  14141     PUSH32(esp, esi); /* 0x3802E791: push esi */
  14142     PUSH32(esp, edi); /* 0x3802E792: push edi */
  14143     PUSH32(esp, 0x28u); /* 0x3802E793: push 0x28 */
  14144     esi = ecx; /* 0x3802E795: mov esi, ecx */
  14145     RECOMP_ICALL(0x3804B676u); /* 0x3802E797: call 0x3804b676 */ /* not lifted */
  14146     RECOMP_FLAGS_IN();
  14147     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  14148     ebx = 0; /* 0x3802E79C: xor ebx, ebx */
  14149     _cf = 0;
  14150     _flag_k = FK_TEST;
  14151     MEM32(eax + 0x4) = ebx; /* 0x3802E79E: mov dword ptr [eax + 4], ebx */
  14152     MEM8(eax + 0x25) = (uint8_t)(LO8(ebx)); /* 0x3802E7A1: mov byte ptr [eax + 0x25], bl */
  14153     SET_LO8(ecx, 1); /* 0x3802E7A4: mov cl, 1 */
  14154     MEM8(eax + 0x24) = (uint8_t)(LO8(ecx)); /* 0x3802E7A6: mov byte ptr [eax + 0x24], cl */
  14155     MEM32(esi + 0x8) = eax; /* 0x3802E7A9: mov dword ptr [esi + 8], eax */
  14156     MEM8(eax + 0x25) = (uint8_t)(LO8(ecx)); /* 0x3802E7AC: mov byte ptr [eax + 0x25], cl */
  14157     eax = MEM32(esi + 0x8); /* 0x3802E7AF: mov eax, dword ptr [esi + 8] */
  14158     MEM32(eax) = ebx; /* 0x3802E7B2: mov dword ptr [eax], ebx */
  14159     ecx = MEM32(esi + 0x8); /* 0x3802E7B4: mov ecx, dword ptr [esi + 8] */
  14160     MEM32(ecx + 0x8) = ebx; /* 0x3802E7B7: mov dword ptr [ecx + 8], ebx */
  14161     edi = MEM32(esi + 0x8); /* 0x3802E7BA: mov edi, dword ptr [esi + 8] */
  14162     PUSH32(esp, 0x28u); /* 0x3802E7BD: push 0x28 */
  14163     RECOMP_ICALL(0x3804B676u); /* 0x3802E7BF: call 0x3804b676 */ /* not lifted */
  14164     RECOMP_FLAGS_IN();
  14165     MEM32(eax + 0x4) = edi; /* 0x3802E7C4: mov dword ptr [eax + 4], edi */
  14166     MEM8(eax + 0x24) = (uint8_t)(LO8(ebx)); /* 0x3802E7C7: mov byte ptr [eax + 0x24], bl */
  14167     MEM8(eax + 0x25) = (uint8_t)(LO8(ebx)); /* 0x3802E7CA: mov byte ptr [eax + 0x25], bl */
  14168     MEM32(esi + 0x4) = eax; /* 0x3802E7CD: mov dword ptr [esi + 4], eax */
  14169     MEM32(eax) = eax; /* 0x3802E7D0: mov dword ptr [eax], eax */
  14170     eax = MEM32(esi + 0x4); /* 0x3802E7D2: mov eax, dword ptr [esi + 4] */
  14171     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  14172     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14173     esp = esp + 8; /* 0x3802E7D5: add esp, 8 */
  14174     _flag_k = FK_ADD;
  14175     edi = POP32_VAL(esp); /* 0x3802E7D8: pop edi */
  14176     MEM32(eax + 0x8) = eax; /* 0x3802E7D9: mov dword ptr [eax + 8], eax */
  14177     MEM32(esi + 0x10) = ebx; /* 0x3802E7DC: mov dword ptr [esi + 0x10], ebx */
  14178     esi = POP32_VAL(esp); /* 0x3802E7DF: pop esi */
  14179     ebx = POP32_VAL(esp); /* 0x3802E7E0: pop ebx */
  14180     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802E7E1: ret  */
  14181     RECOMP_REGS_OUT();
  14182 }
  14183 
  14184 void sub_3802E7F0(void) {
  14185     int _fpu_cmp = 0;
  14186     uint32_t _cf = 0;
  14187     int _df = 1;
  14188     uint32_t _flag_k = FK_NONE;
  14189     uint32_t _flag_a = 0, _flag_b = 0;
  14190     uint32_t _itail_tgt = 0;
  14191     RECOMP_REGS_LOCALS
  14192     RECOMP_ENTER(0x3802E7F0u);
  14193 
  14194 L_3802E7F0:
  14195     PUSH32(esp, ebp); /* 0x3802E7F0: push ebp */
  14196     ebp = esp; /* 0x3802E7F1: mov ebp, esp */
  14197     PUSH32(esp, ebx); /* 0x3802E7F3: push ebx */
  14198     PUSH32(esp, esi); /* 0x3802E7F4: push esi */
  14199     ebx = ecx; /* 0x3802E7F5: mov ebx, ecx */
  14200     eax = MEM32(ebx + 0x8); /* 0x3802E7F7: mov eax, dword ptr [ebx + 8] */
  14201     PUSH32(esp, edi); /* 0x3802E7FA: push edi */
  14202     edi = MEM32(ebp + 0x8); /* 0x3802E7FB: mov edi, dword ptr [ebp + 8] */
  14203     /* cmp edi, eax */ /* 0x3802E7FE: cmp edi, eax */
  14204     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
  14205     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14206     _flag_k = FK_CMP;
  14207     esi = edi; /* 0x3802E800: mov esi, edi */
  14208     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E823; /* 0x3802E802: je 0x3802e823 */
  14209 L_3802E804:
  14210     eax = MEM32(esi + 0x8); /* 0x3802E804: mov eax, dword ptr [esi + 8] */
  14211     PUSH32(esp, eax); /* 0x3802E807: push eax */
  14212     ecx = ebx; /* 0x3802E808: mov ecx, ebx */
  14213     RECOMP_ICALL(0x3802E7F0u); /* 0x3802E80A: call 0x3802e7f0 */ /* not lifted */
  14214     RECOMP_FLAGS_IN();
  14215     esi = MEM32(esi); /* 0x3802E80F: mov esi, dword ptr [esi] */
  14216     PUSH32(esp, edi); /* 0x3802E811: push edi */
  14217     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E812: call 0x3804b4f6 */ /* not lifted */
  14218     RECOMP_FLAGS_IN();
  14219     eax = MEM32(ebx + 0x8); /* 0x3802E817: mov eax, dword ptr [ebx + 8] */
  14220     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14221     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14222     esp = esp + 4; /* 0x3802E81A: add esp, 4 */
  14223     _flag_k = FK_ADD;
  14224     /* cmp esi, eax */ /* 0x3802E81D: cmp esi, eax */
  14225     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
  14226     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14227     _flag_k = FK_CMP;
  14228     edi = esi; /* 0x3802E81F: mov edi, esi */
  14229     RECOMP_BACKEDGE();
  14230     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E804; /* 0x3802E821: jne 0x3802e804 */
  14231 L_3802E823:
  14232     edi = POP32_VAL(esp); /* 0x3802E823: pop edi */
  14233     esi = POP32_VAL(esp); /* 0x3802E824: pop esi */
  14234     ebx = POP32_VAL(esp); /* 0x3802E825: pop ebx */
  14235     ebp = POP32_VAL(esp); /* 0x3802E826: pop ebp */
  14236     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3802E827: ret 4 */
  14237     RECOMP_REGS_OUT();
  14238 }
  14239 
  14240 void sub_3802E830(void) {
  14241     int _fpu_cmp = 0;
  14242     uint32_t _cf = 0;
  14243     int _df = 1;
  14244     uint32_t _flag_k = FK_NONE;
  14245     uint32_t _flag_a = 0, _flag_b = 0;
  14246     uint32_t _itail_tgt = 0;
  14247     RECOMP_REGS_LOCALS
  14248     RECOMP_ENTER(0x3802E830u);
  14249 
  14250 L_3802E830:
  14251     PUSH32(esp, ebp); /* 0x3802E830: push ebp */
  14252     ebp = esp; /* 0x3802E831: mov ebp, esp */
  14253     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
  14254     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14255     esp = esp - 0xCu; /* 0x3802E833: sub esp, 0xc */
  14256     _flag_k = FK_CMP;
  14257     eax = MEM32(ecx + 0xC); /* 0x3802E836: mov eax, dword ptr [ecx + 0xc] */
  14258     PUSH32(esp, ebx); /* 0x3802E839: push ebx */
  14259     PUSH32(esp, esi); /* 0x3802E83A: push esi */
  14260     esi = MEM32(ecx + 0x8); /* 0x3802E83B: mov esi, dword ptr [ecx + 8] */
  14261     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
  14262     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14263     eax = eax - esi; /* 0x3802E83E: sub eax, esi */
  14264     _flag_k = FK_CMP;
  14265     PUSH32(esp, edi); /* 0x3802E840: push edi */
  14266     edi = MEM32(ebp + 0xC); /* 0x3802E841: mov edi, dword ptr [ebp + 0xc] */
  14267     if (4u) _cf = (((eax) >> 3) & 1u); /* 0x3802E844: sar eax, 4 */
  14268     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14269     eax = (uint32_t)((int32_t)eax >> 4u);
  14270     /* cmp eax, edi */ /* 0x3802E847: cmp eax, edi */
  14271     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
  14272     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14273     _flag_k = FK_CMP;
  14274     MEM32(ebp + (-0x4)) = ecx; /* 0x3802E849: mov dword ptr [ebp - 4], ecx */
  14275     if (CMP_AE(_flag_a, _flag_b)) goto L_3802E969; /* 0x3802E84C: jae 0x3802e969 */
  14276 L_3802E852:
  14277     ecx = MEM32(ecx + 0x4); /* 0x3802E852: mov ecx, dword ptr [ecx + 4] */
  14278     /* test ecx, ecx */ /* 0x3802E855: test ecx, ecx */
  14279     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
  14280     _cf = 0;
  14281     _flag_k = FK_TEST;
  14282     if (TEST_Z(_flag_a, _flag_b)) goto L_3802E864; /* 0x3802E857: je 0x3802e864 */
  14283 L_3802E859:
  14284     eax = esi; /* 0x3802E859: mov eax, esi */
  14285     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  14286     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14287     eax = eax - ecx; /* 0x3802E85B: sub eax, ecx */
  14288     _flag_k = FK_CMP;
  14289     if (4u) _cf = (((eax) >> 3) & 1u); /* 0x3802E85D: sar eax, 4 */
  14290     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14291     eax = (uint32_t)((int32_t)eax >> 4u);
  14292     /* cmp edi, eax */ /* 0x3802E860: cmp edi, eax */
  14293     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
  14294     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14295     _flag_k = FK_CMP;
  14296     if (CMP_B(_flag_a, _flag_b)) goto L_3802E866; /* 0x3802E862: jb 0x3802e866 */
  14297 L_3802E864:
  14298     eax = edi; /* 0x3802E864: mov eax, edi */
  14299 L_3802E866:
  14300     /* test ecx, ecx */ /* 0x3802E866: test ecx, ecx */
  14301     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
  14302     _cf = 0;
  14303     _flag_k = FK_TEST;
  14304     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E86E; /* 0x3802E868: jne 0x3802e86e */
  14305 L_3802E86A:
  14306     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  14307     esi = 0; /* 0x3802E86A: xor esi, esi */
  14308     _cf = 0;
  14309     _flag_k = FK_TEST;
  14310     goto L_3802E873; /* 0x3802E86C: jmp 0x3802e873 */
  14311 L_3802E86E:
  14312     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ecx);
  14313     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14314     esi = esi - ecx; /* 0x3802E86E: sub esi, ecx */
  14315     _flag_k = FK_CMP;
  14316     if (4u) _cf = (((esi) >> 3) & 1u); /* 0x3802E870: sar esi, 4 */
  14317     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)esi >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14318     esi = (uint32_t)((int32_t)esi >> 4u);
  14319 L_3802E873:
  14320     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
  14321     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14322     eax = eax + esi; /* 0x3802E873: add eax, esi */
  14323     _flag_k = FK_ADD;
  14324     /* test eax, eax */ /* 0x3802E875: test eax, eax */
  14325     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  14326     _cf = 0;
  14327     _flag_k = FK_TEST;
  14328     MEM32(ebp + (-0x8)) = eax; /* 0x3802E877: mov dword ptr [ebp - 8], eax */
  14329     if (TEST_NS(_flag_a, _flag_b)) goto L_3802E87E; /* 0x3802E87A: jge 0x3802e87e */
  14330 L_3802E87C:
  14331     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  14332     eax = 0; /* 0x3802E87C: xor eax, eax */
  14333     _cf = 0;
  14334     _flag_k = FK_TEST;
  14335 L_3802E87E:
  14336     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802E87E: shl eax, 4 */
  14337     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14338     eax = eax << 4u; /* 0x3802E87E: shl eax, 4 */
  14339     PUSH32(esp, eax); /* 0x3802E881: push eax */
  14340     RECOMP_ICALL(0x3804B676u); /* 0x3802E882: call 0x3804b676 */ /* not lifted */
  14341     RECOMP_FLAGS_IN();
  14342     ecx = MEM32(ebp + (-0x4)); /* 0x3802E887: mov ecx, dword ptr [ebp - 4] */
  14343     esi = MEM32(ecx + 0x4); /* 0x3802E88A: mov esi, dword ptr [ecx + 4] */
  14344     MEM32(ebp + (-0xC)) = eax; /* 0x3802E88D: mov dword ptr [ebp - 0xc], eax */
  14345     ebx = eax; /* 0x3802E890: mov ebx, eax */
  14346     eax = MEM32(ebp + 0x8); /* 0x3802E892: mov eax, dword ptr [ebp + 8] */
  14347     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14348     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14349     esp = esp + 4; /* 0x3802E895: add esp, 4 */
  14350     _flag_k = FK_ADD;
  14351     /* cmp esi, eax */ /* 0x3802E898: cmp esi, eax */
  14352     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
  14353     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14354     _flag_k = FK_CMP;
  14355     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E8B3; /* 0x3802E89A: je 0x3802e8b3 */
  14356 L_3802E89C:
  14357     PUSH32(esp, esi); /* 0x3802E89C: push esi */
  14358     PUSH32(esp, ebx); /* 0x3802E89D: push ebx */
  14359     RECOMP_ICALL(0x3802F580u); /* 0x3802E89E: call 0x3802f580 */ /* not lifted */
  14360     RECOMP_FLAGS_IN();
  14361     eax = MEM32(ebp + 0x8); /* 0x3802E8A3: mov eax, dword ptr [ebp + 8] */
  14362     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0x10u);
  14363     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14364     esi = esi + 0x10u; /* 0x3802E8A6: add esi, 0x10 */
  14365     _flag_k = FK_ADD;
  14366     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  14367     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14368     esp = esp + 8; /* 0x3802E8A9: add esp, 8 */
  14369     _flag_k = FK_ADD;
  14370     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0x10u);
  14371     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14372     ebx = ebx + 0x10u; /* 0x3802E8AC: add ebx, 0x10 */
  14373     _flag_k = FK_ADD;
  14374     /* cmp esi, eax */ /* 0x3802E8AF: cmp esi, eax */
  14375     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
  14376     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14377     _flag_k = FK_CMP;
  14378     RECOMP_BACKEDGE();
  14379     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E89C; /* 0x3802E8B1: jne 0x3802e89c */
  14380 L_3802E8B3:
  14381     /* test edi, edi */ /* 0x3802E8B3: test edi, edi */
  14382     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
  14383     _cf = 0;
  14384     _flag_k = FK_TEST;
  14385     esi = ebx; /* 0x3802E8B5: mov esi, ebx */
  14386     if (TEST_Z(_flag_a, _flag_b)) goto L_3802E8D5; /* 0x3802E8B7: jbe 0x3802e8d5 */
  14387 L_3802E8B9:
  14388     MEM32(ebp + 0xC) = edi; /* 0x3802E8B9: mov dword ptr [ebp + 0xc], edi */
  14389 L_3802E8BC:
  14390     edx = MEM32(ebp + 0x10); /* 0x3802E8BC: mov edx, dword ptr [ebp + 0x10] */
  14391     PUSH32(esp, edx); /* 0x3802E8BF: push edx */
  14392     PUSH32(esp, esi); /* 0x3802E8C0: push esi */
  14393     RECOMP_ICALL(0x3802F580u); /* 0x3802E8C1: call 0x3802f580 */ /* not lifted */
  14394     RECOMP_FLAGS_IN();
  14395     eax = MEM32(ebp + 0xC); /* 0x3802E8C6: mov eax, dword ptr [ebp + 0xc] */
  14396     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  14397     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14398     esp = esp + 8; /* 0x3802E8C9: add esp, 8 */
  14399     _flag_k = FK_ADD;
  14400     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0x10u);
  14401     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14402     esi = esi + 0x10u; /* 0x3802E8CC: add esi, 0x10 */
  14403     _flag_k = FK_ADD;
  14404     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  14405     eax = eax - 1; /* 0x3802E8CF: dec eax */
  14406     _flag_k = FK_DEC;
  14407     MEM32(ebp + 0xC) = eax; /* 0x3802E8D0: mov dword ptr [ebp + 0xc], eax */
  14408     RECOMP_BACKEDGE();
  14409     if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3802E8BC; /* 0x3802E8D3: jne 0x3802e8bc */
  14410 L_3802E8D5:
  14411     ecx = MEM32(ebp + (-0x4)); /* 0x3802E8D5: mov ecx, dword ptr [ebp - 4] */
  14412     esi = MEM32(ebp + 0x8); /* 0x3802E8D8: mov esi, dword ptr [ebp + 8] */
  14413     eax = edi; /* 0x3802E8DB: mov eax, edi */
  14414     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802E8DD: shl eax, 4 */
  14415     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14416     eax = eax << 4u; /* 0x3802E8DD: shl eax, 4 */
  14417     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  14418     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14419     eax = eax + ebx; /* 0x3802E8E0: add eax, ebx */
  14420     _flag_k = FK_ADD;
  14421     ebx = MEM32(ecx + 0x8); /* 0x3802E8E2: mov ebx, dword ptr [ecx + 8] */
  14422     /* cmp esi, ebx */ /* 0x3802E8E5: cmp esi, ebx */
  14423     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx);
  14424     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14425     _flag_k = FK_CMP;
  14426     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E909; /* 0x3802E8E7: je 0x3802e909 */
  14427 L_3802E8E9:
  14428     MEM32(ebp + 0x8) = eax; /* 0x3802E8E9: mov dword ptr [ebp + 8], eax */
  14429 L_3802E8EC:
  14430     edx = MEM32(ebp + 0x8); /* 0x3802E8EC: mov edx, dword ptr [ebp + 8] */
  14431     PUSH32(esp, esi); /* 0x3802E8EF: push esi */
  14432     PUSH32(esp, edx); /* 0x3802E8F0: push edx */
  14433     RECOMP_ICALL(0x3802F580u); /* 0x3802E8F1: call 0x3802f580 */ /* not lifted */
  14434     RECOMP_FLAGS_IN();
  14435     ecx = MEM32(ebp + 0x8); /* 0x3802E8F6: mov ecx, dword ptr [ebp + 8] */
  14436     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0x10u);
  14437     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14438     esi = esi + 0x10u; /* 0x3802E8F9: add esi, 0x10 */
  14439     _flag_k = FK_ADD;
  14440     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0x10u);
  14441     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14442     ecx = ecx + 0x10u; /* 0x3802E8FC: add ecx, 0x10 */
  14443     _flag_k = FK_ADD;
  14444     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  14445     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14446     esp = esp + 8; /* 0x3802E8FF: add esp, 8 */
  14447     _flag_k = FK_ADD;
  14448     /* cmp esi, ebx */ /* 0x3802E902: cmp esi, ebx */
  14449     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx);
  14450     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14451     _flag_k = FK_CMP;
  14452     MEM32(ebp + 0x8) = ecx; /* 0x3802E904: mov dword ptr [ebp + 8], ecx */
  14453     RECOMP_BACKEDGE();
  14454     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E8EC; /* 0x3802E907: jne 0x3802e8ec */
  14455 L_3802E909:
  14456     eax = MEM32(ebp + (-0x4)); /* 0x3802E909: mov eax, dword ptr [ebp - 4] */
  14457     eax = MEM32(eax + 0x4); /* 0x3802E90C: mov eax, dword ptr [eax + 4] */
  14458     PUSH32(esp, eax); /* 0x3802E90F: push eax */
  14459     MEM32(ebp + 0x8) = eax; /* 0x3802E910: mov dword ptr [ebp + 8], eax */
  14460     RECOMP_ICALL(0x3804B4F6u); /* 0x3802E913: call 0x3804b4f6 */ /* not lifted */
  14461     RECOMP_FLAGS_IN();
  14462     eax = MEM32(ebp + (-0x8)); /* 0x3802E918: mov eax, dword ptr [ebp - 8] */
  14463     ecx = MEM32(ebp + (-0x4)); /* 0x3802E91B: mov ecx, dword ptr [ebp - 4] */
  14464     esi = MEM32(ebp + (-0xC)); /* 0x3802E91E: mov esi, dword ptr [ebp - 0xc] */
  14465     edx = MEM32(ecx + 0x4); /* 0x3802E921: mov edx, dword ptr [ecx + 4] */
  14466     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802E924: shl eax, 4 */
  14467     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14468     eax = eax << 4u; /* 0x3802E924: shl eax, 4 */
  14469     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
  14470     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14471     eax = eax + esi; /* 0x3802E927: add eax, esi */
  14472     _flag_k = FK_ADD;
  14473     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14474     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14475     esp = esp + 4; /* 0x3802E929: add esp, 4 */
  14476     _flag_k = FK_ADD;
  14477     /* test edx, edx */ /* 0x3802E92C: test edx, edx */
  14478     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
  14479     _cf = 0;
  14480     _flag_k = FK_TEST;
  14481     MEM32(ecx + 0xC) = eax; /* 0x3802E92E: mov dword ptr [ecx + 0xc], eax */
  14482     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802E94B; /* 0x3802E931: jne 0x3802e94b */
  14483 L_3802E933:
  14484     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  14485     eax = 0; /* 0x3802E933: xor eax, eax */
  14486     _cf = 0;
  14487     _flag_k = FK_TEST;
  14488     eax = edi; /* 0x3802E935: mov eax, edi */
  14489     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802E937: shl eax, 4 */
  14490     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14491     eax = eax << 4u; /* 0x3802E937: shl eax, 4 */
  14492     edi = POP32_VAL(esp); /* 0x3802E93A: pop edi */
  14493     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
  14494     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14495     eax = eax + esi; /* 0x3802E93B: add eax, esi */
  14496     _flag_k = FK_ADD;
  14497     MEM32(ecx + 0x4) = esi; /* 0x3802E93D: mov dword ptr [ecx + 4], esi */
  14498     esi = POP32_VAL(esp); /* 0x3802E940: pop esi */
  14499     MEM32(ecx + 0x8) = eax; /* 0x3802E941: mov dword ptr [ecx + 8], eax */
  14500     ebx = POP32_VAL(esp); /* 0x3802E944: pop ebx */
  14501     esp = ebp; /* 0x3802E945: mov esp, ebp */
  14502     ebp = POP32_VAL(esp); /* 0x3802E947: pop ebp */
  14503     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802E948: ret 0xc */
  14504 L_3802E94B:
  14505     eax = MEM32(ecx + 0x8); /* 0x3802E94B: mov eax, dword ptr [ecx + 8] */
  14506     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
  14507     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14508     eax = eax - edx; /* 0x3802E94E: sub eax, edx */
  14509     _flag_k = FK_CMP;
  14510     if (4u) _cf = (((eax) >> 3) & 1u); /* 0x3802E950: sar eax, 4 */
  14511     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14512     eax = (uint32_t)((int32_t)eax >> 4u);
  14513     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
  14514     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14515     eax = eax + edi; /* 0x3802E953: add eax, edi */
  14516     _flag_k = FK_ADD;
  14517     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802E955: shl eax, 4 */
  14518     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14519     eax = eax << 4u; /* 0x3802E955: shl eax, 4 */
  14520     edi = POP32_VAL(esp); /* 0x3802E958: pop edi */
  14521     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
  14522     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14523     eax = eax + esi; /* 0x3802E959: add eax, esi */
  14524     _flag_k = FK_ADD;
  14525     MEM32(ecx + 0x4) = esi; /* 0x3802E95B: mov dword ptr [ecx + 4], esi */
  14526     esi = POP32_VAL(esp); /* 0x3802E95E: pop esi */
  14527     MEM32(ecx + 0x8) = eax; /* 0x3802E95F: mov dword ptr [ecx + 8], eax */
  14528     ebx = POP32_VAL(esp); /* 0x3802E962: pop ebx */
  14529     esp = ebp; /* 0x3802E963: mov esp, ebp */
  14530     ebp = POP32_VAL(esp); /* 0x3802E965: pop ebp */
  14531     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802E966: ret 0xc */
  14532 L_3802E969:
  14533     ebx = MEM32(ebp + 0x8); /* 0x3802E969: mov ebx, dword ptr [ebp + 8] */
  14534     edx = esi; /* 0x3802E96C: mov edx, esi */
  14535     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ebx);
  14536     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14537     edx = edx - ebx; /* 0x3802E96E: sub edx, ebx */
  14538     _flag_k = FK_CMP;
  14539     if (4u) _cf = (((edx) >> 3) & 1u); /* 0x3802E970: sar edx, 4 */
  14540     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14541     edx = (uint32_t)((int32_t)edx >> 4u);
  14542     /* cmp edx, edi */ /* 0x3802E973: cmp edx, edi */
  14543     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edi);
  14544     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14545     _flag_k = FK_CMP;
  14546     if (CMP_AE(_flag_a, _flag_b)) goto L_3802EA2C; /* 0x3802E975: jae 0x3802ea2c */
  14547 L_3802E97B:
  14548     eax = edi; /* 0x3802E97B: mov eax, edi */
  14549     if (4u) _cf = (((eax) >> 28) & 1u); /* 0x3802E97D: shl eax, 4 */
  14550     if (4u) { _flag_a = recomp_flags_pack((eax << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14551     eax = eax << 4u; /* 0x3802E97D: shl eax, 4 */
  14552     /* cmp ebx, esi */ /* 0x3802E980: cmp ebx, esi */
  14553     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(esi);
  14554     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14555     _flag_k = FK_CMP;
  14556     edx = eax + ebx; /* 0x3802E982: lea edx, [eax + ebx] */
  14557     MEM32(ebp + 0x8) = eax; /* 0x3802E985: mov dword ptr [ebp + 8], eax */
  14558     MEM32(ebp + (-0xC)) = edx; /* 0x3802E988: mov dword ptr [ebp - 0xc], edx */
  14559     MEM32(ebp + 0xC) = ebx; /* 0x3802E98B: mov dword ptr [ebp + 0xc], ebx */
  14560     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802E9C1; /* 0x3802E98E: je 0x3802e9c1 */
  14561 L_3802E990:
  14562     eax = edx; /* 0x3802E990: mov eax, edx */
  14563     MEM32(ebp + (-0x8)) = eax; /* 0x3802E992: mov dword ptr [ebp - 8], eax */
  14564 L_3802E995:
  14565     ecx = MEM32(ebp + 0xC); /* 0x3802E995: mov ecx, dword ptr [ebp + 0xc] */
  14566     edx = MEM32(ebp + (-0x8)); /* 0x3802E998: mov edx, dword ptr [ebp - 8] */
  14567     PUSH32(esp, ecx); /* 0x3802E99B: push ecx */
  14568     PUSH32(esp, edx); /* 0x3802E99C: push edx */
  14569     RECOMP_ICALL(0x3802F580u); /* 0x3802E99D: call 0x3802f580 */ /* not lifted */
  14570     RECOMP_FLAGS_IN();
  14571     eax = MEM32(ebp + 0xC); /* 0x3802E9A2: mov eax, dword ptr [ebp + 0xc] */
  14572     edx = MEM32(ebp + (-0x8)); /* 0x3802E9A5: mov edx, dword ptr [ebp - 8] */
  14573     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x10u);
  14574     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14575     eax = eax + 0x10u; /* 0x3802E9A8: add eax, 0x10 */
  14576     _flag_k = FK_ADD;
  14577     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u);
  14578     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14579     edx = edx + 0x10u; /* 0x3802E9AB: add edx, 0x10 */
  14580     _flag_k = FK_ADD;
  14581     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  14582     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14583     esp = esp + 8; /* 0x3802E9AE: add esp, 8 */
  14584     _flag_k = FK_ADD;
  14585     /* cmp eax, esi */ /* 0x3802E9B1: cmp eax, esi */
  14586     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
  14587     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14588     _flag_k = FK_CMP;
  14589     MEM32(ebp + 0xC) = eax; /* 0x3802E9B3: mov dword ptr [ebp + 0xc], eax */
  14590     MEM32(ebp + (-0x8)) = edx; /* 0x3802E9B6: mov dword ptr [ebp - 8], edx */
  14591     RECOMP_BACKEDGE();
  14592     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E995; /* 0x3802E9B9: jne 0x3802e995 */
  14593 L_3802E9BB:
  14594     ecx = MEM32(ebp + (-0x4)); /* 0x3802E9BB: mov ecx, dword ptr [ebp - 4] */
  14595     eax = MEM32(ebp + 0x8); /* 0x3802E9BE: mov eax, dword ptr [ebp + 8] */
  14596 L_3802E9C1:
  14597     esi = MEM32(ecx + 0x8); /* 0x3802E9C1: mov esi, dword ptr [ecx + 8] */
  14598     edx = esi; /* 0x3802E9C4: mov edx, esi */
  14599     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ebx);
  14600     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14601     edx = edx - ebx; /* 0x3802E9C6: sub edx, ebx */
  14602     _flag_k = FK_CMP;
  14603     if (4u) _cf = (((edx) >> 3) & 1u); /* 0x3802E9C8: sar edx, 4 */
  14604     if (4u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 4u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14605     edx = (uint32_t)((int32_t)edx >> 4u);
  14606     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edx);
  14607     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14608     edi = edi - edx; /* 0x3802E9CB: sub edi, edx */
  14609     _flag_k = FK_CMP;
  14610     if (/* sub result */ CMP_EQ(_flag_a, _flag_b)) goto L_3802E9E8; /* 0x3802E9CD: je 0x3802e9e8 */
  14611 L_3802E9CF:
  14612     eax = MEM32(ebp + 0x10); /* 0x3802E9CF: mov eax, dword ptr [ebp + 0x10] */
  14613     PUSH32(esp, eax); /* 0x3802E9D2: push eax */
  14614     PUSH32(esp, esi); /* 0x3802E9D3: push esi */
  14615     RECOMP_ICALL(0x3802F580u); /* 0x3802E9D4: call 0x3802f580 */ /* not lifted */
  14616     RECOMP_FLAGS_IN();
  14617     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  14618     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14619     esp = esp + 8; /* 0x3802E9D9: add esp, 8 */
  14620     _flag_k = FK_ADD;
  14621     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0x10u);
  14622     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14623     esi = esi + 0x10u; /* 0x3802E9DC: add esi, 0x10 */
  14624     _flag_k = FK_ADD;
  14625     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(1);
  14626     edi = edi - 1; /* 0x3802E9DF: dec edi */
  14627     _flag_k = FK_DEC;
  14628     RECOMP_BACKEDGE();
  14629     if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3802E9CF; /* 0x3802E9E0: jne 0x3802e9cf */
  14630 L_3802E9E2:
  14631     ecx = MEM32(ebp + (-0x4)); /* 0x3802E9E2: mov ecx, dword ptr [ebp - 4] */
  14632     eax = MEM32(ebp + 0x8); /* 0x3802E9E5: mov eax, dword ptr [ebp + 8] */
  14633 L_3802E9E8:
  14634     edx = MEM32(ecx + 0x8); /* 0x3802E9E8: mov edx, dword ptr [ecx + 8] */
  14635     /* cmp ebx, edx */ /* 0x3802E9EB: cmp ebx, edx */
  14636     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(edx);
  14637     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14638     _flag_k = FK_CMP;
  14639     MEM32(ebp + 0x8) = edx; /* 0x3802E9ED: mov dword ptr [ebp + 8], edx */
  14640     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802EACB; /* 0x3802E9F0: je 0x3802eacb */
  14641 L_3802E9F6:
  14642     edx = MEM32(ebp + 0x10); /* 0x3802E9F6: mov edx, dword ptr [ebp + 0x10] */
  14643     edi = MEM32(edx); /* 0x3802E9F9: mov edi, dword ptr [edx] */
  14644     esi = ebx; /* 0x3802E9FB: mov esi, ebx */
  14645     MEM32(esi) = edi; /* 0x3802E9FD: mov dword ptr [esi], edi */
  14646     edi = MEM32(edx + 0x4); /* 0x3802E9FF: mov edi, dword ptr [edx + 4] */
  14647     MEM32(esi + 0x4) = edi; /* 0x3802EA02: mov dword ptr [esi + 4], edi */
  14648     edi = MEM32(edx + 0x8); /* 0x3802EA05: mov edi, dword ptr [edx + 8] */
  14649     MEM32(esi + 0x8) = edi; /* 0x3802EA08: mov dword ptr [esi + 8], edi */
  14650     edx = MEM32(edx + 0xC); /* 0x3802EA0B: mov edx, dword ptr [edx + 0xc] */
  14651     MEM32(esi + 0xC) = edx; /* 0x3802EA0E: mov dword ptr [esi + 0xc], edx */
  14652     edx = MEM32(ebp + 0x8); /* 0x3802EA11: mov edx, dword ptr [ebp + 8] */
  14653     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0x10u);
  14654     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14655     ebx = ebx + 0x10u; /* 0x3802EA14: add ebx, 0x10 */
  14656     _flag_k = FK_ADD;
  14657     /* cmp ebx, edx */ /* 0x3802EA17: cmp ebx, edx */
  14658     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(edx);
  14659     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14660     _flag_k = FK_CMP;
  14661     RECOMP_BACKEDGE();
  14662     if (CMP_NE(_flag_a, _flag_b)) goto L_3802E9F6; /* 0x3802EA19: jne 0x3802e9f6 */
  14663 L_3802EA1B:
  14664     edx = MEM32(ecx + 0x8); /* 0x3802EA1B: mov edx, dword ptr [ecx + 8] */
  14665     edi = POP32_VAL(esp); /* 0x3802EA1E: pop edi */
  14666     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
  14667     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14668     edx = edx + eax; /* 0x3802EA1F: add edx, eax */
  14669     _flag_k = FK_ADD;
  14670     esi = POP32_VAL(esp); /* 0x3802EA21: pop esi */
  14671     MEM32(ecx + 0x8) = edx; /* 0x3802EA22: mov dword ptr [ecx + 8], edx */
  14672     ebx = POP32_VAL(esp); /* 0x3802EA25: pop ebx */
  14673     esp = ebp; /* 0x3802EA26: mov esp, ebp */
  14674     ebp = POP32_VAL(esp); /* 0x3802EA28: pop ebp */
  14675     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802EA29: ret 0xc */
  14676 L_3802EA2C:
  14677     /* test edi, edi */ /* 0x3802EA2C: test edi, edi */
  14678     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
  14679     _cf = 0;
  14680     _flag_k = FK_TEST;
  14681     if (TEST_Z(_flag_a, _flag_b)) goto L_3802EACE; /* 0x3802EA2E: jbe 0x3802eace */
  14682 L_3802EA34:
  14683     if (4u) _cf = (((edi) >> 28) & 1u); /* 0x3802EA34: shl edi, 4 */
  14684     if (4u) { _flag_a = recomp_flags_pack((edi << 4u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14685     edi = edi << 4u; /* 0x3802EA34: shl edi, 4 */
  14686     eax = edi; /* 0x3802EA37: mov eax, edi */
  14687     edi = esi; /* 0x3802EA39: mov edi, esi */
  14688     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
  14689     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14690     edi = edi - eax; /* 0x3802EA3B: sub edi, eax */
  14691     _flag_k = FK_CMP;
  14692     /* cmp edi, esi */ /* 0x3802EA3D: cmp edi, esi */
  14693     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(esi);
  14694     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14695     _flag_k = FK_CMP;
  14696     MEM32(ebp + 0xC) = esi; /* 0x3802EA3F: mov dword ptr [ebp + 0xc], esi */
  14697     MEM32(ebp + 0x8) = eax; /* 0x3802EA42: mov dword ptr [ebp + 8], eax */
  14698     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802EA67; /* 0x3802EA45: je 0x3802ea67 */
  14699 L_3802EA47:
  14700     eax = MEM32(ebp + 0xC); /* 0x3802EA47: mov eax, dword ptr [ebp + 0xc] */
  14701     PUSH32(esp, edi); /* 0x3802EA4A: push edi */
  14702     PUSH32(esp, eax); /* 0x3802EA4B: push eax */
  14703     RECOMP_ICALL(0x3802F580u); /* 0x3802EA4C: call 0x3802f580 */ /* not lifted */
  14704     RECOMP_FLAGS_IN();
  14705     edx = MEM32(ebp + 0xC); /* 0x3802EA51: mov edx, dword ptr [ebp + 0xc] */
  14706     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u);
  14707     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14708     edx = edx + 0x10u; /* 0x3802EA54: add edx, 0x10 */
  14709     _flag_k = FK_ADD;
  14710     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(0x10u);
  14711     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14712     edi = edi + 0x10u; /* 0x3802EA57: add edi, 0x10 */
  14713     _flag_k = FK_ADD;
  14714     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  14715     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14716     esp = esp + 8; /* 0x3802EA5A: add esp, 8 */
  14717     _flag_k = FK_ADD;
  14718     /* cmp edi, esi */ /* 0x3802EA5D: cmp edi, esi */
  14719     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(esi);
  14720     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14721     _flag_k = FK_CMP;
  14722     MEM32(ebp + 0xC) = edx; /* 0x3802EA5F: mov dword ptr [ebp + 0xc], edx */
  14723     RECOMP_BACKEDGE();
  14724     if (CMP_NE(_flag_a, _flag_b)) goto L_3802EA47; /* 0x3802EA62: jne 0x3802ea47 */
  14725 L_3802EA64:
  14726     ecx = MEM32(ebp + (-0x4)); /* 0x3802EA64: mov ecx, dword ptr [ebp - 4] */
  14727 L_3802EA67:
  14728     edx = MEM32(ecx + 0x8); /* 0x3802EA67: mov edx, dword ptr [ecx + 8] */
  14729     edi = MEM32(ebp + 0x8); /* 0x3802EA6A: mov edi, dword ptr [ebp + 8] */
  14730     eax = edx; /* 0x3802EA6D: mov eax, edx */
  14731     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
  14732     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14733     eax = eax - edi; /* 0x3802EA6F: sub eax, edi */
  14734     _flag_k = FK_CMP;
  14735     /* cmp ebx, eax */ /* 0x3802EA71: cmp ebx, eax */
  14736     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(eax);
  14737     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14738     _flag_k = FK_CMP;
  14739     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802EA9C; /* 0x3802EA73: je 0x3802ea9c */
  14740 L_3802EA75:
  14741     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x10u);
  14742     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14743     eax = eax - 0x10u; /* 0x3802EA75: sub eax, 0x10 */
  14744     _flag_k = FK_CMP;
  14745     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x10u);
  14746     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14747     edx = edx - 0x10u; /* 0x3802EA78: sub edx, 0x10 */
  14748     _flag_k = FK_CMP;
  14749     /* cmp eax, ebx */ /* 0x3802EA7B: cmp eax, ebx */
  14750     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  14751     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14752     _flag_k = FK_CMP;
  14753     ecx = eax; /* 0x3802EA7D: mov ecx, eax */
  14754     edi = MEM32(ecx); /* 0x3802EA7F: mov edi, dword ptr [ecx] */
  14755     esi = edx; /* 0x3802EA81: mov esi, edx */
  14756     MEM32(esi) = edi; /* 0x3802EA83: mov dword ptr [esi], edi */
  14757     edi = MEM32(ecx + 0x4); /* 0x3802EA85: mov edi, dword ptr [ecx + 4] */
  14758     MEM32(esi + 0x4) = edi; /* 0x3802EA88: mov dword ptr [esi + 4], edi */
  14759     edi = MEM32(ecx + 0x8); /* 0x3802EA8B: mov edi, dword ptr [ecx + 8] */
  14760     MEM32(esi + 0x8) = edi; /* 0x3802EA8E: mov dword ptr [esi + 8], edi */
  14761     ecx = MEM32(ecx + 0xC); /* 0x3802EA91: mov ecx, dword ptr [ecx + 0xc] */
  14762     MEM32(esi + 0xC) = ecx; /* 0x3802EA94: mov dword ptr [esi + 0xc], ecx */
  14763     RECOMP_BACKEDGE();
  14764     if (CMP_NE(_flag_a, _flag_b)) goto L_3802EA75; /* 0x3802EA97: jne 0x3802ea75 */
  14765 L_3802EA99:
  14766     ecx = MEM32(ebp + (-0x4)); /* 0x3802EA99: mov ecx, dword ptr [ebp - 4] */
  14767 L_3802EA9C:
  14768     edx = MEM32(ebp + 0x8); /* 0x3802EA9C: mov edx, dword ptr [ebp + 8] */
  14769     eax = edx + ebx; /* 0x3802EA9F: lea eax, [edx + ebx] */
  14770     /* cmp ebx, eax */ /* 0x3802EAA2: cmp ebx, eax */
  14771     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(eax);
  14772     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14773     _flag_k = FK_CMP;
  14774     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802EAC8; /* 0x3802EAA4: je 0x3802eac8 */
  14775 L_3802EAA6:
  14776     edx = MEM32(ebp + 0x10); /* 0x3802EAA6: mov edx, dword ptr [ebp + 0x10] */
  14777     edi = MEM32(edx); /* 0x3802EAA9: mov edi, dword ptr [edx] */
  14778     esi = ebx; /* 0x3802EAAB: mov esi, ebx */
  14779     MEM32(esi) = edi; /* 0x3802EAAD: mov dword ptr [esi], edi */
  14780     edi = MEM32(edx + 0x4); /* 0x3802EAAF: mov edi, dword ptr [edx + 4] */
  14781     MEM32(esi + 0x4) = edi; /* 0x3802EAB2: mov dword ptr [esi + 4], edi */
  14782     edi = MEM32(edx + 0x8); /* 0x3802EAB5: mov edi, dword ptr [edx + 8] */
  14783     MEM32(esi + 0x8) = edi; /* 0x3802EAB8: mov dword ptr [esi + 8], edi */
  14784     edx = MEM32(edx + 0xC); /* 0x3802EABB: mov edx, dword ptr [edx + 0xc] */
  14785     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0x10u);
  14786     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14787     ebx = ebx + 0x10u; /* 0x3802EABE: add ebx, 0x10 */
  14788     _flag_k = FK_ADD;
  14789     /* cmp ebx, eax */ /* 0x3802EAC1: cmp ebx, eax */
  14790     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(eax);
  14791     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14792     _flag_k = FK_CMP;
  14793     MEM32(esi + 0xC) = edx; /* 0x3802EAC3: mov dword ptr [esi + 0xc], edx */
  14794     RECOMP_BACKEDGE();
  14795     if (CMP_NE(_flag_a, _flag_b)) goto L_3802EAA6; /* 0x3802EAC6: jne 0x3802eaa6 */
  14796 L_3802EAC8:
  14797     eax = MEM32(ebp + 0x8); /* 0x3802EAC8: mov eax, dword ptr [ebp + 8] */
  14798 L_3802EACB:
  14799     _flag_a = (uint32_t)(MEM32(ecx + 0x8)); _flag_b = (uint32_t)(eax);
  14800     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14801     MEM32(ecx + 0x8) = MEM32(ecx + 0x8) + eax; /* 0x3802EACB: add dword ptr [ecx + 8], eax */
  14802     _flag_k = FK_ADD;
  14803 L_3802EACE:
  14804     edi = POP32_VAL(esp); /* 0x3802EACE: pop edi */
  14805     esi = POP32_VAL(esp); /* 0x3802EACF: pop esi */
  14806     ebx = POP32_VAL(esp); /* 0x3802EAD0: pop ebx */
  14807     esp = ebp; /* 0x3802EAD1: mov esp, ebp */
  14808     ebp = POP32_VAL(esp); /* 0x3802EAD3: pop ebp */
  14809     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802EAD4: ret 0xc */
  14810     RECOMP_REGS_OUT();
  14811 }
  14812 
  14813 void sub_3802EAE0(void) {
  14814     int _fpu_cmp = 0;
  14815     uint32_t _cf = 0;
  14816     int _df = 1;
  14817     uint32_t _flag_k = FK_NONE;
  14818     uint32_t _flag_a = 0, _flag_b = 0;
  14819     uint32_t _itail_tgt = 0;
  14820     RECOMP_REGS_LOCALS
  14821     RECOMP_ENTER(0x3802EAE0u);
  14822 
  14823 L_3802EAE0:
  14824     eax = MEM32(ecx + 0x4); /* 0x3802EAE0: mov eax, dword ptr [ecx + 4] */
  14825     /* test eax, eax */ /* 0x3802EAE3: test eax, eax */
  14826     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  14827     _cf = 0;
  14828     _flag_k = FK_TEST;
  14829     if (TEST_NZ(_flag_a, _flag_b)) goto L_3802EAE8; /* 0x3802EAE5: jne 0x3802eae8 */
  14830 L_3802EAE7:
  14831     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802EAE7: ret  */
  14832 L_3802EAE8:
  14833     ecx = MEM32(ecx + 0x8); /* 0x3802EAE8: mov ecx, dword ptr [ecx + 8] */
  14834     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
  14835     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14836     ecx = ecx - eax; /* 0x3802EAEB: sub ecx, eax */
  14837     _flag_k = FK_CMP;
  14838     eax = 0x2AAAAAABu; /* 0x3802EAED: mov eax, 0x2aaaaaab */
  14839     { int64_t _r = (int64_t)(int32_t)eax * (int32_t)(ecx); /* 0x3802EAF2: imul ecx */
  14840       eax = (uint32_t)_r; edx = (uint32_t)(_r >> 32); uint32_t _ov = _r != (int32_t)_r;
  14841       _flag_k = FK_EFLAGS; _flag_a = _ov ? 0x801u : 0u; _flag_b = 0; _cf = _ov; }
  14842     if (2u) _cf = (((edx) >> 1) & 1u); /* 0x3802EAF4: sar edx, 2 */
  14843     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14844     edx = (uint32_t)((int32_t)edx >> 2u);
  14845     eax = edx; /* 0x3802EAF7: mov eax, edx */
  14846     if (31u) _cf = (((eax) >> 30) & 1u); /* 0x3802EAF9: shr eax, 0x1f */
  14847     if (31u) { _flag_a = recomp_flags_pack((eax >> 31u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14848     eax = eax >> 31u; /* 0x3802EAF9: shr eax, 0x1f */
  14849     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
  14850     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14851     edx = edx + eax; /* 0x3802EAFC: add edx, eax */
  14852     _flag_k = FK_ADD;
  14853     eax = edx; /* 0x3802EAFE: mov eax, edx */
  14854     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3802EB00: ret  */
  14855     RECOMP_REGS_OUT();
  14856 }
  14857 
  14858 void sub_3802EB10(void) {
  14859     int _fpu_cmp = 0;
  14860     uint32_t _cf = 0;
  14861     int _df = 1;
  14862     uint32_t _flag_k = FK_NONE;
  14863     uint32_t _flag_a = 0, _flag_b = 0;
  14864     uint32_t _itail_tgt = 0;
  14865     RECOMP_REGS_LOCALS
  14866     RECOMP_ENTER(0x3802EB10u);
  14867 
  14868 L_3802EB10:
  14869     PUSH32(esp, ebp); /* 0x3802EB10: push ebp */
  14870     ebp = esp; /* 0x3802EB11: mov ebp, esp */
  14871     edx = MEM32(ebp + 0x8); /* 0x3802EB13: mov edx, dword ptr [ebp + 8] */
  14872     PUSH32(esp, ebx); /* 0x3802EB16: push ebx */
  14873     ebx = MEM32(ebp + 0xC); /* 0x3802EB17: mov ebx, dword ptr [ebp + 0xc] */
  14874     /* cmp edx, ebx */ /* 0x3802EB1A: cmp edx, ebx */
  14875     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ebx);
  14876     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14877     _flag_k = FK_CMP;
  14878     if (CMP_EQ(_flag_a, _flag_b)) goto L_3802EB43; /* 0x3802EB1C: je 0x3802eb43 */
  14879 L_3802EB1E:
  14880     eax = MEM32(ebp + 0x10); /* 0x3802EB1E: mov eax, dword ptr [ebp + 0x10] */
  14881     PUSH32(esp, esi); /* 0x3802EB21: push esi */
  14882     PUSH32(esp, edi); /* 0x3802EB22: push edi */
  14883 L_3802EB23:
  14884     /* test eax, eax */ /* 0x3802EB23: test eax, eax */
  14885     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  14886     _cf = 0;
  14887     _flag_k = FK_TEST;
  14888     if (TEST_Z(_flag_a, _flag_b)) goto L_3802EB32; /* 0x3802EB25: je 0x3802eb32 */
  14889 L_3802EB27:
  14890     ecx = 6; /* 0x3802EB27: mov ecx, 6 */
  14891     esi = edx; /* 0x3802EB2C: mov esi, edx */
  14892     edi = eax; /* 0x3802EB2E: mov edi, eax */
  14893     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3802EB30: 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; }
  14894 L_3802EB32:
  14895     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0x18u);
  14896     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14897     edx = edx + 0x18u; /* 0x3802EB32: add edx, 0x18 */
  14898     _flag_k = FK_ADD;
  14899     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x18u);
  14900     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14901     eax = eax + 0x18u; /* 0x3802EB35: add eax, 0x18 */
  14902     _flag_k = FK_ADD;
  14903     /* cmp edx, ebx */ /* 0x3802EB38: cmp edx, ebx */
  14904     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ebx);
  14905     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14906     _flag_k = FK_CMP;
  14907     RECOMP_BACKEDGE();
  14908     if (CMP_NE(_flag_a, _flag_b)) goto L_3802EB23; /* 0x3802EB3A: jne 0x3802eb23 */
  14909 L_3802EB3C:
  14910     edi = POP32_VAL(esp); /* 0x3802EB3C: pop edi */
  14911     esi = POP32_VAL(esp); /* 0x3802EB3D: pop esi */
  14912     ebx = POP32_VAL(esp); /* 0x3802EB3E: pop ebx */
  14913     ebp = POP32_VAL(esp); /* 0x3802EB3F: pop ebp */
  14914     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802EB40: ret 0xc */
  14915 L_3802EB43:
  14916     eax = MEM32(ebp + 0x10); /* 0x3802EB43: mov eax, dword ptr [ebp + 0x10] */
  14917     ebx = POP32_VAL(esp); /* 0x3802EB46: pop ebx */
  14918     ebp = POP32_VAL(esp); /* 0x3802EB47: pop ebp */
  14919     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802EB48: ret 0xc */
  14920     RECOMP_REGS_OUT();
  14921 }
  14922 
  14923 void sub_3802EB50(void) {
  14924     int _fpu_cmp = 0;
  14925     uint32_t _cf = 0;
  14926     int _df = 1;
  14927     uint32_t _flag_k = FK_NONE;
  14928     uint32_t _flag_a = 0, _flag_b = 0;
  14929     uint32_t _itail_tgt = 0;
  14930     RECOMP_REGS_LOCALS
  14931     RECOMP_ENTER(0x3802EB50u);
  14932 
  14933 L_3802EB50:
  14934     PUSH32(esp, ebp); /* 0x3802EB50: push ebp */
  14935     ebp = esp; /* 0x3802EB51: mov ebp, esp */
  14936     eax = MEM32(ebp + 0xC); /* 0x3802EB53: mov eax, dword ptr [ebp + 0xc] */
  14937     /* test eax, eax */ /* 0x3802EB56: test eax, eax */
  14938     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  14939     _cf = 0;
  14940     _flag_k = FK_TEST;
  14941     if (TEST_Z(_flag_a, _flag_b)) goto L_3802EB7D; /* 0x3802EB58: jbe 0x3802eb7d */
  14942 L_3802EB5A:
  14943     PUSH32(esp, ebx); /* 0x3802EB5A: push ebx */
  14944     ebx = MEM32(ebp + 0x10); /* 0x3802EB5B: mov ebx, dword ptr [ebp + 0x10] */
  14945     PUSH32(esp, esi); /* 0x3802EB5E: push esi */
  14946     edx = eax; /* 0x3802EB5F: mov edx, eax */
  14947     eax = MEM32(ebp + 0x8); /* 0x3802EB61: mov eax, dword ptr [ebp + 8] */
  14948     PUSH32(esp, edi); /* 0x3802EB64: push edi */
  14949 L_3802EB65:
  14950     /* test eax, eax */ /* 0x3802EB65: test eax, eax */
  14951     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  14952     _cf = 0;
  14953     _flag_k = FK_TEST;
  14954     if (TEST_Z(_flag_a, _flag_b)) goto L_3802EB74; /* 0x3802EB67: je 0x3802eb74 */
  14955 L_3802EB69:
  14956     ecx = 6; /* 0x3802EB69: mov ecx, 6 */
  14957     esi = ebx; /* 0x3802EB6E: mov esi, ebx */
  14958     edi = eax; /* 0x3802EB70: mov edi, eax */
  14959     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3802EB72: 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; }
  14960 L_3802EB74:
  14961     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0x18u);
  14962     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14963     eax = eax + 0x18u; /* 0x3802EB74: add eax, 0x18 */
  14964     _flag_k = FK_ADD;
  14965     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
  14966     edx = edx - 1; /* 0x3802EB77: dec edx */
  14967     _flag_k = FK_DEC;
  14968     RECOMP_BACKEDGE();
  14969     if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3802EB65; /* 0x3802EB78: jne 0x3802eb65 */
  14970 L_3802EB7A:
  14971     edi = POP32_VAL(esp); /* 0x3802EB7A: pop edi */
  14972     esi = POP32_VAL(esp); /* 0x3802EB7B: pop esi */
  14973     ebx = POP32_VAL(esp); /* 0x3802EB7C: pop ebx */
  14974 L_3802EB7D:
  14975     ebp = POP32_VAL(esp); /* 0x3802EB7D: pop ebp */
  14976     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3802EB7E: ret 0xc */
  14977     RECOMP_REGS_OUT();
  14978 }