#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 */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, char);
int /*<<< orphan*/ fscanf(int /*<<< orphan*/ *, char *, char *);
int /*<<< orphan*/ printf(char *, ...);
int rand();
void geraArquivoeImprimeSudoku() {
  int i, j, aux = 0;
  char sudokuTemp[9][9];
  FILE *arq1;
  arq1 = fopen("sudoku_modelo.txt", "r");
  if (arq1 == NULL)
    printf("Problemas na CRIACAO do arquivo\n");
  for (i = 0; i < 9; i++)
    for (j = 0; j < 9; j++)
      fscanf(arq1, "%c", &sudokuTemp[i][j]);
  for (i = 0; i < 9; i++) {
    do {
      j = rand() % 9;
      sudokuTemp[i][j] = ' ';
      j = rand() % 9;
      sudokuTemp[i][j] = ' ';
      j = rand() % 9;
      sudokuTemp[i][j] = ' ';
      j = rand() % 9;
      sudokuTemp[i][j] = ' ';
      j = rand() % 9;
      sudokuTemp[i][j] = ' ';
      j = rand() % 9;
      sudokuTemp[i][j] = ' ';
      aux++;
    } while (aux < 5);
  }
  printf("+--------+--------+--------+\n");
  for (i = 0; i < 9; i++) {
    for (j = 0; j < 9; j++) {
      printf(" %c ", sudokuTemp[i][j]);
    }
    printf("\n");
  }
  printf("+--------+--------+--------+\n");
  fclose(arq1);
  FILE *arq2;
  arq2 = fopen("sudoku.txt", "w");
  if (arq2 == NULL)
    printf("Problemas na CRIACAO do arquivo\n");
  fprintf(arq2, "+--------+--------+--------+\n", sudokuTemp[i][j]);
  for (i = 0; i < 9; i++)
    for (j = 0; j < 9; j++) {
      if (j == 8)
        fprintf(arq2, " %c \n", sudokuTemp[i][j]);
      else
        fprintf(arq2, " %c ", sudokuTemp[i][j]);
    }
  fprintf(arq2, "+--------+--------+--------+\n", sudokuTemp[i][j]);
  fclose(arq2);
}


x86 assembly (clang, -O0):
<geraArquivoeImprimeSudoku>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
movl   $0x0,-0xc(%rbp)
lea    0xe8a(%rip),%rdi
lea    0xe95(%rip),%rsi
call   1070 <fopen@plt>
mov    %rax,-0x68(%rbp)
cmpq   $0x0,-0x68(%rbp)
jne    119f <geraArquivoeImprimeSudoku+0x3f>
lea    0xe7c(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
movl   $0x0,-0x4(%rbp)
cmpl   $0x9,-0x4(%rbp)
jge    1208 <geraArquivoeImprimeSudoku+0xa8>
movl   $0x0,-0x8(%rbp)
cmpl   $0x9,-0x8(%rbp)
jge    11f5 <geraArquivoeImprimeSudoku+0x95>
mov    -0x68(%rbp),%rdi
movslq -0x4(%rbp),%rax
lea    -0x60(%rbp),%rdx
imul   $0x9,%rax,%rax
add    %rax,%rdx
movslq -0x8(%rbp),%rax
add    %rax,%rdx
lea    0xe53(%rip),%rsi
call   1050 <fscanf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    11b7 <geraArquivoeImprimeSudoku+0x57>
jmp    11fa <geraArquivoeImprimeSudoku+0x9a>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    11a6 <geraArquivoeImprimeSudoku+0x46>
movl   $0x0,-0x4(%rbp)
cmpl   $0x9,-0x4(%rbp)
jge    133a <geraArquivoeImprimeSudoku+0x1da>
jmp    121e <geraArquivoeImprimeSudoku+0xbe>
mov    $0x0,%al
call   1080 <rand@plt>
mov    $0x9,%ecx
cltd
idiv   %ecx
mov    %edx,-0x8(%rbp)
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
movb   $0x20,(%rax,%rcx,1)
mov    $0x0,%al
call   1080 <rand@plt>
mov    $0x9,%ecx
cltd
idiv   %ecx
mov    %edx,-0x8(%rbp)
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
movb   $0x20,(%rax,%rcx,1)
mov    $0x0,%al
call   1080 <rand@plt>
mov    $0x9,%ecx
cltd
idiv   %ecx
mov    %edx,-0x8(%rbp)
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
movb   $0x20,(%rax,%rcx,1)
mov    $0x0,%al
call   1080 <rand@plt>
mov    $0x9,%ecx
cltd
idiv   %ecx
mov    %edx,-0x8(%rbp)
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
movb   $0x20,(%rax,%rcx,1)
mov    $0x0,%al
call   1080 <rand@plt>
mov    $0x9,%ecx
cltd
idiv   %ecx
mov    %edx,-0x8(%rbp)
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
movb   $0x20,(%rax,%rcx,1)
mov    $0x0,%al
call   1080 <rand@plt>
mov    $0x9,%ecx
cltd
idiv   %ecx
mov    %edx,-0x8(%rbp)
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
movb   $0x20,(%rax,%rcx,1)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
cmpl   $0x5,-0xc(%rbp)
jl     121e <geraArquivoeImprimeSudoku+0xbe>
jmp    132c <geraArquivoeImprimeSudoku+0x1cc>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    120f <geraArquivoeImprimeSudoku+0xaf>
lea    0xcf7(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
movl   $0x0,-0x4(%rbp)
cmpl   $0x9,-0x4(%rbp)
jge    13b9 <geraArquivoeImprimeSudoku+0x259>
movl   $0x0,-0x8(%rbp)
cmpl   $0x9,-0x8(%rbp)
jge    139d <geraArquivoeImprimeSudoku+0x23d>
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
movsbl (%rax,%rcx,1),%esi
lea    0xcce(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1360 <geraArquivoeImprimeSudoku+0x200>
lea    0xcc8(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    134f <geraArquivoeImprimeSudoku+0x1ef>
lea    0xc78(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x68(%rbp),%rdi
call   1030 <fclose@plt>
lea    0xc84(%rip),%rdi
lea    0xc88(%rip),%rsi
call   1070 <fopen@plt>
mov    %rax,-0x70(%rbp)
cmpq   $0x0,-0x70(%rbp)
jne    1400 <geraArquivoeImprimeSudoku+0x2a0>
lea    0xc1b(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x70(%rbp),%rdi
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
lea    0xc1a(%rip),%rsi
movsbl (%rax,%rcx,1),%edx
call   1060 <fprintf@plt>
movl   $0x0,-0x4(%rbp)
cmpl   $0x9,-0x4(%rbp)
jge    14cc <geraArquivoeImprimeSudoku+0x36c>
movl   $0x0,-0x8(%rbp)
cmpl   $0x9,-0x8(%rbp)
jge    14b9 <geraArquivoeImprimeSudoku+0x359>
cmpl   $0x8,-0x8(%rbp)
jne    147f <geraArquivoeImprimeSudoku+0x31f>
mov    -0x70(%rbp),%rdi
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
lea    0xbf7(%rip),%rsi
movsbl (%rax,%rcx,1),%edx
call   1060 <fprintf@plt>
jmp    14a6 <geraArquivoeImprimeSudoku+0x346>
mov    -0x70(%rbp),%rdi
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
lea    0xbb9(%rip),%rsi
movsbl (%rax,%rcx,1),%edx
call   1060 <fprintf@plt>
jmp    14ab <geraArquivoeImprimeSudoku+0x34b>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    143f <geraArquivoeImprimeSudoku+0x2df>
jmp    14be <geraArquivoeImprimeSudoku+0x35e>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    142e <geraArquivoeImprimeSudoku+0x2ce>
mov    -0x70(%rbp),%rdi
movslq -0x4(%rbp),%rcx
lea    -0x60(%rbp),%rax
imul   $0x9,%rcx,%rcx
add    %rcx,%rax
movslq -0x8(%rbp),%rcx
lea    0xb4e(%rip),%rsi
movsbl (%rax,%rcx,1),%edx
call   1060 <fprintf@plt>
mov    -0x70(%rbp),%rdi
call   1030 <fclose@plt>
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<geraArquivoeImprimeSudoku>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x60,%rsp
lea    0xe6d(%rip),%rdi
lea    0xe78(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,%r14
test   %rax,%rax
jne    11b3 <geraArquivoeImprimeSudoku+0x33>
lea    0xebc(%rip),%rdi
call   1040 <puts@plt>
xor    %ebp,%ebp
lea    0xe58(%rip),%rbx
nopl   0x0(%rax)
lea    (%rsp,%rbp,1),%rdx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1070 <fscanf@plt>
lea    (%rsp,%rbp,1),%rdx
add    $0x1,%rdx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1070 <fscanf@plt>
lea    (%rsp,%rbp,1),%rdx
add    $0x2,%rdx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1070 <fscanf@plt>
lea    (%rsp,%rbp,1),%rdx
add    $0x3,%rdx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1070 <fscanf@plt>
lea    (%rsp,%rbp,1),%rdx
add    $0x4,%rdx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1070 <fscanf@plt>
lea    (%rsp,%rbp,1),%rdx
add    $0x5,%rdx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1070 <fscanf@plt>
lea    (%rsp,%rbp,1),%rdx
add    $0x6,%rdx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1070 <fscanf@plt>
lea    (%rsp,%rbp,1),%rdx
add    $0x7,%rdx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1070 <fscanf@plt>
lea    (%rsp,%rbp,1),%rdx
add    $0x8,%rdx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1070 <fscanf@plt>
add    $0x9,%rbp
cmp    $0x51,%rbp
jne    11c0 <geraArquivoeImprimeSudoku+0x40>
xor    %r12d,%r12d
xor    %r15d,%r15d
nopl   0x0(%rax,%rax,1)
mov    %r15d,%eax
cmp    $0x5,%r15d
mov    $0x4,%r15d
cmovge %eax,%r15d
add    $0x1,%r15d
mov    %r15d,%ebp
sub    %eax,%ebp
nopw   0x0(%rax,%rax,1)
xor    %eax,%eax
call   10a0 <rand@plt>
cltq
imul   $0x38e38e39,%rax,%rcx
mov    %rcx,%rdx
shr    $0x3f,%rdx
sar    $0x21,%rcx
add    %edx,%ecx
lea    (%rcx,%rcx,8),%ecx
sub    %ecx,%eax
cltq
lea    (%r12,%r12,8),%rcx
lea    (%rsp,%rcx,1),%rbx
movb   $0x20,(%rax,%rbx,1)
xor    %eax,%eax
call   10a0 <rand@plt>
cltq
imul   $0x38e38e39,%rax,%rcx
mov    %rcx,%rdx
shr    $0x3f,%rdx
sar    $0x21,%rcx
add    %edx,%ecx
lea    (%rcx,%rcx,8),%ecx
sub    %ecx,%eax
cltq
movb   $0x20,(%rax,%rbx,1)
xor    %eax,%eax
call   10a0 <rand@plt>
cltq
imul   $0x38e38e39,%rax,%rcx
mov    %rcx,%rdx
shr    $0x3f,%rdx
sar    $0x21,%rcx
add    %edx,%ecx
lea    (%rcx,%rcx,8),%ecx
sub    %ecx,%eax
cltq
movb   $0x20,(%rax,%rbx,1)
xor    %eax,%eax
call   10a0 <rand@plt>
cltq
imul   $0x38e38e39,%rax,%rcx
mov    %rcx,%rdx
shr    $0x3f,%rdx
sar    $0x21,%rcx
add    %edx,%ecx
lea    (%rcx,%rcx,8),%ecx
sub    %ecx,%eax
cltq
movb   $0x20,(%rax,%rbx,1)
xor    %eax,%eax
call   10a0 <rand@plt>
cltq
imul   $0x38e38e39,%rax,%rcx
mov    %rcx,%rdx
shr    $0x3f,%rdx
sar    $0x21,%rcx
add    %edx,%ecx
lea    (%rcx,%rcx,8),%ecx
sub    %ecx,%eax
cltq
movb   $0x20,(%rax,%rbx,1)
xor    %eax,%eax
call   10a0 <rand@plt>
cltq
imul   $0x38e38e39,%rax,%rcx
mov    %rcx,%rdx
shr    $0x3f,%rdx
sar    $0x21,%rcx
add    %edx,%ecx
lea    (%rcx,%rcx,8),%ecx
sub    %ecx,%eax
cltq
movb   $0x20,(%rax,%rbx,1)
add    $0xffffffff,%ebp
jne    12a0 <geraArquivoeImprimeSudoku+0x120>
add    $0x1,%r12
cmp    $0x9,%r12
jne    1280 <geraArquivoeImprimeSudoku+0x100>
lea    0xc97(%rip),%rdi
call   1040 <puts@plt>
mov    $0x8,%ebp
lea    0xc6e(%rip),%rbx
nopw   0x0(%rax,%rax,1)
movsbl -0x8(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
movsbl -0x7(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
movsbl -0x6(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
movsbl -0x5(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
movsbl -0x4(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
movsbl -0x3(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
movsbl -0x2(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
movsbl -0x1(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
movsbl (%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x9,%rbp
cmp    $0x59,%rbp
jne    13d0 <geraArquivoeImprimeSudoku+0x250>
lea    0xbd8(%rip),%rdi
call   1040 <puts@plt>
mov    %r14,%rdi
call   1050 <fclose@plt>
lea    0xbb1(%rip),%rdi
lea    0xbb5(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,%rbx
test   %rax,%rax
jne    14a9 <geraArquivoeImprimeSudoku+0x329>
lea    0xbc6(%rip),%rdi
call   1040 <puts@plt>
movsbl 0x5a(%rsp),%edx
lea    0xb62(%rip),%rsi
mov    %rbx,%rdi
call   1080 <fprintf@plt>
mov    $0x8,%ebp
lea    0xb6c(%rip),%r14
lea    0xb77(%rip),%r15
movsbl -0x8(%rsp,%rbp,1),%edx
mov    %rbx,%rdi
mov    %r14,%rsi
call   1080 <fprintf@plt>
movsbl -0x7(%rsp,%rbp,1),%edx
mov    %rbx,%rdi
mov    %r14,%rsi
call   1080 <fprintf@plt>
movsbl -0x6(%rsp,%rbp,1),%edx
mov    %rbx,%rdi
mov    %r14,%rsi
call   1080 <fprintf@plt>
movsbl -0x5(%rsp,%rbp,1),%edx
mov    %rbx,%rdi
mov    %r14,%rsi
call   1080 <fprintf@plt>
movsbl -0x4(%rsp,%rbp,1),%edx
mov    %rbx,%rdi
mov    %r14,%rsi
call   1080 <fprintf@plt>
movsbl -0x3(%rsp,%rbp,1),%edx
mov    %rbx,%rdi
mov    %r14,%rsi
call   1080 <fprintf@plt>
movsbl -0x2(%rsp,%rbp,1),%edx
mov    %rbx,%rdi
mov    %r14,%rsi
call   1080 <fprintf@plt>
movsbl -0x1(%rsp,%rbp,1),%edx
mov    %rbx,%rdi
mov    %r14,%rsi
call   1080 <fprintf@plt>
movsbl (%rsp,%rbp,1),%edx
mov    %rbx,%rdi
mov    %r15,%rsi
call   1080 <fprintf@plt>
add    $0x9,%rbp
cmp    $0x59,%rbp
jne    14d0 <geraArquivoeImprimeSudoku+0x350>
movsbl 0x5a(%rsp),%edx
lea    0xa9e(%rip),%rsi
mov    %rbx,%rdi
call   1080 <fprintf@plt>
mov    %rbx,%rdi
call   1050 <fclose@plt>
add    $0x60,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [18 x i8] c"sudoku_modelo.txt\00"
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [33 x i8] c"Problemas na CRIACAO do arquivo\0A\00"
@.str.3 = [3 x i8] c"%c\00"
@.str.4 = [30 x i8] c"+--------+--------+--------+\0A\00"
@.str.5 = [5 x i8] c" %c \00"
@.str.6 = [2 x i8] c"\0A\00"
@.str.7 = [11 x i8] c"sudoku.txt\00"
@.str.8 = [2 x i8] c"w\00"
@.str.9 = [6 x i8] c" %c \0A\00"
define void @geraArquivoeImprimeSudoku() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca [9 x [9 x i8]]
%5 = alloca i32*
%6 = alloca i32*
store i32 0, i32* %3
%7 = call i32* @fopen(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %7, i32** %5
%8 = load i32*, i32** %5
%9 = icmp eq i32* %8, null
br i1 %9, label %10, label %12
10: ; preds = %0
%11 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.2, i64 0, i64 0))
br label %12
12: ; preds = %10, %0
store i32 0, i32* %1
br label %13
13: ; preds = %33, %12
%14 = load i32, i32* %1
%15 = icmp slt i32 %14, 9
br i1 %15, label %16, label %36
16: ; preds = %13
store i32 0, i32* %2
br label %17
17: ; preds = %29, %16
%18 = load i32, i32* %2
%19 = icmp slt i32 %18, 9
br i1 %19, label %20, label %32
20: ; preds = %17
%21 = load i32*, i32** %5
%22 = load i32, i32* %1
%23 = sext i32 %22 to i64
%24 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %23
%25 = load i32, i32* %2
%26 = sext i32 %25 to i64
%27 = getelementptr inbounds [9 x i8], [9 x i8]* %24, i64 0, i64 %26
%28 = call i32 @fscanf(i32* %21, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* %27)
br label %29
29: ; preds = %20
%30 = load i32, i32* %2
%31 = add nsw i32 %30, 1
store i32 %31, i32* %2
br label %17
32: ; preds = %17
br label %33
33: ; preds = %32
%34 = load i32, i32* %1
%35 = add nsw i32 %34, 1
store i32 %35, i32* %1
br label %13
36: ; preds = %13
store i32 0, i32* %1
br label %37
37: ; preds = %96, %36
%38 = load i32, i32* %1
%39 = icmp slt i32 %38, 9
br i1 %39, label %40, label %99
40: ; preds = %37
br label %41
41: ; preds = %92, %40
%42 = call i32 (...) @rand()
%43 = srem i32 %42, 9
store i32 %43, i32* %2
%44 = load i32, i32* %1
%45 = sext i32 %44 to i64
%46 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %45
%47 = load i32, i32* %2
%48 = sext i32 %47 to i64
%49 = getelementptr inbounds [9 x i8], [9 x i8]* %46, i64 0, i64 %48
store i8 32, i8* %49
%50 = call i32 (...) @rand()
%51 = srem i32 %50, 9
store i32 %51, i32* %2
%52 = load i32, i32* %1
%53 = sext i32 %52 to i64
%54 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %53
%55 = load i32, i32* %2
%56 = sext i32 %55 to i64
%57 = getelementptr inbounds [9 x i8], [9 x i8]* %54, i64 0, i64 %56
store i8 32, i8* %57
%58 = call i32 (...) @rand()
%59 = srem i32 %58, 9
store i32 %59, i32* %2
%60 = load i32, i32* %1
%61 = sext i32 %60 to i64
%62 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %61
%63 = load i32, i32* %2
%64 = sext i32 %63 to i64
%65 = getelementptr inbounds [9 x i8], [9 x i8]* %62, i64 0, i64 %64
store i8 32, i8* %65
%66 = call i32 (...) @rand()
%67 = srem i32 %66, 9
store i32 %67, i32* %2
%68 = load i32, i32* %1
%69 = sext i32 %68 to i64
%70 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %69
%71 = load i32, i32* %2
%72 = sext i32 %71 to i64
%73 = getelementptr inbounds [9 x i8], [9 x i8]* %70, i64 0, i64 %72
store i8 32, i8* %73
%74 = call i32 (...) @rand()
%75 = srem i32 %74, 9
store i32 %75, i32* %2
%76 = load i32, i32* %1
%77 = sext i32 %76 to i64
%78 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %77
%79 = load i32, i32* %2
%80 = sext i32 %79 to i64
%81 = getelementptr inbounds [9 x i8], [9 x i8]* %78, i64 0, i64 %80
store i8 32, i8* %81
%82 = call i32 (...) @rand()
%83 = srem i32 %82, 9
store i32 %83, i32* %2
%84 = load i32, i32* %1
%85 = sext i32 %84 to i64
%86 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %85
%87 = load i32, i32* %2
%88 = sext i32 %87 to i64
%89 = getelementptr inbounds [9 x i8], [9 x i8]* %86, i64 0, i64 %88
store i8 32, i8* %89
%90 = load i32, i32* %3
%91 = add nsw i32 %90, 1
store i32 %91, i32* %3
br label %92
92: ; preds = %41
%93 = load i32, i32* %3
%94 = icmp slt i32 %93, 5
br i1 %94, label %41, label %95
95: ; preds = %92
br label %96
96: ; preds = %95
%97 = load i32, i32* %1
%98 = add nsw i32 %97, 1
store i32 %98, i32* %1
br label %37
99: ; preds = %37
%100 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.4, i64 0, i64 0))
store i32 0, i32* %1
br label %101
101: ; preds = %123, %99
%102 = load i32, i32* %1
%103 = icmp slt i32 %102, 9
br i1 %103, label %104, label %126
104: ; preds = %101
store i32 0, i32* %2
br label %105
105: ; preds = %118, %104
%106 = load i32, i32* %2
%107 = icmp slt i32 %106, 9
br i1 %107, label %108, label %121
108: ; preds = %105
%109 = load i32, i32* %1
%110 = sext i32 %109 to i64
%111 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %110
%112 = load i32, i32* %2
%113 = sext i32 %112 to i64
%114 = getelementptr inbounds [9 x i8], [9 x i8]* %111, i64 0, i64 %113
%115 = load i8, i8* %114
%116 = sext i8 %115 to i32
%117 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i32 %116)
br label %118
118: ; preds = %108
%119 = load i32, i32* %2
%120 = add nsw i32 %119, 1
store i32 %120, i32* %2
br label %105
121: ; preds = %105
%122 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.6, i64 0, i64 0))
br label %123
123: ; preds = %121
%124 = load i32, i32* %1
%125 = add nsw i32 %124, 1
store i32 %125, i32* %1
br label %101
126: ; preds = %101
%127 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.4, i64 0, i64 0))
%128 = load i32*, i32** %5
%129 = call i32 @fclose(i32* %128)
%130 = call i32* @fopen(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
store i32* %130, i32** %6
%131 = load i32*, i32** %6
%132 = icmp eq i32* %131, null
br i1 %132, label %133, label %135
133: ; preds = %126
%134 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.2, i64 0, i64 0))
br label %135
135: ; preds = %133, %126
%136 = load i32*, i32** %6
%137 = load i32, i32* %1
%138 = sext i32 %137 to i64
%139 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %138
%140 = load i32, i32* %2
%141 = sext i32 %140 to i64
%142 = getelementptr inbounds [9 x i8], [9 x i8]* %139, i64 0, i64 %141
%143 = load i8, i8* %142
%144 = call i32 @fprintf(i32* %136, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.4, i64 0, i64 0), i8 signext %143)
store i32 0, i32* %1
br label %145
145: ; preds = %180, %135
%146 = load i32, i32* %1
%147 = icmp slt i32 %146, 9
br i1 %147, label %148, label %183
148: ; preds = %145
store i32 0, i32* %2
br label %149
149: ; preds = %176, %148
%150 = load i32, i32* %2
%151 = icmp slt i32 %150, 9
br i1 %151, label %152, label %179
152: ; preds = %149
%153 = load i32, i32* %2
%154 = icmp eq i32 %153, 8
br i1 %154, label %155, label %165
155: ; preds = %152
%156 = load i32*, i32** %6
%157 = load i32, i32* %1
%158 = sext i32 %157 to i64
%159 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %158
%160 = load i32, i32* %2
%161 = sext i32 %160 to i64
%162 = getelementptr inbounds [9 x i8], [9 x i8]* %159, i64 0, i64 %161
%163 = load i8, i8* %162
%164 = call i32 @fprintf(i32* %156, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.9, i64 0, i64 0), i8 signext %163)
br label %175
165: ; preds = %152
%166 = load i32*, i32** %6
%167 = load i32, i32* %1
%168 = sext i32 %167 to i64
%169 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %168
%170 = load i32, i32* %2
%171 = sext i32 %170 to i64
%172 = getelementptr inbounds [9 x i8], [9 x i8]* %169, i64 0, i64 %171
%173 = load i8, i8* %172
%174 = call i32 @fprintf(i32* %166, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8 signext %173)
br label %175
175: ; preds = %165, %155
br label %176
176: ; preds = %175
%177 = load i32, i32* %2
%178 = add nsw i32 %177, 1
store i32 %178, i32* %2
br label %149
179: ; preds = %149
br label %180
180: ; preds = %179
%181 = load i32, i32* %1
%182 = add nsw i32 %181, 1
store i32 %182, i32* %1
br label %145
183: ; preds = %145
%184 = load i32*, i32** %6
%185 = load i32, i32* %1
%186 = sext i32 %185 to i64
%187 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %4, i64 0, i64 %186
%188 = load i32, i32* %2
%189 = sext i32 %188 to i64
%190 = getelementptr inbounds [9 x i8], [9 x i8]* %187, i64 0, i64 %189
%191 = load i8, i8* %190
%192 = call i32 @fprintf(i32* %184, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.4, i64 0, i64 0), i8 signext %191)
%193 = load i32*, i32** %6
%194 = call i32 @fclose(i32* %193)
ret void
}

LLVM IR (-O2):
@.str = [18 x i8] c"sudoku_modelo.txt\00"
@.str.1 = [2 x i8] c"r\00"
@.str.3 = [3 x i8] c"%c\00"
@.str.4 = [30 x i8] c"+--------+--------+--------+\0A\00"
@.str.5 = [5 x i8] c" %c \00"
@.str.7 = [11 x i8] c"sudoku.txt\00"
@.str.8 = [2 x i8] c"w\00"
@.str.9 = [6 x i8] c" %c \0A\00"
@str.10 = [29 x i8] c"+--------+--------+--------+\00"
@str.12 = [32 x i8] c"Problemas na CRIACAO do arquivo\00"
define void @geraArquivoeImprimeSudoku() {
%1 = alloca [9 x [9 x i8]]
%2 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 0, i64 0
%3 = tail call i32* @fopen(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%4 = icmp eq i32* %3, null
br i1 %4, label %5, label %7
5: ; preds = %0
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @str.12, i64 0, i64 0))
br label %7
7: ; preds = %5, %0
br label %8
8: ; preds = %7, %8
%9 = phi i64 [ %28, %8 ], [ 0, %7 ]
%10 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %9, i64 0
%11 = call i32 @fscanf(i32* %3, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* %10)
%12 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %9, i64 1
%13 = call i32 @fscanf(i32* %3, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* %12)
%14 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %9, i64 2
%15 = call i32 @fscanf(i32* %3, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* %14)
%16 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %9, i64 3
%17 = call i32 @fscanf(i32* %3, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* %16)
%18 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %9, i64 4
%19 = call i32 @fscanf(i32* %3, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* %18)
%20 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %9, i64 5
%21 = call i32 @fscanf(i32* %3, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* %20)
%22 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %9, i64 6
%23 = call i32 @fscanf(i32* %3, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* %22)
%24 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %9, i64 7
%25 = call i32 @fscanf(i32* %3, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* %24)
%26 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %9, i64 8
%27 = call i32 @fscanf(i32* %3, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8* %26)
%28 = add nuw nsw i64 %9, 1
%29 = icmp eq i64 %28, 9
br i1 %29, label %30, label %8
30: ; preds = %8, %63
%31 = phi i64 [ %64, %63 ], [ 0, %8 ]
%32 = phi i32 [ %34, %63 ], [ 0, %8 ]
%33 = call i32 @llvm.smax.i32(i32 %32, i32 4)
%34 = add nuw i32 %33, 1
br label %35
35: ; preds = %30, %35
%36 = phi i32 [ %61, %35 ], [ %32, %30 ]
%37 = call i32 (...) @rand()
%38 = srem i32 %37, 9
%39 = sext i32 %38 to i64
%40 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %31, i64 %39
store i8 32, i8* %40
%41 = call i32 (...) @rand()
%42 = srem i32 %41, 9
%43 = sext i32 %42 to i64
%44 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %31, i64 %43
store i8 32, i8* %44
%45 = call i32 (...) @rand()
%46 = srem i32 %45, 9
%47 = sext i32 %46 to i64
%48 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %31, i64 %47
store i8 32, i8* %48
%49 = call i32 (...) @rand()
%50 = srem i32 %49, 9
%51 = sext i32 %50 to i64
%52 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %31, i64 %51
store i8 32, i8* %52
%53 = call i32 (...) @rand()
%54 = srem i32 %53, 9
%55 = sext i32 %54 to i64
%56 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %31, i64 %55
store i8 32, i8* %56
%57 = call i32 (...) @rand()
%58 = srem i32 %57, 9
%59 = sext i32 %58 to i64
%60 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %31, i64 %59
store i8 32, i8* %60
%61 = add i32 %36, 1
%62 = icmp eq i32 %36, %33
br i1 %62, label %63, label %35
63: ; preds = %35
%64 = add nuw nsw i64 %31, 1
%65 = icmp eq i64 %64, 9
br i1 %65, label %66, label %30
66: ; preds = %63
%67 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @str.10, i64 0, i64 0))
br label %68
68: ; preds = %66, %68
%69 = phi i64 [ 0, %66 ], [ %107, %68 ]
%70 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %69, i64 0
%71 = load i8, i8* %70
%72 = sext i8 %71 to i32
%73 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i32 %72)
%74 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %69, i64 1
%75 = load i8, i8* %74
%76 = sext i8 %75 to i32
%77 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i32 %76)
%78 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %69, i64 2
%79 = load i8, i8* %78
%80 = sext i8 %79 to i32
%81 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i32 %80)
%82 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %69, i64 3
%83 = load i8, i8* %82
%84 = sext i8 %83 to i32
%85 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i32 %84)
%86 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %69, i64 4
%87 = load i8, i8* %86
%88 = sext i8 %87 to i32
%89 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i32 %88)
%90 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %69, i64 5
%91 = load i8, i8* %90
%92 = sext i8 %91 to i32
%93 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i32 %92)
%94 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %69, i64 6
%95 = load i8, i8* %94
%96 = sext i8 %95 to i32
%97 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i32 %96)
%98 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %69, i64 7
%99 = load i8, i8* %98
%100 = sext i8 %99 to i32
%101 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i32 %100)
%102 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %69, i64 8
%103 = load i8, i8* %102
%104 = sext i8 %103 to i32
%105 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i32 %104)
%106 = call i32 @putchar(i32 10)
%107 = add nuw nsw i64 %69, 1
%108 = icmp eq i64 %107, 9
br i1 %108, label %109, label %68
109: ; preds = %68
%110 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @str.10, i64 0, i64 0))
%111 = call i32 @fclose(i32* %3)
%112 = call i32* @fopen(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
%113 = icmp eq i32* %112, null
br i1 %113, label %114, label %116
114: ; preds = %109
%115 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @str.12, i64 0, i64 0))
br label %116
116: ; preds = %114, %109
%117 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 9, i64 9
%118 = load i8, i8* %117
%119 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.4, i64 0, i64 0), i8 signext %118)
br label %120
120: ; preds = %116, %120
%121 = phi i64 [ 0, %116 ], [ %149, %120 ]
%122 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %121, i64 8
%123 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %121, i64 0
%124 = load i8, i8* %123
%125 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8 signext %124)
%126 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %121, i64 1
%127 = load i8, i8* %126
%128 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8 signext %127)
%129 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %121, i64 2
%130 = load i8, i8* %129
%131 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8 signext %130)
%132 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %121, i64 3
%133 = load i8, i8* %132
%134 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8 signext %133)
%135 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %121, i64 4
%136 = load i8, i8* %135
%137 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8 signext %136)
%138 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %121, i64 5
%139 = load i8, i8* %138
%140 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8 signext %139)
%141 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %121, i64 6
%142 = load i8, i8* %141
%143 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8 signext %142)
%144 = getelementptr inbounds [9 x [9 x i8]], [9 x [9 x i8]]* %1, i64 0, i64 %121, i64 7
%145 = load i8, i8* %144
%146 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8 signext %145)
%147 = load i8, i8* %122
%148 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.9, i64 0, i64 0), i8 signext %147)
%149 = add nuw nsw i64 %121, 1
%150 = icmp eq i64 %149, 9
br i1 %150, label %151, label %120
151: ; preds = %120
%152 = load i8, i8* %117
%153 = call i32 @fprintf(i32* %112, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.4, i64 0, i64 0), i8 signext %152)
%154 = call i32 @fclose(i32* %112)
ret void
}