// File: /workspace/github_c_makefile_star2_O0/ComplexNetworks-DCC-FCUP[P]gtrieScanner/nauty/nauty.c
// Function: processnode(int*, int*, int, int)
static int
processnode(int *lab, int *ptn, int level, int numcells)
{
        int i,code,save,newlevel;
        boolean ispruneok;
        int sr;

        code = 0;
        if (eqlev_first != level && (!getcanon || comp_canon < 0))
            code = 4;
        else if (numcells == n)
        {
            if (eqlev_first == level)
            {
                for (i = 0; i < n; ++i) workperm[firstlab[i]] = lab[i];

                if (gca_first >= noncheaplevel ||
                                   (*dispatch.isautom)(g,workperm,digraph,M,n))
                    code = 1;
            }
            if (code == 0)
                if (getcanon)
                {
                    sr = 0;
                    if (comp_canon == 0)
                    {
                        if (level < canonlevel)
                            comp_canon = 1;
                        else
                        {
                            (*dispatch.updatecan)
                                              (g,canong,canonlab,samerows,M,n);
                            samerows = n;
                            comp_canon
                                = (*dispatch.testcanlab)(g,canong,lab,&sr,M,n);
                        }
                    }
                    if (comp_canon == 0)
                    {
                        for (i = 0; i < n; ++i) workperm[canonlab[i]] = lab[i];
                        code = 2;
                    }
                    else if (comp_canon > 0)
                        code = 3;
                    else
                        code = 4;
                }
                else
                    code = 4;
        }

        if (code != 0 && level > stats->maxlevel) stats->maxlevel = level;

        switch (code)
        {
        case 0:                 /* nothing unusual noticed */
            return level;

        case 1:                 /* lab is equivalent to firstlab */
            if (fmptr == worktop) fmptr -= 2 * M;
            fmperm(workperm,fmptr,fmptr+M,M,n);
            fmptr += 2 * M;
            if (writeautoms)
                writeperm(outfile,workperm,cartesian,linelength,n);
            stats->numorbits = orbjoin(orbits,workperm,n);
            ++stats->numgenerators;
            OPTCALL(userautomproc)(stats->numgenerators,workperm,orbits,
                                        stats->numorbits,stabvertex,n);
            return gca_first;

        case 2:                 /* lab is equivalent to canonlab */
            if (fmptr == worktop) fmptr -= 2 * M;
            fmperm(workperm,fmptr,fmptr+M,M,n);
            fmptr += 2 * M;
            save = stats->numorbits;
            stats->numorbits = orbjoin(orbits,workperm,n);
            if (stats->numorbits == save)
            {
                if (gca_canon != gca_first) needshortprune = TRUE;
                return gca_canon;
            }
            if (writeautoms)
                writeperm(outfile,workperm,cartesian,linelength,n);
            ++stats->numgenerators;
            OPTCALL(userautomproc)(stats->numgenerators,workperm,orbits,
                                        stats->numorbits,stabvertex,n);
            if (orbits[cosetindex] < cosetindex)
                return gca_first;
            if (gca_canon != gca_first)
                needshortprune = TRUE;
            return gca_canon;

        case 3:                 /* lab is better than canonlab */
            ++stats->canupdates;
            for (i = 0; i < n; ++i) canonlab[i] = lab[i];
            canonlevel = eqlev_canon = gca_canon = level;
            comp_canon = 0;
            canoncode[level+1] = 077777;
            samerows = sr;
            break;

        case 4:                /* non-automorphism terminal node */
            ++stats->numbadleaves;
            break;
        }  /* end of switch statement */

    /* only cases 3 and 4 get this far: */
        if (level != noncheaplevel)
        {
            ispruneok = TRUE;
            if (fmptr == worktop) fmptr -= 2 * M;
            fmptn(lab,ptn,noncheaplevel,fmptr,fmptr+M,M,n);
            fmptr += 2 * M;
        }
        else
            ispruneok = FALSE;

        save = (allsamelevel > eqlev_canon ? allsamelevel-1 : eqlev_canon);
        newlevel = (noncheaplevel <= save ? noncheaplevel-1 : save);

        if (ispruneok && newlevel != gca_first) needshortprune = TRUE;
        return newlevel;
 }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movl %ecx, -0x20(%rbp)
movl $0x0, -0x28(%rbp)
movl 0x211c1(%rip), %eax     # 0x3d514
cmpl -0x1c(%rbp), %eax
je 0x1c376
cmpl $0x0, 0x21101(%rip)     # 0x3d460
je 0x1c36a
cmpl $0x0, 0x211b8(%rip)     # 0x3d520
jge 0x1c376
movl $0x4, -0x28(%rbp)
jmp 0x1c54d
movl -0x20(%rbp), %eax
cmpl 0x21025(%rip), %eax     # 0x3d3a4
jne 0x1c54b
movl 0x21189(%rip), %eax     # 0x3d514
cmpl -0x1c(%rbp), %eax
jne 0x1c41b
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl 0x21000(%rip), %eax     # 0x3d3a4
jge 0x1c3d5
movq -0x10(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,4), %edx
movq 0x21028(%rip), %rax     # 0x3d3e0
movq 0x21031(%rip), %rcx     # 0x3d3f0
movslq -0x24(%rbp), %rsi
movslq (%rcx,%rsi,4), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x1c39b
movl 0x21131(%rip), %eax     # 0x3d50c
cmpl 0x210e7(%rip), %eax     # 0x3d4c8
jge 0x1c412
movq 0x20f5e(%rip), %rax     # 0x3d348
movq 0x210cf(%rip), %rdi     # 0x3d4c0
movq 0x20fe8(%rip), %rsi     # 0x3d3e0
movl 0x21066(%rip), %edx     # 0x3d464
movl 0x20f9c(%rip), %ecx     # 0x3d3a0
movl 0x20f99(%rip), %r8d     # 0x3d3a4
callq *%rax
cmpl $0x0, %eax
je 0x1c419
movl $0x1, -0x28(%rbp)
jmp 0x1c41b
cmpl $0x0, -0x28(%rbp)
jne 0x1c549
cmpl $0x0, 0x21034(%rip)     # 0x3d460
je 0x1c540
movl $0x0, -0x38(%rbp)
cmpl $0x0, 0x210e0(%rip)     # 0x3d520
jne 0x1c4d0
movl -0x1c(%rbp), %eax
cmpl 0x210cd(%rip), %eax     # 0x3d51c
jge 0x1c45d
movl $0x1, 0x210c5(%rip)     # 0x3d520
jmp 0x1c4ce
movq 0x20ef4(%rip), %rax     # 0x3d358
movq 0x21055(%rip), %rdi     # 0x3d4c0
movq 0x21046(%rip), %rsi     # 0x3d4b8
movq 0x20f87(%rip), %rdx     # 0x3d400
movl 0x21081(%rip), %ecx     # 0x3d500
movl 0x20f1a(%rip), %r8d     # 0x3d3a0
movl 0x20f17(%rip), %r9d     # 0x3d3a4
callq *%rax
movl 0x20f0f(%rip), %eax     # 0x3d3a4
movl %eax, 0x21065(%rip)     # 0x3d500
movq 0x20eae(%rip), %rax     # 0x3d350
movq 0x21017(%rip), %rdi     # 0x3d4c0
movq 0x21008(%rip), %rsi     # 0x3d4b8
movq -0x10(%rbp), %rdx
movl 0x20ee5(%rip), %r8d     # 0x3d3a0
movl 0x20ee2(%rip), %r9d     # 0x3d3a4
leaq -0x38(%rbp), %rcx
callq *%rax
movl %eax, 0x21052(%rip)     # 0x3d520
jmp 0x1c4d0
cmpl $0x0, 0x21049(%rip)     # 0x3d520
jne 0x1c523
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl 0x20ebb(%rip), %eax     # 0x3d3a4
jge 0x1c51a
movq -0x10(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,4), %edx
movq 0x20ee3(%rip), %rax     # 0x3d3e0
movq 0x20efc(%rip), %rcx     # 0x3d400
movslq -0x24(%rbp), %rsi
movslq (%rcx,%rsi,4), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x1c4e0
movl $0x2, -0x28(%rbp)
jmp 0x1c53e
cmpl $0x0, 0x20ff6(%rip)     # 0x3d520
jle 0x1c535
movl $0x3, -0x28(%rbp)
jmp 0x1c53c
movl $0x4, -0x28(%rbp)
jmp 0x1c53e
jmp 0x1c547
movl $0x4, -0x28(%rbp)
jmp 0x1c549
jmp 0x1c54b
jmp 0x1c54d
cmpl $0x0, -0x28(%rbp)
je 0x1c56f
movl -0x1c(%rbp), %eax
movq 0x20efb(%rip), %rcx     # 0x3d458
cmpl 0x28(%rcx), %eax
jle 0x1c56f
movl -0x1c(%rbp), %ecx
movq 0x20eec(%rip), %rax     # 0x3d458
movl %ecx, 0x28(%rax)
movl -0x28(%rbp), %eax
movq %rax, -0x40(%rbp)
subq $0x4, %rax
ja 0x1c93a
movq -0x40(%rbp), %rax
leaq 0x474d(%rip), %rcx      # 0x20cd8
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl -0x1c(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x1ca5e
movq 0x20f3a(%rip), %rax     # 0x3d4e0
cmpq 0x20f2b(%rip), %rax     # 0x3d4d8
jne 0x1c5d4
movl 0x20deb(%rip), %ecx     # 0x3d3a0
shll %ecx
movq 0x20f22(%rip), %rax     # 0x3d4e0
movslq %ecx, %rdx
xorl %ecx, %ecx
subq %rdx, %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, 0x20f0c(%rip)     # 0x3d4e0
movq 0x20e05(%rip), %rdi     # 0x3d3e0
movq 0x20efe(%rip), %rsi     # 0x3d4e0
movq 0x20ef7(%rip), %rdx     # 0x3d4e0
movslq 0x20db0(%rip), %rax     # 0x3d3a0
shlq $0x2, %rax
addq %rax, %rdx
movl 0x20da3(%rip), %ecx     # 0x3d3a0
movl 0x20da0(%rip), %r8d     # 0x3d3a4
callq 0x1d2a0
movl 0x20d91(%rip), %ecx     # 0x3d3a0
shll %ecx
movq 0x20ec8(%rip), %rax     # 0x3d4e0
movslq %ecx, %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, 0x20eb7(%rip)     # 0x3d4e0
cmpl $0x0, 0x20e38(%rip)     # 0x3d468
je 0x1c658
movq 0x20e47(%rip), %rdi     # 0x3d480
movq 0x20da0(%rip), %rsi     # 0x3d3e0
movl 0x20e2a(%rip), %edx     # 0x3d470
movl 0x20e28(%rip), %ecx     # 0x3d474
movl 0x20d51(%rip), %r8d     # 0x3d3a4
callq 0x1cf80
movq 0x20df1(%rip), %rdi     # 0x3d450
movq 0x20d7a(%rip), %rsi     # 0x3d3e0
movl 0x20d38(%rip), %edx     # 0x3d3a4
callq 0x1ce60
movl %eax, %ecx
movq 0x20dde(%rip), %rax     # 0x3d458
movl %ecx, 0xc(%rax)
movq 0x20dd4(%rip), %rax     # 0x3d458
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
cmpq $0x0, 0x20dfb(%rip)     # 0x3d490
je 0x1c6d0
movq 0x20df2(%rip), %rax     # 0x3d490
movq 0x20db3(%rip), %rcx     # 0x3d458
movl 0x10(%rcx), %edi
movq 0x20d31(%rip), %rsi     # 0x3d3e0
movq 0x20d9a(%rip), %rdx     # 0x3d450
movq 0x20d9b(%rip), %rcx     # 0x3d458
movl 0xc(%rcx), %ecx
movl 0x20e3d(%rip), %r8d     # 0x3d504
movl 0x20cd6(%rip), %r9d     # 0x3d3a4
callq *%rax
movl 0x20e36(%rip), %eax     # 0x3d50c
movl %eax, -0x4(%rbp)
jmp 0x1ca5e
movq 0x20dfb(%rip), %rax     # 0x3d4e0
cmpq 0x20dec(%rip), %rax     # 0x3d4d8
jne 0x1c713
movl 0x20cac(%rip), %ecx     # 0x3d3a0
shll %ecx
movq 0x20de3(%rip), %rax     # 0x3d4e0
movslq %ecx, %rdx
xorl %ecx, %ecx
subq %rdx, %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, 0x20dcd(%rip)     # 0x3d4e0
movq 0x20cc6(%rip), %rdi     # 0x3d3e0
movq 0x20dbf(%rip), %rsi     # 0x3d4e0
movq 0x20db8(%rip), %rdx     # 0x3d4e0
movslq 0x20c71(%rip), %rax     # 0x3d3a0
shlq $0x2, %rax
addq %rax, %rdx
movl 0x20c64(%rip), %ecx     # 0x3d3a0
movl 0x20c61(%rip), %r8d     # 0x3d3a4
callq 0x1d2a0
movl 0x20c52(%rip), %ecx     # 0x3d3a0
shll %ecx
movq 0x20d89(%rip), %rax     # 0x3d4e0
movslq %ecx, %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, 0x20d78(%rip)     # 0x3d4e0
movq 0x20ce9(%rip), %rax     # 0x3d458
movl 0xc(%rax), %eax
movl %eax, -0x2c(%rbp)
movq 0x20cd4(%rip), %rdi     # 0x3d450
movq 0x20c5d(%rip), %rsi     # 0x3d3e0
movl 0x20c1b(%rip), %edx     # 0x3d3a4
callq 0x1ce60
movl %eax, %ecx
movq 0x20cc1(%rip), %rax     # 0x3d458
movl %ecx, 0xc(%rax)
movq 0x20cb7(%rip), %rax     # 0x3d458
movl 0xc(%rax), %eax
cmpl -0x2c(%rbp), %eax
jne 0x1c7cf
movl 0x20d69(%rip), %eax     # 0x3d518
cmpl 0x20d57(%rip), %eax     # 0x3d50c
je 0x1c7c1
movl $0x1, 0x20d27(%rip)     # 0x3d4e8
movl 0x20d51(%rip), %eax     # 0x3d518
movl %eax, -0x4(%rbp)
jmp 0x1ca5e
cmpl $0x0, 0x20c92(%rip)     # 0x3d468
je 0x1c7fe
movq 0x20ca1(%rip), %rdi     # 0x3d480
movq 0x20bfa(%rip), %rsi     # 0x3d3e0
movl 0x20c84(%rip), %edx     # 0x3d470
movl 0x20c82(%rip), %ecx     # 0x3d474
movl 0x20bab(%rip), %r8d     # 0x3d3a4
callq 0x1cf80
movq 0x20c53(%rip), %rax     # 0x3d458
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
cmpq $0x0, 0x20c7a(%rip)     # 0x3d490
je 0x1c851
movq 0x20c71(%rip), %rax     # 0x3d490
movq 0x20c32(%rip), %rcx     # 0x3d458
movl 0x10(%rcx), %edi
movq 0x20bb0(%rip), %rsi     # 0x3d3e0
movq 0x20c19(%rip), %rdx     # 0x3d450
movq 0x20c1a(%rip), %rcx     # 0x3d458
movl 0xc(%rcx), %ecx
movl 0x20cbc(%rip), %r8d     # 0x3d504
movl 0x20b55(%rip), %r9d     # 0x3d3a4
callq *%rax
movq 0x20bf8(%rip), %rax     # 0x3d450
movslq 0x20ca9(%rip), %rcx     # 0x3d508
movl (%rax,%rcx,4), %eax
cmpl 0x20ca0(%rip), %eax     # 0x3d508
jge 0x1c878
movl 0x20c9c(%rip), %eax     # 0x3d50c
movl %eax, -0x4(%rbp)
jmp 0x1ca5e
movl 0x20c9a(%rip), %eax     # 0x3d518
cmpl 0x20c88(%rip), %eax     # 0x3d50c
je 0x1c890
movl $0x1, 0x20c58(%rip)     # 0x3d4e8
movl 0x20c82(%rip), %eax     # 0x3d518
movl %eax, -0x4(%rbp)
jmp 0x1ca5e
movq 0x20bb3(%rip), %rax     # 0x3d458
movq 0x38(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x38(%rax)
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl 0x20ae3(%rip), %eax     # 0x3d3a4
jge 0x1c8e7
movq -0x10(%rbp), %rax
movslq -0x24(%rbp), %rcx
movl (%rax,%rcx,4), %edx
movq 0x20b2b(%rip), %rax     # 0x3d400
movslq -0x24(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x1c8b8
movl -0x1c(%rbp), %eax
movl %eax, 0x20c28(%rip)     # 0x3d518
movl %eax, 0x20bd6(%rip)     # 0x3d4cc
movl %eax, 0x20c20(%rip)     # 0x3d51c
movl $0x0, 0x20c1a(%rip)     # 0x3d520
movq 0x20b13(%rip), %rax     # 0x3d420
movl -0x1c(%rbp), %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movw $0x7fff, (%rax,%rcx,2)  # imm = 0x7FFF
movl -0x38(%rbp), %eax
movl %eax, 0x20bdb(%rip)     # 0x3d500
jmp 0x1c93a
movq 0x20b2a(%rip), %rax     # 0x3d458
movq 0x20(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x20(%rax)
movl -0x1c(%rbp), %eax
cmpl 0x20b85(%rip), %eax     # 0x3d4c8
je 0x1c9e6
movl $0x1, -0x34(%rbp)
movq 0x20b89(%rip), %rax     # 0x3d4e0
cmpq 0x20b7a(%rip), %rax     # 0x3d4d8
jne 0x1c985
movl 0x20a3a(%rip), %ecx     # 0x3d3a0
shll %ecx
movq 0x20b71(%rip), %rax     # 0x3d4e0
movslq %ecx, %rdx
xorl %ecx, %ecx
subq %rdx, %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, 0x20b5b(%rip)     # 0x3d4e0
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movl 0x20b35(%rip), %edx     # 0x3d4c8
movq 0x20b46(%rip), %rcx     # 0x3d4e0
movq 0x20b3f(%rip), %r8      # 0x3d4e0
movslq 0x209f8(%rip), %rax     # 0x3d3a0
shlq $0x2, %rax
addq %rax, %r8
movl 0x209ea(%rip), %r9d     # 0x3d3a0
movl 0x209e8(%rip), %eax     # 0x3d3a4
movl %eax, (%rsp)
callq 0x1d490
movl 0x209d6(%rip), %ecx     # 0x3d3a0
shll %ecx
movq 0x20b0d(%rip), %rax     # 0x3d4e0
movslq %ecx, %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, 0x20afc(%rip)     # 0x3d4e0
jmp 0x1c9ed
movl $0x0, -0x34(%rbp)
movl 0x20b1d(%rip), %eax     # 0x3d510
cmpl 0x20ad3(%rip), %eax     # 0x3d4cc
jle 0x1ca09
movl 0x20b0f(%rip), %eax     # 0x3d510
subl $0x1, %eax
movl %eax, -0x44(%rbp)
jmp 0x1ca12
movl 0x20abd(%rip), %eax     # 0x3d4cc
movl %eax, -0x44(%rbp)
movl -0x44(%rbp), %eax
movl %eax, -0x2c(%rbp)
movl 0x20aaa(%rip), %eax     # 0x3d4c8
cmpl -0x2c(%rbp), %eax
jg 0x1ca31
movl 0x20a9f(%rip), %eax     # 0x3d4c8
subl $0x1, %eax
movl %eax, -0x48(%rbp)
jmp 0x1ca37
movl -0x2c(%rbp), %eax
movl %eax, -0x48(%rbp)
movl -0x48(%rbp), %eax
movl %eax, -0x30(%rbp)
cmpl $0x0, -0x34(%rbp)
je 0x1ca58
movl -0x30(%rbp), %eax
cmpl 0x20ac0(%rip), %eax     # 0x3d50c
je 0x1ca58
movl $0x1, 0x20a90(%rip)     # 0x3d4e8
movl -0x30(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopw (%rax,%rax)