// File: WolfgangLechner[P]StructureAnalysis/molecular_system.cpp
// Function: CMolecularSystem::norm_Q4Q6Histograms()
void CMolecularSystem::norm_Q4Q6Histograms()
{
  double normBCC, normHCP, normFCC, normLIQ;
  normBCC = 0.0;
  normHCP = 0.0;
  normFCC = 0.0;
  normLIQ = 0.0;
  for (int ti = 0;ti<Q4SIZE;ti++)
  {
    for (int tj = 0;tj<Q6SIZE;tj++)
    {
      normBCC += QBCC[ti][tj];
      normFCC += QFCC[ti][tj];
      normHCP += QHCP[ti][tj];
      normLIQ += QLIQ[ti][tj];
    }
  }
  for (int ti = 0;ti<Q4SIZE;ti++)
  {
    for (int tj = 0;tj<Q6SIZE;tj++)
    {
      QBCC[ti][tj] /= normBCC;
      QFCC[ti][tj] /= normFCC;
      QHCP[ti][tj] /= normHCP;
      QLIQ[ti][tj] /= normLIQ;
    }
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x40(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x10(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x18(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x20(%rbp)
xorps %xmm0, %xmm0
movsd %xmm0, -0x28(%rbp)
movl $0x0, -0x2c(%rbp)
cmpl $0xc8, -0x2c(%rbp)
jge 0x8c02
movl $0x0, -0x30(%rbp)
cmpl $0x258, -0x30(%rbp)     # imm = 0x258
jge 0x8bf2
movq -0x40(%rbp), %rax
movq %rax, %rcx
addq $0x7a50b8, %rcx         # imm = 0x7A50B8
movslq -0x2c(%rbp), %rdx
imulq $0x12c0, %rdx, %rdx     # imm = 0x12C0
addq %rdx, %rcx
movslq -0x30(%rbp), %rdx
movsd (%rcx,%rdx,8), %xmm0
addsd -0x10(%rbp), %xmm0
movsd %xmm0, -0x10(%rbp)
movq %rax, %rcx
addq $0x88f6b8, %rcx         # imm = 0x88F6B8
movslq -0x2c(%rbp), %rdx
imulq $0x12c0, %rdx, %rdx     # imm = 0x12C0
addq %rdx, %rcx
movslq -0x30(%rbp), %rdx
movsd (%rcx,%rdx,8), %xmm0
addsd -0x20(%rbp), %xmm0
movsd %xmm0, -0x20(%rbp)
movq %rax, %rcx
addq $0x979cb8, %rcx         # imm = 0x979CB8
movslq -0x2c(%rbp), %rdx
imulq $0x12c0, %rdx, %rdx     # imm = 0x12C0
addq %rdx, %rcx
movslq -0x30(%rbp), %rdx
movsd (%rcx,%rdx,8), %xmm0
addsd -0x18(%rbp), %xmm0
movsd %xmm0, -0x18(%rbp)
addq $0xa642b8, %rax         # imm = 0xA642B8
movslq -0x2c(%rbp), %rcx
imulq $0x12c0, %rcx, %rcx     # imm = 0x12C0
addq %rcx, %rax
movslq -0x30(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
addsd -0x28(%rbp), %xmm0
movsd %xmm0, -0x28(%rbp)
movl -0x30(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
jmp 0x8b2b
jmp 0x8bf4
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x8b17
movl $0x0, -0x34(%rbp)
cmpl $0xc8, -0x34(%rbp)
jge 0x8d04
movl $0x0, -0x38(%rbp)
cmpl $0x258, -0x38(%rbp)     # imm = 0x258
jge 0x8cf4
movq -0x40(%rbp), %rax
movsd -0x10(%rbp), %xmm1
movq %rax, %rcx
addq $0x7a50b8, %rcx         # imm = 0x7A50B8
movslq -0x34(%rbp), %rdx
imulq $0x12c0, %rdx, %rdx     # imm = 0x12C0
addq %rdx, %rcx
movslq -0x38(%rbp), %rdx
movsd (%rcx,%rdx,8), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, (%rcx,%rdx,8)
movsd -0x20(%rbp), %xmm1
movq %rax, %rcx
addq $0x88f6b8, %rcx         # imm = 0x88F6B8
movslq -0x34(%rbp), %rdx
imulq $0x12c0, %rdx, %rdx     # imm = 0x12C0
addq %rdx, %rcx
movslq -0x38(%rbp), %rdx
movsd (%rcx,%rdx,8), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, (%rcx,%rdx,8)
movsd -0x18(%rbp), %xmm1
movq %rax, %rcx
addq $0x979cb8, %rcx         # imm = 0x979CB8
movslq -0x34(%rbp), %rdx
imulq $0x12c0, %rdx, %rdx     # imm = 0x12C0
addq %rdx, %rcx
movslq -0x38(%rbp), %rdx
movsd (%rcx,%rdx,8), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, (%rcx,%rdx,8)
movsd -0x28(%rbp), %xmm1
addq $0xa642b8, %rax         # imm = 0xA642B8
movslq -0x34(%rbp), %rcx
imulq $0x12c0, %rcx, %rcx     # imm = 0x12C0
addq %rcx, %rax
movslq -0x38(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, (%rax,%rcx,8)
movl -0x38(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x38(%rbp)
jmp 0x8c1d
jmp 0x8cf6
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x8c09
popq %rbp
retq
nopw %cs:(%rax,%rax)