// File: /workspace/github_cpp_makefile_star2_O2/cjxgm[P]libgpp/src/libgpp.cpp
// Function: (anonymous namespace)::Preprocessor::splice_possible_user(int*, int*, int*, int*, int*, int*, int*, int, int*, int)
int splice_possible_user(int *idstart, int *idend, int *sh_end, int *lg_end,
                int *argb, int *arge, int *argc, int idcheck, int *id, int cmtmode) {
            int match, k, pos;

            if (!match_start_sequence(S->user.macro_start, idstart))
                return 0;
            *idend = identifier_end(*idstart);
            if ((*idend) && !get_char(*idend - 1))
                return 0;

            // look for args or no args
            *sh_end = *idend;
            if (!match_end_sequence(S->user.macro_end, sh_end))
                *sh_end = -1;
            pos = *idend;
            match = match_sequence(S->user.macro_arg_start, &pos);

            if (idcheck) {
                *id = find_ident(C->buf + *idstart, *idend - *idstart);
                if (*id < 0)
                    match = 0;
            }
            *lg_end = -1;

            if (match) {
                *argc = 0;
                while (1) {
                    if (*argc >= max_arg_count)
                        bug("too many macro parameters");
                    argb[*argc] = pos;
                    k = 0;
                    while (1) { // look for macro_arg_end, macro_arg_sep, or comment-start
                        pos = iter_identifier_end(pos);
                        skip_possible_comments(&pos, cmtmode, 0);
                        if (get_char(pos) == 0)
                            return (*sh_end >= 0); // EOF
                        if (strchr(S->user.stackchar, get_char(pos)))
                            k++;
                        if (k) {
                            if (strchr(S->user.unstackchar, get_char(pos)))
                                k--;
                        } else {
                            arge[*argc] = pos;
                            if (match_sequence(S->user.macro_arg_sep, &pos)) {
                                match = 0;
                                break;
                            }
                            if (match_end_sequence(S->user.macro_arg_end, &pos)) {
                                match = 1;
                                break;
                            }
                        }
                        pos++; // nothing matched, go forward
                    }
                    (*argc)++;
                    if (match) { // no more args
                        *lg_end = pos;
                        break;
                    }
                }
            }
            return ((*lg_end >= 0) || (*sh_end >= 0));
        }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %r9, %rbp
movq %r8, %rbx
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r13
movq %rdi, %r12
movq (%rdi), %rax
movq (%rax), %rsi
movq %r13, %rdx
callq 0x5248
testl %eax, %eax
je 0x6409
movl (%r13), %esi
movq %r12, %rdi
callq 0x5a2e
movl %eax, (%r15)
testl %eax, %eax
je 0x6410
decl %eax
movq %r12, %rdi
movl %eax, %esi
callq 0x5932
testb %al, %al
je 0x6409
movq %rbx, 0x10(%rsp)
movl (%r15), %eax
jmp 0x6417
xorl %eax, %eax
jmp 0x65c2
movq %rbx, 0x10(%rsp)
xorl %eax, %eax
movq %rbp, 0x18(%rsp)
movl 0x70(%rsp), %ebx
movl %eax, (%r14)
movq (%r12), %rax
movq 0x8(%rax), %rsi
movq %r12, %rdi
movq %r14, %rdx
callq 0x5432
testl %eax, %eax
jne 0x643e
orl $-0x1, (%r14)
movq %r14, 0x20(%rsp)
movl (%r15), %eax
leaq 0xc(%rsp), %rdx
movl %eax, (%rdx)
movq (%r12), %rax
movq 0x10(%rax), %rsi
movq %r12, %rdi
callq 0x56be
movl %eax, %ebp
testl %ebx, %ebx
je 0x648b
movq 0x78(%rsp), %rbx
movq 0x20(%r12), %rax
movslq (%r13), %rsi
movl (%r15), %edx
subl %esi, %edx
addq (%rax), %rsi
movq %r12, %rdi
callq 0x5d26
movl %eax, (%rbx)
testl %eax, %eax
js 0x65ae
movq 0x10(%rsp), %rax
orl $-0x1, (%rax)
testl %ebp, %ebp
je 0x65b6
movq 0x68(%rsp), %rbx
xorl %eax, %eax
leaq 0xc(%rsp), %r13
movl %eax, (%rbx)
cmpl $0x64, %eax
jge 0x65e6
movq %rbx, %rbp
movl 0xc(%rsp), %r15d
cltq
movq 0x18(%rsp), %rcx
movl %r15d, (%rcx,%rax,4)
xorl %ebx, %ebx
movq %r12, %rdi
movl %r15d, %esi
callq 0x65f2
movl %eax, 0xc(%rsp)
movq %r12, %rdi
movq %r13, %rsi
movl 0x80(%rsp), %edx
xorl %ecx, %ecx
callq 0x6614
movl 0xc(%rsp), %r15d
movq %r12, %rdi
movl %r15d, %esi
callq 0x5932
testb %al, %al
je 0x65b6
movq (%r12), %rax
movq 0x38(%rax), %r14
movq %r12, %rdi
movl %r15d, %esi
callq 0x5932
movsbl %al, %esi
movq %r14, %rdi
callq 0x2040
xorl %ecx, %ecx
testq %rax, %rax
setne %cl
addl %ecx, %ebx
je 0x6553
movq (%r12), %rax
movq 0x40(%rax), %r14
movq %r12, %rdi
movl %r15d, %esi
callq 0x5932
movsbl %al, %esi
movq %r14, %rdi
callq 0x2040
cmpq $0x1, %rax
adcl $-0x1, %ebx
jmp 0x6598
movq %rbp, %rbx
movslq (%rbp), %rax
movq 0x60(%rsp), %rcx
movl %r15d, (%rcx,%rax,4)
movq (%r12), %rax
movq 0x18(%rax), %rsi
movq %r12, %rdi
movq %r13, %rdx
callq 0x56be
testl %eax, %eax
jne 0x65a5
movq (%r12), %rax
movq 0x20(%rax), %rsi
movq %r12, %rdi
movq %r13, %rdx
callq 0x5432
xorl %ebx, %ebx
movl 0xc(%rsp), %r15d
testl %eax, %eax
jne 0x65d1
incl %r15d
movl %r15d, 0xc(%rsp)
jmp 0x64c7
movl (%rbx), %eax
incl %eax
jmp 0x64a7
movq 0x10(%rsp), %rax
orl $-0x1, (%rax)
movq 0x20(%rsp), %rax
movl (%rax), %eax
notl %eax
shrl $0x1f, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
incl (%rbp)
movq 0x10(%rsp), %rax
movl %r15d, (%rax)
testl %r15d, %r15d
js 0x65b6
pushq $0x1
popq %rax
jmp 0x65c2
leaq 0x2461(%rip), %rdi      # 0x8a4e
callq 0x2d13