// File: /workspace/github_c_makefile_star2_O0/mruby-zest[P]osc-bridge/rtosc/rtosc.c
// Function: arg_size
static unsigned arg_size(const uint8_t *arg_mem, char type)
{
    if(!has_reserved(type))
        return 0;
    const uint8_t  *arg_pos=arg_mem;
    uint32_t blob_length = 0;
    switch(type)
    {
        case 'h':
        case 't':
        case 'd':
            return 8;
        case 'm':
        case 'r':
        case 'f':
        case 'c':
        case 'i':
            return 4;
        case 'S':
        case 's':
            while(*++arg_pos);
            arg_pos += 4-(arg_pos-arg_mem)%4;
            return arg_pos-arg_mem;
        case 'b':
            blob_length |= (*arg_pos++ << 24);
            blob_length |= (*arg_pos++ << 16);
            blob_length |= (*arg_pos++ << 8);
            blob_length |= (*arg_pos++);
            if(blob_length%4)
                blob_length += 4-blob_length%4;
            arg_pos += blob_length;
            return arg_pos-arg_mem;
        default:
            assert("Invalid Type");
    }
    return -1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movb %sil, %al
movq %rdi, -0x10(%rbp)
movb %al, -0x11(%rbp)
movsbl -0x11(%rbp), %edi
callq 0xa510
cmpl $0x0, %eax
jne 0x9c9c
movl $0x0, -0x4(%rbp)
jmp 0x9e17
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movl $0x0, -0x24(%rbp)
movsbl -0x11(%rbp), %eax
addl $-0x53, %eax
movl %eax, %ecx
movq %rcx, -0x30(%rbp)
subl $0x21, %eax
ja 0x9de5
movq -0x30(%rbp), %rax
leaq 0x2e8c(%rip), %rcx      # 0xcb58
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl $0x8, -0x4(%rbp)
jmp 0x9e17
movl $0x4, -0x4(%rbp)
jmp 0x9e17
jmp 0x9cef
movq -0x20(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x20(%rbp)
cmpb $0x0, 0x1(%rax)
je 0x9d06
jmp 0x9cef
movq -0x20(%rbp), %rax
movq -0x10(%rbp), %rcx
subq %rcx, %rax
movl $0x4, %ecx
cqto
idivq %rcx
movl $0x4, %eax
subq %rdx, %rax
addq -0x20(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq -0x10(%rbp), %rcx
subq %rcx, %rax
movl %eax, -0x4(%rbp)
jmp 0x9e17
movq -0x20(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x20(%rbp)
movzbl (%rax), %eax
shll $0x18, %eax
orl -0x24(%rbp), %eax
movl %eax, -0x24(%rbp)
movq -0x20(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x20(%rbp)
movzbl (%rax), %eax
shll $0x10, %eax
orl -0x24(%rbp), %eax
movl %eax, -0x24(%rbp)
movq -0x20(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x20(%rbp)
movzbl (%rax), %eax
shll $0x8, %eax
orl -0x24(%rbp), %eax
movl %eax, -0x24(%rbp)
movq -0x20(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x20(%rbp)
movzbl (%rax), %eax
orl -0x24(%rbp), %eax
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
andl $0x3, %eax
cmpl $0x0, %eax
je 0x9dc5
movl -0x24(%rbp), %ecx
andl $0x3, %ecx
movl $0x4, %eax
subl %ecx, %eax
addl -0x24(%rbp), %eax
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq -0x10(%rbp), %rcx
subq %rcx, %rax
movl %eax, -0x4(%rbp)
jmp 0x9e17
movb $0x1, %al
testb $0x1, %al
jne 0x9ded
jmp 0x9def
jmp 0x9e0e
leaq 0x3041(%rip), %rdi      # 0xce37
leaq 0x2e8f(%rip), %rsi      # 0xcc8c
movl $0x80, %edx
leaq 0x303d(%rip), %rcx      # 0xce46
callq 0x2120
jmp 0x9e10
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq