// File: /workspace/github_cpp_makefile_star2_O1/dtsaras[P]GCW/GCW.cpp
// Function: output_stats_k_and_p(std::ostream*, double***, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, int, int*, int*)
void output_stats_k_and_p(ostream * output, double *** data, string variable, string algorithms, int reps, int * eventsArray, int * budgetsArray){
	string names[3] = {"total similarity", "time", "memory"};
	for (int d = 0; d < 3; ++d){
		*output << names[d] << endl;
		*output << setw(16) << "#";
		for (int i = 0; i < reps; ++i){
			if (variable == "c")
				*output << setw(16) << eventsArray[i];
			else
				*output << setw(16) << budgetsArray[i];
		}
		*output << endl;

		for (int i = 0; i < algorithms.size(); i += 2){
			if (algorithms.substr(i,2) == "EG")
				*output << setw(16) << "GCW";
			else
				*output << setw(16) << algorithms.substr(i,2);
			for (int j = 0; j < reps; ++j){
				*output << setw(16) << data[d][i/2][j];
			}
			*output << endl;
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xb8, %rsp
movq %r9, 0x40(%rsp)
movl %r8d, 0x4(%rsp)
movq %rcx, %r12
movq %rdx, 0x38(%rsp)
movq %rsi, 0x48(%rsp)
movq %rdi, %r13
leaq 0x60(%rsp), %rax
movq %rax, -0x10(%rax)
leaq 0x127ed(%rip), %rsi     # 0x180cc
leaq 0x127f6(%rip), %rdx     # 0x180dc
leaq 0x50(%rsp), %rbp
movq %rbp, %rdi
callq 0xb376
leaq 0x70(%rsp), %r15
leaq 0x80(%rsp), %rax
movq %rax, -0x10(%rax)
leaq 0x127d2(%rip), %rsi     # 0x180dd
leaq 0x127cf(%rip), %rdx     # 0x180e1
movq %r15, %rdi
callq 0xb376
leaq 0x90(%rsp), %r15
leaq 0xa0(%rsp), %rbx
movq %rbx, -0x10(%rbx)
leaq 0x127ad(%rip), %rsi     # 0x180e2
leaq 0x127ac(%rip), %rdx     # 0x180e8
movq %r15, %rdi
callq 0xb376
movl 0x4(%rsp), %r14d
xorl %r15d, %r15d
movq %r12, 0x30(%rsp)
movq %r15, %rax
shlq $0x5, %rax
movq 0x50(%rsp,%rax), %rsi
movq 0x58(%rsp,%rax), %rdx
movq %r13, %rdi
callq 0x33b0
movq %rax, %rbp
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbp, %rdi
movl $0xa, %esi
callq 0x3360
movsbl %al, %esi
movq %rbp, %rdi
callq 0x3040
movq %rax, %rdi
callq 0x3240
movq (%r13), %rax
movq -0x18(%rax), %rax
movq $0x10, 0x10(%r13,%rax)
movl $0x1, %edx
movq %r13, %rdi
leaq 0x12735(%rip), %rsi     # 0x180e9
callq 0x33b0
cmpl $0x0, 0x4(%rsp)
jle 0x5a07
xorl %ebp, %ebp
movq 0x38(%rsp), %rdi
leaq 0x131a1(%rip), %rsi     # 0x18b6f
callq 0x3100
testl %eax, %eax
movq (%r13), %rax
movq -0x18(%rax), %rax
movq 0xf0(%rsp), %rcx
cmoveq 0x40(%rsp), %rcx
movq $0x10, 0x10(%r13,%rax)
movl (%rcx,%rbp,4), %esi
movq %r13, %rdi
callq 0x35b0
incq %rbp
cmpq %rbp, %r14
jne 0x59c2
movq (%r13), %rax
movq -0x18(%rax), %rdi
addq %r13, %rdi
movl $0xa, %esi
callq 0x3360
movsbl %al, %esi
movq %r13, %rdi
callq 0x3040
movq %rax, %rdi
callq 0x3240
cmpq $0x0, 0x8(%r12)
je 0x5b74
xorl %edx, %edx
movl $0x2, %ecx
leaq 0x10(%rsp), %rbp
movq %rbp, %rdi
movq %r12, %rsi
movq %rdx, 0x8(%rsp)
callq 0x3380
movq %rbp, %rdi
leaq 0x1268a(%rip), %rsi     # 0x180eb
callq 0x3100
movl %eax, %ebp
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x5a7c
callq 0x3340
movq (%r13), %rax
movq -0x18(%rax), %rax
testl %ebp, %ebp
je 0x5ad0
movq $0x10, 0x10(%r13,%rax)
movl $0x2, %ecx
leaq 0x10(%rsp), %rdi
movq %r12, %rsi
movq 0x8(%rsp), %rdx
callq 0x3380
movq 0x10(%rsp), %rsi
movq 0x18(%rsp), %rdx
movq %r13, %rdi
callq 0x33b0
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x5aed
callq 0x3340
jmp 0x5aed
movq $0x10, 0x10(%r13,%rax)
movl $0x3, %edx
movq %r13, %rdi
leaq 0x12606(%rip), %rsi     # 0x180ee
callq 0x33b0
cmpl $0x0, 0x4(%rsp)
jle 0x5b33
movq 0x8(%rsp), %rbp
shrq %rbp
xorl %r12d, %r12d
movq (%r13), %rax
movq -0x18(%rax), %rax
movq $0x10, 0x10(%r13,%rax)
movq 0x48(%rsp), %rax
movq (%rax,%r15,8), %rax
movq (%rax,%rbp,8), %rax
movsd (%rax,%r12,8), %xmm0
movq %r13, %rdi
callq 0x3520
incq %r12
cmpq %r12, %r14
jne 0x5aff
movq (%r13), %rax
movq -0x18(%rax), %rdi
addq %r13, %rdi
movl $0xa, %esi
callq 0x3360
movsbl %al, %esi
movq %r13, %rdi
callq 0x3040
movq %rax, %rdi
callq 0x3240
movq 0x8(%rsp), %rdx
addq $0x2, %rdx
movq 0x30(%rsp), %r12
cmpq %rdx, 0x8(%r12)
ja 0x5a3d
incq %r15
cmpq $0x3, %r15
jne 0x5951
leaq 0xa0(%rsp), %rbx
xorl %r14d, %r14d
movq 0x90(%rsp,%r14), %rdi
leaq (%rbx,%r14), %rax
cmpq %rdi, %rax
je 0x5ba2
callq 0x3340
addq $-0x20, %r14
cmpq $-0x60, %r14
jne 0x5b8c
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5bc0
movq %rax, %r14
jmp 0x5bcb
movq %rax, %r14
movq %rbp, %r15
cmpq %r15, %rbp
je 0x5c3e
addq $-0x10, %r15
leaq 0x50(%rsp), %rbx
movq -0x10(%r15), %rdi
cmpq %rdi, %r15
je 0x5be7
callq 0x3340
leaq -0x20(%r15), %rax
addq $-0x10, %r15
cmpq %rbx, %r15
movq %rax, %r15
jne 0x5bd9
jmp 0x5c3e
jmp 0x5c1c
jmp 0x5c1c
movq %rax, %r14
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x5c1f
callq 0x3340
jmp 0x5c1f
jmp 0x5c1c
jmp 0x5c1c
jmp 0x5c1c
movq %rax, %r14
movq $-0x60, %r15
movq -0x10(%rbx), %rdi
cmpq %rdi, %rbx
je 0x5c34
callq 0x3340
addq $-0x20, %rbx
addq $0x20, %r15
jne 0x5c26
movq %r14, %rdi
callq 0x35c0