// File: /workspace/github_cpp_makefile_star2_O1/JameyWoo[P]csmile/parse.cpp
// Function: param(TreeNode*)
TreeNode* param(TreeNode* k) {
    TreeNode* t = new TreeNode("Param");
    TreeNode* p = NULL;
    TreeNode* q = NULL;
    if (k == NULL && ptoken.type == "void") {
        p = new TreeNode("void");
        match("void");
    } else if (k == NULL && ptoken.type == "int") {
        p = new TreeNode("int");
        match("int");
    } else if (k != NULL) {
        p = k;
    }
    if (p != NULL) {
        t->child[0] = p;
        if (ptoken.type == "Id") {
            q            = new TreeNode("ParamId");
            q->name      = ptoken.value;
            q->line      = ptoken.line;
            t->child[1]  = q;
            t->child_cnt = 2;
            match("Id");
        }
        // TODO: 处理数组传参
    }
    return t;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x1b8, %rsp            # imm = 0x1B8
movq %rdi, %r14
movl $0xe0, %edi
callq 0x21b0
movq %rax, %rbx
leaq 0x70(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x109f4(%rip), %rsi     # 0x15210
leaq 0x109f2(%rip), %rdx     # 0x15215
leaq 0x60(%rsp), %rdi
callq 0x312c
leaq 0x60(%rsp), %rsi
movq %rbx, %rdi
callq 0x995c
movq 0x60(%rsp), %rdi
cmpq %r12, %rdi
je 0x4851
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x21c0
testq %r14, %r14
je 0x49a6
testq %r14, %r14
je 0x4994
movq %r14, (%rbx)
leaq 0x16c53(%rip), %rdi     # 0x1b4c0
leaq 0x109ac(%rip), %rsi     # 0x15220
callq 0x2090
testl %eax, %eax
jne 0x4994
movl $0xe0, %edi
callq 0x21b0
movq %rax, %r14
leaq 0x10(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x1097c(%rip), %rsi     # 0x1521b
leaq 0x1097c(%rip), %rdx     # 0x15222
movq %rsp, %rdi
callq 0x312c
movq %rsp, %rsi
movq %r14, %rdi
callq 0x995c
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x48cf
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x21c0
movq %r14, %rdi
addq $0xc0, %rdi
leaq 0x16c00(%rip), %rsi     # 0x1b4e0
callq 0x2100
movl 0x16c15(%rip), %eax     # 0x1b500
movl %eax, 0x50(%r14)
movq %r14, 0x8(%rbx)
movl $0x2, 0x28(%rbx)
leaq 0x90(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x10912(%rip), %rsi     # 0x15220
leaq 0x1090d(%rip), %rdx     # 0x15222
leaq 0x80(%rsp), %r14
movq %r14, %rdi
callq 0x312c
leaq 0xe0(%rsp), %rdi
movq %r14, %rsi
callq 0x46a4
leaq 0x110(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4956
movq 0x110(%rsp), %rsi
incq %rsi
callq 0x21c0
leaq 0xf0(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4977
movq 0xf0(%rsp), %rsi
incq %rsi
callq 0x21c0
movq 0x80(%rsp), %rdi
cmpq %r12, %rdi
je 0x4994
movq 0x90(%rsp), %rsi
incq %rsi
callq 0x21c0
movq %rbx, %rax
addq $0x1b8, %rsp            # imm = 0x1B8
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x16b13(%rip), %rdi     # 0x1b4c0
leaq 0x10862(%rip), %rsi     # 0x15216
callq 0x2090
testl %eax, %eax
je 0x4ab9
leaq 0x16af8(%rip), %rdi     # 0x1b4c0
leaq 0x107a5(%rip), %rsi     # 0x15174
callq 0x2090
testl %eax, %eax
jne 0x485a
movl $0xe0, %edi
callq 0x21b0
movq %rax, %r14
leaq 0x30(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x1077a(%rip), %rsi     # 0x15174
leaq 0x10776(%rip), %rdx     # 0x15177
leaq 0x20(%rsp), %rdi
callq 0x312c
leaq 0x20(%rsp), %rsi
movq %r14, %rdi
callq 0x995c
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x4a2f
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x21c0
leaq 0xb0(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x10731(%rip), %rsi     # 0x15174
leaq 0x1072d(%rip), %rdx     # 0x15177
leaq 0xa0(%rsp), %r15
movq %r15, %rdi
callq 0x312c
leaq 0x128(%rsp), %rdi
movq %r15, %rsi
callq 0x46a4
leaq 0x158(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4a8b
movq 0x158(%rsp), %rsi
incq %rsi
callq 0x21c0
leaq 0x138(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4aac
movq 0x138(%rsp), %rsi
incq %rsi
callq 0x21c0
movq 0xa0(%rsp), %rdi
jmp 0x4b91
movl $0xe0, %edi
callq 0x21b0
movq %rax, %r14
leaq 0x50(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x1073f(%rip), %rsi     # 0x15216
leaq 0x1073c(%rip), %rdx     # 0x1521a
leaq 0x40(%rsp), %rdi
callq 0x312c
leaq 0x40(%rsp), %rsi
movq %r14, %rdi
callq 0x995c
movq 0x40(%rsp), %rdi
cmpq %r12, %rdi
je 0x4b0c
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x21c0
leaq 0xd0(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x106f6(%rip), %rsi     # 0x15216
leaq 0x106f3(%rip), %rdx     # 0x1521a
leaq 0xc0(%rsp), %r15
movq %r15, %rdi
callq 0x312c
leaq 0x170(%rsp), %rdi
movq %r15, %rsi
callq 0x46a4
leaq 0x1a0(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4b68
movq 0x1a0(%rsp), %rsi
incq %rsi
callq 0x21c0
leaq 0x180(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4b89
movq 0x180(%rsp), %rsi
incq %rsi
callq 0x21c0
movq 0xc0(%rsp), %rdi
cmpq %r12, %rdi
je 0x485a
movq (%r12), %rsi
incq %rsi
callq 0x21c0
jmp 0x485a
movq %rax, %r15
movq 0xa0(%rsp), %rdi
cmpq %r12, %rdi
je 0x4c84
movq 0xb0(%rsp), %rsi
jmp 0x4c2b
movq %rax, %r15
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x4c4e
movq 0x30(%rsp), %rsi
jmp 0x4c41
jmp 0x4c4b
movq %rax, %r15
movq 0xc0(%rsp), %rdi
cmpq %r12, %rdi
je 0x4c84
movq 0xd0(%rsp), %rsi
jmp 0x4c2b
movq %rax, %r15
movq 0x40(%rsp), %rdi
cmpq %r12, %rdi
je 0x4c4e
movq 0x50(%rsp), %rsi
jmp 0x4c41
jmp 0x4c4b
movq %rax, %r15
movq 0x80(%rsp), %rdi
cmpq %r12, %rdi
je 0x4c84
movq 0x90(%rsp), %rsi
incq %rsi
jmp 0x4c7f
movq %rax, %r15
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x4c4e
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x21c0
jmp 0x4c4e
movq %rax, %r15
movl $0xe0, %esi
movq %r14, %rdi
jmp 0x4c7f
movq %rax, %r15
movq 0x60(%rsp), %rdi
cmpq %r12, %rdi
je 0x4c77
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x21c0
jmp 0x4c77
movq %rax, %r15
movl $0xe0, %esi
movq %rbx, %rdi
callq 0x21c0
movq %r15, %rdi
callq 0x2310