// File: /workspace/github_c_makefile_star2_O1/mishun[P]plantri/plantri.c
// Function: write_digits
static void
write_digits(FILE *f, int doflip)
 
/* Write in alphabetic format.  Always write in next direction,
   and if doflip != 0 also write in prev direction.  This output
   procedure uses the internal numbering of vertices and is 
   intended for debugging purposes. */
{
    int i,k;
    EDGE *ex,*e;
    unsigned char code[2*MAXN+2*MAXE+9];
    int nvsize;
    int lastnum,w;
    int nbop,nbtot,nbpart;
    EDGE **nb0,**nb,**nblim;
#define CODE0(x) ((x)<10 ? '0'+(x) : 'a'+(x)-10)
 
    if (oneswitch)
    {
	nbop = gotone_nbop;
	nbtot = gotone_nbtot;
	nbpart = (nbop==0 || nbop==nbtot ? nbtot : nbop);
	fprintf(f,"%d %d %d %d %d\n",nv,ne,(doflip?2:1),nbpart,nbtot);

	nb0 = (EDGE**) numbering[0];
	nblim = (EDGE**) numbering[doflip ? nbpart : nbtot];

	if (nblim != (EDGE**) numbering[1])
	    for (nb = nb0; nb < nblim; nb += MAXE)
	    {
		for (i = 0; i < ne; ++i)
		    fprintf(f," %c%c",CODE0(nb[i]->start),CODE0(nb[i]->end));
		fprintf(f,"\n");
	    }
    }
    
    if (nv >= 10) 
    {
        code[0] = '0' + nv/10;
        code[1] = '0' + nv%10;
        code[2] = ' ';
        nvsize = k = 3;
    }
    else
    {
        code[0] = '0' + nv;
        code[1] = ' ';
        nvsize = k = 2;
    }

    if (missing_vertex < 0) lastnum = nv-1;
    else                    lastnum = nv;
 
    for (i = 0; i <= lastnum; ++i)
    {
	if (i != missing_vertex)
	{
            e = ex = firstedge[i];
            do
            {
		w = e->end;
		code[k++] = CODE0(w);
                e = e->next;
            }
            while (e != ex);
            code[k++] = ',';
	}
    }
    code[k-1] = '\n';
 
    if (doflip)
    {
        for (i = 0; i <nvsize; ++i) code[k++] = code[i];
    
        for (i = 0; i <= lastnum; ++i)
        {
	    if (i != missing_vertex)
            {
                e = ex = firstedge[i];
                do
                {
                    w = e->end;
		    code[k++] = CODE0(w);
                    e = e->prev;
                }
                while (e != ex);
                code[k++] = ',';
	    }
        }
    }
    code[k-1] = '\n';
 
    if (fwrite(code,(size_t)1,(size_t)k,f) != (size_t)k)
    {
        fprintf(stderr,">E %s: fwrite() failed\n",cmdname);
        perror(">E ");
        exit(1);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x398, %rsp            # imm = 0x398
movl %esi, 0x10(%rsp)
movq %rdi, %rbx
cmpb $0x1, 0x1be43(%rip)     # 0x26254
jne 0xa4e2
movl 0x23a1ea(%rip), %r9d    # 0x244608
movl 0x23a1e8(%rip), %eax    # 0x24460c
testl %r9d, %r9d
cmovel %eax, %r9d
movl 0x23a1df(%rip), %edx    # 0x244610
movl 0x23a1dd(%rip), %ecx    # 0x244614
xorl %r8d, %r8d
cmpl $0x0, 0x10(%rsp)
setne %r8b
movl %r9d, %ebp
cmovel %eax, %ebp
incl %r8d
movl %eax, (%rsp)
leaq 0x16078(%rip), %rsi     # 0x204ce
movq %rbx, %rdi
xorl %eax, %eax
callq 0x1070
cmpl $0x2, %ebp
jl 0xa4e2
movslq %ebp, %rax
imulq $0xba0, %rax, %r15      # imm = 0xBA0
leaq 0x1d87a(%rip), %r12     # 0x27cf0
addq %r12, %r15
leaq 0x1605e(%rip), %r14     # 0x204de
cmpl $0x0, 0x23a18d(%rip)    # 0x244614
jle 0xa4c9
xorl %r13d, %r13d
movq (%r12,%r13,8), %rax
movl (%rax), %ecx
movl 0x4(%rax), %eax
leal 0x57(%rcx), %esi
leal 0x30(%rcx), %edx
cmpl $0xa, %ecx
cmovgel %esi, %edx
leal 0x57(%rax), %esi
leal 0x30(%rax), %ecx
cmpl $0xa, %eax
cmovgel %esi, %ecx
movq %rbx, %rdi
movq %r14, %rsi
xorl %eax, %eax
callq 0x1070
incq %r13
movslq 0x23a150(%rip), %rax    # 0x244614
cmpq %rax, %r13
jl 0xa48c
movl $0xa, %edi
movq %rbx, %rsi
callq 0x1040
addq $0xba0, %r12            # imm = 0xBA0
cmpq %r15, %r12
jb 0xa480
movl 0x23a128(%rip), %edx    # 0x244610
cmpl $0xa, %edx
jl 0xa51f
movl %edx, %eax
movl $0xcccccccd, %ecx       # imm = 0xCCCCCCCD
imulq %rax, %rcx
shrq $0x23, %rcx
leal 0x30(%rcx), %eax
movb %al, 0x20(%rsp)
addl %ecx, %ecx
leal (%rcx,%rcx,4), %eax
movl %edx, %ecx
subl %eax, %ecx
orb $0x30, %cl
movb %cl, 0x21(%rsp)
movb $0x20, 0x22(%rsp)
movl $0x3, %edi
jmp 0xa530
leal 0x30(%rdx), %eax
movb %al, 0x20(%rsp)
movb $0x20, 0x21(%rsp)
movl $0x2, %edi
movabsq $0x100000000, %rax      # imm = 0x100000000
movl 0x1bb50(%rip), %ecx     # 0x26090
movl %ecx, %r8d
sarl $0x1f, %r8d
movl %r8d, %esi
movq %rdx, 0x18(%rsp)
addl %edx, %esi
movl %esi, 0x14(%rsp)
movl %edi, 0xc(%rsp)
movl %edi, %edx
js 0xa5d2
movq 0x18(%rsp), %rdx
leal (%rdx,%r8), %edi
incl %edi
xorl %r11d, %r11d
leaq 0x1d47e(%rip), %r14     # 0x279f0
movl 0xc(%rsp), %edx
cmpq %rcx, %r11
je 0xa5ca
movq (%r14,%r11,8), %rbp
movslq %edx, %r15
leal 0x1(%r15), %edx
leaq (%rsp,%r15), %r13
addq $0x20, %r13
shlq $0x20, %r15
movq %rbp, %r12
movl 0x4(%r12), %r10d
leal 0x57(%r10), %r9d
leal 0x30(%r10), %esi
cmpl $0xa, %r10d
cmovgel %r9d, %esi
movb %sil, (%r13)
movq 0x18(%r12), %r12
incl %edx
incq %r13
addq %rax, %r15
cmpq %rbp, %r12
jne 0xa595
sarq $0x20, %r15
movb $0x2c, 0x20(%rsp,%r15)
incq %r11
cmpq %rdi, %r11
jne 0xa576
movslq %edx, %r14
leaq 0x20(%rsp), %rdi
movb $0xa, -0x1(%r14,%rdi)
cmpl $0x0, 0x10(%rsp)
je 0xa686
movl 0xc(%rsp), %r11d
addq %rsp, %r14
addq $0x20, %r14
xorl %r10d, %r10d
movb 0x20(%rsp,%r10), %sil
movb %sil, (%r14,%r10)
incq %r10
cmpq %r10, %r11
jne 0xa5fa
movl %edx, %edx
addq %r10, %rdx
cmpl $0x0, 0x14(%rsp)
js 0xa686
movq 0x18(%rsp), %rsi
addl %r8d, %esi
incl %esi
xorl %r8d, %r8d
leaq 0x1d3c5(%rip), %r9      # 0x279f0
cmpq %rcx, %r8
je 0xa67e
movq (%r9,%r8,8), %r11
movslq %edx, %r10
leal 0x1(%r10), %edx
leaq (%rsp,%r10), %r14
addq $0x20, %r14
shlq $0x20, %r10
movq %r11, %r15
movl 0x4(%r15), %r12d
leal 0x57(%r12), %ebp
leal 0x30(%r12), %r13d
cmpl $0xa, %r12d
cmovgel %ebp, %r13d
movb %r13b, (%r14)
movq 0x10(%r15), %r15
incl %edx
incq %r14
addq %rax, %r10
cmpq %r11, %r15
jne 0xa64a
sarq $0x20, %r10
movb $0x2c, 0x20(%rsp,%r10)
incq %r8
cmpq %rsi, %r8
jne 0xa62b
movslq %edx, %r14
movb $0xa, -0x1(%r14,%rdi)
movl $0x1, %esi
movq %r14, %rdx
movq %rbx, %rcx
callq 0x10f0
cmpq %r14, %rax
jne 0xa6b6
addq $0x398, %rsp            # imm = 0x398
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x24ac