// File: /workspace/github_cpp_makefile_star2_O3/ATOMIC-LICHESS[P]ATOMKRAFT/evaluate.cpp
// Function: read_evaluation_uci_options(Color)
void read_evaluation_uci_options(Color us) {

  // King safety is asymmetrical. Our king danger level is weighted by
  // "Cowardice" UCI parameter, instead the opponent one by "Aggressiveness".
  const int kingDangerUs   = (us == WHITE ? KingDangerUs   : KingDangerThem);
  const int kingDangerThem = (us == WHITE ? KingDangerThem : KingDangerUs);

  Weights[Mobility]       = weight_option("Mobility (Middle Game)", "Mobility (Endgame)", WeightsInternal[Mobility]);
  Weights[PassedPawns]    = weight_option("Passed Pawns (Middle Game)", "Passed Pawns (Endgame)", WeightsInternal[PassedPawns]);
  Weights[Space]          = weight_option("Space", "Space", WeightsInternal[Space]);
  Weights[kingDangerUs]   = weight_option("Cowardice", "Cowardice", WeightsInternal[KingDangerUs]);
  Weights[kingDangerThem] = weight_option("Aggressiveness", "Aggressiveness", WeightsInternal[KingDangerThem]);

  // If running in analysis mode, make sure we use symmetrical king safety. We do this
  // by replacing both Weights[kingDangerUs] and Weights[kingDangerThem] by their average.
  if (Options["UCI_AnalyseMode"].value<bool>())
      Weights[kingDangerUs] = Weights[kingDangerThem] = (Weights[kingDangerUs] + Weights[kingDangerThem]) / 2;

  init_safety();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1b8, %rsp            # imm = 0x1B8
xorl %r15d, %r15d
testl %edi, %edi
sete %bl
leaq 0x30(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x20e03(%rip), %rsi     # 0x32040
leaq 0x20e12(%rip), %rdx     # 0x32056
leaq 0x20(%rsp), %rdi
callq 0xad16
leaq 0x10(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x20df8(%rip), %rsi     # 0x32057
leaq 0x20e03(%rip), %rdx     # 0x32069
movq %rsp, %rdi
callq 0xad16
movl 0x3a210c(%rip), %edx    # 0x3b3380
leaq 0x20(%rsp), %rdi
movq %rsp, %rsi
callq 0x116a9
movl %eax, 0x3a2699(%rip)    # 0x3b3920
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x1129d
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x5400
movq 0x20(%rsp), %rdi
cmpq %r14, %rdi
je 0x112b4
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x5400
leaq 0x20(%rsp), %rdi
movq %r14, (%rdi)
leaq 0x20da7(%rip), %rsi     # 0x3206a
leaq 0x20dba(%rip), %rdx     # 0x32084
callq 0xad16
movq %rsp, %rdi
movq %r12, (%rdi)
leaq 0x20da9(%rip), %rsi     # 0x32085
leaq 0x20db8(%rip), %rdx     # 0x3209b
callq 0xad16
movl 0x3a2096(%rip), %edx    # 0x3b3384
leaq 0x20(%rsp), %rdi
movq %rsp, %rsi
callq 0x116a9
movl %eax, 0x3a2623(%rip)    # 0x3b3924
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x11317
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x5400
movq 0x20(%rsp), %rdi
cmpq %r14, %rdi
je 0x1132e
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x5400
leaq 0x20(%rsp), %rdi
movq %r14, (%rdi)
leaq 0x20d5f(%rip), %rsi     # 0x3209c
leaq 0x20d5d(%rip), %rdx     # 0x320a1
callq 0xad16
movq %rsp, %rdi
movq %r12, (%rdi)
leaq 0x20d46(%rip), %rsi     # 0x3209c
leaq 0x20d44(%rip), %rdx     # 0x320a1
callq 0xad16
movl 0x3a2020(%rip), %edx    # 0x3b3388
leaq 0x20(%rsp), %rdi
movq %rsp, %rsi
callq 0x116a9
movl %eax, 0x3a25ad(%rip)    # 0x3b3928
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x11391
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x5400
movq 0x20(%rsp), %rdi
cmpq %r14, %rdi
je 0x113a8
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x5400
leaq 0x20(%rsp), %rdi
movq %r14, (%rdi)
leaq 0x20ceb(%rip), %rsi     # 0x320a2
leaq 0x20ced(%rip), %rdx     # 0x320ab
callq 0xad16
movq %rsp, %rdi
movq %r12, (%rdi)
leaq 0x20cd2(%rip), %rsi     # 0x320a2
leaq 0x20cd4(%rip), %rdx     # 0x320ab
callq 0xad16
movl 0x3a1faa(%rip), %edx    # 0x3b338c
leaq 0x20(%rsp), %rdi
movq %rsp, %rsi
callq 0x116a9
movb %bl, %r15b
movl $0x4, %ebp
subq %r15, %rbp
leaq 0x3a251f(%rip), %r13    # 0x3b3920
movl %eax, (%r13,%rbp,4)
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x1141c
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x5400
movq 0x20(%rsp), %rdi
cmpq %r14, %rdi
je 0x11433
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x5400
leaq 0x20(%rsp), %rdi
movq %r14, (%rdi)
leaq 0x20c6a(%rip), %rsi     # 0x320ac
leaq 0x20c71(%rip), %rdx     # 0x320ba
callq 0xad16
movq %rsp, %rdi
movq %r12, (%rdi)
leaq 0x20c51(%rip), %rsi     # 0x320ac
leaq 0x20c58(%rip), %rdx     # 0x320ba
callq 0xad16
movl 0x3a1f23(%rip), %edx    # 0x3b3390
leaq 0x20(%rsp), %rdi
movq %rsp, %rsi
callq 0x116a9
addq $0x3, %r15
movl %eax, (%r13,%r15,4)
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x11499
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x5400
movq 0x20(%rsp), %rdi
cmpq %r14, %rdi
je 0x114b0
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x5400
leaq 0x20(%rsp), %rdi
movq %r14, (%rdi)
leaq 0x20bfc(%rip), %rsi     # 0x320bb
leaq 0x20c04(%rip), %rdx     # 0x320ca
callq 0xad16
leaq 0x3bcba6(%rip), %rdi    # 0x3ce078
leaq 0x20(%rsp), %rsi
callq 0x15a9c
addq $0x20, %rax
leaq 0x20d30(%rip), %rsi     # 0x32217
movq %rax, %rdi
callq 0x5120
movl %eax, %ebx
movq 0x20(%rsp), %rdi
cmpq %r14, %rdi
je 0x11508
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x5400
testl %ebx, %ebx
jne 0x11554
movl (%r13,%r15,4), %eax
addl (%r13,%rbp,4), %eax
movl $0x8000, %ecx           # imm = 0x8000
leal (%rax,%rcx), %edx
movl %edx, %esi
shrl $0x10, %esi
shrl $0x1f, %edx
addl %esi, %edx
movswl %dx, %edx
movl %eax, %esi
andl $0x7fff, %esi           # imm = 0x7FFF
andl %ecx, %eax
subl %eax, %esi
movzwl %si, %eax
shrl $0xf, %eax
addl %esi, %eax
cwtl
sarl %eax
andl $-0x2, %edx
shll $0xf, %edx
addl %eax, %edx
movl %edx, (%r13,%r15,4)
movl %edx, (%r13,%rbp,4)
xorl %eax, %eax
movsd 0x20952(%rip), %xmm0    # 0x31eb0
xorps %xmm1, %xmm1
cvtsi2sd %eax, %xmm1
movapd %xmm1, %xmm2
mulsd %xmm0, %xmm2
mulsd %xmm1, %xmm2
cvttsd2si %xmm2, %ecx
testq %rax, %rax
je 0x11589
movl 0x1c(%rsp,%rax,4), %edx
addl $0x1e, %edx
cmpl %ecx, %edx
jl 0x11587
movl %ecx, %edx
movl %edx, %ecx
movl $0x500, %edx            # imm = 0x500
cmpl %edx, %ecx
jl 0x11597
movl $0x500, %ecx            # imm = 0x500
movl %ecx, 0x20(%rsp,%rax,4)
incq %rax
cmpq $0x64, %rax
jne 0x1155e
movb $0x1, %al
xorl %ecx, %ecx
movl $0x8000, %edx           # imm = 0x8000
movdqa 0x2092b(%rip), %xmm0    # 0x31ee0
leaq 0x3a2404(%rip), %rsi    # 0x3b39c0
movl 0xc(%r13,%rcx,4), %edi
addl %edx, %edi
movd %edi, %xmm1
pshufd $0x0, %xmm1, %xmm1      # xmm1 = xmm1[0,0,0,0]
psrad $0x10, %xmm1
shlq $0x9, %rcx
packssdw %xmm1, %xmm1
xorl %edi, %edi
pshuflw $0xe8, 0x20(%rsp,%rdi,4), %xmm2 # xmm2 = mem[0,2,2,3,4,5,6,7]
pshufhw $0xe8, %xmm2, %xmm2     # xmm2 = xmm2[0,1,2,3,4,6,6,7]
pshufd $0xe8, %xmm2, %xmm2     # xmm2 = xmm2[0,2,2,3]
movdqa %xmm2, %xmm3
pmulhw %xmm1, %xmm3
pmullw %xmm1, %xmm2
punpcklwd %xmm3, %xmm2    # xmm2 = xmm2[0],xmm3[0],xmm2[1],xmm3[1],xmm2[2],xmm3[2],xmm2[3],xmm3[3]
movdqa %xmm2, %xmm3
psrad $0x1f, %xmm3
psrld $0x18, %xmm3
paddd %xmm2, %xmm3
pslld $0x8, %xmm3
pand %xmm0, %xmm3
leaq (%rcx,%rdi,4), %r8
movdqa %xmm3, (%rsi,%r8)
addq $0x4, %rdi
cmpq $0x64, %rdi
jne 0x115db
movl $0x1, %ecx
testb $0x1, %al
movl $0x0, %eax
jne 0x115bc
addq $0x1b8, %rsp            # imm = 0x1B8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x11682
jmp 0x1169e
jmp 0x11667
jmp 0x11682
jmp 0x1169e
jmp 0x11667
jmp 0x11682
jmp 0x1169e
jmp 0x11667
jmp 0x11682
jmp 0x1169e
jmp 0x11667
jmp 0x11682
jmp 0x1169e
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x11685
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x5400
jmp 0x11685
movq %rax, %rbx
movq 0x20(%rsp), %rdi
cmpq %r14, %rdi
je 0x116a1
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x5400
jmp 0x116a1
movq %rax, %rbx
movq %rbx, %rdi
callq 0x5790