// File: /workspace/github_c_makefile_star2_O3/lecram[P]congif/main.c
// Function: main
int
main(int argc, char *argv[])
{
    int opt;
    int ret;

    set_defaults();
    options.has_winsize = 0;
    if (ioctl(0, TIOCGWINSZ, &options.size) != -1) {
        options.has_winsize = 1;
    }
    while ((opt = getopt(argc, argv, "o:m:d:l:f:h:w:c:p:qv")) != -1) {
        switch (opt) {
        case 'o':
            options.output = optarg;
            break;
        case 'm':
            options.maxdelay = atof(optarg);
            break;
        case 'd':
            options.divisor = atof(optarg);
            break;
        case 'l':
            options.loop = atoi(optarg);
            break;
        case 'f':
            options.font = optarg;
            break;
        case 'h':
            options.height = atoi(optarg);
            break;
        case 'w':
            options.width = atoi(optarg);
            break;
        case 'c':
            if (!strcmp(optarg, "on") || !strcmp(optarg, "1"))
                options.cursor = 1;
            else if (!strcmp(optarg, "off") || !strcmp(optarg, "0"))
                options.cursor = 0;
            break;
        case 'q':
            options.quiet = 1;
            break;
        case 'v':
            set_verbosity(1);
            break;
        case 'p':
            set_default_palette(optarg);
            break;
        default:
            help(argv[0]);
            return 1;
        }
    }
    if (optind >= argc - 1) {
        fprintf(stderr, "error: no input given\n");
        help(argv[0]);
        return 1;
    }
    options.timings = argv[optind++];
    options.dialogue = argv[optind++];
    if (!options.quiet && options.has_winsize)
        options.barsize = options.size.ws_col - 1;
    ret = convert_script();
    return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movl %edi, %ebp
leaq 0x1e76(%rip), %rax      # 0x5df8
movq %rax, 0x83ff(%rip)      # 0xc388
movsd 0x1a9f(%rip), %xmm0     # 0x5a30
movsd %xmm0, 0x83f7(%rip)     # 0xc390
movl $0xffffffff, 0x83f5(%rip) # imm = 0xFFFFFFFF
xorl %eax, %eax
movq %rax, 0x83f4(%rip)      # 0xc3a0
movaps 0x1a8d(%rip), %xmm0     # 0x5a40
movups %xmm0, 0x83ee(%rip)     # 0xc3a8
movq %rax, 0x83f7(%rip)      # 0xc3b8
leaq 0x83f8(%rip), %rdx      # 0xc3c0
movl $0x5413, %esi           # imm = 0x5413
xorl %edi, %edi
xorl %eax, %eax
callq 0x10d0
cmpl $-0x1, %eax
je 0x3fe5
movl $0x1, 0x83d7(%rip)      # 0xc3bc
leaq 0x1e14(%rip), %r14      # 0x5e00
leaq 0x1a5d(%rip), %r13      # 0x5a50
movl %ebp, %edi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x11d0
leal -0x63(%rax), %ecx
cmpl $0x14, %ecx
ja 0x419c
movslq (%r13,%rcx,4), %rax
addq %r13, %rax
jmpq *%rax
movq 0x3fb3(%rip), %rax      # 0x7fd0
movq (%rax), %r12
movzbl (%r12), %r15d
cmpl $0x31, %r15d
je 0x415f
cmpl $0x6f, %r15d
jne 0x4049
cmpb $0x6e, 0x1(%r12)
jne 0x4049
cmpb $0x0, 0x2(%r12)
je 0x418d
movq %r12, %rdi
leaq 0x1dc2(%rip), %rsi      # 0x5e15
callq 0x1120
testl %eax, %eax
je 0x417e
cmpb $0x30, %r15b
jne 0x3ff3
cmpb $0x0, 0x1(%r12)
jne 0x3ff3
jmp 0x417e
movq 0x3f56(%rip), %rax      # 0x7fd0
movq (%rax), %rdi
callq 0x11c0
movl %eax, 0x8324(%rip)      # 0xc3ac
jmp 0x3ff3
movq 0x3f3c(%rip), %rax      # 0x7fd0
movq (%rax), %rdi
callq 0x1070
cvtsd2ss %xmm0, %xmm0
movss %xmm0, 0x82e8(%rip)     # 0xc390
jmp 0x3ff3
movq 0x3f1c(%rip), %rax      # 0x7fd0
movq (%rax), %rdi
callq 0x11c0
movl %eax, 0x82d6(%rip)      # 0xc398
jmp 0x3ff3
movl $0x1, %edi
callq 0x14dc
jmp 0x3ff3
movq 0x3ef3(%rip), %rax      # 0x7fd0
movq (%rax), %rax
movq %rax, 0x82b9(%rip)      # 0xc3a0
jmp 0x3ff3
movq 0x3edd(%rip), %rax      # 0x7fd0
movq (%rax), %rdi
callq 0x1070
cvtsd2ss %xmm0, %xmm0
movss %xmm0, 0x828d(%rip)     # 0xc394
jmp 0x3ff3
movq 0x3ebd(%rip), %rax      # 0x7fd0
movq (%rax), %rdi
callq 0x14e3
jmp 0x3ff3
movq 0x3ea9(%rip), %rax      # 0x7fd0
movq (%rax), %rdi
callq 0x11c0
movl %eax, 0x8273(%rip)      # 0xc3a8
jmp 0x3ff3
movl $0x1, 0x8270(%rip)      # 0xc3b4
jmp 0x3ff3
movq 0x3e80(%rip), %rax      # 0x7fd0
movq (%rax), %rax
movq %rax, 0x822e(%rip)      # 0xc388
jmp 0x3ff3
cmpb $0x0, 0x1(%r12)
je 0x418d
movq %r12, %rdi
leaq 0x1ca4(%rip), %rsi      # 0x5e15
callq 0x1120
testl %eax, %eax
jne 0x3ff3
movl $0x0, 0x8228(%rip)      # 0xc3b0
jmp 0x3ff3
movl $0x1, 0x8219(%rip)      # 0xc3b0
jmp 0x3ff3
cmpl $-0x1, %eax
jne 0x4201
movq 0x3e20(%rip), %rax      # 0x7fc8
movslq (%rax), %rcx
decl %ebp
cmpl %ebp, %ecx
jge 0x420b
movq (%rbx,%rcx,8), %rdx
movq %rdx, 0x81bc(%rip)      # 0xc378
leal 0x2(%rcx), %edx
movl %edx, (%rax)
movq 0x8(%rbx,%rcx,8), %rax
movq %rax, 0x81b3(%rip)      # 0xc380
cmpl $0x0, 0x81e0(%rip)      # 0xc3b4
jne 0x41ee
cmpl $0x0, 0x81df(%rip)      # 0xc3bc
je 0x41ee
movzwl 0x81dc(%rip), %eax      # 0xc3c2
decl %eax
movl %eax, 0x81ca(%rip)      # 0xc3b8
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x397f
movq %rbx, %rdi
callq 0x13c7
jmp 0x4213
movq %rbx, %rdi
callq 0x1389
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq