// File: /workspace/github_c_makefile_star2_O3/wjmelements[P]evm/src/disassemble.c
// Function: disassembleNextOp
void disassembleNextOp(const char **iter) {
    disassembleWaste(iter);
    op_t op = hexString16ToUint8(*iter);
    *iter += 2;
    if (op >= PUSH1 && op <= PUSH32) {
        pc++;
        disassemblePush(op, iter);
        return;
    }
    statement_t op_statement;
    if (op == JUMPDEST) {
        pcs_append(&jumpdests, pc);
        op_statement = labelForPc(pc);
    } else {
        size_t bufLen = 15;
        char *str = calloc(bufLen, 1);
        char *end = stpncpy(str, opString[op], bufLen);
        size_t strLen = end - str;
        op_statement = (statement_t){
            strLen,
            str,
            bufLen
        };
    }
    int argc = argCount[op];
    if (argc && argc <= stack.num_statements) {
        statement_append(&op_statement, '(');
        while (argc--) {
            statement_t arg = statement_stack_pop(&stack);
            for (size_t i = 0; i < arg.num_schars; i++) {
                statement_append(&op_statement,arg.schars[i]);
            }
            free(arg.schars);
            if (argc) {
                statement_append(&op_statement,',');
            }
        }
        statement_append(&op_statement, ')');
    }
    statement_stack_append(&stack, op_statement);
    if (retCount[op] != 1) {
        for (size_t i = 0; i < stack.num_statements; i++) {
            puts(stack.statements[i].schars);
            free(stack.statements[i].schars);
        }
        stack.num_statements = 0;
    }
    pc++;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
callq 0x1169d
movq (%rbx), %r14
movzbl (%r14), %ecx
leal -0x30(%rcx), %ebp
cmpb $0xa, %bpl
jb 0x10fb6
leal -0x61(%rcx), %eax
cmpb $0x5, %al
ja 0x10fa6
addb $-0x57, %cl
jmp 0x10fb4
leal -0x41(%rcx), %eax
cmpb $0x5, %al
ja 0x1165a
addb $-0x37, %cl
movl %ecx, %ebp
movzbl 0x1(%r14), %ecx
leal -0x30(%rcx), %eax
cmpb $0xa, %al
jb 0x10fde
leal -0x61(%rcx), %eax
cmpb $0x5, %al
ja 0x10fce
addb $-0x57, %cl
jmp 0x10fdc
leal -0x41(%rcx), %eax
cmpb $0x5, %al
ja 0x1167c
addb $-0x37, %cl
movl %ecx, %eax
shlb $0x4, %bpl
addb %al, %bpl
addq $0x2, (%rbx)
cmpb $0x60, %bpl
jl 0x110e4
movl 0x204fa56(%rip), %r12d  # 0x2060a50
leal 0x1(%r12), %eax
movl %eax, 0x204fa4b(%rip)   # 0x2060a50
addb $-0x5f, %bpl
cmpb $0x3, %bpl
ja 0x1119d
movq 0x6fde(%rip), %r15      # 0x17ff8
leaq 0x118a(%rip), %r14      # 0x121ab
xorl %r12d, %r12d
movq %rbx, %rdi
callq 0x1169d
shlq $0x4, %r12
movq (%rbx), %rax
cmpb $0x0, (%rax)
je 0x11067
leaq 0x1(%rax), %rcx
movq %rcx, (%rbx)
movzbl (%rax), %ecx
leal -0x30(%rcx), %eax
cmpb $0xa, %al
jb 0x11061
leal -0x61(%rcx), %eax
cmpb $0x5, %al
ja 0x11055
addb $-0x57, %cl
jmp 0x1105f
leal -0x41(%rcx), %eax
cmpb $0x5, %al
ja 0x110be
addb $-0x37, %cl
movl %ecx, %eax
movzbl %al, %eax
addq %rax, %r12
movq %rbx, %rdi
callq 0x1169d
shlq $0x4, %r12
movq (%rbx), %rax
cmpb $0x0, (%rax)
je 0x110aa
leaq 0x1(%rax), %rcx
movq %rcx, (%rbx)
movzbl (%rax), %ecx
leal -0x30(%rcx), %eax
cmpb $0xa, %al
jb 0x110a4
leal -0x61(%rcx), %eax
cmpb $0x5, %al
ja 0x11098
addb $-0x57, %cl
jmp 0x110a2
leal -0x41(%rcx), %eax
cmpb $0x5, %al
ja 0x110d1
addb $-0x37, %cl
movl %ecx, %eax
movzbl %al, %eax
addq %rax, %r12
incl 0x204f9a0(%rip)         # 0x2060a50
decb %bpl
jne 0x11024
jmp 0x112a8
movq (%r15), %rdi
movq %r14, %rsi
movl %ecx, %edx
xorl %eax, %eax
callq 0x31d0
movb $-0x1, %al
jmp 0x11061
movq (%r15), %rdi
movq %r14, %rsi
movl %ecx, %edx
xorl %eax, %eax
callq 0x31d0
movb $-0x1, %al
jmp 0x110a4
cmpb $0x5b, %bpl
jne 0x1135e
movl 0x204f95c(%rip), %ebp   # 0x2060a50
movq 0x204f95d(%rip), %rax   # 0x2060a58
movq 0x204f966(%rip), %r14   # 0x2060a68
movq 0x204f957(%rip), %rbx   # 0x2060a60
cmpq %r14, %rax
jb 0x11151
leaq (%r14,%r14), %rdi
movq %rdi, 0x204f94f(%rip)   # 0x2060a68
movl $0x4, %esi
callq 0x31b0
movq %rax, %r15
shlq $0x2, %r14
movq %rax, %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x31f0
movq %rbx, %rdi
callq 0x3040
movq %r15, 0x204f919(%rip)   # 0x2060a60
movq 0x204f90a(%rip), %rax   # 0x2060a58
movq %r15, %rbx
leaq 0x1(%rax), %rcx
movq %rcx, 0x204f8fc(%rip)   # 0x2060a58
movl %ebp, (%rbx,%rax,4)
movl $0x8, %r15d
movl $0x8, %edi
movl $0x1, %esi
callq 0x31b0
movq %rax, %rbx
leaq 0x3305(%rip), %rdx      # 0x14483
movl $0x8, %esi
movq %rax, %rdi
movl %ebp, %ecx
xorl %eax, %eax
callq 0x3110
movslq %eax, %rbp
movl $0x5b, %r13d
jmp 0x11398
leal (,%rbp,2), %eax
addb $0x2, %al
movzbl %al, %edi
movl $0x1, %esi
movq %rdi, 0x8(%rsp)
callq 0x31b0
movq %rax, %r15
movw $0x7830, (%rax)         # imm = 0x7830
addl $0x2, %r12d
movb $0x3, %r13b
movq %rbx, %rdi
callq 0x1169d
movq (%rbx), %rcx
movb $0x30, %r14b
cmpb $0x0, (%rcx)
movb $0x30, %al
je 0x111e5
leaq 0x1(%rcx), %rax
movq %rax, (%rbx)
movb (%rcx), %al
leal -0x1(%r13), %ecx
movzbl %cl, %ecx
movb %al, (%r15,%rcx)
movq %rbx, %rdi
callq 0x1169d
movq (%rbx), %rax
cmpb $0x0, (%rax)
je 0x1120a
leaq 0x1(%rax), %rcx
movq %rcx, (%rbx)
movb (%rax), %r14b
movzbl %r13b, %eax
movb %r14b, (%r15,%rax)
addb $0x2, %r13b
movl %r12d, 0x204f833(%rip)  # 0x2060a50
leal 0x1(%r12), %eax
movl %eax, %r12d
decb %bpl
jne 0x111c7
movq 0x204f83f(%rip), %rax   # 0x2060a70
movq 0x204f848(%rip), %r14   # 0x2060a80
movq 0x204f839(%rip), %rbx   # 0x2060a78
cmpq %r14, %rax
jb 0x11288
leaq (%r14,%r14), %rdi
movq %rdi, 0x204f831(%rip)   # 0x2060a80
movl $0x18, %esi
callq 0x31b0
movq %rax, %r12
shlq $0x3, %r14
leaq (%r14,%r14,2), %rdx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x31f0
movq %rbx, %rdi
callq 0x3040
movq %r12, 0x204f7fa(%rip)   # 0x2060a78
movq 0x204f7eb(%rip), %rax   # 0x2060a70
movq %r12, %rbx
movq 0x8(%rsp), %rbp
leaq 0x1(%rax), %rcx
movq %rcx, 0x204f7d8(%rip)   # 0x2060a70
leaq (%rax,%rax,2), %rax
leaq (%rbx,%rax,8), %rax
movq %rbp, (%rax)
jmp 0x11351
movl $0x14, %ebp
movl $0x14, %edi
movl $0x1, %esi
callq 0x31b0
movq %rax, %r15
leaq 0x17aa(%rip), %rdx      # 0x12a70
movl $0x14, %esi
movq %rax, %rdi
movq %r12, %rcx
xorl %eax, %eax
callq 0x3110
movl %eax, %ebx
movq 0x204f78f(%rip), %rax   # 0x2060a70
movq 0x204f798(%rip), %r14   # 0x2060a80
movq 0x204f789(%rip), %r12   # 0x2060a78
cmpq %r14, %rax
jb 0x11338
leaq (%r14,%r14), %rdi
movq %rdi, 0x204f781(%rip)   # 0x2060a80
movl $0x18, %esi
callq 0x31b0
movq %rax, %r13
shlq $0x3, %r14
leaq (%r14,%r14,2), %rdx
movq %rax, %rdi
movq %r12, %rsi
callq 0x31f0
movq %r12, %rdi
callq 0x3040
movq %r13, 0x204f74a(%rip)   # 0x2060a78
movq 0x204f73b(%rip), %rax   # 0x2060a70
movq %r13, %r12
movslq %ebx, %rcx
leaq 0x1(%rax), %rdx
movq %rdx, 0x204f72a(%rip)   # 0x2060a70
leaq (%rax,%rax,2), %rax
leaq (%r12,%rax,8), %rax
movq %rcx, (%rax)
movq %r15, 0x8(%rax)
movq %rbp, 0x10(%rax)
jmp 0x1164b
movl $0xf, %r15d
movl $0xf, %edi
movl $0x1, %esi
callq 0x31b0
movq %rax, %rbx
movzbl %bpl, %r13d
leaq 0x6e6f(%rip), %rax      # 0x181f0
movq (%rax,%r13,8), %rsi
movl $0xf, %edx
movq %rbx, %rdi
callq 0x3220
movq %rax, %rbp
subq %rbx, %rbp
leaq 0x1b41(%rip), %rax      # 0x12ee0
movb (%rax,%r13), %al
movzbl %al, %esi
testb %sil, %sil
sete %cl
movq 0x204f6bd(%rip), %rax   # 0x2060a70
cmpq %rsi, %rax
setb %dl
orb %cl, %dl
jne 0x11560
cmpq %r15, %rbp
movq %rsi, 0x18(%rsp)
jb 0x113fb
leal (%r15,%r15), %r12d
movl $0x1, %esi
movq %r12, %rdi
callq 0x31b0
movq %rbx, %r14
movq %rax, %rbx
movq %rax, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x31f0
movq %r14, %rdi
callq 0x3040
movq %r12, %r15
movq %r13, 0x10(%rsp)
movb $0x28, (%rbx,%rbp)
incq %rbp
movq 0x204f66a(%rip), %rax   # 0x2060a78
movq 0x204f65b(%rip), %rcx   # 0x2060a70
decq %rcx
movq %rcx, 0x204f651(%rip)   # 0x2060a70
leaq (%rcx,%rcx,2), %rcx
movq (%rax,%rcx,8), %r12
movq 0x8(%rax,%rcx,8), %r13
movq %r13, 0x20(%rsp)
testq %r12, %r12
je 0x11495
movb (%r13), %r14b
cmpq %r15, %rbp
jb 0x11486
movq %rbp, 0x8(%rsp)
leaq (%r15,%r15), %rbp
movl $0x1, %esi
movq %rbp, %rdi
callq 0x31b0
movq %r15, %rdx
movq %rax, %r15
movabsq $0x7fffffffffffffff, %rax # imm = 0x7FFFFFFFFFFFFFFF
andq %rax, %rdx
movq %r15, %rdi
movq %rbx, %rsi
callq 0x31f0
movq %rbx, %rdi
callq 0x3040
movq %r15, %rbx
movq %rbp, %r15
movq 0x8(%rsp), %rbp
movb %r14b, (%rbx,%rbp)
incq %rbp
incq %r13
decq %r12
jne 0x11436
movq 0x18(%rsp), %r14
decl %r14d
movq 0x20(%rsp), %rdi
callq 0x3040
testl %r14d, %r14d
je 0x11505
cmpq %r15, %rbp
movq %r14, 0x18(%rsp)
jb 0x114fc
movq %rbx, %r14
leaq (%r15,%r15), %rbx
movl $0x1, %esi
movq %rbx, %rdi
callq 0x31b0
movq %rbp, %r12
movq %rax, %rbp
movabsq $0x7fffffffffffffff, %rax # imm = 0x7FFFFFFFFFFFFFFF
andq %rax, %r15
movq %rbp, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x31f0
movq %r14, %rdi
callq 0x3040
movq %rbx, %r15
movq %rbp, %rbx
movq %r12, %rbp
movb $0x2c, (%rbx,%rbp)
jmp 0x11404
cmpq %r15, %rbp
jb 0x1154d
movq %rbx, %r14
leaq (%r15,%r15), %rbx
movl $0x1, %esi
movq %rbx, %rdi
callq 0x31b0
movq %rbp, %r12
movq %rax, %rbp
movabsq $0x7fffffffffffffff, %rdx # imm = 0x7FFFFFFFFFFFFFFF
andq %r15, %rdx
movq %rax, %rdi
movq %r14, %rsi
callq 0x31f0
movq %r14, %rdi
callq 0x3040
movq %rbx, %r15
movq %rbp, %rbx
movq %r12, %rbp
movq 0x10(%rsp), %r13
movb $0x29, (%rbx,%rbp)
incq %rbp
movq 0x204f510(%rip), %rax   # 0x2060a70
movq 0x204f519(%rip), %r14   # 0x2060a80
movq 0x204f50a(%rip), %r12   # 0x2060a78
cmpq %r14, %rax
jb 0x115cd
leaq (%r14,%r14), %rdi
movq %rdi, 0x204f502(%rip)   # 0x2060a80
movl $0x18, %esi
callq 0x31b0
movq %rbp, 0x8(%rsp)
movq %r15, %rbp
movq %rbx, %r15
movq %rax, %rbx
shlq $0x3, %r14
leaq (%r14,%r14,2), %rdx
movq %rax, %rdi
movq %r12, %rsi
callq 0x31f0
movq %r12, %rdi
callq 0x3040
movq %rbx, 0x204f4c0(%rip)   # 0x2060a78
movq 0x204f4b1(%rip), %rax   # 0x2060a70
movq %rbx, %r12
movq %r15, %rbx
movq %rbp, %r15
movq 0x8(%rsp), %rbp
leaq 0x1(%rax), %rcx
movq %rcx, 0x204f498(%rip)   # 0x2060a70
leaq (%rax,%rax,2), %rax
movq %rbp, (%r12,%rax,8)
movq %rbx, 0x8(%r12,%rax,8)
movq %r15, 0x10(%r12,%rax,8)
leaq 0x19ef(%rip), %rax      # 0x12fe0
cmpb $0x1, (%rax,%r13)
je 0x11645
cmpq $0x0, 0x204f470(%rip)   # 0x2060a70
je 0x1163a
movl $0x8, %ebx
xorl %r14d, %r14d
movq 0x204f467(%rip), %rax   # 0x2060a78
movq (%rax,%rbx), %rdi
callq 0x30a0
movq 0x204f457(%rip), %rax   # 0x2060a78
movq (%rax,%rbx), %rdi
callq 0x3040
incq %r14
addq $0x18, %rbx
cmpq 0x204f438(%rip), %r14   # 0x2060a70
jb 0x1160a
movq $0x0, 0x204f42b(%rip) # 0x2060a70
incl 0x204f405(%rip)         # 0x2060a50
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x6997(%rip), %rax      # 0x17ff8
movq (%rax), %rdi
leaq 0xb40(%rip), %rsi       # 0x121ab
movl %ecx, %edx
xorl %eax, %eax
callq 0x31d0
movb $-0x1, %bpl
jmp 0x10fb6
movq 0x6975(%rip), %rax      # 0x17ff8
movq (%rax), %rdi
leaq 0xb1e(%rip), %rsi       # 0x121ab
movl %ecx, %edx
xorl %eax, %eax
callq 0x31d0
movb $-0x1, %al
jmp 0x10fde