// File: /workspace/github_c_makefile_star2_O2/mishun[P]plantri/plantri.c
// Function: extend_min5_c
static EDGE*
extend_min5_c(EDGE *e, EDGE **anchor)

{
/* extends a graph in the way given by the type c extension for
   5-connected triangulations. The edge e must start at
   a vertex of degree 5.

   It returns the edge characterizing this operation. This edge as
   well as the edge pointed to by *anchor must be given to the reduction
   routine.

*/

  EDGE *e1, *e2, *e3, *e4, *e5, *e1i, *e2i, *e3i, *e4i, *e5i, *start, *run;
  int v1, v2, v3, v4, v5, origin;

  *anchor=e;

  e1=e->invers->next;
  e1i=e1->invers;
  e2=e1i->next->next;
  e2i=e2->invers;
  e3=e2i->next->next;
  e3i=e3->invers;
  e4=e3i->next->next;
  e4i=e4->invers;
  e5=e4i->next->next;
  e5i=e5->invers;

  origin=e->start;
  v1=e1->start;
  v2=e1->end;
  v3=e3->start;
  v4=e3->end;
  v5=e5->start;

  start=min5_c(nv);

  firstedge[v1]=e1;
  degree[v1]++;
  firstedge[v2]=e2;
  degree[v2]++;
  firstedge[v3]=e3;
  degree[v3]++;
  firstedge[v4]=e4;
  degree[v4]++;
  firstedge[v5]=e5;
  degree[v5]++;

  firstedge[nv]=start+10; degree[nv]=5; nv++;
  firstedge[nv]=start+16; degree[nv]=5; nv++;
  firstedge[nv]=start+23; degree[nv]=5; nv++;
  firstedge[nv]=start+28; degree[nv]=5; nv++;
  firstedge[nv]=start+35; degree[nv]=5; nv++;
  firstedge[origin]=start+32; 
  /* degree[nv]=5; is already the case */

  ne+=30;

  e1->prev=start; start->next=e1;
  run=start+1;
  e5i->next=run; run->prev=e5i; 
  run++;
  e5->prev=run; run->next=e5;
  run++;
  e4i->next=run; run->prev=e4i;
  run++;
  e4->prev=run; run->next=e4;
  run++;
  e3i->next=run; run->prev=e3i;
  run++;
  e3->prev=run; run->next=e3;
  run++;
  e2i->next=run; run->prev=e2i;
  run++;
  e2->prev=run; run->next=e2;
  run++;
  e1i->next=run; run->prev=e1i;

  start->start=(start+1)->start=(start+10)->end=(start+15)->end=v1;
  (start+8)->start=(start+9)->start=(start+14)->end=(start+32)->end=v2;
  (start+7)->start=(start+6)->start=(start+27)->end=(start+31)->end=v3;
  (start+4)->start=(start+5)->start=(start+22)->end=(start+26)->end=v4;
  (start+2)->start=(start+3)->start=(start+16)->end=(start+21)->end=v5;
  (start+8)->end=(start+13)->end=(start+39)->end=(start+28)->end=(start+7)->end=origin;
  (start+30)->start=(start+31)->start=(start+32)->start=(start+33)->start=
     (start+34)->start=origin;

  return (start+35);

}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, (%rsi)
movq 0x20(%rdi), %rax
movq 0x18(%rax), %r13
movq 0x20(%r13), %rax
movq %rax, -0x8(%rsp)
movq 0x18(%rax), %rax
movq 0x18(%rax), %rax
movq 0x20(%rax), %rdx
movq %rdx, -0x10(%rsp)
movq %rax, %rcx
movq %rax, -0x50(%rsp)
movq 0x18(%rdx), %rax
movq 0x18(%rax), %r14
movq 0x20(%r14), %rax
movq %rax, -0x18(%rsp)
movq 0x18(%rax), %rax
movq 0x18(%rax), %rax
movq 0x20(%rax), %rdx
movq %rdx, -0x20(%rsp)
movq %rax, %r10
movq %rax, -0x68(%rsp)
movq 0x18(%rdx), %rax
movq 0x18(%rax), %r11
movq 0x20(%r11), %rax
movq %rax, -0x48(%rsp)
movslq (%rdi), %rbx
movslq (%r13), %rbp
movslq 0x4(%r13), %rdi
movq %rdi, -0x40(%rsp)
movslq (%r14), %rsi
movq %rsi, -0x38(%rsp)
movslq 0x4(%r14), %rdx
movq %rdx, -0x30(%rsp)
movslq (%r11), %rax
leaq 0x12fc9(%rip), %r9      # 0x25be0
incl (%r9,%rbp,4)
leaq 0x12dbe(%rip), %r8      # 0x259e0
movq %r13, (%r8,%rbp,8)
incl (%r9,%rdi,4)
movq %rcx, (%r8,%rdi,8)
incl (%r9,%rsi,4)
movq %r14, (%r8,%rsi,8)
incl (%r9,%rdx,4)
movq %r10, (%r8,%rdx,8)
movq %rax, -0x28(%rsp)
incl (%r9,%rax,4)
movq %r11, (%r8,%rax,8)
movslq 0x22f9ae(%rip), %rdx    # 0x242600
imulq $0xa00, %rdx, %rax      # imm = 0xA00
leaq 0x22f9b0(%rip), %rsi    # 0x242610
leaq (%rax,%rsi), %r10
addq $0x11f80, %r10          # imm = 0x11F80
movq %r10, (%r8,%rdx,8)
movl $0x5, %ecx
movl %ecx, (%r9,%rdx,4)
movl %ecx, 0x4(%r9,%rdx,4)
movl %ecx, 0x8(%r9,%rdx,4)
movl %ecx, 0xc(%r9,%rdx,4)
movl %ecx, 0x10(%r9,%rdx,4)
leaq 0x12100(%rax,%rsi), %r12
movq %r12, 0x8(%r8,%rdx,8)
leaq 0x122c0(%rax,%rsi), %rdi
movq %rdi, -0x60(%rsp)
movq %rdi, 0x10(%r8,%rdx,8)
leaq 0x12400(%rax,%rsi), %r15
movq %r15, 0x18(%r8,%rdx,8)
leaq (%rax,%rsi), %rdi
addq $0x125c0, %rdi          # imm = 0x125C0
movq %rdi, -0x58(%rsp)
movq %rdi, 0x20(%r8,%rdx,8)
addl %edx, %ecx
movl %ecx, 0x22f92b(%rip)    # 0x242600
leaq (%rax,%rsi), %rdi
addq $0x12500, %rdi          # imm = 0x12500
movq %rdi, (%r8,%rbx,8)
addl $0x1e, 0x22f919(%rip)   # 0x242604
leaq (%rax,%rsi), %rcx
addq $0x11d00, %rcx          # imm = 0x11D00
movq %rcx, 0x10(%r13)
movq %r13, 0x18(%rcx)
leaq 0x11d40(%rax,%rsi), %rcx
movq -0x48(%rsp), %rdx
movq %rcx, 0x18(%rdx)
movq %rdx, 0x10(%rcx)
leaq 0x11d80(%rax,%rsi), %r13
movq %r13, 0x10(%r11)
movq %r11, 0x18(%r13)
leaq 0x11dc0(%rax,%rsi), %r11
movq -0x20(%rsp), %rcx
movq %r11, 0x18(%rcx)
movq %rcx, 0x10(%r11)
leaq 0x11e00(%rax,%rsi), %r10
movq -0x68(%rsp), %rcx
movq %r10, 0x10(%rcx)
movq %rcx, 0x18(%r10)
leaq 0x11e40(%rax,%rsi), %r9
movq -0x18(%rsp), %rcx
movq %r9, 0x18(%rcx)
movq %rcx, 0x10(%r9)
leaq 0x11e80(%rax,%rsi), %r8
movq %r8, 0x10(%r14)
movq %r14, 0x18(%r8)
leaq 0x11ec0(%rax,%rsi), %r14
movq -0x10(%rsp), %rcx
movq %r14, 0x18(%rcx)
movq %rcx, 0x10(%r14)
leaq 0x11f00(%rax,%rsi), %rdx
movq -0x50(%rsp), %rcx
movq %rdx, 0x10(%rcx)
movq %rcx, 0x18(%rdx)
leaq 0x11f40(%rax,%rsi), %rax
movq -0x8(%rsp), %rsi
movq %rax, 0x18(%rsi)
movq %rsi, 0x10(%rax)
movl %ebp, -0x3c(%r12)
movl %ebp, 0x44(%rax)
movl %ebp, -0x80(%r11)
movl %ebp, -0x80(%r13)
movq -0x40(%rsp), %rcx
movl %ecx, 0x4(%rdi)
movl %ecx, -0x7c(%r12)
movl %ecx, (%rax)
movl %ecx, -0x40(%rax)
movq -0x38(%rsp), %rcx
movl %ecx, -0x3c(%rdi)
movl %ecx, -0x3c(%r15)
movl %ecx, -0x80(%rdx)
movl %ecx, -0x80(%rax)
movq -0x30(%rsp), %rcx
movl %ecx, -0x7c(%r15)
movq -0x60(%rsp), %rdx
movl %ecx, -0x3c(%rdx)
movl %ecx, -0x80(%r14)
movl %ecx, -0x80(%r8)
movq -0x28(%rsp), %rcx
movl %ecx, -0x7c(%rdx)
movl %ecx, 0x4(%r12)
movl %ecx, -0x80(%r9)
movl %ecx, -0x80(%r10)
movl %ebx, -0x7c(%rax)
movl %ebx, 0x4(%r15)
movl %ebx, 0x784(%rax)
movl %ebx, 0x104(%rax)
movl %ebx, -0x3c(%rax)
movq -0x58(%rsp), %rax
movl %ebx, -0x40(%rax)
movl %ebx, 0x40(%rdi)
movl %ebx, (%rdi)
movl %ebx, -0x40(%rdi)
movl %ebx, -0x80(%rdi)
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq