// File: /workspace/github_c_makefile_star2_O0/olcaytaner[P]Isell/operator.c
// Function: remove_operator
BOOLEAN remove_operator(bayesiangraphptr mygraph)
{
/*!Last Changed 02.03.2001*/
 int arc_no, from, to, from_order;
 double before, after;
 if (mygraph->arccount == mygraph->nodecount - 1)
   return BOOLEAN_FALSE;
 arc_no = myrand() % mygraph->arccount;
 before = likelihood_of_data(mygraph, cv);
 delete_one_arc(mygraph, arc_no, &from, &to, &from_order);
 delete_parent_counts(&mygraph->nodes[to], from_order);
 free_2d((void **) mygraph->nodes[to].table, mygraph->nodes[to].table_count);
 make_one_conditional_table(mygraph, to);
 if (connected(mygraph))
  {
   after = likelihood_of_data(mygraph, cv);
   if (after > before)
     return BOOLEAN_TRUE;
  }
 free_2d((void **) mygraph->nodes[to].table, mygraph->nodes[to].table_count);
 add_parent_counts(mygraph, &mygraph->nodes[to], from);
 add_one_arc(mygraph);
 add_one_pointer(mygraph, &mygraph->nodes[to], from);
 make_one_conditional_table(mygraph, to);
 return BOOLEAN_FALSE;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movl 0x20(%rax), %eax
movq -0x10(%rbp), %rcx
movl 0x10(%rcx), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jne 0x782bd
movl $0x0, -0x4(%rbp)
jmp 0x78440
movb $0x0, %al
callq 0x54550
movq -0x10(%rbp), %rcx
cltd
idivl 0x20(%rcx)
movl %edx, -0x14(%rbp)
movq -0x10(%rbp), %rdi
leaq 0x8d1be(%rip), %rax     # 0x105498
movq (%rax), %rsi
leaq 0x8d1b4(%rip), %rax     # 0x105498
movq 0x8(%rax), %rdx
callq 0x37640
movsd %xmm0, -0x28(%rbp)
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %esi
leaq -0x18(%rbp), %rdx
leaq -0x1c(%rbp), %rcx
leaq -0x20(%rbp), %r8
callq 0x70860
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
movslq -0x1c(%rbp), %rax
imulq $0x48, %rax, %rax
addq %rax, %rdi
movl -0x20(%rbp), %esi
callq 0x70bc0
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x1c(%rbp), %rcx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
movq 0x38(%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x1c(%rbp), %rcx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
movl %eax, %esi
callq 0x52e20
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %esi
callq 0x71ee0
movq -0x10(%rbp), %rdi
callq 0x714b0
cmpl $0x0, %eax
je 0x783b1
movq -0x10(%rbp), %rdi
leaq 0x8d119(%rip), %rax     # 0x105498
movq (%rax), %rsi
leaq 0x8d10f(%rip), %rax     # 0x105498
movq 0x8(%rax), %rdx
callq 0x37640
movsd %xmm0, -0x30(%rbp)
movsd -0x30(%rbp), %xmm0
ucomisd -0x28(%rbp), %xmm0
jbe 0x783af
movl $0x1, -0x4(%rbp)
jmp 0x78440
jmp 0x783b1
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x1c(%rbp), %rcx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
movq 0x38(%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movslq -0x1c(%rbp), %rcx
imulq $0x48, %rcx, %rcx
addq %rcx, %rax
movq 0x28(%rax), %rax
movl %eax, %esi
callq 0x52e20
movq -0x10(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
movslq -0x1c(%rbp), %rax
imulq $0x48, %rax, %rax
addq %rax, %rsi
movl -0x18(%rbp), %edx
callq 0x70c80
movq -0x10(%rbp), %rdi
callq 0x70a70
movq -0x10(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
movslq -0x1c(%rbp), %rax
imulq $0x48, %rax, %rax
addq %rax, %rsi
movl -0x18(%rbp), %edx
callq 0x70b20
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %esi
callq 0x71ee0
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)