// File: /workspace/github_cpp_makefile_star2_O1/ShootMe[P]Klondike-Solver/Solitaire.cpp
// Function: AddMove(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char>>&, Move, int, int, int, bool)
void AddMove(stringstream & ss, Move m, int stockSize, int wasteSize, int drawCount, bool combine) {
	if (m.Extra > 0) {
		if (m.From != WASTE) {
			if (m.Count > 1) {
				if (!combine) {
					ss << PILES[m.From] << PILES[m.To] << '-' << (int)m.Count << " F" << (int)m.From << ' ';
				} else {
					ss << '[' << PILES[m.From] << PILES[m.To] << '-' << (int)m.Count << " F" << (int)m.From << "] ";
				}
			} else if (!combine) {
				ss << PILES[m.From] << PILES[m.To] << " F" << (int)m.From << ' ';
			} else {
				ss << '[' << PILES[m.From] << PILES[m.To] << " F" << (int)m.From << "] ";
			}
		} else if (!combine) {
			if (m.Extra <= stockSize) {
				ss << "DR" << (m.Extra / drawCount + ((m.Extra % drawCount) == 0 ? 0 : 1)) << ' ' << PILES[m.From] << PILES[m.To] << ' ';
			} else {
				int temp = stockSize / drawCount + ((stockSize % drawCount) == 0 ? 0 : 1);
				if (temp != 0) { ss << "DR" << temp << ' '; }
				ss << "NEW ";
				temp = m.Extra - stockSize - stockSize - wasteSize;
				temp = temp / drawCount + ((temp % drawCount) == 0 ? 0 : 1);
				ss << "DR" << temp << ' ' << PILES[m.From] << PILES[m.To] << ' ';
			}
		} else if (m.Extra <= stockSize) {
			ss << "[DR" << (m.Extra / drawCount + ((m.Extra % drawCount) == 0 ? 0 : 1)) << ' ' << PILES[m.From] << PILES[m.To] << "] ";
		} else {
			int temp = m.Extra - stockSize - stockSize - wasteSize;
			temp = temp / drawCount + ((temp % drawCount) == 0 ? 0 : 1);
			temp += stockSize / drawCount + ((stockSize % drawCount) == 0 ? 0 : 1);
			ss << "[DR" << temp << ' ' << PILES[m.From] << PILES[m.To] << "] ";
		}
	} else if (m.Count > 1) {
		ss << PILES[m.From] << PILES[m.To] << '-' << (int)m.Count << ' ';
	} else {
		ss << PILES[m.From] << PILES[m.To] << ' ';
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %esi, %r15d
movq %rdi, %rbx
movl %esi, %ebp
shrl $0x8, %ebp
movl %esi, %r14d
shrl $0x10, %r14d
cmpl $0x1000000, %esi        # imm = 0x1000000
jae 0x8a33
addq $0x10, %rbx
movl $0xff, %eax
movl %r15d, %ecx
andl %eax, %ecx
andl %eax, %ebp
leaq 0x1f9a(%rip), %r12      # 0xa964
movb (%rcx,%r12), %al
cmpl $0x20000, %r15d         # imm = 0x20000
jb 0x8afe
leaq 0xb(%rsp), %r15
movb %al, (%r15)
movl $0x1, %edx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x2200
movb (%rbp,%r12), %cl
movb %cl, (%r15)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movb $0x2d, (%rbx)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movq %rax, %rdi
movl %r14d, %esi
jmp 0x8dc6
movl %ecx, %r13d
movzbl %r15b, %ecx
testl %ecx, %ecx
je 0x8b38
movzbl %r14b, %r15d
addq $0x10, %rbx
cmpl $0x2, %r15d
jb 0x8ba0
testb %r9b, %r9b
je 0x8cdb
leaq 0xb(%rsp), %r14
movb $0x5b, (%r14)
movl $0x1, %edx
movq %rbx, %rdi
movq %rcx, %r13
movq %r14, %rsi
callq 0x2200
leaq 0x1ee4(%rip), %r12      # 0xa964
movb (%r13,%r12), %cl
movb %cl, (%r14)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movzbl %bpl, %ecx
movb (%rcx,%r12), %cl
movb %cl, (%rbx)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movb $0x2d, (%rbx)
leaq 0xb(%rsp), %rsi
movl $0x1, %edx
movq %rax, %rdi
callq 0x2200
movq %rax, %rdi
movl %r15d, %esi
callq 0x22c0
movq %rax, %rbx
leaq 0x1e8c(%rip), %rsi      # 0xa972
movl $0x2, %edx
movq %rax, %rdi
callq 0x2200
movq %rbx, %rdi
movl %r13d, %esi
jmp 0x8c21
leaq 0xb(%rsp), %r14
movb %al, (%r14)
movl $0x1, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2200
movb (%rbp,%r12), %cl
movb %cl, (%r14)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
jmp 0x8dcb
movl %edx, %r12d
shrl $0x18, %r15d
testb %r9b, %r9b
je 0x8c2b
cmpl %r12d, %r15d
jle 0x8ddd
leal (%r13,%r12,2), %eax
subl %eax, %r15d
movl %r15d, %eax
cltd
idivl %r8d
movl %edx, %ecx
movl %eax, %r14d
movl %r12d, %eax
cltd
idivl %r8d
addl %eax, %r14d
cmpl $0x1, %ecx
sbbl $-0x1, %r14d
cmpl $0x1, %edx
sbbl $-0x1, %r14d
addq $0x10, %rbx
leaq 0x1df5(%rip), %rsi      # 0xa97d
movl $0x3, %edx
movq %rbx, %rdi
callq 0x2200
movq %rbx, %rdi
movl %r14d, %esi
jmp 0x8e0b
testb %r9b, %r9b
je 0x8d63
leaq 0xb(%rsp), %r14
movb $0x5b, (%r14)
movl $0x1, %edx
movq %rbx, %rdi
movq %rcx, %r12
movq %r14, %rsi
callq 0x2200
leaq 0x1d98(%rip), %r15      # 0xa964
movb (%r12,%r15), %cl
movb %cl, (%r14)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movzbl %bpl, %ecx
movb (%rcx,%r15), %cl
movb %cl, (%rbx)
leaq 0xb(%rsp), %rsi
movl $0x1, %edx
movq %rax, %rdi
callq 0x2200
movq %rax, %rbx
leaq 0x1d64(%rip), %rsi      # 0xa972
movl $0x2, %edx
movq %rax, %rdi
callq 0x2200
movq %rbx, %rdi
movl %r12d, %esi
callq 0x22c0
jmp 0x8e62
cmpl %r12d, %r15d
jle 0x8e85
movl %r12d, %eax
cltd
movl %r8d, 0xc(%rsp)
idivl %r8d
xorl %r14d, %r14d
testl %edx, %edx
setne %r14b
addl %eax, %r14d
je 0x8c8a
leaq 0x10(%rbx), %rdi
movq %rdi, 0x10(%rsp)
leaq 0x1d20(%rip), %rsi      # 0xa97e
movl $0x2, %edx
callq 0x2200
movq 0x10(%rsp), %rdi
movl %r14d, %esi
callq 0x22c0
leaq 0xb(%rsp), %rsi
movb $0x20, (%rsi)
movl $0x1, %edx
movq %rax, %rdi
callq 0x2200
addq $0x10, %rbx
leaq 0x1ce3(%rip), %rsi      # 0xa978
movl $0x4, %edx
movq %rbx, %rdi
callq 0x2200
leal (%r13,%r12,2), %eax
subl %eax, %r15d
movl %r15d, %eax
cltd
idivl 0xc(%rsp)
movl %eax, %r14d
cmpl $0x1, %edx
sbbl $-0x1, %r14d
leaq 0x1cbb(%rip), %rsi      # 0xa97e
movl $0x2, %edx
movq %rbx, %rdi
callq 0x2200
movq %rbx, %rdi
movl %r14d, %esi
jmp 0x8eb3
leaq 0x1c82(%rip), %r12      # 0xa964
movb (%rcx,%r12), %al
leaq 0xb(%rsp), %r14
movb %al, (%r14)
movl $0x1, %edx
movq %rbx, %rdi
movq %rcx, %r13
movq %r14, %rsi
callq 0x2200
movzbl %bpl, %ecx
movb (%rcx,%r12), %cl
movb %cl, (%r14)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movb $0x2d, (%rbx)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movq %rax, %rdi
movl %r15d, %esi
callq 0x22c0
movq %rax, %r14
leaq 0x1c24(%rip), %rsi      # 0xa972
movl $0x2, %edx
movq %rax, %rdi
callq 0x2200
movq %r14, %rdi
movl %r13d, %esi
jmp 0x8dc6
leaq 0x1bfa(%rip), %r15      # 0xa964
movb (%rcx,%r15), %al
leaq 0xb(%rsp), %r14
movb %al, (%r14)
movl $0x1, %edx
movq %rbx, %rdi
movq %rcx, %r12
movq %r14, %rsi
callq 0x2200
movzbl %bpl, %ecx
movb (%rcx,%r15), %cl
movb %cl, (%r14)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movq %rax, %r14
leaq 0x1bbf(%rip), %rsi      # 0xa972
movl $0x2, %edx
movq %rax, %rdi
callq 0x2200
movq %r14, %rdi
movl %r12d, %esi
callq 0x22c0
movb $0x20, (%rbx)
leaq 0xb(%rsp), %rsi
movl $0x1, %edx
jmp 0x8e6e
addq $0x10, %rbx
leaq 0x1b95(%rip), %rsi      # 0xa97d
movl $0x3, %edx
movq %rbx, %rdi
movl %r8d, %r14d
callq 0x2200
movl %r15d, %eax
xorl %edx, %edx
idivl %r14d
cmpl $0x1, %edx
sbbl $-0x1, %eax
movq %rbx, %rdi
movl %eax, %esi
callq 0x22c0
leaq 0xb(%rsp), %rbx
movb $0x20, (%rbx)
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movb $0x57, (%rbx)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movzbl %bpl, %ecx
leaq 0x1b19(%rip), %rdx      # 0xa964
movb (%rcx,%rdx), %cl
movb %cl, (%rbx)
leaq 0xb(%rsp), %rsi
movl $0x1, %edx
movq %rax, %rdi
callq 0x2200
leaq 0x1b0c(%rip), %rsi      # 0xa975
movl $0x2, %edx
movq %rax, %rdi
callq 0x2200
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
addq $0x10, %rbx
leaq 0x1aee(%rip), %rsi      # 0xa97e
movl $0x2, %edx
movq %rbx, %rdi
movl %r8d, %r14d
callq 0x2200
movl %r15d, %eax
xorl %edx, %edx
idivl %r14d
cmpl $0x1, %edx
sbbl $-0x1, %eax
movq %rbx, %rdi
movl %eax, %esi
callq 0x22c0
movb $0x20, %r14b
leaq 0xb(%rsp), %rbx
movb %r14b, (%rbx)
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movb $0x57, (%rbx)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movzbl %bpl, %ecx
leaq 0x1a6e(%rip), %rdx      # 0xa964
movb (%rcx,%rdx), %cl
movb %cl, (%rbx)
leaq 0xb(%rsp), %rbx
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x2200
movb %r14b, (%rbx)
jmp 0x8dce