#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 */
int atoi(char *);
int floor(double);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *);
int pow(float, int);
int /*<<< orphan*/ printf(char *, ...);
int sqrt(float);
int /*<<< orphan*/ stderr;
int main(int argc, char **argv) {
  int i;
  int N;
  int shift;
  int j;
  float p[16];
  int pi[16];
  int sum;
  int aN[32768];
  if (argc != 3) {
    fprintf(stderr, "usage: gen_laplace_tables <nb entries> <shift>\n");
    return 1;
  }
  N = atoi(argv[1]);
  shift = atoi(argv[2]);
  printf("/* This file is auto-generated using \"gen_laplace_tables %d %d\" "
         "*/\n\n",
         N, shift);
  printf("#ifdef HAVE_CONFIG_H\n");
  printf("#include \"config.h\"\n");
  printf("#endif\n\n");
  printf("#include \"laplace_code.h\"\n\n");
  printf("const ogg_uint16_t EXP_CDF_TABLE[%d][16] = {\n", N);
  printf("  {");
  for (j = 0; j < 16; j++) {
    printf("%5d%s", 32768U - 15 + j, j + 1 < 16 ? "," : "");
  }
  printf("},\n");
  aN[0] = 1;
  aN[0] = 0;
  for (i = 1; i < N; i++) {
    float r;
    int cdf;
    float maxp;
    int maxj;
    r = i / (float)(1 << shift);
    p[0] = 1 - r;
    for (j = 1; j < 15; j++)
      p[j] = (1 - r) * pow(r, j);
    p[15] = pow(r, 15);
    aN[i] = 32768 * (p[0] - p[0] * sqrt(r) / (1 + sqrt(r)));
    sum = 0;
    maxp = 0;
    maxj = 0;
    for (j = 0; j < 16; j++) {
      if (p[j] > maxp) {
        maxp = p[j];
        maxj = j;
      }
      pi[j] = floor(.5 + 32768 * p[j]);
      if (pi[j] == 0)
        pi[j] = 1;
      sum += pi[j];
    }
    pi[maxj] += 32768 - sum;
    cdf = 0;
    printf("  {");
    for (j = 0; j < 16; j++) {
      cdf += pi[j];
      printf("%5d%s", cdf, j + 1 < 16 ? "," : "");
    }
    printf("}%s\n", i + 1 <= N ? "," : "");
  }
  printf("};\n");
  printf("\n\n");
  printf("const ogg_uint16_t LAPLACE_OFFSET[%d] = {\n", N);
  for (i = 0; i < N; i++)
    printf("  %d%s\n", aN[i], i + 1 <= N ? "," : "");
  printf("};\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x200d0,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x3,-0x8(%rbp)
je     11a4 <main+0x44>
mov    0x2e56(%rip),%rax
mov    (%rax),%edi
lea    0xe7d(%rip),%rsi
call   1040 <fprintf@plt>
movl   $0x1,-0x4(%rbp)
jmp    1636 <main+0x4d6>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1060 <atoi@plt>
mov    %eax,-0x18(%rbp)
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1060 <atoi@plt>
mov    %eax,-0x1c(%rbp)
mov    -0x18(%rbp),%esi
mov    -0x1c(%rbp),%edx
lea    0xe6f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xea6(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeae(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeb5(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeb0(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x18(%rbp),%esi
lea    0xebb(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xedb(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x20(%rbp)
cmpl   $0x10,-0x20(%rbp)
jge    1280 <main+0x120>
mov    -0x20(%rbp),%esi
add    $0x7ff1,%esi
mov    -0x20(%rbp),%ecx
add    $0x1,%ecx
lea    0xe7e(%rip),%rdx
lea    0xeb0(%rip),%rax
cmp    $0x10,%ecx
cmovl  %rax,%rdx
lea    0xe9c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x20(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x20(%rbp)
jmp    1236 <main+0xd6>
lea    0xe88(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x1,-0x200b0(%rbp)
movl   $0x0,-0x200b0(%rbp)
movl   $0x1,-0x14(%rbp)
mov    -0x14(%rbp),%eax
cmp    -0x18(%rbp),%eax
jge    159d <main+0x43d>
cvtsi2ssl -0x14(%rbp),%xmm0
mov    -0x1c(%rbp),%ecx
mov    $0x1,%eax
shl    %cl,%eax
cvtsi2ss %eax,%xmm1
divss  %xmm1,%xmm0
movss  %xmm0,-0x200b4(%rbp)
ff
movss  0xd24(%rip),%xmm0
subss  -0x200b4(%rbp),%xmm0
ff
movss  %xmm0,-0x60(%rbp)
movl   $0x1,-0x20(%rbp)
cmpl   $0xf,-0x20(%rbp)
jge    134a <main+0x1ea>
movss  0xcfe(%rip),%xmm0
subss  -0x200b4(%rbp),%xmm0
ff
movss  %xmm0,-0x200c4(%rbp)
ff
movss  -0x200b4(%rbp),%xmm0
ff
mov    -0x20(%rbp),%edi
call   1050 <pow@plt>
movss  -0x200c4(%rbp),%xmm0
ff
cvtsi2ss %eax,%xmm1
mulss  %xmm1,%xmm0
movslq -0x20(%rbp),%rax
movss  %xmm0,-0x60(%rbp,%rax,4)
mov    -0x20(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x20(%rbp)
jmp    12f0 <main+0x190>
movss  -0x200b4(%rbp),%xmm0
ff
mov    $0xf,%edi
call   1050 <pow@plt>
cvtsi2ss %eax,%xmm0
movss  %xmm0,-0x24(%rbp)
movss  -0x60(%rbp),%xmm0
movss  %xmm0,-0x200c8(%rbp)
ff
movss  -0x60(%rbp),%xmm0
movss  %xmm0,-0x200d0(%rbp)
ff
movss  -0x200b4(%rbp),%xmm0
ff
call   1070 <sqrt@plt>
movss  -0x200d0(%rbp),%xmm0
ff
cvtsi2ss %eax,%xmm1
mulss  %xmm1,%xmm0
movss  %xmm0,-0x200cc(%rbp)
ff
movss  -0x200b4(%rbp),%xmm0
ff
call   1070 <sqrt@plt>
movss  -0x200cc(%rbp),%xmm0
ff
movss  -0x200c8(%rbp),%xmm1
ff
add    $0x1,%eax
cvtsi2ss %eax,%xmm2
divss  %xmm2,%xmm0
subss  %xmm0,%xmm1
movss  0xc2c(%rip),%xmm0
mulss  %xmm1,%xmm0
cvttss2si %xmm0,%ecx
movslq -0x14(%rbp),%rax
mov    %ecx,-0x200b0(%rbp,%rax,4)
movl   $0x0,-0xa4(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x200bc(%rbp)
ff
movl   $0x0,-0x200c0(%rbp)
movl   $0x0,-0x20(%rbp)
cmpl   $0x10,-0x20(%rbp)
jge    14c7 <main+0x367>
movslq -0x20(%rbp),%rax
movss  -0x60(%rbp,%rax,4),%xmm0
ucomiss -0x200bc(%rbp),%xmm0
jbe    144d <main+0x2ed>
movslq -0x20(%rbp),%rax
movss  -0x60(%rbp,%rax,4),%xmm0
movss  %xmm0,-0x200bc(%rbp)
ff
mov    -0x20(%rbp),%eax
mov    %eax,-0x200c0(%rbp)
movslq -0x20(%rbp),%rax
movss  0xbab(%rip),%xmm0
mulss  -0x60(%rbp,%rax,4),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xb9d(%rip),%xmm0
addsd  %xmm1,%xmm0
call   1080 <floor@plt>
mov    %eax,%ecx
movslq -0x20(%rbp),%rax
mov    %ecx,-0xa0(%rbp,%rax,4)
movslq -0x20(%rbp),%rax
cmpl   $0x0,-0xa0(%rbp,%rax,4)
jne    14a2 <main+0x342>
movslq -0x20(%rbp),%rax
movl   $0x1,-0xa0(%rbp,%rax,4)
movslq -0x20(%rbp),%rax
mov    -0xa0(%rbp,%rax,4),%eax
add    -0xa4(%rbp),%eax
mov    %eax,-0xa4(%rbp)
mov    -0x20(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x20(%rbp)
jmp    1411 <main+0x2b1>
mov    $0x8000,%ecx
sub    -0xa4(%rbp),%ecx
movslq -0x200c0(%rbp),%rax
add    -0xa0(%rbp,%rax,4),%ecx
mov    %ecx,-0xa0(%rbp,%rax,4)
movl   $0x0,-0x200b8(%rbp)
lea    0xc0b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x20(%rbp)
cmpl   $0x10,-0x20(%rbp)
jge    1564 <main+0x404>
movslq -0x20(%rbp),%rax
mov    -0xa0(%rbp,%rax,4),%eax
add    -0x200b8(%rbp),%eax
mov    %eax,-0x200b8(%rbp)
mov    -0x200b8(%rbp),%esi
mov    -0x20(%rbp),%ecx
add    $0x1,%ecx
lea    0xb9a(%rip),%rdx
lea    0xbcc(%rip),%rax
cmp    $0x10,%ecx
cmovl  %rax,%rdx
lea    0xbb8(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x20(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x20(%rbp)
jmp    1506 <main+0x3a6>
mov    -0x14(%rbp),%ecx
add    $0x1,%ecx
mov    -0x18(%rbp),%edx
lea    0xb60(%rip),%rsi
lea    0xb92(%rip),%rax
cmp    %edx,%ecx
cmovle %rax,%rsi
lea    0xb8b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    12a9 <main+0x149>
lea    0xb74(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xb20(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x18(%rbp),%esi
lea    0xb59(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x14(%rbp)
mov    -0x14(%rbp),%eax
cmp    -0x18(%rbp),%eax
jge    1621 <main+0x4c1>
movslq -0x14(%rbp),%rax
mov    -0x200b0(%rbp,%rax,4),%esi
mov    -0x14(%rbp),%ecx
add    $0x1,%ecx
mov    -0x18(%rbp),%edi
lea    0xadc(%rip),%rdx
lea    0xb0e(%rip),%rax
cmp    %edi,%ecx
cmovle %rax,%rdx
lea    0xb3b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    15d1 <main+0x471>
lea    0xaf0(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x200d0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x200d8,%rsp
cmp    $0x3,%edi
jne    183d <main+0x6cd>
mov    %rsi,%rbx
mov    0x8(%rsi),%rdi
call   1070 <atoi@plt>
mov    %eax,%r15d
mov    0x10(%rbx),%rdi
call   1070 <atoi@plt>
mov    %eax,%r14d
lea    0xe94(%rip),%rdi
mov    %r15d,%esi
mov    %eax,%edx
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xf36(%rip),%rdi
call   1030 <puts@plt>
lea    0xf3f(%rip),%rdi
call   1030 <puts@plt>
lea    0xf47(%rip),%rdi
call   1030 <puts@plt>
lea    0xf43(%rip),%rdi
call   1030 <puts@plt>
lea    0xe96(%rip),%rdi
mov    %r15d,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xeb3(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xea9(%rip),%rbp
lea    0xf2d(%rip),%rbx
mov    %rbp,%rdi
mov    $0x7ff1,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ff2,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ff3,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ff4,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ff5,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ff6,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ff7,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ff8,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ff9,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ffa,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ffb,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ffc,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ffd,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7ffe,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbp,%rdi
mov    $0x7fff,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xd5a(%rip),%rdx
mov    %rbp,%rdi
mov    $0x8000,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe01(%rip),%rdi
call   1030 <puts@plt>
movl   $0x0,0xd0(%rsp)
mov    %r15d,%ebx
cmp    $0x2,%r15d
jl     1870 <main+0x700>
mov    %r15d,0x28(%rsp)
mov    $0x1,%r13d
mov    $0x1,%eax
mov    %r14d,%ecx
shl    %cl,%eax
cvtsi2ss %eax,%xmm0
movss  %xmm0,0x2c(%rsp)
mov    $0x1,%r15d
mov    %rbx,0x88(%rsp)
jmp    1539 <main+0x3c9>
nop
movslq %r12d,%rax
mov    0x40(%rsp,%rax,4),%ecx
sub    %ebp,%ecx
add    $0x8000,%ecx
mov    %ecx,0x40(%rsp,%rax,4)
lea    0xd09(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x40(%rsp),%r14d
lea    0xcfa(%rip),%rbx
mov    %rbx,%rdi
mov    %r14d,%esi
lea    0xd78(%rip),%rbp
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x44(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x48(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x4c(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x50(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x54(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x58(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x5c(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x60(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x64(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x68(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x6c(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x70(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x74(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x78(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    0x7c(%rsp),%r14d
mov    %rbx,%rdi
mov    %r14d,%esi
lea    0xb78(%rip),%rdx
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%r15
lea    0xb9f(%rip),%rdi
mov    %rbp,%rsi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x88(%rsp),%rbx
cmp    %rbx,%r15
je     185d <main+0x6ed>
cvtsi2ss %r15d,%xmm1
divss  0x2c(%rsp),%xmm1
movss  %xmm1,0xc(%rsp)
movss  0xaae(%rip),%xmm0
subss  %xmm1,%xmm0
movaps %xmm0,0x10(%rsp)
movaps %xmm1,%xmm0
mov    $0x1,%edi
call   1060 <pow@plt>
mov    %eax,%r14d
movss  0xc(%rsp),%xmm0
mov    $0x2,%edi
call   1060 <pow@plt>
mov    %eax,%ebx
movss  0xc(%rsp),%xmm0
mov    $0x3,%edi
call   1060 <pow@plt>
mov    %eax,%ebp
movss  0xc(%rsp),%xmm0
mov    $0x4,%edi
call   1060 <pow@plt>
movd   %r14d,%xmm0
movd   %ebx,%xmm1
punpckldq %xmm1,%xmm0
movd   %ebp,%xmm1
movd   %eax,%xmm2
punpckldq %xmm2,%xmm1
punpcklqdq %xmm1,%xmm0
cvtdq2ps %xmm0,%xmm0
movaps 0x10(%rsp),%xmm1
shufps $0x0,%xmm1,%xmm1
movaps %xmm1,0x30(%rsp)
mulps  %xmm1,%xmm0
movups %xmm0,0x94(%rsp)
movss  0xc(%rsp),%xmm0
mov    $0x5,%edi
call   1060 <pow@plt>
mov    %eax,%r14d
movss  0xc(%rsp),%xmm0
mov    $0x6,%edi
call   1060 <pow@plt>
mov    %eax,%ebp
movss  0xc(%rsp),%xmm0
mov    $0x7,%edi
call   1060 <pow@plt>
mov    %eax,%ebx
movss  0xc(%rsp),%xmm0
mov    $0x8,%edi
call   1060 <pow@plt>
movd   %r14d,%xmm0
movd   %ebp,%xmm1
punpckldq %xmm1,%xmm0
movd   %ebx,%xmm1
movd   %eax,%xmm2
punpckldq %xmm2,%xmm1
punpcklqdq %xmm1,%xmm0
cvtdq2ps %xmm0,%xmm0
mulps  0x30(%rsp),%xmm0
movups %xmm0,0xa4(%rsp)
movss  0xc(%rsp),%xmm0
mov    $0x9,%edi
call   1060 <pow@plt>
mov    %eax,%r14d
movss  0xc(%rsp),%xmm0
mov    $0xa,%edi
call   1060 <pow@plt>
mov    %eax,%ebp
movss  0xc(%rsp),%xmm0
mov    $0xb,%edi
call   1060 <pow@plt>
mov    %eax,%ebx
movss  0xc(%rsp),%xmm0
mov    $0xc,%edi
call   1060 <pow@plt>
movd   %r14d,%xmm0
movd   %ebp,%xmm1
punpckldq %xmm1,%xmm0
movd   %ebx,%xmm1
movd   %eax,%xmm2
punpckldq %xmm2,%xmm1
punpcklqdq %xmm1,%xmm0
cvtdq2ps %xmm0,%xmm0
mulps  0x30(%rsp),%xmm0
movups %xmm0,0xb4(%rsp)
movss  0xc(%rsp),%xmm0
mov    $0xd,%edi
call   1060 <pow@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
mulss  0x10(%rsp),%xmm0
movss  %xmm0,0xc4(%rsp)
movss  0xc(%rsp),%xmm0
mov    $0xe,%edi
call   1060 <pow@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
mulss  0x10(%rsp),%xmm0
movss  %xmm0,0xc8(%rsp)
movss  0xc(%rsp),%xmm0
mov    $0xf,%edi
call   1060 <pow@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
movss  %xmm0,0xcc(%rsp)
movss  0xc(%rsp),%xmm0
call   1080 <sqrt@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
mulss  0x10(%rsp),%xmm0
movss  %xmm0,0x30(%rsp)
movss  0xc(%rsp),%xmm0
call   1080 <sqrt@plt>
add    $0x1,%eax
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
movss  0x30(%rsp),%xmm1
divss  %xmm0,%xmm1
movaps 0x10(%rsp),%xmm2
movaps %xmm2,%xmm0
subss  %xmm1,%xmm0
movss  0x887(%rip),%xmm1
mulss  %xmm1,%xmm0
cvttss2si %xmm0,%eax
xorps  %xmm0,%xmm0
ucomiss %xmm0,%xmm2
seta   %r14b
mov    %eax,0xd0(%rsp,%r15,4)
movaps %xmm2,%xmm0
mulss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
addsd  0x85e(%rip),%xmm0
call   1090 <floor@plt>
xorps  %xmm1,%xmm1
mov    %eax,%ebp
test   %eax,%eax
cmove  %r13d,%ebp
mov    %ebp,0x40(%rsp)
mov    $0x1,%ebx
xor    %r12d,%r12d
movaps 0x10(%rsp),%xmm0
jmp    1832 <main+0x6c2>
nopl   (%rax)
movss  %xmm0,0xc(%rsp)
movss  0x90(%rsp,%rbx,4),%xmm1
movss  %xmm1,0x30(%rsp)
ucomiss %xmm0,%xmm1
seta   %r14b
cmova  %ebx,%r12d
movaps %xmm1,%xmm0
mulss  0x809(%rip),%xmm0
cvtss2sd %xmm0,%xmm0
addsd  0x801(%rip),%xmm0
call   1090 <floor@plt>
test   %eax,%eax
cmove  %r13d,%eax
mov    %eax,0x40(%rsp,%rbx,4)
add    %eax,%ebp
add    $0x1,%rbx
movss  0xc(%rsp),%xmm1
movss  0x30(%rsp),%xmm0
cmp    $0x10,%rbx
je     1390 <main+0x220>
test   $0x1,%r14b
jne    17d0 <main+0x660>
movaps %xmm1,%xmm0
jmp    17d0 <main+0x660>
mov    0x279c(%rip),%rax
mov    (%rax),%edi
lea    0x7c3(%rip),%rsi
call   1050 <fprintf@plt>
mov    $0x1,%r14d
jmp    1909 <main+0x799>
movaps 0x10(%rsp),%xmm0
movss  %xmm0,0x90(%rsp)
mov    0x28(%rsp),%r15d
lea    0x8cd(%rip),%rdi
call   1030 <puts@plt>
lea    0x800(%rip),%rdi
call   1030 <puts@plt>
lea    0x833(%rip),%rdi
xor    %r14d,%r14d
mov    %r15d,%esi
xor    %eax,%eax
call   1040 <printf@plt>
test   %r15d,%r15d
jle    18fd <main+0x78d>
lea    0x845(%rip),%rdi
lea    0x893(%rip),%rdx
xor    %esi,%esi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    $0x1,%r15d
je     18fd <main+0x78d>
mov    $0x1,%ebp
lea    0x823(%rip),%r15
lea    0x871(%rip),%r12
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    0xd0(%rsp,%rbp,4),%esi
add    $0x1,%rbp
mov    %r15,%rdi
mov    %r12,%rdx
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %rbp,%rbx
jne    18e0 <main+0x770>
lea    0x840(%rip),%rdi
call   1030 <puts@plt>
mov    %r14d,%eax
add    $0x200d8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@stderr = global i32 0
@.str = [48 x i8] c"usage: gen_laplace_tables <nb entries> <shift>\0A\00"
@.str.1 = [69 x i8] c"/* This file is auto-generated using \22gen_laplace_tables %d %d\22 */\0A\0A\00"
@.str.2 = [22 x i8] c"#ifdef HAVE_CONFIG_H\0A\00"
@.str.3 = [21 x i8] c"#include \22config.h\22\0A\00"
@.str.4 = [9 x i8] c"#endif\0A\0A\00"
@.str.5 = [28 x i8] c"#include \22laplace_code.h\22\0A\0A\00"
@.str.6 = [46 x i8] c"const ogg_uint16_t EXP_CDF_TABLE[%d][16] = {\0A\00"
@.str.7 = [4 x i8] c" {\00"
@.str.8 = [6 x i8] c"%5d%s\00"
@.str.9 = [2 x i8] c",\00"
@.str.10 = [1 x i8] zeroinitializer
@.str.11 = [4 x i8] c"},\0A\00"
@.str.12 = [5 x i8] c"}%s\0A\00"
@.str.13 = [4 x i8] c"};\0A\00"
@.str.14 = [3 x i8] c"\0A\0A\00"
@.str.15 = [43 x i8] c"const ogg_uint16_t LAPLACE_OFFSET[%d] = {\0A\00"
@.str.16 = [8 x i8] c" %d%s\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca [16 x float]
%11 = alloca [16 x i32]
%12 = alloca i32
%13 = alloca [32768 x i32]
%14 = alloca float
%15 = alloca i32
%16 = alloca float
%17 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%18 = load i32, i32* %4
%19 = icmp ne i32 %18, 3
br i1 %19, label %20, label %23
20: ; preds = %2
%21 = load i32, i32* @stderr
%22 = call i32 @fprintf(i32 %21, i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str, i64 0, i64 0))
store i32 1, i32* %3
br label %229
23: ; preds = %2
%24 = load i8**, i8*** %5
%25 = getelementptr inbounds i8*, i8** %24, i64 1
%26 = load i8*, i8** %25
%27 = call i32 @atoi(i8* %26)
store i32 %27, i32* %7
%28 = load i8**, i8*** %5
%29 = getelementptr inbounds i8*, i8** %28, i64 2
%30 = load i8*, i8** %29
%31 = call i32 @atoi(i8* %30)
store i32 %31, i32* %8
%32 = load i32, i32* %7
%33 = load i32, i32* %8
%34 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([69 x i8], [69 x i8]* @.str.1, i64 0, i64 0), i32 %32, i32 %33)
%35 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.2, i64 0, i64 0))
%36 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.3, i64 0, i64 0))
%37 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.4, i64 0, i64 0))
%38 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.5, i64 0, i64 0))
%39 = load i32, i32* %7
%40 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.6, i64 0, i64 0), i32 %39)
%41 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.7, i64 0, i64 0))
store i32 0, i32* %9
br label %42
42: ; preds = %54, %23
%43 = load i32, i32* %9
%44 = icmp slt i32 %43, 16
br i1 %44, label %45, label %57
45: ; preds = %42
%46 = load i32, i32* %9
%47 = add i32 32753, %46
%48 = load i32, i32* %9
%49 = add nsw i32 %48, 1
%50 = icmp slt i32 %49, 16
%51 = zext i1 %50 to i64
%52 = select i1 %50, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.10, i64 0, i64 0)
%53 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %47, i8* %52)
br label %54
54: ; preds = %45
%55 = load i32, i32* %9
%56 = add nsw i32 %55, 1
store i32 %56, i32* %9
br label %42
57: ; preds = %42
%58 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0))
%59 = getelementptr inbounds [32768 x i32], [32768 x i32]* %13, i64 0, i64 0
store i32 1, i32* %59
%60 = getelementptr inbounds [32768 x i32], [32768 x i32]* %13, i64 0, i64 0
store i32 0, i32* %60
store i32 1, i32* %6
br label %61
61: ; preds = %200, %57
%62 = load i32, i32* %6
%63 = load i32, i32* %7
%64 = icmp slt i32 %62, %63
br i1 %64, label %65, label %203
65: ; preds = %61
%66 = load i32, i32* %6
%67 = sitofp i32 %66 to float
%68 = load i32, i32* %8
%69 = shl i32 1, %68
%70 = sitofp i32 %69 to float
%71 = fdiv float %67, %70
store float %71, float* %14
%72 = load float, float* %14
%73 = fsub float 1.000000e+00, %72
%74 = getelementptr inbounds [16 x float], [16 x float]* %10, i64 0, i64 0
store float %73, float* %74
store i32 1, i32* %9
br label %75
75: ; preds = %89, %65
%76 = load i32, i32* %9
%77 = icmp slt i32 %76, 15
br i1 %77, label %78, label %92
78: ; preds = %75
%79 = load float, float* %14
%80 = fsub float 1.000000e+00, %79
%81 = load float, float* %14
%82 = load i32, i32* %9
%83 = call i32 @pow(float %81, i32 %82)
%84 = sitofp i32 %83 to float
%85 = fmul float %80, %84
%86 = load i32, i32* %9
%87 = sext i32 %86 to i64
%88 = getelementptr inbounds [16 x float], [16 x float]* %10, i64 0, i64 %87
store float %85, float* %88
br label %89
89: ; preds = %78
%90 = load i32, i32* %9
%91 = add nsw i32 %90, 1
store i32 %91, i32* %9
br label %75
92: ; preds = %75
%93 = load float, float* %14
%94 = call i32 @pow(float %93, i32 15)
%95 = sitofp i32 %94 to float
%96 = getelementptr inbounds [16 x float], [16 x float]* %10, i64 0, i64 15
store float %95, float* %96
%97 = getelementptr inbounds [16 x float], [16 x float]* %10, i64 0, i64 0
%98 = load float, float* %97
%99 = getelementptr inbounds [16 x float], [16 x float]* %10, i64 0, i64 0
%100 = load float, float* %99
%101 = load float, float* %14
%102 = call i32 @sqrt(float %101)
%103 = sitofp i32 %102 to float
%104 = fmul float %100, %103
%105 = load float, float* %14
%106 = call i32 @sqrt(float %105)
%107 = add nsw i32 1, %106
%108 = sitofp i32 %107 to float
%109 = fdiv float %104, %108
%110 = fsub float %98, %109
%111 = fmul float 3.276800e+04, %110
%112 = fptosi float %111 to i32
%113 = load i32, i32* %6
%114 = sext i32 %113 to i64
%115 = getelementptr inbounds [32768 x i32], [32768 x i32]* %13, i64 0, i64 %114
store i32 %112, i32* %115
store i32 0, i32* %12
store float 0.000000e+00, float* %16
store i32 0, i32* %17
store i32 0, i32* %9
br label %116
116: ; preds = %160, %92
%117 = load i32, i32* %9
%118 = icmp slt i32 %117, 16
br i1 %118, label %119, label %163
119: ; preds = %116
%120 = load i32, i32* %9
%121 = sext i32 %120 to i64
%122 = getelementptr inbounds [16 x float], [16 x float]* %10, i64 0, i64 %121
%123 = load float, float* %122
%124 = load float, float* %16
%125 = fcmp ogt float %123, %124
br i1 %125, label %126, label %132
126: ; preds = %119
%127 = load i32, i32* %9
%128 = sext i32 %127 to i64
%129 = getelementptr inbounds [16 x float], [16 x float]* %10, i64 0, i64 %128
%130 = load float, float* %129
store float %130, float* %16
%131 = load i32, i32* %9
store i32 %131, i32* %17
br label %132
132: ; preds = %126, %119
%133 = load i32, i32* %9
%134 = sext i32 %133 to i64
%135 = getelementptr inbounds [16 x float], [16 x float]* %10, i64 0, i64 %134
%136 = load float, float* %135
%137 = fmul float 3.276800e+04, %136
%138 = fpext float %137 to double
%139 = fadd double 5.000000e-01, %138
%140 = call i32 @floor(double %139)
%141 = load i32, i32* %9
%142 = sext i32 %141 to i64
%143 = getelementptr inbounds [16 x i32], [16 x i32]* %11, i64 0, i64 %142
store i32 %140, i32* %143
%144 = load i32, i32* %9
%145 = sext i32 %144 to i64
%146 = getelementptr inbounds [16 x i32], [16 x i32]* %11, i64 0, i64 %145
%147 = load i32, i32* %146
%148 = icmp eq i32 %147, 0
br i1 %148, label %149, label %153
149: ; preds = %132
%150 = load i32, i32* %9
%151 = sext i32 %150 to i64
%152 = getelementptr inbounds [16 x i32], [16 x i32]* %11, i64 0, i64 %151
store i32 1, i32* %152
br label %153
153: ; preds = %149, %132
%154 = load i32, i32* %9
%155 = sext i32 %154 to i64
%156 = getelementptr inbounds [16 x i32], [16 x i32]* %11, i64 0, i64 %155
%157 = load i32, i32* %156
%158 = load i32, i32* %12
%159 = add nsw i32 %158, %157
store i32 %159, i32* %12
br label %160
160: ; preds = %153
%161 = load i32, i32* %9
%162 = add nsw i32 %161, 1
store i32 %162, i32* %9
br label %116
163: ; preds = %116
%164 = load i32, i32* %12
%165 = sub nsw i32 32768, %164
%166 = load i32, i32* %17
%167 = sext i32 %166 to i64
%168 = getelementptr inbounds [16 x i32], [16 x i32]* %11, i64 0, i64 %167
%169 = load i32, i32* %168
%170 = add nsw i32 %169, %165
store i32 %170, i32* %168
store i32 0, i32* %15
%171 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.7, i64 0, i64 0))
store i32 0, i32* %9
br label %172
172: ; preds = %189, %163
%173 = load i32, i32* %9
%174 = icmp slt i32 %173, 16
br i1 %174, label %175, label %192
175: ; preds = %172
%176 = load i32, i32* %9
%177 = sext i32 %176 to i64
%178 = getelementptr inbounds [16 x i32], [16 x i32]* %11, i64 0, i64 %177
%179 = load i32, i32* %178
%180 = load i32, i32* %15
%181 = add nsw i32 %180, %179
store i32 %181, i32* %15
%182 = load i32, i32* %15
%183 = load i32, i32* %9
%184 = add nsw i32 %183, 1
%185 = icmp slt i32 %184, 16
%186 = zext i1 %185 to i64
%187 = select i1 %185, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.10, i64 0, i64 0)
%188 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %182, i8* %187)
br label %189
189: ; preds = %175
%190 = load i32, i32* %9
%191 = add nsw i32 %190, 1
store i32 %191, i32* %9
br label %172
192: ; preds = %172
%193 = load i32, i32* %6
%194 = add nsw i32 %193, 1
%195 = load i32, i32* %7
%196 = icmp sle i32 %194, %195
%197 = zext i1 %196 to i64
%198 = select i1 %196, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.10, i64 0, i64 0)
%199 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.12, i64 0, i64 0), i8* %198)
br label %200
200: ; preds = %192
%201 = load i32, i32* %6
%202 = add nsw i32 %201, 1
store i32 %202, i32* %6
br label %61
203: ; preds = %61
%204 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.13, i64 0, i64 0))
%205 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.14, i64 0, i64 0))
%206 = load i32, i32* %7
%207 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.15, i64 0, i64 0), i32 %206)
store i32 0, i32* %6
br label %208
208: ; preds = %224, %203
%209 = load i32, i32* %6
%210 = load i32, i32* %7
%211 = icmp slt i32 %209, %210
br i1 %211, label %212, label %227
212: ; preds = %208
%213 = load i32, i32* %6
%214 = sext i32 %213 to i64
%215 = getelementptr inbounds [32768 x i32], [32768 x i32]* %13, i64 0, i64 %214
%216 = load i32, i32* %215
%217 = load i32, i32* %6
%218 = add nsw i32 %217, 1
%219 = load i32, i32* %7
%220 = icmp sle i32 %218, %219
%221 = zext i1 %220 to i64
%222 = select i1 %220, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.10, i64 0, i64 0)
%223 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.16, i64 0, i64 0), i32 %216, i8* %222)
br label %224
224: ; preds = %212
%225 = load i32, i32* %6
%226 = add nsw i32 %225, 1
store i32 %226, i32* %6
br label %208
227: ; preds = %208
%228 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.13, i64 0, i64 0))
store i32 0, i32* %3
br label %229
229: ; preds = %227, %20
%230 = load i32, i32* %3
ret i32 %230
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [48 x i8] c"usage: gen_laplace_tables <nb entries> <shift>\0A\00"
@.str.1 = [69 x i8] c"/* This file is auto-generated using \22gen_laplace_tables %d %d\22 */\0A\0A\00"
@.str.6 = [46 x i8] c"const ogg_uint16_t EXP_CDF_TABLE[%d][16] = {\0A\00"
@.str.7 = [4 x i8] c" {\00"
@.str.8 = [6 x i8] c"%5d%s\00"
@.str.9 = [2 x i8] c",\00"
@.str.10 = [1 x i8] zeroinitializer
@.str.12 = [5 x i8] c"}%s\0A\00"
@.str.15 = [43 x i8] c"const ogg_uint16_t LAPLACE_OFFSET[%d] = {\0A\00"
@.str.16 = [8 x i8] c" %d%s\0A\00"
@str = [21 x i8] c"#ifdef HAVE_CONFIG_H\00"
@str.17 = [20 x i8] c"#include \22config.h\22\00"
@str.18 = [8 x i8] c"#endif\0A\00"
@str.19 = [27 x i8] c"#include \22laplace_code.h\22\0A\00"
@str.20 = [3 x i8] c"},\00"
@str.22 = [2 x i8] c"\0A\00"
@str.23 = [3 x i8] c"};\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = alloca [16 x float]
%4 = alloca [16 x i32]
%5 = alloca [32768 x i32]
%6 = bitcast [16 x float]* %3 to i8*
%7 = bitcast [16 x i32]* %4 to i8*
%8 = bitcast [32768 x i32]* %5 to i8*
%9 = icmp eq i32 %0, 3
br i1 %9, label %13, label %10
10: ; preds = %2
%11 = load i32, i32* @stderr
%12 = tail call i32 @fprintf(i32 %11, i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str, i64 0, i64 0))
br label %240
13: ; preds = %2
%14 = getelementptr inbounds i8*, i8** %1, i64 1
%15 = load i8*, i8** %14
%16 = tail call i32 @atoi(i8* %15)
%17 = getelementptr inbounds i8*, i8** %1, i64 2
%18 = load i8*, i8** %17
%19 = tail call i32 @atoi(i8* %18)
%20 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([69 x i8], [69 x i8]* @.str.1, i64 0, i64 0), i32 %16, i32 %19)
%21 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @str, i64 0, i64 0))
%22 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @str.17, i64 0, i64 0))
%23 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @str.18, i64 0, i64 0))
%24 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @str.19, i64 0, i64 0))
%25 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([46 x i8], [46 x i8]* @.str.6, i64 0, i64 0), i32 %16)
%26 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.7, i64 0, i64 0))
%27 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32753, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%28 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32754, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%29 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32755, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%30 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32756, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%31 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32757, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%32 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32758, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%33 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32759, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%34 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32760, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%35 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32761, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%36 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32762, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%37 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32763, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%38 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32764, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%39 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32765, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%40 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32766, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%41 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32767, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%42 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 32768, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.10, i64 0, i64 0))
%43 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @str.20, i64 0, i64 0))
%44 = getelementptr inbounds [32768 x i32], [32768 x i32]* %5, i64 0, i64 0
store i32 0, i32* %44
%45 = icmp sgt i32 %16, 1
br i1 %45, label %46, label %222
46: ; preds = %13
%47 = shl nuw i32 1, %19
%48 = sitofp i32 %47 to float
%49 = getelementptr inbounds [16 x float], [16 x float]* %3, i64 0, i64 0
%50 = getelementptr inbounds [16 x float], [16 x float]* %3, i64 0, i64 15
%51 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 0
%52 = zext i32 %16 to i64
%53 = getelementptr inbounds [16 x float], [16 x float]* %3, i64 0, i64 1
%54 = getelementptr inbounds [16 x float], [16 x float]* %3, i64 0, i64 5
%55 = getelementptr inbounds [16 x float], [16 x float]* %3, i64 0, i64 9
%56 = getelementptr inbounds [16 x float], [16 x float]* %3, i64 0, i64 13
%57 = getelementptr inbounds [16 x float], [16 x float]* %3, i64 0, i64 14
%58 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 1
%59 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 2
%60 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 3
%61 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 4
%62 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 5
%63 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 6
%64 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 7
%65 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 8
%66 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 9
%67 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 10
%68 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 11
%69 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 12
%70 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 13
%71 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 14
%72 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 15
%73 = bitcast float* %53 to <4 x float>*
%74 = bitcast float* %54 to <4 x float>*
%75 = bitcast float* %55 to <4 x float>*
%76 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 0
br label %77
77: ; preds = %46, %164
%78 = phi i64 [ 1, %46 ], [ %218, %164 ]
%79 = trunc i64 %78 to i32
%80 = sitofp i32 %79 to float
%81 = fdiv float %80, %48
%82 = fsub float 1.000000e+00, %81
%83 = tail call i32 @pow(float %81, i32 1)
%84 = tail call i32 @pow(float %81, i32 2)
%85 = tail call i32 @pow(float %81, i32 3)
%86 = tail call i32 @pow(float %81, i32 4)
%87 = insertelement <4 x i32> poison, i32 %83, i64 0
%88 = insertelement <4 x i32> %87, i32 %84, i64 1
%89 = insertelement <4 x i32> %88, i32 %85, i64 2
%90 = insertelement <4 x i32> %89, i32 %86, i64 3
%91 = sitofp <4 x i32> %90 to <4 x float>
%92 = insertelement <4 x float> poison, float %82, i64 0
%93 = shufflevector <4 x float> %92, <4 x float> poison, <4 x i32> zeroinitializer
%94 = fmul <4 x float> %93, %91
store <4 x float> %94, <4 x float>* %73
%95 = tail call i32 @pow(float %81, i32 5)
%96 = tail call i32 @pow(float %81, i32 6)
%97 = tail call i32 @pow(float %81, i32 7)
%98 = tail call i32 @pow(float %81, i32 8)
%99 = insertelement <4 x i32> poison, i32 %95, i64 0
%100 = insertelement <4 x i32> %99, i32 %96, i64 1
%101 = insertelement <4 x i32> %100, i32 %97, i64 2
%102 = insertelement <4 x i32> %101, i32 %98, i64 3
%103 = sitofp <4 x i32> %102 to <4 x float>
%104 = fmul <4 x float> %93, %103
store <4 x float> %104, <4 x float>* %74
%105 = tail call i32 @pow(float %81, i32 9)
%106 = tail call i32 @pow(float %81, i32 10)
%107 = tail call i32 @pow(float %81, i32 11)
%108 = tail call i32 @pow(float %81, i32 12)
%109 = insertelement <4 x i32> poison, i32 %105, i64 0
%110 = insertelement <4 x i32> %109, i32 %106, i64 1
%111 = insertelement <4 x i32> %110, i32 %107, i64 2
%112 = insertelement <4 x i32> %111, i32 %108, i64 3
%113 = sitofp <4 x i32> %112 to <4 x float>
%114 = fmul <4 x float> %93, %113
store <4 x float> %114, <4 x float>* %75
%115 = tail call i32 @pow(float %81, i32 13)
%116 = sitofp i32 %115 to float
%117 = fmul float %82, %116
store float %117, float* %56
%118 = tail call i32 @pow(float %81, i32 14)
%119 = sitofp i32 %118 to float
%120 = fmul float %82, %119
store float %120, float* %57
%121 = tail call i32 @pow(float %81, i32 15)
%122 = sitofp i32 %121 to float
store float %122, float* %50
%123 = tail call i32 @sqrt(float %81)
%124 = sitofp i32 %123 to float
%125 = fmul float %82, %124
%126 = tail call i32 @sqrt(float %81)
%127 = add nsw i32 %126, 1
%128 = sitofp i32 %127 to float
%129 = fdiv float %125, %128
%130 = fsub float %82, %129
%131 = fmul float %130, 3.276800e+04
%132 = fptosi float %131 to i32
%133 = getelementptr inbounds [32768 x i32], [32768 x i32]* %5, i64 0, i64 %78
store i32 %132, i32* %133
%134 = fcmp ogt float %82, 0.000000e+00
%135 = fmul float %82, 3.276800e+04
%136 = fpext float %135 to double
%137 = fadd double %136, 5.000000e-01
%138 = tail call i32 @floor(double %137)
%139 = icmp eq i32 %138, 0
%140 = select i1 %139, i32 1, i32 %138
store i32 %140, i32* %76
br label %141
141: ; preds = %77, %141
%142 = phi i64 [ 1, %77 ], [ %162, %141 ]
%143 = phi i32 [ %140, %77 ], [ %161, %141 ]
%144 = phi i32 [ 0, %77 ], [ %153, %141 ]
%145 = phi i1 [ %134, %77 ], [ %151, %141 ]
%146 = phi float [ 0.000000e+00, %77 ], [ %148, %141 ]
%147 = phi float [ %82, %77 ], [ %150, %141 ]
%148 = select i1 %145, float %147, float %146
%149 = getelementptr inbounds [16 x float], [16 x float]* %3, i64 0, i64 %142
%150 = load float, float* %149
%151 = fcmp ogt float %150, %148
%152 = trunc i64 %142 to i32
%153 = select i1 %151, i32 %152, i32 %144
%154 = fmul float %150, 3.276800e+04
%155 = fpext float %154 to double
%156 = fadd double %155, 5.000000e-01
%157 = tail call i32 @floor(double %156)
%158 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 %142
%159 = icmp eq i32 %157, 0
%160 = select i1 %159, i32 1, i32 %157
store i32 %160, i32* %158
%161 = add nsw i32 %160, %143
%162 = add nuw nsw i64 %142, 1
%163 = icmp eq i64 %162, 16
br i1 %163, label %164, label %141
164: ; preds = %141
%165 = sub i32 32768, %161
%166 = sext i32 %153 to i64
%167 = getelementptr inbounds [16 x i32], [16 x i32]* %4, i64 0, i64 %166
%168 = load i32, i32* %167
%169 = add nsw i32 %165, %168
store i32 %169, i32* %167
%170 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.7, i64 0, i64 0))
%171 = load i32, i32* %51
%172 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %171, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%173 = load i32, i32* %58
%174 = add nsw i32 %173, %171
%175 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %174, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%176 = load i32, i32* %59
%177 = add nsw i32 %176, %174
%178 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %177, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%179 = load i32, i32* %60
%180 = add nsw i32 %179, %177
%181 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %180, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%182 = load i32, i32* %61
%183 = add nsw i32 %182, %180
%184 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %183, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%185 = load i32, i32* %62
%186 = add nsw i32 %185, %183
%187 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %186, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%188 = load i32, i32* %63
%189 = add nsw i32 %188, %186
%190 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %189, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%191 = load i32, i32* %64
%192 = add nsw i32 %191, %189
%193 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %192, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%194 = load i32, i32* %65
%195 = add nsw i32 %194, %192
%196 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %195, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%197 = load i32, i32* %66
%198 = add nsw i32 %197, %195
%199 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %198, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%200 = load i32, i32* %67
%201 = add nsw i32 %200, %198
%202 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %201, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%203 = load i32, i32* %68
%204 = add nsw i32 %203, %201
%205 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %204, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%206 = load i32, i32* %69
%207 = add nsw i32 %206, %204
%208 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %207, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%209 = load i32, i32* %70
%210 = add nsw i32 %209, %207
%211 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %210, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%212 = load i32, i32* %71
%213 = add nsw i32 %212, %210
%214 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %213, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%215 = load i32, i32* %72
%216 = add nsw i32 %215, %213
%217 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.8, i64 0, i64 0), i32 %216, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.10, i64 0, i64 0))
%218 = add nuw nsw i64 %78, 1
%219 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.12, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%220 = icmp eq i64 %218, %52
br i1 %220, label %221, label %77
221: ; preds = %164
store float %82, float* %49
br label %222
222: ; preds = %221, %13
%223 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @str.23, i64 0, i64 0))
%224 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([2 x i8], [2 x i8]* @str.22, i64 0, i64 0))
%225 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([43 x i8], [43 x i8]* @.str.15, i64 0, i64 0), i32 %16)
%226 = icmp sgt i32 %16, 0
br i1 %226, label %227, label %238
227: ; preds = %222
%228 = zext i32 %16 to i64
%229 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @.str.16, i64 0, i64 0), i32 0, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%230 = icmp eq i32 %16, 1
br i1 %230, label %238, label %231
231: ; preds = %227, %231
%232 = phi i64 [ %235, %231 ], [ 1, %227 ]
%233 = getelementptr inbounds [32768 x i32], [32768 x i32]* %5, i64 0, i64 %232
%234 = load i32, i32* %233
%235 = add nuw nsw i64 %232, 1
%236 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @.str.16, i64 0, i64 0), i32 %234, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%237 = icmp eq i64 %235, %228
br i1 %237, label %238, label %231
238: ; preds = %231, %227, %222
%239 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @str.23, i64 0, i64 0))
br label %240
240: ; preds = %238, %10
%241 = phi i32 [ 1, %10 ], [ 0, %238 ]
ret i32 %241
}