// File: /workspace/github_c_makefile_star2_O0/olcaytaner[P]Isell/svmsimplex.c
// Function: prepare_qp_for_epsilon_svm
Quadraticprogramptr prepare_qp_for_epsilon_svm(Instanceptr data, Svm_simplex_parameterptr parameters)
{
 int i, size = data_size(data);
 double *c, *b;
 matrix A, Q;
 Instanceptr tmp;
 Quadraticprogramptr program;
 Q = prepare_Q_for_epsilon_svm(data, parameters->kernel);
 c = safemalloc(2 * size * sizeof(double), "prepare_qp_for_epsilon_svm", 4);
 for (i = 0, tmp = data; i < size; i++, tmp = tmp->next)
  {
   c[i] = parameters->epsilon - give_regressionvalue(tmp);
   c[i + size] = parameters->epsilon + give_regressionvalue(tmp);
  }
 b = safemalloc((2 * size + 2) * sizeof(double), "prepare_qp_for_epsilon_svm", 7);
 for (i = 0; i < 2 * size; i++)
   b[i] = parameters->C;
 b[2 * size] = 0;
 b[2 * size + 1] = 0;
 A = matrix_alloc(2 * size + 2, 2 * size);
 for (i = 0; i < 2 * size; i++)
   A.values[i][i] = 1;
 for (i = 0; i < size; i++)
  {
   A.values[2 * size][i] = 1;
   A.values[2 * size][size + i] = -1;
   A.values[2 * size + 1][i] = -1;
   A.values[2 * size + 1][size + i] = 1;
  }
 program = prepare_quadratic_program(Q, A, c, b);
 matrix_free(Q);
 matrix_free(A);
 safe_free(c);
 safe_free(b);
 return program;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xa0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
callq 0x449f0
movl %eax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0xcc260
movq %rax, -0x68(%rbp)
movq %rdx, -0x60(%rbp)
movq -0x68(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x60(%rbp), %rax
movq %rax, -0x40(%rbp)
movl -0x18(%rbp), %eax
shll %eax
movslq %eax, %rdi
shlq $0x3, %rdi
leaq 0x21c2c(%rip), %rsi     # 0xee1fc
movl $0x4, %edx
callq 0x52d70
movq %rax, -0x20(%rbp)
movl $0x0, -0x14(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x50(%rbp)
movl -0x14(%rbp), %eax
cmpl -0x18(%rbp), %eax
jge 0xcc67e
movq -0x10(%rbp), %rax
movsd 0x28(%rax), %xmm0
movsd %xmm0, -0x88(%rbp)
movq -0x50(%rbp), %rdi
callq 0x43580
movaps %xmm0, %xmm1
movsd -0x88(%rbp), %xmm0
subsd %xmm1, %xmm0
movq -0x20(%rbp), %rax
movslq -0x14(%rbp), %rcx
movsd %xmm0, (%rax,%rcx,8)
movq -0x10(%rbp), %rax
movsd 0x28(%rax), %xmm0
movsd %xmm0, -0x80(%rbp)
movq -0x50(%rbp), %rdi
callq 0x43580
movaps %xmm0, %xmm1
movsd -0x80(%rbp), %xmm0
addsd %xmm1, %xmm0
movq -0x20(%rbp), %rax
movl -0x14(%rbp), %ecx
addl -0x18(%rbp), %ecx
movslq %ecx, %rcx
movsd %xmm0, (%rax,%rcx,8)
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
movq -0x50(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x50(%rbp)
jmp 0xcc5ed
movl -0x18(%rbp), %eax
shll %eax
addl $0x2, %eax
movslq %eax, %rdi
shlq $0x3, %rdi
leaq 0x21b68(%rip), %rsi     # 0xee1fc
movl $0x7, %edx
callq 0x52d70
movq %rax, -0x28(%rbp)
movl $0x0, -0x14(%rbp)
movl -0x14(%rbp), %eax
movl -0x18(%rbp), %ecx
shll %ecx
cmpl %ecx, %eax
jge 0xcc6d6
movq -0x10(%rbp), %rax
movsd 0x20(%rax), %xmm0
movq -0x28(%rbp), %rax
movslq -0x14(%rbp), %rcx
movsd %xmm0, (%rax,%rcx,8)
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0xcc6a9
movq -0x28(%rbp), %rax
movl -0x18(%rbp), %ecx
shll %ecx
movslq %ecx, %rcx
xorps %xmm0, %xmm0
movsd %xmm0, (%rax,%rcx,8)
movq -0x28(%rbp), %rax
movl -0x18(%rbp), %ecx
shll %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
xorps %xmm0, %xmm0
movsd %xmm0, (%rax,%rcx,8)
movl -0x18(%rbp), %edi
shll %edi
addl $0x2, %edi
movl -0x18(%rbp), %esi
shll %esi
callq 0x57fc0
movq %rax, -0x78(%rbp)
movq %rdx, -0x70(%rbp)
movq -0x78(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x70(%rbp), %rax
movq %rax, -0x30(%rbp)
movl $0x0, -0x14(%rbp)
movl -0x14(%rbp), %eax
movl -0x18(%rbp), %ecx
shll %ecx
cmpl %ecx, %eax
jge 0xcc766
movq -0x30(%rbp), %rax
movslq -0x14(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movslq -0x14(%rbp), %rcx
movsd 0x158c2(%rip), %xmm0    # 0xe2018
movsd %xmm0, (%rax,%rcx,8)
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0xcc732
movl $0x0, -0x14(%rbp)
movl -0x14(%rbp), %eax
cmpl -0x18(%rbp), %eax
jge 0xcc81b
movq -0x30(%rbp), %rax
movl -0x18(%rbp), %ecx
shll %ecx
movslq %ecx, %rcx
movq (%rax,%rcx,8), %rax
movslq -0x14(%rbp), %rcx
movsd 0x15883(%rip), %xmm0    # 0xe2018
movsd %xmm0, (%rax,%rcx,8)
movq -0x30(%rbp), %rax
movl -0x18(%rbp), %ecx
shll %ecx
movslq %ecx, %rcx
movq (%rax,%rcx,8), %rax
movl -0x18(%rbp), %ecx
addl -0x14(%rbp), %ecx
movslq %ecx, %rcx
movsd 0x1628d(%rip), %xmm0    # 0xe2a48
movsd %xmm0, (%rax,%rcx,8)
movq -0x30(%rbp), %rax
movl -0x18(%rbp), %ecx
shll %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movq (%rax,%rcx,8), %rax
movslq -0x14(%rbp), %rcx
movsd 0x16269(%rip), %xmm0    # 0xe2a48
movsd %xmm0, (%rax,%rcx,8)
movq -0x30(%rbp), %rax
movl -0x18(%rbp), %ecx
shll %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movq (%rax,%rcx,8), %rax
movl -0x18(%rbp), %ecx
addl -0x14(%rbp), %ecx
movslq %ecx, %rcx
movsd 0x15810(%rip), %xmm0    # 0xe2018
movsd %xmm0, (%rax,%rcx,8)
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0xcc76d
movq -0x20(%rbp), %r8
movq -0x28(%rbp), %r9
movq -0x48(%rbp), %rdi
movq -0x40(%rbp), %rsi
movq -0x38(%rbp), %rdx
movq -0x30(%rbp), %rcx
callq 0x143e0
movq %rax, -0x58(%rbp)
movq -0x48(%rbp), %rdi
movq -0x40(%rbp), %rsi
callq 0x59ea0
movq -0x38(%rbp), %rdi
movq -0x30(%rbp), %rsi
callq 0x59ea0
movq -0x20(%rbp), %rdi
callq 0x52e80
movq -0x28(%rbp), %rdi
callq 0x52e80
movq -0x58(%rbp), %rax
addq $0xa0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)