// File: /workspace/github_cpp_makefile_star2_O2/chhylp123[P]hifiasm/Overlaps.cpp
// Function: print_node(asg_t*, ma_ug_t*)
void print_node(asg_t* g, ma_ug_t *ug)
{
    int input_iv;
    uint32_t iv, v;
    asg_arc_t *av, *aw;
    uint32_t nv, nw, i, k, w;
    while (1)
    {
        fprintf(stderr, "\n\ninput v: ");
        if(scanf("%d", &input_iv) == 0) break;
        if(input_iv == -1) break;
        iv = input_iv;
        iv = iv << 1;

        v = iv;
        av = asg_arc_a(g, v);
        nv = asg_arc_n(g, v);
        fprintf(stderr, "0**************v>>1: %u, v&1: %u, c: %u, del: %u, len: %u**************\n", 
        v>>1, v&1, (uint32_t)g->seq[v>>1].c, (uint32_t)g->seq[v>>1].del, g->seq[v>>1].len);
        for (i = 0; i < nv; i++)
        {
            if(av[i].del) continue;
            w = av[i].v;
            fprintf(stderr, "(%u) w>>1: %u, w&1: %u, ol: %u, eLen: %u\n", 
            i, w>>1, w&1, av[i].ol, (uint32_t)av[i].ul);
            

            aw = asg_arc_a(g, w^1);
            nw = asg_arc_n(g, w^1);
            for (k = 0; k < nw; k++)
            {
                if(aw[k].del) continue;
                if(aw[k].v == (v^1)) break;
            }

            fprintf(stderr, "self>>1: %u, self&1: %u, out>>1: %u, out^1: %u, is_sym: %u\n", 
            (uint32_t)(av[i].ul>>33), (uint32_t)((av[i].ul>>32)&1), av[i].v>>1, av[i].v&1, 
            (uint32_t)(k != nw));

        }






        v = iv^1;
        av = asg_arc_a(g, v);
        nv = asg_arc_n(g, v);
        fprintf(stderr, "1**************v>>1: %u, v&1: %u, c: %u, del: %u, len: %u**************\n", 
        v>>1, v&1, (uint32_t)g->seq[v>>1].c, (uint32_t)g->seq[v>>1].del, (uint32_t)g->seq[v>>1].len);
        for (i = 0; i < nv; i++)
        {
            if(av[i].del) continue;
            w = av[i].v;
            fprintf(stderr, "w>>1: %u, w&1: %u, ol: %u, eLen: %u\n", 
            w>>1, w&1, (uint32_t)av[i].ol, (uint32_t)av[i].ul);
            

            aw = asg_arc_a(g, w^1);
            nw = asg_arc_n(g, w^1);
            for (k = 0; k < nw; k++)
            {
                if(aw[k].del) continue;
                if(aw[k].v == (v^1)) break;
            }

            fprintf(stderr, "self>>1: %u, self&1: %u, out>>1: %u, out^1: %u, is_sym: %u\n", 
            (uint32_t)(av[i].ul>>33), (uint32_t)((av[i].ul>>32)&1), av[i].v>>1, av[i].v&1, 
            (uint32_t)(k != nw));

        }

        if(ug != NULL)
        {
            ma_utg_t *ma_v = &(ug->u.a[v>>1]);
            fprintf(stderr, "\n###\nma_v->n: %u, ma_v->len: %u\n", ma_v->n, ma_v->len);
            fprintf(stderr, "start>>1: %u, start&1: %u, end>>1: %u, end&1: %u\n", 
            ma_v->start>>1, ma_v->start&1, ma_v->end>>1, ma_v->end&1);
            for (i = 0; i < ma_v->n; i++)
            {
                v = ma_v->a[i]>>32;
                fprintf(stderr, "i: %u, v>>1: %u, v&1: %u, len: %u\n", 
                i, v>>1, v&1, (uint32_t)ma_v->a[i]);
            }
            
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, 0x10(%rsp)
movq 0x1a45dd(%rip), %rbp    # 0x252fe0
leaq 0x13b9d4(%rip), %r13    # 0x1ea3de
movq %rsi, 0x28(%rsp)
movq (%rbp), %rcx
movq %r13, %rdi
pushq $0xb
popq %rsi
pushq $0x1
popq %rdx
callq 0x2410
leaq 0x13c554(%rip), %rdi    # 0x1eaf7c
leaq 0x1c(%rsp), %rsi
xorl %eax, %eax
callq 0x21e0
testl %eax, %eax
sete %cl
movl 0x1c(%rsp), %eax
cmpl $-0x1, %eax
sete %dl
orb %cl, %dl
jne 0xaed8a
movl %eax, %r14d
leal (%r14,%r14), %ebx
movq 0x10(%rsp), %rdx
movq 0x20(%rdx), %rax
movq 0x28(%rdx), %rcx
movq (%rcx,%rbx,8), %r12
movq %r12, %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %r15
addq 0x8(%rdx), %r15
movq (%rbp), %rdi
movl %r14d, %edx
andl $0x7fffffff, %edx       # imm = 0x7FFFFFFF
movzbl 0x4(%rax,%rdx,8), %r8d
movl (%rax,%rdx,8), %eax
movl %eax, %r9d
shrl $0x1f, %r9d
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movl %eax, (%rsp)
leaq 0x13b94c(%rip), %rsi    # 0x1ea3ea
movq %rdx, 0x20(%rsp)
xorl %ecx, %ecx
xorl %eax, %eax
callq 0x22b0
leal 0x1(,%r14,2), %ebp
movl %r12d, %r13d
xorl %r12d, %r12d
movq %r15, 0x30(%rsp)
cmpq %r13, %r12
je 0xaeba2
imulq $0x18, %r12, %r14
movl 0xc(%r15,%r14), %r9d
testl %r9d, %r9d
jns 0xaeadb
incq %r12
jmp 0xaeabf
addq %r15, %r14
movl (%r14), %eax
movl 0x8(%r14), %r15d
movq 0x1a44f4(%rip), %rcx    # 0x252fe0
movq (%rcx), %rdi
movl %r15d, %ecx
shrl %ecx
movl %r15d, %r8d
andl $0x1, %r8d
movl %eax, (%rsp)
leaq 0x13b92e(%rip), %rsi    # 0x1ea433
movl %r12d, %edx
xorl %eax, %eax
callq 0x22b0
movq 0x10(%rsp), %rax
movq 0x8(%rax), %rdx
movq 0x28(%rax), %rax
xorq $0x1, %r15
movq (%rax,%r15,8), %rax
movq %rax, %rsi
shrq $0x20, %rsi
movl %eax, %ecx
imulq $0x18, %rsi, %rsi
addq %rsi, %rdx
addq $0xc, %rdx
xorl %esi, %esi
cmpq %rsi, %rcx
je 0xaeb52
cmpl $0x0, (%rdx)
js 0xaeb49
cmpl %ebp, -0x4(%rdx)
je 0xaeb54
incq %rsi
addq $0x18, %rdx
jmp 0xaeb3a
movl %eax, %esi
movq 0x1a4485(%rip), %rcx    # 0x252fe0
movq (%rcx), %rdi
movq (%r14), %rcx
movq %rcx, %rdx
shrq $0x21, %rdx
shrq $0x20, %rcx
andl $0x1, %ecx
movl 0x8(%r14), %r9d
movl %r9d, %r8d
shrl %r8d
andl $0x1, %r9d
xorl %r10d, %r10d
cmpl %eax, %esi
setne %r10b
movl %r10d, (%rsp)
leaq 0x13b8cc(%rip), %rsi    # 0x1ea45d
xorl %eax, %eax
callq 0x22b0
movq 0x30(%rsp), %r15
jmp 0xaead6
movq 0x10(%rsp), %rsi
movq 0x20(%rsi), %rax
movq 0x28(%rsi), %rcx
movl %ebp, %edx
movq (%rcx,%rdx,8), %r14
movq %r14, %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %r15
addq 0x8(%rsi), %r15
movq 0x1a4415(%rip), %rbp    # 0x252fe0
movq (%rbp), %rdi
movq 0x20(%rsp), %rdx
movzbl 0x4(%rax,%rdx,8), %r8d
movl (%rax,%rdx,8), %eax
movl %eax, %r9d
shrl $0x1f, %r9d
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movl %eax, (%rsp)
leaq 0x13b8a6(%rip), %rsi    # 0x1ea499
pushq $0x1
popq %rcx
xorl %eax, %eax
callq 0x22b0
movl %r14d, %r12d
xorl %r13d, %r13d
cmpq %r12, %r13
je 0xaecd5
imulq $0x18, %r13, %r14
movl 0xc(%r15,%r14), %r8d
testl %r8d, %r8d
jns 0xaec1f
incq %r13
jmp 0xaec03
addq %r15, %r14
movl (%r14), %r9d
movq %rbp, %rax
movl 0x8(%r14), %ebp
movq (%rax), %rdi
movl %ebp, %edx
shrl %edx
movl %ebp, %ecx
andl $0x1, %ecx
leaq 0x13b7f9(%rip), %rsi    # 0x1ea438
xorl %eax, %eax
callq 0x22b0
movq 0x10(%rsp), %rax
movq 0x8(%rax), %rdx
movq 0x28(%rax), %rax
xorq $0x1, %rbp
movq (%rax,%rbp,8), %rax
movq %rax, %rsi
shrq $0x20, %rsi
movl %eax, %ecx
imulq $0x18, %rsi, %rsi
addq %rsi, %rdx
addq $0xc, %rdx
xorl %esi, %esi
cmpq %rsi, %rcx
je 0xaec89
cmpl $0x0, (%rdx)
js 0xaec80
cmpl %ebx, -0x4(%rdx)
je 0xaec8b
incq %rsi
addq $0x18, %rdx
jmp 0xaec71
movl %eax, %esi
movq 0x1a434e(%rip), %rbp    # 0x252fe0
movq (%rbp), %rdi
movq (%r14), %rcx
movq %rcx, %rdx
shrq $0x21, %rdx
shrq $0x20, %rcx
andl $0x1, %ecx
movl 0x8(%r14), %r9d
movl %r9d, %r8d
shrl %r8d
andl $0x1, %r9d
xorl %r10d, %r10d
cmpl %eax, %esi
setne %r10b
movl %r10d, (%rsp)
leaq 0x13b794(%rip), %rsi    # 0x1ea45d
xorl %eax, %eax
callq 0x22b0
jmp 0xaec1a
movq 0x28(%rsp), %r12
testq %r12, %r12
leaq 0x13b6fa(%rip), %r13    # 0x1ea3de
je 0xaea0f
movq 0x10(%r12), %rbx
imulq $0x28, 0x20(%rsp), %r15
leaq (%rbx,%r15), %r14
movq (%rbp), %rdi
movl 0x10(%rbx,%r15), %edx
movl (%rbx,%r15), %ecx
movl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
andl %eax, %ecx
leaq 0x13b7ce(%rip), %rsi    # 0x1ea4e2
xorl %eax, %eax
callq 0x22b0
movq (%rbp), %rdi
movl 0x4(%rbx,%r15), %ecx
movl 0x8(%rbx,%r15), %r9d
movl %ecx, %edx
shrl %edx
andl $0x1, %ecx
movl %r9d, %r8d
shrl %r8d
andl $0x1, %r9d
leaq 0x13b7c2(%rip), %rsi    # 0x1ea503
xorl %eax, %eax
callq 0x22b0
xorl %ebx, %ebx
movl 0x10(%r14), %eax
cmpq %rax, %rbx
jae 0xaea0f
movq 0x18(%r14), %rax
movq (%rax,%rbx,8), %r9
movq %r9, %r8
shrq $0x20, %r8
movq (%rbp), %rdi
movq %r9, %rcx
shrq $0x21, %rcx
andl $0x1, %r8d
leaq 0x13b7b9(%rip), %rsi    # 0x1ea535
movl %ebx, %edx
xorl %eax, %eax
callq 0x22b0
incq %rbx
jmp 0xaed4a
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq