// File: /workspace/github_c_makefile_star2_O0/olcaytaner[P]Isell/univariaterule.c
// Function: growrule
Decisionruleptr growrule(Instanceptr* growset, int positive, Ripper_parameterptr param)
{
 /*!Last Changed 21.01.2004*/
 /*!Last Changed 29.12.2003*/
 /*!Last Changed 02.12.2003*/
 /*!Last Changed 10.05.2003*/
 Decisionruleptr result;
 Decisionconditionptr newcondition = NULL;
 Instanceptr obey, notobey = NULL;
 int n, pnew, nnew;
 double bestgain;
 result = empty_rule(positive);
 obey = (*growset);
 if (rule_cover_negative(obey, *result))
   n = 1;
 else
   n = 0;
 while (n > 0)
  {
   if (get_parameter_o("usediscrete") == ON)
     if (get_parameter_i("smallsetsize") == 0)
       newcondition = find_best_discrete_condition_omnivariate(obey, positive);
     else
       newcondition = find_best_discrete_condition(obey, get_parameter_i("smallsetsize"), positive, &bestgain);
   else
     newcondition = find_best_condition(obey, positive, param);
   if (newcondition && newcondition->featureindex != -1)
    {
     count_examples_for_condition(newcondition, &pnew, &nnew, positive, obey);
     if (result->decisioncount == 0 || nnew != n)
       n = nnew;
     else
      {
       free_condition(*newcondition);
       safe_free(newcondition);
       break;
      }
     send_exceptions(newcondition, &obey, &notobey);
     add_condition(result, newcondition);
    }
   else
    {
     if (newcondition && newcondition->featureindex == -1)
      {
       free_condition(*newcondition);
       safe_free(newcondition);
      }
     break;
    }
  }
 if (notobey)
  {
   merge_instancelist(&notobey, obey);
   (*growset) = notobey;
  }
 else
   (*growset) = obey;
 return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xd0, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x28(%rbp)
movq $0x0, -0x38(%rbp)
movl -0xc(%rbp), %edi
callq 0xad8b0
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rdi
movq -0x20(%rbp), %rcx
movq 0x30(%rcx), %rdx
movq %rsp, %rax
movq %rdx, 0x30(%rax)
movups (%rcx), %xmm0
movups 0x10(%rcx), %xmm1
movups 0x20(%rcx), %xmm2
movups %xmm2, 0x20(%rax)
movups %xmm1, 0x10(%rax)
movups %xmm0, (%rax)
callq 0xae310
cmpl $0x0, %eax
je 0xdaf89
movl $0x1, -0x3c(%rbp)
jmp 0xdaf90
movl $0x0, -0x3c(%rbp)
jmp 0xdaf92
cmpl $0x0, -0x3c(%rbp)
jle 0xdb12c
leaq 0x7642(%rip), %rdi      # 0xe25e5
callq 0x79440
cmpl $0x1, %eax
jne 0xdaffc
leaq 0x75c5(%rip), %rdi      # 0xe2579
callq 0x78f10
cmpl $0x0, %eax
jne 0xdafd0
movq -0x30(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0x479c0
movq %rax, -0x28(%rbp)
jmp 0xdaffa
movq -0x30(%rbp), %rax
movq %rax, -0x58(%rbp)
leaq 0x759a(%rip), %rdi      # 0xe2579
callq 0x78f10
movq -0x58(%rbp), %rdi
movl %eax, %esi
movl -0xc(%rbp), %edx
leaq -0x50(%rbp), %rcx
callq 0x47b20
movq %rax, -0x28(%rbp)
jmp 0xdb010
movq -0x30(%rbp), %rdi
movl -0xc(%rbp), %esi
movq -0x18(%rbp), %rdx
callq 0xda620
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
je 0xdb0ca
movq -0x28(%rbp), %rax
cmpl $-0x1, (%rax)
je 0xdb0ca
movq -0x28(%rbp), %rdi
movl -0xc(%rbp), %ecx
movq -0x30(%rbp), %r8
leaq -0x40(%rbp), %rsi
leaq -0x44(%rbp), %rdx
callq 0xac3d0
movq -0x20(%rbp), %rax
cmpl $0x0, 0x28(%rax)
je 0xdb052
movl -0x44(%rbp), %eax
cmpl -0x3c(%rbp), %eax
je 0xdb05a
movl -0x44(%rbp), %eax
movl %eax, -0x3c(%rbp)
jmp 0xdb0aa
movq -0x28(%rbp), %rcx
movups 0x60(%rcx), %xmm0
movq %rsp, %rax
movups %xmm0, 0x60(%rax)
movups 0x50(%rcx), %xmm0
movups %xmm0, 0x50(%rax)
movups 0x40(%rcx), %xmm0
movups %xmm0, 0x40(%rax)
movups (%rcx), %xmm0
movups 0x10(%rcx), %xmm1
movups 0x20(%rcx), %xmm2
movups 0x30(%rcx), %xmm3
movups %xmm3, 0x30(%rax)
movups %xmm2, 0x20(%rax)
movups %xmm1, 0x10(%rax)
movups %xmm0, (%rax)
callq 0xadc90
movq -0x28(%rbp), %rdi
callq 0x52e80
jmp 0xdb12c
movq -0x28(%rbp), %rdi
leaq -0x30(%rbp), %rsi
leaq -0x38(%rbp), %rdx
callq 0xdad60
movq -0x20(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0xad950
jmp 0xdb127
cmpq $0x0, -0x28(%rbp)
je 0xdb125
movq -0x28(%rbp), %rax
cmpl $-0x1, (%rax)
jne 0xdb125
movq -0x28(%rbp), %rcx
movups 0x60(%rcx), %xmm0
movq %rsp, %rax
movups %xmm0, 0x60(%rax)
movups 0x50(%rcx), %xmm0
movups %xmm0, 0x50(%rax)
movups 0x40(%rcx), %xmm0
movups %xmm0, 0x40(%rax)
movups (%rcx), %xmm0
movups 0x10(%rcx), %xmm1
movups 0x20(%rcx), %xmm2
movups 0x30(%rcx), %xmm3
movups %xmm3, 0x30(%rax)
movups %xmm2, 0x20(%rax)
movups %xmm1, 0x10(%rax)
movups %xmm0, (%rax)
callq 0xadc90
movq -0x28(%rbp), %rdi
callq 0x52e80
jmp 0xdb12c
jmp 0xdaf92
cmpq $0x0, -0x38(%rbp)
je 0xdb14d
movq -0x30(%rbp), %rsi
leaq -0x38(%rbp), %rdi
callq 0x44f40
movq -0x38(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, (%rax)
jmp 0xdb158
movq -0x30(%rbp), %rcx
movq -0x8(%rbp), %rax
movq %rcx, (%rax)
movq -0x20(%rbp), %rax
addq $0xd0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)