#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
float fabs(float);
float log(float);
float pow(float, int);
float slamch(char *);
float sqrt(float);
void slartg(float f__, float g__, float *cs, float *sn, float *r) {
  static int first = 1;
  int i__1;
  float r__1, r__2;
  static int i;
  static float scale;
  static int count;
  static float f1, g1, safmn2, safmx2;
  static float safmin, eps;
  if (first) {
    first = 0;
    safmin = slamch("S");
    eps = slamch("E");
    r__1 = slamch("B");
    i__1 = (int)(log(safmin / eps) / log(slamch("B")) / 2.f);
    safmn2 = pow(r__1, i__1);
    safmx2 = 1.f / safmn2;
  }
  if (g__ == 0.f) {
    *cs = 1.f;
    *sn = 0.f;
    *r = f__;
  } else if (f__ == 0.f) {
    *cs = 0.f;
    *sn = 1.f;
    *r = g__;
  } else {
    f1 = f__;
    g1 = g__;
    r__1 = fabs(f1), r__2 = fabs(g1);
    scale = (((r__1) > (r__2)) ? (r__1) : (r__2));
    if (scale >= safmx2) {
      count = 0;
    L10:
      ++count;
      f1 *= safmn2;
      g1 *= safmn2;
      r__1 = fabs(f1), r__2 = fabs(g1);
      scale = (((r__1) > (r__2)) ? (r__1) : (r__2));
      if (scale >= safmx2) {
        goto L10;
      }
      r__1 = f1;
      r__2 = g1;
      *r = sqrt(r__1 * r__1 + r__2 * r__2);
      *cs = f1 / *r;
      *sn = g1 / *r;
      i__1 = count;
      for (i = 1; i <= count; ++i) {
        *r *= safmx2;
      }
    } else if (scale <= safmn2) {
      count = 0;
    L30:
      ++count;
      f1 *= safmx2;
      g1 *= safmx2;
      r__1 = fabs(f1), r__2 = fabs(g1);
      scale = (((r__1) > (r__2)) ? (r__1) : (r__2));
      if (scale <= safmn2) {
        goto L30;
      }
      r__1 = f1;
      r__2 = g1;
      *r = sqrt(r__1 * r__1 + r__2 * r__2);
      *cs = f1 / *r;
      *sn = g1 / *r;
      i__1 = count;
      for (i = 1; i <= count; ++i) {
        *r *= safmn2;
      }
    } else {
      r__1 = f1;
      r__2 = g1;
      *r = sqrt(r__1 * r__1 + r__2 * r__2);
      *cs = f1 / *r;
      *sn = g1 / *r;
    }
    if (fabs(f__) > fabs(g__) && *cs < 0.f) {
      *cs = -(double)(*cs);
      *sn = -(double)(*sn);
      *r = -(double)(*r);
    }
  }
}


x86 assembly (clang, -O0):
<slartg>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movss  %xmm0,-0x4(%rbp)
movss  %xmm1,-0x8(%rbp)
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
cmpl   $0x0,0x2ed3(%rip)
je     1235 <slartg+0xe5>
movl   $0x0,0x2ec3(%rip)
lea    0xe7c(%rip),%rdi
call   1040 <slamch@plt>
movss  %xmm0,0x2ed3(%rip)
lea    0xe6a(%rip),%rdi
call   1040 <slamch@plt>
movss  %xmm0,0x2ec3(%rip)
lea    0xe58(%rip),%rdi
call   1040 <slamch@plt>
movss  %xmm0,-0x28(%rbp)
movss  0x2ea6(%rip),%xmm0
divss  0x2ea2(%rip),%xmm0
call   1050 <log@plt>
movss  %xmm0,-0x30(%rbp)
lea    0xe2d(%rip),%rdi
call   1040 <slamch@plt>
call   1050 <log@plt>
movaps %xmm0,%xmm1
movss  -0x30(%rbp),%xmm0
divss  %xmm1,%xmm0
movss  0xe07(%rip),%xmm1
divss  %xmm1,%xmm0
cvttss2si %xmm0,%eax
mov    %eax,-0x24(%rbp)
movss  -0x28(%rbp),%xmm0
mov    -0x24(%rbp),%edi
call   1060 <pow@plt>
movss  %xmm0,0x2e47(%rip)
movss  0xddb(%rip),%xmm0
divss  0x2e37(%rip),%xmm0
movss  %xmm0,0x2e33(%rip)
movss  -0x8(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomiss %xmm1,%xmm0
jne    1279 <slartg+0x129>
jp     1279 <slartg+0x129>
mov    -0x10(%rbp),%rax
movss  0xda8(%rip),%xmm0
movss  %xmm0,(%rax)
mov    -0x18(%rbp),%rax
xorps  %xmm0,%xmm0
movss  %xmm0,(%rax)
movss  -0x4(%rbp),%xmm0
mov    -0x20(%rbp),%rax
movss  %xmm0,(%rax)
jmp    17ad <slartg+0x65d>
movss  -0x4(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomiss %xmm1,%xmm0
jne    12bd <slartg+0x16d>
jp     12bd <slartg+0x16d>
mov    -0x10(%rbp),%rax
xorps  %xmm0,%xmm0
movss  %xmm0,(%rax)
mov    -0x18(%rbp),%rax
movss  0xd59(%rip),%xmm0
movss  %xmm0,(%rax)
movss  -0x8(%rbp),%xmm0
mov    -0x20(%rbp),%rax
movss  %xmm0,(%rax)
jmp    17a8 <slartg+0x658>
movss  -0x4(%rbp),%xmm0
movss  %xmm0,0x2d92(%rip)
movss  -0x8(%rbp),%xmm0
movss  %xmm0,0x2d89(%rip)
movss  0x2d7d(%rip),%xmm0
call   1030 <fabs@plt>
movss  %xmm0,-0x28(%rbp)
movss  0x2d6f(%rip),%xmm0
call   1030 <fabs@plt>
movss  %xmm0,-0x2c(%rbp)
movss  -0x28(%rbp),%xmm0
ucomiss -0x2c(%rbp),%xmm0
jbe    1319 <slartg+0x1c9>
movss  -0x28(%rbp),%xmm0
movss  %xmm0,-0x34(%rbp)
jmp    1323 <slartg+0x1d3>
movss  -0x2c(%rbp),%xmm0
movss  %xmm0,-0x34(%rbp)
movss  -0x34(%rbp),%xmm0
movss  %xmm0,0x2d24(%rip)
movss  0x2d1c(%rip),%xmm0
ucomiss 0x2d29(%rip),%xmm0
jb     14c6 <slartg+0x376>
movl   $0x0,0x2d09(%rip)
mov    0x2d03(%rip),%eax
add    $0x1,%eax
mov    %eax,0x2cfa(%rip)
movss  0x2cfe(%rip),%xmm0
mulss  0x2cee(%rip),%xmm0
movss  %xmm0,0x2ce6(%rip)
movss  0x2ce6(%rip),%xmm0
mulss  0x2cda(%rip),%xmm0
movss  %xmm0,0x2cd2(%rip)
movss  0x2cc6(%rip),%xmm0
call   1030 <fabs@plt>
movss  %xmm0,-0x28(%rbp)
movss  0x2cb8(%rip),%xmm0
call   1030 <fabs@plt>
movss  %xmm0,-0x2c(%rbp)
movss  -0x28(%rbp),%xmm0
ucomiss -0x2c(%rbp),%xmm0
jbe    13d0 <slartg+0x280>
movss  -0x28(%rbp),%xmm0
movss  %xmm0,-0x38(%rbp)
jmp    13da <slartg+0x28a>
movss  -0x2c(%rbp),%xmm0
movss  %xmm0,-0x38(%rbp)
movss  -0x38(%rbp),%xmm0
movss  %xmm0,0x2c6d(%rip)
movss  0x2c65(%rip),%xmm0
ucomiss 0x2c72(%rip),%xmm0
jb     1401 <slartg+0x2b1>
jmp    134f <slartg+0x1ff>
movss  0x2c53(%rip),%xmm0
movss  %xmm0,-0x28(%rbp)
movss  0x2c4a(%rip),%xmm0
movss  %xmm0,-0x2c(%rbp)
movss  -0x28(%rbp),%xmm0
movss  -0x28(%rbp),%xmm2
movss  -0x2c(%rbp),%xmm1
mulss  -0x2c(%rbp),%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
call   1070 <sqrt@plt>
mov    -0x20(%rbp),%rax
movss  %xmm0,(%rax)
movss  0x2c10(%rip),%xmm0
mov    -0x20(%rbp),%rax
divss  (%rax),%xmm0
mov    -0x10(%rbp),%rax
movss  %xmm0,(%rax)
movss  0x2bfc(%rip),%xmm0
mov    -0x20(%rbp),%rax
divss  (%rax),%xmm0
mov    -0x18(%rbp),%rax
movss  %xmm0,(%rax)
mov    0x2bde(%rip),%eax
mov    %eax,-0x24(%rbp)
movl   $0x1,0x2bc9(%rip)
mov    0x2bc3(%rip),%eax
cmp    0x2bc5(%rip),%eax
jg     14c1 <slartg+0x371>
movss  0x2bc7(%rip),%xmm0
mov    -0x20(%rbp),%rax
mulss  (%rax),%xmm0
movss  %xmm0,(%rax)
mov    0x2b9d(%rip),%eax
add    $0x1,%eax
mov    %eax,0x2b94(%rip)
jmp    1487 <slartg+0x337>
jmp    16dc <slartg+0x58c>
movss  0x2b86(%rip),%xmm1
movss  0x2b8e(%rip),%xmm0
ucomiss %xmm1,%xmm0
jb     1664 <slartg+0x514>
movl   $0x0,0x2b6f(%rip)
mov    0x2b69(%rip),%eax
add    $0x1,%eax
mov    %eax,0x2b60(%rip)
movss  0x2b68(%rip),%xmm0
mulss  0x2b54(%rip),%xmm0
movss  %xmm0,0x2b4c(%rip)
movss  0x2b50(%rip),%xmm0
mulss  0x2b40(%rip),%xmm0
movss  %xmm0,0x2b38(%rip)
movss  0x2b2c(%rip),%xmm0
call   1030 <fabs@plt>
movss  %xmm0,-0x28(%rbp)
movss  0x2b1e(%rip),%xmm0
call   1030 <fabs@plt>
movss  %xmm0,-0x2c(%rbp)
movss  -0x28(%rbp),%xmm0
ucomiss -0x2c(%rbp),%xmm0
jbe    156a <slartg+0x41a>
movss  -0x28(%rbp),%xmm0
movss  %xmm0,-0x3c(%rbp)
jmp    1574 <slartg+0x424>
movss  -0x2c(%rbp),%xmm0
movss  %xmm0,-0x3c(%rbp)
movss  -0x3c(%rbp),%xmm0
movss  %xmm0,0x2ad3(%rip)
movss  0x2acb(%rip),%xmm1
movss  0x2ad3(%rip),%xmm0
ucomiss %xmm1,%xmm0
jb     159f <slartg+0x44f>
jmp    14e9 <slartg+0x399>
movss  0x2ab5(%rip),%xmm0
movss  %xmm0,-0x28(%rbp)
movss  0x2aac(%rip),%xmm0
movss  %xmm0,-0x2c(%rbp)
movss  -0x28(%rbp),%xmm0
movss  -0x28(%rbp),%xmm2
movss  -0x2c(%rbp),%xmm1
mulss  -0x2c(%rbp),%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
call   1070 <sqrt@plt>
mov    -0x20(%rbp),%rax
movss  %xmm0,(%rax)
movss  0x2a72(%rip),%xmm0
mov    -0x20(%rbp),%rax
divss  (%rax),%xmm0
mov    -0x10(%rbp),%rax
movss  %xmm0,(%rax)
movss  0x2a5e(%rip),%xmm0
mov    -0x20(%rbp),%rax
divss  (%rax),%xmm0
mov    -0x18(%rbp),%rax
movss  %xmm0,(%rax)
mov    0x2a40(%rip),%eax
mov    %eax,-0x24(%rbp)
movl   $0x1,0x2a2b(%rip)
mov    0x2a25(%rip),%eax
cmp    0x2a27(%rip),%eax
jg     165f <slartg+0x50f>
movss  0x2a25(%rip),%xmm0
mov    -0x20(%rbp),%rax
mulss  (%rax),%xmm0
movss  %xmm0,(%rax)
mov    0x29ff(%rip),%eax
add    $0x1,%eax
mov    %eax,0x29f6(%rip)
jmp    1625 <slartg+0x4d5>
jmp    16d7 <slartg+0x587>
movss  0x29f0(%rip),%xmm0
movss  %xmm0,-0x28(%rbp)
movss  0x29e7(%rip),%xmm0
movss  %xmm0,-0x2c(%rbp)
movss  -0x28(%rbp),%xmm0
movss  -0x28(%rbp),%xmm2
movss  -0x2c(%rbp),%xmm1
mulss  -0x2c(%rbp),%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
call   1070 <sqrt@plt>
mov    -0x20(%rbp),%rax
movss  %xmm0,(%rax)
movss  0x29ad(%rip),%xmm0
mov    -0x20(%rbp),%rax
divss  (%rax),%xmm0
mov    -0x10(%rbp),%rax
movss  %xmm0,(%rax)
movss  0x2999(%rip),%xmm0
mov    -0x20(%rbp),%rax
divss  (%rax),%xmm0
mov    -0x18(%rbp),%rax
movss  %xmm0,(%rax)
jmp    16dc <slartg+0x58c>
movss  -0x4(%rbp),%xmm0
call   1030 <fabs@plt>
movss  %xmm0,-0x40(%rbp)
movss  -0x8(%rbp),%xmm0
call   1030 <fabs@plt>
movaps %xmm0,%xmm1
movss  -0x40(%rbp),%xmm0
ucomiss %xmm1,%xmm0
jbe    17a3 <slartg+0x653>
mov    -0x10(%rbp),%rax
xorps  %xmm0,%xmm0
ucomiss (%rax),%xmm0
jbe    17a3 <slartg+0x653>
mov    -0x10(%rbp),%rax
movss  (%rax),%xmm0
cvtss2sd %xmm0,%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
cvtsd2ss %xmm0,%xmm0
mov    -0x10(%rbp),%rax
movss  %xmm0,(%rax)
mov    -0x18(%rbp),%rax
movss  (%rax),%xmm0
cvtss2sd %xmm0,%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
cvtsd2ss %xmm0,%xmm0
mov    -0x18(%rbp),%rax
movss  %xmm0,(%rax)
mov    -0x20(%rbp),%rax
movss  (%rax),%xmm0
cvtss2sd %xmm0,%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
cvtsd2ss %xmm0,%xmm0
mov    -0x20(%rbp),%rax
movss  %xmm0,(%rax)
jmp    17a8 <slartg+0x658>
jmp    17ad <slartg+0x65d>
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<slartg>:
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x28,%rsp
mov    %rdx,%r12
mov    %rsi,%r14
mov    %rdi,%r15
movaps %xmm0,%xmm7
cmpb   $0x0,0x2ee6(%rip)
jne    121f <slartg+0xdf>
movb   $0x1,0x2ed9(%rip)
lea    0xebe(%rip),%rdi
movaps %xmm7,0x10(%rsp)
movaps %xmm1,(%rsp)
call   1030 <slamch@plt>
movss  %xmm0,0x2ed4(%rip)
lea    0xea3(%rip),%rdi
call   1030 <slamch@plt>
movss  %xmm0,0x2ec4(%rip)
lea    0xe91(%rip),%rbx
mov    %rbx,%rdi
call   1030 <slamch@plt>
movss  %xmm0,0x24(%rsp)
movss  0x2ea3(%rip),%xmm0
divss  0x2e9f(%rip),%xmm0
call   1040 <log@plt>
movss  %xmm0,0x20(%rsp)
mov    %rbx,%rdi
call   1030 <slamch@plt>
call   1040 <log@plt>
movss  0x20(%rsp),%xmm1
divss  %xmm0,%xmm1
mulss  0xe15(%rip),%xmm1
cvttss2si %xmm1,%edi
movss  0x24(%rsp),%xmm0
call   1050 <pow@plt>
movaps (%rsp),%xmm1
movaps 0x10(%rsp),%xmm7
movss  %xmm0,0x2e49(%rip)
movss  0xdf1(%rip),%xmm2
divss  %xmm0,%xmm2
movss  %xmm2,0x2e39(%rip)
xorps  %xmm0,%xmm0
ucomiss %xmm0,%xmm1
jne    1239 <slartg+0xf9>
jp     1239 <slartg+0xf9>
movl   $0x3f800000,(%r15)
movl   $0x0,(%r14)
jmp    1251 <slartg+0x111>
ucomiss %xmm0,%xmm7
jne    1263 <slartg+0x123>
jp     1263 <slartg+0x123>
movl   $0x0,(%r15)
movl   $0x3f800000,(%r14)
movaps %xmm1,%xmm7
movss  %xmm7,(%r12)
add    $0x28,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret
movss  %xmm7,0x2de1(%rip)
movss  %xmm1,0x2ddd(%rip)
movaps 0xd96(%rip),%xmm0
movaps %xmm7,%xmm8
andps  %xmm0,%xmm8
movaps %xmm1,%xmm6
andps  %xmm0,%xmm6
movaps %xmm8,%xmm3
maxss  %xmm6,%xmm3
movss  0x2dc0(%rip),%xmm5
ucomiss %xmm5,%xmm3
movss  0x2db1(%rip),%xmm2
jae    12ce <slartg+0x18e>
ucomiss %xmm3,%xmm2
jae    1326 <slartg+0x1e6>
mulss  %xmm1,%xmm1
mulss  %xmm7,%xmm7
addss  %xmm1,%xmm7
xorps  %xmm0,%xmm0
ucomiss %xmm0,%xmm7
jb     143e <slartg+0x2fe>
xorps  %xmm0,%xmm0
sqrtss %xmm7,%xmm0
jmp    145a <slartg+0x31a>
xor    %eax,%eax
add    $0x1,%eax
mulss  %xmm2,%xmm7
mulss  %xmm2,%xmm1
movaps %xmm7,%xmm3
andps  %xmm0,%xmm3
movaps %xmm1,%xmm4
andps  %xmm0,%xmm4
maxss  %xmm4,%xmm3
ucomiss %xmm5,%xmm3
jae    12d0 <slartg+0x190>
mov    %eax,0x2d52(%rip)
movss  %xmm7,0x2d4e(%rip)
movss  %xmm1,0x2d4a(%rip)
mulss  %xmm1,%xmm1
mulss  %xmm7,%xmm7
addss  %xmm1,%xmm7
xorps  %xmm0,%xmm0
ucomiss %xmm0,%xmm7
jb     138a <slartg+0x24a>
xorps  %xmm0,%xmm0
sqrtss %xmm7,%xmm0
jmp    13a6 <slartg+0x266>
xor    %eax,%eax
nopl   0x0(%rax,%rax,1)
add    $0x1,%eax
mulss  %xmm5,%xmm7
mulss  %xmm5,%xmm1
movaps %xmm7,%xmm3
andps  %xmm0,%xmm3
movaps %xmm1,%xmm4
andps  %xmm0,%xmm4
maxss  %xmm4,%xmm3
ucomiss %xmm3,%xmm2
jae    1330 <slartg+0x1f0>
mov    %eax,0x2cf2(%rip)
movss  %xmm7,0x2cee(%rip)
movss  %xmm1,0x2cea(%rip)
mulss  %xmm1,%xmm1
mulss  %xmm7,%xmm7
addss  %xmm1,%xmm7
xorps  %xmm0,%xmm0
ucomiss %xmm0,%xmm7
jb     1489 <slartg+0x349>
xorps  %xmm0,%xmm0
sqrtss %xmm7,%xmm0
jmp    14a5 <slartg+0x365>
movaps %xmm7,%xmm0
movaps %xmm8,0x10(%rsp)
movaps %xmm6,(%rsp)
call   1060 <sqrt@plt>
movaps (%rsp),%xmm6
movaps 0x10(%rsp),%xmm8
movss  %xmm0,(%r12)
movss  0x2c98(%rip),%xmm1
divss  %xmm0,%xmm1
movss  %xmm1,(%r15)
movss  0x2c8b(%rip),%xmm0
divss  (%r12),%xmm0
movss  %xmm0,(%r14)
mov    0x2c72(%rip),%ecx
test   %ecx,%ecx
jle    153f <slartg+0x3ff>
movss  0x2c72(%rip),%xmm1
movss  (%r12),%xmm0
lea    -0x1(%rcx),%edx
mov    %ecx,%eax
and    $0x7,%eax
cmp    $0x7,%edx
jb     1425 <slartg+0x2e5>
and    $0xfffffff8,%ecx
nopl   0x0(%rax)
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
add    $0xfffffff8,%ecx
jne    1400 <slartg+0x2c0>
test   %eax,%eax
je     1539 <slartg+0x3f9>
nopl   (%rax)
mulss  %xmm1,%xmm0
add    $0xffffffff,%eax
jne    1430 <slartg+0x2f0>
jmp    1539 <slartg+0x3f9>
movaps %xmm7,%xmm0
movaps %xmm8,0x10(%rsp)
movaps %xmm6,(%rsp)
call   1060 <sqrt@plt>
movaps (%rsp),%xmm6
movaps 0x10(%rsp),%xmm8
movss  %xmm0,(%r12)
movss  0x2be4(%rip),%xmm1
divss  %xmm0,%xmm1
movss  %xmm1,(%r15)
movss  0x2bd7(%rip),%xmm0
divss  (%r12),%xmm0
movss  %xmm0,(%r14)
jmp    153f <slartg+0x3ff>
movaps %xmm7,%xmm0
movaps %xmm8,0x10(%rsp)
movaps %xmm6,(%rsp)
call   1060 <sqrt@plt>
movaps (%rsp),%xmm6
movaps 0x10(%rsp),%xmm8
movss  %xmm0,(%r12)
movss  0x2b99(%rip),%xmm1
divss  %xmm0,%xmm1
movss  %xmm1,(%r15)
movss  0x2b8c(%rip),%xmm0
divss  (%r12),%xmm0
movss  %xmm0,(%r14)
mov    0x2b73(%rip),%ecx
test   %ecx,%ecx
jle    153f <slartg+0x3ff>
movss  0x2b73(%rip),%xmm1
movss  (%r12),%xmm0
lea    -0x1(%rcx),%edx
mov    %ecx,%eax
and    $0x7,%eax
cmp    $0x7,%edx
jb     1525 <slartg+0x3e5>
and    $0xfffffff8,%ecx
nopw   0x0(%rax,%rax,1)
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
mulss  %xmm1,%xmm0
add    $0xfffffff8,%ecx
jne    1500 <slartg+0x3c0>
test   %eax,%eax
je     1539 <slartg+0x3f9>
nopl   0x0(%rax)
mulss  %xmm1,%xmm0
add    $0xffffffff,%eax
jne    1530 <slartg+0x3f0>
movss  %xmm0,(%r12)
ucomiss %xmm6,%xmm8
jbe    1257 <slartg+0x117>
movss  (%r15),%xmm0
xorps  %xmm1,%xmm1
ucomiss %xmm0,%xmm1
jbe    1257 <slartg+0x117>
movaps 0xabf(%rip),%xmm1
xorps  %xmm1,%xmm0
movss  %xmm0,(%r15)
movss  (%r14),%xmm0
xorps  %xmm1,%xmm0
movss  %xmm0,(%r14)
movss  (%r12),%xmm7
xorps  %xmm1,%xmm7
jmp    1251 <slartg+0x111>

LLVM IR (-O0):
@slartg.first = internal global i32 1
@slartg.i = internal global i32 0
@slartg.scale = internal global float 0.000000e+00
@slartg.count = internal global i32 0
@slartg.f1 = internal global float 0.000000e+00
@slartg.g1 = internal global float 0.000000e+00
@slartg.safmn2 = internal global float 0.000000e+00
@slartg.safmx2 = internal global float 0.000000e+00
@slartg.safmin = internal global float 0.000000e+00
@slartg.eps = internal global float 0.000000e+00
@.str = [2 x i8] c"S\00"
@.str.1 = [2 x i8] c"E\00"
@.str.2 = [2 x i8] c"B\00"
define void @slartg(float %0, float %1, float* %2, float* %3, float* %4) {
%6 = alloca float
%7 = alloca float
%8 = alloca float*
%9 = alloca float*
%10 = alloca float*
%11 = alloca i32
%12 = alloca float
%13 = alloca float
store float %0, float* %6
store float %1, float* %7
store float* %2, float** %8
store float* %3, float** %9
store float* %4, float** %10
%14 = load i32, i32* @slartg.first
%15 = icmp ne i32 %14, 0
br i1 %15, label %16, label %34
16: ; preds = %5
store i32 0, i32* @slartg.first
%17 = call float @slamch(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
store float %17, float* @slartg.safmin
%18 = call float @slamch(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store float %18, float* @slartg.eps
%19 = call float @slamch(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
store float %19, float* %12
%20 = load float, float* @slartg.safmin
%21 = load float, float* @slartg.eps
%22 = fdiv float %20, %21
%23 = call float @log(float %22)
%24 = call float @slamch(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%25 = call float @log(float %24)
%26 = fdiv float %23, %25
%27 = fdiv float %26, 2.000000e+00
%28 = fptosi float %27 to i32
store i32 %28, i32* %11
%29 = load float, float* %12
%30 = load i32, i32* %11
%31 = call float @pow(float %29, i32 %30)
store float %31, float* @slartg.safmn2
%32 = load float, float* @slartg.safmn2
%33 = fdiv float 1.000000e+00, %32
store float %33, float* @slartg.safmx2
br label %34
34: ; preds = %16, %5
%35 = load float, float* %7
%36 = fcmp oeq float %35, 0.000000e+00
br i1 %36, label %37, label %42
37: ; preds = %34
%38 = load float*, float** %8
store float 1.000000e+00, float* %38
%39 = load float*, float** %9
store float 0.000000e+00, float* %39
%40 = load float, float* %6
%41 = load float*, float** %10
store float %40, float* %41
br label %250
42: ; preds = %34
%43 = load float, float* %6
%44 = fcmp oeq float %43, 0.000000e+00
br i1 %44, label %45, label %50
45: ; preds = %42
%46 = load float*, float** %8
store float 0.000000e+00, float* %46
%47 = load float*, float** %9
store float 1.000000e+00, float* %47
%48 = load float, float* %7
%49 = load float*, float** %10
store float %48, float* %49
br label %249
50: ; preds = %42
%51 = load float, float* %6
store float %51, float* @slartg.f1
%52 = load float, float* %7
store float %52, float* @slartg.g1
%53 = load float, float* @slartg.f1
%54 = call float @fabs(float %53)
store float %54, float* %12
%55 = load float, float* @slartg.g1
%56 = call float @fabs(float %55)
store float %56, float* %13
%57 = load float, float* %12
%58 = load float, float* %13
%59 = fcmp ogt float %57, %58
br i1 %59, label %60, label %62
60: ; preds = %50
%61 = load float, float* %12
br label %64
62: ; preds = %50
%63 = load float, float* %13
br label %64
64: ; preds = %62, %60
%65 = phi float [ %61, %60 ], [ %63, %62 ]
store float %65, float* @slartg.scale
%66 = load float, float* @slartg.scale
%67 = load float, float* @slartg.safmx2
%68 = fcmp oge float %66, %67
br i1 %68, label %69, label %131
69: ; preds = %64
store i32 0, i32* @slartg.count
br label %70
70: ; preds = %95, %69
%71 = load i32, i32* @slartg.count
%72 = add nsw i32 %71, 1
store i32 %72, i32* @slartg.count
%73 = load float, float* @slartg.safmn2
%74 = load float, float* @slartg.f1
%75 = fmul float %74, %73
store float %75, float* @slartg.f1
%76 = load float, float* @slartg.safmn2
%77 = load float, float* @slartg.g1
%78 = fmul float %77, %76
store float %78, float* @slartg.g1
%79 = load float, float* @slartg.f1
%80 = call float @fabs(float %79)
store float %80, float* %12
%81 = load float, float* @slartg.g1
%82 = call float @fabs(float %81)
store float %82, float* %13
%83 = load float, float* %12
%84 = load float, float* %13
%85 = fcmp ogt float %83, %84
br i1 %85, label %86, label %88
86: ; preds = %70
%87 = load float, float* %12
br label %90
88: ; preds = %70
%89 = load float, float* %13
br label %90
90: ; preds = %88, %86
%91 = phi float [ %87, %86 ], [ %89, %88 ]
store float %91, float* @slartg.scale
%92 = load float, float* @slartg.scale
%93 = load float, float* @slartg.safmx2
%94 = fcmp oge float %92, %93
br i1 %94, label %95, label %96
95: ; preds = %90
br label %70
96: ; preds = %90
%97 = load float, float* @slartg.f1
store float %97, float* %12
%98 = load float, float* @slartg.g1
store float %98, float* %13
%99 = load float, float* %12
%100 = load float, float* %12
%101 = load float, float* %13
%102 = load float, float* %13
%103 = fmul float %101, %102
%104 = call float @llvm.fmuladd.f32(float %99, float %100, float %103)
%105 = call float @sqrt(float %104)
%106 = load float*, float** %10
store float %105, float* %106
%107 = load float, float* @slartg.f1
%108 = load float*, float** %10
%109 = load float, float* %108
%110 = fdiv float %107, %109
%111 = load float*, float** %8
store float %110, float* %111
%112 = load float, float* @slartg.g1
%113 = load float*, float** %10
%114 = load float, float* %113
%115 = fdiv float %112, %114
%116 = load float*, float** %9
store float %115, float* %116
%117 = load i32, i32* @slartg.count
store i32 %117, i32* %11
store i32 1, i32* @slartg.i
br label %118
118: ; preds = %127, %96
%119 = load i32, i32* @slartg.i
%120 = load i32, i32* @slartg.count
%121 = icmp sle i32 %119, %120
br i1 %121, label %122, label %130
122: ; preds = %118
%123 = load float, float* @slartg.safmx2
%124 = load float*, float** %10
%125 = load float, float* %124
%126 = fmul float %125, %123
store float %126, float* %124
br label %127
127: ; preds = %122
%128 = load i32, i32* @slartg.i
%129 = add nsw i32 %128, 1
store i32 %129, i32* @slartg.i
br label %118
130: ; preds = %118
br label %219
131: ; preds = %64
%132 = load float, float* @slartg.scale
%133 = load float, float* @slartg.safmn2
%134 = fcmp ole float %132, %133
br i1 %134, label %135, label %197
135: ; preds = %131
store i32 0, i32* @slartg.count
br label %136
136: ; preds = %161, %135
%137 = load i32, i32* @slartg.count
%138 = add nsw i32 %137, 1
store i32 %138, i32* @slartg.count
%139 = load float, float* @slartg.safmx2
%140 = load float, float* @slartg.f1
%141 = fmul float %140, %139
store float %141, float* @slartg.f1
%142 = load float, float* @slartg.safmx2
%143 = load float, float* @slartg.g1
%144 = fmul float %143, %142
store float %144, float* @slartg.g1
%145 = load float, float* @slartg.f1
%146 = call float @fabs(float %145)
store float %146, float* %12
%147 = load float, float* @slartg.g1
%148 = call float @fabs(float %147)
store float %148, float* %13
%149 = load float, float* %12
%150 = load float, float* %13
%151 = fcmp ogt float %149, %150
br i1 %151, label %152, label %154
152: ; preds = %136
%153 = load float, float* %12
br label %156
154: ; preds = %136
%155 = load float, float* %13
br label %156
156: ; preds = %154, %152
%157 = phi float [ %153, %152 ], [ %155, %154 ]
store float %157, float* @slartg.scale
%158 = load float, float* @slartg.scale
%159 = load float, float* @slartg.safmn2
%160 = fcmp ole float %158, %159
br i1 %160, label %161, label %162
161: ; preds = %156
br label %136
162: ; preds = %156
%163 = load float, float* @slartg.f1
store float %163, float* %12
%164 = load float, float* @slartg.g1
store float %164, float* %13
%165 = load float, float* %12
%166 = load float, float* %12
%167 = load float, float* %13
%168 = load float, float* %13
%169 = fmul float %167, %168
%170 = call float @llvm.fmuladd.f32(float %165, float %166, float %169)
%171 = call float @sqrt(float %170)
%172 = load float*, float** %10
store float %171, float* %172
%173 = load float, float* @slartg.f1
%174 = load float*, float** %10
%175 = load float, float* %174
%176 = fdiv float %173, %175
%177 = load float*, float** %8
store float %176, float* %177
%178 = load float, float* @slartg.g1
%179 = load float*, float** %10
%180 = load float, float* %179
%181 = fdiv float %178, %180
%182 = load float*, float** %9
store float %181, float* %182
%183 = load i32, i32* @slartg.count
store i32 %183, i32* %11
store i32 1, i32* @slartg.i
br label %184
184: ; preds = %193, %162
%185 = load i32, i32* @slartg.i
%186 = load i32, i32* @slartg.count
%187 = icmp sle i32 %185, %186
br i1 %187, label %188, label %196
188: ; preds = %184
%189 = load float, float* @slartg.safmn2
%190 = load float*, float** %10
%191 = load float, float* %190
%192 = fmul float %191, %189
store float %192, float* %190
br label %193
193: ; preds = %188
%194 = load i32, i32* @slartg.i
%195 = add nsw i32 %194, 1
store i32 %195, i32* @slartg.i
br label %184
196: ; preds = %184
br label %218
197: ; preds = %131
%198 = load float, float* @slartg.f1
store float %198, float* %12
%199 = load float, float* @slartg.g1
store float %199, float* %13
%200 = load float, float* %12
%201 = load float, float* %12
%202 = load float, float* %13
%203 = load float, float* %13
%204 = fmul float %202, %203
%205 = call float @llvm.fmuladd.f32(float %200, float %201, float %204)
%206 = call float @sqrt(float %205)
%207 = load float*, float** %10
store float %206, float* %207
%208 = load float, float* @slartg.f1
%209 = load float*, float** %10
%210 = load float, float* %209
%211 = fdiv float %208, %210
%212 = load float*, float** %8
store float %211, float* %212
%213 = load float, float* @slartg.g1
%214 = load float*, float** %10
%215 = load float, float* %214
%216 = fdiv float %213, %215
%217 = load float*, float** %9
store float %216, float* %217
br label %218
218: ; preds = %197, %196
br label %219
219: ; preds = %218, %130
%220 = load float, float* %6
%221 = call float @fabs(float %220)
%222 = load float, float* %7
%223 = call float @fabs(float %222)
%224 = fcmp ogt float %221, %223
br i1 %224, label %225, label %248
225: ; preds = %219
%226 = load float*, float** %8
%227 = load float, float* %226
%228 = fcmp olt float %227, 0.000000e+00
br i1 %228, label %229, label %248
229: ; preds = %225
%230 = load float*, float** %8
%231 = load float, float* %230
%232 = fpext float %231 to double
%233 = fneg double %232
%234 = fptrunc double %233 to float
%235 = load float*, float** %8
store float %234, float* %235
%236 = load float*, float** %9
%237 = load float, float* %236
%238 = fpext float %237 to double
%239 = fneg double %238
%240 = fptrunc double %239 to float
%241 = load float*, float** %9
store float %240, float* %241
%242 = load float*, float** %10
%243 = load float, float* %242
%244 = fpext float %243 to double
%245 = fneg double %244
%246 = fptrunc double %245 to float
%247 = load float*, float** %10
store float %246, float* %247
br label %248
248: ; preds = %229, %225, %219
br label %249
249: ; preds = %248, %45
br label %250
250: ; preds = %249, %37
ret void
}

LLVM IR (-O2):
@slartg.first = internal unnamed_addr global i1 false
@slartg.count = internal unnamed_addr global i32 0
@slartg.f1 = internal unnamed_addr global float 0.000000e+00
@slartg.g1 = internal unnamed_addr global float 0.000000e+00
@slartg.safmn2 = internal unnamed_addr global float 0.000000e+00
@slartg.safmx2 = internal unnamed_addr global float 0.000000e+00
@slartg.safmin = internal unnamed_addr global float 0.000000e+00
@slartg.eps = internal unnamed_addr global float 0.000000e+00
@.str = [2 x i8] c"S\00"
@.str.1 = [2 x i8] c"E\00"
@.str.2 = [2 x i8] c"B\00"
define void @slartg(float %0, float %1, float* nocapture %2, float* nocapture %3, float* nocapture %4) {
%6 = load i1, i1* @slartg.first
br i1 %6, label %22, label %7
7: ; preds = %5
store i1 true, i1* @slartg.first
%8 = tail call float @slamch(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
store float %8, float* @slartg.safmin
%9 = tail call float @slamch(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store float %9, float* @slartg.eps
%10 = tail call float @slamch(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%11 = load float, float* @slartg.safmin
%12 = load float, float* @slartg.eps
%13 = fdiv float %11, %12
%14 = tail call float @log(float %13)
%15 = tail call float @slamch(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%16 = tail call float @log(float %15)
%17 = fdiv float %14, %16
%18 = fmul float %17, 5.000000e-01
%19 = fptosi float %18 to i32
%20 = tail call float @pow(float %10, i32 %19)
store float %20, float* @slartg.safmn2
%21 = fdiv float 1.000000e+00, %20
store float %21, float* @slartg.safmx2
br label %22
22: ; preds = %7, %5
%23 = fcmp oeq float %1, 0.000000e+00
br i1 %23, label %24, label %25
24: ; preds = %22
store float 1.000000e+00, float* %2
store float 0.000000e+00, float* %3
br label %169
25: ; preds = %22
%26 = fcmp oeq float %0, 0.000000e+00
br i1 %26, label %27, label %28
27: ; preds = %25
store float 0.000000e+00, float* %2
store float 1.000000e+00, float* %3
br label %169
28: ; preds = %25
store float %0, float* @slartg.f1
store float %1, float* @slartg.g1
%29 = tail call float @llvm.fabs.f32(float %0)
%30 = tail call float @llvm.fabs.f32(float %1)
%31 = fcmp ogt float %29, %30
%32 = select i1 %31, float %29, float %30
%33 = load float, float* @slartg.safmx2
%34 = fcmp ult float %32, %33
%35 = load float, float* @slartg.safmn2
br i1 %34, label %80, label %36
36: ; preds = %28, %36
%37 = phi float [ %42, %36 ], [ %1, %28 ]
%38 = phi float [ %41, %36 ], [ %0, %28 ]
%39 = phi i32 [ %40, %36 ], [ 0, %28 ]
%40 = add nuw nsw i32 %39, 1
%41 = fmul float %35, %38
%42 = fmul float %35, %37
%43 = tail call float @llvm.fabs.f32(float %41)
%44 = tail call float @llvm.fabs.f32(float %42)
%45 = fcmp ogt float %43, %44
%46 = select i1 %45, float %43, float %44
%47 = fcmp ult float %46, %33
br i1 %47, label %48, label %36
48: ; preds = %36
store i32 %40, i32* @slartg.count
store float %41, float* @slartg.f1
store float %42, float* @slartg.g1
%49 = fmul float %42, %42
%50 = tail call float @llvm.fmuladd.f32(float %41, float %41, float %49)
%51 = tail call float @sqrt(float %50)
store float %51, float* %4
%52 = load float, float* @slartg.f1
%53 = fdiv float %52, %51
store float %53, float* %2
%54 = load float, float* @slartg.g1
%55 = load float, float* %4
%56 = fdiv float %54, %55
store float %56, float* %3
%57 = load i32, i32* @slartg.count
%58 = icmp slt i32 %57, 1
br i1 %58, label %159, label %59
59: ; preds = %48
%60 = load float, float* @slartg.safmx2
%61 = load float, float* %4
%62 = add i32 %57, -1
%63 = and i32 %57, 7
%64 = icmp ult i32 %62, 7
br i1 %64, label %147, label %65
65: ; preds = %59
%66 = and i32 %57, -8
br label %67
67: ; preds = %67, %65
%68 = phi float [ %61, %65 ], [ %77, %67 ]
%69 = phi i32 [ 0, %65 ], [ %78, %67 ]
%70 = fmul float %60, %68
%71 = fmul float %60, %70
%72 = fmul float %60, %71
%73 = fmul float %60, %72
%74 = fmul float %60, %73
%75 = fmul float %60, %74
%76 = fmul float %60, %75
%77 = fmul float %60, %76
%78 = add i32 %69, 8
%79 = icmp eq i32 %78, %66
br i1 %79, label %147, label %67
80: ; preds = %28
%81 = fcmp ugt float %32, %35
br i1 %81, label %126, label %82
82: ; preds = %80, %82
%83 = phi float [ %88, %82 ], [ %1, %80 ]
%84 = phi float [ %87, %82 ], [ %0, %80 ]
%85 = phi i32 [ %86, %82 ], [ 0, %80 ]
%86 = add nuw nsw i32 %85, 1
%87 = fmul float %33, %84
%88 = fmul float %33, %83
%89 = tail call float @llvm.fabs.f32(float %87)
%90 = tail call float @llvm.fabs.f32(float %88)
%91 = fcmp ogt float %89, %90
%92 = select i1 %91, float %89, float %90
%93 = fcmp ugt float %92, %35
br i1 %93, label %94, label %82
94: ; preds = %82
store i32 %86, i32* @slartg.count
store float %87, float* @slartg.f1
store float %88, float* @slartg.g1
%95 = fmul float %88, %88
%96 = tail call float @llvm.fmuladd.f32(float %87, float %87, float %95)
%97 = tail call float @sqrt(float %96)
store float %97, float* %4
%98 = load float, float* @slartg.f1
%99 = fdiv float %98, %97
store float %99, float* %2
%100 = load float, float* @slartg.g1
%101 = load float, float* %4
%102 = fdiv float %100, %101
store float %102, float* %3
%103 = load i32, i32* @slartg.count
%104 = icmp slt i32 %103, 1
br i1 %104, label %159, label %105
105: ; preds = %94
%106 = load float, float* @slartg.safmn2
%107 = load float, float* %4
%108 = add i32 %103, -1
%109 = and i32 %103, 7
%110 = icmp ult i32 %108, 7
br i1 %110, label %135, label %111
111: ; preds = %105
%112 = and i32 %103, -8
br label %113
113: ; preds = %113, %111
%114 = phi float [ %107, %111 ], [ %123, %113 ]
%115 = phi i32 [ 0, %111 ], [ %124, %113 ]
%116 = fmul float %106, %114
%117 = fmul float %106, %116
%118 = fmul float %106, %117
%119 = fmul float %106, %118
%120 = fmul float %106, %119
%121 = fmul float %106, %120
%122 = fmul float %106, %121
%123 = fmul float %106, %122
%124 = add i32 %115, 8
%125 = icmp eq i32 %124, %112
br i1 %125, label %135, label %113
126: ; preds = %80
%127 = fmul float %1, %1
%128 = tail call float @llvm.fmuladd.f32(float %0, float %0, float %127)
%129 = tail call float @sqrt(float %128)
store float %129, float* %4
%130 = load float, float* @slartg.f1
%131 = fdiv float %130, %129
store float %131, float* %2
%132 = load float, float* @slartg.g1
%133 = load float, float* %4
%134 = fdiv float %132, %133
store float %134, float* %3
br label %159
135: ; preds = %113, %105
%136 = phi float [ undef, %105 ], [ %123, %113 ]
%137 = phi float [ %107, %105 ], [ %123, %113 ]
%138 = icmp eq i32 %109, 0
br i1 %138, label %145, label %139
139: ; preds = %135, %139
%140 = phi float [ %142, %139 ], [ %137, %135 ]
%141 = phi i32 [ %143, %139 ], [ 0, %135 ]
%142 = fmul float %106, %140
%143 = add i32 %141, 1
%144 = icmp eq i32 %143, %109
br i1 %144, label %145, label %139
145: ; preds = %139, %135
%146 = phi float [ %136, %135 ], [ %142, %139 ]
store float %146, float* %4
br label %159
147: ; preds = %67, %59
%148 = phi float [ undef, %59 ], [ %77, %67 ]
%149 = phi float [ %61, %59 ], [ %77, %67 ]
%150 = icmp eq i32 %63, 0
br i1 %150, label %157, label %151
151: ; preds = %147, %151
%152 = phi float [ %154, %151 ], [ %149, %147 ]
%153 = phi i32 [ %155, %151 ], [ 0, %147 ]
%154 = fmul float %60, %152
%155 = add i32 %153, 1
%156 = icmp eq i32 %155, %63
br i1 %156, label %157, label %151
157: ; preds = %151, %147
%158 = phi float [ %148, %147 ], [ %154, %151 ]
store float %158, float* %4
br label %159
159: ; preds = %48, %157, %94, %145, %126
br i1 %31, label %160, label %171
160: ; preds = %159
%161 = load float, float* %2
%162 = fcmp olt float %161, 0.000000e+00
br i1 %162, label %163, label %171
163: ; preds = %160
%164 = fneg float %161
store float %164, float* %2
%165 = load float, float* %3
%166 = fneg float %165
store float %166, float* %3
%167 = load float, float* %4
%168 = fneg float %167
br label %169
169: ; preds = %24, %163, %27
%170 = phi float [ %1, %27 ], [ %168, %163 ], [ %0, %24 ]
store float %170, float* %4
br label %171
171: ; preds = %169, %160, %159
ret void
}