// File: /workspace/github_c_makefile_star2_O0/josch[P]stride/geometry.c
// Function: Ang
float Ang(float *Coord1, float *Coord2, float *Coord3)
{
  float Vector1[3], Vector2[3];
  double A, B, C, D;

  Vector1[0] = Coord1[0] - Coord2[0];
  Vector1[1] = Coord1[1] - Coord2[1];
  Vector1[2] = Coord1[2] - Coord2[2];

  Vector2[0] = Coord3[0] - Coord2[0];
  Vector2[1] = Coord3[1] - Coord2[1];
  Vector2[2] = Coord3[2] - Coord2[2];

  A = Vector1[0]*Vector2[0]+Vector1[1]*Vector2[1]+Vector1[2]*Vector2[2];
  B = sqrt( Vector1[0]*Vector1[0]+Vector1[1]*Vector1[1]+Vector1[2]*Vector1[2]);
  C = sqrt( Vector2[0]*Vector2[0]+Vector2[1]*Vector2[1]+Vector2[2]*Vector2[2]);

  D = A/(B*C);
  if( D > 0.0 && fabs(D - 1.0) < Eps ) 
    D -= Eps;
  else
  if( D < 0.0 && fabs(D + 1.0) < Eps ) 
    D += Eps;
  
  return((float)(RADDEG*acos(D)));
}

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x50(%rsp)
movq %rsi, 0x48(%rsp)
movq %rdx, 0x40(%rsp)
movq 0x50(%rsp), %rax
movss (%rax), %xmm0
movq 0x48(%rsp), %rax
subss (%rax), %xmm0
movss %xmm0, 0x34(%rsp)
movq 0x50(%rsp), %rax
movss 0x4(%rax), %xmm0
movq 0x48(%rsp), %rax
subss 0x4(%rax), %xmm0
movss %xmm0, 0x38(%rsp)
movq 0x50(%rsp), %rax
movss 0x8(%rax), %xmm0
movq 0x48(%rsp), %rax
subss 0x8(%rax), %xmm0
movss %xmm0, 0x3c(%rsp)
movq 0x40(%rsp), %rax
movss (%rax), %xmm0
movq 0x48(%rsp), %rax
subss (%rax), %xmm0
movss %xmm0, 0x28(%rsp)
movq 0x40(%rsp), %rax
movss 0x4(%rax), %xmm0
movq 0x48(%rsp), %rax
subss 0x4(%rax), %xmm0
movss %xmm0, 0x2c(%rsp)
movq 0x40(%rsp), %rax
movss 0x8(%rax), %xmm0
movq 0x48(%rsp), %rax
subss 0x8(%rax), %xmm0
movss %xmm0, 0x30(%rsp)
movss 0x34(%rsp), %xmm1
movss 0x28(%rsp), %xmm2
movss 0x38(%rsp), %xmm0
mulss 0x2c(%rsp), %xmm0
mulss %xmm2, %xmm1
addss %xmm0, %xmm1
movss 0x3c(%rsp), %xmm0
movss 0x30(%rsp), %xmm2
mulss %xmm2, %xmm0
addss %xmm1, %xmm0
cvtss2sd %xmm0, %xmm0
movsd %xmm0, 0x20(%rsp)
movss 0x34(%rsp), %xmm1
movss 0x34(%rsp), %xmm2
movss 0x38(%rsp), %xmm0
mulss 0x38(%rsp), %xmm0
mulss %xmm2, %xmm1
addss %xmm0, %xmm1
movss 0x3c(%rsp), %xmm0
movss 0x3c(%rsp), %xmm2
mulss %xmm2, %xmm0
addss %xmm1, %xmm0
cvtss2sd %xmm0, %xmm0
callq 0x2220
movsd %xmm0, 0x18(%rsp)
movss 0x28(%rsp), %xmm1
movss 0x28(%rsp), %xmm2
movss 0x2c(%rsp), %xmm0
mulss 0x2c(%rsp), %xmm0
mulss %xmm2, %xmm1
addss %xmm0, %xmm1
movss 0x30(%rsp), %xmm0
movss 0x30(%rsp), %xmm2
mulss %xmm2, %xmm0
addss %xmm1, %xmm0
cvtss2sd %xmm0, %xmm0
callq 0x2220
movsd %xmm0, 0x10(%rsp)
movsd 0x20(%rsp), %xmm0
movsd 0x18(%rsp), %xmm1
mulsd 0x10(%rsp), %xmm1
divsd %xmm1, %xmm0
movsd %xmm0, 0x8(%rsp)
movsd 0x8(%rsp), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jbe 0x4caf
movsd 0x8(%rsp), %xmm1
movsd 0x26b80(%rip), %xmm0    # 0x2b7f8
subsd %xmm0, %xmm1
movaps 0x26bcd(%rip), %xmm0    # 0x2b850
pand %xmm0, %xmm1
movsd 0x26b61(%rip), %xmm0    # 0x2b7f0
ucomisd %xmm1, %xmm0
jbe 0x4caf
movsd 0x8(%rsp), %xmm0
movsd 0x26b4d(%rip), %xmm1    # 0x2b7f0
subsd %xmm1, %xmm0
movsd %xmm0, 0x8(%rsp)
jmp 0x4cf7
xorps %xmm0, %xmm0
ucomisd 0x8(%rsp), %xmm0
jbe 0x4cf5
movsd 0x26b36(%rip), %xmm1    # 0x2b7f8
addsd 0x8(%rsp), %xmm1
movaps 0x26b81(%rip), %xmm0    # 0x2b850
pand %xmm0, %xmm1
movsd 0x26b15(%rip), %xmm0    # 0x2b7f0
ucomisd %xmm1, %xmm0
jbe 0x4cf5
movsd 0x26b07(%rip), %xmm0    # 0x2b7f0
addsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
jmp 0x4cf7
movsd 0x8(%rsp), %xmm0
callq 0x2100
movaps %xmm0, %xmm1
movsd 0x26af3(%rip), %xmm0    # 0x2b800
mulsd %xmm1, %xmm0
cvtsd2ss %xmm0, %xmm0
addq $0x58, %rsp
retq
nopw (%rax,%rax)