#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 */
unsigned char *cvector(int, int);
int /*<<< orphan*/ free_cvector(unsigned char *, int, int);
int /*<<< orphan*/ mp2dfr(unsigned char *, unsigned char *, int, int *);
int /*<<< orphan*/ mpdiv(unsigned char *, unsigned char *, unsigned char *,
                         unsigned char *, int, int);
int /*<<< orphan*/ mpmov(unsigned char *, unsigned char *, int);
int /*<<< orphan*/ mpsad(unsigned char *, unsigned char *, int, int);
int /*<<< orphan*/ mpsqrt(unsigned char *, unsigned char *, unsigned char *,
                          int, int);
int /*<<< orphan*/ printf(char *, ...);
void mpsqr2(int n) {
  int j, m;
  unsigned char *x, *y, *t, *q, *r, *s;
  x = cvector(1, 1024);
  y = cvector(1, 1024);
  t = cvector(1, 1024);
  q = cvector(1, 1024);
  r = cvector(1, 1024);
  s = cvector(1, 3 * 1024);
  t[1] = 2;
  for (j = 2; j <= n; j++)
    t[j] = 0;
  mpsqrt(x, x, t, n, n);
  mpmov(y, x, n);
  printf("sqrt(2)=\n");
  s[1] = y[1] + 48;
  s[2] = '.';
  mp2dfr(&y[1], &s[2], n - 1, &m);
  s[m + 3] = 0;
  printf(" %64s\n", &s[1]);
  printf("Result rounded to 1 less base-256 place:\n");
  mpsad(s, x, n, 128);
  mpmov(y, &s[1], n - 1);
  s[1] = y[1] + 48;
  s[2] = '.';
  mp2dfr(&y[1], &s[2], n - 2, &m);
  s[m + 3] = 0;
  printf(" %64s\n", &s[1]);
  printf("2-sqrt(2)=\n");
  mpdiv(q, r, t, x, n, n);
  s[1] = r[1] + 48;
  s[2] = '.';
  mp2dfr(&r[1], &s[2], n - 1, &m);
  s[m + 3] = 0;
  printf(" %64s\n", &s[1]);
  free_cvector(s, 1, 3 * 1024);
  free_cvector(r, 1, 1024);
  free_cvector(q, 1, 1024);
  free_cvector(t, 1, 1024);
  free_cvector(y, 1, 1024);
  free_cvector(x, 1, 1024);
}


x86 assembly (clang, -O0):
<mpsqr2>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x1,%edi
mov    $0x400,%esi
call   1060 <cvector@plt>
mov    %rax,-0x18(%rbp)
mov    $0x1,%edi
mov    $0x400,%esi
call   1060 <cvector@plt>
mov    %rax,-0x20(%rbp)
mov    $0x1,%edi
mov    $0x400,%esi
call   1060 <cvector@plt>
mov    %rax,-0x28(%rbp)
mov    $0x1,%edi
mov    $0x400,%esi
call   1060 <cvector@plt>
mov    %rax,-0x30(%rbp)
mov    $0x1,%edi
mov    $0x400,%esi
call   1060 <cvector@plt>
mov    %rax,-0x38(%rbp)
mov    $0x1,%edi
mov    $0xc00,%esi
call   1060 <cvector@plt>
mov    %rax,-0x40(%rbp)
mov    -0x28(%rbp),%rax
movb   $0x2,0x1(%rax)
movl   $0x2,-0x8(%rbp)
mov    -0x8(%rbp),%eax
cmp    -0x4(%rbp),%eax
jg     1232 <mpsqr2+0xb2>
mov    -0x28(%rbp),%rax
movslq -0x8(%rbp),%rcx
movb   $0x0,(%rax,%rcx,1)
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    120c <mpsqr2+0x8c>
mov    -0x18(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x28(%rbp),%rdx
mov    -0x4(%rbp),%ecx
mov    -0x4(%rbp),%r8d
call   1030 <mpsqrt@plt>
mov    -0x20(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x4(%rbp),%edx
call   1080 <mpmov@plt>
lea    0xdd2(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x20(%rbp),%rax
movzbl 0x1(%rax),%eax
add    $0x30,%eax
mov    %al,%cl
mov    -0x40(%rbp),%rax
mov    %cl,0x1(%rax)
mov    -0x40(%rbp),%rax
movb   $0x2e,0x2(%rax)
mov    -0x20(%rbp),%rdi
add    $0x1,%rdi
mov    -0x40(%rbp),%rsi
add    $0x2,%rsi
mov    -0x4(%rbp),%edx
sub    $0x1,%edx
lea    -0xc(%rbp),%rcx
call   1090 <mp2dfr@plt>
mov    -0x40(%rbp),%rax
mov    -0xc(%rbp),%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movb   $0x0,(%rax,%rcx,1)
mov    -0x40(%rbp),%rsi
add    $0x1,%rsi
lea    0xd3d(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xd36(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x40(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x4(%rbp),%edx
mov    $0x80,%ecx
call   1050 <mpsad@plt>
mov    -0x20(%rbp),%rdi
mov    -0x40(%rbp),%rsi
add    $0x1,%rsi
mov    -0x4(%rbp),%edx
sub    $0x1,%edx
call   1080 <mpmov@plt>
mov    -0x20(%rbp),%rax
movzbl 0x1(%rax),%eax
add    $0x30,%eax
mov    %al,%cl
mov    -0x40(%rbp),%rax
mov    %cl,0x1(%rax)
mov    -0x40(%rbp),%rax
movb   $0x2e,0x2(%rax)
mov    -0x20(%rbp),%rdi
add    $0x1,%rdi
mov    -0x40(%rbp),%rsi
add    $0x2,%rsi
mov    -0x4(%rbp),%edx
sub    $0x2,%edx
lea    -0xc(%rbp),%rcx
call   1090 <mp2dfr@plt>
mov    -0x40(%rbp),%rax
mov    -0xc(%rbp),%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movb   $0x0,(%rax,%rcx,1)
mov    -0x40(%rbp),%rsi
add    $0x1,%rsi
lea    0xca1(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xcc4(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x30(%rbp),%rdi
mov    -0x38(%rbp),%rsi
mov    -0x28(%rbp),%rdx
mov    -0x18(%rbp),%rcx
mov    -0x4(%rbp),%r8d
mov    -0x4(%rbp),%r9d
call   10a0 <mpdiv@plt>
mov    -0x38(%rbp),%rax
movzbl 0x1(%rax),%eax
add    $0x30,%eax
mov    %al,%cl
mov    -0x40(%rbp),%rax
mov    %cl,0x1(%rax)
mov    -0x40(%rbp),%rax
movb   $0x2e,0x2(%rax)
mov    -0x38(%rbp),%rdi
add    $0x1,%rdi
mov    -0x40(%rbp),%rsi
add    $0x2,%rsi
mov    -0x4(%rbp),%edx
sub    $0x1,%edx
lea    -0xc(%rbp),%rcx
call   1090 <mp2dfr@plt>
mov    -0x40(%rbp),%rax
mov    -0xc(%rbp),%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movb   $0x0,(%rax,%rcx,1)
mov    -0x40(%rbp),%rsi
add    $0x1,%rsi
lea    0xc14(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x40(%rbp),%rdi
mov    $0x1,%esi
mov    $0xc00,%edx
call   1070 <free_cvector@plt>
mov    -0x38(%rbp),%rdi
mov    $0x1,%esi
mov    $0x400,%edx
call   1070 <free_cvector@plt>
mov    -0x30(%rbp),%rdi
mov    $0x1,%esi
mov    $0x400,%edx
call   1070 <free_cvector@plt>
mov    -0x28(%rbp),%rdi
mov    $0x1,%esi
mov    $0x400,%edx
call   1070 <free_cvector@plt>
mov    -0x20(%rbp),%rdi
mov    $0x1,%esi
mov    $0x400,%edx
call   1070 <free_cvector@plt>
mov    -0x18(%rbp),%rdi
mov    $0x1,%esi
mov    $0x400,%edx
call   1070 <free_cvector@plt>
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mpsqr2>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x38,%rsp
mov    %edi,%ebx
mov    $0x1,%edi
mov    $0x400,%esi
call   1080 <cvector@plt>
mov    %rax,%r14
mov    $0x1,%edi
mov    $0x400,%esi
call   1080 <cvector@plt>
mov    %rax,%r15
mov    $0x1,%edi
mov    $0x400,%esi
call   1080 <cvector@plt>
mov    %rax,%rbp
mov    $0x1,%edi
mov    $0x400,%esi
call   1080 <cvector@plt>
mov    %rax,0x30(%rsp)
mov    $0x1,%edi
mov    $0x400,%esi
call   1080 <cvector@plt>
mov    %rax,0x28(%rsp)
mov    $0x1,%edi
mov    $0xc00,%esi
call   1080 <cvector@plt>
mov    %rax,%r12
movb   $0x2,0x1(%rbp)
cmp    $0x1,%ebx
jg     1233 <mpsqr2+0x93>
lea    -0x1(%rbx),%eax
mov    %rax,0x8(%rsp)
jmp    1249 <mpsqr2+0xa9>
mov    %rbp,%rdi
add    $0x2,%rdi
lea    -0x1(%rbx),%edx
xor    %esi,%esi
mov    %rdx,0x8(%rsp)
call   1060 <memset@plt>
mov    %r14,%rdi
mov    %r14,%rsi
mov    %rbp,%rdx
mov    %ebx,%ecx
mov    %ebx,%r8d
call   1040 <mpsqrt@plt>
mov    %r15,%rdi
mov    %r14,%rsi
mov    %ebx,%edx
call   10a0 <mpmov@plt>
lea    0xdc2(%rip),%rdi
call   1030 <puts@plt>
mov    %r15,0x18(%rsp)
mov    %r15,%r13
add    $0x1,%r13
mov    0x1(%r15),%al
add    $0x30,%al
mov    %rbp,0x20(%rsp)
mov    %rbx,%r15
lea    0x1(%r12),%rbx
mov    %al,0x1(%r12)
mov    %r14,%rbp
mov    %r14,0x10(%rsp)
mov    %r12,%r14
add    $0x2,%r14
movb   $0x2e,0x2(%r12)
lea    0x4(%rsp),%rcx
mov    %r13,%rdi
mov    %r14,%rsi
mov    0x8(%rsp),%rdx
mov    %rdx,0x8(%rsp)
call   10b0 <mp2dfr@plt>
movslq 0x4(%rsp),%rax
movb   $0x0,0x3(%rax,%r12,1)
lea    0xd26(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xd1c(%rip),%rdi
call   1030 <puts@plt>
mov    %r12,%rdi
mov    %rbp,%rsi
mov    %r15d,%edx
mov    $0x80,%ecx
call   1070 <mpsad@plt>
mov    0x18(%rsp),%rbp
mov    %rbp,%rdi
mov    %rbx,%rsi
mov    0x8(%rsp),%rdx
call   10a0 <mpmov@plt>
mov    0x1(%rbp),%al
add    $0x30,%al
mov    %al,0x1(%r12)
movb   $0x2e,0x2(%r12)
lea    -0x2(%r15),%edx
mov    %r13,%rdi
mov    %r14,%rsi
lea    0x4(%rsp),%rcx
call   10b0 <mp2dfr@plt>
movslq 0x4(%rsp),%rax
movb   $0x0,0x3(%rax,%r12,1)
lea    0xcb2(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xcd1(%rip),%rdi
call   1030 <puts@plt>
mov    0x30(%rsp),%r13
mov    %r13,%rdi
mov    0x28(%rsp),%rbp
mov    %rbp,%rsi
mov    0x20(%rsp),%rdx
mov    0x10(%rsp),%rcx
mov    %r15d,%r8d
mov    %r15d,%r9d
call   10c0 <mpdiv@plt>
mov    %rbp,%rdi
add    $0x1,%rdi
mov    0x1(%rbp),%al
add    $0x30,%al
mov    %al,0x1(%r12)
movb   $0x2e,0x2(%r12)
mov    %r14,%rsi
mov    0x8(%rsp),%rdx
lea    0x4(%rsp),%rcx
call   10b0 <mp2dfr@plt>
movslq 0x4(%rsp),%rax
movb   $0x0,0x3(%rax,%r12,1)
lea    0xc3c(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <printf@plt>
mov    %r12,%rdi
mov    $0x1,%esi
mov    $0xc00,%edx
call   1090 <free_cvector@plt>
mov    %rbp,%rdi
mov    $0x1,%esi
mov    $0x400,%edx
call   1090 <free_cvector@plt>
mov    %r13,%rdi
mov    $0x1,%esi
mov    $0x400,%edx
call   1090 <free_cvector@plt>
mov    0x20(%rsp),%rdi
mov    $0x1,%esi
mov    $0x400,%edx
call   1090 <free_cvector@plt>
mov    0x18(%rsp),%rdi
mov    $0x1,%esi
mov    $0x400,%edx
call   1090 <free_cvector@plt>
mov    0x10(%rsp),%rdi
mov    $0x1,%esi
mov    $0x400,%edx
call   1090 <free_cvector@plt>
add    $0x38,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [10 x i8] c"sqrt(2)=\0A\00"
@.str.1 = [7 x i8] c" %64s\0A\00"
@.str.2 = [42 x i8] c"Result rounded to 1 less base-256 place:\0A\00"
@.str.3 = [12 x i8] c"2-sqrt(2)=\0A\00"
define void @mpsqr2(i32 %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8*
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i8*
%9 = alloca i8*
%10 = alloca i8*
store i32 %0, i32* %2
%11 = call i8* @cvector(i32 1, i32 1024)
store i8* %11, i8** %5
%12 = call i8* @cvector(i32 1, i32 1024)
store i8* %12, i8** %6
%13 = call i8* @cvector(i32 1, i32 1024)
store i8* %13, i8** %7
%14 = call i8* @cvector(i32 1, i32 1024)
store i8* %14, i8** %8
%15 = call i8* @cvector(i32 1, i32 1024)
store i8* %15, i8** %9
%16 = call i8* @cvector(i32 1, i32 3072)
store i8* %16, i8** %10
%17 = load i8*, i8** %7
%18 = getelementptr inbounds i8, i8* %17, i64 1
store i8 2, i8* %18
store i32 2, i32* %3
br label %19
19: ; preds = %28, %1
%20 = load i32, i32* %3
%21 = load i32, i32* %2
%22 = icmp sle i32 %20, %21
br i1 %22, label %23, label %31
23: ; preds = %19
%24 = load i8*, i8** %7
%25 = load i32, i32* %3
%26 = sext i32 %25 to i64
%27 = getelementptr inbounds i8, i8* %24, i64 %26
store i8 0, i8* %27
br label %28
28: ; preds = %23
%29 = load i32, i32* %3
%30 = add nsw i32 %29, 1
store i32 %30, i32* %3
br label %19
31: ; preds = %19
%32 = load i8*, i8** %5
%33 = load i8*, i8** %5
%34 = load i8*, i8** %7
%35 = load i32, i32* %2
%36 = load i32, i32* %2
%37 = call i32 @mpsqrt(i8* %32, i8* %33, i8* %34, i32 %35, i32 %36)
%38 = load i8*, i8** %6
%39 = load i8*, i8** %5
%40 = load i32, i32* %2
%41 = call i32 @mpmov(i8* %38, i8* %39, i32 %40)
%42 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0))
%43 = load i8*, i8** %6
%44 = getelementptr inbounds i8, i8* %43, i64 1
%45 = load i8, i8* %44
%46 = zext i8 %45 to i32
%47 = add nsw i32 %46, 48
%48 = trunc i32 %47 to i8
%49 = load i8*, i8** %10
%50 = getelementptr inbounds i8, i8* %49, i64 1
store i8 %48, i8* %50
%51 = load i8*, i8** %10
%52 = getelementptr inbounds i8, i8* %51, i64 2
store i8 46, i8* %52
%53 = load i8*, i8** %6
%54 = getelementptr inbounds i8, i8* %53, i64 1
%55 = load i8*, i8** %10
%56 = getelementptr inbounds i8, i8* %55, i64 2
%57 = load i32, i32* %2
%58 = sub nsw i32 %57, 1
%59 = call i32 @mp2dfr(i8* %54, i8* %56, i32 %58, i32* %4)
%60 = load i8*, i8** %10
%61 = load i32, i32* %4
%62 = add nsw i32 %61, 3
%63 = sext i32 %62 to i64
%64 = getelementptr inbounds i8, i8* %60, i64 %63
store i8 0, i8* %64
%65 = load i8*, i8** %10
%66 = getelementptr inbounds i8, i8* %65, i64 1
%67 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i8* %66)
%68 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.2, i64 0, i64 0))
%69 = load i8*, i8** %10
%70 = load i8*, i8** %5
%71 = load i32, i32* %2
%72 = call i32 @mpsad(i8* %69, i8* %70, i32 %71, i32 128)
%73 = load i8*, i8** %6
%74 = load i8*, i8** %10
%75 = getelementptr inbounds i8, i8* %74, i64 1
%76 = load i32, i32* %2
%77 = sub nsw i32 %76, 1
%78 = call i32 @mpmov(i8* %73, i8* %75, i32 %77)
%79 = load i8*, i8** %6
%80 = getelementptr inbounds i8, i8* %79, i64 1
%81 = load i8, i8* %80
%82 = zext i8 %81 to i32
%83 = add nsw i32 %82, 48
%84 = trunc i32 %83 to i8
%85 = load i8*, i8** %10
%86 = getelementptr inbounds i8, i8* %85, i64 1
store i8 %84, i8* %86
%87 = load i8*, i8** %10
%88 = getelementptr inbounds i8, i8* %87, i64 2
store i8 46, i8* %88
%89 = load i8*, i8** %6
%90 = getelementptr inbounds i8, i8* %89, i64 1
%91 = load i8*, i8** %10
%92 = getelementptr inbounds i8, i8* %91, i64 2
%93 = load i32, i32* %2
%94 = sub nsw i32 %93, 2
%95 = call i32 @mp2dfr(i8* %90, i8* %92, i32 %94, i32* %4)
%96 = load i8*, i8** %10
%97 = load i32, i32* %4
%98 = add nsw i32 %97, 3
%99 = sext i32 %98 to i64
%100 = getelementptr inbounds i8, i8* %96, i64 %99
store i8 0, i8* %100
%101 = load i8*, i8** %10
%102 = getelementptr inbounds i8, i8* %101, i64 1
%103 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i8* %102)
%104 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%105 = load i8*, i8** %8
%106 = load i8*, i8** %9
%107 = load i8*, i8** %7
%108 = load i8*, i8** %5
%109 = load i32, i32* %2
%110 = load i32, i32* %2
%111 = call i32 @mpdiv(i8* %105, i8* %106, i8* %107, i8* %108, i32 %109, i32 %110)
%112 = load i8*, i8** %9
%113 = getelementptr inbounds i8, i8* %112, i64 1
%114 = load i8, i8* %113
%115 = zext i8 %114 to i32
%116 = add nsw i32 %115, 48
%117 = trunc i32 %116 to i8
%118 = load i8*, i8** %10
%119 = getelementptr inbounds i8, i8* %118, i64 1
store i8 %117, i8* %119
%120 = load i8*, i8** %10
%121 = getelementptr inbounds i8, i8* %120, i64 2
store i8 46, i8* %121
%122 = load i8*, i8** %9
%123 = getelementptr inbounds i8, i8* %122, i64 1
%124 = load i8*, i8** %10
%125 = getelementptr inbounds i8, i8* %124, i64 2
%126 = load i32, i32* %2
%127 = sub nsw i32 %126, 1
%128 = call i32 @mp2dfr(i8* %123, i8* %125, i32 %127, i32* %4)
%129 = load i8*, i8** %10
%130 = load i32, i32* %4
%131 = add nsw i32 %130, 3
%132 = sext i32 %131 to i64
%133 = getelementptr inbounds i8, i8* %129, i64 %132
store i8 0, i8* %133
%134 = load i8*, i8** %10
%135 = getelementptr inbounds i8, i8* %134, i64 1
%136 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i8* %135)
%137 = load i8*, i8** %10
%138 = call i32 @free_cvector(i8* %137, i32 1, i32 3072)
%139 = load i8*, i8** %9
%140 = call i32 @free_cvector(i8* %139, i32 1, i32 1024)
%141 = load i8*, i8** %8
%142 = call i32 @free_cvector(i8* %141, i32 1, i32 1024)
%143 = load i8*, i8** %7
%144 = call i32 @free_cvector(i8* %143, i32 1, i32 1024)
%145 = load i8*, i8** %6
%146 = call i32 @free_cvector(i8* %145, i32 1, i32 1024)
%147 = load i8*, i8** %5
%148 = call i32 @free_cvector(i8* %147, i32 1, i32 1024)
ret void
}

LLVM IR (-O2):
@.str.1 = [7 x i8] c" %64s\0A\00"
@str = [9 x i8] c"sqrt(2)=\00"
@str.4 = [41 x i8] c"Result rounded to 1 less base-256 place:\00"
@str.5 = [11 x i8] c"2-sqrt(2)=\00"
define void @mpsqr2(i32 %0) {
%2 = alloca i32
%3 = bitcast i32* %2 to i8*
%4 = tail call i8* @cvector(i32 1, i32 1024)
%5 = tail call i8* @cvector(i32 1, i32 1024)
%6 = tail call i8* @cvector(i32 1, i32 1024)
%7 = tail call i8* @cvector(i32 1, i32 1024)
%8 = tail call i8* @cvector(i32 1, i32 1024)
%9 = tail call i8* @cvector(i32 1, i32 3072)
%10 = getelementptr inbounds i8, i8* %6, i64 1
store i8 2, i8* %10
%11 = icmp slt i32 %0, 2
br i1 %11, label %12, label %14
12: ; preds = %1
%13 = add nsw i32 %0, -1
br label %18
14: ; preds = %1
%15 = getelementptr i8, i8* %6, i64 2
%16 = add nsw i32 %0, -1
%17 = zext i32 %16 to i64
br label %18
18: ; preds = %12, %14
%19 = phi i32 [ %13, %12 ], [ %16, %14 ]
%20 = tail call i32 @mpsqrt(i8* %4, i8* %4, i8* %6, i32 %0, i32 %0)
%21 = tail call i32 @mpmov(i8* %5, i8* %4, i32 %0)
%22 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @str, i64 0, i64 0))
%23 = getelementptr inbounds i8, i8* %5, i64 1
%24 = load i8, i8* %23
%25 = add i8 %24, 48
%26 = getelementptr inbounds i8, i8* %9, i64 1
store i8 %25, i8* %26
%27 = getelementptr inbounds i8, i8* %9, i64 2
store i8 46, i8* %27
%28 = call i32 @mp2dfr(i8* %23, i8* %27, i32 %19, i32* %2)
%29 = load i32, i32* %2
%30 = add nsw i32 %29, 3
%31 = sext i32 %30 to i64
%32 = getelementptr inbounds i8, i8* %9, i64 %31
store i8 0, i8* %32
%33 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i8* %26)
%34 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @str.4, i64 0, i64 0))
%35 = call i32 @mpsad(i8* %9, i8* %4, i32 %0, i32 128)
%36 = call i32 @mpmov(i8* %5, i8* %26, i32 %19)
%37 = load i8, i8* %23
%38 = add i8 %37, 48
store i8 %38, i8* %26
store i8 46, i8* %27
%39 = add nsw i32 %0, -2
%40 = call i32 @mp2dfr(i8* %23, i8* %27, i32 %39, i32* %2)
%41 = load i32, i32* %2
%42 = add nsw i32 %41, 3
%43 = sext i32 %42 to i64
%44 = getelementptr inbounds i8, i8* %9, i64 %43
store i8 0, i8* %44
%45 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i8* %26)
%46 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @str.5, i64 0, i64 0))
%47 = call i32 @mpdiv(i8* %7, i8* %8, i8* %6, i8* %4, i32 %0, i32 %0)
%48 = getelementptr inbounds i8, i8* %8, i64 1
%49 = load i8, i8* %48
%50 = add i8 %49, 48
store i8 %50, i8* %26
store i8 46, i8* %27
%51 = call i32 @mp2dfr(i8* %48, i8* %27, i32 %19, i32* %2)
%52 = load i32, i32* %2
%53 = add nsw i32 %52, 3
%54 = sext i32 %53 to i64
%55 = getelementptr inbounds i8, i8* %9, i64 %54
store i8 0, i8* %55
%56 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i8* %26)
%57 = call i32 @free_cvector(i8* %9, i32 1, i32 3072)
%58 = call i32 @free_cvector(i8* %8, i32 1, i32 1024)
%59 = call i32 @free_cvector(i8* %7, i32 1, i32 1024)
%60 = call i32 @free_cvector(i8* %6, i32 1, i32 1024)
%61 = call i32 @free_cvector(i8* %5, i32 1, i32 1024)
%62 = call i32 @free_cvector(i8* %4, i32 1, i32 1024)
ret void
}