// File: /workspace/github_cpp_makefile_star2_O3/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 0x11978(%rip), %rsi     # 0x170cc
leaq 0x11981(%rip), %rdx     # 0x170dc
leaq 0x50(%rsp), %r15
movq %r15, %rdi
callq 0xb1f2
leaq 0x70(%rsp), %rbp
leaq 0x80(%rsp), %rax
movq %rax, -0x10(%rax)
leaq 0x1195d(%rip), %rsi     # 0x170dd
leaq 0x1195a(%rip), %rdx     # 0x170e1
movq %rbp, %rdi
callq 0xb1f2
leaq 0x90(%rsp), %rbp
leaq 0xa0(%rsp), %rbx
movq %rbx, -0x10(%rbx)
leaq 0x11938(%rip), %rsi     # 0x170e2
leaq 0x11937(%rip), %rdx     # 0x170e8
movq %rbp, %rdi
callq 0xb1f2
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 0x118c0(%rip), %rsi     # 0x170e9
callq 0x33b0
cmpl $0x0, 0x4(%rsp)
jle 0x587c
xorl %ebp, %ebp
movq 0x38(%rsp), %rdi
leaq 0x12335(%rip), %rsi     # 0x17b78
callq 0x3100
testl %eax, %eax
movq (%r13), %rax
movq -0x18(%rax), %rax
movq $0x10, 0x10(%r13,%rax)
movq 0xf0(%rsp), %rax
cmoveq 0x40(%rsp), %rax
movl (%rax,%rbp,4), %esi
movq %r13, %rdi
callq 0x35b0
incq %rbp
cmpq %rbp, %r14
jne 0x5837
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 0x59e0
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 0x11815(%rip), %rsi     # 0x170eb
callq 0x3100
movl %eax, %ebp
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x58f1
callq 0x3340
movq (%r13), %rax
movq -0x18(%rax), %rax
movq $0x10, 0x10(%r13,%rax)
testl %ebp, %ebp
je 0x5945
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 0x5959
callq 0x3340
jmp 0x5959
movl $0x3, %edx
movq %r13, %rdi
leaq 0x1179a(%rip), %rsi     # 0x170ee
callq 0x33b0
cmpl $0x0, 0x4(%rsp)
jle 0x599f
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 0x596b
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 0x58b2
incq %r15
cmpq $0x3, %r15
jne 0x57c6
leaq 0xa0(%rsp), %rbx
xorl %r14d, %r14d
movq 0x90(%rsp,%r14), %rdi
leaq (%rbx,%r14), %rax
cmpq %rdi, %rax
je 0x5a0e
callq 0x3340
addq $-0x20, %r14
cmpq $-0x60, %r14
jne 0x59f8
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5a2c
movq %rax, %r14
addq $-0x10, %rbp
movq -0x10(%rbp), %rdi
cmpq %rdi, %rbp
je 0x5a41
callq 0x3340
leaq -0x20(%rbp), %rax
addq $-0x10, %rbp
cmpq %r15, %rbp
movq %rax, %rbp
jne 0x5a33
jmp 0x5a98
jmp 0x5a76
jmp 0x5a76
movq %rax, %r14
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x5a79
callq 0x3340
jmp 0x5a79
jmp 0x5a76
jmp 0x5a76
jmp 0x5a76
movq %rax, %r14
movq $-0x60, %r15
movq -0x10(%rbx), %rdi
cmpq %rdi, %rbx
je 0x5a8e
callq 0x3340
addq $-0x20, %rbx
addq $0x20, %r15
jne 0x5a80
movq %r14, %rdi
callq 0x35c0