// File: /workspace/github_c_makefile_star2_O0/glitchub[P]evdump/evls.c
// Function: main
int main(int argc, char *argv[])
{
    for (int ev = 0; ev < 32; ev++)
    {
        char device[32];
        sprintf(device, "/dev/input/event%d", ev);
        int fd = open(device, O_RDONLY);
        if (fd < 0)
        {
            if (errno != ENOENT) die("Can't open %s: %s\n", device, strerror(errno));
            goto next;
        }

        printf("%s:\n", device);

        char name[64];
        if (ioctl(fd, EVIOCGNAME(sizeof name), name) < 0) *name = 0;
        printf("    Name \"%s\"\n", *name ? name : "Name unknown");

        int version;
        if (ioctl(fd, EVIOCGVERSION, &version))
        {
            printf("    EVIOCGVERSION failed\n");
            goto next;
        }
        else if (version != EV_VERSION)
        {
            printf("    Unexpected stack version %d\n", version);
            goto next;
        }

        struct input_id id;
        if (ioctl(fd, EVIOCGID, &id))
        {
            printf("    EVIOCGID failed\n");
            goto next;
        }
        printf("    Vendor %d\n", id.vendor);
        printf("    Product %d\n", id.product);
        printf("    Version %d\n", id.version);
        printf("    Bus type %d is %s\n", id.bustype, ed_BUS(id.bustype)?:"unknown");

        uint8_t capabilities[(EV_MAX+7)/8];
        if (ioctl(fd, EVIOCGBIT(0, sizeof capabilities), capabilities) != sizeof capabilities)
        {
            printf("    EVIOCGBIT(0) failed\n");
            goto next;
        }

        for (int bit = 1; bit < EV_MAX; bit++) // note, skip bit 0 = EV_SYN
        if (set(capabilities, bit))
        {
            printf("    Capability %d is %s\n", bit, ed_EV(bit)?:"unknown");
            switch(bit)
            {
                case EV_KEY:
                {
                    uint32_t repeat[2];
                    if (!ioctl(fd, EVIOCGREP, &repeat))
                    {
                        printf("        Repeat delay %d mS\n", repeat[0]);
                        printf("        Repeat period %d mS\n", repeat[1]);
                    }
                    uint8_t supported[(KEY_MAX+7)/8];
                    if (ioctl(fd, EVIOCGBIT(EV_KEY, sizeof(supported)), supported) == sizeof supported)
                    {
                        int8_t status[(KEY_MAX+7)/8];
                        bool valid = (ioctl(fd, EVIOCGKEY(sizeof(status)), status) == sizeof status);
                        for (int bit = 0; bit < KEY_MAX; bit++)
                            if (set(supported, bit))
                            {
                                if (valid && set(status, bit))
                                    printf("        Active key %d is %s\n", bit, ed_KEY(bit)?:ed_BTN(bit)?:"unknown");
                                else
                                    printf("        Key %d is %s\n", bit, ed_KEY(bit)?:ed_BTN(bit)?:"unknown");
                            }
                    }
                    break;
                }
                case EV_REL:
                {
                    uint8_t supported[(REL_MAX+7)/8];
                    if (ioctl(fd, EVIOCGBIT(EV_REL, sizeof supported), supported) == sizeof supported)
                        for (int bit = 0; bit < REL_MAX; bit++)
                            if (set(supported, bit))
                                printf("        Relative event %d is %s\n", bit, ed_REL(bit)?:"unknown");
                    break;
                }
                case EV_ABS:
                {
                    uint8_t supported[(ABS_MAX+7)/8];
                    if (ioctl(fd, EVIOCGBIT(EV_ABS, sizeof(supported)), supported) == sizeof supported)
                        for (int bit = 0; bit < ABS_MAX; bit++)
                            if (set(supported, bit))
                            {
                                printf("        Axis %d is %s\n", bit, ed_ABS(bit)?:"unknown");
                                struct input_absinfo i;
                                if (!ioctl(fd, EVIOCGABS(bit), &i))
                                {
                                    printf("            Value     : %d\n", i.value);
                                    printf("            Minimum   : %d\n", i.minimum);
                                    printf("            Maximum   : %d\n", i.maximum);
                                    printf("            Fuzz      : %d\n", i.fuzz);
                                    printf("            Flat      : %d\n", i.flat);
                                    printf("            Resolution: %d\n", i.resolution);
                                }
                            }
                    break;
                }
                case EV_MSC:
                {
                    uint8_t supported[(MSC_MAX+7)/8];
                    if (ioctl(fd, EVIOCGBIT(EV_MSC, sizeof supported), supported) == sizeof supported)
                        for (int bit = 0; bit < MSC_MAX; bit++)
                            if (set(supported, bit))
                                printf("        Misc event %d is %s\n", bit, ed_MSC(bit)?:"unknown");
                    break;
                }
                case EV_SW:
                {
                    uint8_t supported[(SW_MAX+7)/8];
                    if (ioctl(fd, EVIOCGBIT(EV_SW, sizeof supported), supported) == sizeof supported)
                    {
                        uint8_t status[sizeof supported];
                        bool valid = (ioctl(fd, EVIOCGSW(sizeof(status)), status) == sizeof status);
                        for (int bit = 0; bit < SW_MAX; bit++)
                            if (set(supported, bit))
                            {
                                if (valid && set(status, bit))
                                    printf("        Active switch %d is %s\n", bit, ed_SW(bit)?:"unknown");
                                else
                                    printf("        Switch %d is %s\n", bit, ed_SW(bit)?:"unknown");
                            }
                    }
                }
                case EV_LED:
                {
                    uint8_t supported[(LED_MAX+7)/8];
                    if (ioctl(fd, EVIOCGBIT(EV_LED, sizeof supported), supported) == sizeof supported)
                    {
                        uint8_t status[sizeof supported];
                        bool valid = (ioctl(fd, EVIOCGLED(sizeof(status)), status) == sizeof status);
                        for (int bit = 0; bit < LED_MAX; bit++)
                            if (set(supported, bit))
                            {
                                if (valid && set(status, bit))
                                    printf("        Active LED %d is %s\n", bit, ed_LED(bit)?:"unknown");
                                else
                                    printf("        LED %d is %s\n", bit, ed_LED(bit)?:"unknown");
                            }
                    }
                    break;
                }
                case EV_SND:
                {
                    uint8_t supported[(SND_MAX+7)/8];
                    if (ioctl(fd, EVIOCGBIT(EV_SND, sizeof supported), supported) == sizeof supported)
                    {
                        uint8_t status[sizeof supported];
                        bool valid = (ioctl(fd, EVIOCGSND(sizeof(status)), status) == sizeof status);
                        for (int bit = 0; bit < SND_MAX; bit++)
                            if (set(supported, bit))
                            {
                                if (valid && set(status, bit))
                                    printf("        Active sound %d is %s\n", bit, ed_SND(bit)?:"unknown");
                                else
                                    printf("        Sound %d is %s\n", bit, ed_SND(bit)?:"unknown");
                            }
                    }
                    break;
                }

            }
        }
        next: close(fd);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x350, %rsp            # imm = 0x350
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl $0x0, -0x14(%rbp)
cmpl $0x20, -0x14(%rbp)
jge 0x5057
leaq -0x40(%rbp), %rdi
movl -0x14(%rbp), %edx
leaq 0x580f(%rip), %rsi      # 0x9a37
movb $0x0, %al
callq 0x1090
leaq -0x40(%rbp), %rdi
xorl %esi, %esi
movb $0x0, %al
callq 0x1080
movl %eax, -0x44(%rbp)
cmpl $0x0, -0x44(%rbp)
jge 0x42a5
callq 0x1030
cmpl $0x2, (%rax)
je 0x42a0
movq 0x7da2(%rip), %rax      # 0xbff8
movq (%rax), %rax
movq %rax, -0x1e0(%rbp)
leaq -0x40(%rbp), %rax
movq %rax, -0x1d8(%rbp)
callq 0x1030
movl (%rax), %edi
callq 0x10b0
movq -0x1e0(%rbp), %rdi
movq -0x1d8(%rbp), %rdx
movq %rax, %rcx
leaq 0x57bb(%rip), %rsi      # 0x9a4a
movb $0x0, %al
callq 0x1070
movl $0x1, %edi
callq 0x10a0
jmp 0x5041
leaq -0x40(%rbp), %rsi
leaq 0x57ad(%rip), %rdi      # 0x9a5d
movb $0x0, %al
callq 0x1040
movl -0x44(%rbp), %edi
leaq -0x90(%rbp), %rdx
movl $0x80404506, %esi       # imm = 0x80404506
movb $0x0, %al
callq 0x1050
cmpl $0x0, %eax
jge 0x42d9
movb $0x0, -0x90(%rbp)
movsbl -0x90(%rbp), %eax
cmpl $0x0, %eax
je 0x42f5
leaq -0x90(%rbp), %rax
movq %rax, -0x1e8(%rbp)
jmp 0x4305
leaq 0x5775(%rip), %rax      # 0x9a71
movq %rax, -0x1e8(%rbp)
jmp 0x4305
movq -0x1e8(%rbp), %rsi
leaq 0x574f(%rip), %rdi      # 0x9a62
movb $0x0, %al
callq 0x1040
movl -0x44(%rbp), %edi
movl $0x80044501, %esi       # imm = 0x80044501
leaq -0x94(%rbp), %rdx
movb $0x0, %al
callq 0x1050
cmpl $0x0, %eax
je 0x4348
leaq 0x5742(%rip), %rdi      # 0x9a7e
movb $0x0, %al
callq 0x1040
jmp 0x5041
cmpl $0x10001, -0x94(%rbp)   # imm = 0x10001
je 0x436d
movl -0x94(%rbp), %esi
leaq 0x5737(%rip), %rdi      # 0x9a98
movb $0x0, %al
callq 0x1040
jmp 0x5041
jmp 0x436f
movl -0x44(%rbp), %edi
movl $0x80084502, %esi       # imm = 0x80084502
leaq -0x9c(%rbp), %rdx
movb $0x0, %al
callq 0x1050
cmpl $0x0, %eax
je 0x439d
leaq 0x5728(%rip), %rdi      # 0x9ab9
movb $0x0, %al
callq 0x1040
jmp 0x5041
movzwl -0x9a(%rbp), %esi
leaq 0x5723(%rip), %rdi      # 0x9ace
movb $0x0, %al
callq 0x1040
movzwl -0x98(%rbp), %esi
leaq 0x571d(%rip), %rdi      # 0x9add
movb $0x0, %al
callq 0x1040
movzwl -0x96(%rbp), %esi
leaq 0x5718(%rip), %rdi      # 0x9aed
movb $0x0, %al
callq 0x1040
movzwl -0x9c(%rbp), %eax
movl %eax, -0x1f4(%rbp)
movzwl -0x9c(%rbp), %edi
callq 0x4020
movq %rax, -0x1f0(%rbp)
cmpq $0x0, %rax
je 0x4412
movq -0x1f0(%rbp), %rax
movq %rax, -0x200(%rbp)
jmp 0x4422
leaq 0x565d(%rip), %rax      # 0x9a76
movq %rax, -0x200(%rbp)
jmp 0x4422
movl -0x1f4(%rbp), %esi
movq -0x200(%rbp), %rdx
leaq 0x56c7(%rip), %rdi      # 0x9afd
movb $0x0, %al
callq 0x1040
movl -0x44(%rbp), %edi
leaq -0xa0(%rbp), %rdx
movl $0x80044520, %esi       # imm = 0x80044520
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x4, %rax
je 0x446e
leaq 0x56b2(%rip), %rdi      # 0x9b14
movb $0x0, %al
callq 0x1040
jmp 0x5041
movl $0x1, -0xa4(%rbp)
cmpl $0x1f, -0xa4(%rbp)
jge 0x503f
movl -0xa4(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0xa0(%rbp,%rax), %eax
movl -0xa4(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x5029
movl -0xa4(%rbp), %eax
movl %eax, -0x20c(%rbp)
movl -0xa4(%rbp), %edi
callq 0x11c0
movq %rax, -0x208(%rbp)
cmpq $0x0, %rax
je 0x44ee
movq -0x208(%rbp), %rax
movq %rax, -0x218(%rbp)
jmp 0x44fe
leaq 0x5581(%rip), %rax      # 0x9a76
movq %rax, -0x218(%rbp)
jmp 0x44fe
movl -0x20c(%rbp), %esi
movq -0x218(%rbp), %rdx
leaq 0x561b(%rip), %rdi      # 0x9b2d
xorl %eax, %eax
callq 0x1040
movl -0xa4(%rbp), %eax
decl %eax
movl %eax, %ecx
movq %rcx, -0x220(%rbp)
subl $0x11, %eax
ja 0x5027
movq -0x220(%rbp), %rax
leaq 0x31a3(%rip), %rcx      # 0x76e4
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl -0x44(%rbp), %edi
movl $0x80084503, %esi       # imm = 0x80084503
leaq -0xac(%rbp), %rdx
movb $0x0, %al
callq 0x1050
cmpl $0x0, %eax
jne 0x458d
movl -0xac(%rbp), %esi
leaq 0x55d4(%rip), %rdi      # 0x9b46
movb $0x0, %al
callq 0x1040
movl -0xa8(%rbp), %esi
leaq 0x55dc(%rip), %rdi      # 0x9b62
movb $0x0, %al
callq 0x1040
movl -0x44(%rbp), %edi
leaq -0x110(%rbp), %rdx
movl $0x80604521, %esi       # imm = 0x80604521
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x60, %rax
jne 0x47b0
movl -0x44(%rbp), %edi
leaq -0x170(%rbp), %rdx
movl $0x80604518, %esi       # imm = 0x80604518
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x60, %rax
sete %al
andb $0x1, %al
movb %al, -0x171(%rbp)
movl $0x0, -0x178(%rbp)
cmpl $0x2ff, -0x178(%rbp)    # imm = 0x2FF
jge 0x47ae
movl -0x178(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0x110(%rbp,%rax), %eax
movl -0x178(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x4798
testb $0x1, -0x171(%rbp)
je 0x4701
movl -0x178(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movsbl -0x170(%rbp,%rax), %eax
movl -0x178(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x4701
movl -0x178(%rbp), %eax
movl %eax, -0x22c(%rbp)
movl -0x178(%rbp), %edi
callq 0x1330
movq %rax, -0x228(%rbp)
cmpq $0x0, %rax
je 0x469b
movq -0x228(%rbp), %rax
movq %rax, -0x238(%rbp)
jmp 0x46e1
movl -0x178(%rbp), %edi
callq 0x31f0
movq %rax, -0x240(%rbp)
cmpq $0x0, %rax
je 0x46c3
movq -0x240(%rbp), %rax
movq %rax, -0x248(%rbp)
jmp 0x46d3
leaq 0x53ac(%rip), %rax      # 0x9a76
movq %rax, -0x248(%rbp)
jmp 0x46d3
movq -0x248(%rbp), %rax
movq %rax, -0x238(%rbp)
movl -0x22c(%rbp), %esi
movq -0x238(%rbp), %rdx
leaq 0x548a(%rip), %rdi      # 0x9b7f
movb $0x0, %al
callq 0x1040
jmp 0x4796
movl -0x178(%rbp), %eax
movl %eax, -0x254(%rbp)
movl -0x178(%rbp), %edi
callq 0x1330
movq %rax, -0x250(%rbp)
cmpq $0x0, %rax
je 0x4735
movq -0x250(%rbp), %rax
movq %rax, -0x260(%rbp)
jmp 0x477b
movl -0x178(%rbp), %edi
callq 0x31f0
movq %rax, -0x268(%rbp)
cmpq $0x0, %rax
je 0x475d
movq -0x268(%rbp), %rax
movq %rax, -0x270(%rbp)
jmp 0x476d
leaq 0x5312(%rip), %rax      # 0x9a76
movq %rax, -0x270(%rbp)
jmp 0x476d
movq -0x270(%rbp), %rax
movq %rax, -0x260(%rbp)
movl -0x254(%rbp), %esi
movq -0x260(%rbp), %rdx
leaq 0x540d(%rip), %rdi      # 0x9b9c
movb $0x0, %al
callq 0x1040
jmp 0x4798
jmp 0x479a
movl -0x178(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x178(%rbp)
jmp 0x45e0
jmp 0x47b0
jmp 0x5027
movl -0x44(%rbp), %edi
leaq -0x17a(%rbp), %rdx
movl $0x80024522, %esi       # imm = 0x80024522
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x2, %rax
jne 0x4896
movl $0x0, -0x180(%rbp)
cmpl $0xf, -0x180(%rbp)
jge 0x4894
movl -0x180(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0x17a(%rbp,%rax), %eax
movl -0x180(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x487e
movl -0x180(%rbp), %eax
movl %eax, -0x27c(%rbp)
movl -0x180(%rbp), %edi
callq 0x38e0
movq %rax, -0x278(%rbp)
cmpq $0x0, %rax
je 0x4853
movq -0x278(%rbp), %rax
movq %rax, -0x288(%rbp)
jmp 0x4863
leaq 0x521c(%rip), %rax      # 0x9a76
movq %rax, -0x288(%rbp)
jmp 0x4863
movl -0x27c(%rbp), %esi
movq -0x288(%rbp), %rdx
leaq 0x533b(%rip), %rdi      # 0x9bb2
movb $0x0, %al
callq 0x1040
jmp 0x4880
movl -0x180(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x180(%rbp)
jmp 0x47e1
jmp 0x4896
jmp 0x5027
movl -0x44(%rbp), %edi
leaq -0x188(%rbp), %rdx
movl $0x80084523, %esi       # imm = 0x80084523
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x8, %rax
jne 0x4a2c
movl $0x0, -0x18c(%rbp)
cmpl $0x3f, -0x18c(%rbp)
jge 0x4a2a
movl -0x18c(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0x188(%rbp,%rax), %eax
movl -0x18c(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x4a14
movl -0x18c(%rbp), %eax
movl %eax, -0x294(%rbp)
movl -0x18c(%rbp), %edi
callq 0x39e0
movq %rax, -0x290(%rbp)
cmpq $0x0, %rax
je 0x493d
movq -0x290(%rbp), %rax
movq %rax, -0x2a0(%rbp)
jmp 0x494d
leaq 0x5132(%rip), %rax      # 0x9a76
movq %rax, -0x2a0(%rbp)
jmp 0x494d
movl -0x294(%rbp), %esi
movq -0x2a0(%rbp), %rdx
leaq 0x5272(%rip), %rdi      # 0x9bd3
movb $0x0, %al
callq 0x1040
movl -0x44(%rbp), %edi
movl -0x18c(%rbp), %eax
addl $0x40, %eax
shll $0x0, %eax
orl $0x80004500, %eax       # imm = 0x80004500
movl %eax, %eax
movl %eax, %esi
orq $0x180000, %rsi         # imm = 0x180000
leaq -0x1a4(%rbp), %rdx
movb $0x0, %al
callq 0x1050
cmpl $0x0, %eax
jne 0x4a12
movl -0x1a4(%rbp), %esi
leaq 0x5243(%rip), %rdi      # 0x9bea
movb $0x0, %al
callq 0x1040
movl -0x1a0(%rbp), %esi
leaq 0x524b(%rip), %rdi      # 0x9c06
movb $0x0, %al
callq 0x1040
movl -0x19c(%rbp), %esi
leaq 0x5253(%rip), %rdi      # 0x9c22
movb $0x0, %al
callq 0x1040
movl -0x198(%rbp), %esi
leaq 0x525b(%rip), %rdi      # 0x9c3e
movb $0x0, %al
callq 0x1040
movl -0x194(%rbp), %esi
leaq 0x5263(%rip), %rdi      # 0x9c5a
movb $0x0, %al
callq 0x1040
movl -0x190(%rbp), %esi
leaq 0x526b(%rip), %rdi      # 0x9c76
movb $0x0, %al
callq 0x1040
jmp 0x4a14
jmp 0x4a16
movl -0x18c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18c(%rbp)
jmp 0x48c7
jmp 0x4a2c
jmp 0x5027
movl -0x44(%rbp), %edi
leaq -0x1a5(%rbp), %rdx
movl $0x80014524, %esi       # imm = 0x80014524
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x1, %rax
jne 0x4b12
movl $0x0, -0x1ac(%rbp)
cmpl $0x7, -0x1ac(%rbp)
jge 0x4b10
movl -0x1ac(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0x1a5(%rbp,%rax), %eax
movl -0x1ac(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x4afa
movl -0x1ac(%rbp), %eax
movl %eax, -0x2ac(%rbp)
movl -0x1ac(%rbp), %edi
callq 0x3de0
movq %rax, -0x2a8(%rbp)
cmpq $0x0, %rax
je 0x4acf
movq -0x2a8(%rbp), %rax
movq %rax, -0x2b8(%rbp)
jmp 0x4adf
leaq 0x4fa0(%rip), %rax      # 0x9a76
movq %rax, -0x2b8(%rbp)
jmp 0x4adf
movl -0x2ac(%rbp), %esi
movq -0x2b8(%rbp), %rdx
leaq 0x519f(%rip), %rdi      # 0x9c92
movb $0x0, %al
callq 0x1040
jmp 0x4afc
movl -0x1ac(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1ac(%rbp)
jmp 0x4a5d
jmp 0x4b12
jmp 0x5027
movl -0x44(%rbp), %edi
leaq -0x1ae(%rbp), %rdx
movl $0x80024525, %esi       # imm = 0x80024525
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x2, %rax
jne 0x4cc4
movl -0x44(%rbp), %edi
leaq -0x1b0(%rbp), %rdx
movl $0x8002451b, %esi       # imm = 0x8002451B
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x2, %rax
sete %al
andb $0x1, %al
movb %al, -0x1b1(%rbp)
movl $0x0, -0x1b8(%rbp)
cmpl $0x10, -0x1b8(%rbp)
jge 0x4cc2
movl -0x1b8(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0x1ae(%rbp,%rax), %eax
movl -0x1b8(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x4cac
testb $0x1, -0x1b1(%rbp)
je 0x4c4b
movl -0x1b8(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0x1b0(%rbp,%rax), %eax
movl -0x1b8(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x4c4b
movl -0x1b8(%rbp), %eax
movl %eax, -0x2c4(%rbp)
movl -0x1b8(%rbp), %edi
callq 0x3cb0
movq %rax, -0x2c0(%rbp)
cmpq $0x0, %rax
je 0x4c1e
movq -0x2c0(%rbp), %rax
movq %rax, -0x2d0(%rbp)
jmp 0x4c2e
leaq 0x4e51(%rip), %rax      # 0x9a76
movq %rax, -0x2d0(%rbp)
jmp 0x4c2e
movl -0x2c4(%rbp), %esi
movq -0x2d0(%rbp), %rdx
leaq 0x506d(%rip), %rdi      # 0x9caf
movb $0x0, %al
callq 0x1040
jmp 0x4caa
movl -0x1b8(%rbp), %eax
movl %eax, -0x2dc(%rbp)
movl -0x1b8(%rbp), %edi
callq 0x3cb0
movq %rax, -0x2d8(%rbp)
cmpq $0x0, %rax
je 0x4c7f
movq -0x2d8(%rbp), %rax
movq %rax, -0x2e8(%rbp)
jmp 0x4c8f
leaq 0x4df0(%rip), %rax      # 0x9a76
movq %rax, -0x2e8(%rbp)
jmp 0x4c8f
movl -0x2dc(%rbp), %esi
movq -0x2e8(%rbp), %rdx
leaq 0x502c(%rip), %rdi      # 0x9ccf
movb $0x0, %al
callq 0x1040
jmp 0x4cac
jmp 0x4cae
movl -0x1b8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1b8(%rbp)
jmp 0x4b6a
jmp 0x4cc4
jmp 0x4cc6
movl -0x44(%rbp), %edi
leaq -0x1ba(%rbp), %rdx
movl $0x80024531, %esi       # imm = 0x80024531
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x2, %rax
jne 0x4e73
movl -0x44(%rbp), %edi
leaq -0x1bc(%rbp), %rdx
movl $0x80024519, %esi       # imm = 0x80024519
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x2, %rax
sete %al
andb $0x1, %al
movb %al, -0x1bd(%rbp)
movl $0x0, -0x1c4(%rbp)
cmpl $0xf, -0x1c4(%rbp)
jge 0x4e71
movl -0x1c4(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0x1ba(%rbp,%rax), %eax
movl -0x1c4(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x4e5b
testb $0x1, -0x1bd(%rbp)
je 0x4dfa
movl -0x1c4(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0x1bc(%rbp,%rax), %eax
movl -0x1c4(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x4dfa
movl -0x1c4(%rbp), %eax
movl %eax, -0x2f4(%rbp)
movl -0x1c4(%rbp), %edi
callq 0x3e80
movq %rax, -0x2f0(%rbp)
cmpq $0x0, %rax
je 0x4dcd
movq -0x2f0(%rbp), %rax
movq %rax, -0x300(%rbp)
jmp 0x4ddd
leaq 0x4ca2(%rip), %rax      # 0x9a76
movq %rax, -0x300(%rbp)
jmp 0x4ddd
movl -0x2f4(%rbp), %esi
movq -0x300(%rbp), %rdx
leaq 0x4ef7(%rip), %rdi      # 0x9ce8
movb $0x0, %al
callq 0x1040
jmp 0x4e59
movl -0x1c4(%rbp), %eax
movl %eax, -0x30c(%rbp)
movl -0x1c4(%rbp), %edi
callq 0x3e80
movq %rax, -0x308(%rbp)
cmpq $0x0, %rax
je 0x4e2e
movq -0x308(%rbp), %rax
movq %rax, -0x318(%rbp)
jmp 0x4e3e
leaq 0x4c41(%rip), %rax      # 0x9a76
movq %rax, -0x318(%rbp)
jmp 0x4e3e
movl -0x30c(%rbp), %esi
movq -0x318(%rbp), %rdx
leaq 0x4eb3(%rip), %rdi      # 0x9d05
movb $0x0, %al
callq 0x1040
jmp 0x4e5b
jmp 0x4e5d
movl -0x1c4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c4(%rbp)
jmp 0x4d19
jmp 0x4e73
jmp 0x5027
movl -0x44(%rbp), %edi
leaq -0x1c5(%rbp), %rdx
movl $0x80014532, %esi       # imm = 0x80014532
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x1, %rax
jne 0x5025
movl -0x44(%rbp), %edi
leaq -0x1c6(%rbp), %rdx
movl $0x8001451a, %esi       # imm = 0x8001451A
movb $0x0, %al
callq 0x1050
cltq
cmpq $0x1, %rax
sete %al
andb $0x1, %al
movb %al, -0x1c7(%rbp)
movl $0x0, -0x1cc(%rbp)
cmpl $0x7, -0x1cc(%rbp)
jge 0x5023
movl -0x1cc(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0x1c5(%rbp,%rax), %eax
movl -0x1cc(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x500d
testb $0x1, -0x1c7(%rbp)
je 0x4fac
movl -0x1cc(%rbp), %eax
movl $0x8, %ecx
cltd
idivl %ecx
cltq
movzbl -0x1c6(%rbp,%rax), %eax
movl -0x1cc(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
andl %ecx, %eax
cmpl $0x0, %eax
je 0x4fac
movl -0x1cc(%rbp), %eax
movl %eax, -0x324(%rbp)
movl -0x1cc(%rbp), %edi
callq 0x3fb0
movq %rax, -0x320(%rbp)
cmpq $0x0, %rax
je 0x4f7f
movq -0x320(%rbp), %rax
movq %rax, -0x330(%rbp)
jmp 0x4f8f
leaq 0x4af0(%rip), %rax      # 0x9a76
movq %rax, -0x330(%rbp)
jmp 0x4f8f
movl -0x324(%rbp), %esi
movq -0x330(%rbp), %rdx
leaq 0x4d78(%rip), %rdi      # 0x9d1b
movb $0x0, %al
callq 0x1040
jmp 0x500b
movl -0x1cc(%rbp), %eax
movl %eax, -0x33c(%rbp)
movl -0x1cc(%rbp), %edi
callq 0x3fb0
movq %rax, -0x338(%rbp)
cmpq $0x0, %rax
je 0x4fe0
movq -0x338(%rbp), %rax
movq %rax, -0x348(%rbp)
jmp 0x4ff0
leaq 0x4a8f(%rip), %rax      # 0x9a76
movq %rax, -0x348(%rbp)
jmp 0x4ff0
movl -0x33c(%rbp), %esi
movq -0x348(%rbp), %rdx
leaq 0x4d36(%rip), %rdi      # 0x9d3a
movb $0x0, %al
callq 0x1040
jmp 0x500d
jmp 0x500f
movl -0x1cc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1cc(%rbp)
jmp 0x4ecb
jmp 0x5025
jmp 0x5027
jmp 0x5029
jmp 0x502b
movl -0xa4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xa4(%rbp)
jmp 0x4478
jmp 0x5041
movl -0x44(%rbp), %edi
callq 0x1060
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x4210
movl -0x4(%rbp), %eax
addq $0x350, %rsp            # imm = 0x350
popq %rbp
retq