// File: /workspace/github_c_makefile_star2_O0/mishun[P]plantri/plantri.c
// Function: extend_bip_Q
static void
extend_bip_Q(EDGE *ref)

/* This routine is the implementation of the Q-operation in Batagelj's
   paper.  It inserts one new vertex -- nv. The reference edge ref is
   the one starting at the vertex to be split that will (always) become a 
   valency 4 vertex in the new graph. 

        a
   |\  /   reference edge nv->a
   | \/nv
   | /\
   |/  \

The operations can only be understood by drawing a picture containing the edge
numbers as initialized in init_P_op().
*/
{
    EDGE *a,*b,*c,*d,*x,*start;
    int dummy, dummy2;

    start=Q_op(nv);

    firstedge[nv]=ref;
    x=ref->next;
    b=ref->prev->invers;
    a=b->prev;

    d=x->next->invers;
    c=d->next;

    ref->start=ref->invers->end=x->start=x->invers->end=nv;

    ref->prev=start+4;

    c->prev=start+1;
    d->next=start+2;
    b->prev=start+3; 
    a->next=start+5;

    dummy=c->start; dummy2=a->start;
    (degree[dummy])+=2; (degree[dummy2])+=2;
    degree[nv]=4; (degree[b->end])-=2;
    start->prev=x; x->next=start; start->end=dummy; start++;
    /*1*/ start->next=c; c->prev=start; start->start=dummy; start++;
    /*2*/ start->prev=d; d->next=start; start->start=dummy;
          start->end=dummy2; start++;
    /*3*/ start->next=b; b->prev=start; start->start=dummy2;
          start->end=dummy; start++;
    /*4*/ start->next=ref; ref->prev=start; start->end=dummy2; start++;
    /*5*/ start->prev=a; a->next=start; start->start=dummy2;

    b=b->invers; d=d->invers;

    firstedge[b->start]=b;
    b->next=d;
    d->prev=b;


    nv++;
    ne+=6;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
imull $0x6, 0x226d51(%rip), %eax # 0x25a620
movslq %eax, %rcx
leaq 0x226d57(%rip), %rax    # 0x25a630
addq $0x600, %rax            # imm = 0x600
addq $0xc000, %rax           # imm = 0xC000
shlq $0x6, %rcx
addq %rcx, %rax
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rdx
movslq 0x226d25(%rip), %rcx    # 0x25a620
leaq 0xa0fe(%rip), %rax      # 0x3da00
movq %rdx, (%rax,%rcx,8)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movq 0x20(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x10(%rbp)
movq -0x30(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x20(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x20(%rbp)
movl 0x226cd0(%rip), %ecx    # 0x25a620
movq -0x30(%rbp), %rax
movq 0x20(%rax), %rax
movl %ecx, 0x4(%rax)
movq -0x30(%rbp), %rax
movl %ecx, (%rax)
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movl %ecx, 0x4(%rax)
movq -0x8(%rbp), %rax
movl %ecx, (%rax)
movq -0x38(%rbp), %rcx
addq $0x100, %rcx            # imm = 0x100
movq -0x8(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x38(%rbp), %rcx
addq $0x40, %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x38(%rbp), %rcx
addq $0x80, %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x38(%rbp), %rcx
addq $0xc0, %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x38(%rbp), %rcx
addq $0x140, %rcx            # imm = 0x140
movq -0x10(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x20(%rbp), %rax
movl (%rax), %eax
movl %eax, -0x3c(%rbp)
movq -0x10(%rbp), %rax
movl (%rax), %eax
movl %eax, -0x40(%rbp)
movslq -0x3c(%rbp), %rcx
leaq 0xa215(%rip), %rax      # 0x3dc00
movl (%rax,%rcx,4), %edx
addl $0x2, %edx
leaq 0xa208(%rip), %rax      # 0x3dc00
movl %edx, (%rax,%rcx,4)
movslq -0x40(%rbp), %rcx
leaq 0xa1fa(%rip), %rax      # 0x3dc00
movl (%rax,%rcx,4), %edx
addl $0x2, %edx
leaq 0xa1ed(%rip), %rax      # 0x3dc00
movl %edx, (%rax,%rcx,4)
movslq 0x226c03(%rip), %rcx    # 0x25a620
leaq 0xa1dc(%rip), %rax      # 0x3dc00
movl $0x4, (%rax,%rcx,4)
movq -0x18(%rbp), %rax
movslq 0x4(%rax), %rcx
leaq 0xa1c6(%rip), %rax      # 0x3dc00
movl (%rax,%rcx,4), %edx
subl $0x2, %edx
leaq 0xa1b9(%rip), %rax      # 0x3dc00
movl %edx, (%rax,%rcx,4)
movq -0x30(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x38(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, 0x18(%rax)
movl -0x3c(%rbp), %ecx
movq -0x38(%rbp), %rax
movl %ecx, 0x4(%rax)
movq -0x38(%rbp), %rax
addq $0x40, %rax
movq %rax, -0x38(%rbp)
movq -0x20(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x38(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x10(%rax)
movl -0x3c(%rbp), %ecx
movq -0x38(%rbp), %rax
movl %ecx, (%rax)
movq -0x38(%rbp), %rax
addq $0x40, %rax
movq %rax, -0x38(%rbp)
movq -0x28(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x38(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x18(%rax)
movl -0x3c(%rbp), %ecx
movq -0x38(%rbp), %rax
movl %ecx, (%rax)
movl -0x40(%rbp), %ecx
movq -0x38(%rbp), %rax
movl %ecx, 0x4(%rax)
movq -0x38(%rbp), %rax
addq $0x40, %rax
movq %rax, -0x38(%rbp)
movq -0x18(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x38(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x10(%rax)
movl -0x40(%rbp), %ecx
movq -0x38(%rbp), %rax
movl %ecx, (%rax)
movl -0x3c(%rbp), %ecx
movq -0x38(%rbp), %rax
movl %ecx, 0x4(%rax)
movq -0x38(%rbp), %rax
addq $0x40, %rax
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x38(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x10(%rax)
movl -0x40(%rbp), %ecx
movq -0x38(%rbp), %rax
movl %ecx, 0x4(%rax)
movq -0x38(%rbp), %rax
addq $0x40, %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x38(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x18(%rax)
movl -0x40(%rbp), %ecx
movq -0x38(%rbp), %rax
movl %ecx, (%rax)
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x28(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rdx
movq -0x18(%rbp), %rax
movslq (%rax), %rcx
leaq 0x9e74(%rip), %rax      # 0x3da00
movq %rdx, (%rax,%rcx,8)
movq -0x28(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x18(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x10(%rax)
movl 0x226a72(%rip), %eax    # 0x25a620
addl $0x1, %eax
movl %eax, 0x226a69(%rip)    # 0x25a620
movl 0x226a67(%rip), %eax    # 0x25a624
addl $0x6, %eax
movl %eax, 0x226a5e(%rip)    # 0x25a624
popq %rbp
retq
nopl (%rax,%rax)