// File: /workspace/github_c_makefile_star2_O1/olcaytaner[P]Isell/hmm.c
// Function: printgaussianhmm
void printgaussianhmm(FILE *controlfile, Hmmptr hmm)
{
 int i, j, st, ft, ft2, numrealfeatures;
 Gaussianptr g;
 numrealfeatures = current_dataset->multifeaturecount - 1;
 fprintf(controlfile, "a :\n");
 for (i = 0; i < hmm->statecount; i++)
 	for (j = 0; j < hmm->statecount; j++)
   {
 		 fprintf(controlfile, "%i %i %f", i, j, hmm->states[i].a_i_dot[j]);
 		 fprintf(controlfile, "\n");
 	 }
 fprintf(controlfile, "Pi :\n");
 for (i = 0; i < hmm->statecount; i++)
   fprintf(controlfile, "%f ", hmm->states[i].pi);
 fprintf(controlfile, "\n");
 fprintf(controlfile, "number of states %d\n", hmm->statecount);
 fprintf(controlfile, "b:\n");
 for (st = 0; st < hmm->statecount; st++)
  {
	  g = (Gaussianptr)(hmm->states[st].b);
 	 fprintf(controlfile, "mean state %d\n", st);
	  for (ft = 0; ft < numrealfeatures; ft++)
 		  fprintf(controlfile,"%f ", g->mean[ft]);
   fprintf(controlfile, "\n"); 
  }
 for (st = 0; st < hmm->statecount; st++)
  {
	  g = (Gaussianptr)(hmm->states[st].b);
 	 fprintf(controlfile, "cov state %d\n", st);
 	 for (ft = 0; ft < numrealfeatures; ft++)
    {
			  for (ft2 = 0; ft2 < numrealfeatures; ft2++)
 				  fprintf(controlfile, "%.25f ", g->covariance.values[ft][ft2]);
     fprintf(controlfile, "\n");
    } 
   fprintf(controlfile, "\n"); 
  }	
 fprintf(controlfile, "\n");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0xa7320(%rip), %rax     # 0xd2870
movq (%rax), %rax
movl 0x1c0(%rax), %eax
movq %rax, (%rsp)
leaq 0x7a0b1(%rip), %rdi     # 0xa5615
movl $0x4, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x42c0
cmpl $0x0, 0x8(%r14)
jle 0x2b5de
xorl %r15d, %r15d
leaq 0x7a093(%rip), %r12     # 0xa561a
cmpl $0x0, 0x8(%r14)
jle 0x2b5d2
movq %r15, %rbp
shlq $0x5, %rbp
xorl %r13d, %r13d
movq (%r14), %rax
movq 0x8(%rax,%rbp), %rax
movsd (%rax,%r13,8), %xmm0
movq %rbx, %rdi
movq %r12, %rsi
movl %r15d, %edx
movl %r13d, %ecx
movb $0x1, %al
callq 0x42e0
movl $0xa, %edi
movq %rbx, %rsi
callq 0x4150
incq %r13
movslq 0x8(%r14), %rax
cmpq %rax, %r13
jl 0x2b598
incq %r15
movslq 0x8(%r14), %rax
cmpq %rax, %r15
jl 0x2b587
movq (%rsp), %rax
leal -0x1(%rax), %r12d
leaq 0x7a036(%rip), %rdi     # 0xa5623
movl $0x5, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x42c0
cmpl $0x0, 0x8(%r14)
jle 0x2b63b
movl $0x10, %r13d
xorl %ebp, %ebp
leaq 0x7a014(%rip), %r15     # 0xa5629
movq (%r14), %rax
movsd (%rax,%r13), %xmm0
movq %rbx, %rdi
movq %r15, %rsi
movb $0x1, %al
callq 0x42e0
incq %rbp
movslq 0x8(%r14), %rax
addq $0x20, %r13
cmpq %rax, %rbp
jl 0x2b615
movl $0xa, %edi
movq %rbx, %rsi
callq 0x4150
movl 0x8(%r14), %edx
leaq 0x79fda(%rip), %rsi     # 0xa562d
movq %rbx, %rdi
xorl %eax, %eax
callq 0x42e0
leaq 0x79fde(%rip), %rdi     # 0xa5642
movl $0x3, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x42c0
cmpl $0x0, 0x8(%r14)
movl %r12d, %r15d
movq %r14, 0x8(%rsp)
jle 0x2b6f8
leaq 0x79f9d(%rip), %r12     # 0xa5629
xorl %r13d, %r13d
movq (%r14), %rax
movq %r13, %rcx
shlq $0x5, %rcx
movq 0x18(%rax,%rcx), %rbp
movq %rbx, %rdi
leaq 0x79f9e(%rip), %rsi     # 0xa5646
movl %r13d, %edx
xorl %eax, %eax
callq 0x42e0
cmpl $0x2, (%rsp)
jl 0x2b6da
xorl %r14d, %r14d
movq (%rbp), %rax
movsd (%rax,%r14,8), %xmm0
movq %rbx, %rdi
movq %r12, %rsi
movb $0x1, %al
callq 0x42e0
incq %r14
cmpq %r14, %r15
jne 0x2b6bb
movl $0xa, %edi
movq %rbx, %rsi
callq 0x4150
incq %r13
movq 0x8(%rsp), %r14
movslq 0x8(%r14), %rax
cmpq %rax, %r13
jl 0x2b68f
cmpl $0x0, 0x8(%r14)
jle 0x2b79c
leaq 0x79f59(%rip), %r12     # 0xa5663
xorl %edx, %edx
movq (%r14), %rax
movq %rdx, %rcx
shlq $0x5, %rcx
movq 0x18(%rax,%rcx), %rbp
movq %rbx, %rdi
leaq 0x79f30(%rip), %rsi     # 0xa5655
movq %rdx, 0x10(%rsp)
xorl %eax, %eax
callq 0x42e0
cmpl $0x2, (%rsp)
jl 0x2b775
xorl %r13d, %r13d
xorl %r14d, %r14d
movq 0x10(%rbp), %rax
movq (%rax,%r13,8), %rax
movsd (%rax,%r14,8), %xmm0
movq %rbx, %rdi
movq %r12, %rsi
movb $0x1, %al
callq 0x42e0
incq %r14
cmpq %r14, %r15
jne 0x2b73d
movl $0xa, %edi
movq %rbx, %rsi
callq 0x4150
incq %r13
cmpq %r15, %r13
jne 0x2b73a
movl $0xa, %edi
movq %rbx, %rsi
callq 0x4150
movq 0x10(%rsp), %rdx
incq %rdx
movq 0x8(%rsp), %r14
movslq 0x8(%r14), %rax
cmpq %rax, %rdx
jl 0x2b70c
movl $0xa, %edi
movq %rbx, %rsi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x4150