// File: /workspace/github_cpp_makefile_star2_O3/tewalds[P]morat/hex/gtpgeneral.cpp
// Function: Morat::Hex::GTP::gtp_boardsize(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>)
GTPResponse GTP::gtp_boardsize(vecstr args){
	if(args.size() != 1)
		return GTPResponse(false, "Current board size: " + hist->size());

	if(!Board::valid_size(args[0]))
		return GTPResponse(false, "Size " + args[0] + " is out of range.");

	hist = History<Board>(Board(args[0]));
	set_board();
	time_control.new_game();

	return GTPResponse(true);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x128, %rsp            # imm = 0x128
movq %rdi, %rbx
movq (%rdx), %rdi
movq 0x8(%rdx), %rax
movq %rsi, %r14
subq %rdi, %rax
cmpq $0x20, %rax
jne 0x29791
movq %rdx, %r15
callq 0xaf9d
addl $-0x3, %eax
cmpl $0x17, %eax
jae 0x297ed
movq (%r15), %rax
leaq 0xd0(%rsp), %r12
leaq 0xc0(%rsp), %r15
movq %r12, -0x10(%r12)
movq %r15, %rdi
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
callq 0xa930
leaq 0xe0(%rsp), %rdi
movq %r15, %rsi
callq 0x9c30
leaq 0xe0(%rsp), %rsi
movq %rsp, %rdi
callq 0x9d0c
vmovaps (%rsp), %xmm0
movq 0x68(%r14), %rdi
vxorps %xmm1, %xmm1, %xmm1
vmovups %xmm0, 0x68(%r14)
movq 0x10(%rsp), %rax
movq %rax, 0x78(%r14)
vmovaps %xmm1, (%rsp)
movq $0x0, 0x10(%rsp)
testq %rdi, %rdi
je 0x2962e
callq 0x52e0
vxorps %xmm1, %xmm1, %xmm1
movzwl 0x20(%rsp), %eax
movw %ax, 0x88(%r14)
movq 0x18(%rsp), %rax
movq %rax, 0x80(%r14)
vmovups 0x28(%rsp), %xmm0
movq 0x90(%r14), %rdi
vmovups %xmm0, 0x90(%r14)
movq 0x38(%rsp), %rax
movq %rax, 0xa0(%r14)
vmovups %xmm1, 0x28(%rsp)
movq $0x0, 0x38(%rsp)
testq %rdi, %rdi
je 0x29682
callq 0x52e0
vmovaps 0x40(%rsp), %xmm0
vxorps %xmm1, %xmm1, %xmm1
vmovups %xmm0, 0xa8(%r14)
vmovaps 0x50(%rsp), %xmm0
vmovaps %xmm1, 0x50(%rsp)
movq 0xc0(%r14), %rdi
vmovups %xmm0, 0xb8(%r14)
testq %rdi, %rdi
je 0x296ca
callq 0xb272
movq 0x58(%rsp), %rdi
testq %rdi, %rdi
je 0x296ca
callq 0xb272
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x296d9
callq 0x52e0
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x296e7
callq 0x52e0
movq 0x120(%rsp), %rdi
testq %rdi, %rdi
je 0x296f9
callq 0xb272
movq 0xf0(%rsp), %rdi
testq %rdi, %rdi
je 0x2970b
callq 0x52e0
movq 0xc0(%rsp), %rdi
leaq 0x80(%r14), %r15
cmpq %r12, %rdi
je 0x29724
callq 0x52e0
movq 0xd8(%r14), %rdi
movl $0x1, %edx
movq %r15, %rsi
movq (%rdi), %rax
callq *0x20(%rax)
vmovsd 0x40(%r14), %xmm0
leaq 0x81c1(%rip), %rdx      # 0x31907
leaq 0xb0(%rsp), %r15
movq %rdx, %rsi
vmovsd %xmm0, 0x60(%r14)
leaq 0xa0(%rsp), %r14
movq %r15, -0x10(%r15)
movq %r14, %rdi
callq 0xb1dc
movl $0x1, %esi
movq %rbx, %rdi
movq %r14, %rdx
callq 0xa8ba
movq 0xa0(%rsp), %rdi
cmpq %r15, %rdi
jne 0x298c0
jmp 0x298c5
movsbl 0x80(%r14), %esi
movq %rsp, %r14
movq %r14, %rdi
callq 0x1131a
leaq 0xc2e5(%rip), %rcx      # 0x35a90
movl $0x14, %r8d
movq %r14, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x5380
leaq 0x90(%rsp), %r14
movq %rax, %rcx
addq $0x10, %rcx
movq %r14, -0x10(%r14)
movq (%rax), %rdx
cmpq %rcx, %rdx
je 0x29838
movq %rdx, 0x80(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x90(%rsp)
jmp 0x29841
movq (%r15), %rdx
leaq 0xc2ae(%rip), %rsi      # 0x35aa5
movq %rsp, %r14
movq %r14, %rdi
callq 0x98b3
leaq 0xc2a2(%rip), %rsi      # 0x35aab
movq %r14, %rdi
callq 0x56e0
leaq 0x70(%rsp), %r14
movq %rax, %rcx
addq $0x10, %rcx
movq %r14, -0x10(%r14)
movq (%rax), %rdx
cmpq %rcx, %rdx
je 0x29874
movq %rdx, 0x60(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x70(%rsp)
jmp 0x2987d
vmovups (%rcx), %xmm0
vmovups %xmm0, (%r14)
movq 0x8(%rax), %rsi
leaq 0x80(%rsp), %rdx
movq %rsi, 0x8(%rdx)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq %rbx, %rdi
xorl %esi, %esi
callq 0xa8ba
movq 0x80(%rsp), %rdi
jmp 0x298a8
vmovups (%rcx), %xmm0
vmovups %xmm0, (%r14)
movq 0x8(%rax), %rsi
leaq 0x60(%rsp), %rdx
movq %rsi, 0x8(%rdx)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq %rbx, %rdi
xorl %esi, %esi
callq 0xa8ba
movq 0x60(%rsp), %rdi
cmpq %r14, %rdi
je 0x298b2
callq 0x52e0
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x298c5
callq 0x52e0
movq %rbx, %rax
addq $0x128, %rsp            # imm = 0x128
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq 0xa0(%rsp), %rdi
movq %rax, %rbx
cmpq %r15, %rdi
jne 0x2993e
jmp 0x29943
movq 0x60(%rsp), %rdi
jmp 0x2991e
leaq 0xe0(%rsp), %rdi
movq %rax, %rbx
callq 0x9d96
jmp 0x29907
jmp 0x2992d
movq %rax, %rbx
movq 0xc0(%rsp), %rdi
cmpq %r12, %rdi
jne 0x2993e
jmp 0x29943
movq 0x80(%rsp), %rdi
movq %rax, %rbx
cmpq %r14, %rdi
je 0x29930
callq 0x52e0
jmp 0x29930
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x29943
callq 0x52e0
movq %rbx, %rdi
callq 0x5670
nop