aorecomp

Anarchy Online classic in the browser

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


client/game/hhr.dll/lifted-0004.c (818461B)


      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_310099D0(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(0x310099D0u);
     17 
     18 L_310099D0:
     19     _flag_a = (uint32_t)(MEM32(0x31057E40)); _flag_b = (uint32_t)(1);
     20     MEM32(0x31057E40) = MEM32(0x31057E40) + 1; /* 0x310099D0: inc dword ptr [0x31057e40] */
     21     _flag_k = FK_INC;
     22     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x310099D6: ret  */
     23     RECOMP_REGS_OUT();
     24 }
     25 
     26 void sub_310099E0(void) {
     27     int _fpu_cmp = 0;
     28     uint32_t _cf = 0;
     29     int _df = 1;
     30     uint32_t _flag_k = FK_NONE;
     31     uint32_t _flag_a = 0, _flag_b = 0;
     32     uint32_t _itail_tgt = 0;
     33     RECOMP_REGS_LOCALS
     34     RECOMP_ENTER(0x310099E0u);
     35 
     36 L_310099E0:
     37     _flag_a = (uint32_t)(MEM32(0x31057E40)); _flag_b = (uint32_t)(1);
     38     MEM32(0x31057E40) = MEM32(0x31057E40) - 1; /* 0x310099E0: dec dword ptr [0x31057e40] */
     39     _flag_k = FK_DEC;
     40     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x310099E6: ret  */
     41     RECOMP_REGS_OUT();
     42 }
     43 
     44 void sub_310099F0(void) {
     45     int _fpu_cmp = 0;
     46     uint32_t _cf = 0;
     47     int _df = 1;
     48     uint32_t _flag_k = FK_NONE;
     49     uint32_t _flag_a = 0, _flag_b = 0;
     50     uint32_t _itail_tgt = 0;
     51     RECOMP_REGS_LOCALS
     52     RECOMP_ENTER(0x310099F0u);
     53 
     54 L_310099F0:
     55     PUSH32(esp, ebp); /* 0x310099F0: push ebp */
     56     ebp = esp; /* 0x310099F1: mov ebp, esp */
     57     PUSH32(esp, ecx); /* 0x310099F3: push ecx */
     58     PUSH32(esp, ebx); /* 0x310099F4: push ebx */
     59     PUSH32(esp, esi); /* 0x310099F5: push esi */
     60     esi = MEM32(ebp + 0xC); /* 0x310099F6: mov esi, dword ptr [ebp + 0xc] */
     61     PUSH32(esp, edi); /* 0x310099F9: push edi */
     62     edi = ecx; /* 0x310099FA: mov edi, ecx */
     63     ecx = ebp + 0xC; /* 0x310099FC: lea ecx, [ebp + 0xc] */
     64     RECOMP_ICALL(0x31005A20u); /* 0x310099FF: call 0x31005a20 */ /* not lifted */
     65     RECOMP_FLAGS_IN();
     66     edx = MEM32(esi); /* 0x31009A04: mov edx, dword ptr [esi] */
     67     eax = MEM32(edi + 0x8); /* 0x31009A06: mov eax, dword ptr [edi + 8] */
     68     /* cmp edx, eax */ /* 0x31009A09: cmp edx, eax */
     69     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
     70     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
     71     _flag_k = FK_CMP;
     72     MEM32(ebp + (-0x4)) = esi; /* 0x31009A0B: mov dword ptr [ebp - 4], esi */
     73     if (CMP_NE(_flag_a, _flag_b)) goto L_31009A30; /* 0x31009A0E: jne 0x31009a30 */
     74 L_31009A10:
     75     eax = MEM32(esi + 0x8); /* 0x31009A10: mov eax, dword ptr [esi + 8] */
     76 L_31009A13:
     77     ecx = MEM32(ebp + (-0x4)); /* 0x31009A13: mov ecx, dword ptr [ebp - 4] */
     78     edx = MEM32(ecx + 0x4); /* 0x31009A16: mov edx, dword ptr [ecx + 4] */
     79     MEM32(eax + 0x4) = edx; /* 0x31009A19: mov dword ptr [eax + 4], edx */
     80     ecx = MEM32(edi + 0x4); /* 0x31009A1C: mov ecx, dword ptr [edi + 4] */
     81     /* cmp MEM32(ecx + 0x4), esi */ /* 0x31009A1F: cmp dword ptr [ecx + 4], esi */
     82     _flag_a = (uint32_t)(MEM32(ecx + 0x4)); _flag_b = (uint32_t)(esi);
     83     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
     84     _flag_k = FK_CMP;
     85     if (CMP_NE(_flag_a, _flag_b)) goto L_31009AB3; /* 0x31009A22: jne 0x31009ab3 */
     86 L_31009A28:
     87     MEM32(ecx + 0x4) = eax; /* 0x31009A28: mov dword ptr [ecx + 4], eax */
     88     goto L_31009AC1; /* 0x31009A2B: jmp 0x31009ac1 */
     89 L_31009A30:
     90     ecx = MEM32(esi + 0x8); /* 0x31009A30: mov ecx, dword ptr [esi + 8] */
     91     /* cmp ecx, eax */ /* 0x31009A33: cmp ecx, eax */
     92     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
     93     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
     94     _flag_k = FK_CMP;
     95     if (CMP_NE(_flag_a, _flag_b)) goto L_31009A3B; /* 0x31009A35: jne 0x31009a3b */
     96 L_31009A37:
     97     eax = edx; /* 0x31009A37: mov eax, edx */
     98     RECOMP_BACKEDGE();
     99     goto L_31009A13; /* 0x31009A39: jmp 0x31009a13 */
    100 L_31009A3B:
    101     eax = MEM32(ecx); /* 0x31009A3B: mov eax, dword ptr [ecx] */
    102     SET_LO8(ebx, MEM8(eax + 0x15)); /* 0x31009A3D: mov bl, byte ptr [eax + 0x15] */
    103     /* test LO8(ebx), LO8(ebx) */ /* 0x31009A40: test bl, bl */
    104     _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    105     _cf = 0;
    106     _flag_k = FK_NARROW(FK_TEST, 24);
    107     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009A4F; /* 0x31009A42: jne 0x31009a4f */
    108 L_31009A44:
    109     ecx = eax; /* 0x31009A44: mov ecx, eax */
    110     eax = MEM32(ecx); /* 0x31009A46: mov eax, dword ptr [ecx] */
    111     SET_LO8(ebx, MEM8(eax + 0x15)); /* 0x31009A48: mov bl, byte ptr [eax + 0x15] */
    112     /* test LO8(ebx), LO8(ebx) */ /* 0x31009A4B: test bl, bl */
    113     _flag_a = (uint32_t)(LO8(ebx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    114     _cf = 0;
    115     _flag_k = FK_NARROW(FK_TEST, 24);
    116     RECOMP_BACKEDGE();
    117     if (TEST_Z(_flag_a, _flag_b)) goto L_31009A44; /* 0x31009A4D: je 0x31009a44 */
    118 L_31009A4F:
    119     /* cmp ecx, esi */ /* 0x31009A4F: cmp ecx, esi */
    120     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(esi);
    121     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    122     _flag_k = FK_CMP;
    123     eax = MEM32(ecx + 0x8); /* 0x31009A51: mov eax, dword ptr [ecx + 8] */
    124     MEM32(ebp + (-0x4)) = ecx; /* 0x31009A54: mov dword ptr [ebp - 4], ecx */
    125     RECOMP_BACKEDGE();
    126     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009A13; /* 0x31009A57: je 0x31009a13 */
    127 L_31009A59:
    128     MEM32(edx + 0x4) = ecx; /* 0x31009A59: mov dword ptr [edx + 4], ecx */
    129     edx = MEM32(esi); /* 0x31009A5C: mov edx, dword ptr [esi] */
    130     MEM32(ecx) = edx; /* 0x31009A5E: mov dword ptr [ecx], edx */
    131     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009A60: cmp ecx, dword ptr [esi + 8] */
    132     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
    133     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    134     _flag_k = FK_CMP;
    135     if (CMP_NE(_flag_a, _flag_b)) goto L_31009A6A; /* 0x31009A63: jne 0x31009a6a */
    136 L_31009A65:
    137     MEM32(eax + 0x4) = ecx; /* 0x31009A65: mov dword ptr [eax + 4], ecx */
    138     goto L_31009A81; /* 0x31009A68: jmp 0x31009a81 */
    139 L_31009A6A:
    140     edx = MEM32(ecx + 0x4); /* 0x31009A6A: mov edx, dword ptr [ecx + 4] */
    141     MEM32(eax + 0x4) = edx; /* 0x31009A6D: mov dword ptr [eax + 4], edx */
    142     edx = MEM32(ecx + 0x4); /* 0x31009A70: mov edx, dword ptr [ecx + 4] */
    143     MEM32(edx) = eax; /* 0x31009A73: mov dword ptr [edx], eax */
    144     edx = MEM32(esi + 0x8); /* 0x31009A75: mov edx, dword ptr [esi + 8] */
    145     MEM32(ecx + 0x8) = edx; /* 0x31009A78: mov dword ptr [ecx + 8], edx */
    146     edx = MEM32(esi + 0x8); /* 0x31009A7B: mov edx, dword ptr [esi + 8] */
    147     MEM32(edx + 0x4) = ecx; /* 0x31009A7E: mov dword ptr [edx + 4], ecx */
    148 L_31009A81:
    149     edx = MEM32(edi + 0x4); /* 0x31009A81: mov edx, dword ptr [edi + 4] */
    150     /* cmp MEM32(edx + 0x4), esi */ /* 0x31009A84: cmp dword ptr [edx + 4], esi */
    151     _flag_a = (uint32_t)(MEM32(edx + 0x4)); _flag_b = (uint32_t)(esi);
    152     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    153     _flag_k = FK_CMP;
    154     if (CMP_NE(_flag_a, _flag_b)) goto L_31009A8E; /* 0x31009A87: jne 0x31009a8e */
    155 L_31009A89:
    156     MEM32(edx + 0x4) = ecx; /* 0x31009A89: mov dword ptr [edx + 4], ecx */
    157     goto L_31009A9C; /* 0x31009A8C: jmp 0x31009a9c */
    158 L_31009A8E:
    159     edx = MEM32(esi + 0x4); /* 0x31009A8E: mov edx, dword ptr [esi + 4] */
    160     /* cmp MEM32(edx), esi */ /* 0x31009A91: cmp dword ptr [edx], esi */
    161     _flag_a = (uint32_t)(MEM32(edx)); _flag_b = (uint32_t)(esi);
    162     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    163     _flag_k = FK_CMP;
    164     if (CMP_NE(_flag_a, _flag_b)) goto L_31009A99; /* 0x31009A93: jne 0x31009a99 */
    165 L_31009A95:
    166     MEM32(edx) = ecx; /* 0x31009A95: mov dword ptr [edx], ecx */
    167     goto L_31009A9C; /* 0x31009A97: jmp 0x31009a9c */
    168 L_31009A99:
    169     MEM32(edx + 0x8) = ecx; /* 0x31009A99: mov dword ptr [edx + 8], ecx */
    170 L_31009A9C:
    171     edx = MEM32(esi + 0x4); /* 0x31009A9C: mov edx, dword ptr [esi + 4] */
    172     MEM32(ecx + 0x4) = edx; /* 0x31009A9F: mov dword ptr [ecx + 4], edx */
    173     SET_LO8(ebx, MEM8(esi + 0x14)); /* 0x31009AA2: mov bl, byte ptr [esi + 0x14] */
    174     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009AA5: mov dl, byte ptr [ecx + 0x14] */
    175     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009AA8: mov byte ptr [ecx + 0x14], bl */
    176     MEM8(esi + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009AAB: mov byte ptr [esi + 0x14], dl */
    177     MEM32(ebp + (-0x4)) = esi; /* 0x31009AAE: mov dword ptr [ebp - 4], esi */
    178     goto L_31009B18; /* 0x31009AB1: jmp 0x31009b18 */
    179 L_31009AB3:
    180     ecx = MEM32(esi + 0x4); /* 0x31009AB3: mov ecx, dword ptr [esi + 4] */
    181     /* cmp MEM32(ecx), esi */ /* 0x31009AB6: cmp dword ptr [ecx], esi */
    182     _flag_a = (uint32_t)(MEM32(ecx)); _flag_b = (uint32_t)(esi);
    183     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    184     _flag_k = FK_CMP;
    185     if (CMP_NE(_flag_a, _flag_b)) goto L_31009ABE; /* 0x31009AB8: jne 0x31009abe */
    186 L_31009ABA:
    187     MEM32(ecx) = eax; /* 0x31009ABA: mov dword ptr [ecx], eax */
    188     goto L_31009AC1; /* 0x31009ABC: jmp 0x31009ac1 */
    189 L_31009ABE:
    190     MEM32(ecx + 0x8) = eax; /* 0x31009ABE: mov dword ptr [ecx + 8], eax */
    191 L_31009AC1:
    192     ebx = MEM32(edi + 0x4); /* 0x31009AC1: mov ebx, dword ptr [edi + 4] */
    193     /* cmp MEM32(ebx), esi */ /* 0x31009AC4: cmp dword ptr [ebx], esi */
    194     _flag_a = (uint32_t)(MEM32(ebx)); _flag_b = (uint32_t)(esi);
    195     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    196     _flag_k = FK_CMP;
    197     if (CMP_NE(_flag_a, _flag_b)) goto L_31009AEB; /* 0x31009AC6: jne 0x31009aeb */
    198 L_31009AC8:
    199     ecx = MEM32(esi + 0x8); /* 0x31009AC8: mov ecx, dword ptr [esi + 8] */
    200     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x31009ACB: cmp ecx, dword ptr [edi + 8] */
    201     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    202     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    203     _flag_k = FK_CMP;
    204     if (CMP_NE(_flag_a, _flag_b)) goto L_31009AD5; /* 0x31009ACE: jne 0x31009ad5 */
    205 L_31009AD0:
    206     edx = MEM32(esi + 0x4); /* 0x31009AD0: mov edx, dword ptr [esi + 4] */
    207     goto L_31009AE9; /* 0x31009AD3: jmp 0x31009ae9 */
    208 L_31009AD5:
    209     ecx = MEM32(eax); /* 0x31009AD5: mov ecx, dword ptr [eax] */
    210     /* cmp MEM8(ecx + 0x15), 0 */ /* 0x31009AD7: cmp byte ptr [ecx + 0x15], 0 */
    211     _flag_a = (uint32_t)(MEM8(ecx + 0x15)) << 24; _flag_b = (uint32_t)(0) << 24;
    212     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    213     _flag_k = FK_NARROW(FK_CMP, 24);
    214     edx = eax; /* 0x31009ADB: mov edx, eax */
    215     if (CMP_NE(_flag_a, _flag_b)) goto L_31009AE9; /* 0x31009ADD: jne 0x31009ae9 */
    216 L_31009ADF:
    217     edx = ecx; /* 0x31009ADF: mov edx, ecx */
    218     ecx = MEM32(edx); /* 0x31009AE1: mov ecx, dword ptr [edx] */
    219     /* cmp MEM8(ecx + 0x15), 0 */ /* 0x31009AE3: cmp byte ptr [ecx + 0x15], 0 */
    220     _flag_a = (uint32_t)(MEM8(ecx + 0x15)) << 24; _flag_b = (uint32_t)(0) << 24;
    221     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    222     _flag_k = FK_NARROW(FK_CMP, 24);
    223     RECOMP_BACKEDGE();
    224     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009ADF; /* 0x31009AE7: je 0x31009adf */
    225 L_31009AE9:
    226     MEM32(ebx) = edx; /* 0x31009AE9: mov dword ptr [ebx], edx */
    227 L_31009AEB:
    228     ebx = MEM32(edi + 0x4); /* 0x31009AEB: mov ebx, dword ptr [edi + 4] */
    229     /* cmp MEM32(ebx + 0x8), esi */ /* 0x31009AEE: cmp dword ptr [ebx + 8], esi */
    230     _flag_a = (uint32_t)(MEM32(ebx + 0x8)); _flag_b = (uint32_t)(esi);
    231     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    232     _flag_k = FK_CMP;
    233     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B18; /* 0x31009AF1: jne 0x31009b18 */
    234 L_31009AF3:
    235     ecx = MEM32(esi); /* 0x31009AF3: mov ecx, dword ptr [esi] */
    236     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x31009AF5: cmp ecx, dword ptr [edi + 8] */
    237     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    238     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    239     _flag_k = FK_CMP;
    240     if (CMP_NE(_flag_a, _flag_b)) goto L_31009AFF; /* 0x31009AF8: jne 0x31009aff */
    241 L_31009AFA:
    242     edx = MEM32(esi + 0x4); /* 0x31009AFA: mov edx, dword ptr [esi + 4] */
    243     goto L_31009B15; /* 0x31009AFD: jmp 0x31009b15 */
    244 L_31009AFF:
    245     ecx = MEM32(eax + 0x8); /* 0x31009AFF: mov ecx, dword ptr [eax + 8] */
    246     /* cmp MEM8(ecx + 0x15), 0 */ /* 0x31009B02: cmp byte ptr [ecx + 0x15], 0 */
    247     _flag_a = (uint32_t)(MEM8(ecx + 0x15)) << 24; _flag_b = (uint32_t)(0) << 24;
    248     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    249     _flag_k = FK_NARROW(FK_CMP, 24);
    250     edx = eax; /* 0x31009B06: mov edx, eax */
    251     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B15; /* 0x31009B08: jne 0x31009b15 */
    252 L_31009B0A:
    253     edx = ecx; /* 0x31009B0A: mov edx, ecx */
    254     ecx = MEM32(edx + 0x8); /* 0x31009B0C: mov ecx, dword ptr [edx + 8] */
    255     /* cmp MEM8(ecx + 0x15), 0 */ /* 0x31009B0F: cmp byte ptr [ecx + 0x15], 0 */
    256     _flag_a = (uint32_t)(MEM8(ecx + 0x15)) << 24; _flag_b = (uint32_t)(0) << 24;
    257     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    258     _flag_k = FK_NARROW(FK_CMP, 24);
    259     RECOMP_BACKEDGE();
    260     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B0A; /* 0x31009B13: je 0x31009b0a */
    261 L_31009B15:
    262     MEM32(ebx + 0x8) = edx; /* 0x31009B15: mov dword ptr [ebx + 8], edx */
    263 L_31009B18:
    264     ecx = MEM32(ebp + (-0x4)); /* 0x31009B18: mov ecx, dword ptr [ebp - 4] */
    265     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B1B: mov dl, byte ptr [ecx + 0x14] */
    266     SET_LO8(ebx, 1); /* 0x31009B1E: mov bl, 1 */
    267     /* cmp LO8(edx), LO8(ebx) */ /* 0x31009B20: cmp dl, bl */
    268     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    269     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    270     _flag_k = FK_NARROW(FK_CMP, 24);
    271     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D85; /* 0x31009B22: jne 0x31009d85 */
    272 L_31009B28:
    273     edx = MEM32(edi + 0x4); /* 0x31009B28: mov edx, dword ptr [edi + 4] */
    274     /* cmp eax, MEM32(edx + 0x4) */ /* 0x31009B2B: cmp eax, dword ptr [edx + 4] */
    275     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
    276     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    277     _flag_k = FK_CMP;
    278     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B2E: je 0x31009d82 */
    279 L_31009B34:
    280     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
    281     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    282     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    283     _flag_k = FK_NARROW(FK_CMP, 24);
    284     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
    285 L_31009B3D:
    286     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
    287     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
    288     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
    289     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
    290     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    291     _flag_k = FK_CMP;
    292     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
    293 L_31009B46:
    294     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
    295     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
    296     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
    297     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
    298     _cf = 0;
    299     _flag_k = FK_NARROW(FK_TEST, 24);
    300     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
    301 L_31009B50:
    302     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
    303     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
    304     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
    305     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
    306     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
    307     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
    308     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
    309     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
    310     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
    311     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    312     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    313     _flag_k = FK_CMP;
    314     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
    315 L_31009B6C:
    316     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
    317 L_31009B6F:
    318     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
    319     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
    320     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
    321     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
    322     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
    323     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    324     _flag_k = FK_CMP;
    325     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
    326 L_31009B7D:
    327     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
    328     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
    329 L_31009B82:
    330     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
    331     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
    332     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
    333     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    334     _flag_k = FK_CMP;
    335     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
    336 L_31009B89:
    337     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
    338     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
    339 L_31009B8D:
    340     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
    341 L_31009B90:
    342     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
    343     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
    344     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
    345     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
    346 L_31009B9B:
    347     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
    348     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
    349     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    350     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    351     _flag_k = FK_NARROW(FK_CMP, 24);
    352     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
    353 L_31009BA6:
    354     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
    355     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
    356     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    357     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    358     _flag_k = FK_NARROW(FK_CMP, 24);
    359     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
    360 L_31009BB2:
    361     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
    362 L_31009BB4:
    363     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
    364     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
    365     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
    366     _cf = 0;
    367     _flag_k = FK_NARROW(FK_TEST, 24);
    368     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
    369 L_31009BBB:
    370     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
    371     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
    372     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
    373     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
    374     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
    375     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
    376     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
    377     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
    378     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
    379     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    380     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    381     _flag_k = FK_CMP;
    382     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
    383 L_31009BD7:
    384     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
    385 L_31009BDA:
    386     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
    387     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
    388     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
    389     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
    390     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
    391     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    392     _flag_k = FK_CMP;
    393     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
    394 L_31009BE8:
    395     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
    396     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
    397 L_31009BED:
    398     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
    399     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
    400     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
    401     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    402     _flag_k = FK_CMP;
    403     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
    404 L_31009BF5:
    405     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
    406     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
    407 L_31009BFA:
    408     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
    409 L_31009BFC:
    410     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
    411     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
    412     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
    413     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
    414 L_31009C07:
    415     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
    416     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
    417     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    418     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    419     _flag_k = FK_NARROW(FK_CMP, 24);
    420     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
    421 L_31009C13:
    422     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
    423     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
    424     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    425     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    426     _flag_k = FK_NARROW(FK_CMP, 24);
    427     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
    428 L_31009C1E:
    429     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
    430     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
    431     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
    432     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
    433     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
    434     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    435     _flag_k = FK_CMP;
    436     RECOMP_BACKEDGE();
    437     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
    438 L_31009C31:
    439     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
    440 L_31009C36:
    441     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
    442     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
    443     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    444     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    445     _flag_k = FK_NARROW(FK_CMP, 24);
    446     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
    447 L_31009C3E:
    448     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
    449     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
    450     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
    451     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
    452     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
    453     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
    454     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
    455     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
    456     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    457     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    458     _flag_k = FK_CMP;
    459     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
    460 L_31009C56:
    461     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
    462 L_31009C59:
    463     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
    464     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
    465     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
    466     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
    467     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
    468     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    469     _flag_k = FK_CMP;
    470     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
    471 L_31009C67:
    472     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
    473     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
    474 L_31009C6C:
    475     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
    476     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
    477     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
    478     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    479     _flag_k = FK_CMP;
    480     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
    481 L_31009C74:
    482     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
    483     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
    484 L_31009C79:
    485     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
    486 L_31009C7B:
    487     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
    488     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
    489     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
    490     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
    491 L_31009C87:
    492     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
    493     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
    494     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
    495     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
    496     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
    497     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
    498     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
    499     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
    500     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
    501     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
    502     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
    503     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
    504     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
    505     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    506     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    507     _flag_k = FK_CMP;
    508     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
    509 L_31009CAE:
    510     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
    511 L_31009CB1:
    512     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
    513     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
    514     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
    515     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
    516     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
    517     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    518     _flag_k = FK_CMP;
    519     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
    520 L_31009CBF:
    521     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
    522     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
    523     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
    524 L_31009CC9:
    525     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
    526     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
    527     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
    528     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    529     _flag_k = FK_CMP;
    530     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
    531 L_31009CD0:
    532     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
    533     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
    534     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
    535 L_31009CD9:
    536     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
    537     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
    538     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
    539 L_31009CE3:
    540     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
    541     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
    542     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    543     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    544     _flag_k = FK_NARROW(FK_CMP, 24);
    545     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
    546 L_31009CEA:
    547     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
    548     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
    549     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
    550     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
    551     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
    552     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
    553     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
    554     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
    555     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    556     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    557     _flag_k = FK_CMP;
    558     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
    559 L_31009D03:
    560     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
    561 L_31009D06:
    562     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
    563     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
    564     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
    565     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
    566     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
    567     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    568     _flag_k = FK_CMP;
    569     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
    570 L_31009D14:
    571     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
    572     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
    573 L_31009D19:
    574     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
    575     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
    576     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
    577     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    578     _flag_k = FK_CMP;
    579     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
    580 L_31009D20:
    581     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
    582     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
    583 L_31009D24:
    584     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
    585 L_31009D27:
    586     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
    587     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
    588     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
    589     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
    590 L_31009D31:
    591     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
    592     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
    593     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
    594     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
    595     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
    596     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
    597     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
    598     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
    599     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
    600     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
    601     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
    602     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
    603     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
    604     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    605     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    606     _flag_k = FK_CMP;
    607     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
    608 L_31009D57:
    609     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
    610 L_31009D5A:
    611     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
    612     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
    613     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
    614     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
    615     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
    616     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    617     _flag_k = FK_CMP;
    618     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
    619 L_31009D68:
    620     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
    621     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
    622 L_31009D6D:
    623     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
    624     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
    625     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
    626     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    627     _flag_k = FK_CMP;
    628     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
    629 L_31009D75:
    630     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
    631     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
    632 L_31009D7A:
    633     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
    634 L_31009D7C:
    635     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
    636 L_31009D7F:
    637     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
    638 L_31009D82:
    639     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
    640 L_31009D85:
    641     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
    642     PUSH32(esp, edx); /* 0x31009D88: push edx */
    643     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
    644     RECOMP_FLAGS_IN();
    645     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
    646     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
    647     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
    648     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
    649     esp = esp + 4; /* 0x31009D94: add esp, 4 */
    650     _flag_k = FK_ADD;
    651     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
    652     eax = eax - 1; /* 0x31009D97: dec eax */
    653     _flag_k = FK_DEC;
    654     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
    655     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
    656     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
    657     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
    658     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
    659     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
    660     esp = ebp; /* 0x31009DA3: mov esp, ebp */
    661     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
    662     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
    663     RECOMP_REGS_OUT();
    664 }
    665 
    666 void sub_31009AC1(void) {
    667     int _fpu_cmp = 0;
    668     uint32_t _cf = 0;
    669     int _df = 1;
    670     uint32_t _flag_k = FK_NONE;
    671     uint32_t _flag_a = 0, _flag_b = 0;
    672     uint32_t _itail_tgt = 0;
    673     RECOMP_REGS_LOCALS
    674     RECOMP_ENTER(0x31009AC1u);
    675 
    676 L_31009AC1:
    677     ebx = MEM32(edi + 0x4); /* 0x31009AC1: mov ebx, dword ptr [edi + 4] */
    678     /* cmp MEM32(ebx), esi */ /* 0x31009AC4: cmp dword ptr [ebx], esi */
    679     _flag_a = (uint32_t)(MEM32(ebx)); _flag_b = (uint32_t)(esi);
    680     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    681     _flag_k = FK_CMP;
    682     if (CMP_NE(_flag_a, _flag_b)) goto L_31009AEB; /* 0x31009AC6: jne 0x31009aeb */
    683 L_31009AC8:
    684     ecx = MEM32(esi + 0x8); /* 0x31009AC8: mov ecx, dword ptr [esi + 8] */
    685     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x31009ACB: cmp ecx, dword ptr [edi + 8] */
    686     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    687     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    688     _flag_k = FK_CMP;
    689     if (CMP_NE(_flag_a, _flag_b)) goto L_31009AD5; /* 0x31009ACE: jne 0x31009ad5 */
    690 L_31009AD0:
    691     edx = MEM32(esi + 0x4); /* 0x31009AD0: mov edx, dword ptr [esi + 4] */
    692     goto L_31009AE9; /* 0x31009AD3: jmp 0x31009ae9 */
    693 L_31009AD5:
    694     ecx = MEM32(eax); /* 0x31009AD5: mov ecx, dword ptr [eax] */
    695     /* cmp MEM8(ecx + 0x15), 0 */ /* 0x31009AD7: cmp byte ptr [ecx + 0x15], 0 */
    696     _flag_a = (uint32_t)(MEM8(ecx + 0x15)) << 24; _flag_b = (uint32_t)(0) << 24;
    697     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    698     _flag_k = FK_NARROW(FK_CMP, 24);
    699     edx = eax; /* 0x31009ADB: mov edx, eax */
    700     if (CMP_NE(_flag_a, _flag_b)) goto L_31009AE9; /* 0x31009ADD: jne 0x31009ae9 */
    701 L_31009ADF:
    702     edx = ecx; /* 0x31009ADF: mov edx, ecx */
    703     ecx = MEM32(edx); /* 0x31009AE1: mov ecx, dword ptr [edx] */
    704     /* cmp MEM8(ecx + 0x15), 0 */ /* 0x31009AE3: cmp byte ptr [ecx + 0x15], 0 */
    705     _flag_a = (uint32_t)(MEM8(ecx + 0x15)) << 24; _flag_b = (uint32_t)(0) << 24;
    706     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    707     _flag_k = FK_NARROW(FK_CMP, 24);
    708     RECOMP_BACKEDGE();
    709     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009ADF; /* 0x31009AE7: je 0x31009adf */
    710 L_31009AE9:
    711     MEM32(ebx) = edx; /* 0x31009AE9: mov dword ptr [ebx], edx */
    712 L_31009AEB:
    713     ebx = MEM32(edi + 0x4); /* 0x31009AEB: mov ebx, dword ptr [edi + 4] */
    714     /* cmp MEM32(ebx + 0x8), esi */ /* 0x31009AEE: cmp dword ptr [ebx + 8], esi */
    715     _flag_a = (uint32_t)(MEM32(ebx + 0x8)); _flag_b = (uint32_t)(esi);
    716     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    717     _flag_k = FK_CMP;
    718     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B18; /* 0x31009AF1: jne 0x31009b18 */
    719 L_31009AF3:
    720     ecx = MEM32(esi); /* 0x31009AF3: mov ecx, dword ptr [esi] */
    721     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x31009AF5: cmp ecx, dword ptr [edi + 8] */
    722     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    723     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    724     _flag_k = FK_CMP;
    725     if (CMP_NE(_flag_a, _flag_b)) goto L_31009AFF; /* 0x31009AF8: jne 0x31009aff */
    726 L_31009AFA:
    727     edx = MEM32(esi + 0x4); /* 0x31009AFA: mov edx, dword ptr [esi + 4] */
    728     goto L_31009B15; /* 0x31009AFD: jmp 0x31009b15 */
    729 L_31009AFF:
    730     ecx = MEM32(eax + 0x8); /* 0x31009AFF: mov ecx, dword ptr [eax + 8] */
    731     /* cmp MEM8(ecx + 0x15), 0 */ /* 0x31009B02: cmp byte ptr [ecx + 0x15], 0 */
    732     _flag_a = (uint32_t)(MEM8(ecx + 0x15)) << 24; _flag_b = (uint32_t)(0) << 24;
    733     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    734     _flag_k = FK_NARROW(FK_CMP, 24);
    735     edx = eax; /* 0x31009B06: mov edx, eax */
    736     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B15; /* 0x31009B08: jne 0x31009b15 */
    737 L_31009B0A:
    738     edx = ecx; /* 0x31009B0A: mov edx, ecx */
    739     ecx = MEM32(edx + 0x8); /* 0x31009B0C: mov ecx, dword ptr [edx + 8] */
    740     /* cmp MEM8(ecx + 0x15), 0 */ /* 0x31009B0F: cmp byte ptr [ecx + 0x15], 0 */
    741     _flag_a = (uint32_t)(MEM8(ecx + 0x15)) << 24; _flag_b = (uint32_t)(0) << 24;
    742     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    743     _flag_k = FK_NARROW(FK_CMP, 24);
    744     RECOMP_BACKEDGE();
    745     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B0A; /* 0x31009B13: je 0x31009b0a */
    746 L_31009B15:
    747     MEM32(ebx + 0x8) = edx; /* 0x31009B15: mov dword ptr [ebx + 8], edx */
    748 L_31009B18:
    749     ecx = MEM32(ebp + (-0x4)); /* 0x31009B18: mov ecx, dword ptr [ebp - 4] */
    750     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B1B: mov dl, byte ptr [ecx + 0x14] */
    751     SET_LO8(ebx, 1); /* 0x31009B1E: mov bl, 1 */
    752     /* cmp LO8(edx), LO8(ebx) */ /* 0x31009B20: cmp dl, bl */
    753     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    754     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    755     _flag_k = FK_NARROW(FK_CMP, 24);
    756     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D85; /* 0x31009B22: jne 0x31009d85 */
    757 L_31009B28:
    758     edx = MEM32(edi + 0x4); /* 0x31009B28: mov edx, dword ptr [edi + 4] */
    759     /* cmp eax, MEM32(edx + 0x4) */ /* 0x31009B2B: cmp eax, dword ptr [edx + 4] */
    760     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
    761     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    762     _flag_k = FK_CMP;
    763     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B2E: je 0x31009d82 */
    764 L_31009B34:
    765     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
    766     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    767     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    768     _flag_k = FK_NARROW(FK_CMP, 24);
    769     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
    770 L_31009B3D:
    771     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
    772     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
    773     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
    774     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
    775     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    776     _flag_k = FK_CMP;
    777     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
    778 L_31009B46:
    779     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
    780     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
    781     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
    782     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
    783     _cf = 0;
    784     _flag_k = FK_NARROW(FK_TEST, 24);
    785     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
    786 L_31009B50:
    787     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
    788     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
    789     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
    790     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
    791     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
    792     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
    793     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
    794     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
    795     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
    796     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    797     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    798     _flag_k = FK_CMP;
    799     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
    800 L_31009B6C:
    801     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
    802 L_31009B6F:
    803     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
    804     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
    805     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
    806     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
    807     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
    808     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    809     _flag_k = FK_CMP;
    810     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
    811 L_31009B7D:
    812     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
    813     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
    814 L_31009B82:
    815     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
    816     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
    817     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
    818     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    819     _flag_k = FK_CMP;
    820     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
    821 L_31009B89:
    822     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
    823     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
    824 L_31009B8D:
    825     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
    826 L_31009B90:
    827     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
    828     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
    829     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
    830     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
    831 L_31009B9B:
    832     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
    833     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
    834     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    835     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    836     _flag_k = FK_NARROW(FK_CMP, 24);
    837     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
    838 L_31009BA6:
    839     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
    840     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
    841     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    842     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    843     _flag_k = FK_NARROW(FK_CMP, 24);
    844     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
    845 L_31009BB2:
    846     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
    847 L_31009BB4:
    848     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
    849     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
    850     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
    851     _cf = 0;
    852     _flag_k = FK_NARROW(FK_TEST, 24);
    853     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
    854 L_31009BBB:
    855     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
    856     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
    857     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
    858     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
    859     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
    860     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
    861     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
    862     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
    863     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
    864     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    865     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    866     _flag_k = FK_CMP;
    867     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
    868 L_31009BD7:
    869     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
    870 L_31009BDA:
    871     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
    872     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
    873     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
    874     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
    875     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
    876     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    877     _flag_k = FK_CMP;
    878     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
    879 L_31009BE8:
    880     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
    881     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
    882 L_31009BED:
    883     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
    884     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
    885     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
    886     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    887     _flag_k = FK_CMP;
    888     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
    889 L_31009BF5:
    890     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
    891     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
    892 L_31009BFA:
    893     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
    894 L_31009BFC:
    895     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
    896     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
    897     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
    898     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
    899 L_31009C07:
    900     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
    901     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
    902     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    903     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    904     _flag_k = FK_NARROW(FK_CMP, 24);
    905     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
    906 L_31009C13:
    907     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
    908     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
    909     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    910     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    911     _flag_k = FK_NARROW(FK_CMP, 24);
    912     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
    913 L_31009C1E:
    914     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
    915     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
    916     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
    917     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
    918     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
    919     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    920     _flag_k = FK_CMP;
    921     RECOMP_BACKEDGE();
    922     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
    923 L_31009C31:
    924     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
    925 L_31009C36:
    926     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
    927     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
    928     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
    929     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    930     _flag_k = FK_NARROW(FK_CMP, 24);
    931     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
    932 L_31009C3E:
    933     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
    934     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
    935     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
    936     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
    937     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
    938     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
    939     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
    940     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
    941     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    942     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    943     _flag_k = FK_CMP;
    944     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
    945 L_31009C56:
    946     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
    947 L_31009C59:
    948     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
    949     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
    950     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
    951     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
    952     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
    953     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    954     _flag_k = FK_CMP;
    955     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
    956 L_31009C67:
    957     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
    958     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
    959 L_31009C6C:
    960     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
    961     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
    962     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
    963     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    964     _flag_k = FK_CMP;
    965     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
    966 L_31009C74:
    967     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
    968     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
    969 L_31009C79:
    970     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
    971 L_31009C7B:
    972     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
    973     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
    974     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
    975     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
    976 L_31009C87:
    977     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
    978     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
    979     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
    980     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
    981     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
    982     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
    983     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
    984     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
    985     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
    986     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
    987     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
    988     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
    989     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
    990     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
    991     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
    992     _flag_k = FK_CMP;
    993     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
    994 L_31009CAE:
    995     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
    996 L_31009CB1:
    997     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
    998     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
    999     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   1000     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   1001     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1002     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1003     _flag_k = FK_CMP;
   1004     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   1005 L_31009CBF:
   1006     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   1007     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   1008     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   1009 L_31009CC9:
   1010     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   1011     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   1012     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   1013     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1014     _flag_k = FK_CMP;
   1015     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   1016 L_31009CD0:
   1017     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   1018     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   1019     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   1020 L_31009CD9:
   1021     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   1022     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   1023     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   1024 L_31009CE3:
   1025     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
   1026     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
   1027     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1028     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1029     _flag_k = FK_NARROW(FK_CMP, 24);
   1030     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
   1031 L_31009CEA:
   1032     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
   1033     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
   1034     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
   1035     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
   1036     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
   1037     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
   1038     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
   1039     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
   1040     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1041     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1042     _flag_k = FK_CMP;
   1043     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
   1044 L_31009D03:
   1045     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
   1046 L_31009D06:
   1047     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
   1048     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
   1049     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
   1050     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
   1051     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1052     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1053     _flag_k = FK_CMP;
   1054     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
   1055 L_31009D14:
   1056     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
   1057     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
   1058 L_31009D19:
   1059     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
   1060     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
   1061     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   1062     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1063     _flag_k = FK_CMP;
   1064     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
   1065 L_31009D20:
   1066     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
   1067     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
   1068 L_31009D24:
   1069     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
   1070 L_31009D27:
   1071     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   1072     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   1073     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   1074     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   1075 L_31009D31:
   1076     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   1077     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   1078     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   1079     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   1080     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   1081     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   1082     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   1083     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   1084     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   1085     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   1086     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   1087     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   1088     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   1089     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1090     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1091     _flag_k = FK_CMP;
   1092     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   1093 L_31009D57:
   1094     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   1095 L_31009D5A:
   1096     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   1097     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   1098     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   1099     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   1100     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1101     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1102     _flag_k = FK_CMP;
   1103     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   1104 L_31009D68:
   1105     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   1106     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   1107 L_31009D6D:
   1108     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   1109     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   1110     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   1111     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1112     _flag_k = FK_CMP;
   1113     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   1114 L_31009D75:
   1115     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   1116     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   1117 L_31009D7A:
   1118     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   1119 L_31009D7C:
   1120     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   1121 L_31009D7F:
   1122     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   1123 L_31009D82:
   1124     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   1125 L_31009D85:
   1126     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   1127     PUSH32(esp, edx); /* 0x31009D88: push edx */
   1128     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   1129     RECOMP_FLAGS_IN();
   1130     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   1131     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   1132     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   1133     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1134     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   1135     _flag_k = FK_ADD;
   1136     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   1137     eax = eax - 1; /* 0x31009D97: dec eax */
   1138     _flag_k = FK_DEC;
   1139     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   1140     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   1141     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   1142     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   1143     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   1144     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   1145     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   1146     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   1147     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   1148     RECOMP_REGS_OUT();
   1149 }
   1150 
   1151 void sub_31009AE9(void) {
   1152     int _fpu_cmp = 0;
   1153     uint32_t _cf = 0;
   1154     int _df = 1;
   1155     uint32_t _flag_k = FK_NONE;
   1156     uint32_t _flag_a = 0, _flag_b = 0;
   1157     uint32_t _itail_tgt = 0;
   1158     RECOMP_REGS_LOCALS
   1159     RECOMP_ENTER(0x31009AE9u);
   1160 
   1161 L_31009AE9:
   1162     MEM32(ebx) = edx; /* 0x31009AE9: mov dword ptr [ebx], edx */
   1163     ebx = MEM32(edi + 0x4); /* 0x31009AEB: mov ebx, dword ptr [edi + 4] */
   1164     /* cmp MEM32(ebx + 0x8), esi */ /* 0x31009AEE: cmp dword ptr [ebx + 8], esi */
   1165     _flag_a = (uint32_t)(MEM32(ebx + 0x8)); _flag_b = (uint32_t)(esi);
   1166     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1167     _flag_k = FK_CMP;
   1168     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B18; /* 0x31009AF1: jne 0x31009b18 */
   1169 L_31009AF3:
   1170     ecx = MEM32(esi); /* 0x31009AF3: mov ecx, dword ptr [esi] */
   1171     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x31009AF5: cmp ecx, dword ptr [edi + 8] */
   1172     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1173     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1174     _flag_k = FK_CMP;
   1175     if (CMP_NE(_flag_a, _flag_b)) goto L_31009AFF; /* 0x31009AF8: jne 0x31009aff */
   1176 L_31009AFA:
   1177     edx = MEM32(esi + 0x4); /* 0x31009AFA: mov edx, dword ptr [esi + 4] */
   1178     goto L_31009B15; /* 0x31009AFD: jmp 0x31009b15 */
   1179 L_31009AFF:
   1180     ecx = MEM32(eax + 0x8); /* 0x31009AFF: mov ecx, dword ptr [eax + 8] */
   1181     /* cmp MEM8(ecx + 0x15), 0 */ /* 0x31009B02: cmp byte ptr [ecx + 0x15], 0 */
   1182     _flag_a = (uint32_t)(MEM8(ecx + 0x15)) << 24; _flag_b = (uint32_t)(0) << 24;
   1183     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1184     _flag_k = FK_NARROW(FK_CMP, 24);
   1185     edx = eax; /* 0x31009B06: mov edx, eax */
   1186     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B15; /* 0x31009B08: jne 0x31009b15 */
   1187 L_31009B0A:
   1188     edx = ecx; /* 0x31009B0A: mov edx, ecx */
   1189     ecx = MEM32(edx + 0x8); /* 0x31009B0C: mov ecx, dword ptr [edx + 8] */
   1190     /* cmp MEM8(ecx + 0x15), 0 */ /* 0x31009B0F: cmp byte ptr [ecx + 0x15], 0 */
   1191     _flag_a = (uint32_t)(MEM8(ecx + 0x15)) << 24; _flag_b = (uint32_t)(0) << 24;
   1192     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1193     _flag_k = FK_NARROW(FK_CMP, 24);
   1194     RECOMP_BACKEDGE();
   1195     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B0A; /* 0x31009B13: je 0x31009b0a */
   1196 L_31009B15:
   1197     MEM32(ebx + 0x8) = edx; /* 0x31009B15: mov dword ptr [ebx + 8], edx */
   1198 L_31009B18:
   1199     ecx = MEM32(ebp + (-0x4)); /* 0x31009B18: mov ecx, dword ptr [ebp - 4] */
   1200     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B1B: mov dl, byte ptr [ecx + 0x14] */
   1201     SET_LO8(ebx, 1); /* 0x31009B1E: mov bl, 1 */
   1202     /* cmp LO8(edx), LO8(ebx) */ /* 0x31009B20: cmp dl, bl */
   1203     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1204     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1205     _flag_k = FK_NARROW(FK_CMP, 24);
   1206     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D85; /* 0x31009B22: jne 0x31009d85 */
   1207 L_31009B28:
   1208     edx = MEM32(edi + 0x4); /* 0x31009B28: mov edx, dword ptr [edi + 4] */
   1209     /* cmp eax, MEM32(edx + 0x4) */ /* 0x31009B2B: cmp eax, dword ptr [edx + 4] */
   1210     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   1211     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1212     _flag_k = FK_CMP;
   1213     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B2E: je 0x31009d82 */
   1214 L_31009B34:
   1215     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
   1216     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1217     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1218     _flag_k = FK_NARROW(FK_CMP, 24);
   1219     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
   1220 L_31009B3D:
   1221     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
   1222     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
   1223     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
   1224     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   1225     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1226     _flag_k = FK_CMP;
   1227     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
   1228 L_31009B46:
   1229     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
   1230     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
   1231     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
   1232     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   1233     _cf = 0;
   1234     _flag_k = FK_NARROW(FK_TEST, 24);
   1235     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
   1236 L_31009B50:
   1237     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
   1238     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
   1239     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
   1240     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
   1241     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
   1242     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
   1243     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
   1244     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
   1245     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
   1246     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1247     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1248     _flag_k = FK_CMP;
   1249     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
   1250 L_31009B6C:
   1251     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
   1252 L_31009B6F:
   1253     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
   1254     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
   1255     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
   1256     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
   1257     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1258     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1259     _flag_k = FK_CMP;
   1260     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
   1261 L_31009B7D:
   1262     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
   1263     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
   1264 L_31009B82:
   1265     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
   1266     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
   1267     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   1268     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1269     _flag_k = FK_CMP;
   1270     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
   1271 L_31009B89:
   1272     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
   1273     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
   1274 L_31009B8D:
   1275     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
   1276 L_31009B90:
   1277     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
   1278     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
   1279     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
   1280     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
   1281 L_31009B9B:
   1282     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
   1283     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
   1284     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1285     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1286     _flag_k = FK_NARROW(FK_CMP, 24);
   1287     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
   1288 L_31009BA6:
   1289     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
   1290     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
   1291     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1292     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1293     _flag_k = FK_NARROW(FK_CMP, 24);
   1294     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
   1295 L_31009BB2:
   1296     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
   1297 L_31009BB4:
   1298     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
   1299     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
   1300     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   1301     _cf = 0;
   1302     _flag_k = FK_NARROW(FK_TEST, 24);
   1303     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
   1304 L_31009BBB:
   1305     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
   1306     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
   1307     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
   1308     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
   1309     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
   1310     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
   1311     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
   1312     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
   1313     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
   1314     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1315     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1316     _flag_k = FK_CMP;
   1317     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
   1318 L_31009BD7:
   1319     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
   1320 L_31009BDA:
   1321     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
   1322     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
   1323     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
   1324     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
   1325     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1326     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1327     _flag_k = FK_CMP;
   1328     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
   1329 L_31009BE8:
   1330     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
   1331     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
   1332 L_31009BED:
   1333     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
   1334     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
   1335     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   1336     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1337     _flag_k = FK_CMP;
   1338     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
   1339 L_31009BF5:
   1340     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
   1341     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
   1342 L_31009BFA:
   1343     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
   1344 L_31009BFC:
   1345     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
   1346     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
   1347     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
   1348     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
   1349 L_31009C07:
   1350     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
   1351     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
   1352     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1353     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1354     _flag_k = FK_NARROW(FK_CMP, 24);
   1355     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
   1356 L_31009C13:
   1357     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
   1358     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
   1359     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1360     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1361     _flag_k = FK_NARROW(FK_CMP, 24);
   1362     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
   1363 L_31009C1E:
   1364     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
   1365     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
   1366     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
   1367     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
   1368     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   1369     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1370     _flag_k = FK_CMP;
   1371     RECOMP_BACKEDGE();
   1372     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
   1373 L_31009C31:
   1374     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
   1375 L_31009C36:
   1376     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
   1377     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
   1378     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1379     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1380     _flag_k = FK_NARROW(FK_CMP, 24);
   1381     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
   1382 L_31009C3E:
   1383     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
   1384     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
   1385     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
   1386     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
   1387     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
   1388     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
   1389     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
   1390     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
   1391     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1392     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1393     _flag_k = FK_CMP;
   1394     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
   1395 L_31009C56:
   1396     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
   1397 L_31009C59:
   1398     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
   1399     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
   1400     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
   1401     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
   1402     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1403     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1404     _flag_k = FK_CMP;
   1405     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
   1406 L_31009C67:
   1407     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
   1408     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
   1409 L_31009C6C:
   1410     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
   1411     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
   1412     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   1413     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1414     _flag_k = FK_CMP;
   1415     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
   1416 L_31009C74:
   1417     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
   1418     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
   1419 L_31009C79:
   1420     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
   1421 L_31009C7B:
   1422     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   1423     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   1424     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   1425     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   1426 L_31009C87:
   1427     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   1428     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   1429     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   1430     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   1431     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   1432     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   1433     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   1434     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   1435     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   1436     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   1437     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   1438     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   1439     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   1440     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1441     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1442     _flag_k = FK_CMP;
   1443     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   1444 L_31009CAE:
   1445     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   1446 L_31009CB1:
   1447     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   1448     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   1449     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   1450     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   1451     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1452     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1453     _flag_k = FK_CMP;
   1454     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   1455 L_31009CBF:
   1456     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   1457     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   1458     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   1459 L_31009CC9:
   1460     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   1461     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   1462     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   1463     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1464     _flag_k = FK_CMP;
   1465     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   1466 L_31009CD0:
   1467     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   1468     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   1469     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   1470 L_31009CD9:
   1471     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   1472     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   1473     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   1474 L_31009CE3:
   1475     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
   1476     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
   1477     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1478     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1479     _flag_k = FK_NARROW(FK_CMP, 24);
   1480     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
   1481 L_31009CEA:
   1482     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
   1483     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
   1484     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
   1485     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
   1486     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
   1487     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
   1488     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
   1489     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
   1490     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1491     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1492     _flag_k = FK_CMP;
   1493     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
   1494 L_31009D03:
   1495     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
   1496 L_31009D06:
   1497     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
   1498     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
   1499     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
   1500     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
   1501     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1502     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1503     _flag_k = FK_CMP;
   1504     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
   1505 L_31009D14:
   1506     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
   1507     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
   1508 L_31009D19:
   1509     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
   1510     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
   1511     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   1512     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1513     _flag_k = FK_CMP;
   1514     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
   1515 L_31009D20:
   1516     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
   1517     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
   1518 L_31009D24:
   1519     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
   1520 L_31009D27:
   1521     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   1522     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   1523     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   1524     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   1525 L_31009D31:
   1526     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   1527     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   1528     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   1529     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   1530     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   1531     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   1532     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   1533     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   1534     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   1535     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   1536     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   1537     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   1538     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   1539     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1540     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1541     _flag_k = FK_CMP;
   1542     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   1543 L_31009D57:
   1544     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   1545 L_31009D5A:
   1546     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   1547     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   1548     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   1549     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   1550     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1551     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1552     _flag_k = FK_CMP;
   1553     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   1554 L_31009D68:
   1555     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   1556     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   1557 L_31009D6D:
   1558     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   1559     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   1560     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   1561     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1562     _flag_k = FK_CMP;
   1563     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   1564 L_31009D75:
   1565     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   1566     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   1567 L_31009D7A:
   1568     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   1569 L_31009D7C:
   1570     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   1571 L_31009D7F:
   1572     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   1573 L_31009D82:
   1574     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   1575 L_31009D85:
   1576     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   1577     PUSH32(esp, edx); /* 0x31009D88: push edx */
   1578     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   1579     RECOMP_FLAGS_IN();
   1580     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   1581     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   1582     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   1583     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1584     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   1585     _flag_k = FK_ADD;
   1586     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   1587     eax = eax - 1; /* 0x31009D97: dec eax */
   1588     _flag_k = FK_DEC;
   1589     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   1590     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   1591     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   1592     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   1593     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   1594     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   1595     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   1596     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   1597     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   1598     RECOMP_REGS_OUT();
   1599 }
   1600 
   1601 void sub_31009B15(void) {
   1602     int _fpu_cmp = 0;
   1603     uint32_t _cf = 0;
   1604     int _df = 1;
   1605     uint32_t _flag_k = FK_NONE;
   1606     uint32_t _flag_a = 0, _flag_b = 0;
   1607     uint32_t _itail_tgt = 0;
   1608     RECOMP_REGS_LOCALS
   1609     RECOMP_ENTER(0x31009B15u);
   1610 
   1611 L_31009B15:
   1612     MEM32(ebx + 0x8) = edx; /* 0x31009B15: mov dword ptr [ebx + 8], edx */
   1613     ecx = MEM32(ebp + (-0x4)); /* 0x31009B18: mov ecx, dword ptr [ebp - 4] */
   1614     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B1B: mov dl, byte ptr [ecx + 0x14] */
   1615     SET_LO8(ebx, 1); /* 0x31009B1E: mov bl, 1 */
   1616     /* cmp LO8(edx), LO8(ebx) */ /* 0x31009B20: cmp dl, bl */
   1617     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1618     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1619     _flag_k = FK_NARROW(FK_CMP, 24);
   1620     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D85; /* 0x31009B22: jne 0x31009d85 */
   1621 L_31009B28:
   1622     edx = MEM32(edi + 0x4); /* 0x31009B28: mov edx, dword ptr [edi + 4] */
   1623     /* cmp eax, MEM32(edx + 0x4) */ /* 0x31009B2B: cmp eax, dword ptr [edx + 4] */
   1624     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   1625     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1626     _flag_k = FK_CMP;
   1627     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B2E: je 0x31009d82 */
   1628 L_31009B34:
   1629     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
   1630     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1631     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1632     _flag_k = FK_NARROW(FK_CMP, 24);
   1633     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
   1634 L_31009B3D:
   1635     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
   1636     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
   1637     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
   1638     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   1639     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1640     _flag_k = FK_CMP;
   1641     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
   1642 L_31009B46:
   1643     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
   1644     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
   1645     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
   1646     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   1647     _cf = 0;
   1648     _flag_k = FK_NARROW(FK_TEST, 24);
   1649     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
   1650 L_31009B50:
   1651     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
   1652     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
   1653     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
   1654     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
   1655     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
   1656     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
   1657     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
   1658     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
   1659     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
   1660     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1661     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1662     _flag_k = FK_CMP;
   1663     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
   1664 L_31009B6C:
   1665     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
   1666 L_31009B6F:
   1667     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
   1668     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
   1669     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
   1670     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
   1671     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1672     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1673     _flag_k = FK_CMP;
   1674     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
   1675 L_31009B7D:
   1676     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
   1677     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
   1678 L_31009B82:
   1679     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
   1680     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
   1681     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   1682     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1683     _flag_k = FK_CMP;
   1684     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
   1685 L_31009B89:
   1686     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
   1687     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
   1688 L_31009B8D:
   1689     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
   1690 L_31009B90:
   1691     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
   1692     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
   1693     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
   1694     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
   1695 L_31009B9B:
   1696     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
   1697     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
   1698     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1699     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1700     _flag_k = FK_NARROW(FK_CMP, 24);
   1701     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
   1702 L_31009BA6:
   1703     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
   1704     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
   1705     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1706     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1707     _flag_k = FK_NARROW(FK_CMP, 24);
   1708     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
   1709 L_31009BB2:
   1710     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
   1711 L_31009BB4:
   1712     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
   1713     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
   1714     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   1715     _cf = 0;
   1716     _flag_k = FK_NARROW(FK_TEST, 24);
   1717     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
   1718 L_31009BBB:
   1719     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
   1720     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
   1721     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
   1722     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
   1723     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
   1724     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
   1725     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
   1726     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
   1727     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
   1728     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1729     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1730     _flag_k = FK_CMP;
   1731     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
   1732 L_31009BD7:
   1733     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
   1734 L_31009BDA:
   1735     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
   1736     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
   1737     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
   1738     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
   1739     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1740     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1741     _flag_k = FK_CMP;
   1742     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
   1743 L_31009BE8:
   1744     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
   1745     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
   1746 L_31009BED:
   1747     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
   1748     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
   1749     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   1750     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1751     _flag_k = FK_CMP;
   1752     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
   1753 L_31009BF5:
   1754     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
   1755     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
   1756 L_31009BFA:
   1757     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
   1758 L_31009BFC:
   1759     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
   1760     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
   1761     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
   1762     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
   1763 L_31009C07:
   1764     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
   1765     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
   1766     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1767     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1768     _flag_k = FK_NARROW(FK_CMP, 24);
   1769     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
   1770 L_31009C13:
   1771     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
   1772     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
   1773     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1774     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1775     _flag_k = FK_NARROW(FK_CMP, 24);
   1776     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
   1777 L_31009C1E:
   1778     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
   1779     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
   1780     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
   1781     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
   1782     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   1783     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1784     _flag_k = FK_CMP;
   1785     RECOMP_BACKEDGE();
   1786     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
   1787 L_31009C31:
   1788     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
   1789 L_31009C36:
   1790     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
   1791     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
   1792     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1793     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1794     _flag_k = FK_NARROW(FK_CMP, 24);
   1795     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
   1796 L_31009C3E:
   1797     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
   1798     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
   1799     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
   1800     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
   1801     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
   1802     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
   1803     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
   1804     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
   1805     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1806     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1807     _flag_k = FK_CMP;
   1808     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
   1809 L_31009C56:
   1810     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
   1811 L_31009C59:
   1812     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
   1813     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
   1814     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
   1815     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
   1816     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1817     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1818     _flag_k = FK_CMP;
   1819     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
   1820 L_31009C67:
   1821     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
   1822     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
   1823 L_31009C6C:
   1824     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
   1825     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
   1826     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   1827     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1828     _flag_k = FK_CMP;
   1829     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
   1830 L_31009C74:
   1831     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
   1832     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
   1833 L_31009C79:
   1834     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
   1835 L_31009C7B:
   1836     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   1837     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   1838     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   1839     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   1840 L_31009C87:
   1841     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   1842     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   1843     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   1844     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   1845     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   1846     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   1847     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   1848     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   1849     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   1850     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   1851     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   1852     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   1853     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   1854     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1855     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1856     _flag_k = FK_CMP;
   1857     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   1858 L_31009CAE:
   1859     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   1860 L_31009CB1:
   1861     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   1862     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   1863     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   1864     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   1865     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1866     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1867     _flag_k = FK_CMP;
   1868     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   1869 L_31009CBF:
   1870     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   1871     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   1872     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   1873 L_31009CC9:
   1874     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   1875     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   1876     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   1877     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1878     _flag_k = FK_CMP;
   1879     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   1880 L_31009CD0:
   1881     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   1882     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   1883     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   1884 L_31009CD9:
   1885     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   1886     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   1887     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   1888 L_31009CE3:
   1889     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
   1890     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
   1891     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   1892     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1893     _flag_k = FK_NARROW(FK_CMP, 24);
   1894     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
   1895 L_31009CEA:
   1896     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
   1897     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
   1898     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
   1899     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
   1900     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
   1901     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
   1902     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
   1903     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
   1904     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1905     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1906     _flag_k = FK_CMP;
   1907     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
   1908 L_31009D03:
   1909     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
   1910 L_31009D06:
   1911     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
   1912     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
   1913     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
   1914     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
   1915     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1916     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1917     _flag_k = FK_CMP;
   1918     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
   1919 L_31009D14:
   1920     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
   1921     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
   1922 L_31009D19:
   1923     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
   1924     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
   1925     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   1926     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1927     _flag_k = FK_CMP;
   1928     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
   1929 L_31009D20:
   1930     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
   1931     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
   1932 L_31009D24:
   1933     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
   1934 L_31009D27:
   1935     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   1936     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   1937     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   1938     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   1939 L_31009D31:
   1940     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   1941     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   1942     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   1943     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   1944     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   1945     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   1946     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   1947     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   1948     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   1949     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   1950     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   1951     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   1952     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   1953     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   1954     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1955     _flag_k = FK_CMP;
   1956     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   1957 L_31009D57:
   1958     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   1959 L_31009D5A:
   1960     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   1961     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   1962     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   1963     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   1964     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   1965     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1966     _flag_k = FK_CMP;
   1967     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   1968 L_31009D68:
   1969     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   1970     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   1971 L_31009D6D:
   1972     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   1973     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   1974     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   1975     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   1976     _flag_k = FK_CMP;
   1977     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   1978 L_31009D75:
   1979     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   1980     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   1981 L_31009D7A:
   1982     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   1983 L_31009D7C:
   1984     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   1985 L_31009D7F:
   1986     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   1987 L_31009D82:
   1988     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   1989 L_31009D85:
   1990     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   1991     PUSH32(esp, edx); /* 0x31009D88: push edx */
   1992     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   1993     RECOMP_FLAGS_IN();
   1994     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   1995     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   1996     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   1997     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   1998     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   1999     _flag_k = FK_ADD;
   2000     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   2001     eax = eax - 1; /* 0x31009D97: dec eax */
   2002     _flag_k = FK_DEC;
   2003     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   2004     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   2005     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   2006     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   2007     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   2008     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   2009     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   2010     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   2011     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   2012     RECOMP_REGS_OUT();
   2013 }
   2014 
   2015 void sub_31009B34(void) {
   2016     int _fpu_cmp = 0;
   2017     uint32_t _cf = 0;
   2018     int _df = 1;
   2019     uint32_t _flag_k = FK_NONE;
   2020     uint32_t _flag_a = 0, _flag_b = 0;
   2021     uint32_t _itail_tgt = 0;
   2022     RECOMP_REGS_LOCALS
   2023     RECOMP_ENTER(0x31009B34u);
   2024 
   2025 L_31009B34:
   2026     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
   2027     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2028     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2029     _flag_k = FK_NARROW(FK_CMP, 24);
   2030     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
   2031 L_31009B3D:
   2032     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
   2033     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
   2034     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
   2035     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   2036     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2037     _flag_k = FK_CMP;
   2038     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
   2039 L_31009B46:
   2040     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
   2041     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
   2042     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
   2043     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   2044     _cf = 0;
   2045     _flag_k = FK_NARROW(FK_TEST, 24);
   2046     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
   2047 L_31009B50:
   2048     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
   2049     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
   2050     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
   2051     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
   2052     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
   2053     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
   2054     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
   2055     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
   2056     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
   2057     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2058     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2059     _flag_k = FK_CMP;
   2060     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
   2061 L_31009B6C:
   2062     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
   2063 L_31009B6F:
   2064     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
   2065     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
   2066     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
   2067     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
   2068     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2069     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2070     _flag_k = FK_CMP;
   2071     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
   2072 L_31009B7D:
   2073     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
   2074     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
   2075 L_31009B82:
   2076     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
   2077     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
   2078     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   2079     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2080     _flag_k = FK_CMP;
   2081     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
   2082 L_31009B89:
   2083     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
   2084     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
   2085 L_31009B8D:
   2086     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
   2087 L_31009B90:
   2088     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
   2089     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
   2090     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
   2091     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
   2092 L_31009B9B:
   2093     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
   2094     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
   2095     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2096     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2097     _flag_k = FK_NARROW(FK_CMP, 24);
   2098     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
   2099 L_31009BA6:
   2100     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
   2101     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
   2102     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2103     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2104     _flag_k = FK_NARROW(FK_CMP, 24);
   2105     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
   2106 L_31009BB2:
   2107     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
   2108 L_31009BB4:
   2109     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
   2110     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
   2111     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   2112     _cf = 0;
   2113     _flag_k = FK_NARROW(FK_TEST, 24);
   2114     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
   2115 L_31009BBB:
   2116     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
   2117     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
   2118     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
   2119     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
   2120     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
   2121     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
   2122     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
   2123     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
   2124     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
   2125     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2126     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2127     _flag_k = FK_CMP;
   2128     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
   2129 L_31009BD7:
   2130     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
   2131 L_31009BDA:
   2132     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
   2133     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
   2134     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
   2135     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
   2136     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2137     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2138     _flag_k = FK_CMP;
   2139     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
   2140 L_31009BE8:
   2141     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
   2142     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
   2143 L_31009BED:
   2144     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
   2145     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
   2146     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   2147     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2148     _flag_k = FK_CMP;
   2149     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
   2150 L_31009BF5:
   2151     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
   2152     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
   2153 L_31009BFA:
   2154     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
   2155 L_31009BFC:
   2156     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
   2157     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
   2158     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
   2159     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
   2160 L_31009C07:
   2161     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
   2162     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
   2163     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2164     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2165     _flag_k = FK_NARROW(FK_CMP, 24);
   2166     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
   2167 L_31009C13:
   2168     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
   2169     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
   2170     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2171     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2172     _flag_k = FK_NARROW(FK_CMP, 24);
   2173     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
   2174 L_31009C1E:
   2175     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
   2176     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
   2177     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
   2178     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
   2179     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   2180     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2181     _flag_k = FK_CMP;
   2182     RECOMP_BACKEDGE();
   2183     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
   2184 L_31009C31:
   2185     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
   2186 L_31009C36:
   2187     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
   2188     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
   2189     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2190     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2191     _flag_k = FK_NARROW(FK_CMP, 24);
   2192     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
   2193 L_31009C3E:
   2194     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
   2195     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
   2196     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
   2197     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
   2198     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
   2199     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
   2200     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
   2201     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
   2202     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2203     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2204     _flag_k = FK_CMP;
   2205     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
   2206 L_31009C56:
   2207     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
   2208 L_31009C59:
   2209     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
   2210     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
   2211     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
   2212     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
   2213     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2214     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2215     _flag_k = FK_CMP;
   2216     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
   2217 L_31009C67:
   2218     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
   2219     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
   2220 L_31009C6C:
   2221     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
   2222     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
   2223     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   2224     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2225     _flag_k = FK_CMP;
   2226     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
   2227 L_31009C74:
   2228     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
   2229     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
   2230 L_31009C79:
   2231     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
   2232 L_31009C7B:
   2233     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   2234     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   2235     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   2236     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   2237 L_31009C87:
   2238     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   2239     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   2240     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   2241     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   2242     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   2243     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   2244     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   2245     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   2246     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   2247     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   2248     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   2249     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   2250     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   2251     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2252     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2253     _flag_k = FK_CMP;
   2254     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   2255 L_31009CAE:
   2256     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   2257 L_31009CB1:
   2258     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   2259     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   2260     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   2261     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   2262     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2263     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2264     _flag_k = FK_CMP;
   2265     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   2266 L_31009CBF:
   2267     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   2268     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   2269     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   2270 L_31009CC9:
   2271     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   2272     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   2273     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   2274     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2275     _flag_k = FK_CMP;
   2276     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   2277 L_31009CD0:
   2278     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   2279     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   2280     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   2281 L_31009CD9:
   2282     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   2283     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   2284     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   2285 L_31009CE3:
   2286     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
   2287     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
   2288     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2289     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2290     _flag_k = FK_NARROW(FK_CMP, 24);
   2291     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
   2292 L_31009CEA:
   2293     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
   2294     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
   2295     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
   2296     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
   2297     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
   2298     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
   2299     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
   2300     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
   2301     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2302     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2303     _flag_k = FK_CMP;
   2304     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
   2305 L_31009D03:
   2306     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
   2307 L_31009D06:
   2308     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
   2309     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
   2310     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
   2311     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
   2312     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2313     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2314     _flag_k = FK_CMP;
   2315     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
   2316 L_31009D14:
   2317     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
   2318     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
   2319 L_31009D19:
   2320     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
   2321     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
   2322     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   2323     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2324     _flag_k = FK_CMP;
   2325     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
   2326 L_31009D20:
   2327     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
   2328     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
   2329 L_31009D24:
   2330     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
   2331 L_31009D27:
   2332     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   2333     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   2334     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   2335     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   2336 L_31009D31:
   2337     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   2338     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   2339     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   2340     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   2341     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   2342     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   2343     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   2344     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   2345     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   2346     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   2347     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   2348     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   2349     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   2350     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2351     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2352     _flag_k = FK_CMP;
   2353     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   2354 L_31009D57:
   2355     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   2356 L_31009D5A:
   2357     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   2358     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   2359     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   2360     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   2361     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2362     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2363     _flag_k = FK_CMP;
   2364     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   2365 L_31009D68:
   2366     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   2367     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   2368 L_31009D6D:
   2369     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   2370     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   2371     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   2372     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2373     _flag_k = FK_CMP;
   2374     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   2375 L_31009D75:
   2376     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   2377     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   2378 L_31009D7A:
   2379     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   2380 L_31009D7C:
   2381     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   2382 L_31009D7F:
   2383     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   2384 L_31009D82:
   2385     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   2386     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   2387     PUSH32(esp, edx); /* 0x31009D88: push edx */
   2388     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   2389     RECOMP_FLAGS_IN();
   2390     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   2391     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   2392     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   2393     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2394     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   2395     _flag_k = FK_ADD;
   2396     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   2397     eax = eax - 1; /* 0x31009D97: dec eax */
   2398     _flag_k = FK_DEC;
   2399     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   2400     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   2401     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   2402     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   2403     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   2404     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   2405     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   2406     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   2407     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   2408     RECOMP_REGS_OUT();
   2409 }
   2410 
   2411 void sub_31009B90(void) {
   2412     int _fpu_cmp = 0;
   2413     uint32_t _cf = 0;
   2414     int _df = 1;
   2415     uint32_t _flag_k = FK_NONE;
   2416     uint32_t _flag_a = 0, _flag_b = 0;
   2417     uint32_t _itail_tgt = 0;
   2418     RECOMP_REGS_LOCALS
   2419     RECOMP_ENTER(0x31009B90u);
   2420 
   2421     goto L_31009B90;
   2422 L_31009B34:
   2423     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
   2424     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2425     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2426     _flag_k = FK_NARROW(FK_CMP, 24);
   2427     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
   2428 L_31009B3D:
   2429     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
   2430     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
   2431     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
   2432     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   2433     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2434     _flag_k = FK_CMP;
   2435     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
   2436 L_31009B46:
   2437     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
   2438     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
   2439     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
   2440     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   2441     _cf = 0;
   2442     _flag_k = FK_NARROW(FK_TEST, 24);
   2443     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
   2444 L_31009B50:
   2445     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
   2446     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
   2447     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
   2448     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
   2449     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
   2450     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
   2451     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
   2452     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
   2453     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
   2454     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2455     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2456     _flag_k = FK_CMP;
   2457     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
   2458 L_31009B6C:
   2459     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
   2460 L_31009B6F:
   2461     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
   2462     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
   2463     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
   2464     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
   2465     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2466     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2467     _flag_k = FK_CMP;
   2468     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
   2469 L_31009B7D:
   2470     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
   2471     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
   2472 L_31009B82:
   2473     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
   2474     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
   2475     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   2476     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2477     _flag_k = FK_CMP;
   2478     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
   2479 L_31009B89:
   2480     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
   2481     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
   2482 L_31009B8D:
   2483     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
   2484 L_31009B90:
   2485     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
   2486     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
   2487     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
   2488     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
   2489 L_31009B9B:
   2490     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
   2491     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
   2492     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2493     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2494     _flag_k = FK_NARROW(FK_CMP, 24);
   2495     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
   2496 L_31009BA6:
   2497     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
   2498     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
   2499     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2500     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2501     _flag_k = FK_NARROW(FK_CMP, 24);
   2502     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
   2503 L_31009BB2:
   2504     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
   2505 L_31009BB4:
   2506     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
   2507     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
   2508     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   2509     _cf = 0;
   2510     _flag_k = FK_NARROW(FK_TEST, 24);
   2511     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
   2512 L_31009BBB:
   2513     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
   2514     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
   2515     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
   2516     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
   2517     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
   2518     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
   2519     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
   2520     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
   2521     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
   2522     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2523     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2524     _flag_k = FK_CMP;
   2525     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
   2526 L_31009BD7:
   2527     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
   2528 L_31009BDA:
   2529     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
   2530     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
   2531     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
   2532     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
   2533     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2534     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2535     _flag_k = FK_CMP;
   2536     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
   2537 L_31009BE8:
   2538     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
   2539     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
   2540 L_31009BED:
   2541     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
   2542     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
   2543     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   2544     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2545     _flag_k = FK_CMP;
   2546     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
   2547 L_31009BF5:
   2548     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
   2549     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
   2550 L_31009BFA:
   2551     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
   2552 L_31009BFC:
   2553     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
   2554     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
   2555     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
   2556     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
   2557 L_31009C07:
   2558     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
   2559     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
   2560     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2561     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2562     _flag_k = FK_NARROW(FK_CMP, 24);
   2563     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
   2564 L_31009C13:
   2565     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
   2566     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
   2567     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2568     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2569     _flag_k = FK_NARROW(FK_CMP, 24);
   2570     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
   2571 L_31009C1E:
   2572     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
   2573     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
   2574     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
   2575     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
   2576     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   2577     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2578     _flag_k = FK_CMP;
   2579     RECOMP_BACKEDGE();
   2580     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
   2581 L_31009C31:
   2582     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
   2583 L_31009C36:
   2584     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
   2585     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
   2586     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2587     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2588     _flag_k = FK_NARROW(FK_CMP, 24);
   2589     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
   2590 L_31009C3E:
   2591     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
   2592     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
   2593     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
   2594     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
   2595     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
   2596     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
   2597     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
   2598     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
   2599     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2600     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2601     _flag_k = FK_CMP;
   2602     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
   2603 L_31009C56:
   2604     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
   2605 L_31009C59:
   2606     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
   2607     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
   2608     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
   2609     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
   2610     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2611     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2612     _flag_k = FK_CMP;
   2613     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
   2614 L_31009C67:
   2615     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
   2616     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
   2617 L_31009C6C:
   2618     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
   2619     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
   2620     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   2621     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2622     _flag_k = FK_CMP;
   2623     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
   2624 L_31009C74:
   2625     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
   2626     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
   2627 L_31009C79:
   2628     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
   2629 L_31009C7B:
   2630     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   2631     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   2632     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   2633     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   2634 L_31009C87:
   2635     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   2636     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   2637     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   2638     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   2639     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   2640     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   2641     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   2642     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   2643     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   2644     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   2645     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   2646     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   2647     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   2648     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2649     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2650     _flag_k = FK_CMP;
   2651     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   2652 L_31009CAE:
   2653     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   2654 L_31009CB1:
   2655     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   2656     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   2657     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   2658     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   2659     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2660     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2661     _flag_k = FK_CMP;
   2662     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   2663 L_31009CBF:
   2664     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   2665     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   2666     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   2667 L_31009CC9:
   2668     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   2669     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   2670     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   2671     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2672     _flag_k = FK_CMP;
   2673     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   2674 L_31009CD0:
   2675     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   2676     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   2677     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   2678 L_31009CD9:
   2679     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   2680     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   2681     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   2682 L_31009CE3:
   2683     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
   2684     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
   2685     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2686     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2687     _flag_k = FK_NARROW(FK_CMP, 24);
   2688     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
   2689 L_31009CEA:
   2690     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
   2691     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
   2692     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
   2693     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
   2694     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
   2695     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
   2696     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
   2697     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
   2698     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2699     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2700     _flag_k = FK_CMP;
   2701     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
   2702 L_31009D03:
   2703     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
   2704 L_31009D06:
   2705     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
   2706     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
   2707     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
   2708     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
   2709     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2710     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2711     _flag_k = FK_CMP;
   2712     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
   2713 L_31009D14:
   2714     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
   2715     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
   2716 L_31009D19:
   2717     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
   2718     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
   2719     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   2720     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2721     _flag_k = FK_CMP;
   2722     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
   2723 L_31009D20:
   2724     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
   2725     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
   2726 L_31009D24:
   2727     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
   2728 L_31009D27:
   2729     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   2730     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   2731     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   2732     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   2733 L_31009D31:
   2734     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   2735     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   2736     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   2737     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   2738     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   2739     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   2740     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   2741     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   2742     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   2743     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   2744     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   2745     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   2746     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   2747     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2748     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2749     _flag_k = FK_CMP;
   2750     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   2751 L_31009D57:
   2752     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   2753 L_31009D5A:
   2754     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   2755     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   2756     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   2757     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   2758     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2759     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2760     _flag_k = FK_CMP;
   2761     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   2762 L_31009D68:
   2763     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   2764     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   2765 L_31009D6D:
   2766     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   2767     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   2768     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   2769     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2770     _flag_k = FK_CMP;
   2771     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   2772 L_31009D75:
   2773     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   2774     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   2775 L_31009D7A:
   2776     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   2777 L_31009D7C:
   2778     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   2779 L_31009D7F:
   2780     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   2781 L_31009D82:
   2782     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   2783     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   2784     PUSH32(esp, edx); /* 0x31009D88: push edx */
   2785     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   2786     RECOMP_FLAGS_IN();
   2787     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   2788     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   2789     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   2790     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   2791     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   2792     _flag_k = FK_ADD;
   2793     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   2794     eax = eax - 1; /* 0x31009D97: dec eax */
   2795     _flag_k = FK_DEC;
   2796     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   2797     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   2798     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   2799     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   2800     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   2801     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   2802     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   2803     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   2804     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   2805     RECOMP_REGS_OUT();
   2806 }
   2807 
   2808 void sub_31009B9B(void) {
   2809     int _fpu_cmp = 0;
   2810     uint32_t _cf = 0;
   2811     int _df = 1;
   2812     uint32_t _flag_k = FK_NONE;
   2813     uint32_t _flag_a = 0, _flag_b = 0;
   2814     uint32_t _itail_tgt = 0;
   2815     RECOMP_REGS_LOCALS
   2816     RECOMP_ENTER(0x31009B9Bu);
   2817 
   2818     goto L_31009B9B;
   2819 L_31009B34:
   2820     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
   2821     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2822     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2823     _flag_k = FK_NARROW(FK_CMP, 24);
   2824     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
   2825 L_31009B3D:
   2826     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
   2827     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
   2828     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
   2829     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   2830     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2831     _flag_k = FK_CMP;
   2832     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
   2833 L_31009B46:
   2834     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
   2835     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
   2836     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
   2837     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   2838     _cf = 0;
   2839     _flag_k = FK_NARROW(FK_TEST, 24);
   2840     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
   2841 L_31009B50:
   2842     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
   2843     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
   2844     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
   2845     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
   2846     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
   2847     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
   2848     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
   2849     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
   2850     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
   2851     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2852     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2853     _flag_k = FK_CMP;
   2854     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
   2855 L_31009B6C:
   2856     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
   2857 L_31009B6F:
   2858     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
   2859     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
   2860     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
   2861     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
   2862     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2863     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2864     _flag_k = FK_CMP;
   2865     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
   2866 L_31009B7D:
   2867     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
   2868     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
   2869 L_31009B82:
   2870     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
   2871     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
   2872     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   2873     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2874     _flag_k = FK_CMP;
   2875     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
   2876 L_31009B89:
   2877     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
   2878     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
   2879 L_31009B8D:
   2880     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
   2881 L_31009B90:
   2882     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
   2883     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
   2884     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
   2885     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
   2886 L_31009B9B:
   2887     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
   2888     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
   2889     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2890     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2891     _flag_k = FK_NARROW(FK_CMP, 24);
   2892     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
   2893 L_31009BA6:
   2894     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
   2895     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
   2896     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2897     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2898     _flag_k = FK_NARROW(FK_CMP, 24);
   2899     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
   2900 L_31009BB2:
   2901     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
   2902 L_31009BB4:
   2903     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
   2904     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
   2905     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   2906     _cf = 0;
   2907     _flag_k = FK_NARROW(FK_TEST, 24);
   2908     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
   2909 L_31009BBB:
   2910     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
   2911     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
   2912     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
   2913     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
   2914     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
   2915     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
   2916     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
   2917     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
   2918     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
   2919     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2920     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2921     _flag_k = FK_CMP;
   2922     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
   2923 L_31009BD7:
   2924     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
   2925 L_31009BDA:
   2926     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
   2927     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
   2928     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
   2929     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
   2930     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   2931     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2932     _flag_k = FK_CMP;
   2933     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
   2934 L_31009BE8:
   2935     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
   2936     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
   2937 L_31009BED:
   2938     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
   2939     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
   2940     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   2941     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2942     _flag_k = FK_CMP;
   2943     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
   2944 L_31009BF5:
   2945     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
   2946     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
   2947 L_31009BFA:
   2948     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
   2949 L_31009BFC:
   2950     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
   2951     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
   2952     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
   2953     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
   2954 L_31009C07:
   2955     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
   2956     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
   2957     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2958     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2959     _flag_k = FK_NARROW(FK_CMP, 24);
   2960     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
   2961 L_31009C13:
   2962     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
   2963     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
   2964     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2965     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2966     _flag_k = FK_NARROW(FK_CMP, 24);
   2967     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
   2968 L_31009C1E:
   2969     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
   2970     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
   2971     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
   2972     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
   2973     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   2974     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2975     _flag_k = FK_CMP;
   2976     RECOMP_BACKEDGE();
   2977     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
   2978 L_31009C31:
   2979     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
   2980 L_31009C36:
   2981     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
   2982     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
   2983     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   2984     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2985     _flag_k = FK_NARROW(FK_CMP, 24);
   2986     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
   2987 L_31009C3E:
   2988     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
   2989     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
   2990     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
   2991     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
   2992     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
   2993     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
   2994     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
   2995     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
   2996     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   2997     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   2998     _flag_k = FK_CMP;
   2999     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
   3000 L_31009C56:
   3001     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
   3002 L_31009C59:
   3003     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
   3004     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
   3005     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
   3006     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
   3007     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3008     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3009     _flag_k = FK_CMP;
   3010     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
   3011 L_31009C67:
   3012     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
   3013     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
   3014 L_31009C6C:
   3015     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
   3016     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
   3017     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   3018     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3019     _flag_k = FK_CMP;
   3020     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
   3021 L_31009C74:
   3022     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
   3023     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
   3024 L_31009C79:
   3025     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
   3026 L_31009C7B:
   3027     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   3028     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   3029     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   3030     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   3031 L_31009C87:
   3032     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   3033     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   3034     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   3035     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   3036     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   3037     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   3038     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   3039     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   3040     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   3041     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   3042     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   3043     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   3044     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   3045     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3046     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3047     _flag_k = FK_CMP;
   3048     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   3049 L_31009CAE:
   3050     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   3051 L_31009CB1:
   3052     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   3053     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   3054     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   3055     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   3056     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3057     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3058     _flag_k = FK_CMP;
   3059     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   3060 L_31009CBF:
   3061     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   3062     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   3063     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   3064 L_31009CC9:
   3065     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   3066     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   3067     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   3068     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3069     _flag_k = FK_CMP;
   3070     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   3071 L_31009CD0:
   3072     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   3073     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   3074     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   3075 L_31009CD9:
   3076     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   3077     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   3078     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   3079 L_31009CE3:
   3080     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
   3081     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
   3082     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3083     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3084     _flag_k = FK_NARROW(FK_CMP, 24);
   3085     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
   3086 L_31009CEA:
   3087     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
   3088     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
   3089     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
   3090     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
   3091     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
   3092     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
   3093     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
   3094     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
   3095     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3096     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3097     _flag_k = FK_CMP;
   3098     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
   3099 L_31009D03:
   3100     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
   3101 L_31009D06:
   3102     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
   3103     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
   3104     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
   3105     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
   3106     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3107     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3108     _flag_k = FK_CMP;
   3109     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
   3110 L_31009D14:
   3111     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
   3112     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
   3113 L_31009D19:
   3114     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
   3115     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
   3116     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   3117     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3118     _flag_k = FK_CMP;
   3119     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
   3120 L_31009D20:
   3121     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
   3122     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
   3123 L_31009D24:
   3124     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
   3125 L_31009D27:
   3126     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   3127     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   3128     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   3129     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   3130 L_31009D31:
   3131     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   3132     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   3133     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   3134     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   3135     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   3136     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   3137     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   3138     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   3139     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   3140     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   3141     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   3142     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   3143     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   3144     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3145     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3146     _flag_k = FK_CMP;
   3147     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   3148 L_31009D57:
   3149     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   3150 L_31009D5A:
   3151     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   3152     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   3153     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   3154     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   3155     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3156     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3157     _flag_k = FK_CMP;
   3158     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   3159 L_31009D68:
   3160     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   3161     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   3162 L_31009D6D:
   3163     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   3164     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   3165     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   3166     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3167     _flag_k = FK_CMP;
   3168     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   3169 L_31009D75:
   3170     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   3171     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   3172 L_31009D7A:
   3173     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   3174 L_31009D7C:
   3175     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   3176 L_31009D7F:
   3177     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   3178 L_31009D82:
   3179     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   3180     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   3181     PUSH32(esp, edx); /* 0x31009D88: push edx */
   3182     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   3183     RECOMP_FLAGS_IN();
   3184     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   3185     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   3186     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   3187     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   3188     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   3189     _flag_k = FK_ADD;
   3190     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   3191     eax = eax - 1; /* 0x31009D97: dec eax */
   3192     _flag_k = FK_DEC;
   3193     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   3194     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   3195     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   3196     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   3197     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   3198     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   3199     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   3200     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   3201     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   3202     RECOMP_REGS_OUT();
   3203 }
   3204 
   3205 void sub_31009BB4(void) {
   3206     int _fpu_cmp = 0;
   3207     uint32_t _cf = 0;
   3208     int _df = 1;
   3209     uint32_t _flag_k = FK_NONE;
   3210     uint32_t _flag_a = 0, _flag_b = 0;
   3211     uint32_t _itail_tgt = 0;
   3212     RECOMP_REGS_LOCALS
   3213     RECOMP_ENTER(0x31009BB4u);
   3214 
   3215     goto L_31009BB4;
   3216 L_31009B34:
   3217     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
   3218     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3219     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3220     _flag_k = FK_NARROW(FK_CMP, 24);
   3221     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
   3222 L_31009B3D:
   3223     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
   3224     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
   3225     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
   3226     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   3227     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3228     _flag_k = FK_CMP;
   3229     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
   3230 L_31009B46:
   3231     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
   3232     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
   3233     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
   3234     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   3235     _cf = 0;
   3236     _flag_k = FK_NARROW(FK_TEST, 24);
   3237     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
   3238 L_31009B50:
   3239     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
   3240     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
   3241     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
   3242     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
   3243     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
   3244     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
   3245     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
   3246     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
   3247     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
   3248     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3249     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3250     _flag_k = FK_CMP;
   3251     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
   3252 L_31009B6C:
   3253     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
   3254 L_31009B6F:
   3255     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
   3256     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
   3257     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
   3258     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
   3259     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3260     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3261     _flag_k = FK_CMP;
   3262     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
   3263 L_31009B7D:
   3264     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
   3265     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
   3266 L_31009B82:
   3267     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
   3268     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
   3269     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   3270     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3271     _flag_k = FK_CMP;
   3272     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
   3273 L_31009B89:
   3274     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
   3275     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
   3276 L_31009B8D:
   3277     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
   3278 L_31009B90:
   3279     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
   3280     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
   3281     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
   3282     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
   3283 L_31009B9B:
   3284     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
   3285     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
   3286     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3287     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3288     _flag_k = FK_NARROW(FK_CMP, 24);
   3289     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
   3290 L_31009BA6:
   3291     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
   3292     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
   3293     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3294     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3295     _flag_k = FK_NARROW(FK_CMP, 24);
   3296     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
   3297 L_31009BB2:
   3298     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
   3299 L_31009BB4:
   3300     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
   3301     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
   3302     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   3303     _cf = 0;
   3304     _flag_k = FK_NARROW(FK_TEST, 24);
   3305     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
   3306 L_31009BBB:
   3307     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
   3308     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
   3309     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
   3310     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
   3311     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
   3312     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
   3313     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
   3314     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
   3315     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
   3316     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3317     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3318     _flag_k = FK_CMP;
   3319     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
   3320 L_31009BD7:
   3321     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
   3322 L_31009BDA:
   3323     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
   3324     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
   3325     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
   3326     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
   3327     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3328     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3329     _flag_k = FK_CMP;
   3330     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
   3331 L_31009BE8:
   3332     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
   3333     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
   3334 L_31009BED:
   3335     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
   3336     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
   3337     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   3338     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3339     _flag_k = FK_CMP;
   3340     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
   3341 L_31009BF5:
   3342     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
   3343     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
   3344 L_31009BFA:
   3345     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
   3346 L_31009BFC:
   3347     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
   3348     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
   3349     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
   3350     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
   3351 L_31009C07:
   3352     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
   3353     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
   3354     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3355     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3356     _flag_k = FK_NARROW(FK_CMP, 24);
   3357     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
   3358 L_31009C13:
   3359     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
   3360     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
   3361     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3362     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3363     _flag_k = FK_NARROW(FK_CMP, 24);
   3364     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
   3365 L_31009C1E:
   3366     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
   3367     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
   3368     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
   3369     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
   3370     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   3371     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3372     _flag_k = FK_CMP;
   3373     RECOMP_BACKEDGE();
   3374     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
   3375 L_31009C31:
   3376     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
   3377 L_31009C36:
   3378     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
   3379     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
   3380     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3381     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3382     _flag_k = FK_NARROW(FK_CMP, 24);
   3383     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
   3384 L_31009C3E:
   3385     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
   3386     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
   3387     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
   3388     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
   3389     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
   3390     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
   3391     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
   3392     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
   3393     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3394     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3395     _flag_k = FK_CMP;
   3396     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
   3397 L_31009C56:
   3398     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
   3399 L_31009C59:
   3400     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
   3401     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
   3402     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
   3403     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
   3404     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3405     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3406     _flag_k = FK_CMP;
   3407     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
   3408 L_31009C67:
   3409     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
   3410     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
   3411 L_31009C6C:
   3412     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
   3413     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
   3414     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   3415     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3416     _flag_k = FK_CMP;
   3417     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
   3418 L_31009C74:
   3419     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
   3420     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
   3421 L_31009C79:
   3422     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
   3423 L_31009C7B:
   3424     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   3425     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   3426     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   3427     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   3428 L_31009C87:
   3429     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   3430     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   3431     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   3432     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   3433     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   3434     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   3435     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   3436     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   3437     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   3438     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   3439     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   3440     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   3441     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   3442     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3443     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3444     _flag_k = FK_CMP;
   3445     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   3446 L_31009CAE:
   3447     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   3448 L_31009CB1:
   3449     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   3450     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   3451     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   3452     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   3453     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3454     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3455     _flag_k = FK_CMP;
   3456     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   3457 L_31009CBF:
   3458     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   3459     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   3460     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   3461 L_31009CC9:
   3462     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   3463     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   3464     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   3465     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3466     _flag_k = FK_CMP;
   3467     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   3468 L_31009CD0:
   3469     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   3470     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   3471     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   3472 L_31009CD9:
   3473     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   3474     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   3475     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   3476 L_31009CE3:
   3477     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
   3478     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
   3479     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3480     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3481     _flag_k = FK_NARROW(FK_CMP, 24);
   3482     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
   3483 L_31009CEA:
   3484     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
   3485     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
   3486     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
   3487     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
   3488     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
   3489     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
   3490     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
   3491     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
   3492     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3493     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3494     _flag_k = FK_CMP;
   3495     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
   3496 L_31009D03:
   3497     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
   3498 L_31009D06:
   3499     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
   3500     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
   3501     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
   3502     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
   3503     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3504     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3505     _flag_k = FK_CMP;
   3506     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
   3507 L_31009D14:
   3508     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
   3509     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
   3510 L_31009D19:
   3511     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
   3512     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
   3513     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   3514     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3515     _flag_k = FK_CMP;
   3516     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
   3517 L_31009D20:
   3518     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
   3519     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
   3520 L_31009D24:
   3521     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
   3522 L_31009D27:
   3523     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   3524     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   3525     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   3526     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   3527 L_31009D31:
   3528     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   3529     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   3530     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   3531     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   3532     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   3533     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   3534     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   3535     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   3536     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   3537     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   3538     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   3539     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   3540     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   3541     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3542     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3543     _flag_k = FK_CMP;
   3544     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   3545 L_31009D57:
   3546     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   3547 L_31009D5A:
   3548     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   3549     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   3550     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   3551     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   3552     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3553     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3554     _flag_k = FK_CMP;
   3555     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   3556 L_31009D68:
   3557     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   3558     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   3559 L_31009D6D:
   3560     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   3561     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   3562     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   3563     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3564     _flag_k = FK_CMP;
   3565     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   3566 L_31009D75:
   3567     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   3568     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   3569 L_31009D7A:
   3570     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   3571 L_31009D7C:
   3572     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   3573 L_31009D7F:
   3574     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   3575 L_31009D82:
   3576     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   3577     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   3578     PUSH32(esp, edx); /* 0x31009D88: push edx */
   3579     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   3580     RECOMP_FLAGS_IN();
   3581     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   3582     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   3583     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   3584     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   3585     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   3586     _flag_k = FK_ADD;
   3587     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   3588     eax = eax - 1; /* 0x31009D97: dec eax */
   3589     _flag_k = FK_DEC;
   3590     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   3591     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   3592     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   3593     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   3594     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   3595     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   3596     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   3597     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   3598     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   3599     RECOMP_REGS_OUT();
   3600 }
   3601 
   3602 void sub_31009BFC(void) {
   3603     int _fpu_cmp = 0;
   3604     uint32_t _cf = 0;
   3605     int _df = 1;
   3606     uint32_t _flag_k = FK_NONE;
   3607     uint32_t _flag_a = 0, _flag_b = 0;
   3608     uint32_t _itail_tgt = 0;
   3609     RECOMP_REGS_LOCALS
   3610     RECOMP_ENTER(0x31009BFCu);
   3611 
   3612     goto L_31009BFC;
   3613 L_31009B34:
   3614     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
   3615     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3616     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3617     _flag_k = FK_NARROW(FK_CMP, 24);
   3618     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
   3619 L_31009B3D:
   3620     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
   3621     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
   3622     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
   3623     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   3624     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3625     _flag_k = FK_CMP;
   3626     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
   3627 L_31009B46:
   3628     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
   3629     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
   3630     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
   3631     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   3632     _cf = 0;
   3633     _flag_k = FK_NARROW(FK_TEST, 24);
   3634     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
   3635 L_31009B50:
   3636     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
   3637     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
   3638     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
   3639     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
   3640     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
   3641     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
   3642     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
   3643     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
   3644     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
   3645     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3646     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3647     _flag_k = FK_CMP;
   3648     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
   3649 L_31009B6C:
   3650     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
   3651 L_31009B6F:
   3652     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
   3653     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
   3654     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
   3655     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
   3656     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3657     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3658     _flag_k = FK_CMP;
   3659     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
   3660 L_31009B7D:
   3661     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
   3662     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
   3663 L_31009B82:
   3664     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
   3665     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
   3666     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   3667     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3668     _flag_k = FK_CMP;
   3669     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
   3670 L_31009B89:
   3671     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
   3672     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
   3673 L_31009B8D:
   3674     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
   3675 L_31009B90:
   3676     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
   3677     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
   3678     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
   3679     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
   3680 L_31009B9B:
   3681     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
   3682     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
   3683     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3684     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3685     _flag_k = FK_NARROW(FK_CMP, 24);
   3686     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
   3687 L_31009BA6:
   3688     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
   3689     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
   3690     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3691     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3692     _flag_k = FK_NARROW(FK_CMP, 24);
   3693     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
   3694 L_31009BB2:
   3695     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
   3696 L_31009BB4:
   3697     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
   3698     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
   3699     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   3700     _cf = 0;
   3701     _flag_k = FK_NARROW(FK_TEST, 24);
   3702     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
   3703 L_31009BBB:
   3704     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
   3705     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
   3706     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
   3707     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
   3708     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
   3709     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
   3710     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
   3711     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
   3712     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
   3713     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3714     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3715     _flag_k = FK_CMP;
   3716     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
   3717 L_31009BD7:
   3718     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
   3719 L_31009BDA:
   3720     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
   3721     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
   3722     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
   3723     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
   3724     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3725     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3726     _flag_k = FK_CMP;
   3727     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
   3728 L_31009BE8:
   3729     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
   3730     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
   3731 L_31009BED:
   3732     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
   3733     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
   3734     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   3735     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3736     _flag_k = FK_CMP;
   3737     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
   3738 L_31009BF5:
   3739     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
   3740     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
   3741 L_31009BFA:
   3742     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
   3743 L_31009BFC:
   3744     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
   3745     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
   3746     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
   3747     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
   3748 L_31009C07:
   3749     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
   3750     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
   3751     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3752     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3753     _flag_k = FK_NARROW(FK_CMP, 24);
   3754     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
   3755 L_31009C13:
   3756     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
   3757     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
   3758     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3759     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3760     _flag_k = FK_NARROW(FK_CMP, 24);
   3761     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
   3762 L_31009C1E:
   3763     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
   3764     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
   3765     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
   3766     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
   3767     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   3768     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3769     _flag_k = FK_CMP;
   3770     RECOMP_BACKEDGE();
   3771     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
   3772 L_31009C31:
   3773     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
   3774 L_31009C36:
   3775     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
   3776     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
   3777     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3778     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3779     _flag_k = FK_NARROW(FK_CMP, 24);
   3780     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
   3781 L_31009C3E:
   3782     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
   3783     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
   3784     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
   3785     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
   3786     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
   3787     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
   3788     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
   3789     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
   3790     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3791     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3792     _flag_k = FK_CMP;
   3793     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
   3794 L_31009C56:
   3795     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
   3796 L_31009C59:
   3797     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
   3798     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
   3799     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
   3800     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
   3801     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3802     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3803     _flag_k = FK_CMP;
   3804     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
   3805 L_31009C67:
   3806     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
   3807     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
   3808 L_31009C6C:
   3809     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
   3810     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
   3811     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   3812     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3813     _flag_k = FK_CMP;
   3814     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
   3815 L_31009C74:
   3816     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
   3817     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
   3818 L_31009C79:
   3819     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
   3820 L_31009C7B:
   3821     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   3822     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   3823     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   3824     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   3825 L_31009C87:
   3826     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   3827     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   3828     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   3829     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   3830     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   3831     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   3832     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   3833     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   3834     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   3835     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   3836     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   3837     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   3838     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   3839     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3840     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3841     _flag_k = FK_CMP;
   3842     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   3843 L_31009CAE:
   3844     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   3845 L_31009CB1:
   3846     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   3847     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   3848     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   3849     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   3850     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3851     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3852     _flag_k = FK_CMP;
   3853     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   3854 L_31009CBF:
   3855     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   3856     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   3857     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   3858 L_31009CC9:
   3859     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   3860     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   3861     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   3862     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3863     _flag_k = FK_CMP;
   3864     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   3865 L_31009CD0:
   3866     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   3867     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   3868     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   3869 L_31009CD9:
   3870     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   3871     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   3872     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   3873 L_31009CE3:
   3874     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
   3875     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
   3876     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   3877     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3878     _flag_k = FK_NARROW(FK_CMP, 24);
   3879     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
   3880 L_31009CEA:
   3881     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
   3882     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
   3883     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
   3884     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
   3885     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
   3886     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
   3887     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
   3888     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
   3889     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3890     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3891     _flag_k = FK_CMP;
   3892     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
   3893 L_31009D03:
   3894     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
   3895 L_31009D06:
   3896     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
   3897     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
   3898     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
   3899     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
   3900     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3901     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3902     _flag_k = FK_CMP;
   3903     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
   3904 L_31009D14:
   3905     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
   3906     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
   3907 L_31009D19:
   3908     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
   3909     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
   3910     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   3911     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3912     _flag_k = FK_CMP;
   3913     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
   3914 L_31009D20:
   3915     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
   3916     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
   3917 L_31009D24:
   3918     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
   3919 L_31009D27:
   3920     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   3921     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   3922     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   3923     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   3924 L_31009D31:
   3925     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   3926     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   3927     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   3928     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   3929     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   3930     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   3931     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   3932     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   3933     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   3934     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   3935     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   3936     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   3937     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   3938     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   3939     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3940     _flag_k = FK_CMP;
   3941     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   3942 L_31009D57:
   3943     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   3944 L_31009D5A:
   3945     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   3946     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   3947     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   3948     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   3949     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   3950     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3951     _flag_k = FK_CMP;
   3952     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   3953 L_31009D68:
   3954     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   3955     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   3956 L_31009D6D:
   3957     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   3958     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   3959     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   3960     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   3961     _flag_k = FK_CMP;
   3962     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   3963 L_31009D75:
   3964     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   3965     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   3966 L_31009D7A:
   3967     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   3968 L_31009D7C:
   3969     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   3970 L_31009D7F:
   3971     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   3972 L_31009D82:
   3973     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   3974     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   3975     PUSH32(esp, edx); /* 0x31009D88: push edx */
   3976     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   3977     RECOMP_FLAGS_IN();
   3978     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   3979     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   3980     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   3981     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   3982     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   3983     _flag_k = FK_ADD;
   3984     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   3985     eax = eax - 1; /* 0x31009D97: dec eax */
   3986     _flag_k = FK_DEC;
   3987     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   3988     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   3989     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   3990     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   3991     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   3992     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   3993     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   3994     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   3995     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   3996     RECOMP_REGS_OUT();
   3997 }
   3998 
   3999 void sub_31009C07(void) {
   4000     int _fpu_cmp = 0;
   4001     uint32_t _cf = 0;
   4002     int _df = 1;
   4003     uint32_t _flag_k = FK_NONE;
   4004     uint32_t _flag_a = 0, _flag_b = 0;
   4005     uint32_t _itail_tgt = 0;
   4006     RECOMP_REGS_LOCALS
   4007     RECOMP_ENTER(0x31009C07u);
   4008 
   4009     goto L_31009C07;
   4010 L_31009B34:
   4011     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
   4012     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4013     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4014     _flag_k = FK_NARROW(FK_CMP, 24);
   4015     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
   4016 L_31009B3D:
   4017     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
   4018     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
   4019     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
   4020     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   4021     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4022     _flag_k = FK_CMP;
   4023     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
   4024 L_31009B46:
   4025     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
   4026     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
   4027     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
   4028     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   4029     _cf = 0;
   4030     _flag_k = FK_NARROW(FK_TEST, 24);
   4031     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
   4032 L_31009B50:
   4033     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
   4034     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
   4035     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
   4036     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
   4037     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
   4038     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
   4039     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
   4040     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
   4041     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
   4042     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4043     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4044     _flag_k = FK_CMP;
   4045     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
   4046 L_31009B6C:
   4047     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
   4048 L_31009B6F:
   4049     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
   4050     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
   4051     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
   4052     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
   4053     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4054     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4055     _flag_k = FK_CMP;
   4056     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
   4057 L_31009B7D:
   4058     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
   4059     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
   4060 L_31009B82:
   4061     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
   4062     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
   4063     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   4064     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4065     _flag_k = FK_CMP;
   4066     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
   4067 L_31009B89:
   4068     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
   4069     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
   4070 L_31009B8D:
   4071     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
   4072 L_31009B90:
   4073     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
   4074     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
   4075     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
   4076     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
   4077 L_31009B9B:
   4078     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
   4079     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
   4080     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4081     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4082     _flag_k = FK_NARROW(FK_CMP, 24);
   4083     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
   4084 L_31009BA6:
   4085     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
   4086     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
   4087     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4088     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4089     _flag_k = FK_NARROW(FK_CMP, 24);
   4090     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
   4091 L_31009BB2:
   4092     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
   4093 L_31009BB4:
   4094     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
   4095     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
   4096     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   4097     _cf = 0;
   4098     _flag_k = FK_NARROW(FK_TEST, 24);
   4099     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
   4100 L_31009BBB:
   4101     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
   4102     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
   4103     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
   4104     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
   4105     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
   4106     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
   4107     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
   4108     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
   4109     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
   4110     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4111     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4112     _flag_k = FK_CMP;
   4113     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
   4114 L_31009BD7:
   4115     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
   4116 L_31009BDA:
   4117     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
   4118     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
   4119     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
   4120     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
   4121     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4122     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4123     _flag_k = FK_CMP;
   4124     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
   4125 L_31009BE8:
   4126     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
   4127     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
   4128 L_31009BED:
   4129     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
   4130     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
   4131     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   4132     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4133     _flag_k = FK_CMP;
   4134     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
   4135 L_31009BF5:
   4136     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
   4137     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
   4138 L_31009BFA:
   4139     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
   4140 L_31009BFC:
   4141     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
   4142     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
   4143     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
   4144     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
   4145 L_31009C07:
   4146     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
   4147     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
   4148     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4149     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4150     _flag_k = FK_NARROW(FK_CMP, 24);
   4151     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
   4152 L_31009C13:
   4153     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
   4154     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
   4155     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4156     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4157     _flag_k = FK_NARROW(FK_CMP, 24);
   4158     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
   4159 L_31009C1E:
   4160     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
   4161     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
   4162     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
   4163     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
   4164     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   4165     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4166     _flag_k = FK_CMP;
   4167     RECOMP_BACKEDGE();
   4168     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
   4169 L_31009C31:
   4170     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
   4171 L_31009C36:
   4172     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
   4173     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
   4174     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4175     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4176     _flag_k = FK_NARROW(FK_CMP, 24);
   4177     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
   4178 L_31009C3E:
   4179     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
   4180     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
   4181     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
   4182     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
   4183     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
   4184     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
   4185     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
   4186     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
   4187     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4188     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4189     _flag_k = FK_CMP;
   4190     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
   4191 L_31009C56:
   4192     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
   4193 L_31009C59:
   4194     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
   4195     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
   4196     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
   4197     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
   4198     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4199     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4200     _flag_k = FK_CMP;
   4201     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
   4202 L_31009C67:
   4203     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
   4204     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
   4205 L_31009C6C:
   4206     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
   4207     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
   4208     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   4209     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4210     _flag_k = FK_CMP;
   4211     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
   4212 L_31009C74:
   4213     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
   4214     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
   4215 L_31009C79:
   4216     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
   4217 L_31009C7B:
   4218     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   4219     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   4220     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   4221     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   4222 L_31009C87:
   4223     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   4224     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   4225     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   4226     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   4227     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   4228     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   4229     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   4230     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   4231     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   4232     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   4233     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   4234     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   4235     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   4236     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4237     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4238     _flag_k = FK_CMP;
   4239     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   4240 L_31009CAE:
   4241     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   4242 L_31009CB1:
   4243     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   4244     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   4245     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   4246     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   4247     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4248     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4249     _flag_k = FK_CMP;
   4250     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   4251 L_31009CBF:
   4252     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   4253     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   4254     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   4255 L_31009CC9:
   4256     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   4257     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   4258     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   4259     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4260     _flag_k = FK_CMP;
   4261     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   4262 L_31009CD0:
   4263     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   4264     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   4265     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   4266 L_31009CD9:
   4267     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   4268     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   4269     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   4270 L_31009CE3:
   4271     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
   4272     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
   4273     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4274     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4275     _flag_k = FK_NARROW(FK_CMP, 24);
   4276     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
   4277 L_31009CEA:
   4278     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
   4279     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
   4280     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
   4281     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
   4282     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
   4283     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
   4284     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
   4285     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
   4286     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4287     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4288     _flag_k = FK_CMP;
   4289     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
   4290 L_31009D03:
   4291     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
   4292 L_31009D06:
   4293     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
   4294     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
   4295     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
   4296     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
   4297     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4298     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4299     _flag_k = FK_CMP;
   4300     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
   4301 L_31009D14:
   4302     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
   4303     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
   4304 L_31009D19:
   4305     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
   4306     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
   4307     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   4308     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4309     _flag_k = FK_CMP;
   4310     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
   4311 L_31009D20:
   4312     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
   4313     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
   4314 L_31009D24:
   4315     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
   4316 L_31009D27:
   4317     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   4318     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   4319     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   4320     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   4321 L_31009D31:
   4322     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   4323     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   4324     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   4325     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   4326     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   4327     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   4328     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   4329     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   4330     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   4331     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   4332     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   4333     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   4334     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   4335     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4336     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4337     _flag_k = FK_CMP;
   4338     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   4339 L_31009D57:
   4340     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   4341 L_31009D5A:
   4342     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   4343     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   4344     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   4345     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   4346     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4347     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4348     _flag_k = FK_CMP;
   4349     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   4350 L_31009D68:
   4351     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   4352     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   4353 L_31009D6D:
   4354     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   4355     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   4356     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   4357     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4358     _flag_k = FK_CMP;
   4359     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   4360 L_31009D75:
   4361     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   4362     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   4363 L_31009D7A:
   4364     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   4365 L_31009D7C:
   4366     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   4367 L_31009D7F:
   4368     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   4369 L_31009D82:
   4370     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   4371     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   4372     PUSH32(esp, edx); /* 0x31009D88: push edx */
   4373     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   4374     RECOMP_FLAGS_IN();
   4375     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   4376     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   4377     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   4378     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4379     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   4380     _flag_k = FK_ADD;
   4381     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   4382     eax = eax - 1; /* 0x31009D97: dec eax */
   4383     _flag_k = FK_DEC;
   4384     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   4385     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   4386     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   4387     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   4388     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   4389     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   4390     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   4391     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   4392     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   4393     RECOMP_REGS_OUT();
   4394 }
   4395 
   4396 void sub_31009C1E(void) {
   4397     int _fpu_cmp = 0;
   4398     uint32_t _cf = 0;
   4399     int _df = 1;
   4400     uint32_t _flag_k = FK_NONE;
   4401     uint32_t _flag_a = 0, _flag_b = 0;
   4402     uint32_t _itail_tgt = 0;
   4403     RECOMP_REGS_LOCALS
   4404     RECOMP_ENTER(0x31009C1Eu);
   4405 
   4406     goto L_31009C1E;
   4407 L_31009B34:
   4408     /* cmp MEM8(eax + 0x14), LO8(ebx) */ /* 0x31009B34: cmp byte ptr [eax + 0x14], bl */
   4409     _flag_a = (uint32_t)(MEM8(eax + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4410     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4411     _flag_k = FK_NARROW(FK_CMP, 24);
   4412     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D82; /* 0x31009B37: jne 0x31009d82 */
   4413 L_31009B3D:
   4414     edx = MEM32(eax + 0x4); /* 0x31009B3D: mov edx, dword ptr [eax + 4] */
   4415     ecx = MEM32(edx); /* 0x31009B40: mov ecx, dword ptr [edx] */
   4416     /* cmp eax, ecx */ /* 0x31009B42: cmp eax, ecx */
   4417     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   4418     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4419     _flag_k = FK_CMP;
   4420     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BB4; /* 0x31009B44: jne 0x31009bb4 */
   4421 L_31009B46:
   4422     ecx = MEM32(edx + 0x8); /* 0x31009B46: mov ecx, dword ptr [edx + 8] */
   4423     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009B49: mov dl, byte ptr [ecx + 0x14] */
   4424     /* test LO8(edx), LO8(edx) */ /* 0x31009B4C: test dl, dl */
   4425     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   4426     _cf = 0;
   4427     _flag_k = FK_NARROW(FK_TEST, 24);
   4428     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009B9B; /* 0x31009B4E: jne 0x31009b9b */
   4429 L_31009B50:
   4430     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009B50: mov byte ptr [ecx + 0x14], bl */
   4431     ecx = MEM32(eax + 0x4); /* 0x31009B53: mov ecx, dword ptr [eax + 4] */
   4432     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009B56: mov byte ptr [ecx + 0x14], 0 */
   4433     ecx = MEM32(eax + 0x4); /* 0x31009B5A: mov ecx, dword ptr [eax + 4] */
   4434     edx = MEM32(ecx + 0x8); /* 0x31009B5D: mov edx, dword ptr [ecx + 8] */
   4435     esi = MEM32(edx); /* 0x31009B60: mov esi, dword ptr [edx] */
   4436     MEM32(ecx + 0x8) = esi; /* 0x31009B62: mov dword ptr [ecx + 8], esi */
   4437     esi = MEM32(edx); /* 0x31009B65: mov esi, dword ptr [edx] */
   4438     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009B67: cmp esi, dword ptr [edi + 8] */
   4439     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4440     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4441     _flag_k = FK_CMP;
   4442     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009B6F; /* 0x31009B6A: je 0x31009b6f */
   4443 L_31009B6C:
   4444     MEM32(esi + 0x4) = ecx; /* 0x31009B6C: mov dword ptr [esi + 4], ecx */
   4445 L_31009B6F:
   4446     esi = MEM32(ecx + 0x4); /* 0x31009B6F: mov esi, dword ptr [ecx + 4] */
   4447     MEM32(edx + 0x4) = esi; /* 0x31009B72: mov dword ptr [edx + 4], esi */
   4448     esi = MEM32(edi + 0x4); /* 0x31009B75: mov esi, dword ptr [edi + 4] */
   4449     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009B78: cmp ecx, dword ptr [esi + 4] */
   4450     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4451     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4452     _flag_k = FK_CMP;
   4453     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B82; /* 0x31009B7B: jne 0x31009b82 */
   4454 L_31009B7D:
   4455     MEM32(esi + 0x4) = edx; /* 0x31009B7D: mov dword ptr [esi + 4], edx */
   4456     goto L_31009B90; /* 0x31009B80: jmp 0x31009b90 */
   4457 L_31009B82:
   4458     esi = MEM32(ecx + 0x4); /* 0x31009B82: mov esi, dword ptr [ecx + 4] */
   4459     /* cmp ecx, MEM32(esi) */ /* 0x31009B85: cmp ecx, dword ptr [esi] */
   4460     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   4461     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4462     _flag_k = FK_CMP;
   4463     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B8D; /* 0x31009B87: jne 0x31009b8d */
   4464 L_31009B89:
   4465     MEM32(esi) = edx; /* 0x31009B89: mov dword ptr [esi], edx */
   4466     goto L_31009B90; /* 0x31009B8B: jmp 0x31009b90 */
   4467 L_31009B8D:
   4468     MEM32(esi + 0x8) = edx; /* 0x31009B8D: mov dword ptr [esi + 8], edx */
   4469 L_31009B90:
   4470     MEM32(edx) = ecx; /* 0x31009B90: mov dword ptr [edx], ecx */
   4471     MEM32(ecx + 0x4) = edx; /* 0x31009B92: mov dword ptr [ecx + 4], edx */
   4472     edx = MEM32(eax + 0x4); /* 0x31009B95: mov edx, dword ptr [eax + 4] */
   4473     ecx = MEM32(edx + 0x8); /* 0x31009B98: mov ecx, dword ptr [edx + 8] */
   4474 L_31009B9B:
   4475     edx = MEM32(ecx); /* 0x31009B9B: mov edx, dword ptr [ecx] */
   4476     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009B9D: cmp byte ptr [edx + 0x14], bl */
   4477     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4478     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4479     _flag_k = FK_NARROW(FK_CMP, 24);
   4480     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BA0: jne 0x31009c36 */
   4481 L_31009BA6:
   4482     edx = MEM32(ecx + 0x8); /* 0x31009BA6: mov edx, dword ptr [ecx + 8] */
   4483     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009BA9: cmp byte ptr [edx + 0x14], bl */
   4484     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4485     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4486     _flag_k = FK_NARROW(FK_CMP, 24);
   4487     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C36; /* 0x31009BAC: jne 0x31009c36 */
   4488 L_31009BB2:
   4489     goto L_31009C1E; /* 0x31009BB2: jmp 0x31009c1e */
   4490 L_31009BB4:
   4491     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x31009BB4: mov dl, byte ptr [ecx + 0x14] */
   4492     /* test LO8(edx), LO8(edx) */ /* 0x31009BB7: test dl, dl */
   4493     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   4494     _cf = 0;
   4495     _flag_k = FK_NARROW(FK_TEST, 24);
   4496     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009C07; /* 0x31009BB9: jne 0x31009c07 */
   4497 L_31009BBB:
   4498     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009BBB: mov byte ptr [ecx + 0x14], bl */
   4499     ecx = MEM32(eax + 0x4); /* 0x31009BBE: mov ecx, dword ptr [eax + 4] */
   4500     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009BC1: mov byte ptr [ecx + 0x14], 0 */
   4501     ecx = MEM32(eax + 0x4); /* 0x31009BC5: mov ecx, dword ptr [eax + 4] */
   4502     edx = MEM32(ecx); /* 0x31009BC8: mov edx, dword ptr [ecx] */
   4503     esi = MEM32(edx + 0x8); /* 0x31009BCA: mov esi, dword ptr [edx + 8] */
   4504     MEM32(ecx) = esi; /* 0x31009BCD: mov dword ptr [ecx], esi */
   4505     esi = MEM32(edx + 0x8); /* 0x31009BCF: mov esi, dword ptr [edx + 8] */
   4506     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009BD2: cmp esi, dword ptr [edi + 8] */
   4507     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4508     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4509     _flag_k = FK_CMP;
   4510     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009BDA; /* 0x31009BD5: je 0x31009bda */
   4511 L_31009BD7:
   4512     MEM32(esi + 0x4) = ecx; /* 0x31009BD7: mov dword ptr [esi + 4], ecx */
   4513 L_31009BDA:
   4514     esi = MEM32(ecx + 0x4); /* 0x31009BDA: mov esi, dword ptr [ecx + 4] */
   4515     MEM32(edx + 0x4) = esi; /* 0x31009BDD: mov dword ptr [edx + 4], esi */
   4516     esi = MEM32(edi + 0x4); /* 0x31009BE0: mov esi, dword ptr [edi + 4] */
   4517     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009BE3: cmp ecx, dword ptr [esi + 4] */
   4518     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4519     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4520     _flag_k = FK_CMP;
   4521     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BED; /* 0x31009BE6: jne 0x31009bed */
   4522 L_31009BE8:
   4523     MEM32(esi + 0x4) = edx; /* 0x31009BE8: mov dword ptr [esi + 4], edx */
   4524     goto L_31009BFC; /* 0x31009BEB: jmp 0x31009bfc */
   4525 L_31009BED:
   4526     esi = MEM32(ecx + 0x4); /* 0x31009BED: mov esi, dword ptr [ecx + 4] */
   4527     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009BF0: cmp ecx, dword ptr [esi + 8] */
   4528     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   4529     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4530     _flag_k = FK_CMP;
   4531     if (CMP_NE(_flag_a, _flag_b)) goto L_31009BFA; /* 0x31009BF3: jne 0x31009bfa */
   4532 L_31009BF5:
   4533     MEM32(esi + 0x8) = edx; /* 0x31009BF5: mov dword ptr [esi + 8], edx */
   4534     goto L_31009BFC; /* 0x31009BF8: jmp 0x31009bfc */
   4535 L_31009BFA:
   4536     MEM32(esi) = edx; /* 0x31009BFA: mov dword ptr [esi], edx */
   4537 L_31009BFC:
   4538     MEM32(edx + 0x8) = ecx; /* 0x31009BFC: mov dword ptr [edx + 8], ecx */
   4539     MEM32(ecx + 0x4) = edx; /* 0x31009BFF: mov dword ptr [ecx + 4], edx */
   4540     edx = MEM32(eax + 0x4); /* 0x31009C02: mov edx, dword ptr [eax + 4] */
   4541     ecx = MEM32(edx); /* 0x31009C05: mov ecx, dword ptr [edx] */
   4542 L_31009C07:
   4543     edx = MEM32(ecx + 0x8); /* 0x31009C07: mov edx, dword ptr [ecx + 8] */
   4544     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C0A: cmp byte ptr [edx + 0x14], bl */
   4545     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4546     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4547     _flag_k = FK_NARROW(FK_CMP, 24);
   4548     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C0D: jne 0x31009ce3 */
   4549 L_31009C13:
   4550     edx = MEM32(ecx); /* 0x31009C13: mov edx, dword ptr [ecx] */
   4551     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C15: cmp byte ptr [edx + 0x14], bl */
   4552     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4553     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4554     _flag_k = FK_NARROW(FK_CMP, 24);
   4555     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CE3; /* 0x31009C18: jne 0x31009ce3 */
   4556 L_31009C1E:
   4557     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C1E: mov byte ptr [ecx + 0x14], 0 */
   4558     ecx = MEM32(edi + 0x4); /* 0x31009C22: mov ecx, dword ptr [edi + 4] */
   4559     eax = MEM32(eax + 0x4); /* 0x31009C25: mov eax, dword ptr [eax + 4] */
   4560     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x31009C28: cmp eax, dword ptr [ecx + 4] */
   4561     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   4562     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4563     _flag_k = FK_CMP;
   4564     RECOMP_BACKEDGE();
   4565     if (CMP_NE(_flag_a, _flag_b)) goto L_31009B34; /* 0x31009C2B: jne 0x31009b34 */
   4566 L_31009C31:
   4567     goto L_31009D82; /* 0x31009C31: jmp 0x31009d82 */
   4568 L_31009C36:
   4569     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
   4570     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
   4571     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4572     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4573     _flag_k = FK_NARROW(FK_CMP, 24);
   4574     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
   4575 L_31009C3E:
   4576     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
   4577     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
   4578     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
   4579     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
   4580     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
   4581     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
   4582     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
   4583     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
   4584     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4585     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4586     _flag_k = FK_CMP;
   4587     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
   4588 L_31009C56:
   4589     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
   4590 L_31009C59:
   4591     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
   4592     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
   4593     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
   4594     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
   4595     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4596     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4597     _flag_k = FK_CMP;
   4598     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
   4599 L_31009C67:
   4600     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
   4601     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
   4602 L_31009C6C:
   4603     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
   4604     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
   4605     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   4606     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4607     _flag_k = FK_CMP;
   4608     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
   4609 L_31009C74:
   4610     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
   4611     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
   4612 L_31009C79:
   4613     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
   4614 L_31009C7B:
   4615     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   4616     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   4617     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   4618     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   4619 L_31009C87:
   4620     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   4621     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   4622     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   4623     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   4624     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   4625     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   4626     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   4627     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   4628     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   4629     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   4630     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   4631     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   4632     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   4633     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4634     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4635     _flag_k = FK_CMP;
   4636     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   4637 L_31009CAE:
   4638     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   4639 L_31009CB1:
   4640     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   4641     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   4642     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   4643     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   4644     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4645     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4646     _flag_k = FK_CMP;
   4647     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   4648 L_31009CBF:
   4649     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   4650     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   4651     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   4652 L_31009CC9:
   4653     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   4654     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   4655     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   4656     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4657     _flag_k = FK_CMP;
   4658     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   4659 L_31009CD0:
   4660     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   4661     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   4662     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   4663 L_31009CD9:
   4664     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   4665     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   4666     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   4667 L_31009CE3:
   4668     edx = MEM32(ecx); /* 0x31009CE3: mov edx, dword ptr [ecx] */
   4669     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009CE5: cmp byte ptr [edx + 0x14], bl */
   4670     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4671     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4672     _flag_k = FK_NARROW(FK_CMP, 24);
   4673     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D31; /* 0x31009CE8: jne 0x31009d31 */
   4674 L_31009CEA:
   4675     edx = MEM32(ecx + 0x8); /* 0x31009CEA: mov edx, dword ptr [ecx + 8] */
   4676     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009CED: mov byte ptr [edx + 0x14], bl */
   4677     edx = MEM32(ecx + 0x8); /* 0x31009CF0: mov edx, dword ptr [ecx + 8] */
   4678     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009CF3: mov byte ptr [ecx + 0x14], 0 */
   4679     esi = MEM32(edx); /* 0x31009CF7: mov esi, dword ptr [edx] */
   4680     MEM32(ecx + 0x8) = esi; /* 0x31009CF9: mov dword ptr [ecx + 8], esi */
   4681     esi = MEM32(edx); /* 0x31009CFC: mov esi, dword ptr [edx] */
   4682     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CFE: cmp esi, dword ptr [edi + 8] */
   4683     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4684     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4685     _flag_k = FK_CMP;
   4686     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D06; /* 0x31009D01: je 0x31009d06 */
   4687 L_31009D03:
   4688     MEM32(esi + 0x4) = ecx; /* 0x31009D03: mov dword ptr [esi + 4], ecx */
   4689 L_31009D06:
   4690     esi = MEM32(ecx + 0x4); /* 0x31009D06: mov esi, dword ptr [ecx + 4] */
   4691     MEM32(edx + 0x4) = esi; /* 0x31009D09: mov dword ptr [edx + 4], esi */
   4692     esi = MEM32(edi + 0x4); /* 0x31009D0C: mov esi, dword ptr [edi + 4] */
   4693     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D0F: cmp ecx, dword ptr [esi + 4] */
   4694     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4695     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4696     _flag_k = FK_CMP;
   4697     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D19; /* 0x31009D12: jne 0x31009d19 */
   4698 L_31009D14:
   4699     MEM32(esi + 0x4) = edx; /* 0x31009D14: mov dword ptr [esi + 4], edx */
   4700     goto L_31009D27; /* 0x31009D17: jmp 0x31009d27 */
   4701 L_31009D19:
   4702     esi = MEM32(ecx + 0x4); /* 0x31009D19: mov esi, dword ptr [ecx + 4] */
   4703     /* cmp ecx, MEM32(esi) */ /* 0x31009D1C: cmp ecx, dword ptr [esi] */
   4704     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   4705     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4706     _flag_k = FK_CMP;
   4707     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D24; /* 0x31009D1E: jne 0x31009d24 */
   4708 L_31009D20:
   4709     MEM32(esi) = edx; /* 0x31009D20: mov dword ptr [esi], edx */
   4710     goto L_31009D27; /* 0x31009D22: jmp 0x31009d27 */
   4711 L_31009D24:
   4712     MEM32(esi + 0x8) = edx; /* 0x31009D24: mov dword ptr [esi + 8], edx */
   4713 L_31009D27:
   4714     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   4715     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   4716     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   4717     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   4718 L_31009D31:
   4719     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   4720     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   4721     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   4722     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   4723     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   4724     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   4725     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   4726     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   4727     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   4728     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   4729     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   4730     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   4731     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   4732     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4733     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4734     _flag_k = FK_CMP;
   4735     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   4736 L_31009D57:
   4737     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   4738 L_31009D5A:
   4739     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   4740     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   4741     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   4742     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   4743     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4744     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4745     _flag_k = FK_CMP;
   4746     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   4747 L_31009D68:
   4748     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   4749     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   4750 L_31009D6D:
   4751     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   4752     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   4753     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   4754     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4755     _flag_k = FK_CMP;
   4756     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   4757 L_31009D75:
   4758     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   4759     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   4760 L_31009D7A:
   4761     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   4762 L_31009D7C:
   4763     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   4764 L_31009D7F:
   4765     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   4766 L_31009D82:
   4767     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   4768     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   4769     PUSH32(esp, edx); /* 0x31009D88: push edx */
   4770     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   4771     RECOMP_FLAGS_IN();
   4772     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   4773     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   4774     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   4775     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4776     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   4777     _flag_k = FK_ADD;
   4778     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   4779     eax = eax - 1; /* 0x31009D97: dec eax */
   4780     _flag_k = FK_DEC;
   4781     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   4782     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   4783     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   4784     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   4785     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   4786     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   4787     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   4788     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   4789     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   4790     RECOMP_REGS_OUT();
   4791 }
   4792 
   4793 void sub_31009C36(void) {
   4794     int _fpu_cmp = 0;
   4795     uint32_t _cf = 0;
   4796     int _df = 1;
   4797     uint32_t _flag_k = FK_NONE;
   4798     uint32_t _flag_a = 0, _flag_b = 0;
   4799     uint32_t _itail_tgt = 0;
   4800     RECOMP_REGS_LOCALS
   4801     RECOMP_ENTER(0x31009C36u);
   4802 
   4803 L_31009C36:
   4804     edx = MEM32(ecx + 0x8); /* 0x31009C36: mov edx, dword ptr [ecx + 8] */
   4805     /* cmp MEM8(edx + 0x14), LO8(ebx) */ /* 0x31009C39: cmp byte ptr [edx + 0x14], bl */
   4806     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   4807     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4808     _flag_k = FK_NARROW(FK_CMP, 24);
   4809     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C87; /* 0x31009C3C: jne 0x31009c87 */
   4810 L_31009C3E:
   4811     edx = MEM32(ecx); /* 0x31009C3E: mov edx, dword ptr [ecx] */
   4812     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C40: mov byte ptr [edx + 0x14], bl */
   4813     edx = MEM32(ecx); /* 0x31009C43: mov edx, dword ptr [ecx] */
   4814     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x31009C45: mov byte ptr [ecx + 0x14], 0 */
   4815     esi = MEM32(edx + 0x8); /* 0x31009C49: mov esi, dword ptr [edx + 8] */
   4816     MEM32(ecx) = esi; /* 0x31009C4C: mov dword ptr [ecx], esi */
   4817     esi = MEM32(edx + 0x8); /* 0x31009C4E: mov esi, dword ptr [edx + 8] */
   4818     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009C51: cmp esi, dword ptr [edi + 8] */
   4819     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4820     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4821     _flag_k = FK_CMP;
   4822     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009C59; /* 0x31009C54: je 0x31009c59 */
   4823 L_31009C56:
   4824     MEM32(esi + 0x4) = ecx; /* 0x31009C56: mov dword ptr [esi + 4], ecx */
   4825 L_31009C59:
   4826     esi = MEM32(ecx + 0x4); /* 0x31009C59: mov esi, dword ptr [ecx + 4] */
   4827     MEM32(edx + 0x4) = esi; /* 0x31009C5C: mov dword ptr [edx + 4], esi */
   4828     esi = MEM32(edi + 0x4); /* 0x31009C5F: mov esi, dword ptr [edi + 4] */
   4829     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009C62: cmp ecx, dword ptr [esi + 4] */
   4830     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4831     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4832     _flag_k = FK_CMP;
   4833     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C6C; /* 0x31009C65: jne 0x31009c6c */
   4834 L_31009C67:
   4835     MEM32(esi + 0x4) = edx; /* 0x31009C67: mov dword ptr [esi + 4], edx */
   4836     goto L_31009C7B; /* 0x31009C6A: jmp 0x31009c7b */
   4837 L_31009C6C:
   4838     esi = MEM32(ecx + 0x4); /* 0x31009C6C: mov esi, dword ptr [ecx + 4] */
   4839     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009C6F: cmp ecx, dword ptr [esi + 8] */
   4840     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   4841     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4842     _flag_k = FK_CMP;
   4843     if (CMP_NE(_flag_a, _flag_b)) goto L_31009C79; /* 0x31009C72: jne 0x31009c79 */
   4844 L_31009C74:
   4845     MEM32(esi + 0x8) = edx; /* 0x31009C74: mov dword ptr [esi + 8], edx */
   4846     goto L_31009C7B; /* 0x31009C77: jmp 0x31009c7b */
   4847 L_31009C79:
   4848     MEM32(esi) = edx; /* 0x31009C79: mov dword ptr [esi], edx */
   4849 L_31009C7B:
   4850     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   4851     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   4852     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   4853     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   4854 L_31009C87:
   4855     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   4856     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   4857     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   4858     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   4859     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   4860     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   4861     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   4862     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   4863     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   4864     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   4865     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   4866     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   4867     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   4868     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4869     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4870     _flag_k = FK_CMP;
   4871     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   4872 L_31009CAE:
   4873     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   4874 L_31009CB1:
   4875     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   4876     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   4877     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   4878     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   4879     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4880     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4881     _flag_k = FK_CMP;
   4882     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   4883 L_31009CBF:
   4884     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   4885     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   4886     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   4887 L_31009CC9:
   4888     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   4889     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   4890     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   4891     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4892     _flag_k = FK_CMP;
   4893     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   4894 L_31009CD0:
   4895     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   4896     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   4897     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   4898 L_31009CD9:
   4899     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   4900     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   4901     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   4902 L_31009D7F:
   4903     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   4904     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   4905     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   4906     PUSH32(esp, edx); /* 0x31009D88: push edx */
   4907     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   4908     RECOMP_FLAGS_IN();
   4909     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   4910     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   4911     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   4912     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   4913     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   4914     _flag_k = FK_ADD;
   4915     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   4916     eax = eax - 1; /* 0x31009D97: dec eax */
   4917     _flag_k = FK_DEC;
   4918     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   4919     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   4920     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   4921     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   4922     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   4923     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   4924     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   4925     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   4926     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   4927     RECOMP_REGS_OUT();
   4928 }
   4929 
   4930 void sub_31009C7B(void) {
   4931     int _fpu_cmp = 0;
   4932     uint32_t _cf = 0;
   4933     int _df = 1;
   4934     uint32_t _flag_k = FK_NONE;
   4935     uint32_t _flag_a = 0, _flag_b = 0;
   4936     uint32_t _itail_tgt = 0;
   4937     RECOMP_REGS_LOCALS
   4938     RECOMP_ENTER(0x31009C7Bu);
   4939 
   4940 L_31009C7B:
   4941     MEM32(edx + 0x8) = ecx; /* 0x31009C7B: mov dword ptr [edx + 8], ecx */
   4942     MEM32(ecx + 0x4) = edx; /* 0x31009C7E: mov dword ptr [ecx + 4], edx */
   4943     ecx = MEM32(eax + 0x4); /* 0x31009C81: mov ecx, dword ptr [eax + 4] */
   4944     ecx = MEM32(ecx + 0x8); /* 0x31009C84: mov ecx, dword ptr [ecx + 8] */
   4945     edx = MEM32(eax + 0x4); /* 0x31009C87: mov edx, dword ptr [eax + 4] */
   4946     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009C8A: mov dl, byte ptr [edx + 0x14] */
   4947     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009C8D: mov byte ptr [ecx + 0x14], dl */
   4948     edx = MEM32(eax + 0x4); /* 0x31009C90: mov edx, dword ptr [eax + 4] */
   4949     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C93: mov byte ptr [edx + 0x14], bl */
   4950     ecx = MEM32(ecx + 0x8); /* 0x31009C96: mov ecx, dword ptr [ecx + 8] */
   4951     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009C99: mov byte ptr [ecx + 0x14], bl */
   4952     ecx = MEM32(eax + 0x4); /* 0x31009C9C: mov ecx, dword ptr [eax + 4] */
   4953     edx = MEM32(ecx + 0x8); /* 0x31009C9F: mov edx, dword ptr [ecx + 8] */
   4954     esi = MEM32(edx); /* 0x31009CA2: mov esi, dword ptr [edx] */
   4955     MEM32(ecx + 0x8) = esi; /* 0x31009CA4: mov dword ptr [ecx + 8], esi */
   4956     esi = MEM32(edx); /* 0x31009CA7: mov esi, dword ptr [edx] */
   4957     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009CA9: cmp esi, dword ptr [edi + 8] */
   4958     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   4959     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4960     _flag_k = FK_CMP;
   4961     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009CB1; /* 0x31009CAC: je 0x31009cb1 */
   4962 L_31009CAE:
   4963     MEM32(esi + 0x4) = ecx; /* 0x31009CAE: mov dword ptr [esi + 4], ecx */
   4964 L_31009CB1:
   4965     esi = MEM32(ecx + 0x4); /* 0x31009CB1: mov esi, dword ptr [ecx + 4] */
   4966     MEM32(edx + 0x4) = esi; /* 0x31009CB4: mov dword ptr [edx + 4], esi */
   4967     esi = MEM32(edi + 0x4); /* 0x31009CB7: mov esi, dword ptr [edi + 4] */
   4968     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009CBA: cmp ecx, dword ptr [esi + 4] */
   4969     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   4970     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4971     _flag_k = FK_CMP;
   4972     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CC9; /* 0x31009CBD: jne 0x31009cc9 */
   4973 L_31009CBF:
   4974     MEM32(esi + 0x4) = edx; /* 0x31009CBF: mov dword ptr [esi + 4], edx */
   4975     MEM32(edx) = ecx; /* 0x31009CC2: mov dword ptr [edx], ecx */
   4976     goto L_31009D7F; /* 0x31009CC4: jmp 0x31009d7f */
   4977 L_31009CC9:
   4978     esi = MEM32(ecx + 0x4); /* 0x31009CC9: mov esi, dword ptr [ecx + 4] */
   4979     /* cmp ecx, MEM32(esi) */ /* 0x31009CCC: cmp ecx, dword ptr [esi] */
   4980     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi));
   4981     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   4982     _flag_k = FK_CMP;
   4983     if (CMP_NE(_flag_a, _flag_b)) goto L_31009CD9; /* 0x31009CCE: jne 0x31009cd9 */
   4984 L_31009CD0:
   4985     MEM32(esi) = edx; /* 0x31009CD0: mov dword ptr [esi], edx */
   4986     MEM32(edx) = ecx; /* 0x31009CD2: mov dword ptr [edx], ecx */
   4987     goto L_31009D7F; /* 0x31009CD4: jmp 0x31009d7f */
   4988 L_31009CD9:
   4989     MEM32(esi + 0x8) = edx; /* 0x31009CD9: mov dword ptr [esi + 8], edx */
   4990     MEM32(edx) = ecx; /* 0x31009CDC: mov dword ptr [edx], ecx */
   4991     goto L_31009D7F; /* 0x31009CDE: jmp 0x31009d7f */
   4992 L_31009D7F:
   4993     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   4994     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   4995     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   4996     PUSH32(esp, edx); /* 0x31009D88: push edx */
   4997     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   4998     RECOMP_FLAGS_IN();
   4999     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   5000     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   5001     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5002     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5003     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   5004     _flag_k = FK_ADD;
   5005     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   5006     eax = eax - 1; /* 0x31009D97: dec eax */
   5007     _flag_k = FK_DEC;
   5008     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   5009     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   5010     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   5011     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   5012     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   5013     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   5014     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   5015     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   5016     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   5017     RECOMP_REGS_OUT();
   5018 }
   5019 
   5020 void sub_31009D27(void) {
   5021     int _fpu_cmp = 0;
   5022     uint32_t _cf = 0;
   5023     int _df = 1;
   5024     uint32_t _flag_k = FK_NONE;
   5025     uint32_t _flag_a = 0, _flag_b = 0;
   5026     uint32_t _itail_tgt = 0;
   5027     RECOMP_REGS_LOCALS
   5028     RECOMP_ENTER(0x31009D27u);
   5029 
   5030 L_31009D27:
   5031     MEM32(edx) = ecx; /* 0x31009D27: mov dword ptr [edx], ecx */
   5032     MEM32(ecx + 0x4) = edx; /* 0x31009D29: mov dword ptr [ecx + 4], edx */
   5033     ecx = MEM32(eax + 0x4); /* 0x31009D2C: mov ecx, dword ptr [eax + 4] */
   5034     ecx = MEM32(ecx); /* 0x31009D2F: mov ecx, dword ptr [ecx] */
   5035     edx = MEM32(eax + 0x4); /* 0x31009D31: mov edx, dword ptr [eax + 4] */
   5036     SET_LO8(edx, MEM8(edx + 0x14)); /* 0x31009D34: mov dl, byte ptr [edx + 0x14] */
   5037     MEM8(ecx + 0x14) = (uint8_t)(LO8(edx)); /* 0x31009D37: mov byte ptr [ecx + 0x14], dl */
   5038     edx = MEM32(eax + 0x4); /* 0x31009D3A: mov edx, dword ptr [eax + 4] */
   5039     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D3D: mov byte ptr [edx + 0x14], bl */
   5040     ecx = MEM32(ecx); /* 0x31009D40: mov ecx, dword ptr [ecx] */
   5041     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D42: mov byte ptr [ecx + 0x14], bl */
   5042     ecx = MEM32(eax + 0x4); /* 0x31009D45: mov ecx, dword ptr [eax + 4] */
   5043     edx = MEM32(ecx); /* 0x31009D48: mov edx, dword ptr [ecx] */
   5044     esi = MEM32(edx + 0x8); /* 0x31009D4A: mov esi, dword ptr [edx + 8] */
   5045     MEM32(ecx) = esi; /* 0x31009D4D: mov dword ptr [ecx], esi */
   5046     esi = MEM32(edx + 0x8); /* 0x31009D4F: mov esi, dword ptr [edx + 8] */
   5047     /* cmp esi, MEM32(edi + 0x8) */ /* 0x31009D52: cmp esi, dword ptr [edi + 8] */
   5048     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   5049     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5050     _flag_k = FK_CMP;
   5051     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009D5A; /* 0x31009D55: je 0x31009d5a */
   5052 L_31009D57:
   5053     MEM32(esi + 0x4) = ecx; /* 0x31009D57: mov dword ptr [esi + 4], ecx */
   5054 L_31009D5A:
   5055     esi = MEM32(ecx + 0x4); /* 0x31009D5A: mov esi, dword ptr [ecx + 4] */
   5056     MEM32(edx + 0x4) = esi; /* 0x31009D5D: mov dword ptr [edx + 4], esi */
   5057     esi = MEM32(edi + 0x4); /* 0x31009D60: mov esi, dword ptr [edi + 4] */
   5058     /* cmp ecx, MEM32(esi + 0x4) */ /* 0x31009D63: cmp ecx, dword ptr [esi + 4] */
   5059     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x4));
   5060     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5061     _flag_k = FK_CMP;
   5062     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D6D; /* 0x31009D66: jne 0x31009d6d */
   5063 L_31009D68:
   5064     MEM32(esi + 0x4) = edx; /* 0x31009D68: mov dword ptr [esi + 4], edx */
   5065     goto L_31009D7C; /* 0x31009D6B: jmp 0x31009d7c */
   5066 L_31009D6D:
   5067     esi = MEM32(ecx + 0x4); /* 0x31009D6D: mov esi, dword ptr [ecx + 4] */
   5068     /* cmp ecx, MEM32(esi + 0x8) */ /* 0x31009D70: cmp ecx, dword ptr [esi + 8] */
   5069     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   5070     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5071     _flag_k = FK_CMP;
   5072     if (CMP_NE(_flag_a, _flag_b)) goto L_31009D7A; /* 0x31009D73: jne 0x31009d7a */
   5073 L_31009D75:
   5074     MEM32(esi + 0x8) = edx; /* 0x31009D75: mov dword ptr [esi + 8], edx */
   5075     goto L_31009D7C; /* 0x31009D78: jmp 0x31009d7c */
   5076 L_31009D7A:
   5077     MEM32(esi) = edx; /* 0x31009D7A: mov dword ptr [esi], edx */
   5078 L_31009D7C:
   5079     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   5080     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   5081     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   5082     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   5083     PUSH32(esp, edx); /* 0x31009D88: push edx */
   5084     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   5085     RECOMP_FLAGS_IN();
   5086     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   5087     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   5088     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5089     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5090     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   5091     _flag_k = FK_ADD;
   5092     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   5093     eax = eax - 1; /* 0x31009D97: dec eax */
   5094     _flag_k = FK_DEC;
   5095     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   5096     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   5097     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   5098     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   5099     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   5100     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   5101     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   5102     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   5103     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   5104     RECOMP_REGS_OUT();
   5105 }
   5106 
   5107 void sub_31009D7C(void) {
   5108     int _fpu_cmp = 0;
   5109     uint32_t _cf = 0;
   5110     int _df = 1;
   5111     uint32_t _flag_k = FK_NONE;
   5112     uint32_t _flag_a = 0, _flag_b = 0;
   5113     uint32_t _itail_tgt = 0;
   5114     RECOMP_REGS_LOCALS
   5115     RECOMP_ENTER(0x31009D7Cu);
   5116 
   5117 L_31009D7C:
   5118     MEM32(edx + 0x8) = ecx; /* 0x31009D7C: mov dword ptr [edx + 8], ecx */
   5119     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   5120     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   5121     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   5122     PUSH32(esp, edx); /* 0x31009D88: push edx */
   5123     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   5124     RECOMP_FLAGS_IN();
   5125     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   5126     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   5127     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5128     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5129     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   5130     _flag_k = FK_ADD;
   5131     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   5132     eax = eax - 1; /* 0x31009D97: dec eax */
   5133     _flag_k = FK_DEC;
   5134     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   5135     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   5136     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   5137     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   5138     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   5139     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   5140     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   5141     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   5142     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   5143     RECOMP_REGS_OUT();
   5144 }
   5145 
   5146 void sub_31009D7F(void) {
   5147     int _fpu_cmp = 0;
   5148     uint32_t _cf = 0;
   5149     int _df = 1;
   5150     uint32_t _flag_k = FK_NONE;
   5151     uint32_t _flag_a = 0, _flag_b = 0;
   5152     uint32_t _itail_tgt = 0;
   5153     RECOMP_REGS_LOCALS
   5154     RECOMP_ENTER(0x31009D7Fu);
   5155 
   5156 L_31009D7F:
   5157     MEM32(ecx + 0x4) = edx; /* 0x31009D7F: mov dword ptr [ecx + 4], edx */
   5158     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   5159     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   5160     PUSH32(esp, edx); /* 0x31009D88: push edx */
   5161     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   5162     RECOMP_FLAGS_IN();
   5163     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   5164     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   5165     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5166     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5167     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   5168     _flag_k = FK_ADD;
   5169     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   5170     eax = eax - 1; /* 0x31009D97: dec eax */
   5171     _flag_k = FK_DEC;
   5172     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   5173     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   5174     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   5175     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   5176     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   5177     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   5178     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   5179     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   5180     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   5181     RECOMP_REGS_OUT();
   5182 }
   5183 
   5184 void sub_31009D82(void) {
   5185     int _fpu_cmp = 0;
   5186     uint32_t _cf = 0;
   5187     int _df = 1;
   5188     uint32_t _flag_k = FK_NONE;
   5189     uint32_t _flag_a = 0, _flag_b = 0;
   5190     uint32_t _itail_tgt = 0;
   5191     RECOMP_REGS_LOCALS
   5192     RECOMP_ENTER(0x31009D82u);
   5193 
   5194 L_31009D82:
   5195     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x31009D82: mov byte ptr [eax + 0x14], bl */
   5196     edx = MEM32(ebp + (-0x4)); /* 0x31009D85: mov edx, dword ptr [ebp - 4] */
   5197     PUSH32(esp, edx); /* 0x31009D88: push edx */
   5198     RECOMP_ICALL(0x31046858u); /* 0x31009D89: call 0x31046858 */ /* not lifted */
   5199     RECOMP_FLAGS_IN();
   5200     eax = MEM32(edi + 0x10); /* 0x31009D8E: mov eax, dword ptr [edi + 0x10] */
   5201     ecx = MEM32(ebp + 0xC); /* 0x31009D91: mov ecx, dword ptr [ebp + 0xc] */
   5202     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5203     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5204     esp = esp + 4; /* 0x31009D94: add esp, 4 */
   5205     _flag_k = FK_ADD;
   5206     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
   5207     eax = eax - 1; /* 0x31009D97: dec eax */
   5208     _flag_k = FK_DEC;
   5209     MEM32(edi + 0x10) = eax; /* 0x31009D98: mov dword ptr [edi + 0x10], eax */
   5210     eax = MEM32(ebp + 0x8); /* 0x31009D9B: mov eax, dword ptr [ebp + 8] */
   5211     edi = POP32_VAL(esp); /* 0x31009D9E: pop edi */
   5212     esi = POP32_VAL(esp); /* 0x31009D9F: pop esi */
   5213     MEM32(eax) = ecx; /* 0x31009DA0: mov dword ptr [eax], ecx */
   5214     ebx = POP32_VAL(esp); /* 0x31009DA2: pop ebx */
   5215     esp = ebp; /* 0x31009DA3: mov esp, ebp */
   5216     ebp = POP32_VAL(esp); /* 0x31009DA5: pop ebp */
   5217     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009DA6: ret 8 */
   5218     RECOMP_REGS_OUT();
   5219 }
   5220 
   5221 void sub_31009DB0(void) {
   5222     int _fpu_cmp = 0;
   5223     uint32_t _cf = 0;
   5224     int _df = 1;
   5225     uint32_t _flag_k = FK_NONE;
   5226     uint32_t _flag_a = 0, _flag_b = 0;
   5227     uint32_t _itail_tgt = 0;
   5228     RECOMP_REGS_LOCALS
   5229     RECOMP_ENTER(0x31009DB0u);
   5230 
   5231 L_31009DB0:
   5232     PUSH32(esp, ebp); /* 0x31009DB0: push ebp */
   5233     ebp = esp; /* 0x31009DB1: mov ebp, esp */
   5234     PUSH32(esp, ebx); /* 0x31009DB3: push ebx */
   5235     PUSH32(esp, esi); /* 0x31009DB4: push esi */
   5236     ebx = ecx; /* 0x31009DB5: mov ebx, ecx */
   5237     eax = MEM32(ebx + 0x8); /* 0x31009DB7: mov eax, dword ptr [ebx + 8] */
   5238     PUSH32(esp, edi); /* 0x31009DBA: push edi */
   5239     edi = MEM32(ebp + 0x8); /* 0x31009DBB: mov edi, dword ptr [ebp + 8] */
   5240     /* cmp edi, eax */ /* 0x31009DBE: cmp edi, eax */
   5241     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   5242     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5243     _flag_k = FK_CMP;
   5244     esi = edi; /* 0x31009DC0: mov esi, edi */
   5245     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009DE3; /* 0x31009DC2: je 0x31009de3 */
   5246 L_31009DC4:
   5247     eax = MEM32(esi + 0x8); /* 0x31009DC4: mov eax, dword ptr [esi + 8] */
   5248     PUSH32(esp, eax); /* 0x31009DC7: push eax */
   5249     ecx = ebx; /* 0x31009DC8: mov ecx, ebx */
   5250     RECOMP_ICALL(0x31009DB0u); /* 0x31009DCA: call 0x31009db0 */ /* not lifted */
   5251     RECOMP_FLAGS_IN();
   5252     esi = MEM32(esi); /* 0x31009DCF: mov esi, dword ptr [esi] */
   5253     PUSH32(esp, edi); /* 0x31009DD1: push edi */
   5254     RECOMP_ICALL(0x31046858u); /* 0x31009DD2: call 0x31046858 */ /* not lifted */
   5255     RECOMP_FLAGS_IN();
   5256     eax = MEM32(ebx + 0x8); /* 0x31009DD7: mov eax, dword ptr [ebx + 8] */
   5257     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5258     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5259     esp = esp + 4; /* 0x31009DDA: add esp, 4 */
   5260     _flag_k = FK_ADD;
   5261     /* cmp esi, eax */ /* 0x31009DDD: cmp esi, eax */
   5262     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   5263     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5264     _flag_k = FK_CMP;
   5265     edi = esi; /* 0x31009DDF: mov edi, esi */
   5266     RECOMP_BACKEDGE();
   5267     if (CMP_NE(_flag_a, _flag_b)) goto L_31009DC4; /* 0x31009DE1: jne 0x31009dc4 */
   5268 L_31009DE3:
   5269     edi = POP32_VAL(esp); /* 0x31009DE3: pop edi */
   5270     esi = POP32_VAL(esp); /* 0x31009DE4: pop esi */
   5271     ebx = POP32_VAL(esp); /* 0x31009DE5: pop ebx */
   5272     ebp = POP32_VAL(esp); /* 0x31009DE6: pop ebp */
   5273     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x31009DE7: ret 4 */
   5274     RECOMP_REGS_OUT();
   5275 }
   5276 
   5277 void sub_31009DF0(void) {
   5278     int _fpu_cmp = 0;
   5279     uint32_t _cf = 0;
   5280     int _df = 1;
   5281     uint32_t _flag_k = FK_NONE;
   5282     uint32_t _flag_a = 0, _flag_b = 0;
   5283     uint32_t _itail_tgt = 0;
   5284     RECOMP_REGS_LOCALS
   5285     RECOMP_ENTER(0x31009DF0u);
   5286 
   5287 L_31009DF0:
   5288     _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24;
   5289     SET_LO8(eax, 0); /* 0x31009DF0: xor al, al */
   5290     _cf = 0;
   5291     _flag_k = FK_NARROW(FK_TEST, 24);
   5292     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x31009DF2: ret  */
   5293     RECOMP_REGS_OUT();
   5294 }
   5295 
   5296 void sub_31009E00(void) {
   5297     int _fpu_cmp = 0;
   5298     uint32_t _cf = 0;
   5299     int _df = 1;
   5300     uint32_t _flag_k = FK_NONE;
   5301     uint32_t _flag_a = 0, _flag_b = 0;
   5302     uint32_t _itail_tgt = 0;
   5303     RECOMP_REGS_LOCALS
   5304     RECOMP_ENTER(0x31009E00u);
   5305 
   5306 L_31009E00:
   5307     PUSH32(esp, ebp); /* 0x31009E00: push ebp */
   5308     ebp = esp; /* 0x31009E01: mov ebp, esp */
   5309     PUSH32(esp, ecx); /* 0x31009E03: push ecx */
   5310     eax = MEM32(ebp + 0x8); /* 0x31009E04: mov eax, dword ptr [ebp + 8] */
   5311     SET_LO8(edx, MEM8(ebp + 0xB)); /* 0x31009E07: mov dl, byte ptr [ebp + 0xb] */
   5312     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5313     ecx = 0; /* 0x31009E0A: xor ecx, ecx */
   5314     _cf = 0;
   5315     _flag_k = FK_TEST;
   5316     MEM32(ebp + (-0x4)) = ecx; /* 0x31009E0C: mov dword ptr [ebp - 4], ecx */
   5317     MEM8(eax) = (uint8_t)(LO8(edx)); /* 0x31009E0F: mov byte ptr [eax], dl */
   5318     MEM32(eax + 0x4) = ecx; /* 0x31009E11: mov dword ptr [eax + 4], ecx */
   5319     MEM32(eax + 0x8) = ecx; /* 0x31009E14: mov dword ptr [eax + 8], ecx */
   5320     MEM32(eax + 0xC) = ecx; /* 0x31009E17: mov dword ptr [eax + 0xc], ecx */
   5321     esp = ebp; /* 0x31009E1A: mov esp, ebp */
   5322     ebp = POP32_VAL(esp); /* 0x31009E1C: pop ebp */
   5323     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009E1D: ret 8 */
   5324     RECOMP_REGS_OUT();
   5325 }
   5326 
   5327 void sub_31009E20(void) {
   5328     int _fpu_cmp = 0;
   5329     uint32_t _cf = 0;
   5330     int _df = 1;
   5331     uint32_t _flag_k = FK_NONE;
   5332     uint32_t _flag_a = 0, _flag_b = 0;
   5333     uint32_t _itail_tgt = 0;
   5334     RECOMP_REGS_LOCALS
   5335     RECOMP_ENTER(0x31009E20u);
   5336 
   5337 L_31009E20:
   5338     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x31009E20: ret 4 */
   5339     RECOMP_REGS_OUT();
   5340 }
   5341 
   5342 void sub_31009E30(void) {
   5343     int _fpu_cmp = 0;
   5344     uint32_t _cf = 0;
   5345     int _df = 1;
   5346     uint32_t _flag_k = FK_NONE;
   5347     uint32_t _flag_a = 0, _flag_b = 0;
   5348     uint32_t _itail_tgt = 0;
   5349     RECOMP_REGS_LOCALS
   5350     RECOMP_ENTER(0x31009E30u);
   5351 
   5352 L_31009E30:
   5353     PUSH32(esp, ebp); /* 0x31009E30: push ebp */
   5354     ebp = esp; /* 0x31009E31: mov ebp, esp */
   5355     SET_LO8(eax, MEM8(ebp + 0x8)); /* 0x31009E33: mov al, byte ptr [ebp + 8] */
   5356     /* test LO8(eax), LO8(eax) */ /* 0x31009E36: test al, al */
   5357     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   5358     _cf = 0;
   5359     _flag_k = FK_NARROW(FK_TEST, 24);
   5360     if (TEST_Z(_flag_a, _flag_b)) goto L_31009E40; /* 0x31009E38: je 0x31009e40 */
   5361 L_31009E3A:
   5362     _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24;
   5363     SET_LO8(eax, 0); /* 0x31009E3A: xor al, al */
   5364     _cf = 0;
   5365     _flag_k = FK_NARROW(FK_TEST, 24);
   5366     ebp = POP32_VAL(esp); /* 0x31009E3C: pop ebp */
   5367     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x31009E3D: ret 4 */
   5368 L_31009E40:
   5369     edx = MEM32(ecx + 0x240); /* 0x31009E40: mov edx, dword ptr [ecx + 0x240] */
   5370     /* test edx, edx */ /* 0x31009E46: test edx, edx */
   5371     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   5372     _cf = 0;
   5373     _flag_k = FK_TEST;
   5374     eax = 1; /* 0x31009E48: mov eax, 1 */
   5375     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009E55; /* 0x31009E4D: jne 0x31009e55 */
   5376 L_31009E4F:
   5377     MEM32(ecx + 0x240) = eax; /* 0x31009E4F: mov dword ptr [ecx + 0x240], eax */
   5378 L_31009E55:
   5379     PUSH32(esp, esi); /* 0x31009E55: push esi */
   5380     esi = MEM32(ecx + 0x240); /* 0x31009E56: mov esi, dword ptr [ecx + 0x240] */
   5381     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5382     edx = 0; /* 0x31009E5C: xor edx, edx */
   5383     _cf = 0;
   5384     _flag_k = FK_TEST;
   5385     /* cmp esi, eax */ /* 0x31009E5E: cmp esi, eax */
   5386     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   5387     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5388     _flag_k = FK_CMP;
   5389     SET_LO8(edx, (CMP_EQ(_flag_a, _flag_b)) ? 1 : 0); /* 0x31009E60: sete dl */
   5390     SET_LO8(eax, LO8(edx)); /* 0x31009E63: mov al, dl */
   5391     esi = POP32_VAL(esp); /* 0x31009E65: pop esi */
   5392     ebp = POP32_VAL(esp); /* 0x31009E66: pop ebp */
   5393     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x31009E67: ret 4 */
   5394     RECOMP_REGS_OUT();
   5395 }
   5396 
   5397 void sub_31009E70(void) {
   5398     int _fpu_cmp = 0;
   5399     uint32_t _cf = 0;
   5400     int _df = 1;
   5401     uint32_t _flag_k = FK_NONE;
   5402     uint32_t _flag_a = 0, _flag_b = 0;
   5403     uint32_t _itail_tgt = 0;
   5404     RECOMP_REGS_LOCALS
   5405     RECOMP_ENTER(0x31009E70u);
   5406 
   5407 L_31009E70:
   5408     PUSH32(esp, ebp); /* 0x31009E70: push ebp */
   5409     ebp = esp; /* 0x31009E71: mov ebp, esp */
   5410     PUSH32(esp, ecx); /* 0x31009E73: push ecx */
   5411     PUSH32(esp, ebx); /* 0x31009E74: push ebx */
   5412     PUSH32(esp, esi); /* 0x31009E75: push esi */
   5413     PUSH32(esp, edi); /* 0x31009E76: push edi */
   5414     edi = ecx; /* 0x31009E77: mov edi, ecx */
   5415     edx = MEM32(edi + 0x8); /* 0x31009E79: mov edx, dword ptr [edi + 8] */
   5416     esi = MEM32(edi + 0x4); /* 0x31009E7C: mov esi, dword ptr [edi + 4] */
   5417     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5418     ebx = 0; /* 0x31009E7F: xor ebx, ebx */
   5419     _cf = 0;
   5420     _flag_k = FK_TEST;
   5421     /* cmp esi, edx */ /* 0x31009E81: cmp esi, edx */
   5422     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
   5423     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5424     _flag_k = FK_CMP;
   5425     MEM32(ebp + (-0x4)) = edx; /* 0x31009E83: mov dword ptr [ebp - 4], edx */
   5426     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009EBE; /* 0x31009E86: je 0x31009ebe */
   5427 L_31009E88:
   5428     eax = MEM32(esi + 0x4); /* 0x31009E88: mov eax, dword ptr [esi + 4] */
   5429     /* cmp eax, ebx */ /* 0x31009E8B: cmp eax, ebx */
   5430     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
   5431     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5432     _flag_k = FK_CMP;
   5433     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009EAE; /* 0x31009E8D: je 0x31009eae */
   5434 L_31009E8F:
   5435     ecx = eax + (-0x1); /* 0x31009E8F: lea ecx, [eax - 1] */
   5436     SET_LO8(eax, MEM8(ecx)); /* 0x31009E92: mov al, byte ptr [ecx] */
   5437     /* cmp LO8(eax), LO8(ebx) */ /* 0x31009E94: cmp al, bl */
   5438     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   5439     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5440     _flag_k = FK_NARROW(FK_CMP, 24);
   5441     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009EA2; /* 0x31009E96: je 0x31009ea2 */
   5442 L_31009E98:
   5443     /* cmp LO8(eax), 0xFFu */ /* 0x31009E98: cmp al, 0xff */
   5444     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   5445     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5446     _flag_k = FK_NARROW(FK_CMP, 24);
   5447     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009EA2; /* 0x31009E9A: je 0x31009ea2 */
   5448 L_31009E9C:
   5449     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   5450     SET_LO8(eax, LO8(eax) - 1); /* 0x31009E9C: dec al */
   5451     _flag_k = FK_NARROW(FK_DEC, 24);
   5452     MEM8(ecx) = (uint8_t)(LO8(eax)); /* 0x31009E9E: mov byte ptr [ecx], al */
   5453     goto L_31009EAE; /* 0x31009EA0: jmp 0x31009eae */
   5454 L_31009EA2:
   5455     PUSH32(esp, ecx); /* 0x31009EA2: push ecx */
   5456     RECOMP_ICALL(0x31046858u); /* 0x31009EA3: call 0x31046858 */ /* not lifted */
   5457     RECOMP_FLAGS_IN();
   5458     edx = MEM32(ebp + (-0x4)); /* 0x31009EA8: mov edx, dword ptr [ebp - 4] */
   5459     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5460     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5461     esp = esp + 4; /* 0x31009EAB: add esp, 4 */
   5462     _flag_k = FK_ADD;
   5463 L_31009EAE:
   5464     MEM32(esi + 0x4) = ebx; /* 0x31009EAE: mov dword ptr [esi + 4], ebx */
   5465     MEM32(esi + 0x8) = ebx; /* 0x31009EB1: mov dword ptr [esi + 8], ebx */
   5466     MEM32(esi + 0xC) = ebx; /* 0x31009EB4: mov dword ptr [esi + 0xc], ebx */
   5467     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0x10u);
   5468     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5469     esi = esi + 0x10u; /* 0x31009EB7: add esi, 0x10 */
   5470     _flag_k = FK_ADD;
   5471     /* cmp esi, edx */ /* 0x31009EBA: cmp esi, edx */
   5472     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
   5473     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5474     _flag_k = FK_CMP;
   5475     RECOMP_BACKEDGE();
   5476     if (CMP_NE(_flag_a, _flag_b)) goto L_31009E88; /* 0x31009EBC: jne 0x31009e88 */
   5477 L_31009EBE:
   5478     eax = MEM32(edi + 0x4); /* 0x31009EBE: mov eax, dword ptr [edi + 4] */
   5479     PUSH32(esp, eax); /* 0x31009EC1: push eax */
   5480     RECOMP_ICALL(0x31046858u); /* 0x31009EC2: call 0x31046858 */ /* not lifted */
   5481     RECOMP_FLAGS_IN();
   5482     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5483     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5484     esp = esp + 4; /* 0x31009EC7: add esp, 4 */
   5485     _flag_k = FK_ADD;
   5486     MEM32(edi + 0x4) = ebx; /* 0x31009ECA: mov dword ptr [edi + 4], ebx */
   5487     MEM32(edi + 0x8) = ebx; /* 0x31009ECD: mov dword ptr [edi + 8], ebx */
   5488     MEM32(edi + 0xC) = ebx; /* 0x31009ED0: mov dword ptr [edi + 0xc], ebx */
   5489     edi = POP32_VAL(esp); /* 0x31009ED3: pop edi */
   5490     esi = POP32_VAL(esp); /* 0x31009ED4: pop esi */
   5491     ebx = POP32_VAL(esp); /* 0x31009ED5: pop ebx */
   5492     esp = ebp; /* 0x31009ED6: mov esp, ebp */
   5493     ebp = POP32_VAL(esp); /* 0x31009ED8: pop ebp */
   5494     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x31009ED9: ret  */
   5495     RECOMP_REGS_OUT();
   5496 }
   5497 
   5498 void sub_31009E88(void) {
   5499     int _fpu_cmp = 0;
   5500     uint32_t _cf = 0;
   5501     int _df = 1;
   5502     uint32_t _flag_k = FK_NONE;
   5503     uint32_t _flag_a = 0, _flag_b = 0;
   5504     uint32_t _itail_tgt = 0;
   5505     RECOMP_REGS_LOCALS
   5506     RECOMP_ENTER(0x31009E88u);
   5507 
   5508 L_31009E88:
   5509     eax = MEM32(esi + 0x4); /* 0x31009E88: mov eax, dword ptr [esi + 4] */
   5510     /* cmp eax, ebx */ /* 0x31009E8B: cmp eax, ebx */
   5511     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
   5512     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5513     _flag_k = FK_CMP;
   5514     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009EAE; /* 0x31009E8D: je 0x31009eae */
   5515 L_31009E8F:
   5516     ecx = eax + (-0x1); /* 0x31009E8F: lea ecx, [eax - 1] */
   5517     SET_LO8(eax, MEM8(ecx)); /* 0x31009E92: mov al, byte ptr [ecx] */
   5518     /* cmp LO8(eax), LO8(ebx) */ /* 0x31009E94: cmp al, bl */
   5519     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   5520     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5521     _flag_k = FK_NARROW(FK_CMP, 24);
   5522     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009EA2; /* 0x31009E96: je 0x31009ea2 */
   5523 L_31009E98:
   5524     /* cmp LO8(eax), 0xFFu */ /* 0x31009E98: cmp al, 0xff */
   5525     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   5526     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5527     _flag_k = FK_NARROW(FK_CMP, 24);
   5528     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009EA2; /* 0x31009E9A: je 0x31009ea2 */
   5529 L_31009E9C:
   5530     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   5531     SET_LO8(eax, LO8(eax) - 1); /* 0x31009E9C: dec al */
   5532     _flag_k = FK_NARROW(FK_DEC, 24);
   5533     MEM8(ecx) = (uint8_t)(LO8(eax)); /* 0x31009E9E: mov byte ptr [ecx], al */
   5534     goto L_31009EAE; /* 0x31009EA0: jmp 0x31009eae */
   5535 L_31009EA2:
   5536     PUSH32(esp, ecx); /* 0x31009EA2: push ecx */
   5537     RECOMP_ICALL(0x31046858u); /* 0x31009EA3: call 0x31046858 */ /* not lifted */
   5538     RECOMP_FLAGS_IN();
   5539     edx = MEM32(ebp + (-0x4)); /* 0x31009EA8: mov edx, dword ptr [ebp - 4] */
   5540     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5541     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5542     esp = esp + 4; /* 0x31009EAB: add esp, 4 */
   5543     _flag_k = FK_ADD;
   5544 L_31009EAE:
   5545     MEM32(esi + 0x4) = ebx; /* 0x31009EAE: mov dword ptr [esi + 4], ebx */
   5546     MEM32(esi + 0x8) = ebx; /* 0x31009EB1: mov dword ptr [esi + 8], ebx */
   5547     MEM32(esi + 0xC) = ebx; /* 0x31009EB4: mov dword ptr [esi + 0xc], ebx */
   5548     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0x10u);
   5549     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5550     esi = esi + 0x10u; /* 0x31009EB7: add esi, 0x10 */
   5551     _flag_k = FK_ADD;
   5552     /* cmp esi, edx */ /* 0x31009EBA: cmp esi, edx */
   5553     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
   5554     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5555     _flag_k = FK_CMP;
   5556     RECOMP_BACKEDGE();
   5557     if (CMP_NE(_flag_a, _flag_b)) goto L_31009E88; /* 0x31009EBC: jne 0x31009e88 */
   5558 L_31009EBE:
   5559     eax = MEM32(edi + 0x4); /* 0x31009EBE: mov eax, dword ptr [edi + 4] */
   5560     PUSH32(esp, eax); /* 0x31009EC1: push eax */
   5561     RECOMP_ICALL(0x31046858u); /* 0x31009EC2: call 0x31046858 */ /* not lifted */
   5562     RECOMP_FLAGS_IN();
   5563     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5564     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5565     esp = esp + 4; /* 0x31009EC7: add esp, 4 */
   5566     _flag_k = FK_ADD;
   5567     MEM32(edi + 0x4) = ebx; /* 0x31009ECA: mov dword ptr [edi + 4], ebx */
   5568     MEM32(edi + 0x8) = ebx; /* 0x31009ECD: mov dword ptr [edi + 8], ebx */
   5569     MEM32(edi + 0xC) = ebx; /* 0x31009ED0: mov dword ptr [edi + 0xc], ebx */
   5570     edi = POP32_VAL(esp); /* 0x31009ED3: pop edi */
   5571     esi = POP32_VAL(esp); /* 0x31009ED4: pop esi */
   5572     ebx = POP32_VAL(esp); /* 0x31009ED5: pop ebx */
   5573     esp = ebp; /* 0x31009ED6: mov esp, ebp */
   5574     ebp = POP32_VAL(esp); /* 0x31009ED8: pop ebp */
   5575     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x31009ED9: ret  */
   5576     RECOMP_REGS_OUT();
   5577 }
   5578 
   5579 void sub_31009EAE(void) {
   5580     int _fpu_cmp = 0;
   5581     uint32_t _cf = 0;
   5582     int _df = 1;
   5583     uint32_t _flag_k = FK_NONE;
   5584     uint32_t _flag_a = 0, _flag_b = 0;
   5585     uint32_t _itail_tgt = 0;
   5586     RECOMP_REGS_LOCALS
   5587     RECOMP_ENTER(0x31009EAEu);
   5588 
   5589     goto L_31009EAE;
   5590 L_31009E88:
   5591     eax = MEM32(esi + 0x4); /* 0x31009E88: mov eax, dword ptr [esi + 4] */
   5592     /* cmp eax, ebx */ /* 0x31009E8B: cmp eax, ebx */
   5593     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
   5594     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5595     _flag_k = FK_CMP;
   5596     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009EAE; /* 0x31009E8D: je 0x31009eae */
   5597 L_31009E8F:
   5598     ecx = eax + (-0x1); /* 0x31009E8F: lea ecx, [eax - 1] */
   5599     SET_LO8(eax, MEM8(ecx)); /* 0x31009E92: mov al, byte ptr [ecx] */
   5600     /* cmp LO8(eax), LO8(ebx) */ /* 0x31009E94: cmp al, bl */
   5601     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
   5602     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5603     _flag_k = FK_NARROW(FK_CMP, 24);
   5604     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009EA2; /* 0x31009E96: je 0x31009ea2 */
   5605 L_31009E98:
   5606     /* cmp LO8(eax), 0xFFu */ /* 0x31009E98: cmp al, 0xff */
   5607     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   5608     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5609     _flag_k = FK_NARROW(FK_CMP, 24);
   5610     if (CMP_EQ(_flag_a, _flag_b)) goto L_31009EA2; /* 0x31009E9A: je 0x31009ea2 */
   5611 L_31009E9C:
   5612     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   5613     SET_LO8(eax, LO8(eax) - 1); /* 0x31009E9C: dec al */
   5614     _flag_k = FK_NARROW(FK_DEC, 24);
   5615     MEM8(ecx) = (uint8_t)(LO8(eax)); /* 0x31009E9E: mov byte ptr [ecx], al */
   5616     goto L_31009EAE; /* 0x31009EA0: jmp 0x31009eae */
   5617 L_31009EA2:
   5618     PUSH32(esp, ecx); /* 0x31009EA2: push ecx */
   5619     RECOMP_ICALL(0x31046858u); /* 0x31009EA3: call 0x31046858 */ /* not lifted */
   5620     RECOMP_FLAGS_IN();
   5621     edx = MEM32(ebp + (-0x4)); /* 0x31009EA8: mov edx, dword ptr [ebp - 4] */
   5622     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5623     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5624     esp = esp + 4; /* 0x31009EAB: add esp, 4 */
   5625     _flag_k = FK_ADD;
   5626 L_31009EAE:
   5627     MEM32(esi + 0x4) = ebx; /* 0x31009EAE: mov dword ptr [esi + 4], ebx */
   5628     MEM32(esi + 0x8) = ebx; /* 0x31009EB1: mov dword ptr [esi + 8], ebx */
   5629     MEM32(esi + 0xC) = ebx; /* 0x31009EB4: mov dword ptr [esi + 0xc], ebx */
   5630     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(0x10u);
   5631     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5632     esi = esi + 0x10u; /* 0x31009EB7: add esi, 0x10 */
   5633     _flag_k = FK_ADD;
   5634     /* cmp esi, edx */ /* 0x31009EBA: cmp esi, edx */
   5635     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edx);
   5636     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5637     _flag_k = FK_CMP;
   5638     RECOMP_BACKEDGE();
   5639     if (CMP_NE(_flag_a, _flag_b)) goto L_31009E88; /* 0x31009EBC: jne 0x31009e88 */
   5640 L_31009EBE:
   5641     eax = MEM32(edi + 0x4); /* 0x31009EBE: mov eax, dword ptr [edi + 4] */
   5642     PUSH32(esp, eax); /* 0x31009EC1: push eax */
   5643     RECOMP_ICALL(0x31046858u); /* 0x31009EC2: call 0x31046858 */ /* not lifted */
   5644     RECOMP_FLAGS_IN();
   5645     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5646     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5647     esp = esp + 4; /* 0x31009EC7: add esp, 4 */
   5648     _flag_k = FK_ADD;
   5649     MEM32(edi + 0x4) = ebx; /* 0x31009ECA: mov dword ptr [edi + 4], ebx */
   5650     MEM32(edi + 0x8) = ebx; /* 0x31009ECD: mov dword ptr [edi + 8], ebx */
   5651     MEM32(edi + 0xC) = ebx; /* 0x31009ED0: mov dword ptr [edi + 0xc], ebx */
   5652     edi = POP32_VAL(esp); /* 0x31009ED3: pop edi */
   5653     esi = POP32_VAL(esp); /* 0x31009ED4: pop esi */
   5654     ebx = POP32_VAL(esp); /* 0x31009ED5: pop ebx */
   5655     esp = ebp; /* 0x31009ED6: mov esp, ebp */
   5656     ebp = POP32_VAL(esp); /* 0x31009ED8: pop ebp */
   5657     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x31009ED9: ret  */
   5658     RECOMP_REGS_OUT();
   5659 }
   5660 
   5661 void sub_31009EE0(void) {
   5662     int _fpu_cmp = 0;
   5663     uint32_t _cf = 0;
   5664     int _df = 1;
   5665     uint32_t _flag_k = FK_NONE;
   5666     uint32_t _flag_a = 0, _flag_b = 0;
   5667     uint32_t _itail_tgt = 0;
   5668     RECOMP_REGS_LOCALS
   5669     RECOMP_ENTER(0x31009EE0u);
   5670 
   5671 L_31009EE0:
   5672     PUSH32(esp, ebp); /* 0x31009EE0: push ebp */
   5673     ebp = esp; /* 0x31009EE1: mov ebp, esp */
   5674     PUSH32(esp, ecx); /* 0x31009EE3: push ecx */
   5675     PUSH32(esp, esi); /* 0x31009EE4: push esi */
   5676     esi = MEM32(ebp + 0x8); /* 0x31009EE5: mov esi, dword ptr [ebp + 8] */
   5677     PUSH32(esp, 0); /* 0x31009EE8: push 0 */
   5678     ecx = esi; /* 0x31009EEA: mov ecx, esi */
   5679     MEM32(ebp + (-0x4)) = 0; /* 0x31009EEC: mov dword ptr [ebp - 4], 0 */
   5680     RECOMP_ICALL(0x31004520u); /* 0x31009EF3: call 0x31004520 */ /* not lifted */
   5681     RECOMP_FLAGS_IN();
   5682     eax = esi; /* 0x31009EF8: mov eax, esi */
   5683     esi = POP32_VAL(esp); /* 0x31009EFA: pop esi */
   5684     esp = ebp; /* 0x31009EFB: mov esp, ebp */
   5685     ebp = POP32_VAL(esp); /* 0x31009EFD: pop ebp */
   5686     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x31009EFE: ret 8 */
   5687     RECOMP_REGS_OUT();
   5688 }
   5689 
   5690 void sub_31009F10(void) {
   5691     int _fpu_cmp = 0;
   5692     uint32_t _cf = 0;
   5693     int _df = 1;
   5694     uint32_t _flag_k = FK_NONE;
   5695     uint32_t _flag_a = 0, _flag_b = 0;
   5696     uint32_t _itail_tgt = 0;
   5697     RECOMP_REGS_LOCALS
   5698     RECOMP_ENTER(0x31009F10u);
   5699 
   5700 L_31009F10:
   5701     RECOMP_ICALL(0x31009F20u); /* 0x31009F10: call 0x31009f20 */ /* not lifted */
   5702     RECOMP_FLAGS_IN();
   5703     goto L_31009F50; /* 0x31009F15: jmp 0x31009f50 */
   5704 L_31009F50:
   5705     PUSH32(esp, 0x31009F60u); /* 0x31009F50: push 0x31009f60 */
   5706     RECOMP_ICALL(0x310468C8u); /* 0x31009F55: call 0x310468c8 */ /* not lifted */
   5707     RECOMP_FLAGS_IN();
   5708     ecx = POP32_VAL(esp); /* 0x31009F5A: pop ecx */
   5709     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x31009F5B: ret  */
   5710     RECOMP_REGS_OUT();
   5711 }
   5712 
   5713 void sub_31009F20(void) {
   5714     int _fpu_cmp = 0;
   5715     uint32_t _cf = 0;
   5716     int _df = 1;
   5717     uint32_t _flag_k = FK_NONE;
   5718     uint32_t _flag_a = 0, _flag_b = 0;
   5719     uint32_t _itail_tgt = 0;
   5720     RECOMP_REGS_LOCALS
   5721     RECOMP_ENTER(0x31009F20u);
   5722 
   5723 L_31009F20:
   5724     PUSH32(esp, ebp); /* 0x31009F20: push ebp */
   5725     ebp = esp; /* 0x31009F21: mov ebp, esp */
   5726     PUSH32(esp, ecx); /* 0x31009F23: push ecx */
   5727     SET_LO8(eax, MEM8(ebp + (-0x1))); /* 0x31009F24: mov al, byte ptr [ebp - 1] */
   5728     MEM8(0x31057E48) = (uint8_t)(LO8(eax)); /* 0x31009F27: mov byte ptr [0x31057e48], al */
   5729     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5730     eax = 0; /* 0x31009F2C: xor eax, eax */
   5731     _cf = 0;
   5732     _flag_k = FK_TEST;
   5733     MEM32(0x31057E4C) = eax; /* 0x31009F2E: mov dword ptr [0x31057e4c], eax */
   5734     MEM32(0x31057E50) = eax; /* 0x31009F33: mov dword ptr [0x31057e50], eax */
   5735     MEM32(0x31057E54) = eax; /* 0x31009F38: mov dword ptr [0x31057e54], eax */
   5736     esp = ebp; /* 0x31009F3D: mov esp, ebp */
   5737     ebp = POP32_VAL(esp); /* 0x31009F3F: pop ebp */
   5738     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x31009F40: ret  */
   5739     RECOMP_REGS_OUT();
   5740 }
   5741 
   5742 void sub_31009F50(void) {
   5743     int _fpu_cmp = 0;
   5744     uint32_t _cf = 0;
   5745     int _df = 1;
   5746     uint32_t _flag_k = FK_NONE;
   5747     uint32_t _flag_a = 0, _flag_b = 0;
   5748     uint32_t _itail_tgt = 0;
   5749     RECOMP_REGS_LOCALS
   5750     RECOMP_ENTER(0x31009F50u);
   5751 
   5752 L_31009F50:
   5753     PUSH32(esp, 0x31009F60u); /* 0x31009F50: push 0x31009f60 */
   5754     RECOMP_ICALL(0x310468C8u); /* 0x31009F55: call 0x310468c8 */ /* not lifted */
   5755     RECOMP_FLAGS_IN();
   5756     ecx = POP32_VAL(esp); /* 0x31009F5A: pop ecx */
   5757     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x31009F5B: ret  */
   5758     RECOMP_REGS_OUT();
   5759 }
   5760 
   5761 void sub_31009F60(void) {
   5762     int _fpu_cmp = 0;
   5763     uint32_t _cf = 0;
   5764     int _df = 1;
   5765     uint32_t _flag_k = FK_NONE;
   5766     uint32_t _flag_a = 0, _flag_b = 0;
   5767     uint32_t _itail_tgt = 0;
   5768     RECOMP_REGS_LOCALS
   5769     RECOMP_ENTER(0x31009F60u);
   5770 
   5771 L_31009F60:
   5772     PUSH32(esp, ebp); /* 0x31009F60: push ebp */
   5773     ebp = esp; /* 0x31009F61: mov ebp, esp */
   5774     PUSH32(esp, ecx); /* 0x31009F63: push ecx */
   5775     SET_LO8(ecx, MEM8(0x31057E58)); /* 0x31009F64: mov cl, byte ptr [0x31057e58] */
   5776     SET_LO8(eax, 1); /* 0x31009F6A: mov al, 1 */
   5777     /* test LO8(eax), LO8(ecx) */ /* 0x31009F6C: test al, cl */
   5778     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24;
   5779     _cf = 0;
   5780     _flag_k = FK_NARROW(FK_TEST, 24);
   5781     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009F9C; /* 0x31009F6E: jne 0x31009f9c */
   5782 L_31009F70:
   5783     SET_LO8(edx, LO8(ecx)); /* 0x31009F70: mov dl, cl */
   5784     _flag_a = (uint32_t)((LO8(edx) | LO8(eax))) << 24; _flag_b = (uint32_t)((LO8(edx) | LO8(eax))) << 24;
   5785     SET_LO8(edx, LO8(edx) | LO8(eax)); /* 0x31009F72: or dl, al */
   5786     _cf = 0;
   5787     _flag_k = FK_NARROW(FK_TEST, 24);
   5788     eax = MEM32(0x31057E4C); /* 0x31009F74: mov eax, dword ptr [0x31057e4c] */
   5789     PUSH32(esp, eax); /* 0x31009F79: push eax */
   5790     MEM8(0x31057E58) = (uint8_t)(LO8(edx)); /* 0x31009F7A: mov byte ptr [0x31057e58], dl */
   5791     MEM32(ebp + (-0x4)) = eax; /* 0x31009F80: mov dword ptr [ebp - 4], eax */
   5792     RECOMP_ICALL(0x31046858u); /* 0x31009F83: call 0x31046858 */ /* not lifted */
   5793     RECOMP_FLAGS_IN();
   5794     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5795     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5796     esp = esp + 4; /* 0x31009F88: add esp, 4 */
   5797     _flag_k = FK_ADD;
   5798     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5799     eax = 0; /* 0x31009F8B: xor eax, eax */
   5800     _cf = 0;
   5801     _flag_k = FK_TEST;
   5802     MEM32(0x31057E4C) = eax; /* 0x31009F8D: mov dword ptr [0x31057e4c], eax */
   5803     MEM32(0x31057E50) = eax; /* 0x31009F92: mov dword ptr [0x31057e50], eax */
   5804     MEM32(0x31057E54) = eax; /* 0x31009F97: mov dword ptr [0x31057e54], eax */
   5805 L_31009F9C:
   5806     esp = ebp; /* 0x31009F9C: mov esp, ebp */
   5807     ebp = POP32_VAL(esp); /* 0x31009F9E: pop ebp */
   5808     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x31009F9F: ret  */
   5809     RECOMP_REGS_OUT();
   5810 }
   5811 
   5812 void sub_31009FA0(void) {
   5813     int _fpu_cmp = 0;
   5814     uint32_t _cf = 0;
   5815     int _df = 1;
   5816     uint32_t _flag_k = FK_NONE;
   5817     uint32_t _flag_a = 0, _flag_b = 0;
   5818     uint32_t _itail_tgt = 0;
   5819     RECOMP_REGS_LOCALS
   5820     RECOMP_ENTER(0x31009FA0u);
   5821 
   5822 L_31009FA0:
   5823     PUSH32(esp, ebp); /* 0x31009FA0: push ebp */
   5824     ebp = esp; /* 0x31009FA1: mov ebp, esp */
   5825     PUSH32(esp, ebx); /* 0x31009FA3: push ebx */
   5826     PUSH32(esp, esi); /* 0x31009FA4: push esi */
   5827     PUSH32(esp, edi); /* 0x31009FA5: push edi */
   5828     RECOMP_ICALL(0x310099D0u); /* 0x31009FA6: call 0x310099d0 */ /* not lifted */
   5829     RECOMP_FLAGS_IN();
   5830     ebx = MEM32(ebp + 0x8); /* 0x31009FAB: mov ebx, dword ptr [ebp + 8] */
   5831     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   5832     esi = 0; /* 0x31009FAE: xor esi, esi */
   5833     _cf = 0;
   5834     _flag_k = FK_TEST;
   5835 L_31009FB0:
   5836     ecx = MEM32(0x31057E4C); /* 0x31009FB0: mov ecx, dword ptr [0x31057e4c] */
   5837     /* test ecx, ecx */ /* 0x31009FB6: test ecx, ecx */
   5838     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   5839     _cf = 0;
   5840     _flag_k = FK_TEST;
   5841     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A01B; /* 0x31009FB8: je 0x3100a01b */
   5842 L_31009FBA:
   5843     eax = MEM32(0x31057E50); /* 0x31009FBA: mov eax, dword ptr [0x31057e50] */
   5844     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   5845     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5846     eax = eax - ecx; /* 0x31009FBF: sub eax, ecx */
   5847     _flag_k = FK_CMP;
   5848     if (2u) _cf = (((eax) >> 1) & 1u); /* 0x31009FC1: sar eax, 2 */
   5849     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   5850     eax = (uint32_t)((int32_t)eax >> 2u);
   5851     /* cmp esi, eax */ /* 0x31009FC4: cmp esi, eax */
   5852     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   5853     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5854     _flag_k = FK_CMP;
   5855     if (CMP_AE(_flag_a, _flag_b)) goto L_3100A01B; /* 0x31009FC6: jae 0x3100a01b */
   5856 L_31009FC8:
   5857     eax = MEM32(ebx + 0x4); /* 0x31009FC8: mov eax, dword ptr [ebx + 4] */
   5858     /* test eax, eax */ /* 0x31009FCB: test eax, eax */
   5859     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   5860     _cf = 0;
   5861     _flag_k = FK_TEST;
   5862     edi = MEM32(0x310480EC); /* 0x31009FCD: mov edi, dword ptr [0x310480ec] */
   5863     edx = edi; /* 0x31009FD3: mov edx, edi */
   5864     if (TEST_Z(_flag_a, _flag_b)) goto L_31009FD9; /* 0x31009FD5: je 0x31009fd9 */
   5865 L_31009FD7:
   5866     edx = eax; /* 0x31009FD7: mov edx, eax */
   5867 L_31009FD9:
   5868     eax = MEM32(ecx + esi * 4); /* 0x31009FD9: mov eax, dword ptr [ecx + esi*4] */
   5869     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   5870     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5871     eax = eax + 4; /* 0x31009FDC: add eax, 4 */
   5872     _flag_k = FK_ADD;
   5873     eax = MEM32(eax + 0x4); /* 0x31009FDF: mov eax, dword ptr [eax + 4] */
   5874     /* test eax, eax */ /* 0x31009FE2: test eax, eax */
   5875     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   5876     _cf = 0;
   5877     _flag_k = FK_TEST;
   5878     if (TEST_NZ(_flag_a, _flag_b)) goto L_31009FE8; /* 0x31009FE4: jne 0x31009fe8 */
   5879 L_31009FE6:
   5880     eax = edi; /* 0x31009FE6: mov eax, edi */
   5881 L_31009FE8:
   5882     PUSH32(esp, edx); /* 0x31009FE8: push edx */
   5883     PUSH32(esp, eax); /* 0x31009FE9: push eax */
   5884     RECOMP_ICALL(MEM32(0x3104817C)); /* 0x31009FEA: call dword ptr [0x3104817c] */
   5885     RECOMP_FLAGS_IN();
   5886     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   5887     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5888     esp = esp + 8; /* 0x31009FF0: add esp, 8 */
   5889     _flag_k = FK_ADD;
   5890     /* test eax, eax */ /* 0x31009FF3: 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_31009FFA; /* 0x31009FF5: je 0x31009ffa */
   5895 L_31009FF7:
   5896     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1);
   5897     esi = esi + 1; /* 0x31009FF7: inc esi */
   5898     _flag_k = FK_INC;
   5899     RECOMP_BACKEDGE();
   5900     goto L_31009FB0; /* 0x31009FF8: jmp 0x31009fb0 */
   5901 L_31009FFA:
   5902     ecx = MEM32(0x31057E4C); /* 0x31009FFA: mov ecx, dword ptr [0x31057e4c] */
   5903     ecx = MEM32(ecx + esi * 4); /* 0x3100A000: mov ecx, dword ptr [ecx + esi*4] */
   5904     RECOMP_ICALL(0x31008F90u); /* 0x3100A003: call 0x31008f90 */ /* not lifted */
   5905     RECOMP_FLAGS_IN();
   5906     RECOMP_ICALL(0x310099E0u); /* 0x3100A008: call 0x310099e0 */ /* not lifted */
   5907     RECOMP_FLAGS_IN();
   5908     edx = MEM32(0x31057E4C); /* 0x3100A00D: mov edx, dword ptr [0x31057e4c] */
   5909     eax = MEM32(edx + esi * 4); /* 0x3100A013: mov eax, dword ptr [edx + esi*4] */
   5910     edi = POP32_VAL(esp); /* 0x3100A016: pop edi */
   5911     esi = POP32_VAL(esp); /* 0x3100A017: pop esi */
   5912     ebx = POP32_VAL(esp); /* 0x3100A018: pop ebx */
   5913     ebp = POP32_VAL(esp); /* 0x3100A019: pop ebp */
   5914     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A01A: ret  */
   5915 L_3100A01B:
   5916     edi = MEM32(ebp + 0xC); /* 0x3100A01B: mov edi, dword ptr [ebp + 0xc] */
   5917     PUSH32(esp, edi); /* 0x3100A01E: push edi */
   5918     PUSH32(esp, ebx); /* 0x3100A01F: push ebx */
   5919     RECOMP_ICALL(0x3100EF30u); /* 0x3100A020: call 0x3100ef30 */ /* not lifted */
   5920     RECOMP_FLAGS_IN();
   5921     esi = eax; /* 0x3100A025: mov esi, eax */
   5922     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   5923     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5924     esp = esp + 8; /* 0x3100A027: add esp, 8 */
   5925     _flag_k = FK_ADD;
   5926     /* test esi, esi */ /* 0x3100A02A: test esi, esi */
   5927     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi);
   5928     _cf = 0;
   5929     _flag_k = FK_TEST;
   5930     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100A049; /* 0x3100A02C: jne 0x3100a049 */
   5931 L_3100A02E:
   5932     PUSH32(esp, edi); /* 0x3100A02E: push edi */
   5933     PUSH32(esp, ebx); /* 0x3100A02F: push ebx */
   5934     RECOMP_ICALL(0x3100A3F0u); /* 0x3100A030: call 0x3100a3f0 */ /* not lifted */
   5935     RECOMP_FLAGS_IN();
   5936     esi = eax; /* 0x3100A035: mov esi, eax */
   5937     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   5938     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5939     esp = esp + 8; /* 0x3100A037: add esp, 8 */
   5940     _flag_k = FK_ADD;
   5941     /* test esi, esi */ /* 0x3100A03A: test esi, esi */
   5942     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi);
   5943     _cf = 0;
   5944     _flag_k = FK_TEST;
   5945     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100A049; /* 0x3100A03C: jne 0x3100a049 */
   5946 L_3100A03E:
   5947     PUSH32(esp, ebx); /* 0x3100A03E: push ebx */
   5948     RECOMP_ICALL(0x3100AD60u); /* 0x3100A03F: call 0x3100ad60 */ /* not lifted */
   5949     RECOMP_FLAGS_IN();
   5950     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   5951     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   5952     esp = esp + 4; /* 0x3100A044: add esp, 4 */
   5953     _flag_k = FK_ADD;
   5954     esi = eax; /* 0x3100A047: mov esi, eax */
   5955 L_3100A049:
   5956     RECOMP_ICALL(0x310099E0u); /* 0x3100A049: call 0x310099e0 */ /* not lifted */
   5957     RECOMP_FLAGS_IN();
   5958     edi = POP32_VAL(esp); /* 0x3100A04E: pop edi */
   5959     eax = esi; /* 0x3100A04F: mov eax, esi */
   5960     esi = POP32_VAL(esp); /* 0x3100A051: pop esi */
   5961     ebx = POP32_VAL(esp); /* 0x3100A052: pop ebx */
   5962     ebp = POP32_VAL(esp); /* 0x3100A053: pop ebp */
   5963     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A054: ret  */
   5964     RECOMP_REGS_OUT();
   5965 }
   5966 
   5967 void sub_3100A060(void) {
   5968     int _fpu_cmp = 0;
   5969     uint32_t _cf = 0;
   5970     int _df = 1;
   5971     uint32_t _flag_k = FK_NONE;
   5972     uint32_t _flag_a = 0, _flag_b = 0;
   5973     uint32_t _itail_tgt = 0;
   5974     RECOMP_REGS_LOCALS
   5975     RECOMP_ENTER(0x3100A060u);
   5976 
   5977 L_3100A060:
   5978     PUSH32(esp, ebp); /* 0x3100A060: push ebp */
   5979     ebp = esp; /* 0x3100A061: mov ebp, esp */
   5980     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100A063: push -1 */
   5981     PUSH32(esp, 0x31047358u); /* 0x3100A065: push 0x31047358 */
   5982     eax = MEM32(FS_BASE + (0)); /* 0x3100A06A: mov eax, dword ptr fs:[0] */
   5983     PUSH32(esp, eax); /* 0x3100A070: push eax */
   5984     MEM32(FS_BASE + (0)) = esp; /* 0x3100A071: mov dword ptr fs:[0], esp */
   5985     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   5986     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   5987     esp = esp - 0xCu; /* 0x3100A078: sub esp, 0xc */
   5988     _flag_k = FK_CMP;
   5989     eax = MEM32(ebp + 0x8); /* 0x3100A07B: mov eax, dword ptr [ebp + 8] */
   5990     PUSH32(esp, esi); /* 0x3100A07E: push esi */
   5991     PUSH32(esp, edi); /* 0x3100A07F: push edi */
   5992     edi = ecx; /* 0x3100A080: mov edi, ecx */
   5993     PUSH32(esp, eax); /* 0x3100A082: push eax */
   5994     MEM32(ebp + (-0x18)) = edi; /* 0x3100A083: mov dword ptr [ebp - 0x18], edi */
   5995     RECOMP_ICALL(0x31008C90u); /* 0x3100A086: call 0x31008c90 */ /* not lifted */
   5996     RECOMP_FLAGS_IN();
   5997     MEM32(edi) = 0x31048600u; /* 0x3100A08B: mov dword ptr [edi], 0x31048600 */
   5998     eax = MEM32(0x31057E50); /* 0x3100A091: mov eax, dword ptr [0x31057e50] */
   5999     ecx = MEM32(0x31057E54); /* 0x3100A096: mov ecx, dword ptr [0x31057e54] */
   6000     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
   6001     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6002     ecx = ecx - eax; /* 0x3100A09C: sub ecx, eax */
   6003     _flag_k = FK_CMP;
   6004     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100A09E: sar ecx, 2 */
   6005     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6006     ecx = (uint32_t)((int32_t)ecx >> 2u);
   6007     /* cmp ecx, 1 */ /* 0x3100A0A1: cmp ecx, 1 */
   6008     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   6009     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6010     _flag_k = FK_CMP;
   6011     MEM32(ebp + (-0x4)) = 0; /* 0x3100A0A4: mov dword ptr [ebp - 4], 0 */
   6012     MEM32(ebp + 0x8) = edi; /* 0x3100A0AB: mov dword ptr [ebp + 8], edi */
   6013     esi = eax; /* 0x3100A0AE: mov esi, eax */
   6014     if (CMP_AE(_flag_a, _flag_b)) goto L_3100A1BF; /* 0x3100A0B0: jae 0x3100a1bf */
   6015 L_3100A0B6:
   6016     edx = MEM32(0x31057E4C); /* 0x3100A0B6: mov edx, dword ptr [0x31057e4c] */
   6017     /* test edx, edx */ /* 0x3100A0BC: test edx, edx */
   6018     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   6019     _cf = 0;
   6020     _flag_k = FK_TEST;
   6021     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A0D5; /* 0x3100A0BE: je 0x3100a0d5 */
   6022 L_3100A0C0:
   6023     ecx = eax; /* 0x3100A0C0: mov ecx, eax */
   6024     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   6025     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6026     ecx = ecx - edx; /* 0x3100A0C2: sub ecx, edx */
   6027     _flag_k = FK_CMP;
   6028     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100A0C4: sar ecx, 2 */
   6029     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6030     ecx = (uint32_t)((int32_t)ecx >> 2u);
   6031     /* cmp ecx, 1 */ /* 0x3100A0C7: cmp ecx, 1 */
   6032     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   6033     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6034     _flag_k = FK_CMP;
   6035     if (CMP_BE(_flag_a, _flag_b)) goto L_3100A0D5; /* 0x3100A0CA: jbe 0x3100a0d5 */
   6036 L_3100A0CC:
   6037     ecx = eax; /* 0x3100A0CC: mov ecx, eax */
   6038     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   6039     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6040     ecx = ecx - edx; /* 0x3100A0CE: sub ecx, edx */
   6041     _flag_k = FK_CMP;
   6042     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100A0D0: sar ecx, 2 */
   6043     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6044     ecx = (uint32_t)((int32_t)ecx >> 2u);
   6045     goto L_3100A0DA; /* 0x3100A0D3: jmp 0x3100a0da */
   6046 L_3100A0D5:
   6047     ecx = 1; /* 0x3100A0D5: mov ecx, 1 */
   6048 L_3100A0DA:
   6049     /* test edx, edx */ /* 0x3100A0DA: test edx, edx */
   6050     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
   6051     _cf = 0;
   6052     _flag_k = FK_TEST;
   6053     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100A0E2; /* 0x3100A0DC: jne 0x3100a0e2 */
   6054 L_3100A0DE:
   6055     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   6056     eax = 0; /* 0x3100A0DE: xor eax, eax */
   6057     _cf = 0;
   6058     _flag_k = FK_TEST;
   6059     goto L_3100A0E7; /* 0x3100A0E0: jmp 0x3100a0e7 */
   6060 L_3100A0E2:
   6061     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
   6062     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6063     eax = eax - edx; /* 0x3100A0E2: sub eax, edx */
   6064     _flag_k = FK_CMP;
   6065     if (2u) _cf = (((eax) >> 1) & 1u); /* 0x3100A0E4: sar eax, 2 */
   6066     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6067     eax = (uint32_t)((int32_t)eax >> 2u);
   6068 L_3100A0E7:
   6069     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   6070     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6071     eax = eax + ecx; /* 0x3100A0E7: add eax, ecx */
   6072     _flag_k = FK_ADD;
   6073     /* test eax, eax */ /* 0x3100A0E9: test eax, eax */
   6074     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6075     _cf = 0;
   6076     _flag_k = FK_TEST;
   6077     MEM32(ebp + (-0x14)) = eax; /* 0x3100A0EB: mov dword ptr [ebp - 0x14], eax */
   6078     if (TEST_NS(_flag_a, _flag_b)) goto L_3100A0F2; /* 0x3100A0EE: jge 0x3100a0f2 */
   6079 L_3100A0F0:
   6080     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   6081     eax = 0; /* 0x3100A0F0: xor eax, eax */
   6082     _cf = 0;
   6083     _flag_k = FK_TEST;
   6084 L_3100A0F2:
   6085     edx = eax * 4; /* 0x3100A0F2: lea edx, [eax*4] */
   6086     PUSH32(esp, ebx); /* 0x3100A0F9: push ebx */
   6087     PUSH32(esp, edx); /* 0x3100A0FA: push edx */
   6088     RECOMP_ICALL(0x310468DAu); /* 0x3100A0FB: call 0x310468da */ /* not lifted */
   6089     RECOMP_FLAGS_IN();
   6090     ebx = MEM32(0x31057E4C); /* 0x3100A100: mov ebx, dword ptr [0x31057e4c] */
   6091     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6092     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6093     esp = esp + 4; /* 0x3100A106: add esp, 4 */
   6094     _flag_k = FK_ADD;
   6095     /* cmp ebx, esi */ /* 0x3100A109: cmp ebx, esi */
   6096     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(esi);
   6097     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6098     _flag_k = FK_CMP;
   6099     MEM32(ebp + (-0x10)) = eax; /* 0x3100A10B: mov dword ptr [ebp - 0x10], eax */
   6100     edi = eax; /* 0x3100A10E: mov edi, eax */
   6101     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A126; /* 0x3100A110: je 0x3100a126 */
   6102 L_3100A112:
   6103     PUSH32(esp, ebx); /* 0x3100A112: push ebx */
   6104     PUSH32(esp, edi); /* 0x3100A113: push edi */
   6105     RECOMP_ICALL(0x31008130u); /* 0x3100A114: call 0x31008130 */ /* not lifted */
   6106     RECOMP_FLAGS_IN();
   6107     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(4);
   6108     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6109     ebx = ebx + 4; /* 0x3100A119: add ebx, 4 */
   6110     _flag_k = FK_ADD;
   6111     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   6112     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6113     esp = esp + 8; /* 0x3100A11C: add esp, 8 */
   6114     _flag_k = FK_ADD;
   6115     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(4);
   6116     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6117     edi = edi + 4; /* 0x3100A11F: add edi, 4 */
   6118     _flag_k = FK_ADD;
   6119     /* cmp ebx, esi */ /* 0x3100A122: cmp ebx, esi */
   6120     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(esi);
   6121     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6122     _flag_k = FK_CMP;
   6123     RECOMP_BACKEDGE();
   6124     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A112; /* 0x3100A124: jne 0x3100a112 */
   6125 L_3100A126:
   6126     eax = ebp + 0x8; /* 0x3100A126: lea eax, [ebp + 8] */
   6127     PUSH32(esp, eax); /* 0x3100A129: push eax */
   6128     PUSH32(esp, 1); /* 0x3100A12A: push 1 */
   6129     PUSH32(esp, edi); /* 0x3100A12C: push edi */
   6130     ecx = 0x31057E48u; /* 0x3100A12D: mov ecx, 0x31057e48 */
   6131     RECOMP_ICALL(0x3100A340u); /* 0x3100A132: call 0x3100a340 */ /* not lifted */
   6132     RECOMP_FLAGS_IN();
   6133     ecx = MEM32(0x31057E50); /* 0x3100A137: mov ecx, dword ptr [0x31057e50] */
   6134     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(4);
   6135     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6136     edi = edi + 4; /* 0x3100A13D: add edi, 4 */
   6137     _flag_k = FK_ADD;
   6138     PUSH32(esp, edi); /* 0x3100A140: push edi */
   6139     PUSH32(esp, ecx); /* 0x3100A141: push ecx */
   6140     PUSH32(esp, esi); /* 0x3100A142: push esi */
   6141     ecx = 0x31057E48u; /* 0x3100A143: mov ecx, 0x31057e48 */
   6142     RECOMP_ICALL(0x3100A310u); /* 0x3100A148: call 0x3100a310 */ /* not lifted */
   6143     RECOMP_FLAGS_IN();
   6144     edx = MEM32(0x31057E50); /* 0x3100A14D: mov edx, dword ptr [0x31057e50] */
   6145     eax = MEM32(0x31057E4C); /* 0x3100A153: mov eax, dword ptr [0x31057e4c] */
   6146     PUSH32(esp, edx); /* 0x3100A158: push edx */
   6147     PUSH32(esp, eax); /* 0x3100A159: push eax */
   6148     ecx = 0x31057E48u; /* 0x3100A15A: mov ecx, 0x31057e48 */
   6149     RECOMP_ICALL(0x3100E4D0u); /* 0x3100A15F: call 0x3100e4d0 */ /* not lifted */
   6150     RECOMP_FLAGS_IN();
   6151     ecx = MEM32(0x31057E4C); /* 0x3100A164: mov ecx, dword ptr [0x31057e4c] */
   6152     PUSH32(esp, ecx); /* 0x3100A16A: push ecx */
   6153     RECOMP_ICALL(0x31046858u); /* 0x3100A16B: call 0x31046858 */ /* not lifted */
   6154     RECOMP_FLAGS_IN();
   6155     edx = MEM32(ebp + (-0x10)); /* 0x3100A170: mov edx, dword ptr [ebp - 0x10] */
   6156     eax = MEM32(ebp + (-0x14)); /* 0x3100A173: mov eax, dword ptr [ebp - 0x14] */
   6157     ecx = edx + eax * 4; /* 0x3100A176: lea ecx, [edx + eax*4] */
   6158     MEM32(0x31057E54) = ecx; /* 0x3100A179: mov dword ptr [0x31057e54], ecx */
   6159     ecx = MEM32(0x31057E4C); /* 0x3100A17F: mov ecx, dword ptr [0x31057e4c] */
   6160     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6161     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6162     esp = esp + 4; /* 0x3100A185: add esp, 4 */
   6163     _flag_k = FK_ADD;
   6164     /* test ecx, ecx */ /* 0x3100A188: test ecx, ecx */
   6165     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   6166     _cf = 0;
   6167     _flag_k = FK_TEST;
   6168     ebx = POP32_VAL(esp); /* 0x3100A18A: pop ebx */
   6169     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100A191; /* 0x3100A18B: jne 0x3100a191 */
   6170 L_3100A18D:
   6171     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   6172     eax = 0; /* 0x3100A18D: xor eax, eax */
   6173     _cf = 0;
   6174     _flag_k = FK_TEST;
   6175     goto L_3100A19B; /* 0x3100A18F: jmp 0x3100a19b */
   6176 L_3100A191:
   6177     eax = MEM32(0x31057E50); /* 0x3100A191: mov eax, dword ptr [0x31057e50] */
   6178     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   6179     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6180     eax = eax - ecx; /* 0x3100A196: sub eax, ecx */
   6181     _flag_k = FK_CMP;
   6182     if (2u) _cf = (((eax) >> 1) & 1u); /* 0x3100A198: sar eax, 2 */
   6183     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)eax >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6184     eax = (uint32_t)((int32_t)eax >> 2u);
   6185 L_3100A19B:
   6186     eax = edx + eax * 4 + 0x4; /* 0x3100A19B: lea eax, [edx + eax*4 + 4] */
   6187     edi = POP32_VAL(esp); /* 0x3100A19F: pop edi */
   6188     MEM32(0x31057E50) = eax; /* 0x3100A1A0: mov dword ptr [0x31057e50], eax */
   6189     eax = MEM32(ebp + (-0x18)); /* 0x3100A1A5: mov eax, dword ptr [ebp - 0x18] */
   6190     MEM32(0x31057E4C) = edx; /* 0x3100A1A8: mov dword ptr [0x31057e4c], edx */
   6191     esi = POP32_VAL(esp); /* 0x3100A1AE: pop esi */
   6192     ecx = MEM32(ebp + (-0xC)); /* 0x3100A1AF: mov ecx, dword ptr [ebp - 0xc] */
   6193     MEM32(FS_BASE + (0)) = ecx; /* 0x3100A1B2: mov dword ptr fs:[0], ecx */
   6194     esp = ebp; /* 0x3100A1B9: mov esp, ebp */
   6195     ebp = POP32_VAL(esp); /* 0x3100A1BB: pop ebp */
   6196     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100A1BC: ret 4 */
   6197 L_3100A1BF:
   6198     ecx = eax; /* 0x3100A1BF: mov ecx, eax */
   6199     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(esi);
   6200     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6201     ecx = ecx - esi; /* 0x3100A1C1: sub ecx, esi */
   6202     _flag_k = FK_CMP;
   6203     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100A1C3: sar ecx, 2 */
   6204     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6205     ecx = (uint32_t)((int32_t)ecx >> 2u);
   6206     /* cmp ecx, 1 */ /* 0x3100A1C6: cmp ecx, 1 */
   6207     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   6208     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6209     _flag_k = FK_CMP;
   6210     if (CMP_AE(_flag_a, _flag_b)) goto L_3100A215; /* 0x3100A1C9: jae 0x3100a215 */
   6211 L_3100A1CB:
   6212     edx = esi + 0x4; /* 0x3100A1CB: lea edx, [esi + 4] */
   6213     PUSH32(esp, edx); /* 0x3100A1CE: push edx */
   6214     PUSH32(esp, eax); /* 0x3100A1CF: push eax */
   6215     PUSH32(esp, esi); /* 0x3100A1D0: push esi */
   6216     ecx = 0x31057E48u; /* 0x3100A1D1: mov ecx, 0x31057e48 */
   6217     RECOMP_ICALL(0x3100A310u); /* 0x3100A1D6: call 0x3100a310 */ /* not lifted */
   6218     RECOMP_FLAGS_IN();
   6219     eax = ebp + 0x8; /* 0x3100A1DB: lea eax, [ebp + 8] */
   6220     PUSH32(esp, eax); /* 0x3100A1DE: push eax */
   6221     eax = MEM32(0x31057E50); /* 0x3100A1DF: mov eax, dword ptr [0x31057e50] */
   6222     ecx = eax; /* 0x3100A1E4: mov ecx, eax */
   6223     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(esi);
   6224     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6225     ecx = ecx - esi; /* 0x3100A1E6: sub ecx, esi */
   6226     _flag_k = FK_CMP;
   6227     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100A1E8: sar ecx, 2 */
   6228     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   6229     ecx = (uint32_t)((int32_t)ecx >> 2u);
   6230     edx = 1; /* 0x3100A1EB: mov edx, 1 */
   6231     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   6232     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6233     edx = edx - ecx; /* 0x3100A1F0: sub edx, ecx */
   6234     _flag_k = FK_CMP;
   6235     PUSH32(esp, edx); /* 0x3100A1F2: push edx */
   6236     PUSH32(esp, eax); /* 0x3100A1F3: push eax */
   6237     ecx = 0x31057E48u; /* 0x3100A1F4: mov ecx, 0x31057e48 */
   6238     RECOMP_ICALL(0x3100A340u); /* 0x3100A1F9: call 0x3100a340 */ /* not lifted */
   6239     RECOMP_FLAGS_IN();
   6240     eax = MEM32(0x31057E50); /* 0x3100A1FE: mov eax, dword ptr [0x31057e50] */
   6241     /* cmp esi, eax */ /* 0x3100A203: cmp esi, eax */
   6242     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   6243     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6244     _flag_k = FK_CMP;
   6245     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A255; /* 0x3100A205: je 0x3100a255 */
   6246 L_3100A207:
   6247     ecx = MEM32(ebp + 0x8); /* 0x3100A207: mov ecx, dword ptr [ebp + 8] */
   6248     MEM32(esi) = ecx; /* 0x3100A20A: mov dword ptr [esi], ecx */
   6249     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(4);
   6250     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6251     esi = esi + 4; /* 0x3100A20C: add esi, 4 */
   6252     _flag_k = FK_ADD;
   6253     /* cmp esi, eax */ /* 0x3100A20F: cmp esi, eax */
   6254     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   6255     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6256     _flag_k = FK_CMP;
   6257     RECOMP_BACKEDGE();
   6258     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A207; /* 0x3100A211: jne 0x3100a207 */
   6259 L_3100A213:
   6260     goto L_3100A255; /* 0x3100A213: jmp 0x3100a255 */
   6261 L_3100A215:
   6262     PUSH32(esp, eax); /* 0x3100A215: push eax */
   6263     PUSH32(esp, eax); /* 0x3100A216: push eax */
   6264     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xFFFFFFFCu);
   6265     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6266     eax = eax + 0xFFFFFFFCu; /* 0x3100A217: add eax, -4 */
   6267     _flag_k = FK_ADD;
   6268     PUSH32(esp, eax); /* 0x3100A21A: push eax */
   6269     ecx = 0x31057E48u; /* 0x3100A21B: mov ecx, 0x31057e48 */
   6270     RECOMP_ICALL(0x3100A310u); /* 0x3100A220: call 0x3100a310 */ /* not lifted */
   6271     RECOMP_FLAGS_IN();
   6272     eax = MEM32(0x31057E50); /* 0x3100A225: mov eax, dword ptr [0x31057e50] */
   6273     ecx = eax; /* 0x3100A22A: mov ecx, eax */
   6274     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xFFFFFFFCu);
   6275     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6276     eax = eax + 0xFFFFFFFCu; /* 0x3100A22C: add eax, -4 */
   6277     _flag_k = FK_ADD;
   6278     /* cmp esi, eax */ /* 0x3100A22F: cmp esi, eax */
   6279     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   6280     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6281     _flag_k = FK_CMP;
   6282     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A242; /* 0x3100A231: je 0x3100a242 */
   6283 L_3100A233:
   6284     edx = MEM32(eax + (-0x4)); /* 0x3100A233: mov edx, dword ptr [eax - 4] */
   6285     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   6286     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6287     eax = eax - 4; /* 0x3100A236: sub eax, 4 */
   6288     _flag_k = FK_CMP;
   6289     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4);
   6290     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6291     ecx = ecx - 4; /* 0x3100A239: sub ecx, 4 */
   6292     _flag_k = FK_CMP;
   6293     /* cmp eax, esi */ /* 0x3100A23C: cmp eax, esi */
   6294     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   6295     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6296     _flag_k = FK_CMP;
   6297     MEM32(ecx) = edx; /* 0x3100A23E: mov dword ptr [ecx], edx */
   6298     RECOMP_BACKEDGE();
   6299     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A233; /* 0x3100A240: jne 0x3100a233 */
   6300 L_3100A242:
   6301     eax = esi + 0x4; /* 0x3100A242: lea eax, [esi + 4] */
   6302     /* cmp esi, eax */ /* 0x3100A245: cmp esi, eax */
   6303     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   6304     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6305     _flag_k = FK_CMP;
   6306     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A255; /* 0x3100A247: je 0x3100a255 */
   6307 L_3100A249:
   6308     ecx = MEM32(ebp + 0x8); /* 0x3100A249: mov ecx, dword ptr [ebp + 8] */
   6309     MEM32(esi) = ecx; /* 0x3100A24C: mov dword ptr [esi], ecx */
   6310     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(4);
   6311     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6312     esi = esi + 4; /* 0x3100A24E: add esi, 4 */
   6313     _flag_k = FK_ADD;
   6314     /* cmp esi, eax */ /* 0x3100A251: cmp esi, eax */
   6315     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(eax);
   6316     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6317     _flag_k = FK_CMP;
   6318     RECOMP_BACKEDGE();
   6319     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A249; /* 0x3100A253: jne 0x3100a249 */
   6320 L_3100A255:
   6321     eax = MEM32(0x31057E50); /* 0x3100A255: mov eax, dword ptr [0x31057e50] */
   6322     ecx = MEM32(ebp + (-0xC)); /* 0x3100A25A: mov ecx, dword ptr [ebp - 0xc] */
   6323     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   6324     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6325     eax = eax + 4; /* 0x3100A25D: add eax, 4 */
   6326     _flag_k = FK_ADD;
   6327     MEM32(0x31057E50) = eax; /* 0x3100A260: mov dword ptr [0x31057e50], eax */
   6328     eax = edi; /* 0x3100A265: mov eax, edi */
   6329     edi = POP32_VAL(esp); /* 0x3100A267: pop edi */
   6330     esi = POP32_VAL(esp); /* 0x3100A268: pop esi */
   6331     MEM32(FS_BASE + (0)) = ecx; /* 0x3100A269: mov dword ptr fs:[0], ecx */
   6332     esp = ebp; /* 0x3100A270: mov esp, ebp */
   6333     ebp = POP32_VAL(esp); /* 0x3100A272: pop ebp */
   6334     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100A273: ret 4 */
   6335     RECOMP_REGS_OUT();
   6336 }
   6337 
   6338 void sub_3100A280(void) {
   6339     int _fpu_cmp = 0;
   6340     uint32_t _cf = 0;
   6341     int _df = 1;
   6342     uint32_t _flag_k = FK_NONE;
   6343     uint32_t _flag_a = 0, _flag_b = 0;
   6344     uint32_t _itail_tgt = 0;
   6345     RECOMP_REGS_LOCALS
   6346     RECOMP_ENTER(0x3100A280u);
   6347 
   6348 L_3100A280:
   6349     PUSH32(esp, ebp); /* 0x3100A280: push ebp */
   6350     ebp = esp; /* 0x3100A281: mov ebp, esp */
   6351     PUSH32(esp, esi); /* 0x3100A283: push esi */
   6352     esi = ecx; /* 0x3100A284: mov esi, ecx */
   6353     RECOMP_ICALL(0x3100A2B0u); /* 0x3100A286: call 0x3100a2b0 */ /* not lifted */
   6354     RECOMP_FLAGS_IN();
   6355     /* test MEM8(ebp + 0x8), 1 */ /* 0x3100A28B: test byte ptr [ebp + 8], 1 */
   6356     _flag_a = (uint32_t)(MEM8(ebp + 0x8)) << 24; _flag_b = (uint32_t)(1) << 24;
   6357     _cf = 0;
   6358     _flag_k = FK_NARROW(FK_TEST, 24);
   6359     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A29A; /* 0x3100A28F: je 0x3100a29a */
   6360 L_3100A291:
   6361     PUSH32(esp, esi); /* 0x3100A291: push esi */
   6362     RECOMP_ICALL(0x31046858u); /* 0x3100A292: call 0x31046858 */ /* not lifted */
   6363     RECOMP_FLAGS_IN();
   6364     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6365     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6366     esp = esp + 4; /* 0x3100A297: add esp, 4 */
   6367     _flag_k = FK_ADD;
   6368 L_3100A29A:
   6369     eax = esi; /* 0x3100A29A: mov eax, esi */
   6370     esi = POP32_VAL(esp); /* 0x3100A29C: pop esi */
   6371     ebp = POP32_VAL(esp); /* 0x3100A29D: pop ebp */
   6372     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100A29E: ret 4 */
   6373     RECOMP_REGS_OUT();
   6374 }
   6375 
   6376 void sub_3100A2B0(void) {
   6377     int _fpu_cmp = 0;
   6378     uint32_t _cf = 0;
   6379     int _df = 1;
   6380     uint32_t _flag_k = FK_NONE;
   6381     uint32_t _flag_a = 0, _flag_b = 0;
   6382     uint32_t _itail_tgt = 0;
   6383     RECOMP_REGS_LOCALS
   6384     RECOMP_ENTER(0x3100A2B0u);
   6385 
   6386 L_3100A2B0:
   6387     PUSH32(esp, ebp); /* 0x3100A2B0: push ebp */
   6388     ebp = esp; /* 0x3100A2B1: mov ebp, esp */
   6389     PUSH32(esp, ecx); /* 0x3100A2B3: push ecx */
   6390     MEM32(ecx) = 0x31048600u; /* 0x3100A2B4: mov dword ptr [ecx], 0x31048600 */
   6391     edx = MEM32(0x31057E4C); /* 0x3100A2BA: mov edx, dword ptr [0x31057e4c] */
   6392 L_3100A2C0:
   6393     /* cmp MEM32(edx), ecx */ /* 0x3100A2C0: cmp dword ptr [edx], ecx */
   6394     _flag_a = (uint32_t)(MEM32(edx)); _flag_b = (uint32_t)(ecx);
   6395     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6396     _flag_k = FK_CMP;
   6397     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A2C9; /* 0x3100A2C2: je 0x3100a2c9 */
   6398 L_3100A2C4:
   6399     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(4);
   6400     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6401     edx = edx + 4; /* 0x3100A2C4: add edx, 4 */
   6402     _flag_k = FK_ADD;
   6403     RECOMP_BACKEDGE();
   6404     goto L_3100A2C0; /* 0x3100A2C7: jmp 0x3100a2c0 */
   6405 L_3100A2C9:
   6406     PUSH32(esp, esi); /* 0x3100A2C9: push esi */
   6407     esi = MEM32(0x31057E50); /* 0x3100A2CA: mov esi, dword ptr [0x31057e50] */
   6408     eax = edx + 0x4; /* 0x3100A2D0: lea eax, [edx + 4] */
   6409     /* cmp eax, esi */ /* 0x3100A2D3: cmp eax, esi */
   6410     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   6411     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6412     _flag_k = FK_CMP;
   6413     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A2E7; /* 0x3100A2D5: je 0x3100a2e7 */
   6414 L_3100A2D7:
   6415     PUSH32(esp, edi); /* 0x3100A2D7: push edi */
   6416     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   6417     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6418     edx = edx - eax; /* 0x3100A2D8: sub edx, eax */
   6419     _flag_k = FK_CMP;
   6420 L_3100A2DA:
   6421     edi = MEM32(eax); /* 0x3100A2DA: mov edi, dword ptr [eax] */
   6422     MEM32(edx + eax) = edi; /* 0x3100A2DC: mov dword ptr [edx + eax], edi */
   6423     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   6424     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6425     eax = eax + 4; /* 0x3100A2DF: add eax, 4 */
   6426     _flag_k = FK_ADD;
   6427     /* cmp eax, esi */ /* 0x3100A2E2: cmp eax, esi */
   6428     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   6429     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6430     _flag_k = FK_CMP;
   6431     RECOMP_BACKEDGE();
   6432     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A2DA; /* 0x3100A2E4: jne 0x3100a2da */
   6433 L_3100A2E6:
   6434     edi = POP32_VAL(esp); /* 0x3100A2E6: pop edi */
   6435 L_3100A2E7:
   6436     eax = MEM32(0x31057E50); /* 0x3100A2E7: mov eax, dword ptr [0x31057e50] */
   6437     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xFFFFFFFCu);
   6438     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6439     eax = eax + 0xFFFFFFFCu; /* 0x3100A2EC: add eax, -4 */
   6440     _flag_k = FK_ADD;
   6441     MEM32(ebp + (-0x4)) = eax; /* 0x3100A2EF: mov dword ptr [ebp - 4], eax */
   6442     MEM32(0x31057E50) = eax; /* 0x3100A2F2: mov dword ptr [0x31057e50], eax */
   6443     RECOMP_ICALL(0x31008E30u); /* 0x3100A2F7: call 0x31008e30 */ /* not lifted */
   6444     RECOMP_FLAGS_IN();
   6445     esi = POP32_VAL(esp); /* 0x3100A2FC: pop esi */
   6446     esp = ebp; /* 0x3100A2FD: mov esp, ebp */
   6447     ebp = POP32_VAL(esp); /* 0x3100A2FF: pop ebp */
   6448     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A300: ret  */
   6449     RECOMP_REGS_OUT();
   6450 }
   6451 
   6452 void sub_3100A2C0(void) {
   6453     int _fpu_cmp = 0;
   6454     uint32_t _cf = 0;
   6455     int _df = 1;
   6456     uint32_t _flag_k = FK_NONE;
   6457     uint32_t _flag_a = 0, _flag_b = 0;
   6458     uint32_t _itail_tgt = 0;
   6459     RECOMP_REGS_LOCALS
   6460     RECOMP_ENTER(0x3100A2C0u);
   6461 
   6462 L_3100A2C0:
   6463     /* cmp MEM32(edx), ecx */ /* 0x3100A2C0: cmp dword ptr [edx], ecx */
   6464     _flag_a = (uint32_t)(MEM32(edx)); _flag_b = (uint32_t)(ecx);
   6465     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6466     _flag_k = FK_CMP;
   6467     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A2C9; /* 0x3100A2C2: je 0x3100a2c9 */
   6468 L_3100A2C4:
   6469     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(4);
   6470     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6471     edx = edx + 4; /* 0x3100A2C4: add edx, 4 */
   6472     _flag_k = FK_ADD;
   6473     RECOMP_BACKEDGE();
   6474     goto L_3100A2C0; /* 0x3100A2C7: jmp 0x3100a2c0 */
   6475 L_3100A2C9:
   6476     PUSH32(esp, esi); /* 0x3100A2C9: push esi */
   6477     esi = MEM32(0x31057E50); /* 0x3100A2CA: mov esi, dword ptr [0x31057e50] */
   6478     eax = edx + 0x4; /* 0x3100A2D0: lea eax, [edx + 4] */
   6479     /* cmp eax, esi */ /* 0x3100A2D3: cmp eax, esi */
   6480     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   6481     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6482     _flag_k = FK_CMP;
   6483     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A2E7; /* 0x3100A2D5: je 0x3100a2e7 */
   6484 L_3100A2D7:
   6485     PUSH32(esp, edi); /* 0x3100A2D7: push edi */
   6486     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
   6487     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6488     edx = edx - eax; /* 0x3100A2D8: sub edx, eax */
   6489     _flag_k = FK_CMP;
   6490 L_3100A2DA:
   6491     edi = MEM32(eax); /* 0x3100A2DA: mov edi, dword ptr [eax] */
   6492     MEM32(edx + eax) = edi; /* 0x3100A2DC: mov dword ptr [edx + eax], edi */
   6493     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   6494     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6495     eax = eax + 4; /* 0x3100A2DF: add eax, 4 */
   6496     _flag_k = FK_ADD;
   6497     /* cmp eax, esi */ /* 0x3100A2E2: cmp eax, esi */
   6498     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
   6499     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6500     _flag_k = FK_CMP;
   6501     RECOMP_BACKEDGE();
   6502     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A2DA; /* 0x3100A2E4: jne 0x3100a2da */
   6503 L_3100A2E6:
   6504     edi = POP32_VAL(esp); /* 0x3100A2E6: pop edi */
   6505 L_3100A2E7:
   6506     eax = MEM32(0x31057E50); /* 0x3100A2E7: mov eax, dword ptr [0x31057e50] */
   6507     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xFFFFFFFCu);
   6508     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6509     eax = eax + 0xFFFFFFFCu; /* 0x3100A2EC: add eax, -4 */
   6510     _flag_k = FK_ADD;
   6511     MEM32(ebp + (-0x4)) = eax; /* 0x3100A2EF: mov dword ptr [ebp - 4], eax */
   6512     MEM32(0x31057E50) = eax; /* 0x3100A2F2: mov dword ptr [0x31057e50], eax */
   6513     RECOMP_ICALL(0x31008E30u); /* 0x3100A2F7: call 0x31008e30 */ /* not lifted */
   6514     RECOMP_FLAGS_IN();
   6515     esi = POP32_VAL(esp); /* 0x3100A2FC: pop esi */
   6516     esp = ebp; /* 0x3100A2FD: mov esp, ebp */
   6517     ebp = POP32_VAL(esp); /* 0x3100A2FF: pop ebp */
   6518     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A300: ret  */
   6519     RECOMP_REGS_OUT();
   6520 }
   6521 
   6522 void sub_3100A310(void) {
   6523     int _fpu_cmp = 0;
   6524     uint32_t _cf = 0;
   6525     int _df = 1;
   6526     uint32_t _flag_k = FK_NONE;
   6527     uint32_t _flag_a = 0, _flag_b = 0;
   6528     uint32_t _itail_tgt = 0;
   6529     RECOMP_REGS_LOCALS
   6530     RECOMP_ENTER(0x3100A310u);
   6531 
   6532 L_3100A310:
   6533     PUSH32(esp, ebp); /* 0x3100A310: push ebp */
   6534     ebp = esp; /* 0x3100A311: mov ebp, esp */
   6535     ecx = MEM32(ebp + 0x8); /* 0x3100A313: mov ecx, dword ptr [ebp + 8] */
   6536     edx = MEM32(ebp + 0xC); /* 0x3100A316: mov edx, dword ptr [ebp + 0xc] */
   6537     /* cmp ecx, edx */ /* 0x3100A319: cmp ecx, edx */
   6538     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   6539     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6540     _flag_k = FK_CMP;
   6541     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A338; /* 0x3100A31B: je 0x3100a338 */
   6542 L_3100A31D:
   6543     eax = MEM32(ebp + 0x10); /* 0x3100A31D: mov eax, dword ptr [ebp + 0x10] */
   6544     PUSH32(esp, esi); /* 0x3100A320: push esi */
   6545 L_3100A321:
   6546     /* test eax, eax */ /* 0x3100A321: test eax, eax */
   6547     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6548     _cf = 0;
   6549     _flag_k = FK_TEST;
   6550     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A329; /* 0x3100A323: je 0x3100a329 */
   6551 L_3100A325:
   6552     esi = MEM32(ecx); /* 0x3100A325: mov esi, dword ptr [ecx] */
   6553     MEM32(eax) = esi; /* 0x3100A327: mov dword ptr [eax], esi */
   6554 L_3100A329:
   6555     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4);
   6556     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6557     ecx = ecx + 4; /* 0x3100A329: add ecx, 4 */
   6558     _flag_k = FK_ADD;
   6559     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   6560     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6561     eax = eax + 4; /* 0x3100A32C: add eax, 4 */
   6562     _flag_k = FK_ADD;
   6563     /* cmp ecx, edx */ /* 0x3100A32F: cmp ecx, edx */
   6564     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   6565     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6566     _flag_k = FK_CMP;
   6567     RECOMP_BACKEDGE();
   6568     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A321; /* 0x3100A331: jne 0x3100a321 */
   6569 L_3100A333:
   6570     esi = POP32_VAL(esp); /* 0x3100A333: pop esi */
   6571     ebp = POP32_VAL(esp); /* 0x3100A334: pop ebp */
   6572     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3100A335: ret 0xc */
   6573 L_3100A338:
   6574     eax = MEM32(ebp + 0x10); /* 0x3100A338: mov eax, dword ptr [ebp + 0x10] */
   6575     ebp = POP32_VAL(esp); /* 0x3100A33B: pop ebp */
   6576     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3100A33C: ret 0xc */
   6577     RECOMP_REGS_OUT();
   6578 }
   6579 
   6580 void sub_3100A340(void) {
   6581     int _fpu_cmp = 0;
   6582     uint32_t _cf = 0;
   6583     int _df = 1;
   6584     uint32_t _flag_k = FK_NONE;
   6585     uint32_t _flag_a = 0, _flag_b = 0;
   6586     uint32_t _itail_tgt = 0;
   6587     RECOMP_REGS_LOCALS
   6588     RECOMP_ENTER(0x3100A340u);
   6589 
   6590 L_3100A340:
   6591     PUSH32(esp, ebp); /* 0x3100A340: push ebp */
   6592     ebp = esp; /* 0x3100A341: mov ebp, esp */
   6593     eax = MEM32(ebp + 0xC); /* 0x3100A343: mov eax, dword ptr [ebp + 0xc] */
   6594     /* test eax, eax */ /* 0x3100A346: test eax, eax */
   6595     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6596     _cf = 0;
   6597     _flag_k = FK_TEST;
   6598     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A362; /* 0x3100A348: jbe 0x3100a362 */
   6599 L_3100A34A:
   6600     edx = MEM32(ebp + 0x10); /* 0x3100A34A: mov edx, dword ptr [ebp + 0x10] */
   6601     ecx = eax; /* 0x3100A34D: mov ecx, eax */
   6602     eax = MEM32(ebp + 0x8); /* 0x3100A34F: mov eax, dword ptr [ebp + 8] */
   6603     PUSH32(esp, esi); /* 0x3100A352: push esi */
   6604 L_3100A353:
   6605     /* test eax, eax */ /* 0x3100A353: test eax, eax */
   6606     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6607     _cf = 0;
   6608     _flag_k = FK_TEST;
   6609     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A35B; /* 0x3100A355: je 0x3100a35b */
   6610 L_3100A357:
   6611     esi = MEM32(edx); /* 0x3100A357: mov esi, dword ptr [edx] */
   6612     MEM32(eax) = esi; /* 0x3100A359: mov dword ptr [eax], esi */
   6613 L_3100A35B:
   6614     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(4);
   6615     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6616     eax = eax + 4; /* 0x3100A35B: add eax, 4 */
   6617     _flag_k = FK_ADD;
   6618     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   6619     ecx = ecx - 1; /* 0x3100A35E: dec ecx */
   6620     _flag_k = FK_DEC;
   6621     RECOMP_BACKEDGE();
   6622     if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3100A353; /* 0x3100A35F: jne 0x3100a353 */
   6623 L_3100A361:
   6624     esi = POP32_VAL(esp); /* 0x3100A361: pop esi */
   6625 L_3100A362:
   6626     ebp = POP32_VAL(esp); /* 0x3100A362: pop ebp */
   6627     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3100A363: ret 0xc */
   6628     RECOMP_REGS_OUT();
   6629 }
   6630 
   6631 void sub_3100A370(void) {
   6632     int _fpu_cmp = 0;
   6633     uint32_t _cf = 0;
   6634     int _df = 1;
   6635     uint32_t _flag_k = FK_NONE;
   6636     uint32_t _flag_a = 0, _flag_b = 0;
   6637     uint32_t _itail_tgt = 0;
   6638     RECOMP_REGS_LOCALS
   6639     RECOMP_ENTER(0x3100A370u);
   6640 
   6641 L_3100A370:
   6642     RECOMP_ICALL(0x3100A380u); /* 0x3100A370: call 0x3100a380 */ /* not lifted */
   6643     RECOMP_FLAGS_IN();
   6644     goto L_3100A390; /* 0x3100A375: jmp 0x3100a390 */
   6645 L_3100A390:
   6646     PUSH32(esp, 0x3100A3A0u); /* 0x3100A390: push 0x3100a3a0 */
   6647     RECOMP_ICALL(0x310468C8u); /* 0x3100A395: call 0x310468c8 */ /* not lifted */
   6648     RECOMP_FLAGS_IN();
   6649     ecx = POP32_VAL(esp); /* 0x3100A39A: pop ecx */
   6650     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A39B: ret  */
   6651     RECOMP_REGS_OUT();
   6652 }
   6653 
   6654 void sub_3100A380(void) {
   6655     int _fpu_cmp = 0;
   6656     uint32_t _cf = 0;
   6657     int _df = 1;
   6658     uint32_t _flag_k = FK_NONE;
   6659     uint32_t _flag_a = 0, _flag_b = 0;
   6660     uint32_t _itail_tgt = 0;
   6661     RECOMP_REGS_LOCALS
   6662     RECOMP_ENTER(0x3100A380u);
   6663 
   6664 L_3100A380:
   6665     ecx = 0x31057E5Du; /* 0x3100A380: mov ecx, 0x31057e5d */
   6666 L_3100A385:
   6667     { _itail_tgt = (uint32_t)(MEM32(0x31048108)); goto _ljump; }
   6668     { RECOMP_REGS_OUT(); return; } /* end of function */
   6669   _ljump:
   6670     switch (_itail_tgt) {
   6671       case 0x3100A380u: goto L_3100A380;
   6672       case 0x3100A385u: goto L_3100A385;
   6673       default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; }
   6674     }
   6675     RECOMP_REGS_OUT();
   6676 }
   6677 
   6678 void sub_3100A390(void) {
   6679     int _fpu_cmp = 0;
   6680     uint32_t _cf = 0;
   6681     int _df = 1;
   6682     uint32_t _flag_k = FK_NONE;
   6683     uint32_t _flag_a = 0, _flag_b = 0;
   6684     uint32_t _itail_tgt = 0;
   6685     RECOMP_REGS_LOCALS
   6686     RECOMP_ENTER(0x3100A390u);
   6687 
   6688 L_3100A390:
   6689     PUSH32(esp, 0x3100A3A0u); /* 0x3100A390: push 0x3100a3a0 */
   6690     RECOMP_ICALL(0x310468C8u); /* 0x3100A395: call 0x310468c8 */ /* not lifted */
   6691     RECOMP_FLAGS_IN();
   6692     ecx = POP32_VAL(esp); /* 0x3100A39A: pop ecx */
   6693     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A39B: ret  */
   6694     RECOMP_REGS_OUT();
   6695 }
   6696 
   6697 void sub_3100A3A0(void) {
   6698     int _fpu_cmp = 0;
   6699     uint32_t _cf = 0;
   6700     int _df = 1;
   6701     uint32_t _flag_k = FK_NONE;
   6702     uint32_t _flag_a = 0, _flag_b = 0;
   6703     uint32_t _itail_tgt = 0;
   6704     RECOMP_REGS_LOCALS
   6705     RECOMP_ENTER(0x3100A3A0u);
   6706 
   6707 L_3100A3A0:
   6708     ecx = 0x31057E5Du; /* 0x3100A3A0: mov ecx, 0x31057e5d */
   6709 L_3100A3A5:
   6710     { _itail_tgt = (uint32_t)(MEM32(0x3104807C)); goto _ljump; }
   6711     { RECOMP_REGS_OUT(); return; } /* end of function */
   6712   _ljump:
   6713     switch (_itail_tgt) {
   6714       case 0x3100A3A0u: goto L_3100A3A0;
   6715       case 0x3100A3A5u: goto L_3100A3A5;
   6716       default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; }
   6717     }
   6718     RECOMP_REGS_OUT();
   6719 }
   6720 
   6721 void sub_3100A3B0(void) {
   6722     int _fpu_cmp = 0;
   6723     uint32_t _cf = 0;
   6724     int _df = 1;
   6725     uint32_t _flag_k = FK_NONE;
   6726     uint32_t _flag_a = 0, _flag_b = 0;
   6727     uint32_t _itail_tgt = 0;
   6728     RECOMP_REGS_LOCALS
   6729     RECOMP_ENTER(0x3100A3B0u);
   6730 
   6731 L_3100A3B0:
   6732     RECOMP_ICALL(0x3100A3C0u); /* 0x3100A3B0: call 0x3100a3c0 */ /* not lifted */
   6733     RECOMP_FLAGS_IN();
   6734     goto L_3100A3D0; /* 0x3100A3B5: jmp 0x3100a3d0 */
   6735 L_3100A3D0:
   6736     PUSH32(esp, 0x3100A3E0u); /* 0x3100A3D0: push 0x3100a3e0 */
   6737     RECOMP_ICALL(0x310468C8u); /* 0x3100A3D5: call 0x310468c8 */ /* not lifted */
   6738     RECOMP_FLAGS_IN();
   6739     ecx = POP32_VAL(esp); /* 0x3100A3DA: pop ecx */
   6740     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A3DB: ret  */
   6741     RECOMP_REGS_OUT();
   6742 }
   6743 
   6744 void sub_3100A3C0(void) {
   6745     int _fpu_cmp = 0;
   6746     uint32_t _cf = 0;
   6747     int _df = 1;
   6748     uint32_t _flag_k = FK_NONE;
   6749     uint32_t _flag_a = 0, _flag_b = 0;
   6750     uint32_t _itail_tgt = 0;
   6751     RECOMP_REGS_LOCALS
   6752     RECOMP_ENTER(0x3100A3C0u);
   6753 
   6754 L_3100A3C0:
   6755     ecx = 0x31057E5Cu; /* 0x3100A3C0: mov ecx, 0x31057e5c */
   6756 L_3100A3C5:
   6757     { _itail_tgt = (uint32_t)(MEM32(0x31048104)); goto _ljump; }
   6758     { RECOMP_REGS_OUT(); return; } /* end of function */
   6759   _ljump:
   6760     switch (_itail_tgt) {
   6761       case 0x3100A3C0u: goto L_3100A3C0;
   6762       case 0x3100A3C5u: goto L_3100A3C5;
   6763       default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; }
   6764     }
   6765     RECOMP_REGS_OUT();
   6766 }
   6767 
   6768 void sub_3100A3D0(void) {
   6769     int _fpu_cmp = 0;
   6770     uint32_t _cf = 0;
   6771     int _df = 1;
   6772     uint32_t _flag_k = FK_NONE;
   6773     uint32_t _flag_a = 0, _flag_b = 0;
   6774     uint32_t _itail_tgt = 0;
   6775     RECOMP_REGS_LOCALS
   6776     RECOMP_ENTER(0x3100A3D0u);
   6777 
   6778 L_3100A3D0:
   6779     PUSH32(esp, 0x3100A3E0u); /* 0x3100A3D0: push 0x3100a3e0 */
   6780     RECOMP_ICALL(0x310468C8u); /* 0x3100A3D5: call 0x310468c8 */ /* not lifted */
   6781     RECOMP_FLAGS_IN();
   6782     ecx = POP32_VAL(esp); /* 0x3100A3DA: pop ecx */
   6783     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A3DB: ret  */
   6784     RECOMP_REGS_OUT();
   6785 }
   6786 
   6787 void sub_3100A3E0(void) {
   6788     int _fpu_cmp = 0;
   6789     uint32_t _cf = 0;
   6790     int _df = 1;
   6791     uint32_t _flag_k = FK_NONE;
   6792     uint32_t _flag_a = 0, _flag_b = 0;
   6793     uint32_t _itail_tgt = 0;
   6794     RECOMP_REGS_LOCALS
   6795     RECOMP_ENTER(0x3100A3E0u);
   6796 
   6797 L_3100A3E0:
   6798     ecx = 0x31057E5Cu; /* 0x3100A3E0: mov ecx, 0x31057e5c */
   6799 L_3100A3E5:
   6800     { _itail_tgt = (uint32_t)(MEM32(0x31048080)); goto _ljump; }
   6801     { RECOMP_REGS_OUT(); return; } /* end of function */
   6802   _ljump:
   6803     switch (_itail_tgt) {
   6804       case 0x3100A3E0u: goto L_3100A3E0;
   6805       case 0x3100A3E5u: goto L_3100A3E5;
   6806       default: RECOMP_ITAIL(_itail_tgt); { RECOMP_REGS_OUT(); return; }
   6807     }
   6808     RECOMP_REGS_OUT();
   6809 }
   6810 
   6811 void sub_3100A3F0(void) {
   6812     int _fpu_cmp = 0;
   6813     uint32_t _cf = 0;
   6814     int _df = 1;
   6815     uint32_t _flag_k = FK_NONE;
   6816     uint32_t _flag_a = 0, _flag_b = 0;
   6817     uint32_t _itail_tgt = 0;
   6818     RECOMP_REGS_LOCALS
   6819     RECOMP_ENTER(0x3100A3F0u);
   6820 
   6821 L_3100A3F0:
   6822     PUSH32(esp, ebp); /* 0x3100A3F0: push ebp */
   6823     ebp = esp; /* 0x3100A3F1: mov ebp, esp */
   6824     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100A3F3: push -1 */
   6825     PUSH32(esp, 0x31047384u); /* 0x3100A3F5: push 0x31047384 */
   6826     eax = MEM32(FS_BASE + (0)); /* 0x3100A3FA: mov eax, dword ptr fs:[0] */
   6827     PUSH32(esp, eax); /* 0x3100A400: push eax */
   6828     MEM32(FS_BASE + (0)) = esp; /* 0x3100A401: mov dword ptr fs:[0], esp */
   6829     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x34u);
   6830     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6831     esp = esp - 0x34u; /* 0x3100A408: sub esp, 0x34 */
   6832     _flag_k = FK_CMP;
   6833     PUSH32(esp, esi); /* 0x3100A40B: push esi */
   6834     esi = MEM32(ebp + 0x8); /* 0x3100A40C: mov esi, dword ptr [ebp + 8] */
   6835     PUSH32(esp, 0x31052168u); /* 0x3100A40F: push 0x31052168 */
   6836     eax = ebp + (-0x1C); /* 0x3100A414: lea eax, [ebp - 0x1c] */
   6837     PUSH32(esp, esi); /* 0x3100A417: push esi */
   6838     PUSH32(esp, eax); /* 0x3100A418: push eax */
   6839     RECOMP_ICALL(0x3104686Au); /* 0x3100A419: call 0x3104686a */ /* not lifted */
   6840     RECOMP_FLAGS_IN();
   6841     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   6842     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6843     esp = esp + 0xCu; /* 0x3100A41E: add esp, 0xc */
   6844     _flag_k = FK_ADD;
   6845     eax = MEM32(ebp + (-0x18)); /* 0x3100A421: mov eax, dword ptr [ebp - 0x18] */
   6846     /* test eax, eax */ /* 0x3100A424: test eax, eax */
   6847     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6848     _cf = 0;
   6849     _flag_k = FK_TEST;
   6850     MEM32(ebp + (-0x4)) = 0; /* 0x3100A426: mov dword ptr [ebp - 4], 0 */
   6851     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100A434; /* 0x3100A42D: jne 0x3100a434 */
   6852 L_3100A42F:
   6853     eax = MEM32(0x310480EC); /* 0x3100A42F: mov eax, dword ptr [0x310480ec] */
   6854 L_3100A434:
   6855     ecx = ebp + (-0x40); /* 0x3100A434: lea ecx, [ebp - 0x40] */
   6856     PUSH32(esp, ecx); /* 0x3100A437: push ecx */
   6857     PUSH32(esp, eax); /* 0x3100A438: push eax */
   6858     RECOMP_ICALL(MEM32(0x31048230)); /* 0x3100A439: call dword ptr [0x31048230] */
   6859     RECOMP_FLAGS_IN();
   6860     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   6861     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6862     esp = esp + 8; /* 0x3100A43F: add esp, 8 */
   6863     _flag_k = FK_ADD;
   6864     /* test eax, eax */ /* 0x3100A442: test eax, eax */
   6865     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6866     _cf = 0;
   6867     _flag_k = FK_TEST;
   6868     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A489; /* 0x3100A444: je 0x3100a489 */
   6869 L_3100A446:
   6870     ecx = MEM32(ebp + (-0x18)); /* 0x3100A446: mov ecx, dword ptr [ebp - 0x18] */
   6871     /* test ecx, ecx */ /* 0x3100A449: test ecx, ecx */
   6872     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   6873     _cf = 0;
   6874     _flag_k = FK_TEST;
   6875     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A478; /* 0x3100A44B: je 0x3100a478 */
   6876 L_3100A44D:
   6877     SET_LO8(eax, MEM8(ecx + (-0x1))); /* 0x3100A44D: mov al, byte ptr [ecx - 1] */
   6878     /* test LO8(eax), LO8(eax) */ /* 0x3100A450: test al, al */
   6879     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   6880     _cf = 0;
   6881     _flag_k = FK_NARROW(FK_TEST, 24);
   6882     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A46E; /* 0x3100A452: je 0x3100a46e */
   6883 L_3100A454:
   6884     /* cmp LO8(eax), 0xFFu */ /* 0x3100A454: cmp al, 0xff */
   6885     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   6886     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6887     _flag_k = FK_NARROW(FK_CMP, 24);
   6888     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A46E; /* 0x3100A456: je 0x3100a46e */
   6889 L_3100A458:
   6890     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   6891     SET_LO8(eax, LO8(eax) - 1); /* 0x3100A458: dec al */
   6892     _flag_k = FK_NARROW(FK_DEC, 24);
   6893     MEM8(ecx + (-0x1)) = (uint8_t)(LO8(eax)); /* 0x3100A45A: mov byte ptr [ecx - 1], al */
   6894     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   6895     eax = 0; /* 0x3100A45D: xor eax, eax */
   6896     _cf = 0;
   6897     _flag_k = FK_TEST;
   6898     esi = POP32_VAL(esp); /* 0x3100A45F: pop esi */
   6899     ecx = MEM32(ebp + (-0xC)); /* 0x3100A460: mov ecx, dword ptr [ebp - 0xc] */
   6900     MEM32(FS_BASE + (0)) = ecx; /* 0x3100A463: mov dword ptr fs:[0], ecx */
   6901     esp = ebp; /* 0x3100A46A: mov esp, ebp */
   6902     ebp = POP32_VAL(esp); /* 0x3100A46C: pop ebp */
   6903     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A46D: ret  */
   6904 L_3100A46E:
   6905     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   6906     ecx = ecx - 1; /* 0x3100A46E: dec ecx */
   6907     _flag_k = FK_DEC;
   6908     PUSH32(esp, ecx); /* 0x3100A46F: push ecx */
   6909     RECOMP_ICALL(0x31046858u); /* 0x3100A470: call 0x31046858 */ /* not lifted */
   6910     RECOMP_FLAGS_IN();
   6911     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6912     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6913     esp = esp + 4; /* 0x3100A475: add esp, 4 */
   6914     _flag_k = FK_ADD;
   6915 L_3100A478:
   6916     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   6917     eax = 0; /* 0x3100A478: xor eax, eax */
   6918     _cf = 0;
   6919     _flag_k = FK_TEST;
   6920     esi = POP32_VAL(esp); /* 0x3100A47A: pop esi */
   6921     ecx = MEM32(ebp + (-0xC)); /* 0x3100A47B: mov ecx, dword ptr [ebp - 0xc] */
   6922     MEM32(FS_BASE + (0)) = ecx; /* 0x3100A47E: mov dword ptr fs:[0], ecx */
   6923     esp = ebp; /* 0x3100A485: mov esp, ebp */
   6924     ebp = POP32_VAL(esp); /* 0x3100A487: pop ebp */
   6925     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A488: ret  */
   6926 L_3100A489:
   6927     PUSH32(esp, 0x38u); /* 0x3100A489: push 0x38 */
   6928     RECOMP_ICALL(0x310468DAu); /* 0x3100A48B: call 0x310468da */ /* not lifted */
   6929     RECOMP_FLAGS_IN();
   6930     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6931     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6932     esp = esp + 4; /* 0x3100A490: add esp, 4 */
   6933     _flag_k = FK_ADD;
   6934     MEM32(ebp + 0x8) = eax; /* 0x3100A493: mov dword ptr [ebp + 8], eax */
   6935     /* test eax, eax */ /* 0x3100A496: test eax, eax */
   6936     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   6937     _cf = 0;
   6938     _flag_k = FK_TEST;
   6939     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3100A498: mov byte ptr [ebp - 4], 1 */
   6940     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A4AE; /* 0x3100A49C: je 0x3100a4ae */
   6941 L_3100A49E:
   6942     edx = MEM32(ebp + 0xC); /* 0x3100A49E: mov edx, dword ptr [ebp + 0xc] */
   6943     PUSH32(esp, edx); /* 0x3100A4A1: push edx */
   6944     PUSH32(esp, esi); /* 0x3100A4A2: push esi */
   6945     ecx = eax; /* 0x3100A4A3: mov ecx, eax */
   6946     RECOMP_ICALL(0x3100A500u); /* 0x3100A4A5: call 0x3100a500 */ /* not lifted */
   6947     RECOMP_FLAGS_IN();
   6948     esi = eax; /* 0x3100A4AA: mov esi, eax */
   6949     goto L_3100A4B0; /* 0x3100A4AC: jmp 0x3100a4b0 */
   6950 L_3100A4AE:
   6951     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   6952     esi = 0; /* 0x3100A4AE: xor esi, esi */
   6953     _cf = 0;
   6954     _flag_k = FK_TEST;
   6955 L_3100A4B0:
   6956     ecx = MEM32(ebp + (-0x18)); /* 0x3100A4B0: mov ecx, dword ptr [ebp - 0x18] */
   6957     /* test ecx, ecx */ /* 0x3100A4B3: test ecx, ecx */
   6958     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   6959     _cf = 0;
   6960     _flag_k = FK_TEST;
   6961     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A4E2; /* 0x3100A4B5: je 0x3100a4e2 */
   6962 L_3100A4B7:
   6963     SET_LO8(eax, MEM8(ecx + (-0x1))); /* 0x3100A4B7: mov al, byte ptr [ecx - 1] */
   6964     /* test LO8(eax), LO8(eax) */ /* 0x3100A4BA: test al, al */
   6965     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   6966     _cf = 0;
   6967     _flag_k = FK_NARROW(FK_TEST, 24);
   6968     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A4D8; /* 0x3100A4BC: je 0x3100a4d8 */
   6969 L_3100A4BE:
   6970     /* cmp LO8(eax), 0xFFu */ /* 0x3100A4BE: cmp al, 0xff */
   6971     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   6972     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   6973     _flag_k = FK_NARROW(FK_CMP, 24);
   6974     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A4D8; /* 0x3100A4C0: je 0x3100a4d8 */
   6975 L_3100A4C2:
   6976     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   6977     SET_LO8(eax, LO8(eax) - 1); /* 0x3100A4C2: dec al */
   6978     _flag_k = FK_NARROW(FK_DEC, 24);
   6979     MEM8(ecx + (-0x1)) = (uint8_t)(LO8(eax)); /* 0x3100A4C4: mov byte ptr [ecx - 1], al */
   6980     eax = esi; /* 0x3100A4C7: mov eax, esi */
   6981     esi = POP32_VAL(esp); /* 0x3100A4C9: pop esi */
   6982     ecx = MEM32(ebp + (-0xC)); /* 0x3100A4CA: mov ecx, dword ptr [ebp - 0xc] */
   6983     MEM32(FS_BASE + (0)) = ecx; /* 0x3100A4CD: mov dword ptr fs:[0], ecx */
   6984     esp = ebp; /* 0x3100A4D4: mov esp, ebp */
   6985     ebp = POP32_VAL(esp); /* 0x3100A4D6: pop ebp */
   6986     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A4D7: ret  */
   6987 L_3100A4D8:
   6988     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   6989     ecx = ecx - 1; /* 0x3100A4D8: dec ecx */
   6990     _flag_k = FK_DEC;
   6991     PUSH32(esp, ecx); /* 0x3100A4D9: push ecx */
   6992     RECOMP_ICALL(0x31046858u); /* 0x3100A4DA: call 0x31046858 */ /* not lifted */
   6993     RECOMP_FLAGS_IN();
   6994     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   6995     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   6996     esp = esp + 4; /* 0x3100A4DF: add esp, 4 */
   6997     _flag_k = FK_ADD;
   6998 L_3100A4E2:
   6999     ecx = MEM32(ebp + (-0xC)); /* 0x3100A4E2: mov ecx, dword ptr [ebp - 0xc] */
   7000     eax = esi; /* 0x3100A4E5: mov eax, esi */
   7001     esi = POP32_VAL(esp); /* 0x3100A4E7: pop esi */
   7002     MEM32(FS_BASE + (0)) = ecx; /* 0x3100A4E8: mov dword ptr fs:[0], ecx */
   7003     esp = ebp; /* 0x3100A4EF: mov esp, ebp */
   7004     ebp = POP32_VAL(esp); /* 0x3100A4F1: pop ebp */
   7005     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A4F2: ret  */
   7006     RECOMP_REGS_OUT();
   7007 }
   7008 
   7009 void sub_3100A500(void) {
   7010     int _fpu_cmp = 0;
   7011     uint32_t _cf = 0;
   7012     int _df = 1;
   7013     uint32_t _flag_k = FK_NONE;
   7014     uint32_t _flag_a = 0, _flag_b = 0;
   7015     uint32_t _itail_tgt = 0;
   7016     RECOMP_REGS_LOCALS
   7017     RECOMP_ENTER(0x3100A500u);
   7018 
   7019 L_3100A500:
   7020     PUSH32(esp, ebp); /* 0x3100A500: push ebp */
   7021     ebp = esp; /* 0x3100A501: mov ebp, esp */
   7022     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100A503: push -1 */
   7023     PUSH32(esp, 0x310473ACu); /* 0x3100A505: push 0x310473ac */
   7024     eax = MEM32(FS_BASE + (0)); /* 0x3100A50A: mov eax, dword ptr fs:[0] */
   7025     PUSH32(esp, eax); /* 0x3100A510: push eax */
   7026     MEM32(FS_BASE + (0)) = esp; /* 0x3100A511: mov dword ptr fs:[0], esp */
   7027     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x14u);
   7028     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7029     esp = esp - 0x14u; /* 0x3100A518: sub esp, 0x14 */
   7030     _flag_k = FK_CMP;
   7031     eax = MEM32(ebp + 0x8); /* 0x3100A51B: mov eax, dword ptr [ebp + 8] */
   7032     PUSH32(esp, esi); /* 0x3100A51E: push esi */
   7033     PUSH32(esp, edi); /* 0x3100A51F: push edi */
   7034     esi = ecx; /* 0x3100A520: mov esi, ecx */
   7035     PUSH32(esp, eax); /* 0x3100A522: push eax */
   7036     MEM32(ebp + (-0x10)) = esi; /* 0x3100A523: mov dword ptr [ebp - 0x10], esi */
   7037     RECOMP_ICALL(0x3100A060u); /* 0x3100A526: call 0x3100a060 */ /* not lifted */
   7038     RECOMP_FLAGS_IN();
   7039     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   7040     edi = 0; /* 0x3100A52B: xor edi, edi */
   7041     _cf = 0;
   7042     _flag_k = FK_TEST;
   7043     ecx = esi; /* 0x3100A52D: mov ecx, esi */
   7044     MEM32(ebp + (-0x4)) = edi; /* 0x3100A52F: mov dword ptr [ebp - 4], edi */
   7045     MEM32(esi + 0x30) = edi; /* 0x3100A532: mov dword ptr [esi + 0x30], edi */
   7046     MEM32(esi) = 0x31048674u; /* 0x3100A535: mov dword ptr [esi], 0x31048674 */
   7047     RECOMP_ICALL(0x31008F90u); /* 0x3100A53B: call 0x31008f90 */ /* not lifted */
   7048     RECOMP_FLAGS_IN();
   7049     PUSH32(esp, 0x3105219Cu); /* 0x3100A540: push 0x3105219c */
   7050     ecx = esi + 0x4; /* 0x3100A545: lea ecx, [esi + 4] */
   7051     PUSH32(esp, ecx); /* 0x3100A548: push ecx */
   7052     edx = ebp + (-0x20); /* 0x3100A549: lea edx, [ebp - 0x20] */
   7053     PUSH32(esp, edx); /* 0x3100A54C: push edx */
   7054     RECOMP_ICALL(0x3104686Au); /* 0x3100A54D: call 0x3104686a */ /* not lifted */
   7055     RECOMP_FLAGS_IN();
   7056     PUSH32(esp, 0x1B4u); /* 0x3100A552: push 0x1b4 */
   7057     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3100A557: mov byte ptr [ebp - 4], 1 */
   7058     RECOMP_ICALL(0x310468DAu); /* 0x3100A55B: call 0x310468da */ /* not lifted */
   7059     RECOMP_FLAGS_IN();
   7060     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x10u);
   7061     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7062     esp = esp + 0x10u; /* 0x3100A560: add esp, 0x10 */
   7063     _flag_k = FK_ADD;
   7064     MEM32(ebp + 0x8) = eax; /* 0x3100A563: mov dword ptr [ebp + 8], eax */
   7065     /* cmp eax, edi */ /* 0x3100A566: cmp eax, edi */
   7066     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
   7067     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7068     _flag_k = FK_CMP;
   7069     MEM8(ebp + (-0x4)) = (uint8_t)(2); /* 0x3100A568: mov byte ptr [ebp - 4], 2 */
   7070     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A579; /* 0x3100A56C: je 0x3100a579 */
   7071 L_3100A56E:
   7072     PUSH32(esp, 1); /* 0x3100A56E: push 1 */
   7073     ecx = eax; /* 0x3100A570: mov ecx, eax */
   7074     RECOMP_ICALL(0x31001950u); /* 0x3100A572: call 0x31001950 */ /* not lifted */
   7075     RECOMP_FLAGS_IN();
   7076     goto L_3100A57B; /* 0x3100A577: jmp 0x3100a57b */
   7077 L_3100A579:
   7078     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   7079     eax = 0; /* 0x3100A579: xor eax, eax */
   7080     _cf = 0;
   7081     _flag_k = FK_TEST;
   7082 L_3100A57B:
   7083     edi = MEM32(ebp + (-0x1C)); /* 0x3100A57B: mov edi, dword ptr [ebp - 0x1c] */
   7084     /* test edi, edi */ /* 0x3100A57E: test edi, edi */
   7085     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
   7086     _cf = 0;
   7087     _flag_k = FK_TEST;
   7088     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3100A580: mov byte ptr [ebp - 4], 1 */
   7089     MEM32(esi + 0x34) = eax; /* 0x3100A584: mov dword ptr [esi + 0x34], eax */
   7090     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100A58F; /* 0x3100A587: jne 0x3100a58f */
   7091 L_3100A589:
   7092     edi = MEM32(0x310480EC); /* 0x3100A589: mov edi, dword ptr [0x310480ec] */
   7093 L_3100A58F:
   7094     edx = MEM32(ebp + 0xC); /* 0x3100A58F: mov edx, dword ptr [ebp + 0xc] */
   7095     ecx = edx; /* 0x3100A592: mov ecx, edx */
   7096     if (1u) _cf = (((ecx) >> 0) & 1u); /* 0x3100A594: shr ecx, 1 */
   7097     if (1u) { _flag_a = recomp_flags_pack((ecx >> 1u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
   7098     ecx = ecx >> 1u; /* 0x3100A594: shr ecx, 1 */
   7099     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0xFFFFFF01u);
   7100     ecx = ecx & 0xFFFFFF01u; /* 0x3100A596: and ecx, 0xffffff01 */
   7101     _cf = 0;
   7102     _flag_k = FK_TEST;
   7103     PUSH32(esp, ecx); /* 0x3100A59C: push ecx */
   7104     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(0xFFFFFF01u);
   7105     edx = edx & 0xFFFFFF01u; /* 0x3100A59D: and edx, 0xffffff01 */
   7106     _cf = 0;
   7107     _flag_k = FK_TEST;
   7108     PUSH32(esp, edx); /* 0x3100A5A3: push edx */
   7109     PUSH32(esp, edi); /* 0x3100A5A4: push edi */
   7110     ecx = eax; /* 0x3100A5A5: mov ecx, eax */
   7111     RECOMP_ICALL(0x31001BE0u); /* 0x3100A5A7: call 0x31001be0 */ /* not lifted */
   7112     RECOMP_FLAGS_IN();
   7113     ecx = MEM32(ebp + (-0x1C)); /* 0x3100A5AC: mov ecx, dword ptr [ebp - 0x1c] */
   7114     /* test ecx, ecx */ /* 0x3100A5AF: test ecx, ecx */
   7115     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   7116     _cf = 0;
   7117     _flag_k = FK_TEST;
   7118     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A5E1; /* 0x3100A5B1: je 0x3100a5e1 */
   7119 L_3100A5B3:
   7120     SET_LO8(eax, MEM8(ecx + (-0x1))); /* 0x3100A5B3: mov al, byte ptr [ecx - 1] */
   7121     /* test LO8(eax), LO8(eax) */ /* 0x3100A5B6: test al, al */
   7122     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   7123     _cf = 0;
   7124     _flag_k = FK_NARROW(FK_TEST, 24);
   7125     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A5D7; /* 0x3100A5B8: je 0x3100a5d7 */
   7126 L_3100A5BA:
   7127     /* cmp LO8(eax), 0xFFu */ /* 0x3100A5BA: cmp al, 0xff */
   7128     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   7129     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7130     _flag_k = FK_NARROW(FK_CMP, 24);
   7131     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A5D7; /* 0x3100A5BC: je 0x3100a5d7 */
   7132 L_3100A5BE:
   7133     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   7134     SET_LO8(eax, LO8(eax) - 1); /* 0x3100A5BE: dec al */
   7135     _flag_k = FK_NARROW(FK_DEC, 24);
   7136     MEM8(ecx + (-0x1)) = (uint8_t)(LO8(eax)); /* 0x3100A5C0: mov byte ptr [ecx - 1], al */
   7137     edi = POP32_VAL(esp); /* 0x3100A5C3: pop edi */
   7138     eax = esi; /* 0x3100A5C4: mov eax, esi */
   7139     esi = POP32_VAL(esp); /* 0x3100A5C6: pop esi */
   7140     ecx = MEM32(ebp + (-0xC)); /* 0x3100A5C7: mov ecx, dword ptr [ebp - 0xc] */
   7141     MEM32(FS_BASE + (0)) = ecx; /* 0x3100A5CA: mov dword ptr fs:[0], ecx */
   7142     esp = ebp; /* 0x3100A5D1: mov esp, ebp */
   7143     ebp = POP32_VAL(esp); /* 0x3100A5D3: pop ebp */
   7144     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100A5D4: ret 8 */
   7145 L_3100A5D7:
   7146     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   7147     ecx = ecx - 1; /* 0x3100A5D7: dec ecx */
   7148     _flag_k = FK_DEC;
   7149     PUSH32(esp, ecx); /* 0x3100A5D8: push ecx */
   7150     RECOMP_ICALL(0x31046858u); /* 0x3100A5D9: call 0x31046858 */ /* not lifted */
   7151     RECOMP_FLAGS_IN();
   7152     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   7153     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7154     esp = esp + 4; /* 0x3100A5DE: add esp, 4 */
   7155     _flag_k = FK_ADD;
   7156 L_3100A5E1:
   7157     ecx = MEM32(ebp + (-0xC)); /* 0x3100A5E1: mov ecx, dword ptr [ebp - 0xc] */
   7158     edi = POP32_VAL(esp); /* 0x3100A5E4: pop edi */
   7159     eax = esi; /* 0x3100A5E5: mov eax, esi */
   7160     esi = POP32_VAL(esp); /* 0x3100A5E7: pop esi */
   7161     MEM32(FS_BASE + (0)) = ecx; /* 0x3100A5E8: mov dword ptr fs:[0], ecx */
   7162     esp = ebp; /* 0x3100A5EF: mov esp, ebp */
   7163     ebp = POP32_VAL(esp); /* 0x3100A5F1: pop ebp */
   7164     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100A5F2: ret 8 */
   7165     RECOMP_REGS_OUT();
   7166 }
   7167 
   7168 void sub_3100A600(void) {
   7169     int _fpu_cmp = 0;
   7170     uint32_t _cf = 0;
   7171     int _df = 1;
   7172     uint32_t _flag_k = FK_NONE;
   7173     uint32_t _flag_a = 0, _flag_b = 0;
   7174     uint32_t _itail_tgt = 0;
   7175     RECOMP_REGS_LOCALS
   7176     RECOMP_ENTER(0x3100A600u);
   7177 
   7178 L_3100A600:
   7179     PUSH32(esp, ebp); /* 0x3100A600: push ebp */
   7180     ebp = esp; /* 0x3100A601: mov ebp, esp */
   7181     PUSH32(esp, esi); /* 0x3100A603: push esi */
   7182     esi = ecx; /* 0x3100A604: mov esi, ecx */
   7183     RECOMP_ICALL(0x3100A630u); /* 0x3100A606: call 0x3100a630 */ /* not lifted */
   7184     RECOMP_FLAGS_IN();
   7185     /* test MEM8(ebp + 0x8), 1 */ /* 0x3100A60B: test byte ptr [ebp + 8], 1 */
   7186     _flag_a = (uint32_t)(MEM8(ebp + 0x8)) << 24; _flag_b = (uint32_t)(1) << 24;
   7187     _cf = 0;
   7188     _flag_k = FK_NARROW(FK_TEST, 24);
   7189     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A61A; /* 0x3100A60F: je 0x3100a61a */
   7190 L_3100A611:
   7191     PUSH32(esp, esi); /* 0x3100A611: push esi */
   7192     RECOMP_ICALL(0x31046858u); /* 0x3100A612: call 0x31046858 */ /* not lifted */
   7193     RECOMP_FLAGS_IN();
   7194     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   7195     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7196     esp = esp + 4; /* 0x3100A617: add esp, 4 */
   7197     _flag_k = FK_ADD;
   7198 L_3100A61A:
   7199     eax = esi; /* 0x3100A61A: mov eax, esi */
   7200     esi = POP32_VAL(esp); /* 0x3100A61C: pop esi */
   7201     ebp = POP32_VAL(esp); /* 0x3100A61D: pop ebp */
   7202     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100A61E: ret 4 */
   7203     RECOMP_REGS_OUT();
   7204 }
   7205 
   7206 void sub_3100A630(void) {
   7207     int _fpu_cmp = 0;
   7208     uint32_t _cf = 0;
   7209     int _df = 1;
   7210     uint32_t _flag_k = FK_NONE;
   7211     uint32_t _flag_a = 0, _flag_b = 0;
   7212     uint32_t _itail_tgt = 0;
   7213     RECOMP_REGS_LOCALS
   7214     RECOMP_ENTER(0x3100A630u);
   7215 
   7216 L_3100A630:
   7217     PUSH32(esp, ebp); /* 0x3100A630: push ebp */
   7218     ebp = esp; /* 0x3100A631: mov ebp, esp */
   7219     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100A633: push -1 */
   7220     PUSH32(esp, 0x310473C8u); /* 0x3100A635: push 0x310473c8 */
   7221     eax = MEM32(FS_BASE + (0)); /* 0x3100A63A: mov eax, dword ptr fs:[0] */
   7222     PUSH32(esp, eax); /* 0x3100A640: push eax */
   7223     MEM32(FS_BASE + (0)) = esp; /* 0x3100A641: mov dword ptr fs:[0], esp */
   7224     PUSH32(esp, ecx); /* 0x3100A648: push ecx */
   7225     PUSH32(esp, esi); /* 0x3100A649: push esi */
   7226     esi = ecx; /* 0x3100A64A: mov esi, ecx */
   7227     PUSH32(esp, edi); /* 0x3100A64C: push edi */
   7228     MEM32(ebp + (-0x10)) = esi; /* 0x3100A64D: mov dword ptr [ebp - 0x10], esi */
   7229     MEM32(esi) = 0x31048674u; /* 0x3100A650: mov dword ptr [esi], 0x31048674 */
   7230     ecx = MEM32(esi + 0x34); /* 0x3100A656: mov ecx, dword ptr [esi + 0x34] */
   7231     /* test ecx, ecx */ /* 0x3100A659: test ecx, ecx */
   7232     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   7233     _cf = 0;
   7234     _flag_k = FK_TEST;
   7235     MEM32(ebp + (-0x4)) = 0; /* 0x3100A65B: mov dword ptr [ebp - 4], 0 */
   7236     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A66A; /* 0x3100A662: je 0x3100a66a */
   7237 L_3100A664:
   7238     eax = MEM32(ecx); /* 0x3100A664: mov eax, dword ptr [ecx] */
   7239     PUSH32(esp, 1); /* 0x3100A666: push 1 */
   7240     RECOMP_ICALL(MEM32(eax)); /* 0x3100A668: call dword ptr [eax] */
   7241     RECOMP_FLAGS_IN();
   7242 L_3100A66A:
   7243     edi = MEM32(esi + 0x30); /* 0x3100A66A: mov edi, dword ptr [esi + 0x30] */
   7244     /* test edi, edi */ /* 0x3100A66D: test edi, edi */
   7245     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
   7246     _cf = 0;
   7247     _flag_k = FK_TEST;
   7248     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A681; /* 0x3100A66F: je 0x3100a681 */
   7249 L_3100A671:
   7250     ecx = edi; /* 0x3100A671: mov ecx, edi */
   7251     RECOMP_ICALL(0x310013E0u); /* 0x3100A673: call 0x310013e0 */ /* not lifted */
   7252     RECOMP_FLAGS_IN();
   7253     PUSH32(esp, edi); /* 0x3100A678: push edi */
   7254     RECOMP_ICALL(0x31046858u); /* 0x3100A679: call 0x31046858 */ /* not lifted */
   7255     RECOMP_FLAGS_IN();
   7256     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   7257     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7258     esp = esp + 4; /* 0x3100A67E: add esp, 4 */
   7259     _flag_k = FK_ADD;
   7260 L_3100A681:
   7261     ecx = esi; /* 0x3100A681: mov ecx, esi */
   7262     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100A683: mov dword ptr [ebp - 4], 0xffffffff */
   7263     RECOMP_ICALL(0x3100A2B0u); /* 0x3100A68A: call 0x3100a2b0 */ /* not lifted */
   7264     RECOMP_FLAGS_IN();
   7265     ecx = MEM32(ebp + (-0xC)); /* 0x3100A68F: mov ecx, dword ptr [ebp - 0xc] */
   7266     edi = POP32_VAL(esp); /* 0x3100A692: pop edi */
   7267     esi = POP32_VAL(esp); /* 0x3100A693: pop esi */
   7268     MEM32(FS_BASE + (0)) = ecx; /* 0x3100A694: mov dword ptr fs:[0], ecx */
   7269     esp = ebp; /* 0x3100A69B: mov esp, ebp */
   7270     ebp = POP32_VAL(esp); /* 0x3100A69D: pop ebp */
   7271     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A69E: ret  */
   7272     RECOMP_REGS_OUT();
   7273 }
   7274 
   7275 void sub_3100A6A0(void) {
   7276     int _fpu_cmp = 0;
   7277     uint32_t _cf = 0;
   7278     int _df = 1;
   7279     uint32_t _flag_k = FK_NONE;
   7280     uint32_t _flag_a = 0, _flag_b = 0;
   7281     uint32_t _itail_tgt = 0;
   7282     RECOMP_REGS_LOCALS
   7283     RECOMP_ENTER(0x3100A6A0u);
   7284 
   7285 L_3100A6A0:
   7286     PUSH32(esp, esi); /* 0x3100A6A0: push esi */
   7287     esi = ecx; /* 0x3100A6A1: mov esi, ecx */
   7288     ecx = MEM32(esi + 0x34); /* 0x3100A6A3: mov ecx, dword ptr [esi + 0x34] */
   7289     PUSH32(esp, edi); /* 0x3100A6A6: push edi */
   7290     RECOMP_ICALL(0x31001CD0u); /* 0x3100A6A7: call 0x31001cd0 */ /* not lifted */
   7291     RECOMP_FLAGS_IN();
   7292     edi = MEM32(esi + 0x30); /* 0x3100A6AC: mov edi, dword ptr [esi + 0x30] */
   7293     /* test edi, edi */ /* 0x3100A6AF: test edi, edi */
   7294     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
   7295     _cf = 0;
   7296     _flag_k = FK_TEST;
   7297     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A6C3; /* 0x3100A6B1: je 0x3100a6c3 */
   7298 L_3100A6B3:
   7299     ecx = edi; /* 0x3100A6B3: mov ecx, edi */
   7300     RECOMP_ICALL(0x310013E0u); /* 0x3100A6B5: call 0x310013e0 */ /* not lifted */
   7301     RECOMP_FLAGS_IN();
   7302     PUSH32(esp, edi); /* 0x3100A6BA: push edi */
   7303     RECOMP_ICALL(0x31046858u); /* 0x3100A6BB: call 0x31046858 */ /* not lifted */
   7304     RECOMP_FLAGS_IN();
   7305     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   7306     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7307     esp = esp + 4; /* 0x3100A6C0: add esp, 4 */
   7308     _flag_k = FK_ADD;
   7309 L_3100A6C3:
   7310     edi = POP32_VAL(esp); /* 0x3100A6C3: pop edi */
   7311     MEM32(esi + 0x30) = 0; /* 0x3100A6C4: mov dword ptr [esi + 0x30], 0 */
   7312     esi = POP32_VAL(esp); /* 0x3100A6CB: pop esi */
   7313     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100A6CC: ret  */
   7314     RECOMP_REGS_OUT();
   7315 }
   7316 
   7317 void sub_3100A6D0(void) {
   7318     int _fpu_cmp = 0;
   7319     uint32_t _cf = 0;
   7320     int _df = 1;
   7321     uint32_t _flag_k = FK_NONE;
   7322     uint32_t _flag_a = 0, _flag_b = 0;
   7323     uint32_t _itail_tgt = 0;
   7324     RECOMP_REGS_LOCALS
   7325     RECOMP_ENTER(0x3100A6D0u);
   7326 
   7327 L_3100A6D0:
   7328     PUSH32(esp, ebp); /* 0x3100A6D0: push ebp */
   7329     ebp = esp; /* 0x3100A6D1: mov ebp, esp */
   7330     PUSH32(esp, esi); /* 0x3100A6D3: push esi */
   7331     PUSH32(esp, edi); /* 0x3100A6D4: push edi */
   7332     esi = ecx; /* 0x3100A6D5: mov esi, ecx */
   7333     ecx = MEM32(esi + 0x34); /* 0x3100A6D7: mov ecx, dword ptr [esi + 0x34] */
   7334     PUSH32(esp, 2); /* 0x3100A6DA: push 2 */
   7335     RECOMP_ICALL(0x31002960u); /* 0x3100A6DC: call 0x31002960 */ /* not lifted */
   7336     RECOMP_FLAGS_IN();
   7337     eax = MEM32(ebp + 0xC); /* 0x3100A6E1: mov eax, dword ptr [ebp + 0xc] */
   7338     eax = MEM32(eax); /* 0x3100A6E4: mov eax, dword ptr [eax] */
   7339     /* cmp MEM32(eax), 0x80000000u */ /* 0x3100A6E6: cmp dword ptr [eax], 0x80000000 */
   7340     _flag_a = (uint32_t)(MEM32(eax)); _flag_b = (uint32_t)(0x80000000u);
   7341     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7342     _flag_k = FK_CMP;
   7343     edi = eax + 0x8; /* 0x3100A6EC: lea edi, [eax + 8] */
   7344     if (CMP_B(_flag_a, _flag_b)) goto L_3100A6F4; /* 0x3100A6EF: jb 0x3100a6f4 */
   7345 L_3100A6F1:
   7346     edi = MEM32(eax + 0x8); /* 0x3100A6F1: mov edi, dword ptr [eax + 8] */
   7347 L_3100A6F4:
   7348     eax = MEM32(eax + 0x4); /* 0x3100A6F4: mov eax, dword ptr [eax + 4] */
   7349     ecx = MEM32(ebp + 0x8); /* 0x3100A6F7: mov ecx, dword ptr [ebp + 8] */
   7350     edx = MEM32(ecx + 0xC); /* 0x3100A6FA: mov edx, dword ptr [ecx + 0xc] */
   7351     ecx = MEM32(ecx + 0x8); /* 0x3100A6FD: mov ecx, dword ptr [ecx + 8] */
   7352     PUSH32(esp, edi); /* 0x3100A700: push edi */
   7353     PUSH32(esp, eax); /* 0x3100A701: push eax */
   7354     PUSH32(esp, edx); /* 0x3100A702: push edx */
   7355     PUSH32(esp, ecx); /* 0x3100A703: push ecx */
   7356     ecx = MEM32(esi + 0x34); /* 0x3100A704: mov ecx, dword ptr [esi + 0x34] */
   7357     RECOMP_ICALL(0x31003410u); /* 0x3100A707: call 0x31003410 */ /* not lifted */
   7358     RECOMP_FLAGS_IN();
   7359     ecx = MEM32(esi + 0x34); /* 0x3100A70C: mov ecx, dword ptr [esi + 0x34] */
   7360     edi = eax; /* 0x3100A70F: mov edi, eax */
   7361     RECOMP_ICALL(0x310029E0u); /* 0x3100A711: call 0x310029e0 */ /* not lifted */
   7362     RECOMP_FLAGS_IN();
   7363     eax = edi; /* 0x3100A716: mov eax, edi */
   7364     edi = POP32_VAL(esp); /* 0x3100A718: pop edi */
   7365     esi = POP32_VAL(esp); /* 0x3100A719: pop esi */
   7366     ebp = POP32_VAL(esp); /* 0x3100A71A: pop ebp */
   7367     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100A71B: ret 8 */
   7368     RECOMP_REGS_OUT();
   7369 }
   7370 
   7371 void sub_3100A720(void) {
   7372     int _fpu_cmp = 0;
   7373     uint32_t _cf = 0;
   7374     int _df = 1;
   7375     uint32_t _flag_k = FK_NONE;
   7376     uint32_t _flag_a = 0, _flag_b = 0;
   7377     uint32_t _itail_tgt = 0;
   7378     RECOMP_REGS_LOCALS
   7379     RECOMP_ENTER(0x3100A720u);
   7380 
   7381 L_3100A720:
   7382     PUSH32(esp, ebp); /* 0x3100A720: push ebp */
   7383     ebp = esp; /* 0x3100A721: mov ebp, esp */
   7384     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100A723: push -1 */
   7385     PUSH32(esp, 0x310473FFu); /* 0x3100A725: push 0x310473ff */
   7386     eax = MEM32(FS_BASE + (0)); /* 0x3100A72A: mov eax, dword ptr fs:[0] */
   7387     PUSH32(esp, eax); /* 0x3100A730: push eax */
   7388     MEM32(FS_BASE + (0)) = esp; /* 0x3100A731: mov dword ptr fs:[0], esp */
   7389     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   7390     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7391     esp = esp - 8; /* 0x3100A738: sub esp, 8 */
   7392     _flag_k = FK_CMP;
   7393     PUSH32(esp, ebx); /* 0x3100A73B: push ebx */
   7394     PUSH32(esp, esi); /* 0x3100A73C: push esi */
   7395     esi = ecx; /* 0x3100A73D: mov esi, ecx */
   7396     ecx = MEM32(esi + 0x34); /* 0x3100A73F: mov ecx, dword ptr [esi + 0x34] */
   7397     PUSH32(esp, 1); /* 0x3100A742: push 1 */
   7398     MEM32(ebp + (-0x14)) = 0; /* 0x3100A744: mov dword ptr [ebp - 0x14], 0 */
   7399     RECOMP_ICALL(0x31002960u); /* 0x3100A74B: call 0x31002960 */ /* not lifted */
   7400     RECOMP_FLAGS_IN();
   7401     eax = MEM32(ebp + 0xC); /* 0x3100A750: mov eax, dword ptr [ebp + 0xc] */
   7402     ecx = MEM32(eax + 0xC); /* 0x3100A753: mov ecx, dword ptr [eax + 0xc] */
   7403     eax = MEM32(eax + 0x8); /* 0x3100A756: mov eax, dword ptr [eax + 8] */
   7404     PUSH32(esp, ecx); /* 0x3100A759: push ecx */
   7405     ecx = MEM32(esi + 0x34); /* 0x3100A75A: mov ecx, dword ptr [esi + 0x34] */
   7406     PUSH32(esp, eax); /* 0x3100A75D: push eax */
   7407     eax = ebp + (-0x10); /* 0x3100A75E: lea eax, [ebp - 0x10] */
   7408     PUSH32(esp, eax); /* 0x3100A761: push eax */
   7409     RECOMP_ICALL(0x31003080u); /* 0x3100A762: call 0x31003080 */ /* not lifted */
   7410     RECOMP_FLAGS_IN();
   7411     ecx = MEM32(esi + 0x34); /* 0x3100A767: mov ecx, dword ptr [esi + 0x34] */
   7412     MEM32(ebp + (-0x4)) = 1; /* 0x3100A76A: mov dword ptr [ebp - 4], 1 */
   7413     RECOMP_ICALL(0x310029E0u); /* 0x3100A771: call 0x310029e0 */ /* not lifted */
   7414     RECOMP_FLAGS_IN();
   7415     ecx = MEM32(ebp + (-0x10)); /* 0x3100A776: mov ecx, dword ptr [ebp - 0x10] */
   7416     MEM32(ebp + 0xC) = ecx; /* 0x3100A779: mov dword ptr [ebp + 0xc], ecx */
   7417     ebx = MEM32(ebp + 0xC); /* 0x3100A77C: mov ebx, dword ptr [ebp + 0xc] */
   7418     _flag_a = __atomic_fetch_add((uint32_t *)ADDR(ebx), 1, __ATOMIC_SEQ_CST); _flag_b = 1; /* 0x3100A77F: lock inc dword ptr [ebx] */
   7419     _flag_k = FK_INC;
   7420     esi = MEM32(ebp + 0x8); /* 0x3100A782: mov esi, dword ptr [ebp + 8] */
   7421     edx = MEM32(ebp + (-0x10)); /* 0x3100A785: mov edx, dword ptr [ebp - 0x10] */
   7422     MEM32(esi) = edx; /* 0x3100A788: mov dword ptr [esi], edx */
   7423     MEM32(ebp + (-0x14)) = 1; /* 0x3100A78A: mov dword ptr [ebp - 0x14], 1 */
   7424     ecx = ebp + (-0x10); /* 0x3100A791: lea ecx, [ebp - 0x10] */
   7425     MEM8(ebp + (-0x4)) = (uint8_t)(0); /* 0x3100A794: mov byte ptr [ebp - 4], 0 */
   7426     RECOMP_ICALL(0x31004760u); /* 0x3100A798: call 0x31004760 */ /* not lifted */
   7427     RECOMP_FLAGS_IN();
   7428     ecx = MEM32(ebp + (-0xC)); /* 0x3100A79D: mov ecx, dword ptr [ebp - 0xc] */
   7429     eax = esi; /* 0x3100A7A0: mov eax, esi */
   7430     esi = POP32_VAL(esp); /* 0x3100A7A2: pop esi */
   7431     ebx = POP32_VAL(esp); /* 0x3100A7A3: pop ebx */
   7432     MEM32(FS_BASE + (0)) = ecx; /* 0x3100A7A4: mov dword ptr fs:[0], ecx */
   7433     esp = ebp; /* 0x3100A7AB: mov esp, ebp */
   7434     ebp = POP32_VAL(esp); /* 0x3100A7AD: pop ebp */
   7435     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100A7AE: ret 8 */
   7436     RECOMP_REGS_OUT();
   7437 }
   7438 
   7439 void sub_3100A7C0(void) {
   7440     int _fpu_cmp = 0;
   7441     uint32_t _cf = 0;
   7442     int _df = 1;
   7443     uint32_t _flag_k = FK_NONE;
   7444     uint32_t _flag_a = 0, _flag_b = 0;
   7445     uint32_t _itail_tgt = 0;
   7446     RECOMP_REGS_LOCALS
   7447     RECOMP_ENTER(0x3100A7C0u);
   7448 
   7449 L_3100A7C0:
   7450     PUSH32(esp, ebp); /* 0x3100A7C0: push ebp */
   7451     ebp = esp; /* 0x3100A7C1: mov ebp, esp */
   7452     PUSH32(esp, esi); /* 0x3100A7C3: push esi */
   7453     PUSH32(esp, edi); /* 0x3100A7C4: push edi */
   7454     esi = ecx; /* 0x3100A7C5: mov esi, ecx */
   7455     ecx = MEM32(esi + 0x34); /* 0x3100A7C7: mov ecx, dword ptr [esi + 0x34] */
   7456     PUSH32(esp, 2); /* 0x3100A7CA: push 2 */
   7457     RECOMP_ICALL(0x31002960u); /* 0x3100A7CC: call 0x31002960 */ /* not lifted */
   7458     RECOMP_FLAGS_IN();
   7459     eax = MEM32(ebp + 0x8); /* 0x3100A7D1: mov eax, dword ptr [ebp + 8] */
   7460     ecx = MEM32(eax + 0xC); /* 0x3100A7D4: mov ecx, dword ptr [eax + 0xc] */
   7461     eax = MEM32(eax + 0x8); /* 0x3100A7D7: mov eax, dword ptr [eax + 8] */
   7462     PUSH32(esp, ecx); /* 0x3100A7DA: push ecx */
   7463     ecx = MEM32(esi + 0x34); /* 0x3100A7DB: mov ecx, dword ptr [esi + 0x34] */
   7464     PUSH32(esp, eax); /* 0x3100A7DE: push eax */
   7465     RECOMP_ICALL(0x31003640u); /* 0x3100A7DF: call 0x31003640 */ /* not lifted */
   7466     RECOMP_FLAGS_IN();
   7467     ecx = MEM32(esi + 0x34); /* 0x3100A7E4: mov ecx, dword ptr [esi + 0x34] */
   7468     edi = eax; /* 0x3100A7E7: mov edi, eax */
   7469     RECOMP_ICALL(0x310029E0u); /* 0x3100A7E9: call 0x310029e0 */ /* not lifted */
   7470     RECOMP_FLAGS_IN();
   7471     eax = edi; /* 0x3100A7EE: mov eax, edi */
   7472     edi = POP32_VAL(esp); /* 0x3100A7F0: pop edi */
   7473     esi = POP32_VAL(esp); /* 0x3100A7F1: pop esi */
   7474     ebp = POP32_VAL(esp); /* 0x3100A7F2: pop ebp */
   7475     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100A7F3: ret 4 */
   7476     RECOMP_REGS_OUT();
   7477 }
   7478 
   7479 void sub_3100A800(void) {
   7480     int _fpu_cmp = 0;
   7481     uint32_t _cf = 0;
   7482     int _df = 1;
   7483     uint32_t _flag_k = FK_NONE;
   7484     uint32_t _flag_a = 0, _flag_b = 0;
   7485     uint32_t _itail_tgt = 0;
   7486     RECOMP_REGS_LOCALS
   7487     RECOMP_ENTER(0x3100A800u);
   7488 
   7489 L_3100A800:
   7490     PUSH32(esp, ebp); /* 0x3100A800: push ebp */
   7491     ebp = esp; /* 0x3100A801: mov ebp, esp */
   7492     PUSH32(esp, esi); /* 0x3100A803: push esi */
   7493     PUSH32(esp, edi); /* 0x3100A804: push edi */
   7494     esi = ecx; /* 0x3100A805: mov esi, ecx */
   7495     ecx = MEM32(esi + 0x34); /* 0x3100A807: mov ecx, dword ptr [esi + 0x34] */
   7496     PUSH32(esp, 1); /* 0x3100A80A: push 1 */
   7497     RECOMP_ICALL(0x31002960u); /* 0x3100A80C: call 0x31002960 */ /* not lifted */
   7498     RECOMP_FLAGS_IN();
   7499     eax = MEM32(ebp + 0x8); /* 0x3100A811: mov eax, dword ptr [ebp + 8] */
   7500     ecx = MEM32(eax + 0xC); /* 0x3100A814: mov ecx, dword ptr [eax + 0xc] */
   7501     eax = MEM32(eax + 0x8); /* 0x3100A817: mov eax, dword ptr [eax + 8] */
   7502     PUSH32(esp, ecx); /* 0x3100A81A: push ecx */
   7503     ecx = MEM32(esi + 0x34); /* 0x3100A81B: mov ecx, dword ptr [esi + 0x34] */
   7504     PUSH32(esp, eax); /* 0x3100A81E: push eax */
   7505     RECOMP_ICALL(0x31002C50u); /* 0x3100A81F: call 0x31002c50 */ /* not lifted */
   7506     RECOMP_FLAGS_IN();
   7507     ecx = MEM32(esi + 0x34); /* 0x3100A824: mov ecx, dword ptr [esi + 0x34] */
   7508     edi = eax; /* 0x3100A827: mov edi, eax */
   7509     RECOMP_ICALL(0x310029E0u); /* 0x3100A829: call 0x310029e0 */ /* not lifted */
   7510     RECOMP_FLAGS_IN();
   7511     eax = edi; /* 0x3100A82E: mov eax, edi */
   7512     edi = POP32_VAL(esp); /* 0x3100A830: pop edi */
   7513     esi = POP32_VAL(esp); /* 0x3100A831: pop esi */
   7514     ebp = POP32_VAL(esp); /* 0x3100A832: pop ebp */
   7515     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100A833: ret 4 */
   7516     RECOMP_REGS_OUT();
   7517 }
   7518 
   7519 void sub_3100A840(void) {
   7520     int _fpu_cmp = 0;
   7521     uint32_t _cf = 0;
   7522     int _df = 1;
   7523     uint32_t _flag_k = FK_NONE;
   7524     uint32_t _flag_a = 0, _flag_b = 0;
   7525     uint32_t _itail_tgt = 0;
   7526     RECOMP_REGS_LOCALS
   7527     RECOMP_ENTER(0x3100A840u);
   7528 
   7529 L_3100A840:
   7530     PUSH32(esp, ebp); /* 0x3100A840: push ebp */
   7531     ebp = esp; /* 0x3100A841: mov ebp, esp */
   7532     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x5Cu);
   7533     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7534     esp = esp - 0x5Cu; /* 0x3100A843: sub esp, 0x5c */
   7535     _flag_k = FK_CMP;
   7536     edx = MEM32(ebp + 0x8); /* 0x3100A846: mov edx, dword ptr [ebp + 8] */
   7537     PUSH32(esp, ebx); /* 0x3100A849: push ebx */
   7538     ebx = MEM32(ecx + 0x18); /* 0x3100A84A: mov ebx, dword ptr [ecx + 0x18] */
   7539     PUSH32(esp, esi); /* 0x3100A84D: push esi */
   7540     PUSH32(esp, edi); /* 0x3100A84E: push edi */
   7541     edi = ecx + 0x14; /* 0x3100A84F: lea edi, [ecx + 0x14] */
   7542     MEM32(ebp + (-0xC)) = ecx; /* 0x3100A852: mov dword ptr [ebp - 0xc], ecx */
   7543     ecx = MEM32(edi + 0x8); /* 0x3100A855: mov ecx, dword ptr [edi + 8] */
   7544     MEM32(ebp + (-0x24)) = edx; /* 0x3100A858: mov dword ptr [ebp - 0x24], edx */
   7545     MEM32(ebp + (-0x20)) = 0; /* 0x3100A85B: mov dword ptr [ebp - 0x20], 0 */
   7546     esi = MEM32(ebx + 0x4); /* 0x3100A862: mov esi, dword ptr [ebx + 4] */
   7547     /* cmp esi, ecx */ /* 0x3100A865: cmp esi, ecx */
   7548     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ecx);
   7549     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7550     _flag_k = FK_CMP;
   7551     SET_LO8(eax, 1); /* 0x3100A867: mov al, 1 */
   7552     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A882; /* 0x3100A869: je 0x3100a882 */
   7553 L_3100A86B:
   7554     /* cmp edx, MEM32(esi + 0xC) */ /* 0x3100A86B: cmp edx, dword ptr [esi + 0xc] */
   7555     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0xC));
   7556     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7557     _flag_k = FK_CMP;
   7558     SET_LO8(eax, (CMP_B(_flag_a, _flag_b)) ? 1 : 0); /* 0x3100A86E: setb al */
   7559     /* test LO8(eax), LO8(eax) */ /* 0x3100A871: test al, al */
   7560     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   7561     _cf = 0;
   7562     _flag_k = FK_NARROW(FK_TEST, 24);
   7563     ebx = esi; /* 0x3100A873: mov ebx, esi */
   7564     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A87B; /* 0x3100A875: je 0x3100a87b */
   7565 L_3100A877:
   7566     esi = MEM32(esi); /* 0x3100A877: mov esi, dword ptr [esi] */
   7567     goto L_3100A87E; /* 0x3100A879: jmp 0x3100a87e */
   7568 L_3100A87B:
   7569     esi = MEM32(esi + 0x8); /* 0x3100A87B: mov esi, dword ptr [esi + 8] */
   7570 L_3100A87E:
   7571     /* cmp esi, ecx */ /* 0x3100A87E: cmp esi, ecx */
   7572     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ecx);
   7573     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7574     _flag_k = FK_CMP;
   7575     RECOMP_BACKEDGE();
   7576     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A86B; /* 0x3100A880: jne 0x3100a86b */
   7577 L_3100A882:
   7578     SET_LO8(ecx, MEM8(edi + 0xC)); /* 0x3100A882: mov cl, byte ptr [edi + 0xc] */
   7579     /* test LO8(ecx), LO8(ecx) */ /* 0x3100A885: test cl, cl */
   7580     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24;
   7581     _cf = 0;
   7582     _flag_k = FK_NARROW(FK_TEST, 24);
   7583     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A8B7; /* 0x3100A887: je 0x3100a8b7 */
   7584 L_3100A889:
   7585     eax = ebp + 0xB; /* 0x3100A889: lea eax, [ebp + 0xb] */
   7586     PUSH32(esp, eax); /* 0x3100A88C: push eax */
   7587     ecx = ebp + (-0x24); /* 0x3100A88D: lea ecx, [ebp - 0x24] */
   7588     PUSH32(esp, ecx); /* 0x3100A890: push ecx */
   7589     PUSH32(esp, ebx); /* 0x3100A891: push ebx */
   7590     PUSH32(esp, esi); /* 0x3100A892: push esi */
   7591     edx = ebp + (-0x10); /* 0x3100A893: lea edx, [ebp - 0x10] */
   7592     PUSH32(esp, edx); /* 0x3100A896: push edx */
   7593     ecx = edi; /* 0x3100A897: mov ecx, edi */
   7594     MEM8(ebp + 0xB) = (uint8_t)(1); /* 0x3100A899: mov byte ptr [ebp + 0xb], 1 */
   7595     RECOMP_ICALL(0x3100AB20u); /* 0x3100A89D: call 0x3100ab20 */ /* not lifted */
   7596     RECOMP_FLAGS_IN();
   7597     PUSH32(esp, eax); /* 0x3100A8A2: push eax */
   7598     ecx = ebp + (-0x34); /* 0x3100A8A3: lea ecx, [ebp - 0x34] */
   7599     RECOMP_ICALL(0x3100AB00u); /* 0x3100A8A6: call 0x3100ab00 */ /* not lifted */
   7600     RECOMP_FLAGS_IN();
   7601     ecx = eax; /* 0x3100A8AB: mov ecx, eax */
   7602     eax = MEM32(ecx); /* 0x3100A8AD: mov eax, dword ptr [ecx] */
   7603     ecx = MEM32(ecx + 0x4); /* 0x3100A8AF: mov ecx, dword ptr [ecx + 4] */
   7604     goto L_3100A93C; /* 0x3100A8B2: jmp 0x3100a93c */
   7605 L_3100A8B7:
   7606     /* test LO8(eax), LO8(eax) */ /* 0x3100A8B7: test al, al */
   7607     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   7608     _cf = 0;
   7609     _flag_k = FK_NARROW(FK_TEST, 24);
   7610     MEM32(ebp + (-0x8)) = ebx; /* 0x3100A8B9: mov dword ptr [ebp - 8], ebx */
   7611     if (TEST_Z(_flag_a, _flag_b)) goto L_3100A8F7; /* 0x3100A8BC: je 0x3100a8f7 */
   7612 L_3100A8BE:
   7613     edx = ebp + (-0x14); /* 0x3100A8BE: lea edx, [ebp - 0x14] */
   7614     PUSH32(esp, edx); /* 0x3100A8C1: push edx */
   7615     ecx = edi; /* 0x3100A8C2: mov ecx, edi */
   7616     RECOMP_ICALL(0x3100E400u); /* 0x3100A8C4: call 0x3100e400 */ /* not lifted */
   7617     RECOMP_FLAGS_IN();
   7618     ecx = MEM32(ebp + (-0x8)); /* 0x3100A8C9: mov ecx, dword ptr [ebp - 8] */
   7619     /* cmp ecx, MEM32(eax) */ /* 0x3100A8CC: cmp ecx, dword ptr [eax] */
   7620     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax));
   7621     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7622     _flag_k = FK_CMP;
   7623     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A8EF; /* 0x3100A8CE: jne 0x3100a8ef */
   7624 L_3100A8D0:
   7625     edx = ebp + (-0x1); /* 0x3100A8D0: lea edx, [ebp - 1] */
   7626     PUSH32(esp, edx); /* 0x3100A8D3: push edx */
   7627     eax = ebp + (-0x24); /* 0x3100A8D4: lea eax, [ebp - 0x24] */
   7628     PUSH32(esp, eax); /* 0x3100A8D7: push eax */
   7629     PUSH32(esp, ebx); /* 0x3100A8D8: push ebx */
   7630     PUSH32(esp, esi); /* 0x3100A8D9: push esi */
   7631     ecx = ebp + (-0x18); /* 0x3100A8DA: lea ecx, [ebp - 0x18] */
   7632     PUSH32(esp, ecx); /* 0x3100A8DD: push ecx */
   7633     ecx = edi; /* 0x3100A8DE: mov ecx, edi */
   7634     MEM8(ebp + (-0x1)) = (uint8_t)(1); /* 0x3100A8E0: mov byte ptr [ebp - 1], 1 */
   7635     RECOMP_ICALL(0x3100AB20u); /* 0x3100A8E4: call 0x3100ab20 */ /* not lifted */
   7636     RECOMP_FLAGS_IN();
   7637     PUSH32(esp, eax); /* 0x3100A8E9: push eax */
   7638     ecx = ebp + (-0x3C); /* 0x3100A8EA: lea ecx, [ebp - 0x3c] */
   7639     goto L_3100A930; /* 0x3100A8ED: jmp 0x3100a930 */
   7640 L_3100A8EF:
   7641     ecx = ebp + (-0x8); /* 0x3100A8EF: lea ecx, [ebp - 8] */
   7642     RECOMP_ICALL(0x31010B60u); /* 0x3100A8F2: call 0x31010b60 */ /* not lifted */
   7643     RECOMP_FLAGS_IN();
   7644 L_3100A8F7:
   7645     eax = MEM32(ebp + (-0x8)); /* 0x3100A8F7: mov eax, dword ptr [ebp - 8] */
   7646     ecx = MEM32(eax + 0xC); /* 0x3100A8FA: mov ecx, dword ptr [eax + 0xc] */
   7647     /* cmp ecx, MEM32(ebp + (-0x24)) */ /* 0x3100A8FD: cmp ecx, dword ptr [ebp - 0x24] */
   7648     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(ebp + (-0x24)));
   7649     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7650     _flag_k = FK_CMP;
   7651     if (CMP_AE(_flag_a, _flag_b)) goto L_3100A921; /* 0x3100A900: jae 0x3100a921 */
   7652 L_3100A902:
   7653     edx = ebp + (-0x2); /* 0x3100A902: lea edx, [ebp - 2] */
   7654     PUSH32(esp, edx); /* 0x3100A905: push edx */
   7655     eax = ebp + (-0x24); /* 0x3100A906: lea eax, [ebp - 0x24] */
   7656     PUSH32(esp, eax); /* 0x3100A909: push eax */
   7657     PUSH32(esp, ebx); /* 0x3100A90A: push ebx */
   7658     PUSH32(esp, esi); /* 0x3100A90B: push esi */
   7659     ecx = ebp + (-0x1C); /* 0x3100A90C: lea ecx, [ebp - 0x1c] */
   7660     PUSH32(esp, ecx); /* 0x3100A90F: push ecx */
   7661     ecx = edi; /* 0x3100A910: mov ecx, edi */
   7662     MEM8(ebp + (-0x2)) = (uint8_t)(1); /* 0x3100A912: mov byte ptr [ebp - 2], 1 */
   7663     RECOMP_ICALL(0x3100AB20u); /* 0x3100A916: call 0x3100ab20 */ /* not lifted */
   7664     RECOMP_FLAGS_IN();
   7665     PUSH32(esp, eax); /* 0x3100A91B: push eax */
   7666     ecx = ebp + (-0x44); /* 0x3100A91C: lea ecx, [ebp - 0x44] */
   7667     goto L_3100A930; /* 0x3100A91F: jmp 0x3100a930 */
   7668 L_3100A921:
   7669     eax = ebp + (-0x3); /* 0x3100A921: lea eax, [ebp - 3] */
   7670     ecx = ebp + (-0x8); /* 0x3100A924: lea ecx, [ebp - 8] */
   7671     PUSH32(esp, eax); /* 0x3100A927: push eax */
   7672     PUSH32(esp, ecx); /* 0x3100A928: push ecx */
   7673     MEM8(ebp + (-0x3)) = (uint8_t)(0); /* 0x3100A929: mov byte ptr [ebp - 3], 0 */
   7674     ecx = ebp + (-0x4C); /* 0x3100A92D: lea ecx, [ebp - 0x4c] */
   7675 L_3100A930:
   7676     RECOMP_ICALL(0x3100AB00u); /* 0x3100A930: call 0x3100ab00 */ /* not lifted */
   7677     RECOMP_FLAGS_IN();
   7678     edx = eax; /* 0x3100A935: mov edx, eax */
   7679     eax = MEM32(edx); /* 0x3100A937: mov eax, dword ptr [edx] */
   7680     ecx = MEM32(edx + 0x4); /* 0x3100A939: mov ecx, dword ptr [edx + 4] */
   7681 L_3100A93C:
   7682     MEM32(ebp + (-0x2C)) = eax; /* 0x3100A93C: mov dword ptr [ebp - 0x2c], eax */
   7683     MEM32(ebp + (-0x28)) = ecx; /* 0x3100A93F: mov dword ptr [ebp - 0x28], ecx */
   7684     eax = ebp + (-0x28); /* 0x3100A942: lea eax, [ebp - 0x28] */
   7685     PUSH32(esp, eax); /* 0x3100A945: push eax */
   7686     ecx = ebp + (-0x2C); /* 0x3100A946: lea ecx, [ebp - 0x2c] */
   7687     PUSH32(esp, ecx); /* 0x3100A949: push ecx */
   7688     ecx = ebp + (-0x54); /* 0x3100A94A: lea ecx, [ebp - 0x54] */
   7689     RECOMP_ICALL(0x3100AB00u); /* 0x3100A94D: call 0x3100ab00 */ /* not lifted */
   7690     RECOMP_FLAGS_IN();
   7691     edx = eax; /* 0x3100A952: mov edx, eax */
   7692     eax = MEM32(edx); /* 0x3100A954: mov eax, dword ptr [edx] */
   7693     ecx = MEM32(edx + 0x4); /* 0x3100A956: mov ecx, dword ptr [edx + 4] */
   7694     edx = MEM32(eax + 0x10); /* 0x3100A959: mov edx, dword ptr [eax + 0x10] */
   7695     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   7696     edx = edx + 1; /* 0x3100A95C: inc edx */
   7697     _flag_k = FK_INC;
   7698     edi = POP32_VAL(esp); /* 0x3100A95D: pop edi */
   7699     MEM32(ebp + (-0x58)) = ecx; /* 0x3100A95E: mov dword ptr [ebp - 0x58], ecx */
   7700     ecx = edx; /* 0x3100A961: mov ecx, edx */
   7701     /* cmp ecx, 1 */ /* 0x3100A963: cmp ecx, 1 */
   7702     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   7703     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7704     _flag_k = FK_CMP;
   7705     esi = POP32_VAL(esp); /* 0x3100A966: pop esi */
   7706     MEM32(eax + 0x10) = edx; /* 0x3100A967: mov dword ptr [eax + 0x10], edx */
   7707     ebx = POP32_VAL(esp); /* 0x3100A96A: pop ebx */
   7708     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A97A; /* 0x3100A96B: jne 0x3100a97a */
   7709 L_3100A96D:
   7710     edx = MEM32(ebp + (-0xC)); /* 0x3100A96D: mov edx, dword ptr [ebp - 0xc] */
   7711     ecx = MEM32(edx + 0x34); /* 0x3100A970: mov ecx, dword ptr [edx + 0x34] */
   7712     PUSH32(esp, 2); /* 0x3100A973: push 2 */
   7713     RECOMP_ICALL(0x31002960u); /* 0x3100A975: call 0x31002960 */ /* not lifted */
   7714     RECOMP_FLAGS_IN();
   7715 L_3100A97A:
   7716     SET_LO8(eax, 1); /* 0x3100A97A: mov al, 1 */
   7717     esp = ebp; /* 0x3100A97C: mov esp, ebp */
   7718     ebp = POP32_VAL(esp); /* 0x3100A97E: pop ebp */
   7719     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100A97F: ret 4 */
   7720     RECOMP_REGS_OUT();
   7721 }
   7722 
   7723 void sub_3100A93C(void) {
   7724     int _fpu_cmp = 0;
   7725     uint32_t _cf = 0;
   7726     int _df = 1;
   7727     uint32_t _flag_k = FK_NONE;
   7728     uint32_t _flag_a = 0, _flag_b = 0;
   7729     uint32_t _itail_tgt = 0;
   7730     RECOMP_REGS_LOCALS
   7731     RECOMP_ENTER(0x3100A93Cu);
   7732 
   7733 L_3100A93C:
   7734     MEM32(ebp + (-0x2C)) = eax; /* 0x3100A93C: mov dword ptr [ebp - 0x2c], eax */
   7735     MEM32(ebp + (-0x28)) = ecx; /* 0x3100A93F: mov dword ptr [ebp - 0x28], ecx */
   7736     eax = ebp + (-0x28); /* 0x3100A942: lea eax, [ebp - 0x28] */
   7737     PUSH32(esp, eax); /* 0x3100A945: push eax */
   7738     ecx = ebp + (-0x2C); /* 0x3100A946: lea ecx, [ebp - 0x2c] */
   7739     PUSH32(esp, ecx); /* 0x3100A949: push ecx */
   7740     ecx = ebp + (-0x54); /* 0x3100A94A: lea ecx, [ebp - 0x54] */
   7741     RECOMP_ICALL(0x3100AB00u); /* 0x3100A94D: call 0x3100ab00 */ /* not lifted */
   7742     RECOMP_FLAGS_IN();
   7743     edx = eax; /* 0x3100A952: mov edx, eax */
   7744     eax = MEM32(edx); /* 0x3100A954: mov eax, dword ptr [edx] */
   7745     ecx = MEM32(edx + 0x4); /* 0x3100A956: mov ecx, dword ptr [edx + 4] */
   7746     edx = MEM32(eax + 0x10); /* 0x3100A959: mov edx, dword ptr [eax + 0x10] */
   7747     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   7748     edx = edx + 1; /* 0x3100A95C: inc edx */
   7749     _flag_k = FK_INC;
   7750     edi = POP32_VAL(esp); /* 0x3100A95D: pop edi */
   7751     MEM32(ebp + (-0x58)) = ecx; /* 0x3100A95E: mov dword ptr [ebp - 0x58], ecx */
   7752     ecx = edx; /* 0x3100A961: mov ecx, edx */
   7753     /* cmp ecx, 1 */ /* 0x3100A963: cmp ecx, 1 */
   7754     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   7755     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7756     _flag_k = FK_CMP;
   7757     esi = POP32_VAL(esp); /* 0x3100A966: pop esi */
   7758     MEM32(eax + 0x10) = edx; /* 0x3100A967: mov dword ptr [eax + 0x10], edx */
   7759     ebx = POP32_VAL(esp); /* 0x3100A96A: pop ebx */
   7760     if (CMP_NE(_flag_a, _flag_b)) goto L_3100A97A; /* 0x3100A96B: jne 0x3100a97a */
   7761 L_3100A96D:
   7762     edx = MEM32(ebp + (-0xC)); /* 0x3100A96D: mov edx, dword ptr [ebp - 0xc] */
   7763     ecx = MEM32(edx + 0x34); /* 0x3100A970: mov ecx, dword ptr [edx + 0x34] */
   7764     PUSH32(esp, 2); /* 0x3100A973: push 2 */
   7765     RECOMP_ICALL(0x31002960u); /* 0x3100A975: call 0x31002960 */ /* not lifted */
   7766     RECOMP_FLAGS_IN();
   7767 L_3100A97A:
   7768     SET_LO8(eax, 1); /* 0x3100A97A: mov al, 1 */
   7769     esp = ebp; /* 0x3100A97C: mov esp, ebp */
   7770     ebp = POP32_VAL(esp); /* 0x3100A97E: pop ebp */
   7771     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100A97F: ret 4 */
   7772     RECOMP_REGS_OUT();
   7773 }
   7774 
   7775 void sub_3100A990(void) {
   7776     int _fpu_cmp = 0;
   7777     uint32_t _cf = 0;
   7778     int _df = 1;
   7779     uint32_t _flag_k = FK_NONE;
   7780     uint32_t _flag_a = 0, _flag_b = 0;
   7781     uint32_t _itail_tgt = 0;
   7782     RECOMP_REGS_LOCALS
   7783     RECOMP_ENTER(0x3100A990u);
   7784 
   7785 L_3100A990:
   7786     PUSH32(esp, ebp); /* 0x3100A990: push ebp */
   7787     ebp = esp; /* 0x3100A991: mov ebp, esp */
   7788     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   7789     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7790     esp = esp - 8; /* 0x3100A993: sub esp, 8 */
   7791     _flag_k = FK_CMP;
   7792     eax = MEM32(ebp + 0x8); /* 0x3100A996: mov eax, dword ptr [ebp + 8] */
   7793     PUSH32(esp, ebx); /* 0x3100A999: push ebx */
   7794     PUSH32(esp, esi); /* 0x3100A99A: push esi */
   7795     ebx = ecx; /* 0x3100A99B: mov ebx, ecx */
   7796     PUSH32(esp, edi); /* 0x3100A99D: push edi */
   7797     ecx = ebp + 0x8; /* 0x3100A99E: lea ecx, [ebp + 8] */
   7798     esi = ebx + 0x14; /* 0x3100A9A1: lea esi, [ebx + 0x14] */
   7799     PUSH32(esp, ecx); /* 0x3100A9A4: push ecx */
   7800     ecx = esi; /* 0x3100A9A5: mov ecx, esi */
   7801     MEM32(ebp + 0x8) = eax; /* 0x3100A9A7: mov dword ptr [ebp + 8], eax */
   7802     RECOMP_ICALL(0x3100FE00u); /* 0x3100A9AA: call 0x3100fe00 */ /* not lifted */
   7803     RECOMP_FLAGS_IN();
   7804     ecx = MEM32(esi + 0x4); /* 0x3100A9AF: mov ecx, dword ptr [esi + 4] */
   7805     /* cmp eax, ecx */ /* 0x3100A9B2: cmp eax, ecx */
   7806     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
   7807     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7808     _flag_k = FK_CMP;
   7809     MEM32(ebp + (-0x4)) = eax; /* 0x3100A9B4: mov dword ptr [ebp - 4], eax */
   7810     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100A9C6; /* 0x3100A9B7: je 0x3100a9c6 */
   7811 L_3100A9B9:
   7812     edx = MEM32(ebp + 0x8); /* 0x3100A9B9: mov edx, dword ptr [ebp + 8] */
   7813     /* cmp edx, MEM32(eax + 0xC) */ /* 0x3100A9BC: cmp edx, dword ptr [eax + 0xc] */
   7814     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(eax + 0xC));
   7815     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7816     _flag_k = FK_CMP;
   7817     if (CMP_B(_flag_a, _flag_b)) goto L_3100A9C6; /* 0x3100A9BF: jb 0x3100a9c6 */
   7818 L_3100A9C1:
   7819     eax = ebp + (-0x4); /* 0x3100A9C1: lea eax, [ebp - 4] */
   7820     goto L_3100A9CC; /* 0x3100A9C4: jmp 0x3100a9cc */
   7821 L_3100A9C6:
   7822     MEM32(ebp + (-0x8)) = ecx; /* 0x3100A9C6: mov dword ptr [ebp - 8], ecx */
   7823     eax = ebp + (-0x8); /* 0x3100A9C9: lea eax, [ebp - 8] */
   7824 L_3100A9CC:
   7825     edi = MEM32(eax); /* 0x3100A9CC: mov edi, dword ptr [eax] */
   7826     _flag_a = (uint32_t)(MEM32(edi + 0x10)); _flag_b = (uint32_t)(1);
   7827     MEM32(edi + 0x10) = MEM32(edi + 0x10) - 1; /* 0x3100A9CE: dec dword ptr [edi + 0x10] */
   7828     _flag_k = FK_DEC;
   7829     if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3100A9E7; /* 0x3100A9D1: jne 0x3100a9e7 */
   7830 L_3100A9D3:
   7831     ecx = MEM32(ebx + 0x34); /* 0x3100A9D3: mov ecx, dword ptr [ebx + 0x34] */
   7832     RECOMP_ICALL(0x310029E0u); /* 0x3100A9D6: call 0x310029e0 */ /* not lifted */
   7833     RECOMP_FLAGS_IN();
   7834     PUSH32(esp, edi); /* 0x3100A9DB: push edi */
   7835     eax = ebp + 0x8; /* 0x3100A9DC: lea eax, [ebp + 8] */
   7836     PUSH32(esp, eax); /* 0x3100A9DF: push eax */
   7837     ecx = esi; /* 0x3100A9E0: mov ecx, esi */
   7838     RECOMP_ICALL(0x310099F0u); /* 0x3100A9E2: call 0x310099f0 */ /* not lifted */
   7839     RECOMP_FLAGS_IN();
   7840 L_3100A9E7:
   7841     edi = POP32_VAL(esp); /* 0x3100A9E7: pop edi */
   7842     esi = POP32_VAL(esp); /* 0x3100A9E8: pop esi */
   7843     ebx = POP32_VAL(esp); /* 0x3100A9E9: pop ebx */
   7844     esp = ebp; /* 0x3100A9EA: mov esp, ebp */
   7845     ebp = POP32_VAL(esp); /* 0x3100A9EC: pop ebp */
   7846     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100A9ED: ret 4 */
   7847     RECOMP_REGS_OUT();
   7848 }
   7849 
   7850 void sub_3100A9F0(void) {
   7851     int _fpu_cmp = 0;
   7852     uint32_t _cf = 0;
   7853     int _df = 1;
   7854     uint32_t _flag_k = FK_NONE;
   7855     uint32_t _flag_a = 0, _flag_b = 0;
   7856     uint32_t _itail_tgt = 0;
   7857     RECOMP_REGS_LOCALS
   7858     RECOMP_ENTER(0x3100A9F0u);
   7859 
   7860 L_3100A9F0:
   7861     PUSH32(esp, ebp); /* 0x3100A9F0: push ebp */
   7862     ebp = esp; /* 0x3100A9F1: mov ebp, esp */
   7863     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100A9F3: push -1 */
   7864     PUSH32(esp, 0x3104741Bu); /* 0x3100A9F5: push 0x3104741b */
   7865     eax = MEM32(FS_BASE + (0)); /* 0x3100A9FA: mov eax, dword ptr fs:[0] */
   7866     PUSH32(esp, eax); /* 0x3100AA00: push eax */
   7867     MEM32(FS_BASE + (0)) = esp; /* 0x3100AA01: mov dword ptr fs:[0], esp */
   7868     PUSH32(esp, ecx); /* 0x3100AA08: push ecx */
   7869     PUSH32(esp, esi); /* 0x3100AA09: push esi */
   7870     esi = ecx; /* 0x3100AA0A: mov esi, ecx */
   7871     eax = MEM32(esi + 0x30); /* 0x3100AA0C: mov eax, dword ptr [esi + 0x30] */
   7872     /* test eax, eax */ /* 0x3100AA0F: test eax, eax */
   7873     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   7874     _cf = 0;
   7875     _flag_k = FK_TEST;
   7876     PUSH32(esp, edi); /* 0x3100AA11: push edi */
   7877     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AA47; /* 0x3100AA12: jne 0x3100aa47 */
   7878 L_3100AA14:
   7879     PUSH32(esp, 0x14u); /* 0x3100AA14: push 0x14 */
   7880     RECOMP_ICALL(0x310468DAu); /* 0x3100AA16: call 0x310468da */ /* not lifted */
   7881     RECOMP_FLAGS_IN();
   7882     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   7883     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7884     esp = esp + 4; /* 0x3100AA1B: add esp, 4 */
   7885     _flag_k = FK_ADD;
   7886     MEM32(ebp + (-0x10)) = eax; /* 0x3100AA1E: mov dword ptr [ebp - 0x10], eax */
   7887     /* test eax, eax */ /* 0x3100AA21: test eax, eax */
   7888     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   7889     _cf = 0;
   7890     _flag_k = FK_TEST;
   7891     MEM32(ebp + (-0x4)) = 0; /* 0x3100AA23: mov dword ptr [ebp - 4], 0 */
   7892     if (TEST_Z(_flag_a, _flag_b)) goto L_3100AA3B; /* 0x3100AA2A: je 0x3100aa3b */
   7893 L_3100AA2C:
   7894     ecx = MEM32(esi + 0x34); /* 0x3100AA2C: mov ecx, dword ptr [esi + 0x34] */
   7895     PUSH32(esp, 0); /* 0x3100AA2F: push 0 */
   7896     PUSH32(esp, ecx); /* 0x3100AA31: push ecx */
   7897     ecx = eax; /* 0x3100AA32: mov ecx, eax */
   7898     RECOMP_ICALL(0x310013C0u); /* 0x3100AA34: call 0x310013c0 */ /* not lifted */
   7899     RECOMP_FLAGS_IN();
   7900     goto L_3100AA3D; /* 0x3100AA39: jmp 0x3100aa3d */
   7901 L_3100AA3B:
   7902     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   7903     eax = 0; /* 0x3100AA3B: xor eax, eax */
   7904     _cf = 0;
   7905     _flag_k = FK_TEST;
   7906 L_3100AA3D:
   7907     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100AA3D: mov dword ptr [ebp - 4], 0xffffffff */
   7908     MEM32(esi + 0x30) = eax; /* 0x3100AA44: mov dword ptr [esi + 0x30], eax */
   7909 L_3100AA47:
   7910     ecx = MEM32(esi + 0x34); /* 0x3100AA47: mov ecx, dword ptr [esi + 0x34] */
   7911     PUSH32(esp, 1); /* 0x3100AA4A: push 1 */
   7912     RECOMP_ICALL(0x31002960u); /* 0x3100AA4C: call 0x31002960 */ /* not lifted */
   7913     RECOMP_FLAGS_IN();
   7914     edx = MEM32(ebp + 0xC); /* 0x3100AA51: mov edx, dword ptr [ebp + 0xc] */
   7915     eax = MEM32(ebp + 0x8); /* 0x3100AA54: mov eax, dword ptr [ebp + 8] */
   7916     ecx = MEM32(esi + 0x30); /* 0x3100AA57: mov ecx, dword ptr [esi + 0x30] */
   7917     PUSH32(esp, edx); /* 0x3100AA5A: push edx */
   7918     PUSH32(esp, eax); /* 0x3100AA5B: push eax */
   7919     RECOMP_ICALL(0x31001770u); /* 0x3100AA5C: call 0x31001770 */ /* not lifted */
   7920     RECOMP_FLAGS_IN();
   7921     ecx = MEM32(esi + 0x34); /* 0x3100AA61: mov ecx, dword ptr [esi + 0x34] */
   7922     edi = eax; /* 0x3100AA64: mov edi, eax */
   7923     RECOMP_ICALL(0x310029E0u); /* 0x3100AA66: call 0x310029e0 */ /* not lifted */
   7924     RECOMP_FLAGS_IN();
   7925     ecx = MEM32(ebp + (-0xC)); /* 0x3100AA6B: mov ecx, dword ptr [ebp - 0xc] */
   7926     eax = edi; /* 0x3100AA6E: mov eax, edi */
   7927     edi = POP32_VAL(esp); /* 0x3100AA70: pop edi */
   7928     esi = POP32_VAL(esp); /* 0x3100AA71: pop esi */
   7929     MEM32(FS_BASE + (0)) = ecx; /* 0x3100AA72: mov dword ptr fs:[0], ecx */
   7930     esp = ebp; /* 0x3100AA79: mov esp, ebp */
   7931     ebp = POP32_VAL(esp); /* 0x3100AA7B: pop ebp */
   7932     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100AA7C: ret 8 */
   7933     RECOMP_REGS_OUT();
   7934 }
   7935 
   7936 void sub_3100AA80(void) {
   7937     int _fpu_cmp = 0;
   7938     uint32_t _cf = 0;
   7939     int _df = 1;
   7940     uint32_t _flag_k = FK_NONE;
   7941     uint32_t _flag_a = 0, _flag_b = 0;
   7942     uint32_t _itail_tgt = 0;
   7943     RECOMP_REGS_LOCALS
   7944     RECOMP_ENTER(0x3100AA80u);
   7945 
   7946 L_3100AA80:
   7947     PUSH32(esp, ebp); /* 0x3100AA80: push ebp */
   7948     ebp = esp; /* 0x3100AA81: mov ebp, esp */
   7949     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x34u);
   7950     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   7951     esp = esp - 0x34u; /* 0x3100AA83: sub esp, 0x34 */
   7952     _flag_k = FK_CMP;
   7953     PUSH32(esp, 0x31052168u); /* 0x3100AA86: push 0x31052168 */
   7954     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(4);
   7955     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7956     ecx = ecx + 4; /* 0x3100AA8B: add ecx, 4 */
   7957     _flag_k = FK_ADD;
   7958     PUSH32(esp, ecx); /* 0x3100AA8E: push ecx */
   7959     eax = ebp + (-0x10); /* 0x3100AA8F: lea eax, [ebp - 0x10] */
   7960     PUSH32(esp, eax); /* 0x3100AA92: push eax */
   7961     RECOMP_ICALL(0x3104686Au); /* 0x3100AA93: call 0x3104686a */ /* not lifted */
   7962     RECOMP_FLAGS_IN();
   7963     eax = MEM32(ebp + (-0xC)); /* 0x3100AA98: mov eax, dword ptr [ebp - 0xc] */
   7964     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   7965     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7966     esp = esp + 0xCu; /* 0x3100AA9B: add esp, 0xc */
   7967     _flag_k = FK_ADD;
   7968     /* test eax, eax */ /* 0x3100AA9E: test eax, eax */
   7969     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   7970     _cf = 0;
   7971     _flag_k = FK_TEST;
   7972     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AAA7; /* 0x3100AAA0: jne 0x3100aaa7 */
   7973 L_3100AAA2:
   7974     eax = MEM32(0x310480EC); /* 0x3100AAA2: mov eax, dword ptr [0x310480ec] */
   7975 L_3100AAA7:
   7976     PUSH32(esp, esi); /* 0x3100AAA7: push esi */
   7977     ecx = ebp + (-0x34); /* 0x3100AAA8: lea ecx, [ebp - 0x34] */
   7978     PUSH32(esp, ecx); /* 0x3100AAAB: push ecx */
   7979     PUSH32(esp, eax); /* 0x3100AAAC: push eax */
   7980     RECOMP_ICALL(MEM32(0x31048230)); /* 0x3100AAAD: call dword ptr [0x31048230] */
   7981     RECOMP_FLAGS_IN();
   7982     ecx = MEM32(ebp + (-0x18)); /* 0x3100AAB3: mov ecx, dword ptr [ebp - 0x18] */
   7983     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
   7984     edx = 0; /* 0x3100AAB6: xor edx, edx */
   7985     _cf = 0;
   7986     _flag_k = FK_TEST;
   7987     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
   7988     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   7989     esp = esp + 8; /* 0x3100AAB8: add esp, 8 */
   7990     _flag_k = FK_ADD;
   7991     /* test eax, eax */ /* 0x3100AABB: test eax, eax */
   7992     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
   7993     _cf = 0;
   7994     _flag_k = FK_TEST;
   7995     SET_LO8(edx, (TEST_NZ(_flag_a, _flag_b)) ? 1 : 0); /* 0x3100AABD: setne dl */
   7996     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
   7997     edx = edx - 1; /* 0x3100AAC0: dec edx */
   7998     _flag_k = FK_DEC;
   7999     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
   8000     edx = edx & ecx; /* 0x3100AAC1: and edx, ecx */
   8001     _cf = 0;
   8002     _flag_k = FK_TEST;
   8003     ecx = MEM32(ebp + (-0xC)); /* 0x3100AAC3: mov ecx, dword ptr [ebp - 0xc] */
   8004     /* test ecx, ecx */ /* 0x3100AAC6: test ecx, ecx */
   8005     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
   8006     _cf = 0;
   8007     _flag_k = FK_TEST;
   8008     esi = edx; /* 0x3100AAC8: mov esi, edx */
   8009     if (TEST_Z(_flag_a, _flag_b)) goto L_3100AAED; /* 0x3100AACA: je 0x3100aaed */
   8010 L_3100AACC:
   8011     SET_LO8(eax, MEM8(ecx + (-0x1))); /* 0x3100AACC: mov al, byte ptr [ecx - 1] */
   8012     /* test LO8(eax), LO8(eax) */ /* 0x3100AACF: test al, al */
   8013     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
   8014     _cf = 0;
   8015     _flag_k = FK_NARROW(FK_TEST, 24);
   8016     if (TEST_Z(_flag_a, _flag_b)) goto L_3100AAE3; /* 0x3100AAD1: je 0x3100aae3 */
   8017 L_3100AAD3:
   8018     /* cmp LO8(eax), 0xFFu */ /* 0x3100AAD3: cmp al, 0xff */
   8019     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
   8020     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8021     _flag_k = FK_NARROW(FK_CMP, 24);
   8022     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AAE3; /* 0x3100AAD5: je 0x3100aae3 */
   8023 L_3100AAD7:
   8024     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
   8025     SET_LO8(eax, LO8(eax) - 1); /* 0x3100AAD7: dec al */
   8026     _flag_k = FK_NARROW(FK_DEC, 24);
   8027     MEM8(ecx + (-0x1)) = (uint8_t)(LO8(eax)); /* 0x3100AAD9: mov byte ptr [ecx - 1], al */
   8028     eax = esi; /* 0x3100AADC: mov eax, esi */
   8029     esi = POP32_VAL(esp); /* 0x3100AADE: pop esi */
   8030     esp = ebp; /* 0x3100AADF: mov esp, ebp */
   8031     ebp = POP32_VAL(esp); /* 0x3100AAE1: pop ebp */
   8032     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100AAE2: ret  */
   8033 L_3100AAE3:
   8034     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   8035     ecx = ecx - 1; /* 0x3100AAE3: dec ecx */
   8036     _flag_k = FK_DEC;
   8037     PUSH32(esp, ecx); /* 0x3100AAE4: push ecx */
   8038     RECOMP_ICALL(0x31046858u); /* 0x3100AAE5: call 0x31046858 */ /* not lifted */
   8039     RECOMP_FLAGS_IN();
   8040     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
   8041     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8042     esp = esp + 4; /* 0x3100AAEA: add esp, 4 */
   8043     _flag_k = FK_ADD;
   8044 L_3100AAED:
   8045     eax = esi; /* 0x3100AAED: mov eax, esi */
   8046     esi = POP32_VAL(esp); /* 0x3100AAEF: pop esi */
   8047     esp = ebp; /* 0x3100AAF0: mov esp, ebp */
   8048     ebp = POP32_VAL(esp); /* 0x3100AAF2: pop ebp */
   8049     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100AAF3: ret  */
   8050     RECOMP_REGS_OUT();
   8051 }
   8052 
   8053 void sub_3100AB00(void) {
   8054     int _fpu_cmp = 0;
   8055     uint32_t _cf = 0;
   8056     int _df = 1;
   8057     uint32_t _flag_k = FK_NONE;
   8058     uint32_t _flag_a = 0, _flag_b = 0;
   8059     uint32_t _itail_tgt = 0;
   8060     RECOMP_REGS_LOCALS
   8061     RECOMP_ENTER(0x3100AB00u);
   8062 
   8063 L_3100AB00:
   8064     PUSH32(esp, ebp); /* 0x3100AB00: push ebp */
   8065     ebp = esp; /* 0x3100AB01: mov ebp, esp */
   8066     eax = ecx; /* 0x3100AB03: mov eax, ecx */
   8067     ecx = MEM32(ebp + 0x8); /* 0x3100AB05: mov ecx, dword ptr [ebp + 8] */
   8068     edx = MEM32(ecx); /* 0x3100AB08: mov edx, dword ptr [ecx] */
   8069     ecx = MEM32(ebp + 0xC); /* 0x3100AB0A: mov ecx, dword ptr [ebp + 0xc] */
   8070     MEM32(eax) = edx; /* 0x3100AB0D: mov dword ptr [eax], edx */
   8071     SET_LO8(edx, MEM8(ecx)); /* 0x3100AB0F: mov dl, byte ptr [ecx] */
   8072     MEM8(eax + 0x4) = (uint8_t)(LO8(edx)); /* 0x3100AB11: mov byte ptr [eax + 4], dl */
   8073     ebp = POP32_VAL(esp); /* 0x3100AB14: pop ebp */
   8074     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100AB15: ret 8 */
   8075     RECOMP_REGS_OUT();
   8076 }
   8077 
   8078 void sub_3100AB20(void) {
   8079     int _fpu_cmp = 0;
   8080     uint32_t _cf = 0;
   8081     int _df = 1;
   8082     uint32_t _flag_k = FK_NONE;
   8083     uint32_t _flag_a = 0, _flag_b = 0;
   8084     uint32_t _itail_tgt = 0;
   8085     RECOMP_REGS_LOCALS
   8086     RECOMP_ENTER(0x3100AB20u);
   8087 
   8088 L_3100AB20:
   8089     PUSH32(esp, ebp); /* 0x3100AB20: push ebp */
   8090     ebp = esp; /* 0x3100AB21: mov ebp, esp */
   8091     PUSH32(esp, ecx); /* 0x3100AB23: push ecx */
   8092     PUSH32(esp, ebx); /* 0x3100AB24: push ebx */
   8093     PUSH32(esp, esi); /* 0x3100AB25: push esi */
   8094     PUSH32(esp, edi); /* 0x3100AB26: push edi */
   8095     PUSH32(esp, 0x18u); /* 0x3100AB27: push 0x18 */
   8096     esi = ecx; /* 0x3100AB29: mov esi, ecx */
   8097     RECOMP_ICALL(0x310468DAu); /* 0x3100AB2B: call 0x310468da */ /* not lifted */
   8098     RECOMP_FLAGS_IN();
   8099     edi = MEM32(ebp + 0x10); /* 0x3100AB30: mov edi, dword ptr [ebp + 0x10] */
   8100     ebx = MEM32(ebp + 0x14); /* 0x3100AB33: mov ebx, dword ptr [ebp + 0x14] */
   8101     MEM32(eax + 0x4) = edi; /* 0x3100AB36: mov dword ptr [eax + 4], edi */
   8102     MEM8(eax + 0x14) = (uint8_t)(0); /* 0x3100AB39: mov byte ptr [eax + 0x14], 0 */
   8103     MEM8(eax + 0x15) = (uint8_t)(0); /* 0x3100AB3D: mov byte ptr [eax + 0x15], 0 */
   8104     ecx = MEM32(esi + 0x8); /* 0x3100AB41: mov ecx, dword ptr [esi + 8] */
   8105     MEM32(eax) = ecx; /* 0x3100AB44: mov dword ptr [eax], ecx */
   8106     edx = MEM32(esi + 0x8); /* 0x3100AB46: mov edx, dword ptr [esi + 8] */
   8107     MEM32(ebp + (-0x4)) = eax; /* 0x3100AB49: mov dword ptr [ebp - 4], eax */
   8108     MEM32(eax + 0x8) = edx; /* 0x3100AB4C: mov dword ptr [eax + 8], edx */
   8109     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xCu);
   8110     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8111     eax = eax + 0xCu; /* 0x3100AB4F: add eax, 0xc */
   8112     _flag_k = FK_ADD;
   8113     PUSH32(esp, ebx); /* 0x3100AB52: push ebx */
   8114     PUSH32(esp, eax); /* 0x3100AB53: push eax */
   8115     RECOMP_ICALL(0x31005E40u); /* 0x3100AB54: call 0x31005e40 */ /* not lifted */
   8116     RECOMP_FLAGS_IN();
   8117     ecx = MEM32(esi + 0x10); /* 0x3100AB59: mov ecx, dword ptr [esi + 0x10] */
   8118     eax = MEM32(esi + 0x4); /* 0x3100AB5C: mov eax, dword ptr [esi + 4] */
   8119     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
   8120     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
   8121     esp = esp + 0xCu; /* 0x3100AB5F: add esp, 0xc */
   8122     _flag_k = FK_ADD;
   8123     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
   8124     ecx = ecx + 1; /* 0x3100AB62: inc ecx */
   8125     _flag_k = FK_INC;
   8126     /* cmp edi, eax */ /* 0x3100AB63: cmp edi, eax */
   8127     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   8128     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8129     _flag_k = FK_CMP;
   8130     MEM32(esi + 0x10) = ecx; /* 0x3100AB65: mov dword ptr [esi + 0x10], ecx */
   8131     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AB8C; /* 0x3100AB68: je 0x3100ab8c */
   8132 L_3100AB6A:
   8133     eax = MEM32(ebp + 0xC); /* 0x3100AB6A: mov eax, dword ptr [ebp + 0xc] */
   8134     /* cmp eax, MEM32(esi + 0x8) */ /* 0x3100AB6D: cmp eax, dword ptr [esi + 8] */
   8135     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8136     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8137     _flag_k = FK_CMP;
   8138     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AB8C; /* 0x3100AB70: jne 0x3100ab8c */
   8139 L_3100AB72:
   8140     ecx = MEM32(ebx); /* 0x3100AB72: mov ecx, dword ptr [ebx] */
   8141     /* cmp ecx, MEM32(edi + 0xC) */ /* 0x3100AB74: cmp ecx, dword ptr [edi + 0xc] */
   8142     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0xC));
   8143     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8144     _flag_k = FK_CMP;
   8145     if (CMP_B(_flag_a, _flag_b)) goto L_3100AB8C; /* 0x3100AB77: jb 0x3100ab8c */
   8146 L_3100AB79:
   8147     ecx = MEM32(ebp + (-0x4)); /* 0x3100AB79: mov ecx, dword ptr [ebp - 4] */
   8148     MEM32(edi + 0x8) = ecx; /* 0x3100AB7C: mov dword ptr [edi + 8], ecx */
   8149     eax = MEM32(esi + 0x4); /* 0x3100AB7F: mov eax, dword ptr [esi + 4] */
   8150     /* cmp edi, MEM32(eax + 0x8) */ /* 0x3100AB82: cmp edi, dword ptr [eax + 8] */
   8151     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(eax + 0x8));
   8152     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8153     _flag_k = FK_CMP;
   8154     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABAC; /* 0x3100AB85: jne 0x3100abac */
   8155 L_3100AB87:
   8156     MEM32(eax + 0x8) = ecx; /* 0x3100AB87: mov dword ptr [eax + 8], ecx */
   8157     goto L_3100ABAC; /* 0x3100AB8A: jmp 0x3100abac */
   8158 L_3100AB8C:
   8159     ecx = MEM32(ebp + (-0x4)); /* 0x3100AB8C: mov ecx, dword ptr [ebp - 4] */
   8160     MEM32(edi) = ecx; /* 0x3100AB8F: mov dword ptr [edi], ecx */
   8161     eax = MEM32(esi + 0x4); /* 0x3100AB91: mov eax, dword ptr [esi + 4] */
   8162     /* cmp edi, eax */ /* 0x3100AB94: cmp edi, eax */
   8163     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
   8164     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8165     _flag_k = FK_CMP;
   8166     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABA3; /* 0x3100AB96: jne 0x3100aba3 */
   8167 L_3100AB98:
   8168     MEM32(eax + 0x4) = ecx; /* 0x3100AB98: mov dword ptr [eax + 4], ecx */
   8169     edx = MEM32(esi + 0x4); /* 0x3100AB9B: mov edx, dword ptr [esi + 4] */
   8170     MEM32(edx + 0x8) = ecx; /* 0x3100AB9E: mov dword ptr [edx + 8], ecx */
   8171     goto L_3100ABAC; /* 0x3100ABA1: jmp 0x3100abac */
   8172 L_3100ABA3:
   8173     /* cmp edi, MEM32(eax) */ /* 0x3100ABA3: cmp edi, dword ptr [eax] */
   8174     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(eax));
   8175     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8176     _flag_k = FK_CMP;
   8177     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABAC; /* 0x3100ABA5: jne 0x3100abac */
   8178 L_3100ABA7:
   8179     ecx = MEM32(ebp + (-0x4)); /* 0x3100ABA7: mov ecx, dword ptr [ebp - 4] */
   8180     MEM32(eax) = ecx; /* 0x3100ABAA: mov dword ptr [eax], ecx */
   8181 L_3100ABAC:
   8182     edx = MEM32(esi + 0x4); /* 0x3100ABAC: mov edx, dword ptr [esi + 4] */
   8183     eax = MEM32(ebp + (-0x4)); /* 0x3100ABAF: mov eax, dword ptr [ebp - 4] */
   8184     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ABB2: cmp eax, dword ptr [edx + 4] */
   8185     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   8186     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8187     _flag_k = FK_CMP;
   8188     SET_LO8(ebx, 1); /* 0x3100ABB5: mov bl, 1 */
   8189     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABB7: je 0x3100ad3d */
   8190 L_3100ABBD:
   8191     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
   8192     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
   8193     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
   8194     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   8195     _cf = 0;
   8196     _flag_k = FK_NARROW(FK_TEST, 24);
   8197     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
   8198 L_3100ABCB:
   8199     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
   8200     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
   8201     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
   8202     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   8203     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8204     _flag_k = FK_CMP;
   8205     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
   8206 L_3100ABD8:
   8207     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
   8208     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
   8209     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   8210     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8211     _flag_k = FK_NARROW(FK_CMP, 24);
   8212     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
   8213 L_3100ABE1:
   8214     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
   8215     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
   8216     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
   8217     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
   8218     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
   8219     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
   8220     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
   8221     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
   8222 L_3100ABFC:
   8223     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
   8224     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x8));
   8225     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8226     _flag_k = FK_CMP;
   8227     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
   8228 L_3100AC01:
   8229     eax = ecx; /* 0x3100AC01: mov eax, ecx */
   8230     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
   8231     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
   8232     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
   8233     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
   8234     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
   8235     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8236     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8237     _flag_k = FK_CMP;
   8238     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
   8239 L_3100AC12:
   8240     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
   8241 L_3100AC15:
   8242     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
   8243     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
   8244     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
   8245     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
   8246     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   8247     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8248     _flag_k = FK_CMP;
   8249     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
   8250 L_3100AC23:
   8251     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
   8252     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
   8253 L_3100AC28:
   8254     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
   8255     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
   8256     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
   8257     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8258     _flag_k = FK_CMP;
   8259     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
   8260 L_3100AC2F:
   8261     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
   8262     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
   8263 L_3100AC33:
   8264     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
   8265 L_3100AC36:
   8266     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
   8267     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
   8268 L_3100AC3B:
   8269     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
   8270     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
   8271     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
   8272     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
   8273     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
   8274     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
   8275     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
   8276     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
   8277     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
   8278     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
   8279     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
   8280     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
   8281     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8282     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8283     _flag_k = FK_CMP;
   8284     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
   8285 L_3100AC60:
   8286     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
   8287 L_3100AC63:
   8288     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
   8289     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
   8290     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
   8291     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
   8292     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   8293     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8294     _flag_k = FK_CMP;
   8295     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
   8296 L_3100AC71:
   8297     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
   8298     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
   8299     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
   8300 L_3100AC7C:
   8301     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
   8302     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
   8303     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   8304     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8305     _flag_k = FK_CMP;
   8306     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
   8307 L_3100AC84:
   8308     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
   8309     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
   8310     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
   8311 L_3100AC8F:
   8312     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
   8313     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
   8314     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
   8315 L_3100AC99:
   8316     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
   8317     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   8318     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8319     _flag_k = FK_NARROW(FK_CMP, 24);
   8320     RECOMP_BACKEDGE();
   8321     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
   8322 L_3100ACA3:
   8323     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
   8324     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
   8325     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8326     _flag_k = FK_CMP;
   8327     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
   8328 L_3100ACA7:
   8329     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
   8330     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
   8331     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
   8332     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
   8333     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
   8334     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
   8335     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8336     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8337     _flag_k = FK_CMP;
   8338     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
   8339 L_3100ACB8:
   8340     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
   8341 L_3100ACBB:
   8342     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
   8343     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
   8344     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
   8345     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
   8346     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   8347     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8348     _flag_k = FK_CMP;
   8349     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
   8350 L_3100ACC9:
   8351     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
   8352     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
   8353 L_3100ACCE:
   8354     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
   8355     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
   8356     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
   8357     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8358     _flag_k = FK_CMP;
   8359     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
   8360 L_3100ACD6:
   8361     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
   8362     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
   8363 L_3100ACDB:
   8364     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
   8365 L_3100ACDD:
   8366     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
   8367     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
   8368 L_3100ACE3:
   8369     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
   8370     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
   8371     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
   8372     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
   8373     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
   8374     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
   8375     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
   8376     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
   8377     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
   8378     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
   8379     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
   8380     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
   8381     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8382     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8383     _flag_k = FK_CMP;
   8384     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
   8385 L_3100AD08:
   8386     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
   8387 L_3100AD0B:
   8388     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
   8389     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
   8390     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
   8391     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
   8392     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   8393     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8394     _flag_k = FK_CMP;
   8395     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
   8396 L_3100AD19:
   8397     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
   8398     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
   8399 L_3100AD1E:
   8400     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
   8401     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
   8402     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
   8403     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8404     _flag_k = FK_CMP;
   8405     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
   8406 L_3100AD25:
   8407     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
   8408     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
   8409 L_3100AD29:
   8410     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
   8411 L_3100AD2C:
   8412     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
   8413 L_3100AD2E:
   8414     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
   8415 L_3100AD31:
   8416     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
   8417     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
   8418     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   8419     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8420     _flag_k = FK_CMP;
   8421     RECOMP_BACKEDGE();
   8422     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
   8423 L_3100AD3D:
   8424     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
   8425     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
   8426     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
   8427     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
   8428     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
   8429     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
   8430     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
   8431     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
   8432     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
   8433     esp = ebp; /* 0x3100AD51: mov esp, ebp */
   8434     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
   8435     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
   8436     RECOMP_REGS_OUT();
   8437 }
   8438 
   8439 void sub_3100ABBD(void) {
   8440     int _fpu_cmp = 0;
   8441     uint32_t _cf = 0;
   8442     int _df = 1;
   8443     uint32_t _flag_k = FK_NONE;
   8444     uint32_t _flag_a = 0, _flag_b = 0;
   8445     uint32_t _itail_tgt = 0;
   8446     RECOMP_REGS_LOCALS
   8447     RECOMP_ENTER(0x3100ABBDu);
   8448 
   8449 L_3100ABBD:
   8450     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
   8451     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
   8452     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
   8453     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   8454     _cf = 0;
   8455     _flag_k = FK_NARROW(FK_TEST, 24);
   8456     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
   8457 L_3100ABCB:
   8458     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
   8459     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
   8460     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
   8461     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   8462     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8463     _flag_k = FK_CMP;
   8464     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
   8465 L_3100ABD8:
   8466     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
   8467     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
   8468     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   8469     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8470     _flag_k = FK_NARROW(FK_CMP, 24);
   8471     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
   8472 L_3100ABE1:
   8473     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
   8474     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
   8475     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
   8476     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
   8477     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
   8478     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
   8479     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
   8480     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
   8481 L_3100ABFC:
   8482     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
   8483     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x8));
   8484     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8485     _flag_k = FK_CMP;
   8486     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
   8487 L_3100AC01:
   8488     eax = ecx; /* 0x3100AC01: mov eax, ecx */
   8489     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
   8490     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
   8491     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
   8492     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
   8493     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
   8494     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8495     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8496     _flag_k = FK_CMP;
   8497     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
   8498 L_3100AC12:
   8499     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
   8500 L_3100AC15:
   8501     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
   8502     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
   8503     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
   8504     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
   8505     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   8506     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8507     _flag_k = FK_CMP;
   8508     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
   8509 L_3100AC23:
   8510     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
   8511     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
   8512 L_3100AC28:
   8513     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
   8514     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
   8515     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
   8516     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8517     _flag_k = FK_CMP;
   8518     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
   8519 L_3100AC2F:
   8520     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
   8521     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
   8522 L_3100AC33:
   8523     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
   8524 L_3100AC36:
   8525     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
   8526     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
   8527 L_3100AC3B:
   8528     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
   8529     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
   8530     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
   8531     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
   8532     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
   8533     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
   8534     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
   8535     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
   8536     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
   8537     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
   8538     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
   8539     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
   8540     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8541     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8542     _flag_k = FK_CMP;
   8543     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
   8544 L_3100AC60:
   8545     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
   8546 L_3100AC63:
   8547     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
   8548     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
   8549     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
   8550     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
   8551     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   8552     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8553     _flag_k = FK_CMP;
   8554     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
   8555 L_3100AC71:
   8556     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
   8557     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
   8558     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
   8559 L_3100AC7C:
   8560     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
   8561     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
   8562     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   8563     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8564     _flag_k = FK_CMP;
   8565     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
   8566 L_3100AC84:
   8567     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
   8568     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
   8569     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
   8570 L_3100AC8F:
   8571     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
   8572     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
   8573     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
   8574 L_3100AC99:
   8575     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
   8576     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   8577     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8578     _flag_k = FK_NARROW(FK_CMP, 24);
   8579     RECOMP_BACKEDGE();
   8580     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
   8581 L_3100ACA3:
   8582     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
   8583     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
   8584     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8585     _flag_k = FK_CMP;
   8586     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
   8587 L_3100ACA7:
   8588     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
   8589     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
   8590     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
   8591     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
   8592     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
   8593     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
   8594     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8595     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8596     _flag_k = FK_CMP;
   8597     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
   8598 L_3100ACB8:
   8599     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
   8600 L_3100ACBB:
   8601     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
   8602     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
   8603     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
   8604     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
   8605     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   8606     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8607     _flag_k = FK_CMP;
   8608     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
   8609 L_3100ACC9:
   8610     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
   8611     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
   8612 L_3100ACCE:
   8613     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
   8614     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
   8615     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
   8616     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8617     _flag_k = FK_CMP;
   8618     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
   8619 L_3100ACD6:
   8620     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
   8621     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
   8622 L_3100ACDB:
   8623     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
   8624 L_3100ACDD:
   8625     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
   8626     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
   8627 L_3100ACE3:
   8628     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
   8629     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
   8630     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
   8631     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
   8632     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
   8633     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
   8634     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
   8635     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
   8636     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
   8637     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
   8638     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
   8639     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
   8640     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8641     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8642     _flag_k = FK_CMP;
   8643     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
   8644 L_3100AD08:
   8645     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
   8646 L_3100AD0B:
   8647     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
   8648     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
   8649     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
   8650     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
   8651     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   8652     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8653     _flag_k = FK_CMP;
   8654     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
   8655 L_3100AD19:
   8656     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
   8657     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
   8658 L_3100AD1E:
   8659     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
   8660     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
   8661     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
   8662     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8663     _flag_k = FK_CMP;
   8664     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
   8665 L_3100AD25:
   8666     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
   8667     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
   8668 L_3100AD29:
   8669     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
   8670 L_3100AD2C:
   8671     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
   8672 L_3100AD2E:
   8673     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
   8674 L_3100AD31:
   8675     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
   8676     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
   8677     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   8678     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8679     _flag_k = FK_CMP;
   8680     RECOMP_BACKEDGE();
   8681     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
   8682 L_3100AD3D:
   8683     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
   8684     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
   8685     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
   8686     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
   8687     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
   8688     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
   8689     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
   8690     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
   8691     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
   8692     esp = ebp; /* 0x3100AD51: mov esp, ebp */
   8693     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
   8694     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
   8695     RECOMP_REGS_OUT();
   8696 }
   8697 
   8698 void sub_3100ABE1(void) {
   8699     int _fpu_cmp = 0;
   8700     uint32_t _cf = 0;
   8701     int _df = 1;
   8702     uint32_t _flag_k = FK_NONE;
   8703     uint32_t _flag_a = 0, _flag_b = 0;
   8704     uint32_t _itail_tgt = 0;
   8705     RECOMP_REGS_LOCALS
   8706     RECOMP_ENTER(0x3100ABE1u);
   8707 
   8708     goto L_3100ABE1;
   8709 L_3100ABBD:
   8710     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
   8711     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
   8712     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
   8713     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   8714     _cf = 0;
   8715     _flag_k = FK_NARROW(FK_TEST, 24);
   8716     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
   8717 L_3100ABCB:
   8718     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
   8719     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
   8720     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
   8721     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   8722     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8723     _flag_k = FK_CMP;
   8724     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
   8725 L_3100ABD8:
   8726     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
   8727     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
   8728     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   8729     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8730     _flag_k = FK_NARROW(FK_CMP, 24);
   8731     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
   8732 L_3100ABE1:
   8733     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
   8734     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
   8735     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
   8736     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
   8737     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
   8738     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
   8739     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
   8740     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
   8741 L_3100ABFC:
   8742     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
   8743     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x8));
   8744     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8745     _flag_k = FK_CMP;
   8746     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
   8747 L_3100AC01:
   8748     eax = ecx; /* 0x3100AC01: mov eax, ecx */
   8749     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
   8750     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
   8751     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
   8752     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
   8753     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
   8754     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8755     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8756     _flag_k = FK_CMP;
   8757     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
   8758 L_3100AC12:
   8759     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
   8760 L_3100AC15:
   8761     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
   8762     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
   8763     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
   8764     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
   8765     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   8766     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8767     _flag_k = FK_CMP;
   8768     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
   8769 L_3100AC23:
   8770     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
   8771     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
   8772 L_3100AC28:
   8773     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
   8774     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
   8775     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
   8776     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8777     _flag_k = FK_CMP;
   8778     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
   8779 L_3100AC2F:
   8780     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
   8781     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
   8782 L_3100AC33:
   8783     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
   8784 L_3100AC36:
   8785     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
   8786     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
   8787 L_3100AC3B:
   8788     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
   8789     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
   8790     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
   8791     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
   8792     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
   8793     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
   8794     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
   8795     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
   8796     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
   8797     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
   8798     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
   8799     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
   8800     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8801     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8802     _flag_k = FK_CMP;
   8803     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
   8804 L_3100AC60:
   8805     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
   8806 L_3100AC63:
   8807     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
   8808     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
   8809     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
   8810     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
   8811     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   8812     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8813     _flag_k = FK_CMP;
   8814     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
   8815 L_3100AC71:
   8816     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
   8817     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
   8818     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
   8819 L_3100AC7C:
   8820     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
   8821     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
   8822     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   8823     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8824     _flag_k = FK_CMP;
   8825     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
   8826 L_3100AC84:
   8827     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
   8828     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
   8829     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
   8830 L_3100AC8F:
   8831     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
   8832     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
   8833     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
   8834 L_3100AC99:
   8835     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
   8836     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   8837     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8838     _flag_k = FK_NARROW(FK_CMP, 24);
   8839     RECOMP_BACKEDGE();
   8840     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
   8841 L_3100ACA3:
   8842     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
   8843     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
   8844     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8845     _flag_k = FK_CMP;
   8846     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
   8847 L_3100ACA7:
   8848     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
   8849     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
   8850     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
   8851     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
   8852     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
   8853     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
   8854     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8855     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8856     _flag_k = FK_CMP;
   8857     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
   8858 L_3100ACB8:
   8859     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
   8860 L_3100ACBB:
   8861     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
   8862     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
   8863     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
   8864     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
   8865     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   8866     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8867     _flag_k = FK_CMP;
   8868     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
   8869 L_3100ACC9:
   8870     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
   8871     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
   8872 L_3100ACCE:
   8873     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
   8874     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
   8875     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
   8876     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8877     _flag_k = FK_CMP;
   8878     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
   8879 L_3100ACD6:
   8880     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
   8881     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
   8882 L_3100ACDB:
   8883     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
   8884 L_3100ACDD:
   8885     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
   8886     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
   8887 L_3100ACE3:
   8888     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
   8889     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
   8890     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
   8891     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
   8892     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
   8893     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
   8894     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
   8895     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
   8896     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
   8897     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
   8898     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
   8899     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
   8900     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   8901     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8902     _flag_k = FK_CMP;
   8903     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
   8904 L_3100AD08:
   8905     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
   8906 L_3100AD0B:
   8907     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
   8908     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
   8909     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
   8910     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
   8911     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   8912     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8913     _flag_k = FK_CMP;
   8914     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
   8915 L_3100AD19:
   8916     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
   8917     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
   8918 L_3100AD1E:
   8919     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
   8920     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
   8921     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
   8922     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8923     _flag_k = FK_CMP;
   8924     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
   8925 L_3100AD25:
   8926     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
   8927     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
   8928 L_3100AD29:
   8929     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
   8930 L_3100AD2C:
   8931     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
   8932 L_3100AD2E:
   8933     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
   8934 L_3100AD31:
   8935     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
   8936     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
   8937     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   8938     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8939     _flag_k = FK_CMP;
   8940     RECOMP_BACKEDGE();
   8941     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
   8942 L_3100AD3D:
   8943     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
   8944     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
   8945     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
   8946     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
   8947     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
   8948     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
   8949     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
   8950     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
   8951     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
   8952     esp = ebp; /* 0x3100AD51: mov esp, ebp */
   8953     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
   8954     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
   8955     RECOMP_REGS_OUT();
   8956 }
   8957 
   8958 void sub_3100AC36(void) {
   8959     int _fpu_cmp = 0;
   8960     uint32_t _cf = 0;
   8961     int _df = 1;
   8962     uint32_t _flag_k = FK_NONE;
   8963     uint32_t _flag_a = 0, _flag_b = 0;
   8964     uint32_t _itail_tgt = 0;
   8965     RECOMP_REGS_LOCALS
   8966     RECOMP_ENTER(0x3100AC36u);
   8967 
   8968     goto L_3100AC36;
   8969 L_3100ABBD:
   8970     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
   8971     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
   8972     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
   8973     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   8974     _cf = 0;
   8975     _flag_k = FK_NARROW(FK_TEST, 24);
   8976     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
   8977 L_3100ABCB:
   8978     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
   8979     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
   8980     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
   8981     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   8982     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8983     _flag_k = FK_CMP;
   8984     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
   8985 L_3100ABD8:
   8986     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
   8987     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
   8988     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   8989     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   8990     _flag_k = FK_NARROW(FK_CMP, 24);
   8991     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
   8992 L_3100ABE1:
   8993     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
   8994     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
   8995     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
   8996     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
   8997     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
   8998     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
   8999     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
   9000     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
   9001 L_3100ABFC:
   9002     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
   9003     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x8));
   9004     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9005     _flag_k = FK_CMP;
   9006     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
   9007 L_3100AC01:
   9008     eax = ecx; /* 0x3100AC01: mov eax, ecx */
   9009     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
   9010     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
   9011     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
   9012     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
   9013     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
   9014     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9015     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9016     _flag_k = FK_CMP;
   9017     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
   9018 L_3100AC12:
   9019     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
   9020 L_3100AC15:
   9021     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
   9022     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
   9023     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
   9024     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
   9025     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   9026     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9027     _flag_k = FK_CMP;
   9028     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
   9029 L_3100AC23:
   9030     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
   9031     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
   9032 L_3100AC28:
   9033     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
   9034     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
   9035     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
   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_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
   9039 L_3100AC2F:
   9040     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
   9041     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
   9042 L_3100AC33:
   9043     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
   9044 L_3100AC36:
   9045     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
   9046     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
   9047 L_3100AC3B:
   9048     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
   9049     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
   9050     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
   9051     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
   9052     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
   9053     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
   9054     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
   9055     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
   9056     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
   9057     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
   9058     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
   9059     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
   9060     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9061     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9062     _flag_k = FK_CMP;
   9063     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
   9064 L_3100AC60:
   9065     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
   9066 L_3100AC63:
   9067     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
   9068     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
   9069     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
   9070     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
   9071     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   9072     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9073     _flag_k = FK_CMP;
   9074     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
   9075 L_3100AC71:
   9076     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
   9077     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
   9078     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
   9079 L_3100AC7C:
   9080     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
   9081     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
   9082     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9083     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9084     _flag_k = FK_CMP;
   9085     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
   9086 L_3100AC84:
   9087     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
   9088     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
   9089     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
   9090 L_3100AC8F:
   9091     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
   9092     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
   9093     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
   9094 L_3100AC99:
   9095     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
   9096     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   9097     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9098     _flag_k = FK_NARROW(FK_CMP, 24);
   9099     RECOMP_BACKEDGE();
   9100     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
   9101 L_3100ACA3:
   9102     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
   9103     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
   9104     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9105     _flag_k = FK_CMP;
   9106     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
   9107 L_3100ACA7:
   9108     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
   9109     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
   9110     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
   9111     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
   9112     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
   9113     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
   9114     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9115     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9116     _flag_k = FK_CMP;
   9117     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
   9118 L_3100ACB8:
   9119     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
   9120 L_3100ACBB:
   9121     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
   9122     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
   9123     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
   9124     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
   9125     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   9126     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9127     _flag_k = FK_CMP;
   9128     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
   9129 L_3100ACC9:
   9130     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
   9131     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
   9132 L_3100ACCE:
   9133     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
   9134     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
   9135     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
   9136     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9137     _flag_k = FK_CMP;
   9138     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
   9139 L_3100ACD6:
   9140     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
   9141     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
   9142 L_3100ACDB:
   9143     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
   9144 L_3100ACDD:
   9145     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
   9146     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
   9147 L_3100ACE3:
   9148     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
   9149     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
   9150     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
   9151     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
   9152     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
   9153     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
   9154     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
   9155     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
   9156     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
   9157     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
   9158     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
   9159     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
   9160     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9161     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9162     _flag_k = FK_CMP;
   9163     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
   9164 L_3100AD08:
   9165     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
   9166 L_3100AD0B:
   9167     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
   9168     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
   9169     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
   9170     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
   9171     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   9172     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9173     _flag_k = FK_CMP;
   9174     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
   9175 L_3100AD19:
   9176     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
   9177     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
   9178 L_3100AD1E:
   9179     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
   9180     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
   9181     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
   9182     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9183     _flag_k = FK_CMP;
   9184     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
   9185 L_3100AD25:
   9186     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
   9187     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
   9188 L_3100AD29:
   9189     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
   9190 L_3100AD2C:
   9191     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
   9192 L_3100AD2E:
   9193     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
   9194 L_3100AD31:
   9195     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
   9196     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
   9197     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   9198     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9199     _flag_k = FK_CMP;
   9200     RECOMP_BACKEDGE();
   9201     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
   9202 L_3100AD3D:
   9203     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
   9204     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
   9205     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
   9206     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
   9207     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
   9208     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
   9209     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
   9210     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
   9211     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
   9212     esp = ebp; /* 0x3100AD51: mov esp, ebp */
   9213     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
   9214     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
   9215     RECOMP_REGS_OUT();
   9216 }
   9217 
   9218 void sub_3100AC3B(void) {
   9219     int _fpu_cmp = 0;
   9220     uint32_t _cf = 0;
   9221     int _df = 1;
   9222     uint32_t _flag_k = FK_NONE;
   9223     uint32_t _flag_a = 0, _flag_b = 0;
   9224     uint32_t _itail_tgt = 0;
   9225     RECOMP_REGS_LOCALS
   9226     RECOMP_ENTER(0x3100AC3Bu);
   9227 
   9228     goto L_3100AC3B;
   9229 L_3100ABBD:
   9230     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
   9231     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
   9232     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
   9233     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   9234     _cf = 0;
   9235     _flag_k = FK_NARROW(FK_TEST, 24);
   9236     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
   9237 L_3100ABCB:
   9238     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
   9239     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
   9240     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
   9241     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   9242     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9243     _flag_k = FK_CMP;
   9244     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
   9245 L_3100ABD8:
   9246     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
   9247     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
   9248     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   9249     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9250     _flag_k = FK_NARROW(FK_CMP, 24);
   9251     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
   9252 L_3100ABE1:
   9253     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
   9254     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
   9255     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
   9256     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
   9257     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
   9258     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
   9259     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
   9260     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
   9261 L_3100ABFC:
   9262     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
   9263     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x8));
   9264     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9265     _flag_k = FK_CMP;
   9266     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
   9267 L_3100AC01:
   9268     eax = ecx; /* 0x3100AC01: mov eax, ecx */
   9269     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
   9270     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
   9271     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
   9272     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
   9273     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
   9274     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9275     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9276     _flag_k = FK_CMP;
   9277     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
   9278 L_3100AC12:
   9279     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
   9280 L_3100AC15:
   9281     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
   9282     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
   9283     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
   9284     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
   9285     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   9286     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9287     _flag_k = FK_CMP;
   9288     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
   9289 L_3100AC23:
   9290     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
   9291     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
   9292 L_3100AC28:
   9293     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
   9294     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
   9295     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
   9296     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9297     _flag_k = FK_CMP;
   9298     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
   9299 L_3100AC2F:
   9300     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
   9301     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
   9302 L_3100AC33:
   9303     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
   9304 L_3100AC36:
   9305     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
   9306     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
   9307 L_3100AC3B:
   9308     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
   9309     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
   9310     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
   9311     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
   9312     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
   9313     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
   9314     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
   9315     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
   9316     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
   9317     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
   9318     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
   9319     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
   9320     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9321     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9322     _flag_k = FK_CMP;
   9323     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
   9324 L_3100AC60:
   9325     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
   9326 L_3100AC63:
   9327     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
   9328     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
   9329     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
   9330     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
   9331     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   9332     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9333     _flag_k = FK_CMP;
   9334     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
   9335 L_3100AC71:
   9336     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
   9337     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
   9338     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
   9339 L_3100AC7C:
   9340     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
   9341     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
   9342     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9343     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9344     _flag_k = FK_CMP;
   9345     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
   9346 L_3100AC84:
   9347     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
   9348     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
   9349     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
   9350 L_3100AC8F:
   9351     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
   9352     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
   9353     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
   9354 L_3100AC99:
   9355     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
   9356     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   9357     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9358     _flag_k = FK_NARROW(FK_CMP, 24);
   9359     RECOMP_BACKEDGE();
   9360     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
   9361 L_3100ACA3:
   9362     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
   9363     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
   9364     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9365     _flag_k = FK_CMP;
   9366     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
   9367 L_3100ACA7:
   9368     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
   9369     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
   9370     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
   9371     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
   9372     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
   9373     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
   9374     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9375     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9376     _flag_k = FK_CMP;
   9377     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
   9378 L_3100ACB8:
   9379     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
   9380 L_3100ACBB:
   9381     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
   9382     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
   9383     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
   9384     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
   9385     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   9386     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9387     _flag_k = FK_CMP;
   9388     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
   9389 L_3100ACC9:
   9390     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
   9391     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
   9392 L_3100ACCE:
   9393     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
   9394     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
   9395     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
   9396     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9397     _flag_k = FK_CMP;
   9398     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
   9399 L_3100ACD6:
   9400     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
   9401     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
   9402 L_3100ACDB:
   9403     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
   9404 L_3100ACDD:
   9405     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
   9406     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
   9407 L_3100ACE3:
   9408     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
   9409     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
   9410     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
   9411     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
   9412     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
   9413     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
   9414     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
   9415     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
   9416     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
   9417     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
   9418     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
   9419     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
   9420     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9421     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9422     _flag_k = FK_CMP;
   9423     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
   9424 L_3100AD08:
   9425     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
   9426 L_3100AD0B:
   9427     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
   9428     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
   9429     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
   9430     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
   9431     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   9432     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9433     _flag_k = FK_CMP;
   9434     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
   9435 L_3100AD19:
   9436     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
   9437     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
   9438 L_3100AD1E:
   9439     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
   9440     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
   9441     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
   9442     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9443     _flag_k = FK_CMP;
   9444     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
   9445 L_3100AD25:
   9446     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
   9447     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
   9448 L_3100AD29:
   9449     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
   9450 L_3100AD2C:
   9451     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
   9452 L_3100AD2E:
   9453     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
   9454 L_3100AD31:
   9455     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
   9456     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
   9457     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   9458     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9459     _flag_k = FK_CMP;
   9460     RECOMP_BACKEDGE();
   9461     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
   9462 L_3100AD3D:
   9463     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
   9464     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
   9465     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
   9466     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
   9467     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
   9468     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
   9469     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
   9470     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
   9471     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
   9472     esp = ebp; /* 0x3100AD51: mov esp, ebp */
   9473     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
   9474     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
   9475     RECOMP_REGS_OUT();
   9476 }
   9477 
   9478 void sub_3100AC99(void) {
   9479     int _fpu_cmp = 0;
   9480     uint32_t _cf = 0;
   9481     int _df = 1;
   9482     uint32_t _flag_k = FK_NONE;
   9483     uint32_t _flag_a = 0, _flag_b = 0;
   9484     uint32_t _itail_tgt = 0;
   9485     RECOMP_REGS_LOCALS
   9486     RECOMP_ENTER(0x3100AC99u);
   9487 
   9488     goto L_3100AC99;
   9489 L_3100ABBD:
   9490     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
   9491     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
   9492     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
   9493     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   9494     _cf = 0;
   9495     _flag_k = FK_NARROW(FK_TEST, 24);
   9496     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
   9497 L_3100ABCB:
   9498     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
   9499     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
   9500     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
   9501     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   9502     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9503     _flag_k = FK_CMP;
   9504     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
   9505 L_3100ABD8:
   9506     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
   9507     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
   9508     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   9509     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9510     _flag_k = FK_NARROW(FK_CMP, 24);
   9511     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
   9512 L_3100ABE1:
   9513     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
   9514     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
   9515     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
   9516     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
   9517     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
   9518     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
   9519     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
   9520     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
   9521 L_3100ABFC:
   9522     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
   9523     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 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_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
   9527 L_3100AC01:
   9528     eax = ecx; /* 0x3100AC01: mov eax, ecx */
   9529     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
   9530     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
   9531     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
   9532     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
   9533     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
   9534     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9535     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9536     _flag_k = FK_CMP;
   9537     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
   9538 L_3100AC12:
   9539     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
   9540 L_3100AC15:
   9541     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
   9542     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
   9543     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
   9544     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
   9545     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   9546     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9547     _flag_k = FK_CMP;
   9548     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
   9549 L_3100AC23:
   9550     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
   9551     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
   9552 L_3100AC28:
   9553     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
   9554     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
   9555     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
   9556     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9557     _flag_k = FK_CMP;
   9558     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
   9559 L_3100AC2F:
   9560     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
   9561     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
   9562 L_3100AC33:
   9563     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
   9564 L_3100AC36:
   9565     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
   9566     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
   9567 L_3100AC3B:
   9568     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
   9569     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
   9570     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
   9571     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
   9572     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
   9573     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
   9574     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
   9575     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
   9576     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
   9577     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
   9578     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
   9579     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
   9580     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9581     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9582     _flag_k = FK_CMP;
   9583     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
   9584 L_3100AC60:
   9585     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
   9586 L_3100AC63:
   9587     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
   9588     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
   9589     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
   9590     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
   9591     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   9592     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9593     _flag_k = FK_CMP;
   9594     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
   9595 L_3100AC71:
   9596     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
   9597     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
   9598     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
   9599 L_3100AC7C:
   9600     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
   9601     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
   9602     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   9603     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9604     _flag_k = FK_CMP;
   9605     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
   9606 L_3100AC84:
   9607     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
   9608     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
   9609     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
   9610 L_3100AC8F:
   9611     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
   9612     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
   9613     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
   9614 L_3100AC99:
   9615     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
   9616     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   9617     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9618     _flag_k = FK_NARROW(FK_CMP, 24);
   9619     RECOMP_BACKEDGE();
   9620     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
   9621 L_3100ACA3:
   9622     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
   9623     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
   9624     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9625     _flag_k = FK_CMP;
   9626     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
   9627 L_3100ACA7:
   9628     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
   9629     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
   9630     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
   9631     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
   9632     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
   9633     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
   9634     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9635     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9636     _flag_k = FK_CMP;
   9637     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
   9638 L_3100ACB8:
   9639     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
   9640 L_3100ACBB:
   9641     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
   9642     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
   9643     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
   9644     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
   9645     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   9646     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9647     _flag_k = FK_CMP;
   9648     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
   9649 L_3100ACC9:
   9650     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
   9651     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
   9652 L_3100ACCE:
   9653     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
   9654     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
   9655     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
   9656     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9657     _flag_k = FK_CMP;
   9658     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
   9659 L_3100ACD6:
   9660     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
   9661     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
   9662 L_3100ACDB:
   9663     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
   9664 L_3100ACDD:
   9665     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
   9666     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
   9667 L_3100ACE3:
   9668     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
   9669     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
   9670     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
   9671     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
   9672     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
   9673     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
   9674     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
   9675     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
   9676     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
   9677     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
   9678     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
   9679     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
   9680     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9681     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9682     _flag_k = FK_CMP;
   9683     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
   9684 L_3100AD08:
   9685     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
   9686 L_3100AD0B:
   9687     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
   9688     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
   9689     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
   9690     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
   9691     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   9692     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9693     _flag_k = FK_CMP;
   9694     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
   9695 L_3100AD19:
   9696     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
   9697     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
   9698 L_3100AD1E:
   9699     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
   9700     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
   9701     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
   9702     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9703     _flag_k = FK_CMP;
   9704     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
   9705 L_3100AD25:
   9706     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
   9707     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
   9708 L_3100AD29:
   9709     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
   9710 L_3100AD2C:
   9711     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
   9712 L_3100AD2E:
   9713     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
   9714 L_3100AD31:
   9715     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
   9716     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
   9717     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   9718     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9719     _flag_k = FK_CMP;
   9720     RECOMP_BACKEDGE();
   9721     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
   9722 L_3100AD3D:
   9723     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
   9724     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
   9725     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
   9726     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
   9727     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
   9728     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
   9729     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
   9730     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
   9731     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
   9732     esp = ebp; /* 0x3100AD51: mov esp, ebp */
   9733     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
   9734     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
   9735     RECOMP_REGS_OUT();
   9736 }
   9737 
   9738 void sub_3100ACDD(void) {
   9739     int _fpu_cmp = 0;
   9740     uint32_t _cf = 0;
   9741     int _df = 1;
   9742     uint32_t _flag_k = FK_NONE;
   9743     uint32_t _flag_a = 0, _flag_b = 0;
   9744     uint32_t _itail_tgt = 0;
   9745     RECOMP_REGS_LOCALS
   9746     RECOMP_ENTER(0x3100ACDDu);
   9747 
   9748     goto L_3100ACDD;
   9749 L_3100ABBD:
   9750     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
   9751     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
   9752     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
   9753     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
   9754     _cf = 0;
   9755     _flag_k = FK_NARROW(FK_TEST, 24);
   9756     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
   9757 L_3100ABCB:
   9758     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
   9759     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
   9760     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
   9761     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
   9762     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9763     _flag_k = FK_CMP;
   9764     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
   9765 L_3100ABD8:
   9766     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
   9767     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
   9768     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   9769     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9770     _flag_k = FK_NARROW(FK_CMP, 24);
   9771     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
   9772 L_3100ABE1:
   9773     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
   9774     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
   9775     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
   9776     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
   9777     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
   9778     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
   9779     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
   9780     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
   9781 L_3100ABFC:
   9782     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
   9783     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x8));
   9784     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9785     _flag_k = FK_CMP;
   9786     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
   9787 L_3100AC01:
   9788     eax = ecx; /* 0x3100AC01: mov eax, ecx */
   9789     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
   9790     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
   9791     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
   9792     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
   9793     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
   9794     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9795     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9796     _flag_k = FK_CMP;
   9797     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
   9798 L_3100AC12:
   9799     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
   9800 L_3100AC15:
   9801     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
   9802     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
   9803     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
   9804     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
   9805     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   9806     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9807     _flag_k = FK_CMP;
   9808     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
   9809 L_3100AC23:
   9810     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
   9811     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
   9812 L_3100AC28:
   9813     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
   9814     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
   9815     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
   9816     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9817     _flag_k = FK_CMP;
   9818     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
   9819 L_3100AC2F:
   9820     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
   9821     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
   9822 L_3100AC33:
   9823     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
   9824 L_3100AC36:
   9825     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
   9826     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
   9827 L_3100AC3B:
   9828     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
   9829     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
   9830     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
   9831     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
   9832     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
   9833     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
   9834     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
   9835     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
   9836     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
   9837     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
   9838     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
   9839     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
   9840     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9841     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9842     _flag_k = FK_CMP;
   9843     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
   9844 L_3100AC60:
   9845     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
   9846 L_3100AC63:
   9847     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
   9848     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
   9849     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
   9850     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
   9851     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   9852     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9853     _flag_k = FK_CMP;
   9854     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
   9855 L_3100AC71:
   9856     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
   9857     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
   9858     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
   9859 L_3100AC7C:
   9860     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
   9861     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
   9862     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
   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_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
   9866 L_3100AC84:
   9867     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
   9868     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
   9869     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
   9870 L_3100AC8F:
   9871     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
   9872     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
   9873     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
   9874 L_3100AC99:
   9875     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
   9876     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
   9877     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9878     _flag_k = FK_NARROW(FK_CMP, 24);
   9879     RECOMP_BACKEDGE();
   9880     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
   9881 L_3100ACA3:
   9882     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
   9883     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
   9884     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9885     _flag_k = FK_CMP;
   9886     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
   9887 L_3100ACA7:
   9888     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
   9889     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
   9890     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
   9891     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
   9892     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
   9893     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
   9894     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9895     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9896     _flag_k = FK_CMP;
   9897     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
   9898 L_3100ACB8:
   9899     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
   9900 L_3100ACBB:
   9901     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
   9902     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
   9903     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
   9904     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
   9905     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
   9906     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9907     _flag_k = FK_CMP;
   9908     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
   9909 L_3100ACC9:
   9910     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
   9911     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
   9912 L_3100ACCE:
   9913     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
   9914     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
   9915     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
   9916     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9917     _flag_k = FK_CMP;
   9918     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
   9919 L_3100ACD6:
   9920     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
   9921     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
   9922 L_3100ACDB:
   9923     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
   9924 L_3100ACDD:
   9925     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
   9926     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
   9927 L_3100ACE3:
   9928     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
   9929     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
   9930     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
   9931     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
   9932     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
   9933     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
   9934     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
   9935     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
   9936     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
   9937     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
   9938     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
   9939     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
   9940     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
   9941     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9942     _flag_k = FK_CMP;
   9943     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
   9944 L_3100AD08:
   9945     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
   9946 L_3100AD0B:
   9947     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
   9948     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
   9949     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
   9950     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
   9951     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
   9952     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9953     _flag_k = FK_CMP;
   9954     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
   9955 L_3100AD19:
   9956     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
   9957     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
   9958 L_3100AD1E:
   9959     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
   9960     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
   9961     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
   9962     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9963     _flag_k = FK_CMP;
   9964     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
   9965 L_3100AD25:
   9966     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
   9967     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
   9968 L_3100AD29:
   9969     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
   9970 L_3100AD2C:
   9971     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
   9972 L_3100AD2E:
   9973     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
   9974 L_3100AD31:
   9975     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
   9976     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
   9977     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
   9978     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
   9979     _flag_k = FK_CMP;
   9980     RECOMP_BACKEDGE();
   9981     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
   9982 L_3100AD3D:
   9983     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
   9984     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
   9985     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
   9986     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
   9987     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
   9988     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
   9989     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
   9990     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
   9991     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
   9992     esp = ebp; /* 0x3100AD51: mov esp, ebp */
   9993     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
   9994     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
   9995     RECOMP_REGS_OUT();
   9996 }
   9997 
   9998 void sub_3100ACE3(void) {
   9999     int _fpu_cmp = 0;
  10000     uint32_t _cf = 0;
  10001     int _df = 1;
  10002     uint32_t _flag_k = FK_NONE;
  10003     uint32_t _flag_a = 0, _flag_b = 0;
  10004     uint32_t _itail_tgt = 0;
  10005     RECOMP_REGS_LOCALS
  10006     RECOMP_ENTER(0x3100ACE3u);
  10007 
  10008     goto L_3100ACE3;
  10009 L_3100ABBD:
  10010     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
  10011     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
  10012     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
  10013     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  10014     _cf = 0;
  10015     _flag_k = FK_NARROW(FK_TEST, 24);
  10016     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
  10017 L_3100ABCB:
  10018     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
  10019     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
  10020     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
  10021     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
  10022     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10023     _flag_k = FK_CMP;
  10024     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
  10025 L_3100ABD8:
  10026     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
  10027     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
  10028     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
  10029     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10030     _flag_k = FK_NARROW(FK_CMP, 24);
  10031     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
  10032 L_3100ABE1:
  10033     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
  10034     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
  10035     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
  10036     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
  10037     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
  10038     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
  10039     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
  10040     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
  10041 L_3100ABFC:
  10042     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
  10043     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x8));
  10044     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10045     _flag_k = FK_CMP;
  10046     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
  10047 L_3100AC01:
  10048     eax = ecx; /* 0x3100AC01: mov eax, ecx */
  10049     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
  10050     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
  10051     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
  10052     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
  10053     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
  10054     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10055     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10056     _flag_k = FK_CMP;
  10057     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
  10058 L_3100AC12:
  10059     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
  10060 L_3100AC15:
  10061     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
  10062     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
  10063     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
  10064     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
  10065     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
  10066     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10067     _flag_k = FK_CMP;
  10068     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
  10069 L_3100AC23:
  10070     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
  10071     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
  10072 L_3100AC28:
  10073     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
  10074     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
  10075     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
  10076     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10077     _flag_k = FK_CMP;
  10078     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
  10079 L_3100AC2F:
  10080     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
  10081     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
  10082 L_3100AC33:
  10083     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
  10084 L_3100AC36:
  10085     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
  10086     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
  10087 L_3100AC3B:
  10088     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
  10089     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
  10090     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
  10091     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
  10092     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
  10093     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
  10094     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
  10095     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
  10096     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
  10097     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
  10098     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
  10099     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
  10100     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10101     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10102     _flag_k = FK_CMP;
  10103     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
  10104 L_3100AC60:
  10105     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
  10106 L_3100AC63:
  10107     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
  10108     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
  10109     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
  10110     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
  10111     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
  10112     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10113     _flag_k = FK_CMP;
  10114     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
  10115 L_3100AC71:
  10116     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
  10117     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
  10118     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
  10119 L_3100AC7C:
  10120     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
  10121     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
  10122     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10123     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10124     _flag_k = FK_CMP;
  10125     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
  10126 L_3100AC84:
  10127     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
  10128     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
  10129     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
  10130 L_3100AC8F:
  10131     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
  10132     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
  10133     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
  10134 L_3100AC99:
  10135     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
  10136     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
  10137     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10138     _flag_k = FK_NARROW(FK_CMP, 24);
  10139     RECOMP_BACKEDGE();
  10140     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
  10141 L_3100ACA3:
  10142     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
  10143     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
  10144     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10145     _flag_k = FK_CMP;
  10146     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
  10147 L_3100ACA7:
  10148     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
  10149     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
  10150     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
  10151     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
  10152     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
  10153     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
  10154     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10155     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10156     _flag_k = FK_CMP;
  10157     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
  10158 L_3100ACB8:
  10159     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
  10160 L_3100ACBB:
  10161     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
  10162     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
  10163     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
  10164     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
  10165     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
  10166     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10167     _flag_k = FK_CMP;
  10168     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
  10169 L_3100ACC9:
  10170     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
  10171     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
  10172 L_3100ACCE:
  10173     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
  10174     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
  10175     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
  10176     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10177     _flag_k = FK_CMP;
  10178     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
  10179 L_3100ACD6:
  10180     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
  10181     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
  10182 L_3100ACDB:
  10183     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
  10184 L_3100ACDD:
  10185     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
  10186     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
  10187 L_3100ACE3:
  10188     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
  10189     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
  10190     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
  10191     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
  10192     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
  10193     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
  10194     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
  10195     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
  10196     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
  10197     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
  10198     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
  10199     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
  10200     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10201     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10202     _flag_k = FK_CMP;
  10203     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
  10204 L_3100AD08:
  10205     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
  10206 L_3100AD0B:
  10207     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
  10208     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
  10209     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
  10210     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
  10211     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
  10212     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10213     _flag_k = FK_CMP;
  10214     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
  10215 L_3100AD19:
  10216     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
  10217     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
  10218 L_3100AD1E:
  10219     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
  10220     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
  10221     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
  10222     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10223     _flag_k = FK_CMP;
  10224     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
  10225 L_3100AD25:
  10226     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
  10227     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
  10228 L_3100AD29:
  10229     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
  10230 L_3100AD2C:
  10231     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
  10232 L_3100AD2E:
  10233     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
  10234 L_3100AD31:
  10235     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
  10236     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
  10237     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  10238     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10239     _flag_k = FK_CMP;
  10240     RECOMP_BACKEDGE();
  10241     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
  10242 L_3100AD3D:
  10243     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
  10244     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
  10245     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
  10246     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
  10247     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
  10248     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
  10249     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
  10250     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
  10251     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
  10252     esp = ebp; /* 0x3100AD51: mov esp, ebp */
  10253     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
  10254     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
  10255     RECOMP_REGS_OUT();
  10256 }
  10257 
  10258 void sub_3100AD2C(void) {
  10259     int _fpu_cmp = 0;
  10260     uint32_t _cf = 0;
  10261     int _df = 1;
  10262     uint32_t _flag_k = FK_NONE;
  10263     uint32_t _flag_a = 0, _flag_b = 0;
  10264     uint32_t _itail_tgt = 0;
  10265     RECOMP_REGS_LOCALS
  10266     RECOMP_ENTER(0x3100AD2Cu);
  10267 
  10268     goto L_3100AD2C;
  10269 L_3100ABBD:
  10270     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
  10271     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
  10272     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
  10273     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  10274     _cf = 0;
  10275     _flag_k = FK_NARROW(FK_TEST, 24);
  10276     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
  10277 L_3100ABCB:
  10278     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
  10279     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
  10280     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
  10281     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
  10282     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10283     _flag_k = FK_CMP;
  10284     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
  10285 L_3100ABD8:
  10286     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
  10287     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
  10288     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
  10289     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10290     _flag_k = FK_NARROW(FK_CMP, 24);
  10291     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
  10292 L_3100ABE1:
  10293     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
  10294     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
  10295     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
  10296     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
  10297     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
  10298     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
  10299     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
  10300     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
  10301 L_3100ABFC:
  10302     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
  10303     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x8));
  10304     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10305     _flag_k = FK_CMP;
  10306     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
  10307 L_3100AC01:
  10308     eax = ecx; /* 0x3100AC01: mov eax, ecx */
  10309     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
  10310     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
  10311     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
  10312     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
  10313     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
  10314     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10315     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10316     _flag_k = FK_CMP;
  10317     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
  10318 L_3100AC12:
  10319     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
  10320 L_3100AC15:
  10321     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
  10322     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
  10323     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
  10324     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
  10325     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
  10326     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10327     _flag_k = FK_CMP;
  10328     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
  10329 L_3100AC23:
  10330     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
  10331     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
  10332 L_3100AC28:
  10333     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
  10334     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
  10335     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
  10336     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10337     _flag_k = FK_CMP;
  10338     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
  10339 L_3100AC2F:
  10340     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
  10341     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
  10342 L_3100AC33:
  10343     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
  10344 L_3100AC36:
  10345     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
  10346     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
  10347 L_3100AC3B:
  10348     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
  10349     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
  10350     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
  10351     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
  10352     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
  10353     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
  10354     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
  10355     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
  10356     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
  10357     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
  10358     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
  10359     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
  10360     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10361     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10362     _flag_k = FK_CMP;
  10363     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
  10364 L_3100AC60:
  10365     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
  10366 L_3100AC63:
  10367     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
  10368     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
  10369     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
  10370     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
  10371     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
  10372     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10373     _flag_k = FK_CMP;
  10374     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
  10375 L_3100AC71:
  10376     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
  10377     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
  10378     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
  10379 L_3100AC7C:
  10380     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
  10381     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
  10382     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10383     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10384     _flag_k = FK_CMP;
  10385     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
  10386 L_3100AC84:
  10387     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
  10388     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
  10389     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
  10390 L_3100AC8F:
  10391     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
  10392     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
  10393     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
  10394 L_3100AC99:
  10395     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
  10396     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
  10397     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10398     _flag_k = FK_NARROW(FK_CMP, 24);
  10399     RECOMP_BACKEDGE();
  10400     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
  10401 L_3100ACA3:
  10402     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
  10403     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
  10404     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10405     _flag_k = FK_CMP;
  10406     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
  10407 L_3100ACA7:
  10408     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
  10409     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
  10410     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
  10411     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
  10412     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
  10413     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
  10414     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10415     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10416     _flag_k = FK_CMP;
  10417     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
  10418 L_3100ACB8:
  10419     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
  10420 L_3100ACBB:
  10421     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
  10422     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
  10423     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
  10424     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
  10425     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
  10426     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10427     _flag_k = FK_CMP;
  10428     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
  10429 L_3100ACC9:
  10430     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
  10431     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
  10432 L_3100ACCE:
  10433     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
  10434     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
  10435     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
  10436     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10437     _flag_k = FK_CMP;
  10438     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
  10439 L_3100ACD6:
  10440     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
  10441     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
  10442 L_3100ACDB:
  10443     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
  10444 L_3100ACDD:
  10445     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
  10446     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
  10447 L_3100ACE3:
  10448     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
  10449     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
  10450     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
  10451     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
  10452     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
  10453     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
  10454     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
  10455     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
  10456     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
  10457     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
  10458     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
  10459     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
  10460     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10461     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10462     _flag_k = FK_CMP;
  10463     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
  10464 L_3100AD08:
  10465     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
  10466 L_3100AD0B:
  10467     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
  10468     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
  10469     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
  10470     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
  10471     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
  10472     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10473     _flag_k = FK_CMP;
  10474     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
  10475 L_3100AD19:
  10476     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
  10477     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
  10478 L_3100AD1E:
  10479     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
  10480     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
  10481     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
  10482     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10483     _flag_k = FK_CMP;
  10484     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
  10485 L_3100AD25:
  10486     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
  10487     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
  10488 L_3100AD29:
  10489     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
  10490 L_3100AD2C:
  10491     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
  10492 L_3100AD2E:
  10493     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
  10494 L_3100AD31:
  10495     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
  10496     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
  10497     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  10498     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10499     _flag_k = FK_CMP;
  10500     RECOMP_BACKEDGE();
  10501     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
  10502 L_3100AD3D:
  10503     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
  10504     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
  10505     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
  10506     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
  10507     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
  10508     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
  10509     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
  10510     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
  10511     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
  10512     esp = ebp; /* 0x3100AD51: mov esp, ebp */
  10513     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
  10514     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
  10515     RECOMP_REGS_OUT();
  10516 }
  10517 
  10518 void sub_3100AD2E(void) {
  10519     int _fpu_cmp = 0;
  10520     uint32_t _cf = 0;
  10521     int _df = 1;
  10522     uint32_t _flag_k = FK_NONE;
  10523     uint32_t _flag_a = 0, _flag_b = 0;
  10524     uint32_t _itail_tgt = 0;
  10525     RECOMP_REGS_LOCALS
  10526     RECOMP_ENTER(0x3100AD2Eu);
  10527 
  10528     goto L_3100AD2E;
  10529 L_3100ABBD:
  10530     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
  10531     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
  10532     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
  10533     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  10534     _cf = 0;
  10535     _flag_k = FK_NARROW(FK_TEST, 24);
  10536     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
  10537 L_3100ABCB:
  10538     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
  10539     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
  10540     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
  10541     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
  10542     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10543     _flag_k = FK_CMP;
  10544     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
  10545 L_3100ABD8:
  10546     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
  10547     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
  10548     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
  10549     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10550     _flag_k = FK_NARROW(FK_CMP, 24);
  10551     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
  10552 L_3100ABE1:
  10553     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
  10554     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
  10555     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
  10556     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
  10557     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
  10558     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
  10559     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
  10560     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
  10561 L_3100ABFC:
  10562     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
  10563     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x8));
  10564     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10565     _flag_k = FK_CMP;
  10566     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
  10567 L_3100AC01:
  10568     eax = ecx; /* 0x3100AC01: mov eax, ecx */
  10569     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
  10570     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
  10571     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
  10572     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
  10573     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
  10574     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10575     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10576     _flag_k = FK_CMP;
  10577     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
  10578 L_3100AC12:
  10579     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
  10580 L_3100AC15:
  10581     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
  10582     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
  10583     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
  10584     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
  10585     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
  10586     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10587     _flag_k = FK_CMP;
  10588     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
  10589 L_3100AC23:
  10590     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
  10591     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
  10592 L_3100AC28:
  10593     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
  10594     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
  10595     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
  10596     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10597     _flag_k = FK_CMP;
  10598     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
  10599 L_3100AC2F:
  10600     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
  10601     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
  10602 L_3100AC33:
  10603     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
  10604 L_3100AC36:
  10605     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
  10606     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
  10607 L_3100AC3B:
  10608     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
  10609     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
  10610     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
  10611     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
  10612     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
  10613     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
  10614     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
  10615     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
  10616     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
  10617     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
  10618     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
  10619     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
  10620     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10621     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10622     _flag_k = FK_CMP;
  10623     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
  10624 L_3100AC60:
  10625     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
  10626 L_3100AC63:
  10627     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
  10628     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
  10629     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
  10630     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
  10631     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
  10632     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10633     _flag_k = FK_CMP;
  10634     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
  10635 L_3100AC71:
  10636     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
  10637     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
  10638     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
  10639 L_3100AC7C:
  10640     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
  10641     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
  10642     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10643     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10644     _flag_k = FK_CMP;
  10645     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
  10646 L_3100AC84:
  10647     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
  10648     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
  10649     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
  10650 L_3100AC8F:
  10651     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
  10652     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
  10653     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
  10654 L_3100AC99:
  10655     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
  10656     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
  10657     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10658     _flag_k = FK_NARROW(FK_CMP, 24);
  10659     RECOMP_BACKEDGE();
  10660     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
  10661 L_3100ACA3:
  10662     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
  10663     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
  10664     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10665     _flag_k = FK_CMP;
  10666     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
  10667 L_3100ACA7:
  10668     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
  10669     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
  10670     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
  10671     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
  10672     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
  10673     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
  10674     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10675     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10676     _flag_k = FK_CMP;
  10677     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
  10678 L_3100ACB8:
  10679     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
  10680 L_3100ACBB:
  10681     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
  10682     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
  10683     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
  10684     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
  10685     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
  10686     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10687     _flag_k = FK_CMP;
  10688     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
  10689 L_3100ACC9:
  10690     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
  10691     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
  10692 L_3100ACCE:
  10693     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
  10694     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
  10695     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
  10696     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10697     _flag_k = FK_CMP;
  10698     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
  10699 L_3100ACD6:
  10700     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
  10701     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
  10702 L_3100ACDB:
  10703     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
  10704 L_3100ACDD:
  10705     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
  10706     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
  10707 L_3100ACE3:
  10708     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
  10709     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
  10710     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
  10711     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
  10712     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
  10713     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
  10714     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
  10715     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
  10716     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
  10717     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
  10718     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
  10719     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
  10720     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10721     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10722     _flag_k = FK_CMP;
  10723     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
  10724 L_3100AD08:
  10725     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
  10726 L_3100AD0B:
  10727     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
  10728     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
  10729     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
  10730     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
  10731     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
  10732     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10733     _flag_k = FK_CMP;
  10734     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
  10735 L_3100AD19:
  10736     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
  10737     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
  10738 L_3100AD1E:
  10739     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
  10740     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
  10741     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
  10742     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10743     _flag_k = FK_CMP;
  10744     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
  10745 L_3100AD25:
  10746     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
  10747     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
  10748 L_3100AD29:
  10749     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
  10750 L_3100AD2C:
  10751     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
  10752 L_3100AD2E:
  10753     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
  10754 L_3100AD31:
  10755     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
  10756     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
  10757     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  10758     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10759     _flag_k = FK_CMP;
  10760     RECOMP_BACKEDGE();
  10761     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
  10762 L_3100AD3D:
  10763     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
  10764     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
  10765     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
  10766     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
  10767     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
  10768     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
  10769     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
  10770     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
  10771     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
  10772     esp = ebp; /* 0x3100AD51: mov esp, ebp */
  10773     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
  10774     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
  10775     RECOMP_REGS_OUT();
  10776 }
  10777 
  10778 void sub_3100AD31(void) {
  10779     int _fpu_cmp = 0;
  10780     uint32_t _cf = 0;
  10781     int _df = 1;
  10782     uint32_t _flag_k = FK_NONE;
  10783     uint32_t _flag_a = 0, _flag_b = 0;
  10784     uint32_t _itail_tgt = 0;
  10785     RECOMP_REGS_LOCALS
  10786     RECOMP_ENTER(0x3100AD31u);
  10787 
  10788     goto L_3100AD31;
  10789 L_3100ABBD:
  10790     ecx = MEM32(eax + 0x4); /* 0x3100ABBD: mov ecx, dword ptr [eax + 4] */
  10791     SET_LO8(edx, MEM8(ecx + 0x14)); /* 0x3100ABC0: mov dl, byte ptr [ecx + 0x14] */
  10792     /* test LO8(edx), LO8(edx) */ /* 0x3100ABC3: test dl, dl */
  10793     _flag_a = (uint32_t)(LO8(edx)) << 24; _flag_b = (uint32_t)(LO8(edx)) << 24;
  10794     _cf = 0;
  10795     _flag_k = FK_NARROW(FK_TEST, 24);
  10796     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD3D; /* 0x3100ABC5: jne 0x3100ad3d */
  10797 L_3100ABCB:
  10798     edi = MEM32(ecx + 0x4); /* 0x3100ABCB: mov edi, dword ptr [ecx + 4] */
  10799     edx = MEM32(edi); /* 0x3100ABCE: mov edx, dword ptr [edi] */
  10800     /* cmp ecx, edx */ /* 0x3100ABD0: cmp ecx, edx */
  10801     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
  10802     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10803     _flag_k = FK_CMP;
  10804     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC99; /* 0x3100ABD2: jne 0x3100ac99 */
  10805 L_3100ABD8:
  10806     edx = MEM32(edi + 0x8); /* 0x3100ABD8: mov edx, dword ptr [edi + 8] */
  10807     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100ABDB: cmp byte ptr [edx + 0x14], 0 */
  10808     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
  10809     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10810     _flag_k = FK_NARROW(FK_CMP, 24);
  10811     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABFC; /* 0x3100ABDF: jne 0x3100abfc */
  10812 L_3100ABE1:
  10813     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE1: mov byte ptr [ecx + 0x14], bl */
  10814     MEM8(edx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ABE4: mov byte ptr [edx + 0x14], bl */
  10815     ecx = MEM32(eax + 0x4); /* 0x3100ABE7: mov ecx, dword ptr [eax + 4] */
  10816     edx = MEM32(ecx + 0x4); /* 0x3100ABEA: mov edx, dword ptr [ecx + 4] */
  10817     MEM8(edx + 0x14) = (uint8_t)(0); /* 0x3100ABED: mov byte ptr [edx + 0x14], 0 */
  10818     eax = MEM32(eax + 0x4); /* 0x3100ABF1: mov eax, dword ptr [eax + 4] */
  10819     eax = MEM32(eax + 0x4); /* 0x3100ABF4: mov eax, dword ptr [eax + 4] */
  10820     goto L_3100AD31; /* 0x3100ABF7: jmp 0x3100ad31 */
  10821 L_3100ABFC:
  10822     /* cmp eax, MEM32(ecx + 0x8) */ /* 0x3100ABFC: cmp eax, dword ptr [ecx + 8] */
  10823     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x8));
  10824     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10825     _flag_k = FK_CMP;
  10826     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC3B; /* 0x3100ABFF: jne 0x3100ac3b */
  10827 L_3100AC01:
  10828     eax = ecx; /* 0x3100AC01: mov eax, ecx */
  10829     ecx = MEM32(eax + 0x8); /* 0x3100AC03: mov ecx, dword ptr [eax + 8] */
  10830     edx = MEM32(ecx); /* 0x3100AC06: mov edx, dword ptr [ecx] */
  10831     MEM32(eax + 0x8) = edx; /* 0x3100AC08: mov dword ptr [eax + 8], edx */
  10832     edx = MEM32(ecx); /* 0x3100AC0B: mov edx, dword ptr [ecx] */
  10833     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100AC0D: cmp edx, dword ptr [esi + 8] */
  10834     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10835     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10836     _flag_k = FK_CMP;
  10837     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC15; /* 0x3100AC10: je 0x3100ac15 */
  10838 L_3100AC12:
  10839     MEM32(edx + 0x4) = eax; /* 0x3100AC12: mov dword ptr [edx + 4], eax */
  10840 L_3100AC15:
  10841     edx = MEM32(eax + 0x4); /* 0x3100AC15: mov edx, dword ptr [eax + 4] */
  10842     MEM32(ecx + 0x4) = edx; /* 0x3100AC18: mov dword ptr [ecx + 4], edx */
  10843     edx = MEM32(esi + 0x4); /* 0x3100AC1B: mov edx, dword ptr [esi + 4] */
  10844     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100AC1E: cmp eax, dword ptr [edx + 4] */
  10845     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
  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_3100AC28; /* 0x3100AC21: jne 0x3100ac28 */
  10849 L_3100AC23:
  10850     MEM32(edx + 0x4) = ecx; /* 0x3100AC23: mov dword ptr [edx + 4], ecx */
  10851     goto L_3100AC36; /* 0x3100AC26: jmp 0x3100ac36 */
  10852 L_3100AC28:
  10853     edx = MEM32(eax + 0x4); /* 0x3100AC28: mov edx, dword ptr [eax + 4] */
  10854     /* cmp eax, MEM32(edx) */ /* 0x3100AC2B: cmp eax, dword ptr [edx] */
  10855     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx));
  10856     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10857     _flag_k = FK_CMP;
  10858     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC33; /* 0x3100AC2D: jne 0x3100ac33 */
  10859 L_3100AC2F:
  10860     MEM32(edx) = ecx; /* 0x3100AC2F: mov dword ptr [edx], ecx */
  10861     goto L_3100AC36; /* 0x3100AC31: jmp 0x3100ac36 */
  10862 L_3100AC33:
  10863     MEM32(edx + 0x8) = ecx; /* 0x3100AC33: mov dword ptr [edx + 8], ecx */
  10864 L_3100AC36:
  10865     MEM32(ecx) = eax; /* 0x3100AC36: mov dword ptr [ecx], eax */
  10866     MEM32(eax + 0x4) = ecx; /* 0x3100AC38: mov dword ptr [eax + 4], ecx */
  10867 L_3100AC3B:
  10868     ecx = MEM32(eax + 0x4); /* 0x3100AC3B: mov ecx, dword ptr [eax + 4] */
  10869     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AC3E: mov byte ptr [ecx + 0x14], bl */
  10870     edx = MEM32(eax + 0x4); /* 0x3100AC41: mov edx, dword ptr [eax + 4] */
  10871     ecx = MEM32(edx + 0x4); /* 0x3100AC44: mov ecx, dword ptr [edx + 4] */
  10872     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100AC47: mov byte ptr [ecx + 0x14], 0 */
  10873     edx = MEM32(eax + 0x4); /* 0x3100AC4B: mov edx, dword ptr [eax + 4] */
  10874     ecx = MEM32(edx + 0x4); /* 0x3100AC4E: mov ecx, dword ptr [edx + 4] */
  10875     edx = MEM32(ecx); /* 0x3100AC51: mov edx, dword ptr [ecx] */
  10876     edi = MEM32(edx + 0x8); /* 0x3100AC53: mov edi, dword ptr [edx + 8] */
  10877     MEM32(ecx) = edi; /* 0x3100AC56: mov dword ptr [ecx], edi */
  10878     edi = MEM32(edx + 0x8); /* 0x3100AC58: mov edi, dword ptr [edx + 8] */
  10879     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AC5B: cmp edi, dword ptr [esi + 8] */
  10880     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10881     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10882     _flag_k = FK_CMP;
  10883     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AC63; /* 0x3100AC5E: je 0x3100ac63 */
  10884 L_3100AC60:
  10885     MEM32(edi + 0x4) = ecx; /* 0x3100AC60: mov dword ptr [edi + 4], ecx */
  10886 L_3100AC63:
  10887     edi = MEM32(ecx + 0x4); /* 0x3100AC63: mov edi, dword ptr [ecx + 4] */
  10888     MEM32(edx + 0x4) = edi; /* 0x3100AC66: mov dword ptr [edx + 4], edi */
  10889     edi = MEM32(esi + 0x4); /* 0x3100AC69: mov edi, dword ptr [esi + 4] */
  10890     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AC6C: cmp ecx, dword ptr [edi + 4] */
  10891     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
  10892     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10893     _flag_k = FK_CMP;
  10894     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC7C; /* 0x3100AC6F: jne 0x3100ac7c */
  10895 L_3100AC71:
  10896     MEM32(edi + 0x4) = edx; /* 0x3100AC71: mov dword ptr [edi + 4], edx */
  10897     MEM32(edx + 0x8) = ecx; /* 0x3100AC74: mov dword ptr [edx + 8], ecx */
  10898     goto L_3100AD2E; /* 0x3100AC77: jmp 0x3100ad2e */
  10899 L_3100AC7C:
  10900     edi = MEM32(ecx + 0x4); /* 0x3100AC7C: mov edi, dword ptr [ecx + 4] */
  10901     /* cmp ecx, MEM32(edi + 0x8) */ /* 0x3100AC7F: cmp ecx, dword ptr [edi + 8] */
  10902     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x8));
  10903     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10904     _flag_k = FK_CMP;
  10905     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AC8F; /* 0x3100AC82: jne 0x3100ac8f */
  10906 L_3100AC84:
  10907     MEM32(edi + 0x8) = edx; /* 0x3100AC84: mov dword ptr [edi + 8], edx */
  10908     MEM32(edx + 0x8) = ecx; /* 0x3100AC87: mov dword ptr [edx + 8], ecx */
  10909     goto L_3100AD2E; /* 0x3100AC8A: jmp 0x3100ad2e */
  10910 L_3100AC8F:
  10911     MEM32(edi) = edx; /* 0x3100AC8F: mov dword ptr [edi], edx */
  10912     MEM32(edx + 0x8) = ecx; /* 0x3100AC91: mov dword ptr [edx + 8], ecx */
  10913     goto L_3100AD2E; /* 0x3100AC94: jmp 0x3100ad2e */
  10914 L_3100AC99:
  10915     /* cmp MEM8(edx + 0x14), 0 */ /* 0x3100AC99: cmp byte ptr [edx + 0x14], 0 */
  10916     _flag_a = (uint32_t)(MEM8(edx + 0x14)) << 24; _flag_b = (uint32_t)(0) << 24;
  10917     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10918     _flag_k = FK_NARROW(FK_CMP, 24);
  10919     RECOMP_BACKEDGE();
  10920     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ABE1; /* 0x3100AC9D: je 0x3100abe1 */
  10921 L_3100ACA3:
  10922     /* cmp eax, MEM32(ecx) */ /* 0x3100ACA3: cmp eax, dword ptr [ecx] */
  10923     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
  10924     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10925     _flag_k = FK_CMP;
  10926     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACE3; /* 0x3100ACA5: jne 0x3100ace3 */
  10927 L_3100ACA7:
  10928     eax = ecx; /* 0x3100ACA7: mov eax, ecx */
  10929     ecx = MEM32(eax); /* 0x3100ACA9: mov ecx, dword ptr [eax] */
  10930     edx = MEM32(ecx + 0x8); /* 0x3100ACAB: mov edx, dword ptr [ecx + 8] */
  10931     MEM32(eax) = edx; /* 0x3100ACAE: mov dword ptr [eax], edx */
  10932     edx = MEM32(ecx + 0x8); /* 0x3100ACB0: mov edx, dword ptr [ecx + 8] */
  10933     /* cmp edx, MEM32(esi + 0x8) */ /* 0x3100ACB3: cmp edx, dword ptr [esi + 8] */
  10934     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10935     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10936     _flag_k = FK_CMP;
  10937     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100ACBB; /* 0x3100ACB6: je 0x3100acbb */
  10938 L_3100ACB8:
  10939     MEM32(edx + 0x4) = eax; /* 0x3100ACB8: mov dword ptr [edx + 4], eax */
  10940 L_3100ACBB:
  10941     edx = MEM32(eax + 0x4); /* 0x3100ACBB: mov edx, dword ptr [eax + 4] */
  10942     MEM32(ecx + 0x4) = edx; /* 0x3100ACBE: mov dword ptr [ecx + 4], edx */
  10943     edx = MEM32(esi + 0x4); /* 0x3100ACC1: mov edx, dword ptr [esi + 4] */
  10944     /* cmp eax, MEM32(edx + 0x4) */ /* 0x3100ACC4: cmp eax, dword ptr [edx + 4] */
  10945     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x4));
  10946     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10947     _flag_k = FK_CMP;
  10948     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACCE; /* 0x3100ACC7: jne 0x3100acce */
  10949 L_3100ACC9:
  10950     MEM32(edx + 0x4) = ecx; /* 0x3100ACC9: mov dword ptr [edx + 4], ecx */
  10951     goto L_3100ACDD; /* 0x3100ACCC: jmp 0x3100acdd */
  10952 L_3100ACCE:
  10953     edx = MEM32(eax + 0x4); /* 0x3100ACCE: mov edx, dword ptr [eax + 4] */
  10954     /* cmp eax, MEM32(edx + 0x8) */ /* 0x3100ACD1: cmp eax, dword ptr [edx + 8] */
  10955     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(edx + 0x8));
  10956     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10957     _flag_k = FK_CMP;
  10958     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ACDB; /* 0x3100ACD4: jne 0x3100acdb */
  10959 L_3100ACD6:
  10960     MEM32(edx + 0x8) = ecx; /* 0x3100ACD6: mov dword ptr [edx + 8], ecx */
  10961     goto L_3100ACDD; /* 0x3100ACD9: jmp 0x3100acdd */
  10962 L_3100ACDB:
  10963     MEM32(edx) = ecx; /* 0x3100ACDB: mov dword ptr [edx], ecx */
  10964 L_3100ACDD:
  10965     MEM32(ecx + 0x8) = eax; /* 0x3100ACDD: mov dword ptr [ecx + 8], eax */
  10966     MEM32(eax + 0x4) = ecx; /* 0x3100ACE0: mov dword ptr [eax + 4], ecx */
  10967 L_3100ACE3:
  10968     ecx = MEM32(eax + 0x4); /* 0x3100ACE3: mov ecx, dword ptr [eax + 4] */
  10969     MEM8(ecx + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100ACE6: mov byte ptr [ecx + 0x14], bl */
  10970     edx = MEM32(eax + 0x4); /* 0x3100ACE9: mov edx, dword ptr [eax + 4] */
  10971     ecx = MEM32(edx + 0x4); /* 0x3100ACEC: mov ecx, dword ptr [edx + 4] */
  10972     MEM8(ecx + 0x14) = (uint8_t)(0); /* 0x3100ACEF: mov byte ptr [ecx + 0x14], 0 */
  10973     edx = MEM32(eax + 0x4); /* 0x3100ACF3: mov edx, dword ptr [eax + 4] */
  10974     ecx = MEM32(edx + 0x4); /* 0x3100ACF6: mov ecx, dword ptr [edx + 4] */
  10975     edx = MEM32(ecx + 0x8); /* 0x3100ACF9: mov edx, dword ptr [ecx + 8] */
  10976     edi = MEM32(edx); /* 0x3100ACFC: mov edi, dword ptr [edx] */
  10977     MEM32(ecx + 0x8) = edi; /* 0x3100ACFE: mov dword ptr [ecx + 8], edi */
  10978     edi = MEM32(edx); /* 0x3100AD01: mov edi, dword ptr [edx] */
  10979     /* cmp edi, MEM32(esi + 0x8) */ /* 0x3100AD03: cmp edi, dword ptr [esi + 8] */
  10980     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  10981     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10982     _flag_k = FK_CMP;
  10983     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AD0B; /* 0x3100AD06: je 0x3100ad0b */
  10984 L_3100AD08:
  10985     MEM32(edi + 0x4) = ecx; /* 0x3100AD08: mov dword ptr [edi + 4], ecx */
  10986 L_3100AD0B:
  10987     edi = MEM32(ecx + 0x4); /* 0x3100AD0B: mov edi, dword ptr [ecx + 4] */
  10988     MEM32(edx + 0x4) = edi; /* 0x3100AD0E: mov dword ptr [edx + 4], edi */
  10989     edi = MEM32(esi + 0x4); /* 0x3100AD11: mov edi, dword ptr [esi + 4] */
  10990     /* cmp ecx, MEM32(edi + 0x4) */ /* 0x3100AD14: cmp ecx, dword ptr [edi + 4] */
  10991     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi + 0x4));
  10992     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  10993     _flag_k = FK_CMP;
  10994     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD1E; /* 0x3100AD17: jne 0x3100ad1e */
  10995 L_3100AD19:
  10996     MEM32(edi + 0x4) = edx; /* 0x3100AD19: mov dword ptr [edi + 4], edx */
  10997     goto L_3100AD2C; /* 0x3100AD1C: jmp 0x3100ad2c */
  10998 L_3100AD1E:
  10999     edi = MEM32(ecx + 0x4); /* 0x3100AD1E: mov edi, dword ptr [ecx + 4] */
  11000     /* cmp ecx, MEM32(edi) */ /* 0x3100AD21: cmp ecx, dword ptr [edi] */
  11001     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(edi));
  11002     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11003     _flag_k = FK_CMP;
  11004     if (CMP_NE(_flag_a, _flag_b)) goto L_3100AD29; /* 0x3100AD23: jne 0x3100ad29 */
  11005 L_3100AD25:
  11006     MEM32(edi) = edx; /* 0x3100AD25: mov dword ptr [edi], edx */
  11007     goto L_3100AD2C; /* 0x3100AD27: jmp 0x3100ad2c */
  11008 L_3100AD29:
  11009     MEM32(edi + 0x8) = edx; /* 0x3100AD29: mov dword ptr [edi + 8], edx */
  11010 L_3100AD2C:
  11011     MEM32(edx) = ecx; /* 0x3100AD2C: mov dword ptr [edx], ecx */
  11012 L_3100AD2E:
  11013     MEM32(ecx + 0x4) = edx; /* 0x3100AD2E: mov dword ptr [ecx + 4], edx */
  11014 L_3100AD31:
  11015     ecx = MEM32(esi + 0x4); /* 0x3100AD31: mov ecx, dword ptr [esi + 4] */
  11016     /* cmp eax, MEM32(ecx + 0x4) */ /* 0x3100AD34: cmp eax, dword ptr [ecx + 4] */
  11017     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx + 0x4));
  11018     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11019     _flag_k = FK_CMP;
  11020     RECOMP_BACKEDGE();
  11021     if (CMP_NE(_flag_a, _flag_b)) goto L_3100ABBD; /* 0x3100AD37: jne 0x3100abbd */
  11022 L_3100AD3D:
  11023     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
  11024     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
  11025     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
  11026     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
  11027     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
  11028     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
  11029     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
  11030     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
  11031     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
  11032     esp = ebp; /* 0x3100AD51: mov esp, ebp */
  11033     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
  11034     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
  11035     RECOMP_REGS_OUT();
  11036 }
  11037 
  11038 void sub_3100AD3D(void) {
  11039     int _fpu_cmp = 0;
  11040     uint32_t _cf = 0;
  11041     int _df = 1;
  11042     uint32_t _flag_k = FK_NONE;
  11043     uint32_t _flag_a = 0, _flag_b = 0;
  11044     uint32_t _itail_tgt = 0;
  11045     RECOMP_REGS_LOCALS
  11046     RECOMP_ENTER(0x3100AD3Du);
  11047 
  11048 L_3100AD3D:
  11049     edx = MEM32(esi + 0x4); /* 0x3100AD3D: mov edx, dword ptr [esi + 4] */
  11050     eax = MEM32(edx + 0x4); /* 0x3100AD40: mov eax, dword ptr [edx + 4] */
  11051     ecx = MEM32(ebp + (-0x4)); /* 0x3100AD43: mov ecx, dword ptr [ebp - 4] */
  11052     MEM8(eax + 0x14) = (uint8_t)(LO8(ebx)); /* 0x3100AD46: mov byte ptr [eax + 0x14], bl */
  11053     eax = MEM32(ebp + 0x8); /* 0x3100AD49: mov eax, dword ptr [ebp + 8] */
  11054     edi = POP32_VAL(esp); /* 0x3100AD4C: pop edi */
  11055     esi = POP32_VAL(esp); /* 0x3100AD4D: pop esi */
  11056     MEM32(eax) = ecx; /* 0x3100AD4E: mov dword ptr [eax], ecx */
  11057     ebx = POP32_VAL(esp); /* 0x3100AD50: pop ebx */
  11058     esp = ebp; /* 0x3100AD51: mov esp, ebp */
  11059     ebp = POP32_VAL(esp); /* 0x3100AD53: pop ebp */
  11060     RECOMP_FLAGS_OUT(); esp += 20; { RECOMP_REGS_OUT(); return; } /* 0x3100AD54: ret 0x10 */
  11061     RECOMP_REGS_OUT();
  11062 }
  11063 
  11064 void sub_3100AD60(void) {
  11065     int _fpu_cmp = 0;
  11066     uint32_t _cf = 0;
  11067     int _df = 1;
  11068     uint32_t _flag_k = FK_NONE;
  11069     uint32_t _flag_a = 0, _flag_b = 0;
  11070     uint32_t _itail_tgt = 0;
  11071     RECOMP_REGS_LOCALS
  11072     RECOMP_ENTER(0x3100AD60u);
  11073 
  11074 L_3100AD60:
  11075     PUSH32(esp, ebp); /* 0x3100AD60: push ebp */
  11076     ebp = esp; /* 0x3100AD61: mov ebp, esp */
  11077     eax = MEM32(FS_BASE + (0)); /* 0x3100AD63: mov eax, dword ptr fs:[0] */
  11078     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100AD69: push -1 */
  11079     PUSH32(esp, 0x3104743Bu); /* 0x3100AD6B: push 0x3104743b */
  11080     PUSH32(esp, eax); /* 0x3100AD70: push eax */
  11081     MEM32(FS_BASE + (0)) = esp; /* 0x3100AD71: mov dword ptr fs:[0], esp */
  11082     PUSH32(esp, esi); /* 0x3100AD78: push esi */
  11083     esi = MEM32(ebp + 0x8); /* 0x3100AD79: mov esi, dword ptr [ebp + 8] */
  11084     /* cmp MEM32(esi + 0x8), 3 */ /* 0x3100AD7C: cmp dword ptr [esi + 8], 3 */
  11085     _flag_a = (uint32_t)(MEM32(esi + 0x8)); _flag_b = (uint32_t)(3);
  11086     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11087     _flag_k = FK_CMP;
  11088     PUSH32(esp, edi); /* 0x3100AD80: push edi */
  11089     if (CMP_B(_flag_a, _flag_b)) goto L_3100AE4F; /* 0x3100AD81: jb 0x3100ae4f */
  11090 L_3100AD87:
  11091     eax = MEM32(esi + 0x4); /* 0x3100AD87: mov eax, dword ptr [esi + 4] */
  11092     /* test eax, eax */ /* 0x3100AD8A: test eax, eax */
  11093     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11094     _cf = 0;
  11095     _flag_k = FK_TEST;
  11096     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100AD93; /* 0x3100AD8C: jne 0x3100ad93 */
  11097 L_3100AD8E:
  11098     eax = MEM32(0x310480EC); /* 0x3100AD8E: mov eax, dword ptr [0x310480ec] */
  11099 L_3100AD93:
  11100     eax = (int32_t)(int8_t)MEM8(eax); /* 0x3100AD93: movsx eax, byte ptr [eax] */
  11101     PUSH32(esp, eax); /* 0x3100AD96: push eax */
  11102     RECOMP_ICALL(MEM32(0x31048234)); /* 0x3100AD97: call dword ptr [0x31048234] */
  11103     RECOMP_FLAGS_IN();
  11104     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  11105     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11106     esp = esp + 4; /* 0x3100AD9D: add esp, 4 */
  11107     _flag_k = FK_ADD;
  11108     /* test eax, eax */ /* 0x3100ADA0: test eax, eax */
  11109     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11110     _cf = 0;
  11111     _flag_k = FK_TEST;
  11112     if (TEST_Z(_flag_a, _flag_b)) goto L_3100AE4F; /* 0x3100ADA2: je 0x3100ae4f */
  11113 L_3100ADA8:
  11114     eax = MEM32(esi + 0x4); /* 0x3100ADA8: mov eax, dword ptr [esi + 4] */
  11115     /* test eax, eax */ /* 0x3100ADAB: test eax, eax */
  11116     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11117     _cf = 0;
  11118     _flag_k = FK_TEST;
  11119     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100ADB6; /* 0x3100ADAD: jne 0x3100adb6 */
  11120 L_3100ADAF:
  11121     eax = MEM32(0x310480EC); /* 0x3100ADAF: mov eax, dword ptr [0x310480ec] */
  11122     goto L_3100ADB7; /* 0x3100ADB4: jmp 0x3100adb7 */
  11123 L_3100ADB6:
  11124     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  11125     eax = eax + 1; /* 0x3100ADB6: inc eax */
  11126     _flag_k = FK_INC;
  11127 L_3100ADB7:
  11128     ecx = (int32_t)(int8_t)MEM8(eax); /* 0x3100ADB7: movsx ecx, byte ptr [eax] */
  11129     edi = MEM32(0x31048224); /* 0x3100ADBA: mov edi, dword ptr [0x31048224] */
  11130     PUSH32(esp, ecx); /* 0x3100ADC0: push ecx */
  11131     RECOMP_ICALL(edi); /* 0x3100ADC1: call edi */
  11132     RECOMP_FLAGS_IN();
  11133     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  11134     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11135     esp = esp + 4; /* 0x3100ADC3: add esp, 4 */
  11136     _flag_k = FK_ADD;
  11137     /* test eax, eax */ /* 0x3100ADC6: test eax, eax */
  11138     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11139     _cf = 0;
  11140     _flag_k = FK_TEST;
  11141     if (TEST_Z(_flag_a, _flag_b)) goto L_3100AE4F; /* 0x3100ADC8: je 0x3100ae4f */
  11142 L_3100ADCE:
  11143     eax = MEM32(esi + 0x4); /* 0x3100ADCE: mov eax, dword ptr [esi + 4] */
  11144     /* test eax, eax */ /* 0x3100ADD1: test eax, eax */
  11145     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11146     _cf = 0;
  11147     _flag_k = FK_TEST;
  11148     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100ADDC; /* 0x3100ADD3: jne 0x3100addc */
  11149 L_3100ADD5:
  11150     eax = MEM32(0x310480EC); /* 0x3100ADD5: mov eax, dword ptr [0x310480ec] */
  11151     goto L_3100ADDF; /* 0x3100ADDA: jmp 0x3100addf */
  11152 L_3100ADDC:
  11153     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(2);
  11154     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11155     eax = eax + 2; /* 0x3100ADDC: add eax, 2 */
  11156     _flag_k = FK_ADD;
  11157 L_3100ADDF:
  11158     edx = (int32_t)(int8_t)MEM8(eax); /* 0x3100ADDF: movsx edx, byte ptr [eax] */
  11159     PUSH32(esp, edx); /* 0x3100ADE2: push edx */
  11160     RECOMP_ICALL(edi); /* 0x3100ADE3: call edi */
  11161     RECOMP_FLAGS_IN();
  11162     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  11163     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11164     esp = esp + 4; /* 0x3100ADE5: add esp, 4 */
  11165     _flag_k = FK_ADD;
  11166     /* test eax, eax */ /* 0x3100ADE8: test eax, eax */
  11167     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11168     _cf = 0;
  11169     _flag_k = FK_TEST;
  11170     if (TEST_Z(_flag_a, _flag_b)) goto L_3100AE4F; /* 0x3100ADEA: je 0x3100ae4f */
  11171 L_3100ADEC:
  11172     PUSH32(esp, 0x248u); /* 0x3100ADEC: push 0x248 */
  11173     RECOMP_ICALL(0x310468DAu); /* 0x3100ADF1: call 0x310468da */ /* not lifted */
  11174     RECOMP_FLAGS_IN();
  11175     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  11176     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11177     esp = esp + 4; /* 0x3100ADF6: add esp, 4 */
  11178     _flag_k = FK_ADD;
  11179     MEM32(ebp + 0x8) = eax; /* 0x3100ADF9: mov dword ptr [ebp + 8], eax */
  11180     /* test eax, eax */ /* 0x3100ADFC: test eax, eax */
  11181     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11182     _cf = 0;
  11183     _flag_k = FK_TEST;
  11184     MEM32(ebp + (-0x4)) = 0; /* 0x3100ADFE: mov dword ptr [ebp - 4], 0 */
  11185     if (TEST_Z(_flag_a, _flag_b)) goto L_3100AE13; /* 0x3100AE05: je 0x3100ae13 */
  11186 L_3100AE07:
  11187     PUSH32(esp, esi); /* 0x3100AE07: push esi */
  11188     ecx = eax; /* 0x3100AE08: mov ecx, eax */
  11189     RECOMP_ICALL(0x3100AE70u); /* 0x3100AE0A: call 0x3100ae70 */ /* not lifted */
  11190     RECOMP_FLAGS_IN();
  11191     esi = eax; /* 0x3100AE0F: mov esi, eax */
  11192     goto L_3100AE15; /* 0x3100AE11: jmp 0x3100ae15 */
  11193 L_3100AE13:
  11194     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11195     esi = 0; /* 0x3100AE13: xor esi, esi */
  11196     _cf = 0;
  11197     _flag_k = FK_TEST;
  11198 L_3100AE15:
  11199     ecx = esi; /* 0x3100AE15: mov ecx, esi */
  11200     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100AE17: mov dword ptr [ebp - 4], 0xffffffff */
  11201     RECOMP_ICALL(0x31008F90u); /* 0x3100AE1E: call 0x31008f90 */ /* not lifted */
  11202     RECOMP_FLAGS_IN();
  11203     PUSH32(esp, 0x1Eu); /* 0x3100AE23: push 0x1e */
  11204     ecx = esi; /* 0x3100AE25: mov ecx, esi */
  11205     RECOMP_ICALL(0x3100AFE0u); /* 0x3100AE27: call 0x3100afe0 */ /* not lifted */
  11206     RECOMP_FLAGS_IN();
  11207     /* test LO8(eax), LO8(eax) */ /* 0x3100AE2C: test al, al */
  11208     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  11209     _cf = 0;
  11210     _flag_k = FK_NARROW(FK_TEST, 24);
  11211     if (TEST_Z(_flag_a, _flag_b)) goto L_3100AE42; /* 0x3100AE2E: je 0x3100ae42 */
  11212 L_3100AE30:
  11213     eax = esi; /* 0x3100AE30: mov eax, esi */
  11214     ecx = MEM32(ebp + (-0xC)); /* 0x3100AE32: mov ecx, dword ptr [ebp - 0xc] */
  11215     MEM32(FS_BASE + (0)) = ecx; /* 0x3100AE35: mov dword ptr fs:[0], ecx */
  11216     edi = POP32_VAL(esp); /* 0x3100AE3C: pop edi */
  11217     esi = POP32_VAL(esp); /* 0x3100AE3D: pop esi */
  11218     esp = ebp; /* 0x3100AE3E: mov esp, ebp */
  11219     ebp = POP32_VAL(esp); /* 0x3100AE40: pop ebp */
  11220     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100AE41: ret  */
  11221 L_3100AE42:
  11222     /* test esi, esi */ /* 0x3100AE42: test esi, esi */
  11223     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi);
  11224     _cf = 0;
  11225     _flag_k = FK_TEST;
  11226     if (TEST_Z(_flag_a, _flag_b)) goto L_3100AE4F; /* 0x3100AE44: je 0x3100ae4f */
  11227 L_3100AE46:
  11228     eax = MEM32(esi); /* 0x3100AE46: mov eax, dword ptr [esi] */
  11229     PUSH32(esp, 1); /* 0x3100AE48: push 1 */
  11230     ecx = esi; /* 0x3100AE4A: mov ecx, esi */
  11231     RECOMP_ICALL(MEM32(eax + 0x6C)); /* 0x3100AE4C: call dword ptr [eax + 0x6c] */
  11232     RECOMP_FLAGS_IN();
  11233 L_3100AE4F:
  11234     ecx = MEM32(ebp + (-0xC)); /* 0x3100AE4F: mov ecx, dword ptr [ebp - 0xc] */
  11235     edi = POP32_VAL(esp); /* 0x3100AE52: pop edi */
  11236     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11237     eax = 0; /* 0x3100AE53: xor eax, eax */
  11238     _cf = 0;
  11239     _flag_k = FK_TEST;
  11240     MEM32(FS_BASE + (0)) = ecx; /* 0x3100AE55: mov dword ptr fs:[0], ecx */
  11241     esi = POP32_VAL(esp); /* 0x3100AE5C: pop esi */
  11242     esp = ebp; /* 0x3100AE5D: mov esp, ebp */
  11243     ebp = POP32_VAL(esp); /* 0x3100AE5F: pop ebp */
  11244     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100AE60: ret  */
  11245     RECOMP_REGS_OUT();
  11246 }
  11247 
  11248 void sub_3100AE70(void) {
  11249     int _fpu_cmp = 0;
  11250     uint32_t _cf = 0;
  11251     int _df = 1;
  11252     uint32_t _flag_k = FK_NONE;
  11253     uint32_t _flag_a = 0, _flag_b = 0;
  11254     uint32_t _itail_tgt = 0;
  11255     RECOMP_REGS_LOCALS
  11256     RECOMP_ENTER(0x3100AE70u);
  11257 
  11258 L_3100AE70:
  11259     PUSH32(esp, ebp); /* 0x3100AE70: push ebp */
  11260     ebp = esp; /* 0x3100AE71: mov ebp, esp */
  11261     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100AE73: push -1 */
  11262     PUSH32(esp, 0x31047458u); /* 0x3100AE75: push 0x31047458 */
  11263     eax = MEM32(FS_BASE + (0)); /* 0x3100AE7A: mov eax, dword ptr fs:[0] */
  11264     PUSH32(esp, eax); /* 0x3100AE80: push eax */
  11265     MEM32(FS_BASE + (0)) = esp; /* 0x3100AE81: mov dword ptr fs:[0], esp */
  11266     PUSH32(esp, ecx); /* 0x3100AE88: push ecx */
  11267     eax = MEM32(ebp + 0x8); /* 0x3100AE89: mov eax, dword ptr [ebp + 8] */
  11268     PUSH32(esp, ebx); /* 0x3100AE8C: push ebx */
  11269     PUSH32(esp, esi); /* 0x3100AE8D: push esi */
  11270     PUSH32(esp, edi); /* 0x3100AE8E: push edi */
  11271     esi = ecx; /* 0x3100AE8F: mov esi, ecx */
  11272     PUSH32(esp, eax); /* 0x3100AE91: push eax */
  11273     MEM32(ebp + (-0x10)) = esi; /* 0x3100AE92: mov dword ptr [ebp - 0x10], esi */
  11274     RECOMP_ICALL(0x3100A060u); /* 0x3100AE95: call 0x3100a060 */ /* not lifted */
  11275     RECOMP_FLAGS_IN();
  11276     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11277     ebx = 0; /* 0x3100AE9A: xor ebx, ebx */
  11278     _cf = 0;
  11279     _flag_k = FK_TEST;
  11280     edi = esi + 0x30; /* 0x3100AE9C: lea edi, [esi + 0x30] */
  11281     ecx = edi; /* 0x3100AE9F: mov ecx, edi */
  11282     MEM32(ebp + (-0x4)) = ebx; /* 0x3100AEA1: mov dword ptr [ebp - 4], ebx */
  11283     RECOMP_ICALL(0x31010BC0u); /* 0x3100AEA4: call 0x31010bc0 */ /* not lifted */
  11284     RECOMP_FLAGS_IN();
  11285     ecx = MEM32(ebp + (-0xC)); /* 0x3100AEA9: mov ecx, dword ptr [ebp - 0xc] */
  11286     MEM32(edi) = 0x3104875Cu; /* 0x3100AEAC: mov dword ptr [edi], 0x3104875c */
  11287     MEM32(esi + 0x23C) = ebx; /* 0x3100AEB2: mov dword ptr [esi + 0x23c], ebx */
  11288     MEM32(esi + 0x240) = ebx; /* 0x3100AEB8: mov dword ptr [esi + 0x240], ebx */
  11289     MEM8(esi + 0x244) = (uint8_t)(LO8(ebx)); /* 0x3100AEBE: mov byte ptr [esi + 0x244], bl */
  11290     MEM8(esi + 0x245) = (uint8_t)(LO8(ebx)); /* 0x3100AEC4: mov byte ptr [esi + 0x245], bl */
  11291     edi = POP32_VAL(esp); /* 0x3100AECA: pop edi */
  11292     MEM32(esi) = 0x310486E8u; /* 0x3100AECB: mov dword ptr [esi], 0x310486e8 */
  11293     eax = esi; /* 0x3100AED1: mov eax, esi */
  11294     esi = POP32_VAL(esp); /* 0x3100AED3: pop esi */
  11295     ebx = POP32_VAL(esp); /* 0x3100AED4: pop ebx */
  11296     MEM32(FS_BASE + (0)) = ecx; /* 0x3100AED5: mov dword ptr fs:[0], ecx */
  11297     esp = ebp; /* 0x3100AEDC: mov esp, ebp */
  11298     ebp = POP32_VAL(esp); /* 0x3100AEDE: pop ebp */
  11299     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100AEDF: ret 4 */
  11300     RECOMP_REGS_OUT();
  11301 }
  11302 
  11303 void sub_3100AEF0(void) {
  11304     int _fpu_cmp = 0;
  11305     uint32_t _cf = 0;
  11306     int _df = 1;
  11307     uint32_t _flag_k = FK_NONE;
  11308     uint32_t _flag_a = 0, _flag_b = 0;
  11309     uint32_t _itail_tgt = 0;
  11310     RECOMP_REGS_LOCALS
  11311     RECOMP_ENTER(0x3100AEF0u);
  11312 
  11313 L_3100AEF0:
  11314     eax = MEM32(ecx + 0x23C); /* 0x3100AEF0: mov eax, dword ptr [ecx + 0x23c] */
  11315     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100AEF6: ret  */
  11316     RECOMP_REGS_OUT();
  11317 }
  11318 
  11319 void sub_3100AF00(void) {
  11320     int _fpu_cmp = 0;
  11321     uint32_t _cf = 0;
  11322     int _df = 1;
  11323     uint32_t _flag_k = FK_NONE;
  11324     uint32_t _flag_a = 0, _flag_b = 0;
  11325     uint32_t _itail_tgt = 0;
  11326     RECOMP_REGS_LOCALS
  11327     RECOMP_ENTER(0x3100AF00u);
  11328 
  11329 L_3100AF00:
  11330     PUSH32(esp, ebp); /* 0x3100AF00: push ebp */
  11331     ebp = esp; /* 0x3100AF01: mov ebp, esp */
  11332     PUSH32(esp, esi); /* 0x3100AF03: push esi */
  11333     esi = ecx; /* 0x3100AF04: mov esi, ecx */
  11334     RECOMP_ICALL(0x3100AF30u); /* 0x3100AF06: call 0x3100af30 */ /* not lifted */
  11335     RECOMP_FLAGS_IN();
  11336     /* test MEM8(ebp + 0x8), 1 */ /* 0x3100AF0B: test byte ptr [ebp + 8], 1 */
  11337     _flag_a = (uint32_t)(MEM8(ebp + 0x8)) << 24; _flag_b = (uint32_t)(1) << 24;
  11338     _cf = 0;
  11339     _flag_k = FK_NARROW(FK_TEST, 24);
  11340     if (TEST_Z(_flag_a, _flag_b)) goto L_3100AF1A; /* 0x3100AF0F: je 0x3100af1a */
  11341 L_3100AF11:
  11342     PUSH32(esp, esi); /* 0x3100AF11: push esi */
  11343     RECOMP_ICALL(0x31046858u); /* 0x3100AF12: call 0x31046858 */ /* not lifted */
  11344     RECOMP_FLAGS_IN();
  11345     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  11346     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11347     esp = esp + 4; /* 0x3100AF17: add esp, 4 */
  11348     _flag_k = FK_ADD;
  11349 L_3100AF1A:
  11350     eax = esi; /* 0x3100AF1A: mov eax, esi */
  11351     esi = POP32_VAL(esp); /* 0x3100AF1C: pop esi */
  11352     ebp = POP32_VAL(esp); /* 0x3100AF1D: pop ebp */
  11353     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100AF1E: ret 4 */
  11354     RECOMP_REGS_OUT();
  11355 }
  11356 
  11357 void sub_3100AF30(void) {
  11358     int _fpu_cmp = 0;
  11359     uint32_t _cf = 0;
  11360     int _df = 1;
  11361     uint32_t _flag_k = FK_NONE;
  11362     uint32_t _flag_a = 0, _flag_b = 0;
  11363     uint32_t _itail_tgt = 0;
  11364     RECOMP_REGS_LOCALS
  11365     RECOMP_ENTER(0x3100AF30u);
  11366 
  11367 L_3100AF30:
  11368     PUSH32(esp, ebp); /* 0x3100AF30: push ebp */
  11369     ebp = esp; /* 0x3100AF31: mov ebp, esp */
  11370     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100AF33: push -1 */
  11371     PUSH32(esp, 0x3104749Fu); /* 0x3100AF35: push 0x3104749f */
  11372     eax = MEM32(FS_BASE + (0)); /* 0x3100AF3A: mov eax, dword ptr fs:[0] */
  11373     PUSH32(esp, eax); /* 0x3100AF40: push eax */
  11374     MEM32(FS_BASE + (0)) = esp; /* 0x3100AF41: mov dword ptr fs:[0], esp */
  11375     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x18u);
  11376     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11377     esp = esp - 0x18u; /* 0x3100AF48: sub esp, 0x18 */
  11378     _flag_k = FK_CMP;
  11379     PUSH32(esp, ebx); /* 0x3100AF4B: push ebx */
  11380     PUSH32(esp, esi); /* 0x3100AF4C: push esi */
  11381     esi = ecx; /* 0x3100AF4D: mov esi, ecx */
  11382     PUSH32(esp, edi); /* 0x3100AF4F: push edi */
  11383     edi = esi + 0x30; /* 0x3100AF50: lea edi, [esi + 0x30] */
  11384     MEM32(ebp + (-0x10)) = esi; /* 0x3100AF53: mov dword ptr [ebp - 0x10], esi */
  11385     MEM32(esi) = 0x310486E8u; /* 0x3100AF56: mov dword ptr [esi], 0x310486e8 */
  11386     MEM32(edi) = 0x3104875Cu; /* 0x3100AF5C: mov dword ptr [edi], 0x3104875c */
  11387     eax = 1; /* 0x3100AF62: mov eax, 1 */
  11388     MEM32(ebp + (-0x4)) = eax; /* 0x3100AF67: mov dword ptr [ebp - 4], eax */
  11389     MEM8(esi + 0x244) = (uint8_t)(LO8(eax)); /* 0x3100AF6A: mov byte ptr [esi + 0x244], al */
  11390     SET_LO8(eax, MEM8(esi + 0x245)); /* 0x3100AF70: mov al, byte ptr [esi + 0x245] */
  11391     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11392     ebx = 0; /* 0x3100AF76: xor ebx, ebx */
  11393     _cf = 0;
  11394     _flag_k = FK_TEST;
  11395     /* cmp LO8(eax), LO8(ebx) */ /* 0x3100AF78: cmp al, bl */
  11396     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11397     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11398     _flag_k = FK_NARROW(FK_CMP, 24);
  11399     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AFB1; /* 0x3100AF7A: je 0x3100afb1 */
  11400 L_3100AF7C:
  11401     eax = ebp + (-0x20); /* 0x3100AF7C: lea eax, [ebp - 0x20] */
  11402     PUSH32(esp, eax); /* 0x3100AF7F: push eax */
  11403     RECOMP_ICALL(0x3100C820u); /* 0x3100AF80: call 0x3100c820 */ /* not lifted */
  11404     RECOMP_FLAGS_IN();
  11405     eax = MEM32(ebp + (-0x1C)); /* 0x3100AF85: mov eax, dword ptr [ebp - 0x1c] */
  11406     /* cmp eax, ebx */ /* 0x3100AF88: cmp eax, ebx */
  11407     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  11408     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11409     _flag_k = FK_CMP;
  11410     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AFA8; /* 0x3100AF8A: je 0x3100afa8 */
  11411 L_3100AF8C:
  11412     ecx = eax + (-0x1); /* 0x3100AF8C: lea ecx, [eax - 1] */
  11413     SET_LO8(eax, MEM8(ecx)); /* 0x3100AF8F: mov al, byte ptr [ecx] */
  11414     /* cmp LO8(eax), LO8(ebx) */ /* 0x3100AF91: cmp al, bl */
  11415     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  11416     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11417     _flag_k = FK_NARROW(FK_CMP, 24);
  11418     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AF9F; /* 0x3100AF93: je 0x3100af9f */
  11419 L_3100AF95:
  11420     /* cmp LO8(eax), 0xFFu */ /* 0x3100AF95: cmp al, 0xff */
  11421     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
  11422     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11423     _flag_k = FK_NARROW(FK_CMP, 24);
  11424     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100AF9F; /* 0x3100AF97: je 0x3100af9f */
  11425 L_3100AF99:
  11426     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
  11427     SET_LO8(eax, LO8(eax) - 1); /* 0x3100AF99: dec al */
  11428     _flag_k = FK_NARROW(FK_DEC, 24);
  11429     MEM8(ecx) = (uint8_t)(LO8(eax)); /* 0x3100AF9B: mov byte ptr [ecx], al */
  11430     goto L_3100AFA8; /* 0x3100AF9D: jmp 0x3100afa8 */
  11431 L_3100AF9F:
  11432     PUSH32(esp, ecx); /* 0x3100AF9F: push ecx */
  11433     RECOMP_ICALL(0x31046858u); /* 0x3100AFA0: call 0x31046858 */ /* not lifted */
  11434     RECOMP_FLAGS_IN();
  11435     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  11436     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11437     esp = esp + 4; /* 0x3100AFA5: add esp, 4 */
  11438     _flag_k = FK_ADD;
  11439 L_3100AFA8:
  11440     MEM32(ebp + (-0x1C)) = ebx; /* 0x3100AFA8: mov dword ptr [ebp - 0x1c], ebx */
  11441     MEM32(ebp + (-0x18)) = ebx; /* 0x3100AFAB: mov dword ptr [ebp - 0x18], ebx */
  11442     MEM32(ebp + (-0x14)) = ebx; /* 0x3100AFAE: mov dword ptr [ebp - 0x14], ebx */
  11443 L_3100AFB1:
  11444     ecx = esi; /* 0x3100AFB1: mov ecx, esi */
  11445     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(ecx);
  11446     _cf = (ecx) != 0;
  11447     ecx = (uint32_t)(-(int32_t)ecx); /* 0x3100AFB3: neg ecx */
  11448     _flag_k = FK_CMP;
  11449     { uint32_t _sa = ecx, _sb = ecx, _sc = _cf; /* 0x3100AFB5: sbb ecx, ecx */
  11450       ecx = _sc ? 0xFFFFFFFFu : 0;
  11451       _flag_a = recomp_flags_sbb(_sa, _sb, _sc); _flag_b = 0;
  11452       _flag_k = FK_EFLAGS; _cf = _flag_a & 1u; }
  11453     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
  11454     ecx = ecx & edi; /* 0x3100AFB7: and ecx, edi */
  11455     _cf = 0;
  11456     _flag_k = FK_TEST;
  11457     MEM8(ebp + (-0x4)) = (uint8_t)(LO8(ebx)); /* 0x3100AFB9: mov byte ptr [ebp - 4], bl */
  11458     RECOMP_ICALL(0x31010C60u); /* 0x3100AFBC: call 0x31010c60 */ /* not lifted */
  11459     RECOMP_FLAGS_IN();
  11460     ecx = esi; /* 0x3100AFC1: mov ecx, esi */
  11461     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100AFC3: mov dword ptr [ebp - 4], 0xffffffff */
  11462     RECOMP_ICALL(0x3100A2B0u); /* 0x3100AFCA: call 0x3100a2b0 */ /* not lifted */
  11463     RECOMP_FLAGS_IN();
  11464     ecx = MEM32(ebp + (-0xC)); /* 0x3100AFCF: mov ecx, dword ptr [ebp - 0xc] */
  11465     edi = POP32_VAL(esp); /* 0x3100AFD2: pop edi */
  11466     esi = POP32_VAL(esp); /* 0x3100AFD3: pop esi */
  11467     ebx = POP32_VAL(esp); /* 0x3100AFD4: pop ebx */
  11468     MEM32(FS_BASE + (0)) = ecx; /* 0x3100AFD5: mov dword ptr fs:[0], ecx */
  11469     esp = ebp; /* 0x3100AFDC: mov esp, ebp */
  11470     ebp = POP32_VAL(esp); /* 0x3100AFDE: pop ebp */
  11471     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100AFDF: ret  */
  11472     RECOMP_REGS_OUT();
  11473 }
  11474 
  11475 void sub_3100AFE0(void) {
  11476     int _fpu_cmp = 0;
  11477     uint32_t _cf = 0;
  11478     int _df = 1;
  11479     uint32_t _flag_k = FK_NONE;
  11480     uint32_t _flag_a = 0, _flag_b = 0;
  11481     uint32_t _itail_tgt = 0;
  11482     RECOMP_REGS_LOCALS
  11483     RECOMP_ENTER(0x3100AFE0u);
  11484 
  11485 L_3100AFE0:
  11486     PUSH32(esp, ebp); /* 0x3100AFE0: push ebp */
  11487     ebp = esp; /* 0x3100AFE1: mov ebp, esp */
  11488     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100AFE3: push -1 */
  11489     PUSH32(esp, 0x3104751Cu); /* 0x3100AFE5: push 0x3104751c */
  11490     eax = MEM32(FS_BASE + (0)); /* 0x3100AFEA: mov eax, dword ptr fs:[0] */
  11491     PUSH32(esp, eax); /* 0x3100AFF0: push eax */
  11492     MEM32(FS_BASE + (0)) = esp; /* 0x3100AFF1: mov dword ptr fs:[0], esp */
  11493     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x2D8u);
  11494     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11495     esp = esp - 0x2D8u; /* 0x3100AFF8: sub esp, 0x2d8 */
  11496     _flag_k = FK_CMP;
  11497     PUSH32(esp, ebx); /* 0x3100AFFE: push ebx */
  11498     ebx = ecx; /* 0x3100AFFF: mov ebx, ecx */
  11499     PUSH32(esp, esi); /* 0x3100B001: push esi */
  11500     PUSH32(esp, edi); /* 0x3100B002: push edi */
  11501     _flag_a = (uint32_t)((ecx | 0xFFFFFFFFu)); _flag_b = (uint32_t)((ecx | 0xFFFFFFFFu));
  11502     ecx = ecx | 0xFFFFFFFFu; /* 0x3100B003: or ecx, 0xffffffff */
  11503     _cf = 0;
  11504     _flag_k = FK_TEST;
  11505     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11506     eax = 0; /* 0x3100B006: xor eax, eax */
  11507     _cf = 0;
  11508     _flag_k = FK_TEST;
  11509     MEM8(ebx + 0x245) = (uint8_t)(0); /* 0x3100B008: mov byte ptr [ebx + 0x245], 0 */
  11510     edi = 0x310522B4u; /* 0x3100B00F: mov edi, 0x310522b4 */
  11511     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; } /* 0x3100B014: repne scasb al, byte ptr es:[edi] */
  11512     ecx = ~ecx; /* 0x3100B016: not ecx */
  11513     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
  11514     ecx = ecx - 1; /* 0x3100B018: dec ecx */
  11515     _flag_k = FK_DEC;
  11516     PUSH32(esp, ecx); /* 0x3100B019: push ecx */
  11517     PUSH32(esp, eax); /* 0x3100B01A: push eax */
  11518     esi = ebx + 0x4; /* 0x3100B01B: lea esi, [ebx + 4] */
  11519     PUSH32(esp, 0x310522B4u); /* 0x3100B01E: push 0x310522b4 */
  11520     ecx = esi; /* 0x3100B023: mov ecx, esi */
  11521     MEM32(ebp + (-0x34)) = ebx; /* 0x3100B025: mov dword ptr [ebp - 0x34], ebx */
  11522     RECOMP_ICALL(MEM32(0x31048078)); /* 0x3100B028: call dword ptr [0x31048078] */
  11523     RECOMP_FLAGS_IN();
  11524     /* cmp eax, 0xFFFFFFFFu */ /* 0x3100B02E: cmp eax, -1 */
  11525     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xFFFFFFFFu);
  11526     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11527     _flag_k = FK_CMP;
  11528     if (CMP_NE(_flag_a, _flag_b)) goto L_3100B036; /* 0x3100B031: jne 0x3100b036 */
  11529 L_3100B033:
  11530     eax = MEM32(ebx + 0xC); /* 0x3100B033: mov eax, dword ptr [ebx + 0xc] */
  11531 L_3100B036:
  11532     PUSH32(esp, eax); /* 0x3100B036: push eax */
  11533     PUSH32(esp, 0); /* 0x3100B037: push 0 */
  11534     eax = ebp + (-0x54); /* 0x3100B039: lea eax, [ebp - 0x54] */
  11535     PUSH32(esp, eax); /* 0x3100B03C: push eax */
  11536     ecx = esi; /* 0x3100B03D: mov ecx, esi */
  11537     RECOMP_ICALL(MEM32(0x31048074)); /* 0x3100B03F: call dword ptr [0x31048074] */
  11538     RECOMP_FLAGS_IN();
  11539     eax = MEM32(ebp + (-0x50)); /* 0x3100B045: mov eax, dword ptr [ebp - 0x50] */
  11540     /* test eax, eax */ /* 0x3100B048: test eax, eax */
  11541     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11542     _cf = 0;
  11543     _flag_k = FK_TEST;
  11544     MEM32(ebp + (-0x4)) = 0; /* 0x3100B04A: mov dword ptr [ebp - 4], 0 */
  11545     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100B058; /* 0x3100B051: jne 0x3100b058 */
  11546 L_3100B053:
  11547     eax = MEM32(0x310480EC); /* 0x3100B053: mov eax, dword ptr [0x310480ec] */
  11548 L_3100B058:
  11549     PUSH32(esp, eax); /* 0x3100B058: push eax */
  11550     RECOMP_ICALL(MEM32(0x31048268)); /* 0x3100B059: call dword ptr [0x31048268] */
  11551     RECOMP_FLAGS_IN();
  11552     esi = eax; /* 0x3100B05F: mov esi, eax */
  11553     /* test esi, esi */ /* 0x3100B061: test esi, esi */
  11554     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi);
  11555     _cf = 0;
  11556     _flag_k = FK_TEST;
  11557     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B649; /* 0x3100B063: je 0x3100b649 */
  11558 L_3100B069:
  11559     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11560     ecx = 0; /* 0x3100B069: xor ecx, ecx */
  11561     _cf = 0;
  11562     _flag_k = FK_TEST;
  11563     MEM32(ebp + (-0x44)) = ecx; /* 0x3100B06B: mov dword ptr [ebp - 0x44], ecx */
  11564     MEM32(ebp + (-0x40)) = ecx; /* 0x3100B06E: mov dword ptr [ebp - 0x40], ecx */
  11565     MEM32(ebp + (-0x3C)) = ecx; /* 0x3100B071: mov dword ptr [ebp - 0x3c], ecx */
  11566     PUSH32(esp, 0x7EDu); /* 0x3100B074: push 0x7ed */
  11567     MEM32(ebp + (-0x38)) = ecx; /* 0x3100B079: mov dword ptr [ebp - 0x38], ecx */
  11568     MEM16(ebp + (-0x44)) = (uint16_t)(2); /* 0x3100B07C: mov word ptr [ebp - 0x44], 2 */
  11569     RECOMP_ICALL(MEM32(0x31048270)); /* 0x3100B082: call dword ptr [0x31048270] */
  11570     RECOMP_FLAGS_IN();
  11571     MEM16(ebp + (-0x42)) = (uint16_t)(LO16(eax)); /* 0x3100B088: mov word ptr [ebp - 0x42], ax */
  11572     edx = MEM32(esi + 0xC); /* 0x3100B08C: mov edx, dword ptr [esi + 0xc] */
  11573     eax = MEM32(edx); /* 0x3100B08F: mov eax, dword ptr [edx] */
  11574     ecx = MEM32(eax); /* 0x3100B091: mov ecx, dword ptr [eax] */
  11575     eax = MEM32(ebx + 0x34); /* 0x3100B093: mov eax, dword ptr [ebx + 0x34] */
  11576     PUSH32(esp, 0x10u); /* 0x3100B096: push 0x10 */
  11577     edx = ebp + (-0x44); /* 0x3100B098: lea edx, [ebp - 0x44] */
  11578     PUSH32(esp, edx); /* 0x3100B09B: push edx */
  11579     PUSH32(esp, eax); /* 0x3100B09C: push eax */
  11580     MEM32(ebp + (-0x40)) = ecx; /* 0x3100B09D: mov dword ptr [ebp - 0x40], ecx */
  11581     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11582     esi = 0; /* 0x3100B0A0: xor esi, esi */
  11583     _cf = 0;
  11584     _flag_k = FK_TEST;
  11585     RECOMP_ICALL(MEM32(0x3104826C)); /* 0x3100B0A2: call dword ptr [0x3104826c] */
  11586     RECOMP_FLAGS_IN();
  11587     /* test eax, eax */ /* 0x3100B0A8: test eax, eax */
  11588     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11589     _cf = 0;
  11590     _flag_k = FK_TEST;
  11591     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B125; /* 0x3100B0AA: je 0x3100b125 */
  11592 L_3100B0AC:
  11593     edi = MEM32(0x310481F4); /* 0x3100B0AC: mov edi, dword ptr [0x310481f4] */
  11594 L_3100B0B2:
  11595     /* test esi, esi */ /* 0x3100B0B2: test esi, esi */
  11596     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi);
  11597     _cf = 0;
  11598     _flag_k = FK_TEST;
  11599     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100B0EE; /* 0x3100B0B4: jne 0x3100b0ee */
  11600 L_3100B0B6:
  11601     PUSH32(esp, esi); /* 0x3100B0B6: push esi */
  11602     RECOMP_ICALL(edi); /* 0x3100B0B7: call edi */
  11603     RECOMP_FLAGS_IN();
  11604     esi = eax; /* 0x3100B0B9: mov esi, eax */
  11605     eax = MEM32(ebp + (-0x50)); /* 0x3100B0BB: mov eax, dword ptr [ebp - 0x50] */
  11606     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  11607     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11608     esp = esp + 4; /* 0x3100B0BE: add esp, 4 */
  11609     _flag_k = FK_ADD;
  11610     /* test eax, eax */ /* 0x3100B0C1: test eax, eax */
  11611     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11612     _cf = 0;
  11613     _flag_k = FK_TEST;
  11614     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100B0CA; /* 0x3100B0C3: jne 0x3100b0ca */
  11615 L_3100B0C5:
  11616     eax = MEM32(0x310480EC); /* 0x3100B0C5: mov eax, dword ptr [0x310480ec] */
  11617 L_3100B0CA:
  11618     PUSH32(esp, eax); /* 0x3100B0CA: push eax */
  11619     ecx = ebp + (-0x21C); /* 0x3100B0CB: lea ecx, [ebp - 0x21c] */
  11620     PUSH32(esp, 0x31052298u); /* 0x3100B0D1: push 0x31052298 */
  11621     PUSH32(esp, ecx); /* 0x3100B0D6: push ecx */
  11622     RECOMP_ICALL(MEM32(0x31048208)); /* 0x3100B0D7: call dword ptr [0x31048208] */
  11623     RECOMP_FLAGS_IN();
  11624     edx = ebp + (-0x21C); /* 0x3100B0DD: lea edx, [ebp - 0x21c] */
  11625     PUSH32(esp, 0); /* 0x3100B0E3: push 0 */
  11626     PUSH32(esp, edx); /* 0x3100B0E5: push edx */
  11627     RECOMP_ICALL(0x310013E0u); /* 0x3100B0E6: call 0x310013e0 */ /* not lifted */
  11628     RECOMP_FLAGS_IN();
  11629     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x14u);
  11630     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11631     esp = esp + 0x14u; /* 0x3100B0EB: add esp, 0x14 */
  11632     _flag_k = FK_ADD;
  11633 L_3100B0EE:
  11634     PUSH32(esp, 0); /* 0x3100B0EE: push 0 */
  11635     RECOMP_ICALL(edi); /* 0x3100B0F0: call edi */
  11636     RECOMP_FLAGS_IN();
  11637     ecx = MEM32(ebp + 0x8); /* 0x3100B0F2: mov ecx, dword ptr [ebp + 8] */
  11638     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
  11639     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11640     eax = eax - esi; /* 0x3100B0F5: sub eax, esi */
  11641     _flag_k = FK_CMP;
  11642     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  11643     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11644     esp = esp + 4; /* 0x3100B0F7: add esp, 4 */
  11645     _flag_k = FK_ADD;
  11646     /* cmp eax, ecx */ /* 0x3100B0FA: cmp eax, ecx */
  11647     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  11648     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11649     _flag_k = FK_CMP;
  11650     if (CMP_A(_flag_a, _flag_b)) goto L_3100B619; /* 0x3100B0FC: ja 0x3100b619 */
  11651 L_3100B102:
  11652     PUSH32(esp, 0); /* 0x3100B102: push 0 */
  11653     PUSH32(esp, 0x31052294u); /* 0x3100B104: push 0x31052294 */
  11654     RECOMP_ICALL(0x310013E0u); /* 0x3100B109: call 0x310013e0 */ /* not lifted */
  11655     RECOMP_FLAGS_IN();
  11656     ecx = MEM32(ebx + 0x34); /* 0x3100B10E: mov ecx, dword ptr [ebx + 0x34] */
  11657     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  11658     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11659     esp = esp + 8; /* 0x3100B111: add esp, 8 */
  11660     _flag_k = FK_ADD;
  11661     PUSH32(esp, 0x10u); /* 0x3100B114: push 0x10 */
  11662     eax = ebp + (-0x44); /* 0x3100B116: lea eax, [ebp - 0x44] */
  11663     PUSH32(esp, eax); /* 0x3100B119: push eax */
  11664     PUSH32(esp, ecx); /* 0x3100B11A: push ecx */
  11665     RECOMP_ICALL(MEM32(0x3104826C)); /* 0x3100B11B: call dword ptr [0x3104826c] */
  11666     RECOMP_FLAGS_IN();
  11667     /* test eax, eax */ /* 0x3100B121: test eax, eax */
  11668     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11669     _cf = 0;
  11670     _flag_k = FK_TEST;
  11671     RECOMP_BACKEDGE();
  11672     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100B0B2; /* 0x3100B123: jne 0x3100b0b2 */
  11673 L_3100B125:
  11674     eax = MEM32(ebp + (-0x50)); /* 0x3100B125: mov eax, dword ptr [ebp - 0x50] */
  11675     /* test eax, eax */ /* 0x3100B128: test eax, eax */
  11676     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11677     _cf = 0;
  11678     _flag_k = FK_TEST;
  11679     MEM8(ebx + 0x245) = (uint8_t)(1); /* 0x3100B12A: mov byte ptr [ebx + 0x245], 1 */
  11680     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100B138; /* 0x3100B131: jne 0x3100b138 */
  11681 L_3100B133:
  11682     eax = MEM32(0x310480EC); /* 0x3100B133: mov eax, dword ptr [0x310480ec] */
  11683 L_3100B138:
  11684     PUSH32(esp, eax); /* 0x3100B138: push eax */
  11685     edx = ebp + (-0x2E4); /* 0x3100B139: lea edx, [ebp - 0x2e4] */
  11686     PUSH32(esp, 0x31052278u); /* 0x3100B13F: push 0x31052278 */
  11687     PUSH32(esp, edx); /* 0x3100B144: push edx */
  11688     RECOMP_ICALL(MEM32(0x31048208)); /* 0x3100B145: call dword ptr [0x31048208] */
  11689     RECOMP_FLAGS_IN();
  11690     SET_LO8(eax, MEM8(0x31057E60)); /* 0x3100B14B: mov al, byte ptr [0x31057e60] */
  11691     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
  11692     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11693     esp = esp + 0xCu; /* 0x3100B150: add esp, 0xc */
  11694     _flag_k = FK_ADD;
  11695     /* test LO8(eax), LO8(eax) */ /* 0x3100B153: test al, al */
  11696     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  11697     _cf = 0;
  11698     _flag_k = FK_NARROW(FK_TEST, 24);
  11699     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100B168; /* 0x3100B155: jne 0x3100b168 */
  11700 L_3100B157:
  11701     eax = ebp + (-0x2E4); /* 0x3100B157: lea eax, [ebp - 0x2e4] */
  11702     PUSH32(esp, 0); /* 0x3100B15D: push 0 */
  11703     PUSH32(esp, eax); /* 0x3100B15F: push eax */
  11704     RECOMP_ICALL(0x310013E0u); /* 0x3100B160: call 0x310013e0 */ /* not lifted */
  11705     RECOMP_FLAGS_IN();
  11706     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  11707     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11708     esp = esp + 8; /* 0x3100B165: add esp, 8 */
  11709     _flag_k = FK_ADD;
  11710 L_3100B168:
  11711     PUSH32(esp, 1); /* 0x3100B168: push 1 */
  11712     ecx = ebp + (-0x1D); /* 0x3100B16A: lea ecx, [ebp - 0x1d] */
  11713     PUSH32(esp, ecx); /* 0x3100B16D: push ecx */
  11714     PUSH32(esp, 1); /* 0x3100B16E: push 1 */
  11715     MEM8(0x31057E60) = (uint8_t)(1); /* 0x3100B170: mov byte ptr [0x31057e60], 1 */
  11716     edx = MEM32(ebx + 0x34); /* 0x3100B177: mov edx, dword ptr [ebx + 0x34] */
  11717     PUSH32(esp, 6); /* 0x3100B17A: push 6 */
  11718     PUSH32(esp, edx); /* 0x3100B17C: push edx */
  11719     MEM8(ebp + (-0x1D)) = (uint8_t)(1); /* 0x3100B17D: mov byte ptr [ebp - 0x1d], 1 */
  11720     RECOMP_ICALL(MEM32(0x3104825C)); /* 0x3100B181: call dword ptr [0x3104825c] */
  11721     RECOMP_FLAGS_IN();
  11722     /* test eax, eax */ /* 0x3100B187: test eax, eax */
  11723     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  11724     _cf = 0;
  11725     _flag_k = FK_TEST;
  11726     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B19A; /* 0x3100B189: je 0x3100b19a */
  11727 L_3100B18B:
  11728     PUSH32(esp, 0); /* 0x3100B18B: push 0 */
  11729     PUSH32(esp, 0x31052258u); /* 0x3100B18D: push 0x31052258 */
  11730     RECOMP_ICALL(0x310013E0u); /* 0x3100B192: call 0x310013e0 */ /* not lifted */
  11731     RECOMP_FLAGS_IN();
  11732     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  11733     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11734     esp = esp + 8; /* 0x3100B197: add esp, 8 */
  11735     _flag_k = FK_ADD;
  11736 L_3100B19A:
  11737     SET_LO8(eax, MEM8(ebx + 0x4)); /* 0x3100B19A: mov al, byte ptr [ebx + 4] */
  11738     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(4);
  11739     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11740     ebx = ebx + 4; /* 0x3100B19D: add ebx, 4 */
  11741     _flag_k = FK_ADD;
  11742     PUSH32(esp, 0); /* 0x3100B1A0: push 0 */
  11743     ecx = ebp + (-0x30); /* 0x3100B1A2: lea ecx, [ebp - 0x30] */
  11744     MEM8(ebp + (-0x30)) = (uint8_t)(LO8(eax)); /* 0x3100B1A5: mov byte ptr [ebp - 0x30], al */
  11745     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100B1A8: call dword ptr [0x310480d4] */
  11746     RECOMP_FLAGS_IN();
  11747     ecx = MEM32(0x310480F8); /* 0x3100B1AE: mov ecx, dword ptr [0x310480f8] */
  11748     edx = MEM32(ecx); /* 0x3100B1B4: mov edx, dword ptr [ecx] */
  11749     PUSH32(esp, edx); /* 0x3100B1B6: push edx */
  11750     PUSH32(esp, 0); /* 0x3100B1B7: push 0 */
  11751     PUSH32(esp, ebx); /* 0x3100B1B9: push ebx */
  11752     ecx = ebp + (-0x30); /* 0x3100B1BA: lea ecx, [ebp - 0x30] */
  11753     RECOMP_ICALL(MEM32(0x310480FC)); /* 0x3100B1BD: call dword ptr [0x310480fc] */
  11754     RECOMP_FLAGS_IN();
  11755     edi = MEM32(0x310482C8); /* 0x3100B1C3: mov edi, dword ptr [0x310482c8] */
  11756     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100B1C9: push -1 */
  11757     ecx = ebp + (-0x94); /* 0x3100B1CB: lea ecx, [ebp - 0x94] */
  11758     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3100B1D1: mov byte ptr [ebp - 4], 1 */
  11759     RECOMP_ICALL(edi); /* 0x3100B1D5: call edi */
  11760     RECOMP_FLAGS_IN();
  11761     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100B1D7: push -1 */
  11762     ecx = ebp + (-0xD4); /* 0x3100B1D9: lea ecx, [ebp - 0xd4] */
  11763     MEM8(ebp + (-0x4)) = (uint8_t)(2); /* 0x3100B1DF: mov byte ptr [ebp - 4], 2 */
  11764     RECOMP_ICALL(edi); /* 0x3100B1E3: call edi */
  11765     RECOMP_FLAGS_IN();
  11766     SET_LO8(eax, MEM8(ebp + 0xB)); /* 0x3100B1E5: mov al, byte ptr [ebp + 0xb] */
  11767     PUSH32(esp, 0); /* 0x3100B1E8: push 0 */
  11768     ecx = ebp + (-0x1C); /* 0x3100B1EA: lea ecx, [ebp - 0x1c] */
  11769     MEM8(ebp + (-0x4)) = (uint8_t)(3); /* 0x3100B1ED: mov byte ptr [ebp - 4], 3 */
  11770     MEM8(ebp + (-0x1C)) = (uint8_t)(LO8(eax)); /* 0x3100B1F1: mov byte ptr [ebp - 0x1c], al */
  11771     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100B1F4: call dword ptr [0x310480d4] */
  11772     RECOMP_FLAGS_IN();
  11773     _flag_a = (uint32_t)((ecx | 0xFFFFFFFFu)); _flag_b = (uint32_t)((ecx | 0xFFFFFFFFu));
  11774     ecx = ecx | 0xFFFFFFFFu; /* 0x3100B1FA: or ecx, 0xffffffff */
  11775     _cf = 0;
  11776     _flag_k = FK_TEST;
  11777     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11778     eax = 0; /* 0x3100B1FD: xor eax, eax */
  11779     _cf = 0;
  11780     _flag_k = FK_TEST;
  11781     edi = 0x31052250u; /* 0x3100B1FF: mov edi, 0x31052250 */
  11782     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; } /* 0x3100B204: repne scasb al, byte ptr es:[edi] */
  11783     ecx = ~ecx; /* 0x3100B206: not ecx */
  11784     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
  11785     ecx = ecx - 1; /* 0x3100B208: dec ecx */
  11786     _flag_k = FK_DEC;
  11787     esi = ecx; /* 0x3100B209: mov esi, ecx */
  11788     PUSH32(esp, 1); /* 0x3100B20B: push 1 */
  11789     PUSH32(esp, esi); /* 0x3100B20D: push esi */
  11790     ecx = ebp + (-0x1C); /* 0x3100B20E: lea ecx, [ebp - 0x1c] */
  11791     MEM32(ebp + 0x8) = esi; /* 0x3100B211: mov dword ptr [ebp + 8], esi */
  11792     RECOMP_ICALL(MEM32(0x31048070)); /* 0x3100B214: call dword ptr [0x31048070] */
  11793     RECOMP_FLAGS_IN();
  11794     /* test LO8(eax), LO8(eax) */ /* 0x3100B21A: test al, al */
  11795     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  11796     _cf = 0;
  11797     _flag_k = FK_NARROW(FK_TEST, 24);
  11798     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B242; /* 0x3100B21C: je 0x3100b242 */
  11799 L_3100B21E:
  11800     edi = MEM32(ebp + (-0x18)); /* 0x3100B21E: mov edi, dword ptr [ebp - 0x18] */
  11801     ecx = esi; /* 0x3100B221: mov ecx, esi */
  11802     edx = ecx; /* 0x3100B223: mov edx, ecx */
  11803     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100B225: shr ecx, 2 */
  11804     if (2u) { _flag_a = recomp_flags_pack((ecx >> 2u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  11805     ecx = ecx >> 2u; /* 0x3100B225: shr ecx, 2 */
  11806     esi = 0x31052250u; /* 0x3100B228: mov esi, 0x31052250 */
  11807     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3100B22D: 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; }
  11808     ecx = edx; /* 0x3100B22F: mov ecx, edx */
  11809     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(3);
  11810     ecx = ecx & 3; /* 0x3100B231: and ecx, 3 */
  11811     _cf = 0;
  11812     _flag_k = FK_TEST;
  11813     eax = edx; /* 0x3100B234: mov eax, edx */
  11814     if (ecx) { uint32_t _n = ecx, _b = _n * 1u; /* 0x3100B236: 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; }
  11815     PUSH32(esp, eax); /* 0x3100B238: push eax */
  11816     ecx = ebp + (-0x1C); /* 0x3100B239: lea ecx, [ebp - 0x1c] */
  11817     RECOMP_ICALL(MEM32(0x310480E8)); /* 0x3100B23C: call dword ptr [0x310480e8] */
  11818     RECOMP_FLAGS_IN();
  11819 L_3100B242:
  11820     esi = MEM32(0x310482CC); /* 0x3100B242: mov esi, dword ptr [0x310482cc] */
  11821     ecx = ebp + (-0x1C); /* 0x3100B248: lea ecx, [ebp - 0x1c] */
  11822     PUSH32(esp, ecx); /* 0x3100B24B: push ecx */
  11823     PUSH32(esp, 0x3105224Cu); /* 0x3100B24C: push 0x3105224c */
  11824     ecx = ebp + (-0x94); /* 0x3100B251: lea ecx, [ebp - 0x94] */
  11825     MEM8(ebp + (-0x4)) = (uint8_t)(4); /* 0x3100B257: mov byte ptr [ebp - 4], 4 */
  11826     RECOMP_ICALL(esi); /* 0x3100B25B: call esi */
  11827     RECOMP_FLAGS_IN();
  11828     PUSH32(esp, 1); /* 0x3100B25D: push 1 */
  11829     ecx = ebp + (-0x1C); /* 0x3100B25F: lea ecx, [ebp - 0x1c] */
  11830     MEM8(ebp + (-0x4)) = (uint8_t)(3); /* 0x3100B262: mov byte ptr [ebp - 4], 3 */
  11831     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100B266: call dword ptr [0x310480d4] */
  11832     RECOMP_FLAGS_IN();
  11833     PUSH32(esp, ebx); /* 0x3100B26C: push ebx */
  11834     PUSH32(esp, 0x31052244u); /* 0x3100B26D: push 0x31052244 */
  11835     ecx = ebp + (-0x94); /* 0x3100B272: lea ecx, [ebp - 0x94] */
  11836     RECOMP_ICALL(esi); /* 0x3100B278: call esi */
  11837     RECOMP_FLAGS_IN();
  11838     PUSH32(esp, 0x80u); /* 0x3100B27A: push 0x80 */
  11839     edx = ebp + (-0x154); /* 0x3100B27F: lea edx, [ebp - 0x154] */
  11840     PUSH32(esp, edx); /* 0x3100B285: push edx */
  11841     RECOMP_ICALL(MEM32(0x31048264)); /* 0x3100B286: call dword ptr [0x31048264] */
  11842     RECOMP_FLAGS_IN();
  11843     SET_LO8(eax, MEM8(ebp + 0xB)); /* 0x3100B28C: mov al, byte ptr [ebp + 0xb] */
  11844     PUSH32(esp, 0); /* 0x3100B28F: push 0 */
  11845     ecx = ebp + (-0x1C); /* 0x3100B291: lea ecx, [ebp - 0x1c] */
  11846     MEM8(ebp + (-0x1C)) = (uint8_t)(LO8(eax)); /* 0x3100B294: mov byte ptr [ebp - 0x1c], al */
  11847     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100B297: call dword ptr [0x310480d4] */
  11848     RECOMP_FLAGS_IN();
  11849     _flag_a = (uint32_t)((ecx | 0xFFFFFFFFu)); _flag_b = (uint32_t)((ecx | 0xFFFFFFFFu));
  11850     ecx = ecx | 0xFFFFFFFFu; /* 0x3100B29D: or ecx, 0xffffffff */
  11851     _cf = 0;
  11852     _flag_k = FK_TEST;
  11853     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11854     eax = 0; /* 0x3100B2A0: xor eax, eax */
  11855     _cf = 0;
  11856     _flag_k = FK_TEST;
  11857     edi = ebp + (-0x154); /* 0x3100B2A2: lea edi, [ebp - 0x154] */
  11858     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; } /* 0x3100B2A8: repne scasb al, byte ptr es:[edi] */
  11859     ecx = ~ecx; /* 0x3100B2AA: not ecx */
  11860     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
  11861     ecx = ecx - 1; /* 0x3100B2AC: dec ecx */
  11862     _flag_k = FK_DEC;
  11863     ebx = ecx; /* 0x3100B2AD: mov ebx, ecx */
  11864     PUSH32(esp, 1); /* 0x3100B2AF: push 1 */
  11865     PUSH32(esp, ebx); /* 0x3100B2B1: push ebx */
  11866     ecx = ebp + (-0x1C); /* 0x3100B2B2: lea ecx, [ebp - 0x1c] */
  11867     RECOMP_ICALL(MEM32(0x31048070)); /* 0x3100B2B5: call dword ptr [0x31048070] */
  11868     RECOMP_FLAGS_IN();
  11869     /* test LO8(eax), LO8(eax) */ /* 0x3100B2BB: test al, al */
  11870     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  11871     _cf = 0;
  11872     _flag_k = FK_NARROW(FK_TEST, 24);
  11873     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B2E8; /* 0x3100B2BD: je 0x3100b2e8 */
  11874 L_3100B2BF:
  11875     edi = MEM32(ebp + (-0x18)); /* 0x3100B2BF: mov edi, dword ptr [ebp - 0x18] */
  11876     ecx = ebx; /* 0x3100B2C2: mov ecx, ebx */
  11877     edx = ecx; /* 0x3100B2C4: mov edx, ecx */
  11878     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100B2C6: shr ecx, 2 */
  11879     if (2u) { _flag_a = recomp_flags_pack((ecx >> 2u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  11880     ecx = ecx >> 2u; /* 0x3100B2C6: shr ecx, 2 */
  11881     esi = ebp + (-0x154); /* 0x3100B2C9: lea esi, [ebp - 0x154] */
  11882     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3100B2CF: 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; }
  11883     ecx = edx; /* 0x3100B2D1: mov ecx, edx */
  11884     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(3);
  11885     ecx = ecx & 3; /* 0x3100B2D3: and ecx, 3 */
  11886     _cf = 0;
  11887     _flag_k = FK_TEST;
  11888     if (ecx) { uint32_t _n = ecx, _b = _n * 1u; /* 0x3100B2D6: 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; }
  11889     eax = MEM32(ebp + (-0x18)); /* 0x3100B2D8: mov eax, dword ptr [ebp - 0x18] */
  11890     esi = MEM32(0x310482CC); /* 0x3100B2DB: mov esi, dword ptr [0x310482cc] */
  11891     MEM32(ebp + (-0x14)) = ebx; /* 0x3100B2E1: mov dword ptr [ebp - 0x14], ebx */
  11892     MEM8(eax + ebx) = (uint8_t)(0); /* 0x3100B2E4: mov byte ptr [eax + ebx], 0 */
  11893 L_3100B2E8:
  11894     ecx = ebp + (-0x1C); /* 0x3100B2E8: lea ecx, [ebp - 0x1c] */
  11895     PUSH32(esp, ecx); /* 0x3100B2EB: push ecx */
  11896     PUSH32(esp, 0x3105223Cu); /* 0x3100B2EC: push 0x3105223c */
  11897     ecx = ebp + (-0x94); /* 0x3100B2F1: lea ecx, [ebp - 0x94] */
  11898     MEM8(ebp + (-0x4)) = (uint8_t)(5); /* 0x3100B2F7: mov byte ptr [ebp - 4], 5 */
  11899     RECOMP_ICALL(esi); /* 0x3100B2FB: call esi */
  11900     RECOMP_FLAGS_IN();
  11901     PUSH32(esp, 1); /* 0x3100B2FD: push 1 */
  11902     ecx = ebp + (-0x1C); /* 0x3100B2FF: lea ecx, [ebp - 0x1c] */
  11903     MEM8(ebp + (-0x4)) = (uint8_t)(3); /* 0x3100B302: mov byte ptr [ebp - 4], 3 */
  11904     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100B306: call dword ptr [0x310480d4] */
  11905     RECOMP_FLAGS_IN();
  11906     edi = MEM32(ebp + (-0x34)); /* 0x3100B30C: mov edi, dword ptr [ebp - 0x34] */
  11907     esi = edi + 0x30; /* 0x3100B30F: lea esi, [edi + 0x30] */
  11908 L_3100B312:
  11909     edx = ebp + (-0x94); /* 0x3100B312: lea edx, [ebp - 0x94] */
  11910     PUSH32(esp, edx); /* 0x3100B318: push edx */
  11911     ecx = esi; /* 0x3100B319: mov ecx, esi */
  11912     RECOMP_ICALL(0x31010CA0u); /* 0x3100B31B: call 0x31010ca0 */ /* not lifted */
  11913     RECOMP_FLAGS_IN();
  11914     eax = ebp + (-0xD4); /* 0x3100B320: lea eax, [ebp - 0xd4] */
  11915     PUSH32(esp, eax); /* 0x3100B326: push eax */
  11916     ecx = esi; /* 0x3100B327: mov ecx, esi */
  11917     RECOMP_ICALL(0x31010F40u); /* 0x3100B329: call 0x31010f40 */ /* not lifted */
  11918     RECOMP_FLAGS_IN();
  11919     /* test LO8(eax), LO8(eax) */ /* 0x3100B32E: test al, al */
  11920     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  11921     _cf = 0;
  11922     _flag_k = FK_NARROW(FK_TEST, 24);
  11923     RECOMP_BACKEDGE();
  11924     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B312; /* 0x3100B330: je 0x3100b312 */
  11925 L_3100B332:
  11926     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11927     esi = 0; /* 0x3100B332: xor esi, esi */
  11928     _cf = 0;
  11929     _flag_k = FK_TEST;
  11930     PUSH32(esp, esi); /* 0x3100B334: push esi */
  11931     ebx = edi + 0x4; /* 0x3100B335: lea ebx, [edi + 4] */
  11932     PUSH32(esp, ebx); /* 0x3100B338: push ebx */
  11933     PUSH32(esp, 0x31052234u); /* 0x3100B339: push 0x31052234 */
  11934     ecx = ebp + (-0xD4); /* 0x3100B33E: lea ecx, [ebp - 0xd4] */
  11935     RECOMP_ICALL(MEM32(0x310482D0)); /* 0x3100B344: call dword ptr [0x310482d0] */
  11936     RECOMP_FLAGS_IN();
  11937     PUSH32(esp, esi); /* 0x3100B34A: push esi */
  11938     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(0x23Cu);
  11939     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11940     edi = edi + 0x23Cu; /* 0x3100B34B: add edi, 0x23c */
  11941     _flag_k = FK_ADD;
  11942     PUSH32(esp, edi); /* 0x3100B351: push edi */
  11943     PUSH32(esp, 0x3105222Cu); /* 0x3100B352: push 0x3105222c */
  11944     ecx = ebp + (-0xD4); /* 0x3100B357: lea ecx, [ebp - 0xd4] */
  11945     RECOMP_ICALL(MEM32(0x310482D4)); /* 0x3100B35D: call dword ptr [0x310482d4] */
  11946     RECOMP_FLAGS_IN();
  11947     ecx = ebp + (-0x30); /* 0x3100B363: lea ecx, [ebp - 0x30] */
  11948     PUSH32(esp, ecx); /* 0x3100B366: push ecx */
  11949     PUSH32(esp, ebx); /* 0x3100B367: push ebx */
  11950     RECOMP_ICALL(MEM32(0x31048088)); /* 0x3100B368: call dword ptr [0x31048088] */
  11951     RECOMP_FLAGS_IN();
  11952     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  11953     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  11954     esp = esp + 8; /* 0x3100B36E: add esp, 8 */
  11955     _flag_k = FK_ADD;
  11956     /* test LO8(eax), LO8(eax) */ /* 0x3100B371: test al, al */
  11957     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  11958     _cf = 0;
  11959     _flag_k = FK_NARROW(FK_TEST, 24);
  11960     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B4EE; /* 0x3100B373: je 0x3100b4ee */
  11961 L_3100B379:
  11962     PUSH32(esp, 1); /* 0x3100B379: push 1 */
  11963     PUSH32(esp, esi); /* 0x3100B37B: push esi */
  11964     edx = ebp + 0xB; /* 0x3100B37C: lea edx, [ebp + 0xb] */
  11965     PUSH32(esp, edx); /* 0x3100B37F: push edx */
  11966     ecx = ebp + (-0x30); /* 0x3100B380: lea ecx, [ebp - 0x30] */
  11967     MEM8(ebp + 0xB) = (uint8_t)(0x2Fu); /* 0x3100B383: mov byte ptr [ebp + 0xb], 0x2f */
  11968     RECOMP_ICALL(MEM32(0x310480AC)); /* 0x3100B387: call dword ptr [0x310480ac] */
  11969     RECOMP_FLAGS_IN();
  11970     edi = eax; /* 0x3100B38D: mov edi, eax */
  11971     PUSH32(esp, 1); /* 0x3100B38F: push 1 */
  11972     eax = edi + 0x1; /* 0x3100B391: lea eax, [edi + 1] */
  11973     PUSH32(esp, eax); /* 0x3100B394: push eax */
  11974     ecx = ebp + 0xB; /* 0x3100B395: lea ecx, [ebp + 0xb] */
  11975     PUSH32(esp, ecx); /* 0x3100B398: push ecx */
  11976     ecx = ebp + (-0x30); /* 0x3100B399: lea ecx, [ebp - 0x30] */
  11977     MEM8(ebp + 0xB) = (uint8_t)(0x2Fu); /* 0x3100B39C: mov byte ptr [ebp + 0xb], 0x2f */
  11978     RECOMP_ICALL(MEM32(0x310480AC)); /* 0x3100B3A0: call dword ptr [0x310480ac] */
  11979     RECOMP_FLAGS_IN();
  11980     ebx = eax; /* 0x3100B3A6: mov ebx, eax */
  11981     /* cmp ebx, 0xFFFFFFFFu */ /* 0x3100B3A8: cmp ebx, -1 */
  11982     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0xFFFFFFFFu);
  11983     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  11984     _flag_k = FK_CMP;
  11985     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B4EE; /* 0x3100B3AB: je 0x3100b4ee */
  11986 L_3100B3B1:
  11987     goto L_3100B3B5; /* 0x3100B3B1: jmp 0x3100b3b5 */
  11988 L_3100B3B3:
  11989     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  11990     esi = 0; /* 0x3100B3B3: xor esi, esi */
  11991     _cf = 0;
  11992     _flag_k = FK_TEST;
  11993 L_3100B3B5:
  11994     SET_LO8(edx, MEM8(ebp + (-0x30))); /* 0x3100B3B5: mov dl, byte ptr [ebp - 0x30] */
  11995     eax = MEM32(0x310480F8); /* 0x3100B3B8: mov eax, dword ptr [0x310480f8] */
  11996     MEM8(ebp + (-0x1C)) = (uint8_t)(LO8(edx)); /* 0x3100B3BD: mov byte ptr [ebp - 0x1c], dl */
  11997     MEM32(ebp + (-0x18)) = esi; /* 0x3100B3C0: mov dword ptr [ebp - 0x18], esi */
  11998     MEM32(ebp + (-0x14)) = esi; /* 0x3100B3C3: mov dword ptr [ebp - 0x14], esi */
  11999     MEM32(ebp + (-0x10)) = esi; /* 0x3100B3C6: mov dword ptr [ebp - 0x10], esi */
  12000     ecx = MEM32(eax); /* 0x3100B3C9: mov ecx, dword ptr [eax] */
  12001     PUSH32(esp, ecx); /* 0x3100B3CB: push ecx */
  12002     PUSH32(esp, esi); /* 0x3100B3CC: push esi */
  12003     edx = ebp + (-0x30); /* 0x3100B3CD: lea edx, [ebp - 0x30] */
  12004     PUSH32(esp, edx); /* 0x3100B3D0: push edx */
  12005     ecx = ebp + (-0x1C); /* 0x3100B3D1: lea ecx, [ebp - 0x1c] */
  12006     RECOMP_ICALL(MEM32(0x310480FC)); /* 0x3100B3D4: call dword ptr [0x310480fc] */
  12007     RECOMP_FLAGS_IN();
  12008     eax = MEM32(ebp + (-0x14)); /* 0x3100B3DA: mov eax, dword ptr [ebp - 0x14] */
  12009     esi = ebx; /* 0x3100B3DD: mov esi, ebx */
  12010     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(edi);
  12011     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12012     esi = esi - edi; /* 0x3100B3DF: sub esi, edi */
  12013     _flag_k = FK_CMP;
  12014     /* cmp eax, edi */ /* 0x3100B3E1: cmp eax, edi */
  12015     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
  12016     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12017     _flag_k = FK_CMP;
  12018     MEM8(ebp + (-0x4)) = (uint8_t)(6); /* 0x3100B3E3: mov byte ptr [ebp - 4], 6 */
  12019     if (CMP_AE(_flag_a, _flag_b)) goto L_3100B3F2; /* 0x3100B3E7: jae 0x3100b3f2 */
  12020 L_3100B3E9:
  12021     RECOMP_ICALL(MEM32(0x310480B4)); /* 0x3100B3E9: call dword ptr [0x310480b4] */
  12022     RECOMP_FLAGS_IN();
  12023     eax = MEM32(ebp + (-0x14)); /* 0x3100B3EF: mov eax, dword ptr [ebp - 0x14] */
  12024 L_3100B3F2:
  12025     ecx = eax; /* 0x3100B3F2: mov ecx, eax */
  12026     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
  12027     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12028     ecx = ecx - edi; /* 0x3100B3F4: sub ecx, edi */
  12029     _flag_k = FK_CMP;
  12030     /* cmp ecx, esi */ /* 0x3100B3F6: cmp ecx, esi */
  12031     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(esi);
  12032     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12033     _flag_k = FK_CMP;
  12034     if (CMP_AE(_flag_a, _flag_b)) goto L_3100B3FC; /* 0x3100B3F8: jae 0x3100b3fc */
  12035 L_3100B3FA:
  12036     esi = ecx; /* 0x3100B3FA: mov esi, ecx */
  12037 L_3100B3FC:
  12038     /* test esi, esi */ /* 0x3100B3FC: test esi, esi */
  12039     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(esi);
  12040     _cf = 0;
  12041     _flag_k = FK_TEST;
  12042     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B469; /* 0x3100B3FE: jbe 0x3100b469 */
  12043 L_3100B400:
  12044     edx = MEM32(ebp + (-0x18)); /* 0x3100B400: mov edx, dword ptr [ebp - 0x18] */
  12045     /* test edx, edx */ /* 0x3100B403: test edx, edx */
  12046     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
  12047     _cf = 0;
  12048     _flag_k = FK_TEST;
  12049     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B433; /* 0x3100B405: je 0x3100b433 */
  12050 L_3100B407:
  12051     SET_LO8(ecx, MEM8(edx + (-0x1))); /* 0x3100B407: mov cl, byte ptr [edx - 1] */
  12052     /* test LO8(ecx), LO8(ecx) */ /* 0x3100B40A: test cl, cl */
  12053     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24;
  12054     _cf = 0;
  12055     _flag_k = FK_NARROW(FK_TEST, 24);
  12056     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B425; /* 0x3100B40C: je 0x3100b425 */
  12057 L_3100B40E:
  12058     /* cmp LO8(ecx), 0xFFu */ /* 0x3100B40E: cmp cl, 0xff */
  12059     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
  12060     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12061     _flag_k = FK_NARROW(FK_CMP, 24);
  12062     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B425; /* 0x3100B411: je 0x3100b425 */
  12063 L_3100B413:
  12064     PUSH32(esp, 0); /* 0x3100B413: push 0 */
  12065     PUSH32(esp, eax); /* 0x3100B415: push eax */
  12066     ecx = ebp + (-0x1C); /* 0x3100B416: lea ecx, [ebp - 0x1c] */
  12067     RECOMP_ICALL(MEM32(0x31048070)); /* 0x3100B419: call dword ptr [0x31048070] */
  12068     RECOMP_FLAGS_IN();
  12069     eax = MEM32(ebp + (-0x14)); /* 0x3100B41F: mov eax, dword ptr [ebp - 0x14] */
  12070     edx = MEM32(ebp + (-0x18)); /* 0x3100B422: mov edx, dword ptr [ebp - 0x18] */
  12071 L_3100B425:
  12072     /* test edx, edx */ /* 0x3100B425: test edx, edx */
  12073     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edx);
  12074     _cf = 0;
  12075     _flag_k = FK_TEST;
  12076     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B433; /* 0x3100B427: je 0x3100b433 */
  12077 L_3100B429:
  12078     MEM8(edx + (-0x1)) = (uint8_t)(0xFFu); /* 0x3100B429: mov byte ptr [edx - 1], 0xff */
  12079     eax = MEM32(ebp + (-0x14)); /* 0x3100B42D: mov eax, dword ptr [ebp - 0x14] */
  12080     edx = MEM32(ebp + (-0x18)); /* 0x3100B430: mov edx, dword ptr [ebp - 0x18] */
  12081 L_3100B433:
  12082     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
  12083     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12084     eax = eax - esi; /* 0x3100B433: sub eax, esi */
  12085     _flag_k = FK_CMP;
  12086     ecx = edx + esi; /* 0x3100B435: lea ecx, [edx + esi] */
  12087     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
  12088     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12089     eax = eax - edi; /* 0x3100B438: sub eax, edi */
  12090     _flag_k = FK_CMP;
  12091     PUSH32(esp, eax); /* 0x3100B43A: push eax */
  12092     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
  12093     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12094     ecx = ecx + edi; /* 0x3100B43B: add ecx, edi */
  12095     _flag_k = FK_ADD;
  12096     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(edi);
  12097     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12098     edx = edx + edi; /* 0x3100B43D: add edx, edi */
  12099     _flag_k = FK_ADD;
  12100     PUSH32(esp, ecx); /* 0x3100B43F: push ecx */
  12101     PUSH32(esp, edx); /* 0x3100B440: push edx */
  12102     RECOMP_ICALL(MEM32(0x3104822C)); /* 0x3100B441: call dword ptr [0x3104822c] */
  12103     RECOMP_FLAGS_IN();
  12104     edi = MEM32(ebp + (-0x14)); /* 0x3100B447: mov edi, dword ptr [ebp - 0x14] */
  12105     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
  12106     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12107     esp = esp + 0xCu; /* 0x3100B44A: add esp, 0xc */
  12108     _flag_k = FK_ADD;
  12109     PUSH32(esp, 0); /* 0x3100B44D: push 0 */
  12110     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(esi);
  12111     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12112     edi = edi - esi; /* 0x3100B44F: sub edi, esi */
  12113     _flag_k = FK_CMP;
  12114     PUSH32(esp, edi); /* 0x3100B451: push edi */
  12115     ecx = ebp + (-0x1C); /* 0x3100B452: lea ecx, [ebp - 0x1c] */
  12116     RECOMP_ICALL(MEM32(0x31048070)); /* 0x3100B455: call dword ptr [0x31048070] */
  12117     RECOMP_FLAGS_IN();
  12118     /* test LO8(eax), LO8(eax) */ /* 0x3100B45B: test al, al */
  12119     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  12120     _cf = 0;
  12121     _flag_k = FK_NARROW(FK_TEST, 24);
  12122     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B469; /* 0x3100B45D: je 0x3100b469 */
  12123 L_3100B45F:
  12124     PUSH32(esp, edi); /* 0x3100B45F: push edi */
  12125     ecx = ebp + (-0x1C); /* 0x3100B460: lea ecx, [ebp - 0x1c] */
  12126     RECOMP_ICALL(MEM32(0x310480E8)); /* 0x3100B463: call dword ptr [0x310480e8] */
  12127     RECOMP_FLAGS_IN();
  12128 L_3100B469:
  12129     esi = MEM32(ebp + (-0x34)); /* 0x3100B469: mov esi, dword ptr [ebp - 0x34] */
  12130     eax = MEM32(esi); /* 0x3100B46C: mov eax, dword ptr [esi] */
  12131     ecx = ebp + (-0x1C); /* 0x3100B46E: lea ecx, [ebp - 0x1c] */
  12132     PUSH32(esp, ecx); /* 0x3100B471: push ecx */
  12133     ecx = esi; /* 0x3100B472: mov ecx, esi */
  12134     RECOMP_ICALL(MEM32(eax + 0x44)); /* 0x3100B474: call dword ptr [eax + 0x44] */
  12135     RECOMP_FLAGS_IN();
  12136     eax = esi + 0x4; /* 0x3100B477: lea eax, [esi + 4] */
  12137     PUSH32(esp, eax); /* 0x3100B47A: push eax */
  12138     edx = ebp + (-0x1C); /* 0x3100B47B: lea edx, [ebp - 0x1c] */
  12139     PUSH32(esp, edx); /* 0x3100B47E: push edx */
  12140     edi = ebx; /* 0x3100B47F: mov edi, ebx */
  12141     RECOMP_ICALL(MEM32(0x3104808C)); /* 0x3100B481: call dword ptr [0x3104808c] */
  12142     RECOMP_FLAGS_IN();
  12143     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  12144     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12145     esp = esp + 8; /* 0x3100B487: add esp, 8 */
  12146     _flag_k = FK_ADD;
  12147     /* test LO8(eax), LO8(eax) */ /* 0x3100B48A: test al, al */
  12148     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  12149     _cf = 0;
  12150     _flag_k = FK_NARROW(FK_TEST, 24);
  12151     MEM8(ebp + (-0x4)) = (uint8_t)(3); /* 0x3100B48C: mov byte ptr [ebp - 4], 3 */
  12152     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100B4E1; /* 0x3100B490: jne 0x3100b4e1 */
  12153 L_3100B492:
  12154     ecx = MEM32(ebp + (-0x18)); /* 0x3100B492: mov ecx, dword ptr [ebp - 0x18] */
  12155     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  12156     esi = 0; /* 0x3100B495: xor esi, esi */
  12157     _cf = 0;
  12158     _flag_k = FK_TEST;
  12159     /* cmp ecx, esi */ /* 0x3100B497: cmp ecx, esi */
  12160     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(esi);
  12161     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12162     _flag_k = FK_CMP;
  12163     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B4B6; /* 0x3100B499: je 0x3100b4b6 */
  12164 L_3100B49B:
  12165     SET_LO8(eax, MEM8(ecx + (-0x1))); /* 0x3100B49B: mov al, byte ptr [ecx - 1] */
  12166     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
  12167     ecx = ecx - 1; /* 0x3100B49E: dec ecx */
  12168     _flag_k = FK_DEC;
  12169     /* test LO8(eax), LO8(eax) */ /* 0x3100B49F: test al, al */
  12170     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  12171     _cf = 0;
  12172     _flag_k = FK_NARROW(FK_TEST, 24);
  12173     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B4AD; /* 0x3100B4A1: je 0x3100b4ad */
  12174 L_3100B4A3:
  12175     /* cmp LO8(eax), 0xFFu */ /* 0x3100B4A3: cmp al, 0xff */
  12176     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
  12177     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12178     _flag_k = FK_NARROW(FK_CMP, 24);
  12179     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B4AD; /* 0x3100B4A5: je 0x3100b4ad */
  12180 L_3100B4A7:
  12181     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
  12182     SET_LO8(eax, LO8(eax) - 1); /* 0x3100B4A7: dec al */
  12183     _flag_k = FK_NARROW(FK_DEC, 24);
  12184     MEM8(ecx) = (uint8_t)(LO8(eax)); /* 0x3100B4A9: mov byte ptr [ecx], al */
  12185     goto L_3100B4B6; /* 0x3100B4AB: jmp 0x3100b4b6 */
  12186 L_3100B4AD:
  12187     PUSH32(esp, ecx); /* 0x3100B4AD: push ecx */
  12188     RECOMP_ICALL(0x31046858u); /* 0x3100B4AE: call 0x31046858 */ /* not lifted */
  12189     RECOMP_FLAGS_IN();
  12190     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12191     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12192     esp = esp + 4; /* 0x3100B4B3: add esp, 4 */
  12193     _flag_k = FK_ADD;
  12194 L_3100B4B6:
  12195     PUSH32(esp, 1); /* 0x3100B4B6: push 1 */
  12196     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(1);
  12197     ebx = ebx + 1; /* 0x3100B4B8: inc ebx */
  12198     _flag_k = FK_INC;
  12199     PUSH32(esp, ebx); /* 0x3100B4B9: push ebx */
  12200     eax = ebp + 0xB; /* 0x3100B4BA: lea eax, [ebp + 0xb] */
  12201     PUSH32(esp, eax); /* 0x3100B4BD: push eax */
  12202     ecx = ebp + (-0x30); /* 0x3100B4BE: lea ecx, [ebp - 0x30] */
  12203     MEM32(ebp + (-0x18)) = esi; /* 0x3100B4C1: mov dword ptr [ebp - 0x18], esi */
  12204     MEM32(ebp + (-0x14)) = esi; /* 0x3100B4C4: mov dword ptr [ebp - 0x14], esi */
  12205     MEM32(ebp + (-0x10)) = esi; /* 0x3100B4C7: mov dword ptr [ebp - 0x10], esi */
  12206     MEM8(ebp + 0xB) = (uint8_t)(0x2Fu); /* 0x3100B4CA: mov byte ptr [ebp + 0xb], 0x2f */
  12207     RECOMP_ICALL(MEM32(0x310480AC)); /* 0x3100B4CE: call dword ptr [0x310480ac] */
  12208     RECOMP_FLAGS_IN();
  12209     ebx = eax; /* 0x3100B4D4: mov ebx, eax */
  12210     /* cmp ebx, 0xFFFFFFFFu */ /* 0x3100B4D6: cmp ebx, -1 */
  12211     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(0xFFFFFFFFu);
  12212     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12213     _flag_k = FK_CMP;
  12214     RECOMP_BACKEDGE();
  12215     if (CMP_NE(_flag_a, _flag_b)) goto L_3100B3B3; /* 0x3100B4D9: jne 0x3100b3b3 */
  12216 L_3100B4DF:
  12217     goto L_3100B4EC; /* 0x3100B4DF: jmp 0x3100b4ec */
  12218 L_3100B4E1:
  12219     PUSH32(esp, 1); /* 0x3100B4E1: push 1 */
  12220     ecx = ebp + (-0x1C); /* 0x3100B4E3: lea ecx, [ebp - 0x1c] */
  12221     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100B4E6: call dword ptr [0x310480d4] */
  12222     RECOMP_FLAGS_IN();
  12223 L_3100B4EC:
  12224     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  12225     esi = 0; /* 0x3100B4EC: xor esi, esi */
  12226     _cf = 0;
  12227     _flag_k = FK_TEST;
  12228 L_3100B4EE:
  12229     ebx = 0x3104876Cu; /* 0x3100B4EE: mov ebx, 0x3104876c */
  12230     MEM32(ebp + (-0xD4)) = ebx; /* 0x3100B4F3: mov dword ptr [ebp - 0xd4], ebx */
  12231     edi = MEM32(0x310482F8); /* 0x3100B4F9: mov edi, dword ptr [0x310482f8] */
  12232     ecx = ebp + (-0xD4); /* 0x3100B4FF: lea ecx, [ebp - 0xd4] */
  12233     MEM8(ebp + (-0x4)) = (uint8_t)(8); /* 0x3100B505: mov byte ptr [ebp - 4], 8 */
  12234     RECOMP_ICALL(edi); /* 0x3100B509: call edi */
  12235     RECOMP_FLAGS_IN();
  12236     ecx = MEM32(ebp + (-0x9C)); /* 0x3100B50B: mov ecx, dword ptr [ebp - 0x9c] */
  12237     edx = MEM32(ebp + (-0xA0)); /* 0x3100B511: mov edx, dword ptr [ebp - 0xa0] */
  12238     PUSH32(esp, ecx); /* 0x3100B517: push ecx */
  12239     PUSH32(esp, edx); /* 0x3100B518: push edx */
  12240     ecx = ebp + (-0xA4); /* 0x3100B519: lea ecx, [ebp - 0xa4] */
  12241     MEM8(ebp + (-0x4)) = (uint8_t)(7); /* 0x3100B51F: mov byte ptr [ebp - 4], 7 */
  12242     RECOMP_ICALL(0x3100E4D0u); /* 0x3100B523: call 0x3100e4d0 */ /* not lifted */
  12243     RECOMP_FLAGS_IN();
  12244     eax = MEM32(ebp + (-0xA0)); /* 0x3100B528: mov eax, dword ptr [ebp - 0xa0] */
  12245     PUSH32(esp, eax); /* 0x3100B52E: push eax */
  12246     RECOMP_ICALL(0x31046858u); /* 0x3100B52F: call 0x31046858 */ /* not lifted */
  12247     RECOMP_FLAGS_IN();
  12248     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12249     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12250     esp = esp + 4; /* 0x3100B534: add esp, 4 */
  12251     _flag_k = FK_ADD;
  12252     ecx = ebp + (-0xD0); /* 0x3100B537: lea ecx, [ebp - 0xd0] */
  12253     MEM32(ebp + (-0xA0)) = esi; /* 0x3100B53D: mov dword ptr [ebp - 0xa0], esi */
  12254     MEM32(ebp + (-0x9C)) = esi; /* 0x3100B543: mov dword ptr [ebp - 0x9c], esi */
  12255     MEM32(ebp + (-0x98)) = esi; /* 0x3100B549: mov dword ptr [ebp - 0x98], esi */
  12256     MEM8(ebp + (-0x4)) = (uint8_t)(2); /* 0x3100B54F: mov byte ptr [ebp - 4], 2 */
  12257     RECOMP_ICALL(0x3100E340u); /* 0x3100B553: call 0x3100e340 */ /* not lifted */
  12258     RECOMP_FLAGS_IN();
  12259     MEM32(ebp + (-0x94)) = ebx; /* 0x3100B558: mov dword ptr [ebp - 0x94], ebx */
  12260     ecx = ebp + (-0x94); /* 0x3100B55E: lea ecx, [ebp - 0x94] */
  12261     MEM8(ebp + (-0x4)) = (uint8_t)(0xAu); /* 0x3100B564: mov byte ptr [ebp - 4], 0xa */
  12262     RECOMP_ICALL(edi); /* 0x3100B568: call edi */
  12263     RECOMP_FLAGS_IN();
  12264     ecx = MEM32(ebp + (-0x5C)); /* 0x3100B56A: mov ecx, dword ptr [ebp - 0x5c] */
  12265     edx = MEM32(ebp + (-0x60)); /* 0x3100B56D: mov edx, dword ptr [ebp - 0x60] */
  12266     PUSH32(esp, ecx); /* 0x3100B570: push ecx */
  12267     PUSH32(esp, edx); /* 0x3100B571: push edx */
  12268     ecx = ebp + (-0x64); /* 0x3100B572: lea ecx, [ebp - 0x64] */
  12269     MEM8(ebp + (-0x4)) = (uint8_t)(9); /* 0x3100B575: mov byte ptr [ebp - 4], 9 */
  12270     RECOMP_ICALL(0x3100E4D0u); /* 0x3100B579: call 0x3100e4d0 */ /* not lifted */
  12271     RECOMP_FLAGS_IN();
  12272     eax = MEM32(ebp + (-0x60)); /* 0x3100B57E: mov eax, dword ptr [ebp - 0x60] */
  12273     PUSH32(esp, eax); /* 0x3100B581: push eax */
  12274     RECOMP_ICALL(0x31046858u); /* 0x3100B582: call 0x31046858 */ /* not lifted */
  12275     RECOMP_FLAGS_IN();
  12276     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12277     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12278     esp = esp + 4; /* 0x3100B587: add esp, 4 */
  12279     _flag_k = FK_ADD;
  12280     ecx = ebp + (-0x90); /* 0x3100B58A: lea ecx, [ebp - 0x90] */
  12281     MEM32(ebp + (-0x60)) = esi; /* 0x3100B590: mov dword ptr [ebp - 0x60], esi */
  12282     MEM32(ebp + (-0x5C)) = esi; /* 0x3100B593: mov dword ptr [ebp - 0x5c], esi */
  12283     MEM32(ebp + (-0x58)) = esi; /* 0x3100B596: mov dword ptr [ebp - 0x58], esi */
  12284     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3100B599: mov byte ptr [ebp - 4], 1 */
  12285     RECOMP_ICALL(0x3100E340u); /* 0x3100B59D: call 0x3100e340 */ /* not lifted */
  12286     RECOMP_FLAGS_IN();
  12287     ecx = MEM32(ebp + (-0x2C)); /* 0x3100B5A2: mov ecx, dword ptr [ebp - 0x2c] */
  12288     /* cmp ecx, esi */ /* 0x3100B5A5: cmp ecx, esi */
  12289     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(esi);
  12290     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12291     _flag_k = FK_CMP;
  12292     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B5C5; /* 0x3100B5A7: je 0x3100b5c5 */
  12293 L_3100B5A9:
  12294     SET_LO8(eax, MEM8(ecx + (-0x1))); /* 0x3100B5A9: mov al, byte ptr [ecx - 1] */
  12295     /* test LO8(eax), LO8(eax) */ /* 0x3100B5AC: test al, al */
  12296     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  12297     _cf = 0;
  12298     _flag_k = FK_NARROW(FK_TEST, 24);
  12299     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B5BB; /* 0x3100B5AE: je 0x3100b5bb */
  12300 L_3100B5B0:
  12301     /* cmp LO8(eax), 0xFFu */ /* 0x3100B5B0: cmp al, 0xff */
  12302     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
  12303     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12304     _flag_k = FK_NARROW(FK_CMP, 24);
  12305     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B5BB; /* 0x3100B5B2: je 0x3100b5bb */
  12306 L_3100B5B4:
  12307     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
  12308     SET_LO8(eax, LO8(eax) - 1); /* 0x3100B5B4: dec al */
  12309     _flag_k = FK_NARROW(FK_DEC, 24);
  12310     MEM8(ecx + (-0x1)) = (uint8_t)(LO8(eax)); /* 0x3100B5B6: mov byte ptr [ecx - 1], al */
  12311     goto L_3100B5C5; /* 0x3100B5B9: jmp 0x3100b5c5 */
  12312 L_3100B5BB:
  12313     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
  12314     ecx = ecx - 1; /* 0x3100B5BB: dec ecx */
  12315     _flag_k = FK_DEC;
  12316     PUSH32(esp, ecx); /* 0x3100B5BC: push ecx */
  12317     RECOMP_ICALL(0x31046858u); /* 0x3100B5BD: call 0x31046858 */ /* not lifted */
  12318     RECOMP_FLAGS_IN();
  12319     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12320     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12321     esp = esp + 4; /* 0x3100B5C2: add esp, 4 */
  12322     _flag_k = FK_ADD;
  12323 L_3100B5C5:
  12324     ecx = MEM32(ebp + (-0x50)); /* 0x3100B5C5: mov ecx, dword ptr [ebp - 0x50] */
  12325     /* cmp ecx, esi */ /* 0x3100B5C8: cmp ecx, esi */
  12326     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(esi);
  12327     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12328     _flag_k = FK_CMP;
  12329     MEM32(ebp + (-0x2C)) = esi; /* 0x3100B5CA: mov dword ptr [ebp - 0x2c], esi */
  12330     MEM32(ebp + (-0x28)) = esi; /* 0x3100B5CD: mov dword ptr [ebp - 0x28], esi */
  12331     MEM32(ebp + (-0x24)) = esi; /* 0x3100B5D0: mov dword ptr [ebp - 0x24], esi */
  12332     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B604; /* 0x3100B5D3: je 0x3100b604 */
  12333 L_3100B5D5:
  12334     SET_LO8(eax, MEM8(ecx + (-0x1))); /* 0x3100B5D5: mov al, byte ptr [ecx - 1] */
  12335     /* test LO8(eax), LO8(eax) */ /* 0x3100B5D8: test al, al */
  12336     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  12337     _cf = 0;
  12338     _flag_k = FK_NARROW(FK_TEST, 24);
  12339     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B5FA; /* 0x3100B5DA: je 0x3100b5fa */
  12340 L_3100B5DC:
  12341     /* cmp LO8(eax), 0xFFu */ /* 0x3100B5DC: cmp al, 0xff */
  12342     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
  12343     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12344     _flag_k = FK_NARROW(FK_CMP, 24);
  12345     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B5FA; /* 0x3100B5DE: je 0x3100b5fa */
  12346 L_3100B5E0:
  12347     edi = POP32_VAL(esp); /* 0x3100B5E0: pop edi */
  12348     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
  12349     SET_LO8(eax, LO8(eax) - 1); /* 0x3100B5E1: dec al */
  12350     _flag_k = FK_NARROW(FK_DEC, 24);
  12351     esi = POP32_VAL(esp); /* 0x3100B5E3: pop esi */
  12352     MEM8(ecx + (-0x1)) = (uint8_t)(LO8(eax)); /* 0x3100B5E4: mov byte ptr [ecx - 1], al */
  12353     SET_LO8(eax, 1); /* 0x3100B5E7: mov al, 1 */
  12354     ebx = POP32_VAL(esp); /* 0x3100B5E9: pop ebx */
  12355     ecx = MEM32(ebp + (-0xC)); /* 0x3100B5EA: mov ecx, dword ptr [ebp - 0xc] */
  12356     MEM32(FS_BASE + (0)) = ecx; /* 0x3100B5ED: mov dword ptr fs:[0], ecx */
  12357     esp = ebp; /* 0x3100B5F4: mov esp, ebp */
  12358     ebp = POP32_VAL(esp); /* 0x3100B5F6: pop ebp */
  12359     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100B5F7: ret 4 */
  12360 L_3100B5FA:
  12361     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
  12362     ecx = ecx - 1; /* 0x3100B5FA: dec ecx */
  12363     _flag_k = FK_DEC;
  12364     PUSH32(esp, ecx); /* 0x3100B5FB: push ecx */
  12365     RECOMP_ICALL(0x31046858u); /* 0x3100B5FC: call 0x31046858 */ /* not lifted */
  12366     RECOMP_FLAGS_IN();
  12367     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12368     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12369     esp = esp + 4; /* 0x3100B601: add esp, 4 */
  12370     _flag_k = FK_ADD;
  12371 L_3100B604:
  12372     edi = POP32_VAL(esp); /* 0x3100B604: pop edi */
  12373     esi = POP32_VAL(esp); /* 0x3100B605: pop esi */
  12374     SET_LO8(eax, 1); /* 0x3100B606: mov al, 1 */
  12375     ebx = POP32_VAL(esp); /* 0x3100B608: pop ebx */
  12376     ecx = MEM32(ebp + (-0xC)); /* 0x3100B609: mov ecx, dword ptr [ebp - 0xc] */
  12377     MEM32(FS_BASE + (0)) = ecx; /* 0x3100B60C: mov dword ptr fs:[0], ecx */
  12378     esp = ebp; /* 0x3100B613: mov esp, ebp */
  12379     ebp = POP32_VAL(esp); /* 0x3100B615: pop ebp */
  12380     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100B616: ret 4 */
  12381 L_3100B619:
  12382     eax = MEM32(ebp + (-0x50)); /* 0x3100B619: mov eax, dword ptr [ebp - 0x50] */
  12383     /* test eax, eax */ /* 0x3100B61C: test eax, eax */
  12384     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  12385     _cf = 0;
  12386     _flag_k = FK_TEST;
  12387     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100B625; /* 0x3100B61E: jne 0x3100b625 */
  12388 L_3100B620:
  12389     eax = MEM32(0x310480EC); /* 0x3100B620: mov eax, dword ptr [0x310480ec] */
  12390 L_3100B625:
  12391     PUSH32(esp, eax); /* 0x3100B625: push eax */
  12392     ecx = ebp + (-0x21C); /* 0x3100B626: lea ecx, [ebp - 0x21c] */
  12393     PUSH32(esp, 0x3105220Cu); /* 0x3100B62C: push 0x3105220c */
  12394     PUSH32(esp, ecx); /* 0x3100B631: push ecx */
  12395     RECOMP_ICALL(MEM32(0x31048208)); /* 0x3100B632: call dword ptr [0x31048208] */
  12396     RECOMP_FLAGS_IN();
  12397     edx = ebp + (-0x21C); /* 0x3100B638: lea edx, [ebp - 0x21c] */
  12398     PUSH32(esp, 0); /* 0x3100B63E: push 0 */
  12399     PUSH32(esp, edx); /* 0x3100B640: push edx */
  12400     RECOMP_ICALL(0x310013E0u); /* 0x3100B641: call 0x310013e0 */ /* not lifted */
  12401     RECOMP_FLAGS_IN();
  12402     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x14u);
  12403     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12404     esp = esp + 0x14u; /* 0x3100B646: add esp, 0x14 */
  12405     _flag_k = FK_ADD;
  12406 L_3100B649:
  12407     PUSH32(esp, 1); /* 0x3100B649: push 1 */
  12408     ecx = ebp + (-0x54); /* 0x3100B64B: lea ecx, [ebp - 0x54] */
  12409     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100B64E: mov dword ptr [ebp - 4], 0xffffffff */
  12410     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100B655: call dword ptr [0x310480d4] */
  12411     RECOMP_FLAGS_IN();
  12412     ecx = MEM32(ebp + (-0xC)); /* 0x3100B65B: mov ecx, dword ptr [ebp - 0xc] */
  12413     edi = POP32_VAL(esp); /* 0x3100B65E: pop edi */
  12414     esi = POP32_VAL(esp); /* 0x3100B65F: pop esi */
  12415     _flag_a = (uint32_t)(0) << 24; _flag_b = (uint32_t)(0) << 24;
  12416     SET_LO8(eax, 0); /* 0x3100B660: xor al, al */
  12417     _cf = 0;
  12418     _flag_k = FK_NARROW(FK_TEST, 24);
  12419     ebx = POP32_VAL(esp); /* 0x3100B662: pop ebx */
  12420     MEM32(FS_BASE + (0)) = ecx; /* 0x3100B663: mov dword ptr fs:[0], ecx */
  12421     esp = ebp; /* 0x3100B66A: mov esp, ebp */
  12422     ebp = POP32_VAL(esp); /* 0x3100B66C: pop ebp */
  12423     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100B66D: ret 4 */
  12424     RECOMP_REGS_OUT();
  12425 }
  12426 
  12427 void sub_3100B670(void) {
  12428     int _fpu_cmp = 0;
  12429     uint32_t _cf = 0;
  12430     int _df = 1;
  12431     uint32_t _flag_k = FK_NONE;
  12432     uint32_t _flag_a = 0, _flag_b = 0;
  12433     uint32_t _itail_tgt = 0;
  12434     RECOMP_REGS_LOCALS
  12435     RECOMP_ENTER(0x3100B670u);
  12436 
  12437 L_3100B670:
  12438     PUSH32(esp, ebp); /* 0x3100B670: push ebp */
  12439     ebp = esp; /* 0x3100B671: mov ebp, esp */
  12440     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100B673: push -1 */
  12441     PUSH32(esp, 0x31047546u); /* 0x3100B675: push 0x31047546 */
  12442     eax = MEM32(FS_BASE + (0)); /* 0x3100B67A: mov eax, dword ptr fs:[0] */
  12443     PUSH32(esp, eax); /* 0x3100B680: push eax */
  12444     MEM32(FS_BASE + (0)) = esp; /* 0x3100B681: mov dword ptr fs:[0], esp */
  12445     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  12446     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12447     esp = esp - 8; /* 0x3100B688: sub esp, 8 */
  12448     _flag_k = FK_CMP;
  12449     PUSH32(esp, ebx); /* 0x3100B68B: push ebx */
  12450     PUSH32(esp, esi); /* 0x3100B68C: push esi */
  12451     esi = ecx; /* 0x3100B68D: mov esi, ecx */
  12452     PUSH32(esp, edi); /* 0x3100B68F: push edi */
  12453     MEM32(ebp + (-0x10)) = esi; /* 0x3100B690: mov dword ptr [ebp - 0x10], esi */
  12454     MEM32(esi) = 0x3104876Cu; /* 0x3100B693: mov dword ptr [esi], 0x3104876c */
  12455     MEM32(ebp + (-0x4)) = 1; /* 0x3100B699: mov dword ptr [ebp - 4], 1 */
  12456     RECOMP_ICALL(MEM32(0x310482F8)); /* 0x3100B6A0: call dword ptr [0x310482f8] */
  12457     RECOMP_FLAGS_IN();
  12458     eax = MEM32(esi + 0x34); /* 0x3100B6A6: mov eax, dword ptr [esi + 0x34] */
  12459     PUSH32(esp, eax); /* 0x3100B6A9: push eax */
  12460     MEM32(ebp + (-0x10)) = eax; /* 0x3100B6AA: mov dword ptr [ebp - 0x10], eax */
  12461     RECOMP_ICALL(0x31046858u); /* 0x3100B6AD: call 0x31046858 */ /* not lifted */
  12462     RECOMP_FLAGS_IN();
  12463     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  12464     ebx = 0; /* 0x3100B6B2: xor ebx, ebx */
  12465     _cf = 0;
  12466     _flag_k = FK_TEST;
  12467     MEM32(esi + 0x34) = ebx; /* 0x3100B6B4: mov dword ptr [esi + 0x34], ebx */
  12468     MEM32(esi + 0x38) = ebx; /* 0x3100B6B7: mov dword ptr [esi + 0x38], ebx */
  12469     MEM32(esi + 0x3C) = ebx; /* 0x3100B6BA: mov dword ptr [esi + 0x3c], ebx */
  12470     edi = MEM32(esi + 0x8); /* 0x3100B6BD: mov edi, dword ptr [esi + 8] */
  12471     ecx = MEM32(esi + 0x14); /* 0x3100B6C0: mov ecx, dword ptr [esi + 0x14] */
  12472     eax = MEM32(edi); /* 0x3100B6C3: mov eax, dword ptr [edi] */
  12473     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(4);
  12474     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12475     esi = esi + 4; /* 0x3100B6C5: add esi, 4 */
  12476     _flag_k = FK_ADD;
  12477     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12478     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12479     esp = esp + 4; /* 0x3100B6C8: add esp, 4 */
  12480     _flag_k = FK_ADD;
  12481     /* cmp ecx, ebx */ /* 0x3100B6CB: cmp ecx, ebx */
  12482     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
  12483     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12484     _flag_k = FK_CMP;
  12485     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100B6CD: mov dword ptr [ebp - 4], 0xffffffff */
  12486     MEM32(ebp + (-0x10)) = eax; /* 0x3100B6D4: mov dword ptr [ebp - 0x10], eax */
  12487     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B707; /* 0x3100B6D7: je 0x3100b707 */
  12488 L_3100B6D9:
  12489     ecx = eax; /* 0x3100B6D9: mov ecx, eax */
  12490     /* cmp eax, ecx */ /* 0x3100B6DB: cmp eax, ecx */
  12491     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  12492     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12493     _flag_k = FK_CMP;
  12494     if (CMP_NE(_flag_a, _flag_b)) goto L_3100B707; /* 0x3100B6DD: jne 0x3100b707 */
  12495 L_3100B6DF:
  12496     /* cmp edi, edi */ /* 0x3100B6DF: cmp edi, edi */
  12497     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
  12498     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12499     _flag_k = FK_CMP;
  12500     if (CMP_NE(_flag_a, _flag_b)) goto L_3100B707; /* 0x3100B6E1: jne 0x3100b707 */
  12501 L_3100B6E3:
  12502     eax = MEM32(edi + 0x4); /* 0x3100B6E3: mov eax, dword ptr [edi + 4] */
  12503     PUSH32(esp, eax); /* 0x3100B6E6: push eax */
  12504     ecx = esi; /* 0x3100B6E7: mov ecx, esi */
  12505     RECOMP_ICALL(0x3100E8B0u); /* 0x3100B6E9: call 0x3100e8b0 */ /* not lifted */
  12506     RECOMP_FLAGS_IN();
  12507     ecx = MEM32(esi + 0x4); /* 0x3100B6EE: mov ecx, dword ptr [esi + 4] */
  12508     edx = MEM32(esi + 0x8); /* 0x3100B6F1: mov edx, dword ptr [esi + 8] */
  12509     MEM32(ecx + 0x4) = edx; /* 0x3100B6F4: mov dword ptr [ecx + 4], edx */
  12510     eax = MEM32(esi + 0x4); /* 0x3100B6F7: mov eax, dword ptr [esi + 4] */
  12511     MEM32(esi + 0x10) = ebx; /* 0x3100B6FA: mov dword ptr [esi + 0x10], ebx */
  12512     MEM32(eax) = eax; /* 0x3100B6FD: mov dword ptr [eax], eax */
  12513     eax = MEM32(esi + 0x4); /* 0x3100B6FF: mov eax, dword ptr [esi + 4] */
  12514     MEM32(eax + 0x8) = eax; /* 0x3100B702: mov dword ptr [eax + 8], eax */
  12515     goto L_3100B72A; /* 0x3100B705: jmp 0x3100b72a */
  12516 L_3100B707:
  12517     /* cmp eax, edi */ /* 0x3100B707: cmp eax, edi */
  12518     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
  12519     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12520     _flag_k = FK_CMP;
  12521     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B72A; /* 0x3100B709: je 0x3100b72a */
  12522 L_3100B70B:
  12523     ecx = ebp + (-0x10); /* 0x3100B70B: lea ecx, [ebp - 0x10] */
  12524     ebx = eax; /* 0x3100B70E: mov ebx, eax */
  12525     RECOMP_ICALL(0x3100EC20u); /* 0x3100B710: call 0x3100ec20 */ /* not lifted */
  12526     RECOMP_FLAGS_IN();
  12527     PUSH32(esp, ebx); /* 0x3100B715: push ebx */
  12528     eax = ebp + (-0x14); /* 0x3100B716: lea eax, [ebp - 0x14] */
  12529     PUSH32(esp, eax); /* 0x3100B719: push eax */
  12530     ecx = esi; /* 0x3100B71A: mov ecx, esi */
  12531     RECOMP_ICALL(0x3100E4E0u); /* 0x3100B71C: call 0x3100e4e0 */ /* not lifted */
  12532     RECOMP_FLAGS_IN();
  12533     eax = MEM32(ebp + (-0x10)); /* 0x3100B721: mov eax, dword ptr [ebp - 0x10] */
  12534     /* cmp eax, edi */ /* 0x3100B724: cmp eax, edi */
  12535     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
  12536     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12537     _flag_k = FK_CMP;
  12538     RECOMP_BACKEDGE();
  12539     if (CMP_NE(_flag_a, _flag_b)) goto L_3100B70B; /* 0x3100B726: jne 0x3100b70b */
  12540 L_3100B728:
  12541     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  12542     ebx = 0; /* 0x3100B728: xor ebx, ebx */
  12543     _cf = 0;
  12544     _flag_k = FK_TEST;
  12545 L_3100B72A:
  12546     ecx = MEM32(esi + 0x4); /* 0x3100B72A: mov ecx, dword ptr [esi + 4] */
  12547     PUSH32(esp, ecx); /* 0x3100B72D: push ecx */
  12548     RECOMP_ICALL(0x31046858u); /* 0x3100B72E: call 0x31046858 */ /* not lifted */
  12549     RECOMP_FLAGS_IN();
  12550     edx = MEM32(esi + 0x8); /* 0x3100B733: mov edx, dword ptr [esi + 8] */
  12551     PUSH32(esp, edx); /* 0x3100B736: push edx */
  12552     MEM32(esi + 0x4) = ebx; /* 0x3100B737: mov dword ptr [esi + 4], ebx */
  12553     MEM32(esi + 0x10) = ebx; /* 0x3100B73A: mov dword ptr [esi + 0x10], ebx */
  12554     RECOMP_ICALL(0x31046858u); /* 0x3100B73D: call 0x31046858 */ /* not lifted */
  12555     RECOMP_FLAGS_IN();
  12556     ecx = MEM32(ebp + (-0xC)); /* 0x3100B742: mov ecx, dword ptr [ebp - 0xc] */
  12557     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  12558     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12559     esp = esp + 8; /* 0x3100B745: add esp, 8 */
  12560     _flag_k = FK_ADD;
  12561     MEM32(esi + 0x8) = ebx; /* 0x3100B748: mov dword ptr [esi + 8], ebx */
  12562     edi = POP32_VAL(esp); /* 0x3100B74B: pop edi */
  12563     esi = POP32_VAL(esp); /* 0x3100B74C: pop esi */
  12564     ebx = POP32_VAL(esp); /* 0x3100B74D: pop ebx */
  12565     MEM32(FS_BASE + (0)) = ecx; /* 0x3100B74E: mov dword ptr fs:[0], ecx */
  12566     esp = ebp; /* 0x3100B755: mov esp, ebp */
  12567     ebp = POP32_VAL(esp); /* 0x3100B757: pop ebp */
  12568     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100B758: ret  */
  12569     RECOMP_REGS_OUT();
  12570 }
  12571 
  12572 void sub_3100B72A(void) {
  12573     int _fpu_cmp = 0;
  12574     uint32_t _cf = 0;
  12575     int _df = 1;
  12576     uint32_t _flag_k = FK_NONE;
  12577     uint32_t _flag_a = 0, _flag_b = 0;
  12578     uint32_t _itail_tgt = 0;
  12579     RECOMP_REGS_LOCALS
  12580     RECOMP_ENTER(0x3100B72Au);
  12581 
  12582 L_3100B72A:
  12583     ecx = MEM32(esi + 0x4); /* 0x3100B72A: mov ecx, dword ptr [esi + 4] */
  12584     PUSH32(esp, ecx); /* 0x3100B72D: push ecx */
  12585     RECOMP_ICALL(0x31046858u); /* 0x3100B72E: call 0x31046858 */ /* not lifted */
  12586     RECOMP_FLAGS_IN();
  12587     edx = MEM32(esi + 0x8); /* 0x3100B733: mov edx, dword ptr [esi + 8] */
  12588     PUSH32(esp, edx); /* 0x3100B736: push edx */
  12589     MEM32(esi + 0x4) = ebx; /* 0x3100B737: mov dword ptr [esi + 4], ebx */
  12590     MEM32(esi + 0x10) = ebx; /* 0x3100B73A: mov dword ptr [esi + 0x10], ebx */
  12591     RECOMP_ICALL(0x31046858u); /* 0x3100B73D: call 0x31046858 */ /* not lifted */
  12592     RECOMP_FLAGS_IN();
  12593     ecx = MEM32(ebp + (-0xC)); /* 0x3100B742: mov ecx, dword ptr [ebp - 0xc] */
  12594     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  12595     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12596     esp = esp + 8; /* 0x3100B745: add esp, 8 */
  12597     _flag_k = FK_ADD;
  12598     MEM32(esi + 0x8) = ebx; /* 0x3100B748: mov dword ptr [esi + 8], ebx */
  12599     edi = POP32_VAL(esp); /* 0x3100B74B: pop edi */
  12600     esi = POP32_VAL(esp); /* 0x3100B74C: pop esi */
  12601     ebx = POP32_VAL(esp); /* 0x3100B74D: pop ebx */
  12602     MEM32(FS_BASE + (0)) = ecx; /* 0x3100B74E: mov dword ptr fs:[0], ecx */
  12603     esp = ebp; /* 0x3100B755: mov esp, ebp */
  12604     ebp = POP32_VAL(esp); /* 0x3100B757: pop ebp */
  12605     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100B758: ret  */
  12606     RECOMP_REGS_OUT();
  12607 }
  12608 
  12609 void sub_3100B760(void) {
  12610     int _fpu_cmp = 0;
  12611     uint32_t _cf = 0;
  12612     int _df = 1;
  12613     uint32_t _flag_k = FK_NONE;
  12614     uint32_t _flag_a = 0, _flag_b = 0;
  12615     uint32_t _itail_tgt = 0;
  12616     RECOMP_REGS_LOCALS
  12617     RECOMP_ENTER(0x3100B760u);
  12618 
  12619 L_3100B760:
  12620     PUSH32(esp, ebp); /* 0x3100B760: push ebp */
  12621     ebp = esp; /* 0x3100B761: mov ebp, esp */
  12622     PUSH32(esp, esi); /* 0x3100B763: push esi */
  12623     esi = ecx; /* 0x3100B764: mov esi, ecx */
  12624     RECOMP_ICALL(0x3100B670u); /* 0x3100B766: call 0x3100b670 */ /* not lifted */
  12625     RECOMP_FLAGS_IN();
  12626     /* test MEM8(ebp + 0x8), 1 */ /* 0x3100B76B: test byte ptr [ebp + 8], 1 */
  12627     _flag_a = (uint32_t)(MEM8(ebp + 0x8)) << 24; _flag_b = (uint32_t)(1) << 24;
  12628     _cf = 0;
  12629     _flag_k = FK_NARROW(FK_TEST, 24);
  12630     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B77A; /* 0x3100B76F: je 0x3100b77a */
  12631 L_3100B771:
  12632     PUSH32(esp, esi); /* 0x3100B771: push esi */
  12633     RECOMP_ICALL(0x31046858u); /* 0x3100B772: call 0x31046858 */ /* not lifted */
  12634     RECOMP_FLAGS_IN();
  12635     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12636     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12637     esp = esp + 4; /* 0x3100B777: add esp, 4 */
  12638     _flag_k = FK_ADD;
  12639 L_3100B77A:
  12640     eax = esi; /* 0x3100B77A: mov eax, esi */
  12641     esi = POP32_VAL(esp); /* 0x3100B77C: pop esi */
  12642     ebp = POP32_VAL(esp); /* 0x3100B77D: pop ebp */
  12643     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100B77E: ret 4 */
  12644     RECOMP_REGS_OUT();
  12645 }
  12646 
  12647 void sub_3100B790(void) {
  12648     int _fpu_cmp = 0;
  12649     uint32_t _cf = 0;
  12650     int _df = 1;
  12651     uint32_t _flag_k = FK_NONE;
  12652     uint32_t _flag_a = 0, _flag_b = 0;
  12653     uint32_t _itail_tgt = 0;
  12654     RECOMP_REGS_LOCALS
  12655     RECOMP_ENTER(0x3100B790u);
  12656 
  12657 L_3100B790:
  12658     PUSH32(esp, ebp); /* 0x3100B790: push ebp */
  12659     ebp = esp; /* 0x3100B791: mov ebp, esp */
  12660     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  12661     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12662     esp = esp - 8; /* 0x3100B793: sub esp, 8 */
  12663     _flag_k = FK_CMP;
  12664     PUSH32(esp, ebx); /* 0x3100B796: push ebx */
  12665     PUSH32(esp, esi); /* 0x3100B797: push esi */
  12666     esi = ecx; /* 0x3100B798: mov esi, ecx */
  12667     ecx = MEM32(esi + 0x10); /* 0x3100B79A: mov ecx, dword ptr [esi + 0x10] */
  12668     /* test ecx, ecx */ /* 0x3100B79D: test ecx, ecx */
  12669     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ecx);
  12670     _cf = 0;
  12671     _flag_k = FK_TEST;
  12672     PUSH32(esp, edi); /* 0x3100B79F: push edi */
  12673     edi = MEM32(esi + 0x4); /* 0x3100B7A0: mov edi, dword ptr [esi + 4] */
  12674     eax = MEM32(edi); /* 0x3100B7A3: mov eax, dword ptr [edi] */
  12675     MEM32(ebp + (-0x4)) = eax; /* 0x3100B7A5: mov dword ptr [ebp - 4], eax */
  12676     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B80F; /* 0x3100B7A8: je 0x3100b80f */
  12677 L_3100B7AA:
  12678     ecx = eax; /* 0x3100B7AA: mov ecx, eax */
  12679     /* cmp eax, ecx */ /* 0x3100B7AC: cmp eax, ecx */
  12680     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  12681     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12682     _flag_k = FK_CMP;
  12683     if (CMP_NE(_flag_a, _flag_b)) goto L_3100B80F; /* 0x3100B7AE: jne 0x3100b80f */
  12684 L_3100B7B0:
  12685     /* cmp edi, edi */ /* 0x3100B7B0: cmp edi, edi */
  12686     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(edi);
  12687     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12688     _flag_k = FK_CMP;
  12689     if (CMP_NE(_flag_a, _flag_b)) goto L_3100B80F; /* 0x3100B7B2: jne 0x3100b80f */
  12690 L_3100B7B4:
  12691     ebx = MEM32(edi + 0x4); /* 0x3100B7B4: mov ebx, dword ptr [edi + 4] */
  12692     /* cmp ebx, MEM32(esi + 0x8) */ /* 0x3100B7B7: cmp ebx, dword ptr [esi + 8] */
  12693     _flag_a = (uint32_t)(ebx); _flag_b = (uint32_t)(MEM32(esi + 0x8));
  12694     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12695     _flag_k = FK_CMP;
  12696     edi = ebx; /* 0x3100B7BA: mov edi, ebx */
  12697     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B7E7; /* 0x3100B7BC: je 0x3100b7e7 */
  12698 L_3100B7BE:
  12699     eax = MEM32(edi + 0x8); /* 0x3100B7BE: mov eax, dword ptr [edi + 8] */
  12700     PUSH32(esp, eax); /* 0x3100B7C1: push eax */
  12701     ecx = esi; /* 0x3100B7C2: mov ecx, esi */
  12702     RECOMP_ICALL(0x3100E8B0u); /* 0x3100B7C4: call 0x3100e8b0 */ /* not lifted */
  12703     RECOMP_FLAGS_IN();
  12704     edi = MEM32(edi); /* 0x3100B7C9: mov edi, dword ptr [edi] */
  12705     PUSH32(esp, 0); /* 0x3100B7CB: push 0 */
  12706     ecx = ebx + 0xC; /* 0x3100B7CD: lea ecx, [ebx + 0xc] */
  12707     RECOMP_ICALL(0x3100EE50u); /* 0x3100B7D0: call 0x3100ee50 */ /* not lifted */
  12708     RECOMP_FLAGS_IN();
  12709     PUSH32(esp, ebx); /* 0x3100B7D5: push ebx */
  12710     RECOMP_ICALL(0x31046858u); /* 0x3100B7D6: call 0x31046858 */ /* not lifted */
  12711     RECOMP_FLAGS_IN();
  12712     eax = MEM32(esi + 0x8); /* 0x3100B7DB: mov eax, dword ptr [esi + 8] */
  12713     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  12714     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12715     esp = esp + 4; /* 0x3100B7DE: add esp, 4 */
  12716     _flag_k = FK_ADD;
  12717     /* cmp edi, eax */ /* 0x3100B7E1: cmp edi, eax */
  12718     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(eax);
  12719     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12720     _flag_k = FK_CMP;
  12721     ebx = edi; /* 0x3100B7E3: mov ebx, edi */
  12722     RECOMP_BACKEDGE();
  12723     if (CMP_NE(_flag_a, _flag_b)) goto L_3100B7BE; /* 0x3100B7E5: jne 0x3100b7be */
  12724 L_3100B7E7:
  12725     ecx = MEM32(esi + 0x4); /* 0x3100B7E7: mov ecx, dword ptr [esi + 4] */
  12726     edx = MEM32(esi + 0x8); /* 0x3100B7EA: mov edx, dword ptr [esi + 8] */
  12727     MEM32(ecx + 0x4) = edx; /* 0x3100B7ED: mov dword ptr [ecx + 4], edx */
  12728     eax = MEM32(esi + 0x4); /* 0x3100B7F0: mov eax, dword ptr [esi + 4] */
  12729     MEM32(esi + 0x10) = 0; /* 0x3100B7F3: mov dword ptr [esi + 0x10], 0 */
  12730     MEM32(eax) = eax; /* 0x3100B7FA: mov dword ptr [eax], eax */
  12731     eax = MEM32(esi + 0x4); /* 0x3100B7FC: mov eax, dword ptr [esi + 4] */
  12732     MEM32(eax + 0x8) = eax; /* 0x3100B7FF: mov dword ptr [eax + 8], eax */
  12733     eax = ebp + (-0x8); /* 0x3100B802: lea eax, [ebp - 8] */
  12734     PUSH32(esp, eax); /* 0x3100B805: push eax */
  12735     ecx = esi; /* 0x3100B806: mov ecx, esi */
  12736     RECOMP_ICALL(0x3100E400u); /* 0x3100B808: call 0x3100e400 */ /* not lifted */
  12737     RECOMP_FLAGS_IN();
  12738     goto L_3100B830; /* 0x3100B80D: jmp 0x3100b830 */
  12739 L_3100B80F:
  12740     /* cmp eax, edi */ /* 0x3100B80F: cmp eax, edi */
  12741     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
  12742     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12743     _flag_k = FK_CMP;
  12744     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100B830; /* 0x3100B811: je 0x3100b830 */
  12745 L_3100B813:
  12746     ecx = ebp + (-0x4); /* 0x3100B813: lea ecx, [ebp - 4] */
  12747     ebx = eax; /* 0x3100B816: mov ebx, eax */
  12748     RECOMP_ICALL(0x3100EC20u); /* 0x3100B818: call 0x3100ec20 */ /* not lifted */
  12749     RECOMP_FLAGS_IN();
  12750     PUSH32(esp, ebx); /* 0x3100B81D: push ebx */
  12751     ecx = ebp + (-0x8); /* 0x3100B81E: lea ecx, [ebp - 8] */
  12752     PUSH32(esp, ecx); /* 0x3100B821: push ecx */
  12753     ecx = esi; /* 0x3100B822: mov ecx, esi */
  12754     RECOMP_ICALL(0x3100E4E0u); /* 0x3100B824: call 0x3100e4e0 */ /* not lifted */
  12755     RECOMP_FLAGS_IN();
  12756     eax = MEM32(ebp + (-0x4)); /* 0x3100B829: mov eax, dword ptr [ebp - 4] */
  12757     /* cmp eax, edi */ /* 0x3100B82C: cmp eax, edi */
  12758     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
  12759     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12760     _flag_k = FK_CMP;
  12761     RECOMP_BACKEDGE();
  12762     if (CMP_NE(_flag_a, _flag_b)) goto L_3100B813; /* 0x3100B82E: jne 0x3100b813 */
  12763 L_3100B830:
  12764     edx = MEM32(esi + 0x4); /* 0x3100B830: mov edx, dword ptr [esi + 4] */
  12765     PUSH32(esp, edx); /* 0x3100B833: push edx */
  12766     RECOMP_ICALL(0x31046858u); /* 0x3100B834: call 0x31046858 */ /* not lifted */
  12767     RECOMP_FLAGS_IN();
  12768     eax = MEM32(esi + 0x8); /* 0x3100B839: mov eax, dword ptr [esi + 8] */
  12769     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  12770     edi = 0; /* 0x3100B83C: xor edi, edi */
  12771     _cf = 0;
  12772     _flag_k = FK_TEST;
  12773     PUSH32(esp, eax); /* 0x3100B83E: push eax */
  12774     MEM32(esi + 0x4) = edi; /* 0x3100B83F: mov dword ptr [esi + 4], edi */
  12775     MEM32(esi + 0x10) = edi; /* 0x3100B842: mov dword ptr [esi + 0x10], edi */
  12776     RECOMP_ICALL(0x31046858u); /* 0x3100B845: call 0x31046858 */ /* not lifted */
  12777     RECOMP_FLAGS_IN();
  12778     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  12779     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12780     esp = esp + 8; /* 0x3100B84A: add esp, 8 */
  12781     _flag_k = FK_ADD;
  12782     MEM32(esi + 0x8) = edi; /* 0x3100B84D: mov dword ptr [esi + 8], edi */
  12783     edi = POP32_VAL(esp); /* 0x3100B850: pop edi */
  12784     esi = POP32_VAL(esp); /* 0x3100B851: pop esi */
  12785     ebx = POP32_VAL(esp); /* 0x3100B852: pop ebx */
  12786     esp = ebp; /* 0x3100B853: mov esp, ebp */
  12787     ebp = POP32_VAL(esp); /* 0x3100B855: pop ebp */
  12788     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100B856: ret  */
  12789     RECOMP_REGS_OUT();
  12790 }
  12791 
  12792 void sub_3100B830(void) {
  12793     int _fpu_cmp = 0;
  12794     uint32_t _cf = 0;
  12795     int _df = 1;
  12796     uint32_t _flag_k = FK_NONE;
  12797     uint32_t _flag_a = 0, _flag_b = 0;
  12798     uint32_t _itail_tgt = 0;
  12799     RECOMP_REGS_LOCALS
  12800     RECOMP_ENTER(0x3100B830u);
  12801 
  12802 L_3100B830:
  12803     edx = MEM32(esi + 0x4); /* 0x3100B830: mov edx, dword ptr [esi + 4] */
  12804     PUSH32(esp, edx); /* 0x3100B833: push edx */
  12805     RECOMP_ICALL(0x31046858u); /* 0x3100B834: call 0x31046858 */ /* not lifted */
  12806     RECOMP_FLAGS_IN();
  12807     eax = MEM32(esi + 0x8); /* 0x3100B839: mov eax, dword ptr [esi + 8] */
  12808     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  12809     edi = 0; /* 0x3100B83C: xor edi, edi */
  12810     _cf = 0;
  12811     _flag_k = FK_TEST;
  12812     PUSH32(esp, eax); /* 0x3100B83E: push eax */
  12813     MEM32(esi + 0x4) = edi; /* 0x3100B83F: mov dword ptr [esi + 4], edi */
  12814     MEM32(esi + 0x10) = edi; /* 0x3100B842: mov dword ptr [esi + 0x10], edi */
  12815     RECOMP_ICALL(0x31046858u); /* 0x3100B845: call 0x31046858 */ /* not lifted */
  12816     RECOMP_FLAGS_IN();
  12817     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  12818     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12819     esp = esp + 8; /* 0x3100B84A: add esp, 8 */
  12820     _flag_k = FK_ADD;
  12821     MEM32(esi + 0x8) = edi; /* 0x3100B84D: mov dword ptr [esi + 8], edi */
  12822     edi = POP32_VAL(esp); /* 0x3100B850: pop edi */
  12823     esi = POP32_VAL(esp); /* 0x3100B851: pop esi */
  12824     ebx = POP32_VAL(esp); /* 0x3100B852: pop ebx */
  12825     esp = ebp; /* 0x3100B853: mov esp, ebp */
  12826     ebp = POP32_VAL(esp); /* 0x3100B855: pop ebp */
  12827     RECOMP_FLAGS_OUT(); esp += 4; { RECOMP_REGS_OUT(); return; } /* 0x3100B856: ret  */
  12828     RECOMP_REGS_OUT();
  12829 }
  12830 
  12831 void sub_3100B860(void) {
  12832     int _fpu_cmp = 0;
  12833     uint32_t _cf = 0;
  12834     int _df = 1;
  12835     uint32_t _flag_k = FK_NONE;
  12836     uint32_t _flag_a = 0, _flag_b = 0;
  12837     uint32_t _itail_tgt = 0;
  12838     RECOMP_REGS_LOCALS
  12839     RECOMP_ENTER(0x3100B860u);
  12840 
  12841 L_3100B860:
  12842     PUSH32(esp, ebp); /* 0x3100B860: push ebp */
  12843     ebp = esp; /* 0x3100B861: mov ebp, esp */
  12844     PUSH32(esp, esi); /* 0x3100B863: push esi */
  12845     PUSH32(esp, edi); /* 0x3100B864: push edi */
  12846     PUSH32(esp, 0); /* 0x3100B865: push 0 */
  12847     PUSH32(esp, 0x310522C0u); /* 0x3100B867: push 0x310522c0 */
  12848     esi = ecx; /* 0x3100B86C: mov esi, ecx */
  12849     RECOMP_ICALL(0x310013E0u); /* 0x3100B86E: call 0x310013e0 */ /* not lifted */
  12850     RECOMP_FLAGS_IN();
  12851     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  12852     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12853     esp = esp + 8; /* 0x3100B873: add esp, 8 */
  12854     _flag_k = FK_ADD;
  12855     edi = esi + (-0x30); /* 0x3100B876: lea edi, [esi - 0x30] */
  12856 L_3100B879:
  12857     ecx = esi; /* 0x3100B879: mov ecx, esi */
  12858     RECOMP_ICALL(0x31010C80u); /* 0x3100B87B: call 0x31010c80 */ /* not lifted */
  12859     RECOMP_FLAGS_IN();
  12860     PUSH32(esp, 0); /* 0x3100B880: push 0 */
  12861     ecx = edi; /* 0x3100B882: mov ecx, edi */
  12862     RECOMP_ICALL(0x3100AFE0u); /* 0x3100B884: call 0x3100afe0 */ /* not lifted */
  12863     RECOMP_FLAGS_IN();
  12864     /* test LO8(eax), LO8(eax) */ /* 0x3100B889: test al, al */
  12865     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  12866     _cf = 0;
  12867     _flag_k = FK_NARROW(FK_TEST, 24);
  12868     RECOMP_BACKEDGE();
  12869     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B879; /* 0x3100B88B: je 0x3100b879 */
  12870 L_3100B88D:
  12871     PUSH32(esp, 0); /* 0x3100B88D: push 0 */
  12872     PUSH32(esp, 0x310522B8u); /* 0x3100B88F: push 0x310522b8 */
  12873     RECOMP_ICALL(0x310013E0u); /* 0x3100B894: call 0x310013e0 */ /* not lifted */
  12874     RECOMP_FLAGS_IN();
  12875     SET_LO8(ecx, MEM8(ebp + 0x8)); /* 0x3100B899: mov cl, byte ptr [ebp + 8] */
  12876     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  12877     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  12878     esp = esp + 8; /* 0x3100B89C: add esp, 8 */
  12879     _flag_k = FK_ADD;
  12880     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  12881     eax = 0; /* 0x3100B89F: xor eax, eax */
  12882     _cf = 0;
  12883     _flag_k = FK_TEST;
  12884     /* test LO8(ecx), LO8(ecx) */ /* 0x3100B8A1: test cl, cl */
  12885     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24;
  12886     _cf = 0;
  12887     _flag_k = FK_NARROW(FK_TEST, 24);
  12888     edi = POP32_VAL(esp); /* 0x3100B8A3: pop edi */
  12889     SET_LO8(eax, (TEST_Z(_flag_a, _flag_b)) ? 1 : 0); /* 0x3100B8A4: sete al */
  12890     esi = POP32_VAL(esp); /* 0x3100B8A7: pop esi */
  12891     ebp = POP32_VAL(esp); /* 0x3100B8A8: pop ebp */
  12892     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100B8A9: ret 4 */
  12893     RECOMP_REGS_OUT();
  12894 }
  12895 
  12896 void sub_3100B8B0(void) {
  12897     int _fpu_cmp = 0;
  12898     uint32_t _cf = 0;
  12899     int _df = 1;
  12900     uint32_t _flag_k = FK_NONE;
  12901     uint32_t _flag_a = 0, _flag_b = 0;
  12902     uint32_t _itail_tgt = 0;
  12903     RECOMP_REGS_LOCALS
  12904     RECOMP_ENTER(0x3100B8B0u);
  12905 
  12906 L_3100B8B0:
  12907     PUSH32(esp, ebp); /* 0x3100B8B0: push ebp */
  12908     ebp = esp; /* 0x3100B8B1: mov ebp, esp */
  12909     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100B8B3: push -1 */
  12910     PUSH32(esp, 0x3104758Fu); /* 0x3100B8B5: push 0x3104758f */
  12911     eax = MEM32(FS_BASE + (0)); /* 0x3100B8BA: mov eax, dword ptr fs:[0] */
  12912     PUSH32(esp, eax); /* 0x3100B8C0: push eax */
  12913     MEM32(FS_BASE + (0)) = esp; /* 0x3100B8C1: mov dword ptr fs:[0], esp */
  12914     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x54u);
  12915     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12916     esp = esp - 0x54u; /* 0x3100B8C8: sub esp, 0x54 */
  12917     _flag_k = FK_CMP;
  12918     PUSH32(esp, ebx); /* 0x3100B8CB: push ebx */
  12919     PUSH32(esp, esi); /* 0x3100B8CC: push esi */
  12920     PUSH32(esp, edi); /* 0x3100B8CD: push edi */
  12921     edi = ecx; /* 0x3100B8CE: mov edi, ecx */
  12922     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100B8D0: push -1 */
  12923     ecx = ebp + (-0x60); /* 0x3100B8D2: lea ecx, [ebp - 0x60] */
  12924     MEM32(ebp + (-0x20)) = 0; /* 0x3100B8D5: mov dword ptr [ebp - 0x20], 0 */
  12925     RECOMP_ICALL(MEM32(0x310482C8)); /* 0x3100B8DC: call dword ptr [0x310482c8] */
  12926     RECOMP_FLAGS_IN();
  12927     ecx = edi; /* 0x3100B8E2: mov ecx, edi */
  12928     MEM32(ebp + (-0x4)) = 1; /* 0x3100B8E4: mov dword ptr [ebp - 4], 1 */
  12929     RECOMP_ICALL(0x310013E0u); /* 0x3100B8EB: call 0x310013e0 */ /* not lifted */
  12930     RECOMP_FLAGS_IN();
  12931     ebx = MEM32(ebp + 0xC); /* 0x3100B8F0: mov ebx, dword ptr [ebp + 0xc] */
  12932     esi = edi + 0x30; /* 0x3100B8F3: lea esi, [edi + 0x30] */
  12933 L_3100B8F6:
  12934     PUSH32(esp, 0); /* 0x3100B8F6: push 0 */
  12935     PUSH32(esp, ebx); /* 0x3100B8F8: push ebx */
  12936     PUSH32(esp, 0x310522F4u); /* 0x3100B8F9: push 0x310522f4 */
  12937     ecx = esi; /* 0x3100B8FE: mov ecx, esi */
  12938     RECOMP_ICALL(0x31010D60u); /* 0x3100B900: call 0x31010d60 */ /* not lifted */
  12939     RECOMP_FLAGS_IN();
  12940     eax = ebp + (-0x60); /* 0x3100B905: lea eax, [ebp - 0x60] */
  12941     PUSH32(esp, eax); /* 0x3100B908: push eax */
  12942     ecx = esi; /* 0x3100B909: mov ecx, esi */
  12943     RECOMP_ICALL(0x31010F40u); /* 0x3100B90B: call 0x31010f40 */ /* not lifted */
  12944     RECOMP_FLAGS_IN();
  12945     /* test LO8(eax), LO8(eax) */ /* 0x3100B910: test al, al */
  12946     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  12947     _cf = 0;
  12948     _flag_k = FK_NARROW(FK_TEST, 24);
  12949     RECOMP_BACKEDGE();
  12950     if (TEST_Z(_flag_a, _flag_b)) goto L_3100B8F6; /* 0x3100B912: je 0x3100b8f6 */
  12951 L_3100B914:
  12952     ecx = edi; /* 0x3100B914: mov ecx, edi */
  12953     RECOMP_ICALL(0x310013E0u); /* 0x3100B916: call 0x310013e0 */ /* not lifted */
  12954     RECOMP_FLAGS_IN();
  12955     ecx = ebp + (-0x10); /* 0x3100B91B: lea ecx, [ebp - 0x10] */
  12956     MEM32(ebp + (-0x14)) = 1; /* 0x3100B91E: mov dword ptr [ebp - 0x14], 1 */
  12957     RECOMP_ICALL(0x310045B0u); /* 0x3100B925: call 0x310045b0 */ /* not lifted */
  12958     RECOMP_FLAGS_IN();
  12959     PUSH32(esp, 0); /* 0x3100B92A: push 0 */
  12960     ecx = ebp + (-0x14); /* 0x3100B92C: lea ecx, [ebp - 0x14] */
  12961     PUSH32(esp, ecx); /* 0x3100B92F: push ecx */
  12962     SET_LO8(ebx, 2); /* 0x3100B930: mov bl, 2 */
  12963     PUSH32(esp, 0x310522ECu); /* 0x3100B932: push 0x310522ec */
  12964     ecx = ebp + (-0x60); /* 0x3100B937: lea ecx, [ebp - 0x60] */
  12965     MEM8(ebp + (-0x4)) = (uint8_t)(LO8(ebx)); /* 0x3100B93A: mov byte ptr [ebp - 4], bl */
  12966     RECOMP_ICALL(MEM32(0x310482C0)); /* 0x3100B93D: call dword ptr [0x310482c0] */
  12967     RECOMP_FLAGS_IN();
  12968     /* cmp MEM16(ebp + (-0x14)), 0 */ /* 0x3100B943: cmp word ptr [ebp - 0x14], 0 */
  12969     _flag_a = (uint32_t)(MEM16(ebp + (-0x14))) << 16; _flag_b = (uint32_t)(0) << 16;
  12970     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  12971     _flag_k = FK_NARROW(FK_CMP, 16);
  12972     if (CMP_NE(_flag_a, _flag_b)) goto L_3100B98A; /* 0x3100B948: jne 0x3100b98a */
  12973 L_3100B94A:
  12974     PUSH32(esp, 0); /* 0x3100B94A: push 0 */
  12975     edx = ebp + 0xC; /* 0x3100B94C: lea edx, [ebp + 0xc] */
  12976     PUSH32(esp, edx); /* 0x3100B94F: push edx */
  12977     eax = ebp + (-0x18); /* 0x3100B950: lea eax, [ebp - 0x18] */
  12978     PUSH32(esp, eax); /* 0x3100B953: push eax */
  12979     PUSH32(esp, 0x31052244u); /* 0x3100B954: push 0x31052244 */
  12980     ecx = ebp + (-0x60); /* 0x3100B959: lea ecx, [ebp - 0x60] */
  12981     RECOMP_ICALL(MEM32(0x310482C4)); /* 0x3100B95C: call dword ptr [0x310482c4] */
  12982     RECOMP_FLAGS_IN();
  12983     ecx = MEM32(ebp + 0xC); /* 0x3100B962: mov ecx, dword ptr [ebp + 0xc] */
  12984     edx = MEM32(ebp + (-0x18)); /* 0x3100B965: mov edx, dword ptr [ebp - 0x18] */
  12985     PUSH32(esp, ecx); /* 0x3100B968: push ecx */
  12986     PUSH32(esp, edx); /* 0x3100B969: push edx */
  12987     ecx = ebp + (-0x1C); /* 0x3100B96A: lea ecx, [ebp - 0x1c] */
  12988     RECOMP_ICALL(0x31004670u); /* 0x3100B96D: call 0x31004670 */ /* not lifted */
  12989     RECOMP_FLAGS_IN();
  12990     PUSH32(esp, eax); /* 0x3100B972: push eax */
  12991     ecx = ebp + (-0x10); /* 0x3100B973: lea ecx, [ebp - 0x10] */
  12992     MEM8(ebp + (-0x4)) = (uint8_t)(3); /* 0x3100B976: mov byte ptr [ebp - 4], 3 */
  12993     RECOMP_ICALL(0x310046E0u); /* 0x3100B97A: call 0x310046e0 */ /* not lifted */
  12994     RECOMP_FLAGS_IN();
  12995     ecx = ebp + (-0x1C); /* 0x3100B97F: lea ecx, [ebp - 0x1c] */
  12996     MEM8(ebp + (-0x4)) = (uint8_t)(LO8(ebx)); /* 0x3100B982: mov byte ptr [ebp - 4], bl */
  12997     RECOMP_ICALL(0x31004760u); /* 0x3100B985: call 0x31004760 */ /* not lifted */
  12998     RECOMP_FLAGS_IN();
  12999 L_3100B98A:
  13000     eax = MEM32(ebp + (-0x10)); /* 0x3100B98A: mov eax, dword ptr [ebp - 0x10] */
  13001     MEM32(ebp + 0xC) = eax; /* 0x3100B98D: mov dword ptr [ebp + 0xc], eax */
  13002     ebx = MEM32(ebp + 0xC); /* 0x3100B990: mov ebx, dword ptr [ebp + 0xc] */
  13003     _flag_a = __atomic_fetch_add((uint32_t *)ADDR(ebx), 1, __ATOMIC_SEQ_CST); _flag_b = 1; /* 0x3100B993: lock inc dword ptr [ebx] */
  13004     _flag_k = FK_INC;
  13005     ecx = MEM32(ebp + (-0x10)); /* 0x3100B996: mov ecx, dword ptr [ebp - 0x10] */
  13006     edx = MEM32(ebp + 0x8); /* 0x3100B999: mov edx, dword ptr [ebp + 8] */
  13007     eax = 1; /* 0x3100B99C: mov eax, 1 */
  13008     MEM32(edx) = ecx; /* 0x3100B9A1: mov dword ptr [edx], ecx */
  13009     MEM32(ebp + (-0x20)) = eax; /* 0x3100B9A3: mov dword ptr [ebp - 0x20], eax */
  13010     ecx = ebp + (-0x10); /* 0x3100B9A6: lea ecx, [ebp - 0x10] */
  13011     MEM8(ebp + (-0x4)) = (uint8_t)(LO8(eax)); /* 0x3100B9A9: mov byte ptr [ebp - 4], al */
  13012     RECOMP_ICALL(0x31004760u); /* 0x3100B9AC: call 0x31004760 */ /* not lifted */
  13013     RECOMP_FLAGS_IN();
  13014     MEM32(ebp + (-0x60)) = 0x3104876Cu; /* 0x3100B9B1: mov dword ptr [ebp - 0x60], 0x3104876c */
  13015     ecx = ebp + (-0x60); /* 0x3100B9B8: lea ecx, [ebp - 0x60] */
  13016     MEM32(ebp + (-0x4)) = 5; /* 0x3100B9BB: mov dword ptr [ebp - 4], 5 */
  13017     RECOMP_ICALL(MEM32(0x310482F8)); /* 0x3100B9C2: call dword ptr [0x310482f8] */
  13018     RECOMP_FLAGS_IN();
  13019     eax = MEM32(ebp + (-0x2C)); /* 0x3100B9C8: mov eax, dword ptr [ebp - 0x2c] */
  13020     PUSH32(esp, eax); /* 0x3100B9CB: push eax */
  13021     RECOMP_ICALL(0x31046858u); /* 0x3100B9CC: call 0x31046858 */ /* not lifted */
  13022     RECOMP_FLAGS_IN();
  13023     eax = MEM32(ebp + (-0x58)); /* 0x3100B9D1: mov eax, dword ptr [ebp - 0x58] */
  13024     edx = MEM32(ebp + (-0x4C)); /* 0x3100B9D4: mov edx, dword ptr [ebp - 0x4c] */
  13025     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  13026     ebx = 0; /* 0x3100B9D7: xor ebx, ebx */
  13027     _cf = 0;
  13028     _flag_k = FK_TEST;
  13029     MEM32(ebp + (-0x2C)) = ebx; /* 0x3100B9D9: mov dword ptr [ebp - 0x2c], ebx */
  13030     MEM32(ebp + (-0x28)) = ebx; /* 0x3100B9DC: mov dword ptr [ebp - 0x28], ebx */
  13031     MEM32(ebp + (-0x24)) = ebx; /* 0x3100B9DF: mov dword ptr [ebp - 0x24], ebx */
  13032     ecx = MEM32(eax); /* 0x3100B9E2: mov ecx, dword ptr [eax] */
  13033     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  13034     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13035     esp = esp + 4; /* 0x3100B9E4: add esp, 4 */
  13036     _flag_k = FK_ADD;
  13037     /* cmp edx, ebx */ /* 0x3100B9E7: cmp edx, ebx */
  13038     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ebx);
  13039     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13040     _flag_k = FK_CMP;
  13041     MEM8(ebp + (-0x4)) = (uint8_t)(LO8(ebx)); /* 0x3100B9E9: mov byte ptr [ebp - 4], bl */
  13042     edi = eax; /* 0x3100B9EC: mov edi, eax */
  13043     MEM32(ebp + 0xC) = ecx; /* 0x3100B9EE: mov dword ptr [ebp + 0xc], ecx */
  13044     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100BA2A; /* 0x3100B9F1: je 0x3100ba2a */
  13045 L_3100B9F3:
  13046     edx = ecx; /* 0x3100B9F3: mov edx, ecx */
  13047     /* cmp ecx, edx */ /* 0x3100B9F5: cmp ecx, edx */
  13048     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
  13049     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13050     _flag_k = FK_CMP;
  13051     if (CMP_NE(_flag_a, _flag_b)) goto L_3100BA2A; /* 0x3100B9F7: jne 0x3100ba2a */
  13052 L_3100B9F9:
  13053     ecx = MEM32(eax + 0x4); /* 0x3100B9F9: mov ecx, dword ptr [eax + 4] */
  13054     PUSH32(esp, ecx); /* 0x3100B9FC: push ecx */
  13055     ecx = ebp + (-0x5C); /* 0x3100B9FD: lea ecx, [ebp - 0x5c] */
  13056     RECOMP_ICALL(0x3100E8B0u); /* 0x3100BA00: call 0x3100e8b0 */ /* not lifted */
  13057     RECOMP_FLAGS_IN();
  13058     eax = MEM32(ebp + (-0x54)); /* 0x3100BA05: mov eax, dword ptr [ebp - 0x54] */
  13059     edx = MEM32(ebp + (-0x58)); /* 0x3100BA08: mov edx, dword ptr [ebp - 0x58] */
  13060     MEM32(edx + 0x4) = eax; /* 0x3100BA0B: mov dword ptr [edx + 4], eax */
  13061     eax = MEM32(ebp + (-0x58)); /* 0x3100BA0E: mov eax, dword ptr [ebp - 0x58] */
  13062     MEM32(ebp + (-0x4C)) = ebx; /* 0x3100BA11: mov dword ptr [ebp - 0x4c], ebx */
  13063     MEM32(eax) = eax; /* 0x3100BA14: mov dword ptr [eax], eax */
  13064     eax = MEM32(ebp + (-0x58)); /* 0x3100BA16: mov eax, dword ptr [ebp - 0x58] */
  13065     ecx = ebp + (-0x1C); /* 0x3100BA19: lea ecx, [ebp - 0x1c] */
  13066     PUSH32(esp, ecx); /* 0x3100BA1C: push ecx */
  13067     ecx = ebp + (-0x5C); /* 0x3100BA1D: lea ecx, [ebp - 0x5c] */
  13068     MEM32(eax + 0x8) = eax; /* 0x3100BA20: mov dword ptr [eax + 8], eax */
  13069     RECOMP_ICALL(0x3100E400u); /* 0x3100BA23: call 0x3100e400 */ /* not lifted */
  13070     RECOMP_FLAGS_IN();
  13071     goto L_3100BA4C; /* 0x3100BA28: jmp 0x3100ba4c */
  13072 L_3100BA2A:
  13073     /* cmp ecx, eax */ /* 0x3100BA2A: cmp ecx, eax */
  13074     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
  13075     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13076     _flag_k = FK_CMP;
  13077     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100BA4F; /* 0x3100BA2C: je 0x3100ba4f */
  13078 L_3100BA2E:
  13079     esi = ecx; /* 0x3100BA2E: mov esi, ecx */
  13080     ecx = ebp + 0xC; /* 0x3100BA30: lea ecx, [ebp + 0xc] */
  13081     RECOMP_ICALL(0x3100EC20u); /* 0x3100BA33: call 0x3100ec20 */ /* not lifted */
  13082     RECOMP_FLAGS_IN();
  13083     PUSH32(esp, esi); /* 0x3100BA38: push esi */
  13084     edx = ebp + (-0x1C); /* 0x3100BA39: lea edx, [ebp - 0x1c] */
  13085     PUSH32(esp, edx); /* 0x3100BA3C: push edx */
  13086     ecx = ebp + (-0x5C); /* 0x3100BA3D: lea ecx, [ebp - 0x5c] */
  13087     RECOMP_ICALL(0x3100E4E0u); /* 0x3100BA40: call 0x3100e4e0 */ /* not lifted */
  13088     RECOMP_FLAGS_IN();
  13089     ecx = MEM32(ebp + 0xC); /* 0x3100BA45: mov ecx, dword ptr [ebp + 0xc] */
  13090     /* cmp ecx, edi */ /* 0x3100BA48: cmp ecx, edi */
  13091     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
  13092     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13093     _flag_k = FK_CMP;
  13094     RECOMP_BACKEDGE();
  13095     if (CMP_NE(_flag_a, _flag_b)) goto L_3100BA2E; /* 0x3100BA4A: jne 0x3100ba2e */
  13096 L_3100BA4C:
  13097     eax = MEM32(ebp + (-0x58)); /* 0x3100BA4C: mov eax, dword ptr [ebp - 0x58] */
  13098 L_3100BA4F:
  13099     PUSH32(esp, eax); /* 0x3100BA4F: push eax */
  13100     RECOMP_ICALL(0x31046858u); /* 0x3100BA50: call 0x31046858 */ /* not lifted */
  13101     RECOMP_FLAGS_IN();
  13102     eax = MEM32(ebp + (-0x54)); /* 0x3100BA55: mov eax, dword ptr [ebp - 0x54] */
  13103     PUSH32(esp, eax); /* 0x3100BA58: push eax */
  13104     MEM32(ebp + (-0x58)) = ebx; /* 0x3100BA59: mov dword ptr [ebp - 0x58], ebx */
  13105     MEM32(ebp + (-0x4C)) = ebx; /* 0x3100BA5C: mov dword ptr [ebp - 0x4c], ebx */
  13106     RECOMP_ICALL(0x31046858u); /* 0x3100BA5F: call 0x31046858 */ /* not lifted */
  13107     RECOMP_FLAGS_IN();
  13108     ecx = MEM32(ebp + (-0xC)); /* 0x3100BA64: mov ecx, dword ptr [ebp - 0xc] */
  13109     eax = MEM32(ebp + 0x8); /* 0x3100BA67: mov eax, dword ptr [ebp + 8] */
  13110     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  13111     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13112     esp = esp + 8; /* 0x3100BA6A: add esp, 8 */
  13113     _flag_k = FK_ADD;
  13114     edi = POP32_VAL(esp); /* 0x3100BA6D: pop edi */
  13115     esi = POP32_VAL(esp); /* 0x3100BA6E: pop esi */
  13116     ebx = POP32_VAL(esp); /* 0x3100BA6F: pop ebx */
  13117     MEM32(FS_BASE + (0)) = ecx; /* 0x3100BA70: mov dword ptr fs:[0], ecx */
  13118     esp = ebp; /* 0x3100BA77: mov esp, ebp */
  13119     ebp = POP32_VAL(esp); /* 0x3100BA79: pop ebp */
  13120     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100BA7A: ret 8 */
  13121     RECOMP_REGS_OUT();
  13122 }
  13123 
  13124 void sub_3100BA80(void) {
  13125     int _fpu_cmp = 0;
  13126     uint32_t _cf = 0;
  13127     int _df = 1;
  13128     uint32_t _flag_k = FK_NONE;
  13129     uint32_t _flag_a = 0, _flag_b = 0;
  13130     uint32_t _itail_tgt = 0;
  13131     RECOMP_REGS_LOCALS
  13132     RECOMP_ENTER(0x3100BA80u);
  13133 
  13134 L_3100BA80:
  13135     PUSH32(esp, ebp); /* 0x3100BA80: push ebp */
  13136     ebp = esp; /* 0x3100BA81: mov ebp, esp */
  13137     PUSH32(esp, esi); /* 0x3100BA83: push esi */
  13138     esi = ecx; /* 0x3100BA84: mov esi, ecx */
  13139     PUSH32(esp, 0); /* 0x3100BA86: push 0 */
  13140     RECOMP_ICALL(0x31009E30u); /* 0x3100BA88: call 0x31009e30 */ /* not lifted */
  13141     RECOMP_FLAGS_IN();
  13142     /* test LO8(eax), LO8(eax) */ /* 0x3100BA8D: test al, al */
  13143     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  13144     _cf = 0;
  13145     _flag_k = FK_NARROW(FK_TEST, 24);
  13146     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100BA9B; /* 0x3100BA8F: jne 0x3100ba9b */
  13147 L_3100BA91:
  13148     eax = 1; /* 0x3100BA91: mov eax, 1 */
  13149     esi = POP32_VAL(esp); /* 0x3100BA96: pop esi */
  13150     ebp = POP32_VAL(esp); /* 0x3100BA97: pop ebp */
  13151     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100BA98: ret 8 */
  13152 L_3100BA9B:
  13153     ecx = esi; /* 0x3100BA9B: mov ecx, esi */
  13154     RECOMP_ICALL(0x310013E0u); /* 0x3100BA9D: call 0x310013e0 */ /* not lifted */
  13155     RECOMP_FLAGS_IN();
  13156     eax = MEM32(ebp + 0xC); /* 0x3100BAA2: mov eax, dword ptr [ebp + 0xc] */
  13157     ecx = MEM32(ebp + 0x8); /* 0x3100BAA5: mov ecx, dword ptr [ebp + 8] */
  13158     PUSH32(esp, eax); /* 0x3100BAA8: push eax */
  13159     PUSH32(esp, ecx); /* 0x3100BAA9: push ecx */
  13160     PUSH32(esp, 0x310522FCu); /* 0x3100BAAA: push 0x310522fc */
  13161     ecx = esi + 0x30; /* 0x3100BAAF: lea ecx, [esi + 0x30] */
  13162     RECOMP_ICALL(0x31010D60u); /* 0x3100BAB2: call 0x31010d60 */ /* not lifted */
  13163     RECOMP_FLAGS_IN();
  13164     ecx = esi; /* 0x3100BAB7: mov ecx, esi */
  13165     RECOMP_ICALL(0x310013E0u); /* 0x3100BAB9: call 0x310013e0 */ /* not lifted */
  13166     RECOMP_FLAGS_IN();
  13167     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  13168     eax = 0; /* 0x3100BABE: xor eax, eax */
  13169     _cf = 0;
  13170     _flag_k = FK_TEST;
  13171     esi = POP32_VAL(esp); /* 0x3100BAC0: pop esi */
  13172     ebp = POP32_VAL(esp); /* 0x3100BAC1: pop ebp */
  13173     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100BAC2: ret 8 */
  13174     RECOMP_REGS_OUT();
  13175 }
  13176 
  13177 void sub_3100BAD0(void) {
  13178     int _fpu_cmp = 0;
  13179     uint32_t _cf = 0;
  13180     int _df = 1;
  13181     uint32_t _flag_k = FK_NONE;
  13182     uint32_t _flag_a = 0, _flag_b = 0;
  13183     uint32_t _itail_tgt = 0;
  13184     RECOMP_REGS_LOCALS
  13185     RECOMP_ENTER(0x3100BAD0u);
  13186 
  13187 L_3100BAD0:
  13188     PUSH32(esp, ebp); /* 0x3100BAD0: push ebp */
  13189     ebp = esp; /* 0x3100BAD1: mov ebp, esp */
  13190     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x5Cu);
  13191     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13192     esp = esp - 0x5Cu; /* 0x3100BAD3: sub esp, 0x5c */
  13193     _flag_k = FK_CMP;
  13194     edx = MEM32(ebp + 0x8); /* 0x3100BAD6: mov edx, dword ptr [ebp + 8] */
  13195     PUSH32(esp, ebx); /* 0x3100BAD9: push ebx */
  13196     ebx = MEM32(ecx + 0x18); /* 0x3100BADA: mov ebx, dword ptr [ecx + 0x18] */
  13197     PUSH32(esp, esi); /* 0x3100BADD: push esi */
  13198     PUSH32(esp, edi); /* 0x3100BADE: push edi */
  13199     edi = ecx + 0x14; /* 0x3100BADF: lea edi, [ecx + 0x14] */
  13200     MEM32(ebp + (-0xC)) = ecx; /* 0x3100BAE2: mov dword ptr [ebp - 0xc], ecx */
  13201     ecx = MEM32(edi + 0x8); /* 0x3100BAE5: mov ecx, dword ptr [edi + 8] */
  13202     MEM32(ebp + (-0x24)) = edx; /* 0x3100BAE8: mov dword ptr [ebp - 0x24], edx */
  13203     MEM32(ebp + (-0x20)) = 0; /* 0x3100BAEB: mov dword ptr [ebp - 0x20], 0 */
  13204     esi = MEM32(ebx + 0x4); /* 0x3100BAF2: mov esi, dword ptr [ebx + 4] */
  13205     /* cmp esi, ecx */ /* 0x3100BAF5: cmp esi, ecx */
  13206     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ecx);
  13207     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13208     _flag_k = FK_CMP;
  13209     SET_LO8(eax, 1); /* 0x3100BAF7: mov al, 1 */
  13210     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100BB12; /* 0x3100BAF9: je 0x3100bb12 */
  13211 L_3100BAFB:
  13212     /* cmp edx, MEM32(esi + 0xC) */ /* 0x3100BAFB: cmp edx, dword ptr [esi + 0xc] */
  13213     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0xC));
  13214     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13215     _flag_k = FK_CMP;
  13216     SET_LO8(eax, (CMP_B(_flag_a, _flag_b)) ? 1 : 0); /* 0x3100BAFE: setb al */
  13217     /* test LO8(eax), LO8(eax) */ /* 0x3100BB01: test al, al */
  13218     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  13219     _cf = 0;
  13220     _flag_k = FK_NARROW(FK_TEST, 24);
  13221     ebx = esi; /* 0x3100BB03: mov ebx, esi */
  13222     if (TEST_Z(_flag_a, _flag_b)) goto L_3100BB0B; /* 0x3100BB05: je 0x3100bb0b */
  13223 L_3100BB07:
  13224     esi = MEM32(esi); /* 0x3100BB07: mov esi, dword ptr [esi] */
  13225     goto L_3100BB0E; /* 0x3100BB09: jmp 0x3100bb0e */
  13226 L_3100BB0B:
  13227     esi = MEM32(esi + 0x8); /* 0x3100BB0B: mov esi, dword ptr [esi + 8] */
  13228 L_3100BB0E:
  13229     /* cmp esi, ecx */ /* 0x3100BB0E: cmp esi, ecx */
  13230     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ecx);
  13231     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13232     _flag_k = FK_CMP;
  13233     RECOMP_BACKEDGE();
  13234     if (CMP_NE(_flag_a, _flag_b)) goto L_3100BAFB; /* 0x3100BB10: jne 0x3100bafb */
  13235 L_3100BB12:
  13236     SET_LO8(ecx, MEM8(edi + 0xC)); /* 0x3100BB12: mov cl, byte ptr [edi + 0xc] */
  13237     /* test LO8(ecx), LO8(ecx) */ /* 0x3100BB15: test cl, cl */
  13238     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24;
  13239     _cf = 0;
  13240     _flag_k = FK_NARROW(FK_TEST, 24);
  13241     if (TEST_Z(_flag_a, _flag_b)) goto L_3100BB47; /* 0x3100BB17: je 0x3100bb47 */
  13242 L_3100BB19:
  13243     eax = ebp + (-0x1); /* 0x3100BB19: lea eax, [ebp - 1] */
  13244     PUSH32(esp, eax); /* 0x3100BB1C: push eax */
  13245     ecx = ebp + (-0x24); /* 0x3100BB1D: lea ecx, [ebp - 0x24] */
  13246     PUSH32(esp, ecx); /* 0x3100BB20: push ecx */
  13247     PUSH32(esp, ebx); /* 0x3100BB21: push ebx */
  13248     PUSH32(esp, esi); /* 0x3100BB22: push esi */
  13249     edx = ebp + (-0x10); /* 0x3100BB23: lea edx, [ebp - 0x10] */
  13250     PUSH32(esp, edx); /* 0x3100BB26: push edx */
  13251     ecx = edi; /* 0x3100BB27: mov ecx, edi */
  13252     MEM8(ebp + (-0x1)) = (uint8_t)(1); /* 0x3100BB29: mov byte ptr [ebp - 1], 1 */
  13253     RECOMP_ICALL(0x3100AB20u); /* 0x3100BB2D: call 0x3100ab20 */ /* not lifted */
  13254     RECOMP_FLAGS_IN();
  13255     PUSH32(esp, eax); /* 0x3100BB32: push eax */
  13256     ecx = ebp + (-0x34); /* 0x3100BB33: lea ecx, [ebp - 0x34] */
  13257     RECOMP_ICALL(0x3100AB00u); /* 0x3100BB36: call 0x3100ab00 */ /* not lifted */
  13258     RECOMP_FLAGS_IN();
  13259     ecx = eax; /* 0x3100BB3B: mov ecx, eax */
  13260     eax = MEM32(ecx); /* 0x3100BB3D: mov eax, dword ptr [ecx] */
  13261     ecx = MEM32(ecx + 0x4); /* 0x3100BB3F: mov ecx, dword ptr [ecx + 4] */
  13262     goto L_3100BBCC; /* 0x3100BB42: jmp 0x3100bbcc */
  13263 L_3100BB47:
  13264     /* test LO8(eax), LO8(eax) */ /* 0x3100BB47: test al, al */
  13265     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  13266     _cf = 0;
  13267     _flag_k = FK_NARROW(FK_TEST, 24);
  13268     MEM32(ebp + (-0x8)) = ebx; /* 0x3100BB49: mov dword ptr [ebp - 8], ebx */
  13269     if (TEST_Z(_flag_a, _flag_b)) goto L_3100BB87; /* 0x3100BB4C: je 0x3100bb87 */
  13270 L_3100BB4E:
  13271     edx = ebp + (-0x14); /* 0x3100BB4E: lea edx, [ebp - 0x14] */
  13272     PUSH32(esp, edx); /* 0x3100BB51: push edx */
  13273     ecx = edi; /* 0x3100BB52: mov ecx, edi */
  13274     RECOMP_ICALL(0x3100E400u); /* 0x3100BB54: call 0x3100e400 */ /* not lifted */
  13275     RECOMP_FLAGS_IN();
  13276     ecx = MEM32(ebp + (-0x8)); /* 0x3100BB59: mov ecx, dword ptr [ebp - 8] */
  13277     /* cmp ecx, MEM32(eax) */ /* 0x3100BB5C: cmp ecx, dword ptr [eax] */
  13278     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax));
  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_3100BB7F; /* 0x3100BB5E: jne 0x3100bb7f */
  13282 L_3100BB60:
  13283     edx = ebp + (-0x2); /* 0x3100BB60: lea edx, [ebp - 2] */
  13284     PUSH32(esp, edx); /* 0x3100BB63: push edx */
  13285     eax = ebp + (-0x24); /* 0x3100BB64: lea eax, [ebp - 0x24] */
  13286     PUSH32(esp, eax); /* 0x3100BB67: push eax */
  13287     PUSH32(esp, ebx); /* 0x3100BB68: push ebx */
  13288     PUSH32(esp, esi); /* 0x3100BB69: push esi */
  13289     ecx = ebp + (-0x18); /* 0x3100BB6A: lea ecx, [ebp - 0x18] */
  13290     PUSH32(esp, ecx); /* 0x3100BB6D: push ecx */
  13291     ecx = edi; /* 0x3100BB6E: mov ecx, edi */
  13292     MEM8(ebp + (-0x2)) = (uint8_t)(1); /* 0x3100BB70: mov byte ptr [ebp - 2], 1 */
  13293     RECOMP_ICALL(0x3100AB20u); /* 0x3100BB74: call 0x3100ab20 */ /* not lifted */
  13294     RECOMP_FLAGS_IN();
  13295     PUSH32(esp, eax); /* 0x3100BB79: push eax */
  13296     ecx = ebp + (-0x3C); /* 0x3100BB7A: lea ecx, [ebp - 0x3c] */
  13297     goto L_3100BBC0; /* 0x3100BB7D: jmp 0x3100bbc0 */
  13298 L_3100BB7F:
  13299     ecx = ebp + (-0x8); /* 0x3100BB7F: lea ecx, [ebp - 8] */
  13300     RECOMP_ICALL(0x31010B60u); /* 0x3100BB82: call 0x31010b60 */ /* not lifted */
  13301     RECOMP_FLAGS_IN();
  13302 L_3100BB87:
  13303     eax = MEM32(ebp + (-0x8)); /* 0x3100BB87: mov eax, dword ptr [ebp - 8] */
  13304     ecx = MEM32(eax + 0xC); /* 0x3100BB8A: mov ecx, dword ptr [eax + 0xc] */
  13305     /* cmp ecx, MEM32(ebp + (-0x24)) */ /* 0x3100BB8D: cmp ecx, dword ptr [ebp - 0x24] */
  13306     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(ebp + (-0x24)));
  13307     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13308     _flag_k = FK_CMP;
  13309     if (CMP_AE(_flag_a, _flag_b)) goto L_3100BBB1; /* 0x3100BB90: jae 0x3100bbb1 */
  13310 L_3100BB92:
  13311     edx = ebp + (-0x3); /* 0x3100BB92: lea edx, [ebp - 3] */
  13312     PUSH32(esp, edx); /* 0x3100BB95: push edx */
  13313     eax = ebp + (-0x24); /* 0x3100BB96: lea eax, [ebp - 0x24] */
  13314     PUSH32(esp, eax); /* 0x3100BB99: push eax */
  13315     PUSH32(esp, ebx); /* 0x3100BB9A: push ebx */
  13316     PUSH32(esp, esi); /* 0x3100BB9B: push esi */
  13317     ecx = ebp + (-0x1C); /* 0x3100BB9C: lea ecx, [ebp - 0x1c] */
  13318     PUSH32(esp, ecx); /* 0x3100BB9F: push ecx */
  13319     ecx = edi; /* 0x3100BBA0: mov ecx, edi */
  13320     MEM8(ebp + (-0x3)) = (uint8_t)(1); /* 0x3100BBA2: mov byte ptr [ebp - 3], 1 */
  13321     RECOMP_ICALL(0x3100AB20u); /* 0x3100BBA6: call 0x3100ab20 */ /* not lifted */
  13322     RECOMP_FLAGS_IN();
  13323     PUSH32(esp, eax); /* 0x3100BBAB: push eax */
  13324     ecx = ebp + (-0x44); /* 0x3100BBAC: lea ecx, [ebp - 0x44] */
  13325     goto L_3100BBC0; /* 0x3100BBAF: jmp 0x3100bbc0 */
  13326 L_3100BBB1:
  13327     eax = ebp + (-0x4); /* 0x3100BBB1: lea eax, [ebp - 4] */
  13328     ecx = ebp + (-0x8); /* 0x3100BBB4: lea ecx, [ebp - 8] */
  13329     PUSH32(esp, eax); /* 0x3100BBB7: push eax */
  13330     PUSH32(esp, ecx); /* 0x3100BBB8: push ecx */
  13331     MEM8(ebp + (-0x4)) = (uint8_t)(0); /* 0x3100BBB9: mov byte ptr [ebp - 4], 0 */
  13332     ecx = ebp + (-0x4C); /* 0x3100BBBD: lea ecx, [ebp - 0x4c] */
  13333 L_3100BBC0:
  13334     RECOMP_ICALL(0x3100AB00u); /* 0x3100BBC0: call 0x3100ab00 */ /* not lifted */
  13335     RECOMP_FLAGS_IN();
  13336     edx = eax; /* 0x3100BBC5: mov edx, eax */
  13337     eax = MEM32(edx); /* 0x3100BBC7: mov eax, dword ptr [edx] */
  13338     ecx = MEM32(edx + 0x4); /* 0x3100BBC9: mov ecx, dword ptr [edx + 4] */
  13339 L_3100BBCC:
  13340     MEM32(ebp + (-0x2C)) = eax; /* 0x3100BBCC: mov dword ptr [ebp - 0x2c], eax */
  13341     MEM32(ebp + (-0x28)) = ecx; /* 0x3100BBCF: mov dword ptr [ebp - 0x28], ecx */
  13342     eax = ebp + (-0x28); /* 0x3100BBD2: lea eax, [ebp - 0x28] */
  13343     PUSH32(esp, eax); /* 0x3100BBD5: push eax */
  13344     ecx = ebp + (-0x2C); /* 0x3100BBD6: lea ecx, [ebp - 0x2c] */
  13345     PUSH32(esp, ecx); /* 0x3100BBD9: push ecx */
  13346     ecx = ebp + (-0x54); /* 0x3100BBDA: lea ecx, [ebp - 0x54] */
  13347     RECOMP_ICALL(0x3100AB00u); /* 0x3100BBDD: call 0x3100ab00 */ /* not lifted */
  13348     RECOMP_FLAGS_IN();
  13349     edx = eax; /* 0x3100BBE2: mov edx, eax */
  13350     eax = MEM32(edx); /* 0x3100BBE4: mov eax, dword ptr [edx] */
  13351     esi = MEM32(eax + 0x10); /* 0x3100BBE6: mov esi, dword ptr [eax + 0x10] */
  13352     ecx = MEM32(edx + 0x4); /* 0x3100BBE9: mov ecx, dword ptr [edx + 4] */
  13353     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1);
  13354     esi = esi + 1; /* 0x3100BBEC: inc esi */
  13355     _flag_k = FK_INC;
  13356     MEM32(eax + 0x10) = esi; /* 0x3100BBED: mov dword ptr [eax + 0x10], esi */
  13357     esi = MEM32(ebp + (-0xC)); /* 0x3100BBF0: mov esi, dword ptr [ebp - 0xc] */
  13358     MEM32(ebp + (-0x58)) = ecx; /* 0x3100BBF3: mov dword ptr [ebp - 0x58], ecx */
  13359     ecx = esi; /* 0x3100BBF6: mov ecx, esi */
  13360     RECOMP_ICALL(0x310013E0u); /* 0x3100BBF8: call 0x310013e0 */ /* not lifted */
  13361     RECOMP_FLAGS_IN();
  13362     edx = MEM32(ebp + 0x8); /* 0x3100BBFD: mov edx, dword ptr [ebp + 8] */
  13363     PUSH32(esp, 0); /* 0x3100BC00: push 0 */
  13364     PUSH32(esp, edx); /* 0x3100BC02: push edx */
  13365     PUSH32(esp, 0x31052304u); /* 0x3100BC03: push 0x31052304 */
  13366     ecx = esi + 0x30; /* 0x3100BC08: lea ecx, [esi + 0x30] */
  13367     RECOMP_ICALL(0x31010D60u); /* 0x3100BC0B: call 0x31010d60 */ /* not lifted */
  13368     RECOMP_FLAGS_IN();
  13369     ecx = esi; /* 0x3100BC10: mov ecx, esi */
  13370     RECOMP_ICALL(0x310013E0u); /* 0x3100BC12: call 0x310013e0 */ /* not lifted */
  13371     RECOMP_FLAGS_IN();
  13372     edi = POP32_VAL(esp); /* 0x3100BC17: pop edi */
  13373     esi = POP32_VAL(esp); /* 0x3100BC18: pop esi */
  13374     SET_LO8(eax, 1); /* 0x3100BC19: mov al, 1 */
  13375     ebx = POP32_VAL(esp); /* 0x3100BC1B: pop ebx */
  13376     esp = ebp; /* 0x3100BC1C: mov esp, ebp */
  13377     ebp = POP32_VAL(esp); /* 0x3100BC1E: pop ebp */
  13378     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100BC1F: ret 4 */
  13379     RECOMP_REGS_OUT();
  13380 }
  13381 
  13382 void sub_3100BBCC(void) {
  13383     int _fpu_cmp = 0;
  13384     uint32_t _cf = 0;
  13385     int _df = 1;
  13386     uint32_t _flag_k = FK_NONE;
  13387     uint32_t _flag_a = 0, _flag_b = 0;
  13388     uint32_t _itail_tgt = 0;
  13389     RECOMP_REGS_LOCALS
  13390     RECOMP_ENTER(0x3100BBCCu);
  13391 
  13392 L_3100BBCC:
  13393     MEM32(ebp + (-0x2C)) = eax; /* 0x3100BBCC: mov dword ptr [ebp - 0x2c], eax */
  13394     MEM32(ebp + (-0x28)) = ecx; /* 0x3100BBCF: mov dword ptr [ebp - 0x28], ecx */
  13395     eax = ebp + (-0x28); /* 0x3100BBD2: lea eax, [ebp - 0x28] */
  13396     PUSH32(esp, eax); /* 0x3100BBD5: push eax */
  13397     ecx = ebp + (-0x2C); /* 0x3100BBD6: lea ecx, [ebp - 0x2c] */
  13398     PUSH32(esp, ecx); /* 0x3100BBD9: push ecx */
  13399     ecx = ebp + (-0x54); /* 0x3100BBDA: lea ecx, [ebp - 0x54] */
  13400     RECOMP_ICALL(0x3100AB00u); /* 0x3100BBDD: call 0x3100ab00 */ /* not lifted */
  13401     RECOMP_FLAGS_IN();
  13402     edx = eax; /* 0x3100BBE2: mov edx, eax */
  13403     eax = MEM32(edx); /* 0x3100BBE4: mov eax, dword ptr [edx] */
  13404     esi = MEM32(eax + 0x10); /* 0x3100BBE6: mov esi, dword ptr [eax + 0x10] */
  13405     ecx = MEM32(edx + 0x4); /* 0x3100BBE9: mov ecx, dword ptr [edx + 4] */
  13406     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(1);
  13407     esi = esi + 1; /* 0x3100BBEC: inc esi */
  13408     _flag_k = FK_INC;
  13409     MEM32(eax + 0x10) = esi; /* 0x3100BBED: mov dword ptr [eax + 0x10], esi */
  13410     esi = MEM32(ebp + (-0xC)); /* 0x3100BBF0: mov esi, dword ptr [ebp - 0xc] */
  13411     MEM32(ebp + (-0x58)) = ecx; /* 0x3100BBF3: mov dword ptr [ebp - 0x58], ecx */
  13412     ecx = esi; /* 0x3100BBF6: mov ecx, esi */
  13413     RECOMP_ICALL(0x310013E0u); /* 0x3100BBF8: call 0x310013e0 */ /* not lifted */
  13414     RECOMP_FLAGS_IN();
  13415     edx = MEM32(ebp + 0x8); /* 0x3100BBFD: mov edx, dword ptr [ebp + 8] */
  13416     PUSH32(esp, 0); /* 0x3100BC00: push 0 */
  13417     PUSH32(esp, edx); /* 0x3100BC02: push edx */
  13418     PUSH32(esp, 0x31052304u); /* 0x3100BC03: push 0x31052304 */
  13419     ecx = esi + 0x30; /* 0x3100BC08: lea ecx, [esi + 0x30] */
  13420     RECOMP_ICALL(0x31010D60u); /* 0x3100BC0B: call 0x31010d60 */ /* not lifted */
  13421     RECOMP_FLAGS_IN();
  13422     ecx = esi; /* 0x3100BC10: mov ecx, esi */
  13423     RECOMP_ICALL(0x310013E0u); /* 0x3100BC12: call 0x310013e0 */ /* not lifted */
  13424     RECOMP_FLAGS_IN();
  13425     edi = POP32_VAL(esp); /* 0x3100BC17: pop edi */
  13426     esi = POP32_VAL(esp); /* 0x3100BC18: pop esi */
  13427     SET_LO8(eax, 1); /* 0x3100BC19: mov al, 1 */
  13428     ebx = POP32_VAL(esp); /* 0x3100BC1B: pop ebx */
  13429     esp = ebp; /* 0x3100BC1C: mov esp, ebp */
  13430     ebp = POP32_VAL(esp); /* 0x3100BC1E: pop ebp */
  13431     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100BC1F: ret 4 */
  13432     RECOMP_REGS_OUT();
  13433 }
  13434 
  13435 void sub_3100BC30(void) {
  13436     int _fpu_cmp = 0;
  13437     uint32_t _cf = 0;
  13438     int _df = 1;
  13439     uint32_t _flag_k = FK_NONE;
  13440     uint32_t _flag_a = 0, _flag_b = 0;
  13441     uint32_t _itail_tgt = 0;
  13442     RECOMP_REGS_LOCALS
  13443     RECOMP_ENTER(0x3100BC30u);
  13444 
  13445 L_3100BC30:
  13446     PUSH32(esp, ebp); /* 0x3100BC30: push ebp */
  13447     ebp = esp; /* 0x3100BC31: mov ebp, esp */
  13448     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100BC33: push -1 */
  13449     PUSH32(esp, 0x310475C8u); /* 0x3100BC35: push 0x310475c8 */
  13450     eax = MEM32(FS_BASE + (0)); /* 0x3100BC3A: mov eax, dword ptr fs:[0] */
  13451     PUSH32(esp, eax); /* 0x3100BC40: push eax */
  13452     MEM32(FS_BASE + (0)) = esp; /* 0x3100BC41: mov dword ptr fs:[0], esp */
  13453     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x60u);
  13454     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13455     esp = esp - 0x60u; /* 0x3100BC48: sub esp, 0x60 */
  13456     _flag_k = FK_CMP;
  13457     PUSH32(esp, ebx); /* 0x3100BC4B: push ebx */
  13458     PUSH32(esp, esi); /* 0x3100BC4C: push esi */
  13459     PUSH32(esp, edi); /* 0x3100BC4D: push edi */
  13460     edi = ecx; /* 0x3100BC4E: mov edi, ecx */
  13461     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100BC50: push -1 */
  13462     ecx = ebp + (-0x6C); /* 0x3100BC52: lea ecx, [ebp - 0x6c] */
  13463     RECOMP_ICALL(MEM32(0x310482C8)); /* 0x3100BC55: call dword ptr [0x310482c8] */
  13464     RECOMP_FLAGS_IN();
  13465     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  13466     ebx = 0; /* 0x3100BC5B: xor ebx, ebx */
  13467     _cf = 0;
  13468     _flag_k = FK_TEST;
  13469     ecx = edi; /* 0x3100BC5D: mov ecx, edi */
  13470     MEM32(ebp + (-0x4)) = ebx; /* 0x3100BC5F: mov dword ptr [ebp - 4], ebx */
  13471     RECOMP_ICALL(0x310013E0u); /* 0x3100BC62: call 0x310013e0 */ /* not lifted */
  13472     RECOMP_FLAGS_IN();
  13473     eax = MEM32(ebp + 0x10); /* 0x3100BC67: mov eax, dword ptr [ebp + 0x10] */
  13474     PUSH32(esp, eax); /* 0x3100BC6A: push eax */
  13475     ecx = ebp + (-0x2C); /* 0x3100BC6B: lea ecx, [ebp - 0x2c] */
  13476     PUSH32(esp, 0x31052310u); /* 0x3100BC6E: push 0x31052310 */
  13477     PUSH32(esp, ecx); /* 0x3100BC73: push ecx */
  13478     RECOMP_ICALL(MEM32(0x31048208)); /* 0x3100BC74: call dword ptr [0x31048208] */
  13479     RECOMP_FLAGS_IN();
  13480     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
  13481     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13482     esp = esp + 0xCu; /* 0x3100BC7A: add esp, 0xc */
  13483     _flag_k = FK_ADD;
  13484     esi = edi + 0x30; /* 0x3100BC7D: lea esi, [edi + 0x30] */
  13485 L_3100BC80:
  13486     edx = MEM32(ebp + 0x8); /* 0x3100BC80: mov edx, dword ptr [ebp + 8] */
  13487     PUSH32(esp, ebx); /* 0x3100BC83: push ebx */
  13488     PUSH32(esp, edx); /* 0x3100BC84: push edx */
  13489     eax = ebp + (-0x2C); /* 0x3100BC85: lea eax, [ebp - 0x2c] */
  13490     PUSH32(esp, eax); /* 0x3100BC88: push eax */
  13491     ecx = esi; /* 0x3100BC89: mov ecx, esi */
  13492     RECOMP_ICALL(0x31010D60u); /* 0x3100BC8B: call 0x31010d60 */ /* not lifted */
  13493     RECOMP_FLAGS_IN();
  13494     ecx = ebp + (-0x6C); /* 0x3100BC90: lea ecx, [ebp - 0x6c] */
  13495     PUSH32(esp, ecx); /* 0x3100BC93: push ecx */
  13496     ecx = esi; /* 0x3100BC94: mov ecx, esi */
  13497     RECOMP_ICALL(0x31010F40u); /* 0x3100BC96: call 0x31010f40 */ /* not lifted */
  13498     RECOMP_FLAGS_IN();
  13499     /* test LO8(eax), LO8(eax) */ /* 0x3100BC9B: test al, al */
  13500     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  13501     _cf = 0;
  13502     _flag_k = FK_NARROW(FK_TEST, 24);
  13503     RECOMP_BACKEDGE();
  13504     if (TEST_Z(_flag_a, _flag_b)) goto L_3100BC80; /* 0x3100BC9D: je 0x3100bc80 */
  13505 L_3100BC9F:
  13506     ecx = edi; /* 0x3100BC9F: mov ecx, edi */
  13507     RECOMP_ICALL(0x310013E0u); /* 0x3100BCA1: call 0x310013e0 */ /* not lifted */
  13508     RECOMP_FLAGS_IN();
  13509     PUSH32(esp, ebx); /* 0x3100BCA6: push ebx */
  13510     edx = ebp + (-0xE); /* 0x3100BCA7: lea edx, [ebp - 0xe] */
  13511     PUSH32(esp, edx); /* 0x3100BCAA: push edx */
  13512     PUSH32(esp, 0x310522ECu); /* 0x3100BCAB: push 0x310522ec */
  13513     ecx = ebp + (-0x6C); /* 0x3100BCB0: lea ecx, [ebp - 0x6c] */
  13514     RECOMP_ICALL(MEM32(0x310482C0)); /* 0x3100BCB3: call dword ptr [0x310482c0] */
  13515     RECOMP_FLAGS_IN();
  13516     ecx = ebp + 0x10; /* 0x3100BCB9: lea ecx, [ebp + 0x10] */
  13517     RECOMP_ICALL(0x310045B0u); /* 0x3100BCBC: call 0x310045b0 */ /* not lifted */
  13518     RECOMP_FLAGS_IN();
  13519     esi = MEM32(ebp + 0xC); /* 0x3100BCC1: mov esi, dword ptr [ebp + 0xc] */
  13520     PUSH32(esp, eax); /* 0x3100BCC4: push eax */
  13521     ecx = esi; /* 0x3100BCC5: mov ecx, esi */
  13522     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3100BCC7: mov byte ptr [ebp - 4], 1 */
  13523     RECOMP_ICALL(0x310046E0u); /* 0x3100BCCB: call 0x310046e0 */ /* not lifted */
  13524     RECOMP_FLAGS_IN();
  13525     ecx = ebp + 0x10; /* 0x3100BCD0: lea ecx, [ebp + 0x10] */
  13526     MEM8(ebp + (-0x4)) = (uint8_t)(LO8(ebx)); /* 0x3100BCD3: mov byte ptr [ebp - 4], bl */
  13527     RECOMP_ICALL(0x31004760u); /* 0x3100BCD6: call 0x31004760 */ /* not lifted */
  13528     RECOMP_FLAGS_IN();
  13529     PUSH32(esp, ebx); /* 0x3100BCDB: push ebx */
  13530     eax = ebp + (-0x14); /* 0x3100BCDC: lea eax, [ebp - 0x14] */
  13531     PUSH32(esp, eax); /* 0x3100BCDF: push eax */
  13532     ecx = ebp + (-0x18); /* 0x3100BCE0: lea ecx, [ebp - 0x18] */
  13533     PUSH32(esp, ecx); /* 0x3100BCE3: push ecx */
  13534     PUSH32(esp, 0x31052244u); /* 0x3100BCE4: push 0x31052244 */
  13535     ecx = ebp + (-0x6C); /* 0x3100BCE9: lea ecx, [ebp - 0x6c] */
  13536     RECOMP_ICALL(MEM32(0x310482C4)); /* 0x3100BCEC: call dword ptr [0x310482c4] */
  13537     RECOMP_FLAGS_IN();
  13538     /* test eax, eax */ /* 0x3100BCF2: test eax, eax */
  13539     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  13540     _cf = 0;
  13541     _flag_k = FK_TEST;
  13542     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100BD1D; /* 0x3100BCF4: jne 0x3100bd1d */
  13543 L_3100BCF6:
  13544     edx = MEM32(ebp + (-0x14)); /* 0x3100BCF6: mov edx, dword ptr [ebp - 0x14] */
  13545     eax = MEM32(ebp + (-0x18)); /* 0x3100BCF9: mov eax, dword ptr [ebp - 0x18] */
  13546     PUSH32(esp, edx); /* 0x3100BCFC: push edx */
  13547     PUSH32(esp, eax); /* 0x3100BCFD: push eax */
  13548     ecx = ebp + 0x10; /* 0x3100BCFE: lea ecx, [ebp + 0x10] */
  13549     RECOMP_ICALL(0x31004670u); /* 0x3100BD01: call 0x31004670 */ /* not lifted */
  13550     RECOMP_FLAGS_IN();
  13551     PUSH32(esp, eax); /* 0x3100BD06: push eax */
  13552     ecx = esi; /* 0x3100BD07: mov ecx, esi */
  13553     MEM8(ebp + (-0x4)) = (uint8_t)(2); /* 0x3100BD09: mov byte ptr [ebp - 4], 2 */
  13554     RECOMP_ICALL(0x310046E0u); /* 0x3100BD0D: call 0x310046e0 */ /* not lifted */
  13555     RECOMP_FLAGS_IN();
  13556     ecx = ebp + 0x10; /* 0x3100BD12: lea ecx, [ebp + 0x10] */
  13557     MEM8(ebp + (-0x4)) = (uint8_t)(LO8(ebx)); /* 0x3100BD15: mov byte ptr [ebp - 4], bl */
  13558     RECOMP_ICALL(0x31004760u); /* 0x3100BD18: call 0x31004760 */ /* not lifted */
  13559     RECOMP_FLAGS_IN();
  13560 L_3100BD1D:
  13561     ecx = (int32_t)(int16_t)MEM16(ebp + (-0xE)); /* 0x3100BD1D: movsx ecx, word ptr [ebp - 0xe] */
  13562     MEM32(ebp + 0x8) = ecx; /* 0x3100BD21: mov dword ptr [ebp + 8], ecx */
  13563     MEM32(ebp + (-0x6C)) = 0x3104876Cu; /* 0x3100BD24: mov dword ptr [ebp - 0x6c], 0x3104876c */
  13564     ecx = ebp + (-0x6C); /* 0x3100BD2B: lea ecx, [ebp - 0x6c] */
  13565     MEM32(ebp + (-0x4)) = 4; /* 0x3100BD2E: mov dword ptr [ebp - 4], 4 */
  13566     RECOMP_ICALL(MEM32(0x310482F8)); /* 0x3100BD35: call dword ptr [0x310482f8] */
  13567     RECOMP_FLAGS_IN();
  13568     edx = MEM32(ebp + (-0x38)); /* 0x3100BD3B: mov edx, dword ptr [ebp - 0x38] */
  13569     PUSH32(esp, edx); /* 0x3100BD3E: push edx */
  13570     RECOMP_ICALL(0x31046858u); /* 0x3100BD3F: call 0x31046858 */ /* not lifted */
  13571     RECOMP_FLAGS_IN();
  13572     eax = MEM32(ebp + (-0x64)); /* 0x3100BD44: mov eax, dword ptr [ebp - 0x64] */
  13573     edx = MEM32(ebp + (-0x58)); /* 0x3100BD47: mov edx, dword ptr [ebp - 0x58] */
  13574     MEM32(ebp + (-0x38)) = ebx; /* 0x3100BD4A: mov dword ptr [ebp - 0x38], ebx */
  13575     MEM32(ebp + (-0x34)) = ebx; /* 0x3100BD4D: mov dword ptr [ebp - 0x34], ebx */
  13576     MEM32(ebp + (-0x30)) = ebx; /* 0x3100BD50: mov dword ptr [ebp - 0x30], ebx */
  13577     ecx = MEM32(eax); /* 0x3100BD53: mov ecx, dword ptr [eax] */
  13578     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  13579     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13580     esp = esp + 4; /* 0x3100BD55: add esp, 4 */
  13581     _flag_k = FK_ADD;
  13582     /* cmp edx, ebx */ /* 0x3100BD58: cmp edx, ebx */
  13583     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ebx);
  13584     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13585     _flag_k = FK_CMP;
  13586     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100BD5A: mov dword ptr [ebp - 4], 0xffffffff */
  13587     edi = eax; /* 0x3100BD61: mov edi, eax */
  13588     MEM32(ebp + 0x10) = ecx; /* 0x3100BD63: mov dword ptr [ebp + 0x10], ecx */
  13589     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100BD93; /* 0x3100BD66: je 0x3100bd93 */
  13590 L_3100BD68:
  13591     edx = ecx; /* 0x3100BD68: mov edx, ecx */
  13592     /* cmp ecx, edx */ /* 0x3100BD6A: cmp ecx, edx */
  13593     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
  13594     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13595     _flag_k = FK_CMP;
  13596     if (CMP_NE(_flag_a, _flag_b)) goto L_3100BD93; /* 0x3100BD6C: jne 0x3100bd93 */
  13597 L_3100BD6E:
  13598     eax = MEM32(eax + 0x4); /* 0x3100BD6E: mov eax, dword ptr [eax + 4] */
  13599     PUSH32(esp, eax); /* 0x3100BD71: push eax */
  13600     ecx = ebp + (-0x68); /* 0x3100BD72: lea ecx, [ebp - 0x68] */
  13601     RECOMP_ICALL(0x3100E8B0u); /* 0x3100BD75: call 0x3100e8b0 */ /* not lifted */
  13602     RECOMP_FLAGS_IN();
  13603     ecx = MEM32(ebp + (-0x64)); /* 0x3100BD7A: mov ecx, dword ptr [ebp - 0x64] */
  13604     edx = MEM32(ebp + (-0x60)); /* 0x3100BD7D: mov edx, dword ptr [ebp - 0x60] */
  13605     MEM32(ecx + 0x4) = edx; /* 0x3100BD80: mov dword ptr [ecx + 4], edx */
  13606     eax = MEM32(ebp + (-0x64)); /* 0x3100BD83: mov eax, dword ptr [ebp - 0x64] */
  13607     MEM32(ebp + (-0x58)) = ebx; /* 0x3100BD86: mov dword ptr [ebp - 0x58], ebx */
  13608     MEM32(eax) = eax; /* 0x3100BD89: mov dword ptr [eax], eax */
  13609     eax = MEM32(ebp + (-0x64)); /* 0x3100BD8B: mov eax, dword ptr [ebp - 0x64] */
  13610     MEM32(eax + 0x8) = eax; /* 0x3100BD8E: mov dword ptr [eax + 8], eax */
  13611     goto L_3100BDB5; /* 0x3100BD91: jmp 0x3100bdb5 */
  13612 L_3100BD93:
  13613     /* cmp ecx, eax */ /* 0x3100BD93: cmp ecx, eax */
  13614     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
  13615     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13616     _flag_k = FK_CMP;
  13617     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100BDB8; /* 0x3100BD95: je 0x3100bdb8 */
  13618 L_3100BD97:
  13619     esi = ecx; /* 0x3100BD97: mov esi, ecx */
  13620     ecx = ebp + 0x10; /* 0x3100BD99: lea ecx, [ebp + 0x10] */
  13621     RECOMP_ICALL(0x3100EC20u); /* 0x3100BD9C: call 0x3100ec20 */ /* not lifted */
  13622     RECOMP_FLAGS_IN();
  13623     PUSH32(esp, esi); /* 0x3100BDA1: push esi */
  13624     eax = ebp + 0xC; /* 0x3100BDA2: lea eax, [ebp + 0xc] */
  13625     PUSH32(esp, eax); /* 0x3100BDA5: push eax */
  13626     ecx = ebp + (-0x68); /* 0x3100BDA6: lea ecx, [ebp - 0x68] */
  13627     RECOMP_ICALL(0x3100E4E0u); /* 0x3100BDA9: call 0x3100e4e0 */ /* not lifted */
  13628     RECOMP_FLAGS_IN();
  13629     ecx = MEM32(ebp + 0x10); /* 0x3100BDAE: mov ecx, dword ptr [ebp + 0x10] */
  13630     /* cmp ecx, edi */ /* 0x3100BDB1: cmp ecx, edi */
  13631     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
  13632     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13633     _flag_k = FK_CMP;
  13634     RECOMP_BACKEDGE();
  13635     if (CMP_NE(_flag_a, _flag_b)) goto L_3100BD97; /* 0x3100BDB3: jne 0x3100bd97 */
  13636 L_3100BDB5:
  13637     eax = MEM32(ebp + (-0x64)); /* 0x3100BDB5: mov eax, dword ptr [ebp - 0x64] */
  13638 L_3100BDB8:
  13639     PUSH32(esp, eax); /* 0x3100BDB8: push eax */
  13640     RECOMP_ICALL(0x31046858u); /* 0x3100BDB9: call 0x31046858 */ /* not lifted */
  13641     RECOMP_FLAGS_IN();
  13642     ecx = MEM32(ebp + (-0x60)); /* 0x3100BDBE: mov ecx, dword ptr [ebp - 0x60] */
  13643     PUSH32(esp, ecx); /* 0x3100BDC1: push ecx */
  13644     MEM32(ebp + (-0x64)) = ebx; /* 0x3100BDC2: mov dword ptr [ebp - 0x64], ebx */
  13645     MEM32(ebp + (-0x58)) = ebx; /* 0x3100BDC5: mov dword ptr [ebp - 0x58], ebx */
  13646     RECOMP_ICALL(0x31046858u); /* 0x3100BDC8: call 0x31046858 */ /* not lifted */
  13647     RECOMP_FLAGS_IN();
  13648     ecx = MEM32(ebp + (-0xC)); /* 0x3100BDCD: mov ecx, dword ptr [ebp - 0xc] */
  13649     eax = MEM32(ebp + 0x8); /* 0x3100BDD0: mov eax, dword ptr [ebp + 8] */
  13650     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  13651     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13652     esp = esp + 8; /* 0x3100BDD3: add esp, 8 */
  13653     _flag_k = FK_ADD;
  13654     edi = POP32_VAL(esp); /* 0x3100BDD6: pop edi */
  13655     esi = POP32_VAL(esp); /* 0x3100BDD7: pop esi */
  13656     ebx = POP32_VAL(esp); /* 0x3100BDD8: pop ebx */
  13657     MEM32(FS_BASE + (0)) = ecx; /* 0x3100BDD9: mov dword ptr fs:[0], ecx */
  13658     esp = ebp; /* 0x3100BDE0: mov esp, ebp */
  13659     ebp = POP32_VAL(esp); /* 0x3100BDE2: pop ebp */
  13660     RECOMP_FLAGS_OUT(); esp += 16; { RECOMP_REGS_OUT(); return; } /* 0x3100BDE3: ret 0xc */
  13661     RECOMP_REGS_OUT();
  13662 }
  13663 
  13664 void sub_3100BDF0(void) {
  13665     int _fpu_cmp = 0;
  13666     uint32_t _cf = 0;
  13667     int _df = 1;
  13668     uint32_t _flag_k = FK_NONE;
  13669     uint32_t _flag_a = 0, _flag_b = 0;
  13670     uint32_t _itail_tgt = 0;
  13671     RECOMP_REGS_LOCALS
  13672     RECOMP_ENTER(0x3100BDF0u);
  13673 
  13674 L_3100BDF0:
  13675     PUSH32(esp, ebp); /* 0x3100BDF0: push ebp */
  13676     ebp = esp; /* 0x3100BDF1: mov ebp, esp */
  13677     PUSH32(esp, esi); /* 0x3100BDF3: push esi */
  13678     esi = ecx; /* 0x3100BDF4: mov esi, ecx */
  13679     PUSH32(esp, 0); /* 0x3100BDF6: push 0 */
  13680     RECOMP_ICALL(0x31009E30u); /* 0x3100BDF8: call 0x31009e30 */ /* not lifted */
  13681     RECOMP_FLAGS_IN();
  13682     /* test LO8(eax), LO8(eax) */ /* 0x3100BDFD: test al, al */
  13683     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  13684     _cf = 0;
  13685     _flag_k = FK_NARROW(FK_TEST, 24);
  13686     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100BE0B; /* 0x3100BDFF: jne 0x3100be0b */
  13687 L_3100BE01:
  13688     eax = 1; /* 0x3100BE01: mov eax, 1 */
  13689     esi = POP32_VAL(esp); /* 0x3100BE06: pop esi */
  13690     ebp = POP32_VAL(esp); /* 0x3100BE07: pop ebp */
  13691     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100BE08: ret 4 */
  13692 L_3100BE0B:
  13693     ecx = esi; /* 0x3100BE0B: mov ecx, esi */
  13694     RECOMP_ICALL(0x310013E0u); /* 0x3100BE0D: call 0x310013e0 */ /* not lifted */
  13695     RECOMP_FLAGS_IN();
  13696     eax = MEM32(ebp + 0x8); /* 0x3100BE12: mov eax, dword ptr [ebp + 8] */
  13697     PUSH32(esp, 0); /* 0x3100BE15: push 0 */
  13698     PUSH32(esp, eax); /* 0x3100BE17: push eax */
  13699     PUSH32(esp, 0x3105231Cu); /* 0x3100BE18: push 0x3105231c */
  13700     ecx = esi + 0x30; /* 0x3100BE1D: lea ecx, [esi + 0x30] */
  13701     RECOMP_ICALL(0x31010D60u); /* 0x3100BE20: call 0x31010d60 */ /* not lifted */
  13702     RECOMP_FLAGS_IN();
  13703     ecx = esi; /* 0x3100BE25: mov ecx, esi */
  13704     RECOMP_ICALL(0x310013E0u); /* 0x3100BE27: call 0x310013e0 */ /* not lifted */
  13705     RECOMP_FLAGS_IN();
  13706     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  13707     eax = 0; /* 0x3100BE2C: xor eax, eax */
  13708     _cf = 0;
  13709     _flag_k = FK_TEST;
  13710     esi = POP32_VAL(esp); /* 0x3100BE2E: pop esi */
  13711     ebp = POP32_VAL(esp); /* 0x3100BE2F: pop ebp */
  13712     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100BE30: ret 4 */
  13713     RECOMP_REGS_OUT();
  13714 }
  13715 
  13716 void sub_3100BE40(void) {
  13717     int _fpu_cmp = 0;
  13718     uint32_t _cf = 0;
  13719     int _df = 1;
  13720     uint32_t _flag_k = FK_NONE;
  13721     uint32_t _flag_a = 0, _flag_b = 0;
  13722     uint32_t _itail_tgt = 0;
  13723     RECOMP_REGS_LOCALS
  13724     RECOMP_ENTER(0x3100BE40u);
  13725 
  13726 L_3100BE40:
  13727     PUSH32(esp, ebp); /* 0x3100BE40: push ebp */
  13728     ebp = esp; /* 0x3100BE41: mov ebp, esp */
  13729     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100BE43: push -1 */
  13730     PUSH32(esp, 0x310475F8u); /* 0x3100BE45: push 0x310475f8 */
  13731     eax = MEM32(FS_BASE + (0)); /* 0x3100BE4A: mov eax, dword ptr fs:[0] */
  13732     PUSH32(esp, eax); /* 0x3100BE50: push eax */
  13733     MEM32(FS_BASE + (0)) = esp; /* 0x3100BE51: mov dword ptr fs:[0], esp */
  13734     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x4Cu);
  13735     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13736     esp = esp - 0x4Cu; /* 0x3100BE58: sub esp, 0x4c */
  13737     _flag_k = FK_CMP;
  13738     PUSH32(esp, ebx); /* 0x3100BE5B: push ebx */
  13739     PUSH32(esp, esi); /* 0x3100BE5C: push esi */
  13740     PUSH32(esp, edi); /* 0x3100BE5D: push edi */
  13741     edi = ecx; /* 0x3100BE5E: mov edi, ecx */
  13742     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100BE60: push -1 */
  13743     ecx = ebp + (-0x58); /* 0x3100BE62: lea ecx, [ebp - 0x58] */
  13744     RECOMP_ICALL(MEM32(0x310482C8)); /* 0x3100BE65: call dword ptr [0x310482c8] */
  13745     RECOMP_FLAGS_IN();
  13746     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  13747     ebx = 0; /* 0x3100BE6B: xor ebx, ebx */
  13748     _cf = 0;
  13749     _flag_k = FK_TEST;
  13750     ecx = edi; /* 0x3100BE6D: mov ecx, edi */
  13751     MEM32(ebp + (-0x4)) = ebx; /* 0x3100BE6F: mov dword ptr [ebp - 4], ebx */
  13752     RECOMP_ICALL(0x310013E0u); /* 0x3100BE72: call 0x310013e0 */ /* not lifted */
  13753     RECOMP_FLAGS_IN();
  13754     esi = edi + 0x30; /* 0x3100BE77: lea esi, [edi + 0x30] */
  13755 L_3100BE7A:
  13756     eax = MEM32(ebp + 0x8); /* 0x3100BE7A: mov eax, dword ptr [ebp + 8] */
  13757     PUSH32(esp, ebx); /* 0x3100BE7D: push ebx */
  13758     PUSH32(esp, eax); /* 0x3100BE7E: push eax */
  13759     PUSH32(esp, 0x31052324u); /* 0x3100BE7F: push 0x31052324 */
  13760     ecx = esi; /* 0x3100BE84: mov ecx, esi */
  13761     RECOMP_ICALL(0x31010D60u); /* 0x3100BE86: call 0x31010d60 */ /* not lifted */
  13762     RECOMP_FLAGS_IN();
  13763     ecx = ebp + (-0x58); /* 0x3100BE8B: lea ecx, [ebp - 0x58] */
  13764     PUSH32(esp, ecx); /* 0x3100BE8E: push ecx */
  13765     ecx = esi; /* 0x3100BE8F: mov ecx, esi */
  13766     RECOMP_ICALL(0x31010F40u); /* 0x3100BE91: call 0x31010f40 */ /* not lifted */
  13767     RECOMP_FLAGS_IN();
  13768     /* test LO8(eax), LO8(eax) */ /* 0x3100BE96: test al, al */
  13769     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  13770     _cf = 0;
  13771     _flag_k = FK_NARROW(FK_TEST, 24);
  13772     RECOMP_BACKEDGE();
  13773     if (TEST_Z(_flag_a, _flag_b)) goto L_3100BE7A; /* 0x3100BE98: je 0x3100be7a */
  13774 L_3100BE9A:
  13775     ecx = edi; /* 0x3100BE9A: mov ecx, edi */
  13776     RECOMP_ICALL(0x310013E0u); /* 0x3100BE9C: call 0x310013e0 */ /* not lifted */
  13777     RECOMP_FLAGS_IN();
  13778     PUSH32(esp, ebx); /* 0x3100BEA1: push ebx */
  13779     edx = ebp + (-0x10); /* 0x3100BEA2: lea edx, [ebp - 0x10] */
  13780     PUSH32(esp, edx); /* 0x3100BEA5: push edx */
  13781     PUSH32(esp, 0x310522ECu); /* 0x3100BEA6: push 0x310522ec */
  13782     ecx = ebp + (-0x58); /* 0x3100BEAB: lea ecx, [ebp - 0x58] */
  13783     RECOMP_ICALL(MEM32(0x310482D4)); /* 0x3100BEAE: call dword ptr [0x310482d4] */
  13784     RECOMP_FLAGS_IN();
  13785     eax = MEM32(ebp + (-0x10)); /* 0x3100BEB4: mov eax, dword ptr [ebp - 0x10] */
  13786     MEM32(ebp + (-0x14)) = eax; /* 0x3100BEB7: mov dword ptr [ebp - 0x14], eax */
  13787     MEM32(ebp + (-0x58)) = 0x3104876Cu; /* 0x3100BEBA: mov dword ptr [ebp - 0x58], 0x3104876c */
  13788     ecx = ebp + (-0x58); /* 0x3100BEC1: lea ecx, [ebp - 0x58] */
  13789     MEM32(ebp + (-0x4)) = 2; /* 0x3100BEC4: mov dword ptr [ebp - 4], 2 */
  13790     RECOMP_ICALL(MEM32(0x310482F8)); /* 0x3100BECB: call dword ptr [0x310482f8] */
  13791     RECOMP_FLAGS_IN();
  13792     ecx = MEM32(ebp + (-0x24)); /* 0x3100BED1: mov ecx, dword ptr [ebp - 0x24] */
  13793     PUSH32(esp, ecx); /* 0x3100BED4: push ecx */
  13794     RECOMP_ICALL(0x31046858u); /* 0x3100BED5: call 0x31046858 */ /* not lifted */
  13795     RECOMP_FLAGS_IN();
  13796     eax = MEM32(ebp + (-0x50)); /* 0x3100BEDA: mov eax, dword ptr [ebp - 0x50] */
  13797     edx = MEM32(ebp + (-0x44)); /* 0x3100BEDD: mov edx, dword ptr [ebp - 0x44] */
  13798     MEM32(ebp + (-0x24)) = ebx; /* 0x3100BEE0: mov dword ptr [ebp - 0x24], ebx */
  13799     MEM32(ebp + (-0x20)) = ebx; /* 0x3100BEE3: mov dword ptr [ebp - 0x20], ebx */
  13800     MEM32(ebp + (-0x1C)) = ebx; /* 0x3100BEE6: mov dword ptr [ebp - 0x1c], ebx */
  13801     ecx = MEM32(eax); /* 0x3100BEE9: mov ecx, dword ptr [eax] */
  13802     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  13803     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13804     esp = esp + 4; /* 0x3100BEEB: add esp, 4 */
  13805     _flag_k = FK_ADD;
  13806     /* cmp edx, ebx */ /* 0x3100BEEE: cmp edx, ebx */
  13807     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ebx);
  13808     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13809     _flag_k = FK_CMP;
  13810     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100BEF0: mov dword ptr [ebp - 4], 0xffffffff */
  13811     edi = eax; /* 0x3100BEF7: mov edi, eax */
  13812     MEM32(ebp + 0x8) = ecx; /* 0x3100BEF9: mov dword ptr [ebp + 8], ecx */
  13813     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100BF29; /* 0x3100BEFC: je 0x3100bf29 */
  13814 L_3100BEFE:
  13815     edx = ecx; /* 0x3100BEFE: mov edx, ecx */
  13816     /* cmp ecx, edx */ /* 0x3100BF00: cmp ecx, edx */
  13817     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
  13818     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13819     _flag_k = FK_CMP;
  13820     if (CMP_NE(_flag_a, _flag_b)) goto L_3100BF29; /* 0x3100BF02: jne 0x3100bf29 */
  13821 L_3100BF04:
  13822     edx = MEM32(eax + 0x4); /* 0x3100BF04: mov edx, dword ptr [eax + 4] */
  13823     PUSH32(esp, edx); /* 0x3100BF07: push edx */
  13824     ecx = ebp + (-0x54); /* 0x3100BF08: lea ecx, [ebp - 0x54] */
  13825     RECOMP_ICALL(0x3100E8B0u); /* 0x3100BF0B: call 0x3100e8b0 */ /* not lifted */
  13826     RECOMP_FLAGS_IN();
  13827     eax = MEM32(ebp + (-0x50)); /* 0x3100BF10: mov eax, dword ptr [ebp - 0x50] */
  13828     ecx = MEM32(ebp + (-0x4C)); /* 0x3100BF13: mov ecx, dword ptr [ebp - 0x4c] */
  13829     MEM32(eax + 0x4) = ecx; /* 0x3100BF16: mov dword ptr [eax + 4], ecx */
  13830     eax = MEM32(ebp + (-0x50)); /* 0x3100BF19: mov eax, dword ptr [ebp - 0x50] */
  13831     MEM32(ebp + (-0x44)) = ebx; /* 0x3100BF1C: mov dword ptr [ebp - 0x44], ebx */
  13832     MEM32(eax) = eax; /* 0x3100BF1F: mov dword ptr [eax], eax */
  13833     eax = MEM32(ebp + (-0x50)); /* 0x3100BF21: mov eax, dword ptr [ebp - 0x50] */
  13834     MEM32(eax + 0x8) = eax; /* 0x3100BF24: mov dword ptr [eax + 8], eax */
  13835     goto L_3100BF4B; /* 0x3100BF27: jmp 0x3100bf4b */
  13836 L_3100BF29:
  13837     /* cmp ecx, eax */ /* 0x3100BF29: cmp ecx, eax */
  13838     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
  13839     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13840     _flag_k = FK_CMP;
  13841     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100BF4E; /* 0x3100BF2B: je 0x3100bf4e */
  13842 L_3100BF2D:
  13843     esi = ecx; /* 0x3100BF2D: mov esi, ecx */
  13844     ecx = ebp + 0x8; /* 0x3100BF2F: lea ecx, [ebp + 8] */
  13845     RECOMP_ICALL(0x3100EC20u); /* 0x3100BF32: call 0x3100ec20 */ /* not lifted */
  13846     RECOMP_FLAGS_IN();
  13847     PUSH32(esp, esi); /* 0x3100BF37: push esi */
  13848     edx = ebp + (-0x18); /* 0x3100BF38: lea edx, [ebp - 0x18] */
  13849     PUSH32(esp, edx); /* 0x3100BF3B: push edx */
  13850     ecx = ebp + (-0x54); /* 0x3100BF3C: lea ecx, [ebp - 0x54] */
  13851     RECOMP_ICALL(0x3100E4E0u); /* 0x3100BF3F: call 0x3100e4e0 */ /* not lifted */
  13852     RECOMP_FLAGS_IN();
  13853     ecx = MEM32(ebp + 0x8); /* 0x3100BF44: mov ecx, dword ptr [ebp + 8] */
  13854     /* cmp ecx, edi */ /* 0x3100BF47: cmp ecx, edi */
  13855     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edi);
  13856     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13857     _flag_k = FK_CMP;
  13858     RECOMP_BACKEDGE();
  13859     if (CMP_NE(_flag_a, _flag_b)) goto L_3100BF2D; /* 0x3100BF49: jne 0x3100bf2d */
  13860 L_3100BF4B:
  13861     eax = MEM32(ebp + (-0x50)); /* 0x3100BF4B: mov eax, dword ptr [ebp - 0x50] */
  13862 L_3100BF4E:
  13863     PUSH32(esp, eax); /* 0x3100BF4E: push eax */
  13864     RECOMP_ICALL(0x31046858u); /* 0x3100BF4F: call 0x31046858 */ /* not lifted */
  13865     RECOMP_FLAGS_IN();
  13866     eax = MEM32(ebp + (-0x4C)); /* 0x3100BF54: mov eax, dword ptr [ebp - 0x4c] */
  13867     PUSH32(esp, eax); /* 0x3100BF57: push eax */
  13868     MEM32(ebp + (-0x50)) = ebx; /* 0x3100BF58: mov dword ptr [ebp - 0x50], ebx */
  13869     MEM32(ebp + (-0x44)) = ebx; /* 0x3100BF5B: mov dword ptr [ebp - 0x44], ebx */
  13870     RECOMP_ICALL(0x31046858u); /* 0x3100BF5E: call 0x31046858 */ /* not lifted */
  13871     RECOMP_FLAGS_IN();
  13872     ecx = MEM32(ebp + (-0xC)); /* 0x3100BF63: mov ecx, dword ptr [ebp - 0xc] */
  13873     eax = MEM32(ebp + (-0x14)); /* 0x3100BF66: mov eax, dword ptr [ebp - 0x14] */
  13874     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  13875     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  13876     esp = esp + 8; /* 0x3100BF69: add esp, 8 */
  13877     _flag_k = FK_ADD;
  13878     edi = POP32_VAL(esp); /* 0x3100BF6C: pop edi */
  13879     esi = POP32_VAL(esp); /* 0x3100BF6D: pop esi */
  13880     ebx = POP32_VAL(esp); /* 0x3100BF6E: pop ebx */
  13881     MEM32(FS_BASE + (0)) = ecx; /* 0x3100BF6F: mov dword ptr fs:[0], ecx */
  13882     esp = ebp; /* 0x3100BF76: mov esp, ebp */
  13883     ebp = POP32_VAL(esp); /* 0x3100BF78: pop ebp */
  13884     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100BF79: ret 4 */
  13885     RECOMP_REGS_OUT();
  13886 }
  13887 
  13888 void sub_3100BF80(void) {
  13889     int _fpu_cmp = 0;
  13890     uint32_t _cf = 0;
  13891     int _df = 1;
  13892     uint32_t _flag_k = FK_NONE;
  13893     uint32_t _flag_a = 0, _flag_b = 0;
  13894     uint32_t _itail_tgt = 0;
  13895     RECOMP_REGS_LOCALS
  13896     RECOMP_ENTER(0x3100BF80u);
  13897 
  13898 L_3100BF80:
  13899     PUSH32(esp, ebp); /* 0x3100BF80: push ebp */
  13900     ebp = esp; /* 0x3100BF81: mov ebp, esp */
  13901     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x5Cu);
  13902     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13903     esp = esp - 0x5Cu; /* 0x3100BF83: sub esp, 0x5c */
  13904     _flag_k = FK_CMP;
  13905     edx = MEM32(ebp + 0x8); /* 0x3100BF86: mov edx, dword ptr [ebp + 8] */
  13906     PUSH32(esp, ebx); /* 0x3100BF89: push ebx */
  13907     ebx = MEM32(ecx + 0x18); /* 0x3100BF8A: mov ebx, dword ptr [ecx + 0x18] */
  13908     PUSH32(esp, esi); /* 0x3100BF8D: push esi */
  13909     PUSH32(esp, edi); /* 0x3100BF8E: push edi */
  13910     edi = ecx + 0x14; /* 0x3100BF8F: lea edi, [ecx + 0x14] */
  13911     MEM32(ebp + (-0xC)) = ecx; /* 0x3100BF92: mov dword ptr [ebp - 0xc], ecx */
  13912     ecx = MEM32(edi + 0x8); /* 0x3100BF95: mov ecx, dword ptr [edi + 8] */
  13913     MEM32(ebp + (-0x24)) = edx; /* 0x3100BF98: mov dword ptr [ebp - 0x24], edx */
  13914     MEM32(ebp + (-0x20)) = 0; /* 0x3100BF9B: mov dword ptr [ebp - 0x20], 0 */
  13915     esi = MEM32(ebx + 0x4); /* 0x3100BFA2: mov esi, dword ptr [ebx + 4] */
  13916     /* cmp esi, ecx */ /* 0x3100BFA5: cmp esi, ecx */
  13917     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ecx);
  13918     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13919     _flag_k = FK_CMP;
  13920     SET_LO8(eax, 1); /* 0x3100BFA7: mov al, 1 */
  13921     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100BFC2; /* 0x3100BFA9: je 0x3100bfc2 */
  13922 L_3100BFAB:
  13923     /* cmp edx, MEM32(esi + 0xC) */ /* 0x3100BFAB: cmp edx, dword ptr [esi + 0xc] */
  13924     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(esi + 0xC));
  13925     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13926     _flag_k = FK_CMP;
  13927     SET_LO8(eax, (CMP_B(_flag_a, _flag_b)) ? 1 : 0); /* 0x3100BFAE: setb al */
  13928     /* test LO8(eax), LO8(eax) */ /* 0x3100BFB1: test al, al */
  13929     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  13930     _cf = 0;
  13931     _flag_k = FK_NARROW(FK_TEST, 24);
  13932     ebx = esi; /* 0x3100BFB3: mov ebx, esi */
  13933     if (TEST_Z(_flag_a, _flag_b)) goto L_3100BFBB; /* 0x3100BFB5: je 0x3100bfbb */
  13934 L_3100BFB7:
  13935     esi = MEM32(esi); /* 0x3100BFB7: mov esi, dword ptr [esi] */
  13936     goto L_3100BFBE; /* 0x3100BFB9: jmp 0x3100bfbe */
  13937 L_3100BFBB:
  13938     esi = MEM32(esi + 0x8); /* 0x3100BFBB: mov esi, dword ptr [esi + 8] */
  13939 L_3100BFBE:
  13940     /* cmp esi, ecx */ /* 0x3100BFBE: cmp esi, ecx */
  13941     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ecx);
  13942     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13943     _flag_k = FK_CMP;
  13944     RECOMP_BACKEDGE();
  13945     if (CMP_NE(_flag_a, _flag_b)) goto L_3100BFAB; /* 0x3100BFC0: jne 0x3100bfab */
  13946 L_3100BFC2:
  13947     SET_LO8(ecx, MEM8(edi + 0xC)); /* 0x3100BFC2: mov cl, byte ptr [edi + 0xc] */
  13948     /* test LO8(ecx), LO8(ecx) */ /* 0x3100BFC5: test cl, cl */
  13949     _flag_a = (uint32_t)(LO8(ecx)) << 24; _flag_b = (uint32_t)(LO8(ecx)) << 24;
  13950     _cf = 0;
  13951     _flag_k = FK_NARROW(FK_TEST, 24);
  13952     if (TEST_Z(_flag_a, _flag_b)) goto L_3100BFF7; /* 0x3100BFC7: je 0x3100bff7 */
  13953 L_3100BFC9:
  13954     eax = ebp + (-0x1); /* 0x3100BFC9: lea eax, [ebp - 1] */
  13955     PUSH32(esp, eax); /* 0x3100BFCC: push eax */
  13956     ecx = ebp + (-0x24); /* 0x3100BFCD: lea ecx, [ebp - 0x24] */
  13957     PUSH32(esp, ecx); /* 0x3100BFD0: push ecx */
  13958     PUSH32(esp, ebx); /* 0x3100BFD1: push ebx */
  13959     PUSH32(esp, esi); /* 0x3100BFD2: push esi */
  13960     edx = ebp + (-0x10); /* 0x3100BFD3: lea edx, [ebp - 0x10] */
  13961     PUSH32(esp, edx); /* 0x3100BFD6: push edx */
  13962     ecx = edi; /* 0x3100BFD7: mov ecx, edi */
  13963     MEM8(ebp + (-0x1)) = (uint8_t)(1); /* 0x3100BFD9: mov byte ptr [ebp - 1], 1 */
  13964     RECOMP_ICALL(0x3100AB20u); /* 0x3100BFDD: call 0x3100ab20 */ /* not lifted */
  13965     RECOMP_FLAGS_IN();
  13966     PUSH32(esp, eax); /* 0x3100BFE2: push eax */
  13967     ecx = ebp + (-0x34); /* 0x3100BFE3: lea ecx, [ebp - 0x34] */
  13968     RECOMP_ICALL(0x3100AB00u); /* 0x3100BFE6: call 0x3100ab00 */ /* not lifted */
  13969     RECOMP_FLAGS_IN();
  13970     ecx = eax; /* 0x3100BFEB: mov ecx, eax */
  13971     eax = MEM32(ecx); /* 0x3100BFED: mov eax, dword ptr [ecx] */
  13972     ecx = MEM32(ecx + 0x4); /* 0x3100BFEF: mov ecx, dword ptr [ecx + 4] */
  13973     goto L_3100C07C; /* 0x3100BFF2: jmp 0x3100c07c */
  13974 L_3100BFF7:
  13975     /* test LO8(eax), LO8(eax) */ /* 0x3100BFF7: test al, al */
  13976     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  13977     _cf = 0;
  13978     _flag_k = FK_NARROW(FK_TEST, 24);
  13979     MEM32(ebp + (-0x8)) = ebx; /* 0x3100BFF9: mov dword ptr [ebp - 8], ebx */
  13980     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C037; /* 0x3100BFFC: je 0x3100c037 */
  13981 L_3100BFFE:
  13982     edx = ebp + (-0x14); /* 0x3100BFFE: lea edx, [ebp - 0x14] */
  13983     PUSH32(esp, edx); /* 0x3100C001: push edx */
  13984     ecx = edi; /* 0x3100C002: mov ecx, edi */
  13985     RECOMP_ICALL(0x3100E400u); /* 0x3100C004: call 0x3100e400 */ /* not lifted */
  13986     RECOMP_FLAGS_IN();
  13987     ecx = MEM32(ebp + (-0x8)); /* 0x3100C009: mov ecx, dword ptr [ebp - 8] */
  13988     /* cmp ecx, MEM32(eax) */ /* 0x3100C00C: cmp ecx, dword ptr [eax] */
  13989     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(eax));
  13990     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  13991     _flag_k = FK_CMP;
  13992     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C02F; /* 0x3100C00E: jne 0x3100c02f */
  13993 L_3100C010:
  13994     edx = ebp + (-0x2); /* 0x3100C010: lea edx, [ebp - 2] */
  13995     PUSH32(esp, edx); /* 0x3100C013: push edx */
  13996     eax = ebp + (-0x24); /* 0x3100C014: lea eax, [ebp - 0x24] */
  13997     PUSH32(esp, eax); /* 0x3100C017: push eax */
  13998     PUSH32(esp, ebx); /* 0x3100C018: push ebx */
  13999     PUSH32(esp, esi); /* 0x3100C019: push esi */
  14000     ecx = ebp + (-0x18); /* 0x3100C01A: lea ecx, [ebp - 0x18] */
  14001     PUSH32(esp, ecx); /* 0x3100C01D: push ecx */
  14002     ecx = edi; /* 0x3100C01E: mov ecx, edi */
  14003     MEM8(ebp + (-0x2)) = (uint8_t)(1); /* 0x3100C020: mov byte ptr [ebp - 2], 1 */
  14004     RECOMP_ICALL(0x3100AB20u); /* 0x3100C024: call 0x3100ab20 */ /* not lifted */
  14005     RECOMP_FLAGS_IN();
  14006     PUSH32(esp, eax); /* 0x3100C029: push eax */
  14007     ecx = ebp + (-0x3C); /* 0x3100C02A: lea ecx, [ebp - 0x3c] */
  14008     goto L_3100C070; /* 0x3100C02D: jmp 0x3100c070 */
  14009 L_3100C02F:
  14010     ecx = ebp + (-0x8); /* 0x3100C02F: lea ecx, [ebp - 8] */
  14011     RECOMP_ICALL(0x31010B60u); /* 0x3100C032: call 0x31010b60 */ /* not lifted */
  14012     RECOMP_FLAGS_IN();
  14013 L_3100C037:
  14014     eax = MEM32(ebp + (-0x8)); /* 0x3100C037: mov eax, dword ptr [ebp - 8] */
  14015     ecx = MEM32(eax + 0xC); /* 0x3100C03A: mov ecx, dword ptr [eax + 0xc] */
  14016     /* cmp ecx, MEM32(ebp + (-0x24)) */ /* 0x3100C03D: cmp ecx, dword ptr [ebp - 0x24] */
  14017     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(MEM32(ebp + (-0x24)));
  14018     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14019     _flag_k = FK_CMP;
  14020     if (CMP_AE(_flag_a, _flag_b)) goto L_3100C061; /* 0x3100C040: jae 0x3100c061 */
  14021 L_3100C042:
  14022     edx = ebp + (-0x3); /* 0x3100C042: lea edx, [ebp - 3] */
  14023     PUSH32(esp, edx); /* 0x3100C045: push edx */
  14024     eax = ebp + (-0x24); /* 0x3100C046: lea eax, [ebp - 0x24] */
  14025     PUSH32(esp, eax); /* 0x3100C049: push eax */
  14026     PUSH32(esp, ebx); /* 0x3100C04A: push ebx */
  14027     PUSH32(esp, esi); /* 0x3100C04B: push esi */
  14028     ecx = ebp + (-0x1C); /* 0x3100C04C: lea ecx, [ebp - 0x1c] */
  14029     PUSH32(esp, ecx); /* 0x3100C04F: push ecx */
  14030     ecx = edi; /* 0x3100C050: mov ecx, edi */
  14031     MEM8(ebp + (-0x3)) = (uint8_t)(1); /* 0x3100C052: mov byte ptr [ebp - 3], 1 */
  14032     RECOMP_ICALL(0x3100AB20u); /* 0x3100C056: call 0x3100ab20 */ /* not lifted */
  14033     RECOMP_FLAGS_IN();
  14034     PUSH32(esp, eax); /* 0x3100C05B: push eax */
  14035     ecx = ebp + (-0x44); /* 0x3100C05C: lea ecx, [ebp - 0x44] */
  14036     goto L_3100C070; /* 0x3100C05F: jmp 0x3100c070 */
  14037 L_3100C061:
  14038     eax = ebp + (-0x4); /* 0x3100C061: lea eax, [ebp - 4] */
  14039     ecx = ebp + (-0x8); /* 0x3100C064: lea ecx, [ebp - 8] */
  14040     PUSH32(esp, eax); /* 0x3100C067: push eax */
  14041     PUSH32(esp, ecx); /* 0x3100C068: push ecx */
  14042     MEM8(ebp + (-0x4)) = (uint8_t)(0); /* 0x3100C069: mov byte ptr [ebp - 4], 0 */
  14043     ecx = ebp + (-0x4C); /* 0x3100C06D: lea ecx, [ebp - 0x4c] */
  14044 L_3100C070:
  14045     RECOMP_ICALL(0x3100AB00u); /* 0x3100C070: call 0x3100ab00 */ /* not lifted */
  14046     RECOMP_FLAGS_IN();
  14047     edx = eax; /* 0x3100C075: mov edx, eax */
  14048     eax = MEM32(edx); /* 0x3100C077: mov eax, dword ptr [edx] */
  14049     ecx = MEM32(edx + 0x4); /* 0x3100C079: mov ecx, dword ptr [edx + 4] */
  14050 L_3100C07C:
  14051     MEM32(ebp + (-0x2C)) = eax; /* 0x3100C07C: mov dword ptr [ebp - 0x2c], eax */
  14052     MEM32(ebp + (-0x28)) = ecx; /* 0x3100C07F: mov dword ptr [ebp - 0x28], ecx */
  14053     eax = ebp + (-0x28); /* 0x3100C082: lea eax, [ebp - 0x28] */
  14054     PUSH32(esp, eax); /* 0x3100C085: push eax */
  14055     ecx = ebp + (-0x2C); /* 0x3100C086: lea ecx, [ebp - 0x2c] */
  14056     PUSH32(esp, ecx); /* 0x3100C089: push ecx */
  14057     ecx = ebp + (-0x54); /* 0x3100C08A: lea ecx, [ebp - 0x54] */
  14058     RECOMP_ICALL(0x3100AB00u); /* 0x3100C08D: call 0x3100ab00 */ /* not lifted */
  14059     RECOMP_FLAGS_IN();
  14060     edx = eax; /* 0x3100C092: mov edx, eax */
  14061     eax = MEM32(edx); /* 0x3100C094: mov eax, dword ptr [edx] */
  14062     ecx = MEM32(edx + 0x4); /* 0x3100C096: mov ecx, dword ptr [edx + 4] */
  14063     edx = MEM32(eax + 0x10); /* 0x3100C099: mov edx, dword ptr [eax + 0x10] */
  14064     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
  14065     edx = edx + 1; /* 0x3100C09C: inc edx */
  14066     _flag_k = FK_INC;
  14067     MEM32(ebp + (-0x58)) = ecx; /* 0x3100C09D: mov dword ptr [ebp - 0x58], ecx */
  14068     ecx = edx; /* 0x3100C0A0: mov ecx, edx */
  14069     /* cmp ecx, 1 */ /* 0x3100C0A2: cmp ecx, 1 */
  14070     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
  14071     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14072     _flag_k = FK_CMP;
  14073     MEM32(eax + 0x10) = edx; /* 0x3100C0A5: mov dword ptr [eax + 0x10], edx */
  14074     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C0CE; /* 0x3100C0A8: jne 0x3100c0ce */
  14075 L_3100C0AA:
  14076     esi = MEM32(ebp + (-0xC)); /* 0x3100C0AA: mov esi, dword ptr [ebp - 0xc] */
  14077     ecx = esi; /* 0x3100C0AD: mov ecx, esi */
  14078     RECOMP_ICALL(0x310013E0u); /* 0x3100C0AF: call 0x310013e0 */ /* not lifted */
  14079     RECOMP_FLAGS_IN();
  14080     edx = MEM32(ebp + 0x8); /* 0x3100C0B4: mov edx, dword ptr [ebp + 8] */
  14081     PUSH32(esp, 0); /* 0x3100C0B7: push 0 */
  14082     PUSH32(esp, edx); /* 0x3100C0B9: push edx */
  14083     PUSH32(esp, 0x3105232Cu); /* 0x3100C0BA: push 0x3105232c */
  14084     ecx = esi + 0x30; /* 0x3100C0BF: lea ecx, [esi + 0x30] */
  14085     RECOMP_ICALL(0x31010D60u); /* 0x3100C0C2: call 0x31010d60 */ /* not lifted */
  14086     RECOMP_FLAGS_IN();
  14087     ecx = esi; /* 0x3100C0C7: mov ecx, esi */
  14088     RECOMP_ICALL(0x310013E0u); /* 0x3100C0C9: call 0x310013e0 */ /* not lifted */
  14089     RECOMP_FLAGS_IN();
  14090 L_3100C0CE:
  14091     edi = POP32_VAL(esp); /* 0x3100C0CE: pop edi */
  14092     esi = POP32_VAL(esp); /* 0x3100C0CF: pop esi */
  14093     SET_LO8(eax, 1); /* 0x3100C0D0: mov al, 1 */
  14094     ebx = POP32_VAL(esp); /* 0x3100C0D2: pop ebx */
  14095     esp = ebp; /* 0x3100C0D3: mov esp, ebp */
  14096     ebp = POP32_VAL(esp); /* 0x3100C0D5: pop ebp */
  14097     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100C0D6: ret 4 */
  14098     RECOMP_REGS_OUT();
  14099 }
  14100 
  14101 void sub_3100C07C(void) {
  14102     int _fpu_cmp = 0;
  14103     uint32_t _cf = 0;
  14104     int _df = 1;
  14105     uint32_t _flag_k = FK_NONE;
  14106     uint32_t _flag_a = 0, _flag_b = 0;
  14107     uint32_t _itail_tgt = 0;
  14108     RECOMP_REGS_LOCALS
  14109     RECOMP_ENTER(0x3100C07Cu);
  14110 
  14111 L_3100C07C:
  14112     MEM32(ebp + (-0x2C)) = eax; /* 0x3100C07C: mov dword ptr [ebp - 0x2c], eax */
  14113     MEM32(ebp + (-0x28)) = ecx; /* 0x3100C07F: mov dword ptr [ebp - 0x28], ecx */
  14114     eax = ebp + (-0x28); /* 0x3100C082: lea eax, [ebp - 0x28] */
  14115     PUSH32(esp, eax); /* 0x3100C085: push eax */
  14116     ecx = ebp + (-0x2C); /* 0x3100C086: lea ecx, [ebp - 0x2c] */
  14117     PUSH32(esp, ecx); /* 0x3100C089: push ecx */
  14118     ecx = ebp + (-0x54); /* 0x3100C08A: lea ecx, [ebp - 0x54] */
  14119     RECOMP_ICALL(0x3100AB00u); /* 0x3100C08D: call 0x3100ab00 */ /* not lifted */
  14120     RECOMP_FLAGS_IN();
  14121     edx = eax; /* 0x3100C092: mov edx, eax */
  14122     eax = MEM32(edx); /* 0x3100C094: mov eax, dword ptr [edx] */
  14123     ecx = MEM32(edx + 0x4); /* 0x3100C096: mov ecx, dword ptr [edx + 4] */
  14124     edx = MEM32(eax + 0x10); /* 0x3100C099: mov edx, dword ptr [eax + 0x10] */
  14125     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(1);
  14126     edx = edx + 1; /* 0x3100C09C: inc edx */
  14127     _flag_k = FK_INC;
  14128     MEM32(ebp + (-0x58)) = ecx; /* 0x3100C09D: mov dword ptr [ebp - 0x58], ecx */
  14129     ecx = edx; /* 0x3100C0A0: mov ecx, edx */
  14130     /* cmp ecx, 1 */ /* 0x3100C0A2: cmp ecx, 1 */
  14131     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
  14132     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14133     _flag_k = FK_CMP;
  14134     MEM32(eax + 0x10) = edx; /* 0x3100C0A5: mov dword ptr [eax + 0x10], edx */
  14135     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C0CE; /* 0x3100C0A8: jne 0x3100c0ce */
  14136 L_3100C0AA:
  14137     esi = MEM32(ebp + (-0xC)); /* 0x3100C0AA: mov esi, dword ptr [ebp - 0xc] */
  14138     ecx = esi; /* 0x3100C0AD: mov ecx, esi */
  14139     RECOMP_ICALL(0x310013E0u); /* 0x3100C0AF: call 0x310013e0 */ /* not lifted */
  14140     RECOMP_FLAGS_IN();
  14141     edx = MEM32(ebp + 0x8); /* 0x3100C0B4: mov edx, dword ptr [ebp + 8] */
  14142     PUSH32(esp, 0); /* 0x3100C0B7: push 0 */
  14143     PUSH32(esp, edx); /* 0x3100C0B9: push edx */
  14144     PUSH32(esp, 0x3105232Cu); /* 0x3100C0BA: push 0x3105232c */
  14145     ecx = esi + 0x30; /* 0x3100C0BF: lea ecx, [esi + 0x30] */
  14146     RECOMP_ICALL(0x31010D60u); /* 0x3100C0C2: call 0x31010d60 */ /* not lifted */
  14147     RECOMP_FLAGS_IN();
  14148     ecx = esi; /* 0x3100C0C7: mov ecx, esi */
  14149     RECOMP_ICALL(0x310013E0u); /* 0x3100C0C9: call 0x310013e0 */ /* not lifted */
  14150     RECOMP_FLAGS_IN();
  14151 L_3100C0CE:
  14152     edi = POP32_VAL(esp); /* 0x3100C0CE: pop edi */
  14153     esi = POP32_VAL(esp); /* 0x3100C0CF: pop esi */
  14154     SET_LO8(eax, 1); /* 0x3100C0D0: mov al, 1 */
  14155     ebx = POP32_VAL(esp); /* 0x3100C0D2: pop ebx */
  14156     esp = ebp; /* 0x3100C0D3: mov esp, ebp */
  14157     ebp = POP32_VAL(esp); /* 0x3100C0D5: pop ebp */
  14158     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100C0D6: ret 4 */
  14159     RECOMP_REGS_OUT();
  14160 }
  14161 
  14162 void sub_3100C0E0(void) {
  14163     int _fpu_cmp = 0;
  14164     uint32_t _cf = 0;
  14165     int _df = 1;
  14166     uint32_t _flag_k = FK_NONE;
  14167     uint32_t _flag_a = 0, _flag_b = 0;
  14168     uint32_t _itail_tgt = 0;
  14169     RECOMP_REGS_LOCALS
  14170     RECOMP_ENTER(0x3100C0E0u);
  14171 
  14172 L_3100C0E0:
  14173     PUSH32(esp, ebp); /* 0x3100C0E0: push ebp */
  14174     ebp = esp; /* 0x3100C0E1: mov ebp, esp */
  14175     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
  14176     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14177     esp = esp - 0xCu; /* 0x3100C0E3: sub esp, 0xc */
  14178     _flag_k = FK_CMP;
  14179     eax = MEM32(ebp + 0x8); /* 0x3100C0E6: mov eax, dword ptr [ebp + 8] */
  14180     PUSH32(esp, ebx); /* 0x3100C0E9: push ebx */
  14181     PUSH32(esp, esi); /* 0x3100C0EA: push esi */
  14182     esi = ecx; /* 0x3100C0EB: mov esi, ecx */
  14183     PUSH32(esp, edi); /* 0x3100C0ED: push edi */
  14184     ecx = ebp + (-0x4); /* 0x3100C0EE: lea ecx, [ebp - 4] */
  14185     edi = esi + 0x14; /* 0x3100C0F1: lea edi, [esi + 0x14] */
  14186     PUSH32(esp, ecx); /* 0x3100C0F4: push ecx */
  14187     ecx = edi; /* 0x3100C0F5: mov ecx, edi */
  14188     MEM32(ebp + (-0x4)) = eax; /* 0x3100C0F7: mov dword ptr [ebp - 4], eax */
  14189     RECOMP_ICALL(0x3100FE00u); /* 0x3100C0FA: call 0x3100fe00 */ /* not lifted */
  14190     RECOMP_FLAGS_IN();
  14191     ecx = MEM32(edi + 0x4); /* 0x3100C0FF: mov ecx, dword ptr [edi + 4] */
  14192     /* cmp eax, ecx */ /* 0x3100C102: cmp eax, ecx */
  14193     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  14194     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14195     _flag_k = FK_CMP;
  14196     MEM32(ebp + (-0x8)) = eax; /* 0x3100C104: mov dword ptr [ebp - 8], eax */
  14197     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C116; /* 0x3100C107: je 0x3100c116 */
  14198 L_3100C109:
  14199     edx = MEM32(ebp + (-0x4)); /* 0x3100C109: mov edx, dword ptr [ebp - 4] */
  14200     /* cmp edx, MEM32(eax + 0xC) */ /* 0x3100C10C: cmp edx, dword ptr [eax + 0xc] */
  14201     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(MEM32(eax + 0xC));
  14202     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14203     _flag_k = FK_CMP;
  14204     if (CMP_B(_flag_a, _flag_b)) goto L_3100C116; /* 0x3100C10F: jb 0x3100c116 */
  14205 L_3100C111:
  14206     eax = ebp + (-0x8); /* 0x3100C111: lea eax, [ebp - 8] */
  14207     goto L_3100C11C; /* 0x3100C114: jmp 0x3100c11c */
  14208 L_3100C116:
  14209     MEM32(ebp + (-0xC)) = ecx; /* 0x3100C116: mov dword ptr [ebp - 0xc], ecx */
  14210     eax = ebp + (-0xC); /* 0x3100C119: lea eax, [ebp - 0xc] */
  14211 L_3100C11C:
  14212     ebx = MEM32(eax); /* 0x3100C11C: mov ebx, dword ptr [eax] */
  14213     _flag_a = (uint32_t)(MEM32(ebx + 0x10)); _flag_b = (uint32_t)(1);
  14214     MEM32(ebx + 0x10) = MEM32(ebx + 0x10) - 1; /* 0x3100C11E: dec dword ptr [ebx + 0x10] */
  14215     _flag_k = FK_DEC;
  14216     if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3100C150; /* 0x3100C121: jne 0x3100c150 */
  14217 L_3100C123:
  14218     ecx = esi; /* 0x3100C123: mov ecx, esi */
  14219     RECOMP_ICALL(0x310013E0u); /* 0x3100C125: call 0x310013e0 */ /* not lifted */
  14220     RECOMP_FLAGS_IN();
  14221     eax = MEM32(ebp + 0x8); /* 0x3100C12A: mov eax, dword ptr [ebp + 8] */
  14222     PUSH32(esp, 0); /* 0x3100C12D: push 0 */
  14223     PUSH32(esp, eax); /* 0x3100C12F: push eax */
  14224     PUSH32(esp, 0x31052334u); /* 0x3100C130: push 0x31052334 */
  14225     ecx = esi + 0x30; /* 0x3100C135: lea ecx, [esi + 0x30] */
  14226     RECOMP_ICALL(0x31010D60u); /* 0x3100C138: call 0x31010d60 */ /* not lifted */
  14227     RECOMP_FLAGS_IN();
  14228     ecx = esi; /* 0x3100C13D: mov ecx, esi */
  14229     RECOMP_ICALL(0x310013E0u); /* 0x3100C13F: call 0x310013e0 */ /* not lifted */
  14230     RECOMP_FLAGS_IN();
  14231     PUSH32(esp, ebx); /* 0x3100C144: push ebx */
  14232     ecx = ebp + 0x8; /* 0x3100C145: lea ecx, [ebp + 8] */
  14233     PUSH32(esp, ecx); /* 0x3100C148: push ecx */
  14234     ecx = edi; /* 0x3100C149: mov ecx, edi */
  14235     RECOMP_ICALL(0x310099F0u); /* 0x3100C14B: call 0x310099f0 */ /* not lifted */
  14236     RECOMP_FLAGS_IN();
  14237 L_3100C150:
  14238     edi = POP32_VAL(esp); /* 0x3100C150: pop edi */
  14239     esi = POP32_VAL(esp); /* 0x3100C151: pop esi */
  14240     ebx = POP32_VAL(esp); /* 0x3100C152: pop ebx */
  14241     esp = ebp; /* 0x3100C153: mov esp, ebp */
  14242     ebp = POP32_VAL(esp); /* 0x3100C155: pop ebp */
  14243     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100C156: ret 4 */
  14244     RECOMP_REGS_OUT();
  14245 }
  14246 
  14247 void sub_3100C160(void) {
  14248     int _fpu_cmp = 0;
  14249     uint32_t _cf = 0;
  14250     int _df = 1;
  14251     uint32_t _flag_k = FK_NONE;
  14252     uint32_t _flag_a = 0, _flag_b = 0;
  14253     uint32_t _itail_tgt = 0;
  14254     RECOMP_REGS_LOCALS
  14255     RECOMP_ENTER(0x3100C160u);
  14256 
  14257 L_3100C160:
  14258     PUSH32(esp, ebp); /* 0x3100C160: push ebp */
  14259     ebp = esp; /* 0x3100C161: mov ebp, esp */
  14260     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100C163: push -1 */
  14261     PUSH32(esp, 0x3104764Fu); /* 0x3100C165: push 0x3104764f */
  14262     eax = MEM32(FS_BASE + (0)); /* 0x3100C16A: mov eax, dword ptr fs:[0] */
  14263     PUSH32(esp, eax); /* 0x3100C170: push eax */
  14264     MEM32(FS_BASE + (0)) = esp; /* 0x3100C171: mov dword ptr fs:[0], esp */
  14265     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x9Cu);
  14266     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14267     esp = esp - 0x9Cu; /* 0x3100C178: sub esp, 0x9c */
  14268     _flag_k = FK_CMP;
  14269     edx = MEM32(ebp + 0x8); /* 0x3100C17E: mov edx, dword ptr [ebp + 8] */
  14270     PUSH32(esp, ebx); /* 0x3100C181: push ebx */
  14271     PUSH32(esp, esi); /* 0x3100C182: push esi */
  14272     esi = ecx; /* 0x3100C183: mov esi, ecx */
  14273     eax = MEM32(esi + 0xC); /* 0x3100C185: mov eax, dword ptr [esi + 0xc] */
  14274     ecx = eax + (-0x1); /* 0x3100C188: lea ecx, [eax - 1] */
  14275     eax = MEM32(edx + 0x8); /* 0x3100C18B: mov eax, dword ptr [edx + 8] */
  14276     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  14277     ebx = 0; /* 0x3100C18E: xor ebx, ebx */
  14278     _cf = 0;
  14279     _flag_k = FK_TEST;
  14280     /* cmp eax, ecx */ /* 0x3100C190: cmp eax, ecx */
  14281     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ecx);
  14282     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14283     _flag_k = FK_CMP;
  14284     PUSH32(esp, edi); /* 0x3100C192: push edi */
  14285     MEM32(ebp + (-0x14)) = esi; /* 0x3100C193: mov dword ptr [ebp - 0x14], esi */
  14286     if (CMP_A(_flag_a, _flag_b)) goto L_3100C1C4; /* 0x3100C196: ja 0x3100c1c4 */
  14287 L_3100C198:
  14288     eax = MEM32(edx + 0x4); /* 0x3100C198: mov eax, dword ptr [edx + 4] */
  14289     /* cmp eax, ebx */ /* 0x3100C19B: cmp eax, ebx */
  14290     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  14291     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14292     _flag_k = FK_CMP;
  14293     edi = MEM32(0x310480EC); /* 0x3100C19D: mov edi, dword ptr [0x310480ec] */
  14294     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C1A7; /* 0x3100C1A3: jne 0x3100c1a7 */
  14295 L_3100C1A5:
  14296     eax = edi; /* 0x3100C1A5: mov eax, edi */
  14297 L_3100C1A7:
  14298     edx = MEM32(esi + 0x8); /* 0x3100C1A7: mov edx, dword ptr [esi + 8] */
  14299     /* cmp edx, ebx */ /* 0x3100C1AA: cmp edx, ebx */
  14300     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ebx);
  14301     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14302     _flag_k = FK_CMP;
  14303     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C1B0; /* 0x3100C1AC: jne 0x3100c1b0 */
  14304 L_3100C1AE:
  14305     edx = edi; /* 0x3100C1AE: mov edx, edi */
  14306 L_3100C1B0:
  14307     PUSH32(esp, ecx); /* 0x3100C1B0: push ecx */
  14308     PUSH32(esp, eax); /* 0x3100C1B1: push eax */
  14309     PUSH32(esp, edx); /* 0x3100C1B2: push edx */
  14310     RECOMP_ICALL(MEM32(0x31048180)); /* 0x3100C1B3: call dword ptr [0x31048180] */
  14311     RECOMP_FLAGS_IN();
  14312     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
  14313     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14314     esp = esp + 0xCu; /* 0x3100C1B9: add esp, 0xc */
  14315     _flag_k = FK_ADD;
  14316     /* test eax, eax */ /* 0x3100C1BC: test eax, eax */
  14317     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  14318     _cf = 0;
  14319     _flag_k = FK_TEST;
  14320     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C3EF; /* 0x3100C1BE: je 0x3100c3ef */
  14321 L_3100C1C4:
  14322     PUSH32(esp, 1); /* 0x3100C1C4: push 1 */
  14323     PUSH32(esp, ebx); /* 0x3100C1C6: push ebx */
  14324     eax = ebp + (-0xD); /* 0x3100C1C7: lea eax, [ebp - 0xd] */
  14325     edi = esi + 0x4; /* 0x3100C1CA: lea edi, [esi + 4] */
  14326     PUSH32(esp, eax); /* 0x3100C1CD: push eax */
  14327     ecx = edi; /* 0x3100C1CE: mov ecx, edi */
  14328     MEM8(ebp + (-0xD)) = (uint8_t)(0x2Fu); /* 0x3100C1D0: mov byte ptr [ebp - 0xd], 0x2f */
  14329     RECOMP_ICALL(MEM32(0x310480AC)); /* 0x3100C1D4: call dword ptr [0x310480ac] */
  14330     RECOMP_FLAGS_IN();
  14331     /* cmp eax, 0xFFFFFFFFu */ /* 0x3100C1DA: cmp eax, -1 */
  14332     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(0xFFFFFFFFu);
  14333     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14334     _flag_k = FK_CMP;
  14335     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C1E2; /* 0x3100C1DD: jne 0x3100c1e2 */
  14336 L_3100C1DF:
  14337     eax = MEM32(esi + 0xC); /* 0x3100C1DF: mov eax, dword ptr [esi + 0xc] */
  14338 L_3100C1E2:
  14339     ecx = MEM32(ebp + 0x8); /* 0x3100C1E2: mov ecx, dword ptr [ebp + 8] */
  14340     ecx = MEM32(ecx + 0x4); /* 0x3100C1E5: mov ecx, dword ptr [ecx + 4] */
  14341     /* cmp ecx, ebx */ /* 0x3100C1E8: cmp ecx, ebx */
  14342     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
  14343     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14344     _flag_k = FK_CMP;
  14345     edx = MEM32(0x310480EC); /* 0x3100C1EA: mov edx, dword ptr [0x310480ec] */
  14346     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C1F4; /* 0x3100C1F0: jne 0x3100c1f4 */
  14347 L_3100C1F2:
  14348     ecx = edx; /* 0x3100C1F2: mov ecx, edx */
  14349 L_3100C1F4:
  14350     edi = MEM32(edi + 0x4); /* 0x3100C1F4: mov edi, dword ptr [edi + 4] */
  14351     /* cmp edi, ebx */ /* 0x3100C1F7: cmp edi, ebx */
  14352     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
  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_3100C1FD; /* 0x3100C1F9: je 0x3100c1fd */
  14356 L_3100C1FB:
  14357     edx = edi; /* 0x3100C1FB: mov edx, edi */
  14358 L_3100C1FD:
  14359     PUSH32(esp, eax); /* 0x3100C1FD: push eax */
  14360     PUSH32(esp, ecx); /* 0x3100C1FE: push ecx */
  14361     PUSH32(esp, edx); /* 0x3100C1FF: push edx */
  14362     RECOMP_ICALL(MEM32(0x31048180)); /* 0x3100C200: call dword ptr [0x31048180] */
  14363     RECOMP_FLAGS_IN();
  14364     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
  14365     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14366     esp = esp + 0xCu; /* 0x3100C206: add esp, 0xc */
  14367     _flag_k = FK_ADD;
  14368     /* test eax, eax */ /* 0x3100C209: test eax, eax */
  14369     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  14370     _cf = 0;
  14371     _flag_k = FK_TEST;
  14372     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C22B; /* 0x3100C20B: je 0x3100c22b */
  14373 L_3100C20D:
  14374     edx = MEM32(ebp + 0x8); /* 0x3100C20D: mov edx, dword ptr [ebp + 8] */
  14375     PUSH32(esp, edx); /* 0x3100C210: push edx */
  14376     ecx = esi; /* 0x3100C211: mov ecx, esi */
  14377     RECOMP_ICALL(0x31008FB0u); /* 0x3100C213: call 0x31008fb0 */ /* not lifted */
  14378     RECOMP_FLAGS_IN();
  14379     edi = POP32_VAL(esp); /* 0x3100C218: pop edi */
  14380     esi = POP32_VAL(esp); /* 0x3100C219: pop esi */
  14381     ebx = POP32_VAL(esp); /* 0x3100C21A: pop ebx */
  14382     ecx = MEM32(ebp + (-0xC)); /* 0x3100C21B: mov ecx, dword ptr [ebp - 0xc] */
  14383     MEM32(FS_BASE + (0)) = ecx; /* 0x3100C21E: mov dword ptr fs:[0], ecx */
  14384     esp = ebp; /* 0x3100C225: mov esp, ebp */
  14385     ebp = POP32_VAL(esp); /* 0x3100C227: pop ebp */
  14386     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100C228: ret 4 */
  14387 L_3100C22B:
  14388     edi = MEM32(0x310482C8); /* 0x3100C22B: mov edi, dword ptr [0x310482c8] */
  14389     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100C231: push -1 */
  14390     ecx = ebp + (-0x68); /* 0x3100C233: lea ecx, [ebp - 0x68] */
  14391     RECOMP_ICALL(edi); /* 0x3100C236: call edi */
  14392     RECOMP_FLAGS_IN();
  14393     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100C238: push -1 */
  14394     ecx = ebp + (-0xA8); /* 0x3100C23A: lea ecx, [ebp - 0xa8] */
  14395     MEM32(ebp + (-0x4)) = ebx; /* 0x3100C240: mov dword ptr [ebp - 4], ebx */
  14396     RECOMP_ICALL(edi); /* 0x3100C243: call edi */
  14397     RECOMP_FLAGS_IN();
  14398     SET_LO8(eax, MEM8(ebp + 0xB)); /* 0x3100C245: mov al, byte ptr [ebp + 0xb] */
  14399     _flag_a = (uint32_t)((ecx | 0xFFFFFFFFu)); _flag_b = (uint32_t)((ecx | 0xFFFFFFFFu));
  14400     ecx = ecx | 0xFFFFFFFFu; /* 0x3100C248: or ecx, 0xffffffff */
  14401     _cf = 0;
  14402     _flag_k = FK_TEST;
  14403     MEM8(ebp + (-0x24)) = (uint8_t)(LO8(eax)); /* 0x3100C24B: mov byte ptr [ebp - 0x24], al */
  14404     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  14405     eax = 0; /* 0x3100C24E: xor eax, eax */
  14406     _cf = 0;
  14407     _flag_k = FK_TEST;
  14408     edi = 0x3105233Cu; /* 0x3100C250: mov edi, 0x3105233c */
  14409     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; } /* 0x3100C255: repne scasb al, byte ptr es:[edi] */
  14410     ecx = ~ecx; /* 0x3100C257: not ecx */
  14411     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
  14412     ecx = ecx - 1; /* 0x3100C259: dec ecx */
  14413     _flag_k = FK_DEC;
  14414     edi = ecx; /* 0x3100C25A: mov edi, ecx */
  14415     PUSH32(esp, 1); /* 0x3100C25C: push 1 */
  14416     PUSH32(esp, edi); /* 0x3100C25E: push edi */
  14417     ecx = ebp + (-0x24); /* 0x3100C25F: lea ecx, [ebp - 0x24] */
  14418     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3100C262: mov byte ptr [ebp - 4], 1 */
  14419     MEM32(ebp + (-0x20)) = ebx; /* 0x3100C266: mov dword ptr [ebp - 0x20], ebx */
  14420     MEM32(ebp + (-0x1C)) = ebx; /* 0x3100C269: mov dword ptr [ebp - 0x1c], ebx */
  14421     MEM32(ebp + (-0x18)) = ebx; /* 0x3100C26C: mov dword ptr [ebp - 0x18], ebx */
  14422     MEM32(ebp + (-0x28)) = edi; /* 0x3100C26F: mov dword ptr [ebp - 0x28], edi */
  14423     RECOMP_ICALL(MEM32(0x31048070)); /* 0x3100C272: call dword ptr [0x31048070] */
  14424     RECOMP_FLAGS_IN();
  14425     /* test LO8(eax), LO8(eax) */ /* 0x3100C278: test al, al */
  14426     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  14427     _cf = 0;
  14428     _flag_k = FK_NARROW(FK_TEST, 24);
  14429     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C2A3; /* 0x3100C27A: je 0x3100c2a3 */
  14430 L_3100C27C:
  14431     ecx = edi; /* 0x3100C27C: mov ecx, edi */
  14432     edi = MEM32(ebp + (-0x20)); /* 0x3100C27E: mov edi, dword ptr [ebp - 0x20] */
  14433     edx = ecx; /* 0x3100C281: mov edx, ecx */
  14434     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100C283: shr ecx, 2 */
  14435     if (2u) { _flag_a = recomp_flags_pack((ecx >> 2u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14436     ecx = ecx >> 2u; /* 0x3100C283: shr ecx, 2 */
  14437     esi = 0x3105233Cu; /* 0x3100C286: mov esi, 0x3105233c */
  14438     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3100C28B: 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; }
  14439     ecx = edx; /* 0x3100C28D: mov ecx, edx */
  14440     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(3);
  14441     ecx = ecx & 3; /* 0x3100C28F: and ecx, 3 */
  14442     _cf = 0;
  14443     _flag_k = FK_TEST;
  14444     eax = edx; /* 0x3100C292: mov eax, edx */
  14445     if (ecx) { uint32_t _n = ecx, _b = _n * 1u; /* 0x3100C294: 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; }
  14446     PUSH32(esp, eax); /* 0x3100C296: push eax */
  14447     ecx = ebp + (-0x24); /* 0x3100C297: lea ecx, [ebp - 0x24] */
  14448     RECOMP_ICALL(MEM32(0x310480E8)); /* 0x3100C29A: call dword ptr [0x310480e8] */
  14449     RECOMP_FLAGS_IN();
  14450     esi = MEM32(ebp + (-0x14)); /* 0x3100C2A0: mov esi, dword ptr [ebp - 0x14] */
  14451 L_3100C2A3:
  14452     edi = MEM32(0x310482CC); /* 0x3100C2A3: mov edi, dword ptr [0x310482cc] */
  14453     ecx = ebp + (-0x24); /* 0x3100C2A9: lea ecx, [ebp - 0x24] */
  14454     PUSH32(esp, ecx); /* 0x3100C2AC: push ecx */
  14455     PUSH32(esp, 0x3105224Cu); /* 0x3100C2AD: push 0x3105224c */
  14456     ecx = ebp + (-0x68); /* 0x3100C2B2: lea ecx, [ebp - 0x68] */
  14457     MEM8(ebp + (-0x4)) = (uint8_t)(2); /* 0x3100C2B5: mov byte ptr [ebp - 4], 2 */
  14458     RECOMP_ICALL(edi); /* 0x3100C2B9: call edi */
  14459     RECOMP_FLAGS_IN();
  14460     eax = MEM32(ebp + (-0x20)); /* 0x3100C2BB: mov eax, dword ptr [ebp - 0x20] */
  14461     /* cmp eax, ebx */ /* 0x3100C2BE: cmp eax, ebx */
  14462     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  14463     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14464     _flag_k = FK_CMP;
  14465     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3100C2C0: mov byte ptr [ebp - 4], 1 */
  14466     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C2E2; /* 0x3100C2C4: je 0x3100c2e2 */
  14467 L_3100C2C6:
  14468     ecx = eax + (-0x1); /* 0x3100C2C6: lea ecx, [eax - 1] */
  14469     SET_LO8(eax, MEM8(ecx)); /* 0x3100C2C9: mov al, byte ptr [ecx] */
  14470     /* cmp LO8(eax), LO8(ebx) */ /* 0x3100C2CB: cmp al, bl */
  14471     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(ebx)) << 24;
  14472     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14473     _flag_k = FK_NARROW(FK_CMP, 24);
  14474     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C2D9; /* 0x3100C2CD: je 0x3100c2d9 */
  14475 L_3100C2CF:
  14476     /* cmp LO8(eax), 0xFFu */ /* 0x3100C2CF: cmp al, 0xff */
  14477     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
  14478     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14479     _flag_k = FK_NARROW(FK_CMP, 24);
  14480     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C2D9; /* 0x3100C2D1: je 0x3100c2d9 */
  14481 L_3100C2D3:
  14482     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
  14483     SET_LO8(eax, LO8(eax) - 1); /* 0x3100C2D3: dec al */
  14484     _flag_k = FK_NARROW(FK_DEC, 24);
  14485     MEM8(ecx) = (uint8_t)(LO8(eax)); /* 0x3100C2D5: mov byte ptr [ecx], al */
  14486     goto L_3100C2E2; /* 0x3100C2D7: jmp 0x3100c2e2 */
  14487 L_3100C2D9:
  14488     PUSH32(esp, ecx); /* 0x3100C2D9: push ecx */
  14489     RECOMP_ICALL(0x31046858u); /* 0x3100C2DA: call 0x31046858 */ /* not lifted */
  14490     RECOMP_FLAGS_IN();
  14491     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14492     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14493     esp = esp + 4; /* 0x3100C2DF: add esp, 4 */
  14494     _flag_k = FK_ADD;
  14495 L_3100C2E2:
  14496     edx = MEM32(ebp + 0x8); /* 0x3100C2E2: mov edx, dword ptr [ebp + 8] */
  14497     PUSH32(esp, edx); /* 0x3100C2E5: push edx */
  14498     PUSH32(esp, 0x31052244u); /* 0x3100C2E6: push 0x31052244 */
  14499     ecx = ebp + (-0x68); /* 0x3100C2EB: lea ecx, [ebp - 0x68] */
  14500     RECOMP_ICALL(edi); /* 0x3100C2EE: call edi */
  14501     RECOMP_FLAGS_IN();
  14502     edi = esi + 0x30; /* 0x3100C2F0: lea edi, [esi + 0x30] */
  14503 L_3100C2F3:
  14504     eax = ebp + (-0x68); /* 0x3100C2F3: lea eax, [ebp - 0x68] */
  14505     PUSH32(esp, eax); /* 0x3100C2F6: push eax */
  14506     ecx = edi; /* 0x3100C2F7: mov ecx, edi */
  14507     RECOMP_ICALL(0x31010CA0u); /* 0x3100C2F9: call 0x31010ca0 */ /* not lifted */
  14508     RECOMP_FLAGS_IN();
  14509     ecx = ebp + (-0xA8); /* 0x3100C2FE: lea ecx, [ebp - 0xa8] */
  14510     PUSH32(esp, ecx); /* 0x3100C304: push ecx */
  14511     ecx = edi; /* 0x3100C305: mov ecx, edi */
  14512     RECOMP_ICALL(0x31010F40u); /* 0x3100C307: call 0x31010f40 */ /* not lifted */
  14513     RECOMP_FLAGS_IN();
  14514     /* test LO8(eax), LO8(eax) */ /* 0x3100C30C: test al, al */
  14515     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  14516     _cf = 0;
  14517     _flag_k = FK_NARROW(FK_TEST, 24);
  14518     RECOMP_BACKEDGE();
  14519     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C2F3; /* 0x3100C30E: je 0x3100c2f3 */
  14520 L_3100C310:
  14521     PUSH32(esp, ebx); /* 0x3100C310: push ebx */
  14522     eax = esi + 0x4; /* 0x3100C311: lea eax, [esi + 4] */
  14523     PUSH32(esp, eax); /* 0x3100C314: push eax */
  14524     PUSH32(esp, 0x31052234u); /* 0x3100C315: push 0x31052234 */
  14525     ecx = ebp + (-0xA8); /* 0x3100C31A: lea ecx, [ebp - 0xa8] */
  14526     RECOMP_ICALL(MEM32(0x310482D0)); /* 0x3100C320: call dword ptr [0x310482d0] */
  14527     RECOMP_FLAGS_IN();
  14528     eax = esi + 0x23C; /* 0x3100C326: lea eax, [esi + 0x23c] */
  14529     PUSH32(esp, ebx); /* 0x3100C32C: push ebx */
  14530     PUSH32(esp, eax); /* 0x3100C32D: push eax */
  14531     PUSH32(esp, 0x3105222Cu); /* 0x3100C32E: push 0x3105222c */
  14532     ecx = ebp + (-0xA8); /* 0x3100C333: lea ecx, [ebp - 0xa8] */
  14533     MEM32(eax) = ebx; /* 0x3100C339: mov dword ptr [eax], ebx */
  14534     RECOMP_ICALL(MEM32(0x310482D4)); /* 0x3100C33B: call dword ptr [0x310482d4] */
  14535     RECOMP_FLAGS_IN();
  14536     MEM32(esi + 0x240) = ebx; /* 0x3100C341: mov dword ptr [esi + 0x240], ebx */
  14537     MEM32(ebp + (-0xA8)) = 0x3104876Cu; /* 0x3100C347: mov dword ptr [ebp - 0xa8], 0x3104876c */
  14538     edi = MEM32(0x310482F8); /* 0x3100C351: mov edi, dword ptr [0x310482f8] */
  14539     ecx = ebp + (-0xA8); /* 0x3100C357: lea ecx, [ebp - 0xa8] */
  14540     MEM8(ebp + (-0x4)) = (uint8_t)(4); /* 0x3100C35D: mov byte ptr [ebp - 4], 4 */
  14541     RECOMP_ICALL(edi); /* 0x3100C361: call edi */
  14542     RECOMP_FLAGS_IN();
  14543     edx = MEM32(ebp + (-0x74)); /* 0x3100C363: mov edx, dword ptr [ebp - 0x74] */
  14544     PUSH32(esp, edx); /* 0x3100C366: push edx */
  14545     RECOMP_ICALL(0x31046858u); /* 0x3100C367: call 0x31046858 */ /* not lifted */
  14546     RECOMP_FLAGS_IN();
  14547     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14548     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14549     esp = esp + 4; /* 0x3100C36C: add esp, 4 */
  14550     _flag_k = FK_ADD;
  14551     ecx = ebp + (-0xA4); /* 0x3100C36F: lea ecx, [ebp - 0xa4] */
  14552     MEM32(ebp + (-0x74)) = ebx; /* 0x3100C375: mov dword ptr [ebp - 0x74], ebx */
  14553     MEM32(ebp + (-0x70)) = ebx; /* 0x3100C378: mov dword ptr [ebp - 0x70], ebx */
  14554     MEM32(ebp + (-0x6C)) = ebx; /* 0x3100C37B: mov dword ptr [ebp - 0x6c], ebx */
  14555     MEM8(ebp + (-0x4)) = (uint8_t)(LO8(ebx)); /* 0x3100C37E: mov byte ptr [ebp - 4], bl */
  14556     RECOMP_ICALL(0x3100E340u); /* 0x3100C381: call 0x3100e340 */ /* not lifted */
  14557     RECOMP_FLAGS_IN();
  14558     MEM32(ebp + (-0x68)) = 0x3104876Cu; /* 0x3100C386: mov dword ptr [ebp - 0x68], 0x3104876c */
  14559     ecx = ebp + (-0x68); /* 0x3100C38D: lea ecx, [ebp - 0x68] */
  14560     MEM32(ebp + (-0x4)) = 6; /* 0x3100C390: mov dword ptr [ebp - 4], 6 */
  14561     RECOMP_ICALL(edi); /* 0x3100C397: call edi */
  14562     RECOMP_FLAGS_IN();
  14563     eax = MEM32(ebp + (-0x34)); /* 0x3100C399: mov eax, dword ptr [ebp - 0x34] */
  14564     PUSH32(esp, eax); /* 0x3100C39C: push eax */
  14565     RECOMP_ICALL(0x31046858u); /* 0x3100C39D: call 0x31046858 */ /* not lifted */
  14566     RECOMP_FLAGS_IN();
  14567     ecx = MEM32(ebp + (-0x60)); /* 0x3100C3A2: mov ecx, dword ptr [ebp - 0x60] */
  14568     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14569     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14570     esp = esp + 4; /* 0x3100C3A5: add esp, 4 */
  14571     _flag_k = FK_ADD;
  14572     PUSH32(esp, ecx); /* 0x3100C3A8: push ecx */
  14573     edx = ebp + 0x8; /* 0x3100C3A9: lea edx, [ebp + 8] */
  14574     PUSH32(esp, edx); /* 0x3100C3AC: push edx */
  14575     ecx = ebp + (-0x64); /* 0x3100C3AD: lea ecx, [ebp - 0x64] */
  14576     MEM32(ebp + (-0x34)) = ebx; /* 0x3100C3B0: mov dword ptr [ebp - 0x34], ebx */
  14577     MEM32(ebp + (-0x30)) = ebx; /* 0x3100C3B3: mov dword ptr [ebp - 0x30], ebx */
  14578     MEM32(ebp + (-0x2C)) = ebx; /* 0x3100C3B6: mov dword ptr [ebp - 0x2c], ebx */
  14579     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100C3B9: mov dword ptr [ebp - 4], 0xffffffff */
  14580     RECOMP_ICALL(0x3100E400u); /* 0x3100C3C0: call 0x3100e400 */ /* not lifted */
  14581     RECOMP_FLAGS_IN();
  14582     eax = MEM32(eax); /* 0x3100C3C5: mov eax, dword ptr [eax] */
  14583     PUSH32(esp, eax); /* 0x3100C3C7: push eax */
  14584     ecx = ebp + (-0x14); /* 0x3100C3C8: lea ecx, [ebp - 0x14] */
  14585     PUSH32(esp, ecx); /* 0x3100C3CB: push ecx */
  14586     ecx = ebp + (-0x64); /* 0x3100C3CC: lea ecx, [ebp - 0x64] */
  14587     RECOMP_ICALL(0x3100E420u); /* 0x3100C3CF: call 0x3100e420 */ /* not lifted */
  14588     RECOMP_FLAGS_IN();
  14589     edx = MEM32(ebp + (-0x60)); /* 0x3100C3D4: mov edx, dword ptr [ebp - 0x60] */
  14590     PUSH32(esp, edx); /* 0x3100C3D7: push edx */
  14591     RECOMP_ICALL(0x31046858u); /* 0x3100C3D8: call 0x31046858 */ /* not lifted */
  14592     RECOMP_FLAGS_IN();
  14593     eax = MEM32(ebp + (-0x5C)); /* 0x3100C3DD: mov eax, dword ptr [ebp - 0x5c] */
  14594     PUSH32(esp, eax); /* 0x3100C3E0: push eax */
  14595     MEM32(ebp + (-0x60)) = ebx; /* 0x3100C3E1: mov dword ptr [ebp - 0x60], ebx */
  14596     MEM32(ebp + (-0x54)) = ebx; /* 0x3100C3E4: mov dword ptr [ebp - 0x54], ebx */
  14597     RECOMP_ICALL(0x31046858u); /* 0x3100C3E7: call 0x31046858 */ /* not lifted */
  14598     RECOMP_FLAGS_IN();
  14599     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  14600     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14601     esp = esp + 8; /* 0x3100C3EC: add esp, 8 */
  14602     _flag_k = FK_ADD;
  14603 L_3100C3EF:
  14604     ecx = MEM32(ebp + (-0xC)); /* 0x3100C3EF: mov ecx, dword ptr [ebp - 0xc] */
  14605     edi = POP32_VAL(esp); /* 0x3100C3F2: pop edi */
  14606     eax = esi; /* 0x3100C3F3: mov eax, esi */
  14607     esi = POP32_VAL(esp); /* 0x3100C3F5: pop esi */
  14608     ebx = POP32_VAL(esp); /* 0x3100C3F6: pop ebx */
  14609     MEM32(FS_BASE + (0)) = ecx; /* 0x3100C3F7: mov dword ptr fs:[0], ecx */
  14610     esp = ebp; /* 0x3100C3FE: mov esp, ebp */
  14611     ebp = POP32_VAL(esp); /* 0x3100C400: pop ebp */
  14612     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100C401: ret 4 */
  14613     RECOMP_REGS_OUT();
  14614 }
  14615 
  14616 void sub_3100C410(void) {
  14617     int _fpu_cmp = 0;
  14618     uint32_t _cf = 0;
  14619     int _df = 1;
  14620     uint32_t _flag_k = FK_NONE;
  14621     uint32_t _flag_a = 0, _flag_b = 0;
  14622     uint32_t _itail_tgt = 0;
  14623     RECOMP_REGS_LOCALS
  14624     RECOMP_ENTER(0x3100C410u);
  14625 
  14626 L_3100C410:
  14627     PUSH32(esp, ebp); /* 0x3100C410: push ebp */
  14628     ebp = esp; /* 0x3100C411: mov ebp, esp */
  14629     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100C413: push -1 */
  14630     PUSH32(esp, 0x31047678u); /* 0x3100C415: push 0x31047678 */
  14631     eax = MEM32(FS_BASE + (0)); /* 0x3100C41A: mov eax, dword ptr fs:[0] */
  14632     PUSH32(esp, eax); /* 0x3100C420: push eax */
  14633     MEM32(FS_BASE + (0)) = esp; /* 0x3100C421: mov dword ptr fs:[0], esp */
  14634     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x50u);
  14635     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14636     esp = esp - 0x50u; /* 0x3100C428: sub esp, 0x50 */
  14637     _flag_k = FK_CMP;
  14638     eax = MEM32(ebp + 0xC); /* 0x3100C42B: mov eax, dword ptr [ebp + 0xc] */
  14639     PUSH32(esp, ebx); /* 0x3100C42E: push ebx */
  14640     PUSH32(esp, esi); /* 0x3100C42F: push esi */
  14641     esi = MEM32(eax); /* 0x3100C430: mov esi, dword ptr [eax] */
  14642     PUSH32(esp, edi); /* 0x3100C432: push edi */
  14643     MEM32(ebp + (-0x14)) = ecx; /* 0x3100C433: mov dword ptr [ebp - 0x14], ecx */
  14644     ecx = MEM32(ebp + 0x8); /* 0x3100C436: mov ecx, dword ptr [ebp + 8] */
  14645     edi = MEM32(ecx); /* 0x3100C439: mov edi, dword ptr [ecx] */
  14646     PUSH32(esp, 0x14u); /* 0x3100C43B: push 0x14 */
  14647     RECOMP_ICALL(0x310468DAu); /* 0x3100C43D: call 0x310468da */ /* not lifted */
  14648     RECOMP_FLAGS_IN();
  14649     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  14650     ebx = 0; /* 0x3100C442: xor ebx, ebx */
  14651     _cf = 0;
  14652     _flag_k = FK_TEST;
  14653     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14654     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14655     esp = esp + 4; /* 0x3100C444: add esp, 4 */
  14656     _flag_k = FK_ADD;
  14657     /* cmp eax, ebx */ /* 0x3100C447: cmp eax, ebx */
  14658     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  14659     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14660     _flag_k = FK_CMP;
  14661     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C466; /* 0x3100C449: je 0x3100c466 */
  14662 L_3100C44B:
  14663     ecx = eax + 0x8; /* 0x3100C44B: lea ecx, [eax + 8] */
  14664     edx = ebp + (-0x1C); /* 0x3100C44E: lea edx, [ebp - 0x1c] */
  14665     /* cmp ecx, edx */ /* 0x3100C451: cmp ecx, edx */
  14666     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(edx);
  14667     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14668     _flag_k = FK_CMP;
  14669     MEM32(eax) = ebx; /* 0x3100C453: mov dword ptr [eax], ebx */
  14670     MEM32(eax + 0x4) = ebx; /* 0x3100C455: mov dword ptr [eax + 4], ebx */
  14671     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C45F; /* 0x3100C458: je 0x3100c45f */
  14672 L_3100C45A:
  14673     MEM32(ecx) = edi; /* 0x3100C45A: mov dword ptr [ecx], edi */
  14674     MEM32(ecx + 0x4) = esi; /* 0x3100C45C: mov dword ptr [ecx + 4], esi */
  14675 L_3100C45F:
  14676     MEM32(eax + 0x10) = ebx; /* 0x3100C45F: mov dword ptr [eax + 0x10], ebx */
  14677     esi = eax; /* 0x3100C462: mov esi, eax */
  14678     goto L_3100C468; /* 0x3100C464: jmp 0x3100c468 */
  14679 L_3100C466:
  14680     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  14681     esi = 0; /* 0x3100C466: xor esi, esi */
  14682     _cf = 0;
  14683     _flag_k = FK_TEST;
  14684 L_3100C468:
  14685     _flag_a = (uint32_t)(MEM32(esi + 0x10)); _flag_b = (uint32_t)(1);
  14686     MEM32(esi + 0x10) = MEM32(esi + 0x10) + 1; /* 0x3100C468: inc dword ptr [esi + 0x10] */
  14687     _flag_k = FK_INC;
  14688     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100C46B: push -1 */
  14689     ecx = ebp + (-0x5C); /* 0x3100C46D: lea ecx, [ebp - 0x5c] */
  14690     RECOMP_ICALL(MEM32(0x310482C8)); /* 0x3100C470: call dword ptr [0x310482c8] */
  14691     RECOMP_FLAGS_IN();
  14692     edi = MEM32(ebp + (-0x14)); /* 0x3100C476: mov edi, dword ptr [ebp - 0x14] */
  14693     ecx = edi; /* 0x3100C479: mov ecx, edi */
  14694     MEM32(ebp + (-0x4)) = ebx; /* 0x3100C47B: mov dword ptr [ebp - 4], ebx */
  14695     RECOMP_ICALL(0x310013E0u); /* 0x3100C47E: call 0x310013e0 */ /* not lifted */
  14696     RECOMP_FLAGS_IN();
  14697     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(0x30u);
  14698     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14699     edi = edi + 0x30u; /* 0x3100C483: add edi, 0x30 */
  14700     _flag_k = FK_ADD;
  14701 L_3100C486:
  14702     PUSH32(esp, ebx); /* 0x3100C486: push ebx */
  14703     PUSH32(esp, esi); /* 0x3100C487: push esi */
  14704     PUSH32(esp, 0x31052358u); /* 0x3100C488: push 0x31052358 */
  14705     ecx = edi; /* 0x3100C48D: mov ecx, edi */
  14706     RECOMP_ICALL(0x31010D60u); /* 0x3100C48F: call 0x31010d60 */ /* not lifted */
  14707     RECOMP_FLAGS_IN();
  14708     eax = ebp + (-0x5C); /* 0x3100C494: lea eax, [ebp - 0x5c] */
  14709     PUSH32(esp, eax); /* 0x3100C497: push eax */
  14710     ecx = edi; /* 0x3100C498: mov ecx, edi */
  14711     RECOMP_ICALL(0x31010F40u); /* 0x3100C49A: call 0x31010f40 */ /* not lifted */
  14712     RECOMP_FLAGS_IN();
  14713     /* test LO8(eax), LO8(eax) */ /* 0x3100C49F: test al, al */
  14714     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  14715     _cf = 0;
  14716     _flag_k = FK_NARROW(FK_TEST, 24);
  14717     RECOMP_BACKEDGE();
  14718     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C486; /* 0x3100C4A1: je 0x3100c486 */
  14719 L_3100C4A3:
  14720     ecx = MEM32(ebp + (-0x14)); /* 0x3100C4A3: mov ecx, dword ptr [ebp - 0x14] */
  14721     RECOMP_ICALL(0x310013E0u); /* 0x3100C4A6: call 0x310013e0 */ /* not lifted */
  14722     RECOMP_FLAGS_IN();
  14723     _flag_a = (uint32_t)(MEM32(esi + 0x10)); _flag_b = (uint32_t)(1);
  14724     MEM32(esi + 0x10) = MEM32(esi + 0x10) - 1; /* 0x3100C4AB: dec dword ptr [esi + 0x10] */
  14725     _flag_k = FK_DEC;
  14726     if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3100C4BD; /* 0x3100C4AE: jne 0x3100c4bd */
  14727 L_3100C4B0:
  14728     /* cmp esi, ebx */ /* 0x3100C4B0: cmp esi, ebx */
  14729     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ebx);
  14730     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14731     _flag_k = FK_CMP;
  14732     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C4BD; /* 0x3100C4B2: je 0x3100c4bd */
  14733 L_3100C4B4:
  14734     PUSH32(esp, esi); /* 0x3100C4B4: push esi */
  14735     RECOMP_ICALL(0x31046858u); /* 0x3100C4B5: call 0x31046858 */ /* not lifted */
  14736     RECOMP_FLAGS_IN();
  14737     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14738     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14739     esp = esp + 4; /* 0x3100C4BA: add esp, 4 */
  14740     _flag_k = FK_ADD;
  14741 L_3100C4BD:
  14742     PUSH32(esp, ebx); /* 0x3100C4BD: push ebx */
  14743     ecx = ebp + (-0xE); /* 0x3100C4BE: lea ecx, [ebp - 0xe] */
  14744     PUSH32(esp, ecx); /* 0x3100C4C1: push ecx */
  14745     PUSH32(esp, 0x310522ECu); /* 0x3100C4C2: push 0x310522ec */
  14746     ecx = ebp + (-0x5C); /* 0x3100C4C7: lea ecx, [ebp - 0x5c] */
  14747     RECOMP_ICALL(MEM32(0x310482C0)); /* 0x3100C4CA: call dword ptr [0x310482c0] */
  14748     RECOMP_FLAGS_IN();
  14749     edx = MEM32(ebp + 0x8); /* 0x3100C4D0: mov edx, dword ptr [ebp + 8] */
  14750     esi = MEM32(0x310482D4); /* 0x3100C4D3: mov esi, dword ptr [0x310482d4] */
  14751     PUSH32(esp, ebx); /* 0x3100C4D9: push ebx */
  14752     PUSH32(esp, edx); /* 0x3100C4DA: push edx */
  14753     PUSH32(esp, 0x31052350u); /* 0x3100C4DB: push 0x31052350 */
  14754     ecx = ebp + (-0x5C); /* 0x3100C4E0: lea ecx, [ebp - 0x5c] */
  14755     RECOMP_ICALL(esi); /* 0x3100C4E3: call esi */
  14756     RECOMP_FLAGS_IN();
  14757     eax = MEM32(ebp + 0xC); /* 0x3100C4E5: mov eax, dword ptr [ebp + 0xc] */
  14758     PUSH32(esp, ebx); /* 0x3100C4E8: push ebx */
  14759     PUSH32(esp, eax); /* 0x3100C4E9: push eax */
  14760     PUSH32(esp, 0x31052348u); /* 0x3100C4EA: push 0x31052348 */
  14761     ecx = ebp + (-0x5C); /* 0x3100C4EF: lea ecx, [ebp - 0x5c] */
  14762     RECOMP_ICALL(esi); /* 0x3100C4F2: call esi */
  14763     RECOMP_FLAGS_IN();
  14764     edi = (int32_t)(int16_t)MEM16(ebp + (-0xE)); /* 0x3100C4F4: movsx edi, word ptr [ebp - 0xe] */
  14765     MEM32(ebp + (-0x5C)) = 0x3104876Cu; /* 0x3100C4F8: mov dword ptr [ebp - 0x5c], 0x3104876c */
  14766     ecx = ebp + (-0x5C); /* 0x3100C4FF: lea ecx, [ebp - 0x5c] */
  14767     MEM32(ebp + (-0x4)) = 2; /* 0x3100C502: mov dword ptr [ebp - 4], 2 */
  14768     RECOMP_ICALL(MEM32(0x310482F8)); /* 0x3100C509: call dword ptr [0x310482f8] */
  14769     RECOMP_FLAGS_IN();
  14770     ecx = MEM32(ebp + (-0x28)); /* 0x3100C50F: mov ecx, dword ptr [ebp - 0x28] */
  14771     PUSH32(esp, ecx); /* 0x3100C512: push ecx */
  14772     RECOMP_ICALL(0x31046858u); /* 0x3100C513: call 0x31046858 */ /* not lifted */
  14773     RECOMP_FLAGS_IN();
  14774     esi = MEM32(ebp + (-0x54)); /* 0x3100C518: mov esi, dword ptr [ebp - 0x54] */
  14775     ecx = MEM32(ebp + (-0x48)); /* 0x3100C51B: mov ecx, dword ptr [ebp - 0x48] */
  14776     MEM32(ebp + (-0x28)) = ebx; /* 0x3100C51E: mov dword ptr [ebp - 0x28], ebx */
  14777     MEM32(ebp + (-0x24)) = ebx; /* 0x3100C521: mov dword ptr [ebp - 0x24], ebx */
  14778     MEM32(ebp + (-0x20)) = ebx; /* 0x3100C524: mov dword ptr [ebp - 0x20], ebx */
  14779     eax = MEM32(esi); /* 0x3100C527: mov eax, dword ptr [esi] */
  14780     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14781     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14782     esp = esp + 4; /* 0x3100C529: add esp, 4 */
  14783     _flag_k = FK_ADD;
  14784     /* cmp ecx, ebx */ /* 0x3100C52C: cmp ecx, ebx */
  14785     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
  14786     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14787     _flag_k = FK_CMP;
  14788     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100C52E: mov dword ptr [ebp - 4], 0xffffffff */
  14789     MEM32(ebp + 0x8) = eax; /* 0x3100C535: mov dword ptr [ebp + 8], eax */
  14790     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C587; /* 0x3100C538: je 0x3100c587 */
  14791 L_3100C53A:
  14792     edx = ebp + 0xC; /* 0x3100C53A: lea edx, [ebp + 0xc] */
  14793     PUSH32(esp, edx); /* 0x3100C53D: push edx */
  14794     ecx = ebp + (-0x58); /* 0x3100C53E: lea ecx, [ebp - 0x58] */
  14795     RECOMP_ICALL(0x3100E400u); /* 0x3100C541: call 0x3100e400 */ /* not lifted */
  14796     RECOMP_FLAGS_IN();
  14797     ecx = eax; /* 0x3100C546: mov ecx, eax */
  14798     eax = MEM32(ebp + 0x8); /* 0x3100C548: mov eax, dword ptr [ebp + 8] */
  14799     /* cmp eax, MEM32(ecx) */ /* 0x3100C54B: cmp eax, dword ptr [ecx] */
  14800     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(MEM32(ecx));
  14801     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14802     _flag_k = FK_CMP;
  14803     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C587; /* 0x3100C54D: jne 0x3100c587 */
  14804 L_3100C54F:
  14805     ecx = MEM32(ebp + (-0x54)); /* 0x3100C54F: mov ecx, dword ptr [ebp - 0x54] */
  14806     /* cmp esi, ecx */ /* 0x3100C552: cmp esi, ecx */
  14807     _flag_a = (uint32_t)(esi); _flag_b = (uint32_t)(ecx);
  14808     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14809     _flag_k = FK_CMP;
  14810     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C587; /* 0x3100C554: jne 0x3100c587 */
  14811 L_3100C556:
  14812     edx = MEM32(ecx + 0x4); /* 0x3100C556: mov edx, dword ptr [ecx + 4] */
  14813     PUSH32(esp, edx); /* 0x3100C559: push edx */
  14814     ecx = ebp + (-0x58); /* 0x3100C55A: lea ecx, [ebp - 0x58] */
  14815     RECOMP_ICALL(0x3100E8B0u); /* 0x3100C55D: call 0x3100e8b0 */ /* not lifted */
  14816     RECOMP_FLAGS_IN();
  14817     eax = MEM32(ebp + (-0x54)); /* 0x3100C562: mov eax, dword ptr [ebp - 0x54] */
  14818     ecx = MEM32(ebp + (-0x50)); /* 0x3100C565: mov ecx, dword ptr [ebp - 0x50] */
  14819     MEM32(eax + 0x4) = ecx; /* 0x3100C568: mov dword ptr [eax + 4], ecx */
  14820     eax = MEM32(ebp + (-0x54)); /* 0x3100C56B: mov eax, dword ptr [ebp - 0x54] */
  14821     MEM32(ebp + (-0x48)) = ebx; /* 0x3100C56E: mov dword ptr [ebp - 0x48], ebx */
  14822     MEM32(eax) = eax; /* 0x3100C571: mov dword ptr [eax], eax */
  14823     eax = MEM32(ebp + (-0x54)); /* 0x3100C573: mov eax, dword ptr [ebp - 0x54] */
  14824     edx = ebp + (-0x18); /* 0x3100C576: lea edx, [ebp - 0x18] */
  14825     PUSH32(esp, edx); /* 0x3100C579: push edx */
  14826     ecx = ebp + (-0x58); /* 0x3100C57A: lea ecx, [ebp - 0x58] */
  14827     MEM32(eax + 0x8) = eax; /* 0x3100C57D: mov dword ptr [eax + 8], eax */
  14828     RECOMP_ICALL(0x3100E400u); /* 0x3100C580: call 0x3100e400 */ /* not lifted */
  14829     RECOMP_FLAGS_IN();
  14830     goto L_3100C5AC; /* 0x3100C585: jmp 0x3100c5ac */
  14831 L_3100C587:
  14832     /* cmp eax, esi */ /* 0x3100C587: cmp eax, esi */
  14833     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(esi);
  14834     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14835     _flag_k = FK_CMP;
  14836     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C5AC; /* 0x3100C589: je 0x3100c5ac */
  14837 L_3100C58B:
  14838     PUSH32(esp, ebx); /* 0x3100C58B: push ebx */
  14839     eax = ebp + 0xC; /* 0x3100C58C: lea eax, [ebp + 0xc] */
  14840     PUSH32(esp, eax); /* 0x3100C58F: push eax */
  14841     ecx = ebp + 0x8; /* 0x3100C590: lea ecx, [ebp + 8] */
  14842     RECOMP_ICALL(0x3100E900u); /* 0x3100C593: call 0x3100e900 */ /* not lifted */
  14843     RECOMP_FLAGS_IN();
  14844     ecx = MEM32(eax); /* 0x3100C598: mov ecx, dword ptr [eax] */
  14845     PUSH32(esp, ecx); /* 0x3100C59A: push ecx */
  14846     edx = ebp + (-0x14); /* 0x3100C59B: lea edx, [ebp - 0x14] */
  14847     PUSH32(esp, edx); /* 0x3100C59E: push edx */
  14848     ecx = ebp + (-0x58); /* 0x3100C59F: lea ecx, [ebp - 0x58] */
  14849     RECOMP_ICALL(0x3100E4E0u); /* 0x3100C5A2: call 0x3100e4e0 */ /* not lifted */
  14850     RECOMP_FLAGS_IN();
  14851     /* cmp MEM32(ebp + 0x8), esi */ /* 0x3100C5A7: cmp dword ptr [ebp + 8], esi */
  14852     _flag_a = (uint32_t)(MEM32(ebp + 0x8)); _flag_b = (uint32_t)(esi);
  14853     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14854     _flag_k = FK_CMP;
  14855     RECOMP_BACKEDGE();
  14856     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C58B; /* 0x3100C5AA: jne 0x3100c58b */
  14857 L_3100C5AC:
  14858     eax = MEM32(ebp + (-0x54)); /* 0x3100C5AC: mov eax, dword ptr [ebp - 0x54] */
  14859     PUSH32(esp, eax); /* 0x3100C5AF: push eax */
  14860     RECOMP_ICALL(0x31046858u); /* 0x3100C5B0: call 0x31046858 */ /* not lifted */
  14861     RECOMP_FLAGS_IN();
  14862     ecx = MEM32(ebp + (-0x50)); /* 0x3100C5B5: mov ecx, dword ptr [ebp - 0x50] */
  14863     PUSH32(esp, ecx); /* 0x3100C5B8: push ecx */
  14864     MEM32(ebp + (-0x54)) = ebx; /* 0x3100C5B9: mov dword ptr [ebp - 0x54], ebx */
  14865     MEM32(ebp + (-0x48)) = ebx; /* 0x3100C5BC: mov dword ptr [ebp - 0x48], ebx */
  14866     RECOMP_ICALL(0x31046858u); /* 0x3100C5BF: call 0x31046858 */ /* not lifted */
  14867     RECOMP_FLAGS_IN();
  14868     ecx = MEM32(ebp + (-0xC)); /* 0x3100C5C4: mov ecx, dword ptr [ebp - 0xc] */
  14869     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  14870     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14871     esp = esp + 8; /* 0x3100C5C7: add esp, 8 */
  14872     _flag_k = FK_ADD;
  14873     eax = edi; /* 0x3100C5CA: mov eax, edi */
  14874     edi = POP32_VAL(esp); /* 0x3100C5CC: pop edi */
  14875     esi = POP32_VAL(esp); /* 0x3100C5CD: pop esi */
  14876     ebx = POP32_VAL(esp); /* 0x3100C5CE: pop ebx */
  14877     MEM32(FS_BASE + (0)) = ecx; /* 0x3100C5CF: mov dword ptr fs:[0], ecx */
  14878     esp = ebp; /* 0x3100C5D6: mov esp, ebp */
  14879     ebp = POP32_VAL(esp); /* 0x3100C5D8: pop ebp */
  14880     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100C5D9: ret 8 */
  14881     RECOMP_REGS_OUT();
  14882 }
  14883 
  14884 void sub_3100C5E0(void) {
  14885     int _fpu_cmp = 0;
  14886     uint32_t _cf = 0;
  14887     int _df = 1;
  14888     uint32_t _flag_k = FK_NONE;
  14889     uint32_t _flag_a = 0, _flag_b = 0;
  14890     uint32_t _itail_tgt = 0;
  14891     RECOMP_REGS_LOCALS
  14892     RECOMP_ENTER(0x3100C5E0u);
  14893 
  14894 L_3100C5E0:
  14895     PUSH32(esp, ebp); /* 0x3100C5E0: push ebp */
  14896     ebp = esp; /* 0x3100C5E1: mov ebp, esp */
  14897     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100C5E3: push -1 */
  14898     PUSH32(esp, 0x310476BBu); /* 0x3100C5E5: push 0x310476bb */
  14899     eax = MEM32(FS_BASE + (0)); /* 0x3100C5EA: mov eax, dword ptr fs:[0] */
  14900     PUSH32(esp, eax); /* 0x3100C5F0: push eax */
  14901     MEM32(FS_BASE + (0)) = esp; /* 0x3100C5F1: mov dword ptr fs:[0], esp */
  14902     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0x5Cu);
  14903     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14904     esp = esp - 0x5Cu; /* 0x3100C5F8: sub esp, 0x5c */
  14905     _flag_k = FK_CMP;
  14906     PUSH32(esp, ebx); /* 0x3100C5FB: push ebx */
  14907     PUSH32(esp, esi); /* 0x3100C5FC: push esi */
  14908     esi = MEM32(ebp + 0xC); /* 0x3100C5FD: mov esi, dword ptr [ebp + 0xc] */
  14909     eax = MEM32(esi + 0x4); /* 0x3100C600: mov eax, dword ptr [esi + 4] */
  14910     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  14911     ebx = 0; /* 0x3100C603: xor ebx, ebx */
  14912     _cf = 0;
  14913     _flag_k = FK_TEST;
  14914     /* cmp eax, ebx */ /* 0x3100C605: cmp eax, ebx */
  14915     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  14916     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14917     _flag_k = FK_CMP;
  14918     MEM32(ebp + (-0x10)) = ecx; /* 0x3100C607: mov dword ptr [ebp - 0x10], ecx */
  14919     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C804; /* 0x3100C60A: je 0x3100c804 */
  14920 L_3100C610:
  14921     ecx = MEM32(esi + 0x8); /* 0x3100C610: mov ecx, dword ptr [esi + 8] */
  14922     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
  14923     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14924     ecx = ecx - eax; /* 0x3100C613: sub ecx, eax */
  14925     _flag_k = FK_CMP;
  14926     /* test ecx, 0xFFFFFFFCu */ /* 0x3100C615: test ecx, 0xfffffffc */
  14927     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0xFFFFFFFCu);
  14928     _cf = 0;
  14929     _flag_k = FK_TEST;
  14930     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C804; /* 0x3100C61B: je 0x3100c804 */
  14931 L_3100C621:
  14932     edx = MEM32(ebp + 0x8); /* 0x3100C621: mov edx, dword ptr [ebp + 8] */
  14933     eax = MEM32(eax); /* 0x3100C624: mov eax, dword ptr [eax] */
  14934     ecx = MEM32(edx); /* 0x3100C626: mov ecx, dword ptr [edx] */
  14935     PUSH32(esp, edi); /* 0x3100C628: push edi */
  14936     PUSH32(esp, 0x14u); /* 0x3100C629: push 0x14 */
  14937     MEM32(ebp + (-0x28)) = ecx; /* 0x3100C62B: mov dword ptr [ebp - 0x28], ecx */
  14938     MEM32(ebp + (-0x24)) = eax; /* 0x3100C62E: mov dword ptr [ebp - 0x24], eax */
  14939     RECOMP_ICALL(0x310468DAu); /* 0x3100C631: call 0x310468da */ /* not lifted */
  14940     RECOMP_FLAGS_IN();
  14941     edi = eax; /* 0x3100C636: mov edi, eax */
  14942     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  14943     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  14944     esp = esp + 4; /* 0x3100C638: add esp, 4 */
  14945     _flag_k = FK_ADD;
  14946     MEM32(ebp + (-0x20)) = edi; /* 0x3100C63B: mov dword ptr [ebp - 0x20], edi */
  14947     /* cmp edi, ebx */ /* 0x3100C63E: cmp edi, ebx */
  14948     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
  14949     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14950     _flag_k = FK_CMP;
  14951     MEM32(ebp + (-0x4)) = ebx; /* 0x3100C640: mov dword ptr [ebp - 4], ebx */
  14952     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C65B; /* 0x3100C643: je 0x3100c65b */
  14953 L_3100C645:
  14954     eax = ebp + (-0x28); /* 0x3100C645: lea eax, [ebp - 0x28] */
  14955     PUSH32(esp, eax); /* 0x3100C648: push eax */
  14956     ecx = edi + 0x8; /* 0x3100C649: lea ecx, [edi + 8] */
  14957     MEM32(edi) = ebx; /* 0x3100C64C: mov dword ptr [edi], ebx */
  14958     MEM32(edi + 0x4) = ebx; /* 0x3100C64E: mov dword ptr [edi + 4], ebx */
  14959     RECOMP_ICALL(0x31007530u); /* 0x3100C651: call 0x31007530 */ /* not lifted */
  14960     RECOMP_FLAGS_IN();
  14961     MEM32(edi + 0x10) = ebx; /* 0x3100C656: mov dword ptr [edi + 0x10], ebx */
  14962     goto L_3100C65D; /* 0x3100C659: jmp 0x3100c65d */
  14963 L_3100C65B:
  14964     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  14965     edi = 0; /* 0x3100C65B: xor edi, edi */
  14966     _cf = 0;
  14967     _flag_k = FK_TEST;
  14968 L_3100C65D:
  14969     eax = MEM32(edi + 0x10); /* 0x3100C65D: mov eax, dword ptr [edi + 0x10] */
  14970     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(1);
  14971     eax = eax + 1; /* 0x3100C660: inc eax */
  14972     _flag_k = FK_INC;
  14973     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100C661: push -1 */
  14974     ecx = ebp + (-0x68); /* 0x3100C663: lea ecx, [ebp - 0x68] */
  14975     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100C666: mov dword ptr [ebp - 4], 0xffffffff */
  14976     MEM32(edi + 0x10) = eax; /* 0x3100C66D: mov dword ptr [edi + 0x10], eax */
  14977     RECOMP_ICALL(MEM32(0x310482C8)); /* 0x3100C670: call dword ptr [0x310482c8] */
  14978     RECOMP_FLAGS_IN();
  14979     eax = MEM32(esi + 0x4); /* 0x3100C676: mov eax, dword ptr [esi + 4] */
  14980     /* cmp eax, ebx */ /* 0x3100C679: cmp eax, ebx */
  14981     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  14982     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14983     _flag_k = FK_CMP;
  14984     MEM32(ebp + (-0x4)) = 1; /* 0x3100C67B: mov dword ptr [ebp - 4], 1 */
  14985     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C689; /* 0x3100C682: jne 0x3100c689 */
  14986 L_3100C684:
  14987     MEM32(ebp + (-0x14)) = ebx; /* 0x3100C684: mov dword ptr [ebp - 0x14], ebx */
  14988     goto L_3100C694; /* 0x3100C687: jmp 0x3100c694 */
  14989 L_3100C689:
  14990     ecx = MEM32(esi + 0x8); /* 0x3100C689: mov ecx, dword ptr [esi + 8] */
  14991     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(eax);
  14992     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  14993     ecx = ecx - eax; /* 0x3100C68C: sub ecx, eax */
  14994     _flag_k = FK_CMP;
  14995     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100C68E: sar ecx, 2 */
  14996     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)ecx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  14997     ecx = (uint32_t)((int32_t)ecx >> 2u);
  14998     MEM32(ebp + (-0x14)) = ecx; /* 0x3100C691: mov dword ptr [ebp - 0x14], ecx */
  14999 L_3100C694:
  15000     PUSH32(esp, 4); /* 0x3100C694: push 4 */
  15001     edx = ebp + (-0x14); /* 0x3100C696: lea edx, [ebp - 0x14] */
  15002     PUSH32(esp, edx); /* 0x3100C699: push edx */
  15003     ecx = ebp + (-0x18); /* 0x3100C69A: lea ecx, [ebp - 0x18] */
  15004     RECOMP_ICALL(0x31004670u); /* 0x3100C69D: call 0x31004670 */ /* not lifted */
  15005     RECOMP_FLAGS_IN();
  15006     ecx = MEM32(ebp + (-0x10)); /* 0x3100C6A2: mov ecx, dword ptr [ebp - 0x10] */
  15007     MEM8(ebp + (-0x4)) = (uint8_t)(2); /* 0x3100C6A5: mov byte ptr [ebp - 4], 2 */
  15008     RECOMP_ICALL(0x310013E0u); /* 0x3100C6A9: call 0x310013e0 */ /* not lifted */
  15009     RECOMP_FLAGS_IN();
  15010 L_3100C6AE:
  15011     ecx = MEM32(ebp + (-0x10)); /* 0x3100C6AE: mov ecx, dword ptr [ebp - 0x10] */
  15012     eax = ebp + (-0x18); /* 0x3100C6B1: lea eax, [ebp - 0x18] */
  15013     PUSH32(esp, eax); /* 0x3100C6B4: push eax */
  15014     PUSH32(esp, edi); /* 0x3100C6B5: push edi */
  15015     PUSH32(esp, 0x31052360u); /* 0x3100C6B6: push 0x31052360 */
  15016     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(0x30u);
  15017     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15018     ecx = ecx + 0x30u; /* 0x3100C6BB: add ecx, 0x30 */
  15019     _flag_k = FK_ADD;
  15020     RECOMP_ICALL(0x31010D60u); /* 0x3100C6BE: call 0x31010d60 */ /* not lifted */
  15021     RECOMP_FLAGS_IN();
  15022     eax = MEM32(ebp + (-0x10)); /* 0x3100C6C3: mov eax, dword ptr [ebp - 0x10] */
  15023     edx = ebp + (-0x68); /* 0x3100C6C6: lea edx, [ebp - 0x68] */
  15024     PUSH32(esp, edx); /* 0x3100C6C9: push edx */
  15025     ecx = eax + 0x30; /* 0x3100C6CA: lea ecx, [eax + 0x30] */
  15026     RECOMP_ICALL(0x31010F40u); /* 0x3100C6CD: call 0x31010f40 */ /* not lifted */
  15027     RECOMP_FLAGS_IN();
  15028     /* test LO8(eax), LO8(eax) */ /* 0x3100C6D2: test al, al */
  15029     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  15030     _cf = 0;
  15031     _flag_k = FK_NARROW(FK_TEST, 24);
  15032     RECOMP_BACKEDGE();
  15033     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C6AE; /* 0x3100C6D4: je 0x3100c6ae */
  15034 L_3100C6D6:
  15035     ecx = MEM32(ebp + (-0x10)); /* 0x3100C6D6: mov ecx, dword ptr [ebp - 0x10] */
  15036     RECOMP_ICALL(0x310013E0u); /* 0x3100C6D9: call 0x310013e0 */ /* not lifted */
  15037     RECOMP_FLAGS_IN();
  15038     _flag_a = (uint32_t)(MEM32(edi + 0x10)); _flag_b = (uint32_t)(1);
  15039     MEM32(edi + 0x10) = MEM32(edi + 0x10) - 1; /* 0x3100C6DE: dec dword ptr [edi + 0x10] */
  15040     _flag_k = FK_DEC;
  15041     if (/* dec result */ CMP_NE(_flag_a, _flag_b)) goto L_3100C6F0; /* 0x3100C6E1: jne 0x3100c6f0 */
  15042 L_3100C6E3:
  15043     /* cmp edi, ebx */ /* 0x3100C6E3: cmp edi, ebx */
  15044     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ebx);
  15045     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15046     _flag_k = FK_CMP;
  15047     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C6F0; /* 0x3100C6E5: je 0x3100c6f0 */
  15048 L_3100C6E7:
  15049     PUSH32(esp, edi); /* 0x3100C6E7: push edi */
  15050     RECOMP_ICALL(0x31046858u); /* 0x3100C6E8: call 0x31046858 */ /* not lifted */
  15051     RECOMP_FLAGS_IN();
  15052     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  15053     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15054     esp = esp + 4; /* 0x3100C6ED: add esp, 4 */
  15055     _flag_k = FK_ADD;
  15056 L_3100C6F0:
  15057     ecx = MEM32(ebp + 0x8); /* 0x3100C6F0: mov ecx, dword ptr [ebp + 8] */
  15058     PUSH32(esp, ebx); /* 0x3100C6F3: push ebx */
  15059     PUSH32(esp, ecx); /* 0x3100C6F4: push ecx */
  15060     PUSH32(esp, 0x31052350u); /* 0x3100C6F5: push 0x31052350 */
  15061     ecx = ebp + (-0x68); /* 0x3100C6FA: lea ecx, [ebp - 0x68] */
  15062     RECOMP_ICALL(MEM32(0x310482D4)); /* 0x3100C6FD: call dword ptr [0x310482d4] */
  15063     RECOMP_FLAGS_IN();
  15064     PUSH32(esp, ebx); /* 0x3100C703: push ebx */
  15065     edx = ebp + 0xC; /* 0x3100C704: lea edx, [ebp + 0xc] */
  15066     PUSH32(esp, edx); /* 0x3100C707: push edx */
  15067     eax = ebp + (-0x1C); /* 0x3100C708: lea eax, [ebp - 0x1c] */
  15068     PUSH32(esp, eax); /* 0x3100C70B: push eax */
  15069     PUSH32(esp, 0x31052244u); /* 0x3100C70C: push 0x31052244 */
  15070     ecx = ebp + (-0x68); /* 0x3100C711: lea ecx, [ebp - 0x68] */
  15071     MEM32(ebp + 0xC) = ebx; /* 0x3100C714: mov dword ptr [ebp + 0xc], ebx */
  15072     RECOMP_ICALL(MEM32(0x310482C4)); /* 0x3100C717: call dword ptr [0x310482c4] */
  15073     RECOMP_FLAGS_IN();
  15074     eax = MEM32(ebp + 0xC); /* 0x3100C71D: mov eax, dword ptr [ebp + 0xc] */
  15075     ecx = MEM32(esi + 0x4); /* 0x3100C720: mov ecx, dword ptr [esi + 4] */
  15076     if (2u) _cf = (((eax) >> 1) & 1u); /* 0x3100C723: shr eax, 2 */
  15077     if (2u) { _flag_a = recomp_flags_pack((eax >> 2u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  15078     eax = eax >> 2u; /* 0x3100C723: shr eax, 2 */
  15079     /* cmp ecx, ebx */ /* 0x3100C726: cmp ecx, ebx */
  15080     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
  15081     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15082     _flag_k = FK_CMP;
  15083     MEM32(ebp + 0x8) = ebx; /* 0x3100C728: mov dword ptr [ebp + 8], ebx */
  15084     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C731; /* 0x3100C72B: jne 0x3100c731 */
  15085 L_3100C72D:
  15086     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  15087     edx = 0; /* 0x3100C72D: xor edx, edx */
  15088     _cf = 0;
  15089     _flag_k = FK_TEST;
  15090     goto L_3100C739; /* 0x3100C72F: jmp 0x3100c739 */
  15091 L_3100C731:
  15092     edx = MEM32(esi + 0x8); /* 0x3100C731: mov edx, dword ptr [esi + 8] */
  15093     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
  15094     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15095     edx = edx - ecx; /* 0x3100C734: sub edx, ecx */
  15096     _flag_k = FK_CMP;
  15097     if (2u) _cf = (((edx) >> 1) & 1u); /* 0x3100C736: sar edx, 2 */
  15098     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  15099     edx = (uint32_t)((int32_t)edx >> 2u);
  15100 L_3100C739:
  15101     /* cmp edx, eax */ /* 0x3100C739: cmp edx, eax */
  15102     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(eax);
  15103     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15104     _flag_k = FK_CMP;
  15105     if (CMP_AE(_flag_a, _flag_b)) goto L_3100C761; /* 0x3100C73B: jae 0x3100c761 */
  15106 L_3100C73D:
  15107     /* cmp ecx, ebx */ /* 0x3100C73D: cmp ecx, ebx */
  15108     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
  15109     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15110     _flag_k = FK_CMP;
  15111     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C745; /* 0x3100C73F: jne 0x3100c745 */
  15112 L_3100C741:
  15113     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  15114     edx = 0; /* 0x3100C741: xor edx, edx */
  15115     _cf = 0;
  15116     _flag_k = FK_TEST;
  15117     goto L_3100C74D; /* 0x3100C743: jmp 0x3100c74d */
  15118 L_3100C745:
  15119     edx = MEM32(esi + 0x8); /* 0x3100C745: mov edx, dword ptr [esi + 8] */
  15120     _flag_a = (uint32_t)(edx); _flag_b = (uint32_t)(ecx);
  15121     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15122     edx = edx - ecx; /* 0x3100C748: sub edx, ecx */
  15123     _flag_k = FK_CMP;
  15124     if (2u) _cf = (((edx) >> 1) & 1u); /* 0x3100C74A: sar edx, 2 */
  15125     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edx >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  15126     edx = (uint32_t)((int32_t)edx >> 2u);
  15127 L_3100C74D:
  15128     ecx = MEM32(esi + 0x8); /* 0x3100C74D: mov ecx, dword ptr [esi + 8] */
  15129     edi = ebp + 0x8; /* 0x3100C750: lea edi, [ebp + 8] */
  15130     PUSH32(esp, edi); /* 0x3100C753: push edi */
  15131     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edx);
  15132     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15133     eax = eax - edx; /* 0x3100C754: sub eax, edx */
  15134     _flag_k = FK_CMP;
  15135     PUSH32(esp, eax); /* 0x3100C756: push eax */
  15136     PUSH32(esp, ecx); /* 0x3100C757: push ecx */
  15137     ecx = esi; /* 0x3100C758: mov ecx, esi */
  15138     RECOMP_ICALL(0x310048B0u); /* 0x3100C75A: call 0x310048b0 */ /* not lifted */
  15139     RECOMP_FLAGS_IN();
  15140     goto L_3100C77F; /* 0x3100C75F: jmp 0x3100c77f */
  15141 L_3100C761:
  15142     /* cmp ecx, ebx */ /* 0x3100C761: cmp ecx, ebx */
  15143     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(ebx);
  15144     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15145     _flag_k = FK_CMP;
  15146     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C77F; /* 0x3100C763: je 0x3100c77f */
  15147 L_3100C765:
  15148     edx = MEM32(esi + 0x8); /* 0x3100C765: mov edx, dword ptr [esi + 8] */
  15149     edi = edx; /* 0x3100C768: mov edi, edx */
  15150     _flag_a = (uint32_t)(edi); _flag_b = (uint32_t)(ecx);
  15151     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15152     edi = edi - ecx; /* 0x3100C76A: sub edi, ecx */
  15153     _flag_k = FK_CMP;
  15154     if (2u) _cf = (((edi) >> 1) & 1u); /* 0x3100C76C: sar edi, 2 */
  15155     if (2u) { _flag_a = recomp_flags_pack(((uint32_t)((int32_t)edi >> 2u)), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  15156     edi = (uint32_t)((int32_t)edi >> 2u);
  15157     /* cmp eax, edi */ /* 0x3100C76F: cmp eax, edi */
  15158     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(edi);
  15159     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15160     _flag_k = FK_CMP;
  15161     if (CMP_AE(_flag_a, _flag_b)) goto L_3100C77F; /* 0x3100C771: jae 0x3100c77f */
  15162 L_3100C773:
  15163     ecx = ecx + eax * 4; /* 0x3100C773: lea ecx, [ecx + eax*4] */
  15164     PUSH32(esp, edx); /* 0x3100C776: push edx */
  15165     PUSH32(esp, ecx); /* 0x3100C777: push ecx */
  15166     ecx = esi; /* 0x3100C778: mov ecx, esi */
  15167     RECOMP_ICALL(0x3100E300u); /* 0x3100C77A: call 0x3100e300 */ /* not lifted */
  15168     RECOMP_FLAGS_IN();
  15169 L_3100C77F:
  15170     ecx = MEM32(ebp + 0xC); /* 0x3100C77F: mov ecx, dword ptr [ebp + 0xc] */
  15171     edi = MEM32(esi + 0x4); /* 0x3100C782: mov edi, dword ptr [esi + 4] */
  15172     esi = MEM32(ebp + (-0x1C)); /* 0x3100C785: mov esi, dword ptr [ebp - 0x1c] */
  15173     edx = ecx; /* 0x3100C788: mov edx, ecx */
  15174     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100C78A: shr ecx, 2 */
  15175     if (2u) { _flag_a = recomp_flags_pack((ecx >> 2u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  15176     ecx = ecx >> 2u; /* 0x3100C78A: shr ecx, 2 */
  15177     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3100C78D: 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; }
  15178     ecx = edx; /* 0x3100C78F: mov ecx, edx */
  15179     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(3);
  15180     ecx = ecx & 3; /* 0x3100C791: and ecx, 3 */
  15181     _cf = 0;
  15182     _flag_k = FK_TEST;
  15183     if (ecx) { uint32_t _n = ecx, _b = _n * 1u; /* 0x3100C794: 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; }
  15184     ecx = ebp + (-0x18); /* 0x3100C796: lea ecx, [ebp - 0x18] */
  15185     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3100C799: mov byte ptr [ebp - 4], 1 */
  15186     RECOMP_ICALL(0x31004760u); /* 0x3100C79D: call 0x31004760 */ /* not lifted */
  15187     RECOMP_FLAGS_IN();
  15188     MEM32(ebp + (-0x68)) = 0x3104876Cu; /* 0x3100C7A2: mov dword ptr [ebp - 0x68], 0x3104876c */
  15189     ecx = ebp + (-0x68); /* 0x3100C7A9: lea ecx, [ebp - 0x68] */
  15190     MEM32(ebp + (-0x4)) = 4; /* 0x3100C7AC: mov dword ptr [ebp - 4], 4 */
  15191     RECOMP_ICALL(MEM32(0x310482F8)); /* 0x3100C7B3: call dword ptr [0x310482f8] */
  15192     RECOMP_FLAGS_IN();
  15193     eax = MEM32(ebp + (-0x34)); /* 0x3100C7B9: mov eax, dword ptr [ebp - 0x34] */
  15194     PUSH32(esp, eax); /* 0x3100C7BC: push eax */
  15195     RECOMP_ICALL(0x31046858u); /* 0x3100C7BD: call 0x31046858 */ /* not lifted */
  15196     RECOMP_FLAGS_IN();
  15197     eax = MEM32(ebp + (-0x60)); /* 0x3100C7C2: mov eax, dword ptr [ebp - 0x60] */
  15198     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  15199     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15200     esp = esp + 4; /* 0x3100C7C5: add esp, 4 */
  15201     _flag_k = FK_ADD;
  15202     MEM32(ebp + (-0x34)) = ebx; /* 0x3100C7C8: mov dword ptr [ebp - 0x34], ebx */
  15203     MEM32(ebp + (-0x30)) = ebx; /* 0x3100C7CB: mov dword ptr [ebp - 0x30], ebx */
  15204     MEM32(ebp + (-0x2C)) = ebx; /* 0x3100C7CE: mov dword ptr [ebp - 0x2c], ebx */
  15205     ecx = MEM32(eax); /* 0x3100C7D1: mov ecx, dword ptr [eax] */
  15206     PUSH32(esp, eax); /* 0x3100C7D3: push eax */
  15207     PUSH32(esp, ecx); /* 0x3100C7D4: push ecx */
  15208     ecx = ebp + 0x8; /* 0x3100C7D5: lea ecx, [ebp + 8] */
  15209     PUSH32(esp, ecx); /* 0x3100C7D8: push ecx */
  15210     ecx = ebp + (-0x64); /* 0x3100C7D9: lea ecx, [ebp - 0x64] */
  15211     MEM32(ebp + (-0x4)) = 0xFFFFFFFFu; /* 0x3100C7DC: mov dword ptr [ebp - 4], 0xffffffff */
  15212     RECOMP_ICALL(0x3100E420u); /* 0x3100C7E3: call 0x3100e420 */ /* not lifted */
  15213     RECOMP_FLAGS_IN();
  15214     edx = MEM32(ebp + (-0x60)); /* 0x3100C7E8: mov edx, dword ptr [ebp - 0x60] */
  15215     PUSH32(esp, edx); /* 0x3100C7EB: push edx */
  15216     RECOMP_ICALL(0x31046858u); /* 0x3100C7EC: call 0x31046858 */ /* not lifted */
  15217     RECOMP_FLAGS_IN();
  15218     eax = MEM32(ebp + (-0x5C)); /* 0x3100C7F1: mov eax, dword ptr [ebp - 0x5c] */
  15219     PUSH32(esp, eax); /* 0x3100C7F4: push eax */
  15220     MEM32(ebp + (-0x60)) = ebx; /* 0x3100C7F5: mov dword ptr [ebp - 0x60], ebx */
  15221     MEM32(ebp + (-0x54)) = ebx; /* 0x3100C7F8: mov dword ptr [ebp - 0x54], ebx */
  15222     RECOMP_ICALL(0x31046858u); /* 0x3100C7FB: call 0x31046858 */ /* not lifted */
  15223     RECOMP_FLAGS_IN();
  15224     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  15225     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15226     esp = esp + 8; /* 0x3100C800: add esp, 8 */
  15227     _flag_k = FK_ADD;
  15228     edi = POP32_VAL(esp); /* 0x3100C803: pop edi */
  15229 L_3100C804:
  15230     ecx = MEM32(ebp + (-0xC)); /* 0x3100C804: mov ecx, dword ptr [ebp - 0xc] */
  15231     esi = POP32_VAL(esp); /* 0x3100C807: pop esi */
  15232     ebx = POP32_VAL(esp); /* 0x3100C808: pop ebx */
  15233     MEM32(FS_BASE + (0)) = ecx; /* 0x3100C809: mov dword ptr fs:[0], ecx */
  15234     esp = ebp; /* 0x3100C810: mov esp, ebp */
  15235     ebp = POP32_VAL(esp); /* 0x3100C812: pop ebp */
  15236     RECOMP_FLAGS_OUT(); esp += 12; { RECOMP_REGS_OUT(); return; } /* 0x3100C813: ret 8 */
  15237     RECOMP_REGS_OUT();
  15238 }
  15239 
  15240 void sub_3100C820(void) {
  15241     int _fpu_cmp = 0;
  15242     uint32_t _cf = 0;
  15243     int _df = 1;
  15244     uint32_t _flag_k = FK_NONE;
  15245     uint32_t _flag_a = 0, _flag_b = 0;
  15246     uint32_t _itail_tgt = 0;
  15247     RECOMP_REGS_LOCALS
  15248     RECOMP_ENTER(0x3100C820u);
  15249 
  15250 L_3100C820:
  15251     PUSH32(esp, ebp); /* 0x3100C820: push ebp */
  15252     ebp = esp; /* 0x3100C821: mov ebp, esp */
  15253     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100C823: push -1 */
  15254     PUSH32(esp, 0x31047733u); /* 0x3100C825: push 0x31047733 */
  15255     eax = MEM32(FS_BASE + (0)); /* 0x3100C82A: mov eax, dword ptr fs:[0] */
  15256     PUSH32(esp, eax); /* 0x3100C830: push eax */
  15257     MEM32(FS_BASE + (0)) = esp; /* 0x3100C831: mov dword ptr fs:[0], esp */
  15258     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xD0u);
  15259     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15260     esp = esp - 0xD0u; /* 0x3100C838: sub esp, 0xd0 */
  15261     _flag_k = FK_CMP;
  15262     PUSH32(esp, ebx); /* 0x3100C83E: push ebx */
  15263     PUSH32(esp, esi); /* 0x3100C83F: push esi */
  15264     PUSH32(esp, edi); /* 0x3100C840: push edi */
  15265     edi = MEM32(0x310482C8); /* 0x3100C841: mov edi, dword ptr [0x310482c8] */
  15266     esi = ecx; /* 0x3100C847: mov esi, ecx */
  15267     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100C849: push -1 */
  15268     ecx = ebp + (-0x78); /* 0x3100C84B: lea ecx, [ebp - 0x78] */
  15269     MEM32(ebp + (-0x38)) = esi; /* 0x3100C84E: mov dword ptr [ebp - 0x38], esi */
  15270     MEM32(ebp + (-0x34)) = 0; /* 0x3100C851: mov dword ptr [ebp - 0x34], 0 */
  15271     RECOMP_ICALL(edi); /* 0x3100C858: call edi */
  15272     RECOMP_FLAGS_IN();
  15273     PUSH32(esp, 0xFFFFFFFFu); /* 0x3100C85A: push -1 */
  15274     ecx = ebp + (-0xB8); /* 0x3100C85C: lea ecx, [ebp - 0xb8] */
  15275     MEM32(ebp + (-0x4)) = 1; /* 0x3100C862: mov dword ptr [ebp - 4], 1 */
  15276     RECOMP_ICALL(edi); /* 0x3100C869: call edi */
  15277     RECOMP_FLAGS_IN();
  15278     SET_LO8(eax, MEM8(ebp + 0xB)); /* 0x3100C86B: mov al, byte ptr [ebp + 0xb] */
  15279     PUSH32(esp, 0); /* 0x3100C86E: push 0 */
  15280     ecx = ebp + (-0x30); /* 0x3100C870: lea ecx, [ebp - 0x30] */
  15281     MEM8(ebp + (-0x4)) = (uint8_t)(2); /* 0x3100C873: mov byte ptr [ebp - 4], 2 */
  15282     MEM8(ebp + (-0x30)) = (uint8_t)(LO8(eax)); /* 0x3100C877: mov byte ptr [ebp - 0x30], al */
  15283     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100C87A: call dword ptr [0x310480d4] */
  15284     RECOMP_FLAGS_IN();
  15285     _flag_a = (uint32_t)((ecx | 0xFFFFFFFFu)); _flag_b = (uint32_t)((ecx | 0xFFFFFFFFu));
  15286     ecx = ecx | 0xFFFFFFFFu; /* 0x3100C880: or ecx, 0xffffffff */
  15287     _cf = 0;
  15288     _flag_k = FK_TEST;
  15289     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  15290     eax = 0; /* 0x3100C883: xor eax, eax */
  15291     _cf = 0;
  15292     _flag_k = FK_TEST;
  15293     edi = 0x310523ECu; /* 0x3100C885: mov edi, 0x310523ec */
  15294     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; } /* 0x3100C88A: repne scasb al, byte ptr es:[edi] */
  15295     ecx = ~ecx; /* 0x3100C88C: not ecx */
  15296     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(1);
  15297     ecx = ecx - 1; /* 0x3100C88E: dec ecx */
  15298     _flag_k = FK_DEC;
  15299     ebx = ecx; /* 0x3100C88F: mov ebx, ecx */
  15300     PUSH32(esp, 1); /* 0x3100C891: push 1 */
  15301     PUSH32(esp, ebx); /* 0x3100C893: push ebx */
  15302     ecx = ebp + (-0x30); /* 0x3100C894: lea ecx, [ebp - 0x30] */
  15303     RECOMP_ICALL(MEM32(0x31048070)); /* 0x3100C897: call dword ptr [0x31048070] */
  15304     RECOMP_FLAGS_IN();
  15305     /* test LO8(eax), LO8(eax) */ /* 0x3100C89D: test al, al */
  15306     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  15307     _cf = 0;
  15308     _flag_k = FK_NARROW(FK_TEST, 24);
  15309     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C8C6; /* 0x3100C89F: je 0x3100c8c6 */
  15310 L_3100C8A1:
  15311     edi = MEM32(ebp + (-0x2C)); /* 0x3100C8A1: mov edi, dword ptr [ebp - 0x2c] */
  15312     ecx = ebx; /* 0x3100C8A4: mov ecx, ebx */
  15313     edx = ecx; /* 0x3100C8A6: mov edx, ecx */
  15314     if (2u) _cf = (((ecx) >> 1) & 1u); /* 0x3100C8A8: shr ecx, 2 */
  15315     if (2u) { _flag_a = recomp_flags_pack((ecx >> 2u), _cf, 0, 0); _flag_b = 0; _flag_k = FK_EFLAGS; }
  15316     ecx = ecx >> 2u; /* 0x3100C8A8: shr ecx, 2 */
  15317     esi = 0x310523ECu; /* 0x3100C8AB: mov esi, 0x310523ec */
  15318     if (ecx) { uint32_t _n = ecx, _b = _n * 4u; /* 0x3100C8B0: 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; }
  15319     ecx = edx; /* 0x3100C8B2: mov ecx, edx */
  15320     _flag_a = (uint32_t)(ecx); _flag_b = (uint32_t)(3);
  15321     ecx = ecx & 3; /* 0x3100C8B4: and ecx, 3 */
  15322     _cf = 0;
  15323     _flag_k = FK_TEST;
  15324     if (ecx) { uint32_t _n = ecx, _b = _n * 1u; /* 0x3100C8B7: 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; }
  15325     PUSH32(esp, ebx); /* 0x3100C8B9: push ebx */
  15326     ecx = ebp + (-0x30); /* 0x3100C8BA: lea ecx, [ebp - 0x30] */
  15327     RECOMP_ICALL(MEM32(0x310480E8)); /* 0x3100C8BD: call dword ptr [0x310480e8] */
  15328     RECOMP_FLAGS_IN();
  15329     esi = MEM32(ebp + (-0x38)); /* 0x3100C8C3: mov esi, dword ptr [ebp - 0x38] */
  15330 L_3100C8C6:
  15331     eax = ebp + (-0x30); /* 0x3100C8C6: lea eax, [ebp - 0x30] */
  15332     PUSH32(esp, eax); /* 0x3100C8C9: push eax */
  15333     PUSH32(esp, 0x3105224Cu); /* 0x3100C8CA: push 0x3105224c */
  15334     ecx = ebp + (-0x78); /* 0x3100C8CF: lea ecx, [ebp - 0x78] */
  15335     MEM8(ebp + (-0x4)) = (uint8_t)(3); /* 0x3100C8D2: mov byte ptr [ebp - 4], 3 */
  15336     RECOMP_ICALL(MEM32(0x310482CC)); /* 0x3100C8D6: call dword ptr [0x310482cc] */
  15337     RECOMP_FLAGS_IN();
  15338     PUSH32(esp, 1); /* 0x3100C8DC: push 1 */
  15339     ecx = ebp + (-0x30); /* 0x3100C8DE: lea ecx, [ebp - 0x30] */
  15340     MEM8(ebp + (-0x4)) = (uint8_t)(2); /* 0x3100C8E1: mov byte ptr [ebp - 4], 2 */
  15341     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100C8E5: call dword ptr [0x310480d4] */
  15342     RECOMP_FLAGS_IN();
  15343     ecx = esi; /* 0x3100C8EB: mov ecx, esi */
  15344     RECOMP_ICALL(0x310013E0u); /* 0x3100C8ED: call 0x310013e0 */ /* not lifted */
  15345     RECOMP_FLAGS_IN();
  15346     edi = esi + 0x30; /* 0x3100C8F2: lea edi, [esi + 0x30] */
  15347 L_3100C8F5:
  15348     ecx = ebp + (-0x78); /* 0x3100C8F5: lea ecx, [ebp - 0x78] */
  15349     PUSH32(esp, ecx); /* 0x3100C8F8: push ecx */
  15350     ecx = edi; /* 0x3100C8F9: mov ecx, edi */
  15351     RECOMP_ICALL(0x31010CA0u); /* 0x3100C8FB: call 0x31010ca0 */ /* not lifted */
  15352     RECOMP_FLAGS_IN();
  15353     edx = ebp + (-0xB8); /* 0x3100C900: lea edx, [ebp - 0xb8] */
  15354     PUSH32(esp, edx); /* 0x3100C906: push edx */
  15355     ecx = edi; /* 0x3100C907: mov ecx, edi */
  15356     RECOMP_ICALL(0x31010F40u); /* 0x3100C909: call 0x31010f40 */ /* not lifted */
  15357     RECOMP_FLAGS_IN();
  15358     /* test LO8(eax), LO8(eax) */ /* 0x3100C90E: test al, al */
  15359     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  15360     _cf = 0;
  15361     _flag_k = FK_NARROW(FK_TEST, 24);
  15362     RECOMP_BACKEDGE();
  15363     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C8F5; /* 0x3100C910: je 0x3100c8f5 */
  15364 L_3100C912:
  15365     ecx = esi; /* 0x3100C912: mov ecx, esi */
  15366     RECOMP_ICALL(0x310013E0u); /* 0x3100C914: call 0x310013e0 */ /* not lifted */
  15367     RECOMP_FLAGS_IN();
  15368     SET_LO8(eax, MEM8(ebp + 0xB)); /* 0x3100C919: mov al, byte ptr [ebp + 0xb] */
  15369     _flag_a = (uint32_t)(0); _flag_b = (uint32_t)(0);
  15370     ebx = 0; /* 0x3100C91C: xor ebx, ebx */
  15371     _cf = 0;
  15372     _flag_k = FK_TEST;
  15373     PUSH32(esp, ebx); /* 0x3100C91E: push ebx */
  15374     ecx = ebp + (-0x20); /* 0x3100C91F: lea ecx, [ebp - 0x20] */
  15375     MEM8(ebp + (-0x20)) = (uint8_t)(LO8(eax)); /* 0x3100C922: mov byte ptr [ebp - 0x20], al */
  15376     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100C925: call dword ptr [0x310480d4] */
  15377     RECOMP_FLAGS_IN();
  15378     PUSH32(esp, ebx); /* 0x3100C92B: push ebx */
  15379     ecx = ebp + (-0x20); /* 0x3100C92C: lea ecx, [ebp - 0x20] */
  15380     PUSH32(esp, ecx); /* 0x3100C92F: push ecx */
  15381     PUSH32(esp, 0x310522ECu); /* 0x3100C930: push 0x310522ec */
  15382     ecx = ebp + (-0xB8); /* 0x3100C935: lea ecx, [ebp - 0xb8] */
  15383     MEM8(ebp + (-0x4)) = (uint8_t)(4); /* 0x3100C93B: mov byte ptr [ebp - 4], 4 */
  15384     RECOMP_ICALL(MEM32(0x310482D0)); /* 0x3100C93F: call dword ptr [0x310482d0] */
  15385     RECOMP_FLAGS_IN();
  15386     SET_LO8(eax, MEM8(esi + 0x244)); /* 0x3100C945: mov al, byte ptr [esi + 0x244] */
  15387     /* test LO8(eax), LO8(eax) */ /* 0x3100C94B: test al, al */
  15388     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  15389     _cf = 0;
  15390     _flag_k = FK_NARROW(FK_TEST, 24);
  15391     if (TEST_NZ(_flag_a, _flag_b)) goto L_3100C9C7; /* 0x3100C94D: jne 0x3100c9c7 */
  15392 L_3100C94F:
  15393     PUSH32(esp, 0x31052294u); /* 0x3100C94F: push 0x31052294 */
  15394     edx = ebp + (-0x20); /* 0x3100C954: lea edx, [ebp - 0x20] */
  15395     PUSH32(esp, edx); /* 0x3100C957: push edx */
  15396     eax = ebp + (-0x30); /* 0x3100C958: lea eax, [ebp - 0x30] */
  15397     PUSH32(esp, eax); /* 0x3100C95B: push eax */
  15398     RECOMP_ICALL(0x3104686Au); /* 0x3100C95C: call 0x3104686a */ /* not lifted */
  15399     RECOMP_FLAGS_IN();
  15400     eax = MEM32(eax + 0x4); /* 0x3100C961: mov eax, dword ptr [eax + 4] */
  15401     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(0xCu);
  15402     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15403     esp = esp + 0xCu; /* 0x3100C964: add esp, 0xc */
  15404     _flag_k = FK_ADD;
  15405     /* cmp eax, ebx */ /* 0x3100C967: cmp eax, ebx */
  15406     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  15407     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15408     _flag_k = FK_CMP;
  15409     if (CMP_NE(_flag_a, _flag_b)) goto L_3100C970; /* 0x3100C969: jne 0x3100c970 */
  15410 L_3100C96B:
  15411     eax = MEM32(0x310480EC); /* 0x3100C96B: mov eax, dword ptr [0x310480ec] */
  15412 L_3100C970:
  15413     ecx = ebp + (-0xDC); /* 0x3100C970: lea ecx, [ebp - 0xdc] */
  15414     PUSH32(esp, ecx); /* 0x3100C976: push ecx */
  15415     PUSH32(esp, eax); /* 0x3100C977: push eax */
  15416     RECOMP_ICALL(MEM32(0x31048230)); /* 0x3100C978: call dword ptr [0x31048230] */
  15417     RECOMP_FLAGS_IN();
  15418     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  15419     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15420     esp = esp + 8; /* 0x3100C97E: add esp, 8 */
  15421     _flag_k = FK_ADD;
  15422     /* test eax, eax */ /* 0x3100C981: test eax, eax */
  15423     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(eax);
  15424     _cf = 0;
  15425     _flag_k = FK_TEST;
  15426     eax = MEM32(ebp + (-0x2C)); /* 0x3100C983: mov eax, dword ptr [ebp - 0x2c] */
  15427     MEM8(ebp + (-0xD)) = (uint8_t)((TEST_NZ(_flag_a, _flag_b)) ? 1 : 0); /* 0x3100C986: setne byte ptr [ebp - 0xd] */
  15428     /* cmp eax, ebx */ /* 0x3100C98A: cmp eax, ebx */
  15429     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  15430     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15431     _flag_k = FK_CMP;
  15432     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C9AA; /* 0x3100C98C: je 0x3100c9aa */
  15433 L_3100C98E:
  15434     ecx = eax + (-0x1); /* 0x3100C98E: lea ecx, [eax - 1] */
  15435     SET_LO8(eax, MEM8(ecx)); /* 0x3100C991: mov al, byte ptr [ecx] */
  15436     /* test LO8(eax), LO8(eax) */ /* 0x3100C993: test al, al */
  15437     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  15438     _cf = 0;
  15439     _flag_k = FK_NARROW(FK_TEST, 24);
  15440     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C9A1; /* 0x3100C995: je 0x3100c9a1 */
  15441 L_3100C997:
  15442     /* cmp LO8(eax), 0xFFu */ /* 0x3100C997: cmp al, 0xff */
  15443     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
  15444     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15445     _flag_k = FK_NARROW(FK_CMP, 24);
  15446     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100C9A1; /* 0x3100C999: je 0x3100c9a1 */
  15447 L_3100C99B:
  15448     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
  15449     SET_LO8(eax, LO8(eax) - 1); /* 0x3100C99B: dec al */
  15450     _flag_k = FK_NARROW(FK_DEC, 24);
  15451     MEM8(ecx) = (uint8_t)(LO8(eax)); /* 0x3100C99D: mov byte ptr [ecx], al */
  15452     goto L_3100C9AA; /* 0x3100C99F: jmp 0x3100c9aa */
  15453 L_3100C9A1:
  15454     PUSH32(esp, ecx); /* 0x3100C9A1: push ecx */
  15455     RECOMP_ICALL(0x31046858u); /* 0x3100C9A2: call 0x31046858 */ /* not lifted */
  15456     RECOMP_FLAGS_IN();
  15457     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  15458     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15459     esp = esp + 4; /* 0x3100C9A7: add esp, 4 */
  15460     _flag_k = FK_ADD;
  15461 L_3100C9AA:
  15462     SET_LO8(eax, MEM8(ebp + (-0xD))); /* 0x3100C9AA: mov al, byte ptr [ebp - 0xd] */
  15463     /* test LO8(eax), LO8(eax) */ /* 0x3100C9AD: test al, al */
  15464     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  15465     _cf = 0;
  15466     _flag_k = FK_NARROW(FK_TEST, 24);
  15467     if (TEST_Z(_flag_a, _flag_b)) goto L_3100C9C7; /* 0x3100C9AF: je 0x3100c9c7 */
  15468 L_3100C9B1:
  15469     PUSH32(esp, 1); /* 0x3100C9B1: push 1 */
  15470     PUSH32(esp, 0x31052368u); /* 0x3100C9B3: push 0x31052368 */
  15471     MEM8(esi + 0x244) = (uint8_t)(1); /* 0x3100C9B8: mov byte ptr [esi + 0x244], 1 */
  15472     RECOMP_ICALL(0x310013E0u); /* 0x3100C9BF: call 0x310013e0 */ /* not lifted */
  15473     RECOMP_FLAGS_IN();
  15474     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(8);
  15475     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15476     esp = esp + 8; /* 0x3100C9C4: add esp, 8 */
  15477     _flag_k = FK_ADD;
  15478 L_3100C9C7:
  15479     edi = MEM32(ebp + 0x8); /* 0x3100C9C7: mov edi, dword ptr [ebp + 8] */
  15480     SET_LO8(edx, MEM8(ebp + (-0x20))); /* 0x3100C9CA: mov dl, byte ptr [ebp - 0x20] */
  15481     PUSH32(esp, ebx); /* 0x3100C9CD: push ebx */
  15482     ecx = edi; /* 0x3100C9CE: mov ecx, edi */
  15483     MEM8(edi) = (uint8_t)(LO8(edx)); /* 0x3100C9D0: mov byte ptr [edi], dl */
  15484     RECOMP_ICALL(MEM32(0x310480D4)); /* 0x3100C9D2: call dword ptr [0x310480d4] */
  15485     RECOMP_FLAGS_IN();
  15486     eax = MEM32(0x310480F8); /* 0x3100C9D8: mov eax, dword ptr [0x310480f8] */
  15487     ecx = MEM32(eax); /* 0x3100C9DD: mov ecx, dword ptr [eax] */
  15488     PUSH32(esp, ecx); /* 0x3100C9DF: push ecx */
  15489     PUSH32(esp, ebx); /* 0x3100C9E0: push ebx */
  15490     edx = ebp + (-0x20); /* 0x3100C9E1: lea edx, [ebp - 0x20] */
  15491     PUSH32(esp, edx); /* 0x3100C9E4: push edx */
  15492     ecx = edi; /* 0x3100C9E5: mov ecx, edi */
  15493     RECOMP_ICALL(MEM32(0x310480FC)); /* 0x3100C9E7: call dword ptr [0x310480fc] */
  15494     RECOMP_FLAGS_IN();
  15495     MEM32(ebp + (-0x34)) = 1; /* 0x3100C9ED: mov dword ptr [ebp - 0x34], 1 */
  15496     eax = MEM32(ebp + (-0x1C)); /* 0x3100C9F4: mov eax, dword ptr [ebp - 0x1c] */
  15497     /* cmp eax, ebx */ /* 0x3100C9F7: cmp eax, ebx */
  15498     _flag_a = (uint32_t)(eax); _flag_b = (uint32_t)(ebx);
  15499     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15500     _flag_k = FK_CMP;
  15501     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100CA17; /* 0x3100C9F9: je 0x3100ca17 */
  15502 L_3100C9FB:
  15503     ecx = eax + (-0x1); /* 0x3100C9FB: lea ecx, [eax - 1] */
  15504     SET_LO8(eax, MEM8(ecx)); /* 0x3100C9FE: mov al, byte ptr [ecx] */
  15505     /* test LO8(eax), LO8(eax) */ /* 0x3100CA00: test al, al */
  15506     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(LO8(eax)) << 24;
  15507     _cf = 0;
  15508     _flag_k = FK_NARROW(FK_TEST, 24);
  15509     if (TEST_Z(_flag_a, _flag_b)) goto L_3100CA0E; /* 0x3100CA02: je 0x3100ca0e */
  15510 L_3100CA04:
  15511     /* cmp LO8(eax), 0xFFu */ /* 0x3100CA04: cmp al, 0xff */
  15512     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(0xFFu) << 24;
  15513     _cf = (uint32_t)CMP_B(_flag_a, _flag_b);
  15514     _flag_k = FK_NARROW(FK_CMP, 24);
  15515     if (CMP_EQ(_flag_a, _flag_b)) goto L_3100CA0E; /* 0x3100CA06: je 0x3100ca0e */
  15516 L_3100CA08:
  15517     _flag_a = (uint32_t)(LO8(eax)) << 24; _flag_b = (uint32_t)(1) << 24;
  15518     SET_LO8(eax, LO8(eax) - 1); /* 0x3100CA08: dec al */
  15519     _flag_k = FK_NARROW(FK_DEC, 24);
  15520     MEM8(ecx) = (uint8_t)(LO8(eax)); /* 0x3100CA0A: mov byte ptr [ecx], al */
  15521     goto L_3100CA17; /* 0x3100CA0C: jmp 0x3100ca17 */
  15522 L_3100CA0E:
  15523     PUSH32(esp, ecx); /* 0x3100CA0E: push ecx */
  15524     RECOMP_ICALL(0x31046858u); /* 0x3100CA0F: call 0x31046858 */ /* not lifted */
  15525     RECOMP_FLAGS_IN();
  15526     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  15527     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15528     esp = esp + 4; /* 0x3100CA14: add esp, 4 */
  15529     _flag_k = FK_ADD;
  15530 L_3100CA17:
  15531     MEM32(ebp + (-0x1C)) = ebx; /* 0x3100CA17: mov dword ptr [ebp - 0x1c], ebx */
  15532     MEM32(ebp + (-0x18)) = ebx; /* 0x3100CA1A: mov dword ptr [ebp - 0x18], ebx */
  15533     MEM32(ebp + (-0x14)) = ebx; /* 0x3100CA1D: mov dword ptr [ebp - 0x14], ebx */
  15534     MEM32(ebp + (-0xB8)) = 0x3104876Cu; /* 0x3100CA20: mov dword ptr [ebp - 0xb8], 0x3104876c */
  15535     esi = MEM32(0x310482F8); /* 0x3100CA2A: mov esi, dword ptr [0x310482f8] */
  15536     ecx = ebp + (-0xB8); /* 0x3100CA30: lea ecx, [ebp - 0xb8] */
  15537     MEM8(ebp + (-0x4)) = (uint8_t)(6); /* 0x3100CA36: mov byte ptr [ebp - 4], 6 */
  15538     RECOMP_ICALL(esi); /* 0x3100CA3A: call esi */
  15539     RECOMP_FLAGS_IN();
  15540     eax = MEM32(ebp + (-0x84)); /* 0x3100CA3C: mov eax, dword ptr [ebp - 0x84] */
  15541     PUSH32(esp, eax); /* 0x3100CA42: push eax */
  15542     RECOMP_ICALL(0x31046858u); /* 0x3100CA43: call 0x31046858 */ /* not lifted */
  15543     RECOMP_FLAGS_IN();
  15544     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  15545     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15546     esp = esp + 4; /* 0x3100CA48: add esp, 4 */
  15547     _flag_k = FK_ADD;
  15548     ecx = ebp + (-0xB4); /* 0x3100CA4B: lea ecx, [ebp - 0xb4] */
  15549     MEM32(ebp + (-0x84)) = ebx; /* 0x3100CA51: mov dword ptr [ebp - 0x84], ebx */
  15550     MEM32(ebp + (-0x80)) = ebx; /* 0x3100CA57: mov dword ptr [ebp - 0x80], ebx */
  15551     MEM32(ebp + (-0x7C)) = ebx; /* 0x3100CA5A: mov dword ptr [ebp - 0x7c], ebx */
  15552     MEM8(ebp + (-0x4)) = (uint8_t)(1); /* 0x3100CA5D: mov byte ptr [ebp - 4], 1 */
  15553     RECOMP_ICALL(0x3100E340u); /* 0x3100CA61: call 0x3100e340 */ /* not lifted */
  15554     RECOMP_FLAGS_IN();
  15555     MEM32(ebp + (-0x78)) = 0x3104876Cu; /* 0x3100CA66: mov dword ptr [ebp - 0x78], 0x3104876c */
  15556     ecx = ebp + (-0x78); /* 0x3100CA6D: lea ecx, [ebp - 0x78] */
  15557     MEM32(ebp + (-0x4)) = 8; /* 0x3100CA70: mov dword ptr [ebp - 4], 8 */
  15558     RECOMP_ICALL(esi); /* 0x3100CA77: call esi */
  15559     RECOMP_FLAGS_IN();
  15560     ecx = MEM32(ebp + (-0x40)); /* 0x3100CA79: mov ecx, dword ptr [ebp - 0x40] */
  15561     edx = MEM32(ebp + (-0x44)); /* 0x3100CA7C: mov edx, dword ptr [ebp - 0x44] */
  15562     PUSH32(esp, ecx); /* 0x3100CA7F: push ecx */
  15563     PUSH32(esp, edx); /* 0x3100CA80: push edx */
  15564     ecx = ebp + (-0x48); /* 0x3100CA81: lea ecx, [ebp - 0x48] */
  15565     MEM8(ebp + (-0x4)) = (uint8_t)(7); /* 0x3100CA84: mov byte ptr [ebp - 4], 7 */
  15566     RECOMP_ICALL(0x3100E4D0u); /* 0x3100CA88: call 0x3100e4d0 */ /* not lifted */
  15567     RECOMP_FLAGS_IN();
  15568     eax = MEM32(ebp + (-0x44)); /* 0x3100CA8D: mov eax, dword ptr [ebp - 0x44] */
  15569     PUSH32(esp, eax); /* 0x3100CA90: push eax */
  15570     RECOMP_ICALL(0x31046858u); /* 0x3100CA91: call 0x31046858 */ /* not lifted */
  15571     RECOMP_FLAGS_IN();
  15572     _flag_a = (uint32_t)(esp); _flag_b = (uint32_t)(4);
  15573     _cf = (uint32_t)((uint32_t)(_flag_a + _flag_b) < (uint32_t)_flag_a);
  15574     esp = esp + 4; /* 0x3100CA96: add esp, 4 */
  15575     _flag_k = FK_ADD;
  15576     ecx = ebp + (-0x74); /* 0x3100CA99: lea ecx, [ebp - 0x74] */
  15577     MEM32(ebp + (-0x44)) = ebx; /* 0x3100CA9C: mov dword ptr [ebp - 0x44], ebx */
  15578     MEM32(ebp + (-0x40)) = ebx; /* 0x3100CA9F: mov dword ptr [ebp - 0x40], ebx */
  15579     MEM32(ebp + (-0x3C)) = ebx; /* 0x3100CAA2: mov dword ptr [ebp - 0x3c], ebx */
  15580     MEM8(ebp + (-0x4)) = (uint8_t)(0); /* 0x3100CAA5: mov byte ptr [ebp - 4], 0 */
  15581     RECOMP_ICALL(0x3100E340u); /* 0x3100CAA9: call 0x3100e340 */ /* not lifted */
  15582     RECOMP_FLAGS_IN();
  15583     ecx = MEM32(ebp + (-0xC)); /* 0x3100CAAE: mov ecx, dword ptr [ebp - 0xc] */
  15584     eax = edi; /* 0x3100CAB1: mov eax, edi */
  15585     edi = POP32_VAL(esp); /* 0x3100CAB3: pop edi */
  15586     esi = POP32_VAL(esp); /* 0x3100CAB4: pop esi */
  15587     ebx = POP32_VAL(esp); /* 0x3100CAB5: pop ebx */
  15588     MEM32(FS_BASE + (0)) = ecx; /* 0x3100CAB6: mov dword ptr fs:[0], ecx */
  15589     esp = ebp; /* 0x3100CABD: mov esp, ebp */
  15590     ebp = POP32_VAL(esp); /* 0x3100CABF: pop ebp */
  15591     RECOMP_FLAGS_OUT(); esp += 8; { RECOMP_REGS_OUT(); return; } /* 0x3100CAC0: ret 4 */
  15592     RECOMP_REGS_OUT();
  15593 }