#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 /*<<< orphan*/ printf(char *, ...);
int counting_sort(int srcdata[], int testdata[], int rtndata[], size_t len) {
  int tempdata[10];
  size_t idx, jdx;
  for (idx = 0; idx < 10; idx++) {
    tempdata[idx] = 0;
  }
  printf("The temp data is:\n");
  for (jdx = 0; jdx < 10; jdx++) {
    tempdata[testdata[jdx]] = tempdata[testdata[jdx]] + 1;
  }
  for (idx = 0; idx < 10; idx++) {
    printf("%zu\t,%d,\n", idx, tempdata[idx]);
  }
  for (idx = 1; idx < 10; idx++) {
    tempdata[idx] = tempdata[idx] + tempdata[idx - 1];
  }
  printf("The temp data is:\n");
  for (idx = 0; idx < 10; idx++) {
    printf("%zu\t,%d,\n", idx, tempdata[idx]);
  }
  for (jdx = 10; jdx >= 1; jdx--) {
    rtndata[tempdata[testdata[jdx - 1]] - 1] = srcdata[jdx - 1];
    tempdata[testdata[jdx - 1]] = tempdata[testdata[jdx - 1]] - 1;
  }
  return 0;
}


x86 assembly (clang, -O0):
<counting_sort>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
movq   $0x0,-0x58(%rbp)
cmpq   $0xa,-0x58(%rbp)
jae    1158 <counting_sort+0x48>
mov    -0x58(%rbp),%rax
movl   $0x0,-0x50(%rbp,%rax,4)
mov    -0x58(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x58(%rbp)
jmp    1130 <counting_sort+0x20>
lea    0xea1(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movq   $0x0,-0x60(%rbp)
cmpq   $0xa,-0x60(%rbp)
jae    11ad <counting_sort+0x9d>
mov    -0x10(%rbp),%rax
mov    -0x60(%rbp),%rcx
movslq (%rax,%rcx,4),%rax
mov    -0x50(%rbp,%rax,4),%ecx
add    $0x1,%ecx
mov    -0x10(%rbp),%rax
mov    -0x60(%rbp),%rdx
movslq (%rax,%rdx,4),%rax
mov    %ecx,-0x50(%rbp,%rax,4)
mov    -0x60(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x60(%rbp)
jmp    116e <counting_sort+0x5e>
movq   $0x0,-0x58(%rbp)
cmpq   $0xa,-0x58(%rbp)
jae    11eb <counting_sort+0xdb>
mov    -0x58(%rbp),%rsi
mov    -0x58(%rbp),%rax
mov    -0x50(%rbp,%rax,4),%edx
lea    0xe40(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x58(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x58(%rbp)
jmp    11b5 <counting_sort+0xa5>
movq   $0x1,-0x58(%rbp)
cmpq   $0xa,-0x58(%rbp)
jae    122b <counting_sort+0x11b>
mov    -0x58(%rbp),%rax
mov    -0x50(%rbp,%rax,4),%ecx
mov    -0x58(%rbp),%rax
sub    $0x1,%rax
add    -0x50(%rbp,%rax,4),%ecx
mov    -0x58(%rbp),%rax
mov    %ecx,-0x50(%rbp,%rax,4)
mov    -0x58(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x58(%rbp)
jmp    11f3 <counting_sort+0xe3>
lea    0xdce(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movq   $0x0,-0x58(%rbp)
cmpq   $0xa,-0x58(%rbp)
jae    1277 <counting_sort+0x167>
mov    -0x58(%rbp),%rsi
mov    -0x58(%rbp),%rax
mov    -0x50(%rbp,%rax,4),%edx
lea    0xdb4(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x58(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x58(%rbp)
jmp    1241 <counting_sort+0x131>
movq   $0xa,-0x60(%rbp)
cmpq   $0x1,-0x60(%rbp)
jb     12f6 <counting_sort+0x1e6>
mov    -0x8(%rbp),%rax
mov    -0x60(%rbp),%rcx
sub    $0x1,%rcx
mov    (%rax,%rcx,4),%edx
mov    -0x18(%rbp),%rax
mov    -0x10(%rbp),%rcx
mov    -0x60(%rbp),%rsi
sub    $0x1,%rsi
movslq (%rcx,%rsi,4),%rcx
mov    -0x50(%rbp,%rcx,4),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
mov    %edx,(%rax,%rcx,4)
mov    -0x10(%rbp),%rax
mov    -0x60(%rbp),%rcx
sub    $0x1,%rcx
movslq (%rax,%rcx,4),%rax
mov    -0x50(%rbp,%rax,4),%ecx
sub    $0x1,%ecx
mov    -0x10(%rbp),%rax
mov    -0x60(%rbp),%rdx
sub    $0x1,%rdx
movslq (%rax,%rdx,4),%rax
mov    %ecx,-0x50(%rbp,%rax,4)
mov    -0x60(%rbp),%rax
add    $0xffffffffffffffff,%rax
mov    %rax,-0x60(%rbp)
jmp    127f <counting_sort+0x16f>
xor    %eax,%eax
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<counting_sort>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x58,%rsp
mov    %rdx,0x50(%rsp)
mov    %rsi,%rbx
mov    %rdi,0x48(%rsp)
xorps  %xmm0,%xmm0
movaps %xmm0,0x10(%rsp)
movaps %xmm0,(%rsp)
movq   $0x0,0x20(%rsp)
lea    0xeb3(%rip),%rdi
call   1030 <puts@plt>
movslq (%rbx),%rax
addl   $0x1,(%rsp,%rax,4)
movslq 0x4(%rbx),%rax
addl   $0x1,(%rsp,%rax,4)
movslq 0x8(%rbx),%rax
addl   $0x1,(%rsp,%rax,4)
movslq 0xc(%rbx),%rax
addl   $0x1,(%rsp,%rax,4)
movslq 0x10(%rbx),%rax
addl   $0x1,(%rsp,%rax,4)
movslq 0x14(%rbx),%rax
addl   $0x1,(%rsp,%rax,4)
movslq 0x18(%rbx),%rax
addl   $0x1,(%rsp,%rax,4)
movslq 0x1c(%rbx),%rax
addl   $0x1,(%rsp,%rax,4)
movslq 0x20(%rbx),%rax
addl   $0x1,(%rsp,%rax,4)
movslq 0x24(%rbx),%rax
addl   $0x1,(%rsp,%rax,4)
mov    (%rsp),%edx
mov    %edx,0x44(%rsp)
lea    0xe47(%rip),%rbp
mov    %rbp,%rdi
xor    %esi,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x4(%rsp),%edx
mov    %edx,0x40(%rsp)
mov    $0x1,%esi
mov    %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x8(%rsp),%edx
mov    %edx,0x3c(%rsp)
mov    $0x2,%esi
mov    %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0xc(%rsp),%edx
mov    %edx,0x38(%rsp)
mov    $0x3,%esi
mov    %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x10(%rsp),%edx
mov    %edx,0x34(%rsp)
mov    $0x4,%esi
mov    %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x14(%rsp),%edx
mov    %edx,0x30(%rsp)
mov    $0x5,%esi
mov    %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x18(%rsp),%r13d
mov    $0x6,%esi
mov    %rbp,%rdi
mov    %r13d,%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x1c(%rsp),%r14d
mov    $0x7,%esi
mov    %rbp,%rdi
mov    %r14d,%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x20(%rsp),%r12d
mov    $0x8,%esi
mov    %rbp,%rdi
mov    %r12d,%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x24(%rsp),%r15d
mov    $0x9,%esi
mov    %rbp,%rdi
mov    %r15d,%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x40(%rsp),%eax
add    0x44(%rsp),%eax
mov    %eax,0x40(%rsp)
mov    %eax,0x4(%rsp)
mov    0x3c(%rsp),%ecx
add    %eax,%ecx
mov    %ecx,0x3c(%rsp)
mov    %ecx,0x8(%rsp)
mov    0x38(%rsp),%eax
add    %ecx,%eax
mov    %eax,0x38(%rsp)
mov    %eax,0xc(%rsp)
mov    0x34(%rsp),%ecx
add    %eax,%ecx
mov    %ecx,0x34(%rsp)
mov    %ecx,0x10(%rsp)
mov    0x30(%rsp),%eax
add    %ecx,%eax
mov    %eax,0x30(%rsp)
mov    %eax,0x14(%rsp)
add    %eax,%r13d
mov    %r13d,0x18(%rsp)
add    %r13d,%r14d
mov    %r14d,0x1c(%rsp)
add    %r14d,%r12d
mov    %r12d,0x20(%rsp)
add    %r12d,%r15d
mov    %r15d,0x24(%rsp)
lea    0xd07(%rip),%rdi
call   1030 <puts@plt>
mov    %rbp,%rdi
xor    %esi,%esi
mov    0x44(%rsp),%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x1,%esi
mov    %rbp,%rdi
mov    0x40(%rsp),%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x2,%esi
mov    %rbp,%rdi
mov    0x3c(%rsp),%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x3,%esi
mov    %rbp,%rdi
mov    0x38(%rsp),%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x4,%esi
mov    %rbp,%rdi
mov    0x34(%rsp),%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x5,%esi
mov    %rbp,%rdi
mov    0x30(%rsp),%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x6,%esi
mov    %rbp,%rdi
mov    %r13d,%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x7,%esi
mov    %rbp,%rdi
mov    %r14d,%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x8,%esi
mov    %rbp,%rdi
mov    %r12d,%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0x9,%esi
mov    %rbp,%rdi
mov    %r15d,%edx
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x48(%rsp),%rsi
mov    0x24(%rsi),%eax
movslq 0x24(%rbx),%rcx
movslq (%rsp,%rcx,4),%rcx
mov    0x50(%rsp),%rdx
mov    %eax,-0x4(%rdx,%rcx,4)
movslq 0x24(%rbx),%rax
addl   $0xffffffff,(%rsp,%rax,4)
mov    0x20(%rsi),%eax
movslq 0x20(%rbx),%rcx
movslq (%rsp,%rcx,4),%rcx
mov    %eax,-0x4(%rdx,%rcx,4)
movslq 0x20(%rbx),%rax
addl   $0xffffffff,(%rsp,%rax,4)
mov    0x1c(%rsi),%eax
movslq 0x1c(%rbx),%rcx
movslq (%rsp,%rcx,4),%rcx
mov    %eax,-0x4(%rdx,%rcx,4)
movslq 0x1c(%rbx),%rax
addl   $0xffffffff,(%rsp,%rax,4)
mov    0x18(%rsi),%eax
movslq 0x18(%rbx),%rcx
movslq (%rsp,%rcx,4),%rcx
mov    %eax,-0x4(%rdx,%rcx,4)
movslq 0x18(%rbx),%rax
addl   $0xffffffff,(%rsp,%rax,4)
mov    0x14(%rsi),%eax
movslq 0x14(%rbx),%rcx
movslq (%rsp,%rcx,4),%rcx
mov    %eax,-0x4(%rdx,%rcx,4)
movslq 0x14(%rbx),%rax
addl   $0xffffffff,(%rsp,%rax,4)
mov    0x10(%rsi),%eax
movslq 0x10(%rbx),%rcx
movslq (%rsp,%rcx,4),%rcx
mov    %eax,-0x4(%rdx,%rcx,4)
movslq 0x10(%rbx),%rax
addl   $0xffffffff,(%rsp,%rax,4)
mov    0xc(%rsi),%eax
movslq 0xc(%rbx),%rcx
movslq (%rsp,%rcx,4),%rcx
mov    %eax,-0x4(%rdx,%rcx,4)
movslq 0xc(%rbx),%rax
addl   $0xffffffff,(%rsp,%rax,4)
mov    0x8(%rsi),%eax
movslq 0x8(%rbx),%rcx
movslq (%rsp,%rcx,4),%rcx
mov    %eax,-0x4(%rdx,%rcx,4)
movslq 0x8(%rbx),%rax
addl   $0xffffffff,(%rsp,%rax,4)
mov    0x4(%rsi),%eax
movslq 0x4(%rbx),%rcx
movslq (%rsp,%rcx,4),%rcx
mov    %eax,-0x4(%rdx,%rcx,4)
movslq 0x4(%rbx),%rax
addl   $0xffffffff,(%rsp,%rax,4)
mov    (%rsi),%eax
movslq (%rbx),%rcx
movslq (%rsp,%rcx,4),%rcx
mov    %eax,-0x4(%rdx,%rcx,4)
xor    %eax,%eax
add    $0x58,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [19 x i8] c"The temp data is:\0A\00"
@.str.1 = [10 x i8] c"%zu\09,%d,\0A\00"
define i32 @counting_sort(i32* %0, i32* %1, i32* %2, i64 %3) {
%5 = alloca i32*
%6 = alloca i32*
%7 = alloca i32*
%8 = alloca i64
%9 = alloca [10 x i32]
%10 = alloca i64
%11 = alloca i64
store i32* %0, i32** %5
store i32* %1, i32** %6
store i32* %2, i32** %7
store i64 %3, i64* %8
store i64 0, i64* %10
br label %12
12: ; preds = %18, %4
%13 = load i64, i64* %10
%14 = icmp ult i64 %13, 10
br i1 %14, label %15, label %21
15: ; preds = %12
%16 = load i64, i64* %10
%17 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %16
store i32 0, i32* %17
br label %18
18: ; preds = %15
%19 = load i64, i64* %10
%20 = add i64 %19, 1
store i64 %20, i64* %10
br label %12
21: ; preds = %12
%22 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0))
store i64 0, i64* %11
br label %23
23: ; preds = %41, %21
%24 = load i64, i64* %11
%25 = icmp ult i64 %24, 10
br i1 %25, label %26, label %44
26: ; preds = %23
%27 = load i32*, i32** %6
%28 = load i64, i64* %11
%29 = getelementptr inbounds i32, i32* %27, i64 %28
%30 = load i32, i32* %29
%31 = sext i32 %30 to i64
%32 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %31
%33 = load i32, i32* %32
%34 = add nsw i32 %33, 1
%35 = load i32*, i32** %6
%36 = load i64, i64* %11
%37 = getelementptr inbounds i32, i32* %35, i64 %36
%38 = load i32, i32* %37
%39 = sext i32 %38 to i64
%40 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %39
store i32 %34, i32* %40
br label %41
41: ; preds = %26
%42 = load i64, i64* %11
%43 = add i64 %42, 1
store i64 %43, i64* %11
br label %23
44: ; preds = %23
store i64 0, i64* %10
br label %45
45: ; preds = %54, %44
%46 = load i64, i64* %10
%47 = icmp ult i64 %46, 10
br i1 %47, label %48, label %57
48: ; preds = %45
%49 = load i64, i64* %10
%50 = load i64, i64* %10
%51 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %50
%52 = load i32, i32* %51
%53 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 %49, i32 %52)
br label %54
54: ; preds = %48
%55 = load i64, i64* %10
%56 = add i64 %55, 1
store i64 %56, i64* %10
br label %45
57: ; preds = %45
store i64 1, i64* %10
br label %58
58: ; preds = %72, %57
%59 = load i64, i64* %10
%60 = icmp ult i64 %59, 10
br i1 %60, label %61, label %75
61: ; preds = %58
%62 = load i64, i64* %10
%63 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %62
%64 = load i32, i32* %63
%65 = load i64, i64* %10
%66 = sub i64 %65, 1
%67 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %66
%68 = load i32, i32* %67
%69 = add nsw i32 %64, %68
%70 = load i64, i64* %10
%71 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %70
store i32 %69, i32* %71
br label %72
72: ; preds = %61
%73 = load i64, i64* %10
%74 = add i64 %73, 1
store i64 %74, i64* %10
br label %58
75: ; preds = %58
%76 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0))
store i64 0, i64* %10
br label %77
77: ; preds = %86, %75
%78 = load i64, i64* %10
%79 = icmp ult i64 %78, 10
br i1 %79, label %80, label %89
80: ; preds = %77
%81 = load i64, i64* %10
%82 = load i64, i64* %10
%83 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %82
%84 = load i32, i32* %83
%85 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 %81, i32 %84)
br label %86
86: ; preds = %80
%87 = load i64, i64* %10
%88 = add i64 %87, 1
store i64 %88, i64* %10
br label %77
89: ; preds = %77
store i64 10, i64* %11
br label %90
90: ; preds = %127, %89
%91 = load i64, i64* %11
%92 = icmp uge i64 %91, 1
br i1 %92, label %93, label %130
93: ; preds = %90
%94 = load i32*, i32** %5
%95 = load i64, i64* %11
%96 = sub i64 %95, 1
%97 = getelementptr inbounds i32, i32* %94, i64 %96
%98 = load i32, i32* %97
%99 = load i32*, i32** %7
%100 = load i32*, i32** %6
%101 = load i64, i64* %11
%102 = sub i64 %101, 1
%103 = getelementptr inbounds i32, i32* %100, i64 %102
%104 = load i32, i32* %103
%105 = sext i32 %104 to i64
%106 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %105
%107 = load i32, i32* %106
%108 = sub nsw i32 %107, 1
%109 = sext i32 %108 to i64
%110 = getelementptr inbounds i32, i32* %99, i64 %109
store i32 %98, i32* %110
%111 = load i32*, i32** %6
%112 = load i64, i64* %11
%113 = sub i64 %112, 1
%114 = getelementptr inbounds i32, i32* %111, i64 %113
%115 = load i32, i32* %114
%116 = sext i32 %115 to i64
%117 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %116
%118 = load i32, i32* %117
%119 = sub nsw i32 %118, 1
%120 = load i32*, i32** %6
%121 = load i64, i64* %11
%122 = sub i64 %121, 1
%123 = getelementptr inbounds i32, i32* %120, i64 %122
%124 = load i32, i32* %123
%125 = sext i32 %124 to i64
%126 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 %125
store i32 %119, i32* %126
br label %127
127: ; preds = %93
%128 = load i64, i64* %11
%129 = add i64 %128, -1
store i64 %129, i64* %11
br label %90
130: ; preds = %90
ret i32 0
}

LLVM IR (-O2):
@.str.1 = [10 x i8] c"%zu\09,%d,\0A\00"
@str.2 = [18 x i8] c"The temp data is:\00"
define i32 @counting_sort(i32* nocapture %0, i32* nocapture %1, i32* nocapture writeonly %2, i64 %3) {
%5 = alloca [10 x i32]
%6 = bitcast [10 x i32]* %5 to i8*
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @str.2, i64 0, i64 0))
%8 = load i32, i32* %1
%9 = sext i32 %8 to i64
%10 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %9
%11 = load i32, i32* %10
%12 = add nsw i32 %11, 1
store i32 %12, i32* %10
%13 = getelementptr inbounds i32, i32* %1, i64 1
%14 = load i32, i32* %13
%15 = sext i32 %14 to i64
%16 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %15
%17 = load i32, i32* %16
%18 = add nsw i32 %17, 1
store i32 %18, i32* %16
%19 = getelementptr inbounds i32, i32* %1, i64 2
%20 = load i32, i32* %19
%21 = sext i32 %20 to i64
%22 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %21
%23 = load i32, i32* %22
%24 = add nsw i32 %23, 1
store i32 %24, i32* %22
%25 = getelementptr inbounds i32, i32* %1, i64 3
%26 = load i32, i32* %25
%27 = sext i32 %26 to i64
%28 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %27
%29 = load i32, i32* %28
%30 = add nsw i32 %29, 1
store i32 %30, i32* %28
%31 = getelementptr inbounds i32, i32* %1, i64 4
%32 = load i32, i32* %31
%33 = sext i32 %32 to i64
%34 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %33
%35 = load i32, i32* %34
%36 = add nsw i32 %35, 1
store i32 %36, i32* %34
%37 = getelementptr inbounds i32, i32* %1, i64 5
%38 = load i32, i32* %37
%39 = sext i32 %38 to i64
%40 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %39
%41 = load i32, i32* %40
%42 = add nsw i32 %41, 1
store i32 %42, i32* %40
%43 = getelementptr inbounds i32, i32* %1, i64 6
%44 = load i32, i32* %43
%45 = sext i32 %44 to i64
%46 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %45
%47 = load i32, i32* %46
%48 = add nsw i32 %47, 1
store i32 %48, i32* %46
%49 = getelementptr inbounds i32, i32* %1, i64 7
%50 = load i32, i32* %49
%51 = sext i32 %50 to i64
%52 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %51
%53 = load i32, i32* %52
%54 = add nsw i32 %53, 1
store i32 %54, i32* %52
%55 = getelementptr inbounds i32, i32* %1, i64 8
%56 = load i32, i32* %55
%57 = sext i32 %56 to i64
%58 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %57
%59 = load i32, i32* %58
%60 = add nsw i32 %59, 1
store i32 %60, i32* %58
%61 = getelementptr inbounds i32, i32* %1, i64 9
%62 = load i32, i32* %61
%63 = sext i32 %62 to i64
%64 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %63
%65 = load i32, i32* %64
%66 = add nsw i32 %65, 1
store i32 %66, i32* %64
%67 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 0
%68 = load i32, i32* %67
%69 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 0, i32 %68)
%70 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 1
%71 = load i32, i32* %70
%72 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 1, i32 %71)
%73 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 2
%74 = load i32, i32* %73
%75 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 2, i32 %74)
%76 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 3
%77 = load i32, i32* %76
%78 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 3, i32 %77)
%79 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 4
%80 = load i32, i32* %79
%81 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 4, i32 %80)
%82 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 5
%83 = load i32, i32* %82
%84 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 5, i32 %83)
%85 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 6
%86 = load i32, i32* %85
%87 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 6, i32 %86)
%88 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 7
%89 = load i32, i32* %88
%90 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 7, i32 %89)
%91 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 8
%92 = load i32, i32* %91
%93 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 8, i32 %92)
%94 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 9
%95 = load i32, i32* %94
%96 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 9, i32 %95)
%97 = add nsw i32 %68, %71
store i32 %97, i32* %70
%98 = add nsw i32 %97, %74
store i32 %98, i32* %73
%99 = add nsw i32 %98, %77
store i32 %99, i32* %76
%100 = add nsw i32 %99, %80
store i32 %100, i32* %79
%101 = add nsw i32 %100, %83
store i32 %101, i32* %82
%102 = add nsw i32 %101, %86
store i32 %102, i32* %85
%103 = add nsw i32 %102, %89
store i32 %103, i32* %88
%104 = add nsw i32 %103, %92
store i32 %104, i32* %91
%105 = add nsw i32 %104, %95
store i32 %105, i32* %94
%106 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @str.2, i64 0, i64 0))
%107 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 0, i32 %68)
%108 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 1, i32 %97)
%109 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 2, i32 %98)
%110 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 3, i32 %99)
%111 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 4, i32 %100)
%112 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 5, i32 %101)
%113 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 6, i32 %102)
%114 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 7, i32 %103)
%115 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 8, i32 %104)
%116 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i64 9, i32 %105)
%117 = getelementptr inbounds i32, i32* %0, i64 9
%118 = load i32, i32* %117
%119 = load i32, i32* %61
%120 = sext i32 %119 to i64
%121 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %120
%122 = load i32, i32* %121
%123 = add nsw i32 %122, -1
%124 = sext i32 %123 to i64
%125 = getelementptr inbounds i32, i32* %2, i64 %124
store i32 %118, i32* %125
%126 = load i32, i32* %61
%127 = sext i32 %126 to i64
%128 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %127
%129 = load i32, i32* %128
%130 = add nsw i32 %129, -1
store i32 %130, i32* %128
%131 = getelementptr inbounds i32, i32* %0, i64 8
%132 = load i32, i32* %131
%133 = load i32, i32* %55
%134 = sext i32 %133 to i64
%135 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %134
%136 = load i32, i32* %135
%137 = add nsw i32 %136, -1
%138 = sext i32 %137 to i64
%139 = getelementptr inbounds i32, i32* %2, i64 %138
store i32 %132, i32* %139
%140 = load i32, i32* %55
%141 = sext i32 %140 to i64
%142 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %141
%143 = load i32, i32* %142
%144 = add nsw i32 %143, -1
store i32 %144, i32* %142
%145 = getelementptr inbounds i32, i32* %0, i64 7
%146 = load i32, i32* %145
%147 = load i32, i32* %49
%148 = sext i32 %147 to i64
%149 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %148
%150 = load i32, i32* %149
%151 = add nsw i32 %150, -1
%152 = sext i32 %151 to i64
%153 = getelementptr inbounds i32, i32* %2, i64 %152
store i32 %146, i32* %153
%154 = load i32, i32* %49
%155 = sext i32 %154 to i64
%156 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %155
%157 = load i32, i32* %156
%158 = add nsw i32 %157, -1
store i32 %158, i32* %156
%159 = getelementptr inbounds i32, i32* %0, i64 6
%160 = load i32, i32* %159
%161 = load i32, i32* %43
%162 = sext i32 %161 to i64
%163 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %162
%164 = load i32, i32* %163
%165 = add nsw i32 %164, -1
%166 = sext i32 %165 to i64
%167 = getelementptr inbounds i32, i32* %2, i64 %166
store i32 %160, i32* %167
%168 = load i32, i32* %43
%169 = sext i32 %168 to i64
%170 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %169
%171 = load i32, i32* %170
%172 = add nsw i32 %171, -1
store i32 %172, i32* %170
%173 = getelementptr inbounds i32, i32* %0, i64 5
%174 = load i32, i32* %173
%175 = load i32, i32* %37
%176 = sext i32 %175 to i64
%177 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %176
%178 = load i32, i32* %177
%179 = add nsw i32 %178, -1
%180 = sext i32 %179 to i64
%181 = getelementptr inbounds i32, i32* %2, i64 %180
store i32 %174, i32* %181
%182 = load i32, i32* %37
%183 = sext i32 %182 to i64
%184 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %183
%185 = load i32, i32* %184
%186 = add nsw i32 %185, -1
store i32 %186, i32* %184
%187 = getelementptr inbounds i32, i32* %0, i64 4
%188 = load i32, i32* %187
%189 = load i32, i32* %31
%190 = sext i32 %189 to i64
%191 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %190
%192 = load i32, i32* %191
%193 = add nsw i32 %192, -1
%194 = sext i32 %193 to i64
%195 = getelementptr inbounds i32, i32* %2, i64 %194
store i32 %188, i32* %195
%196 = load i32, i32* %31
%197 = sext i32 %196 to i64
%198 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %197
%199 = load i32, i32* %198
%200 = add nsw i32 %199, -1
store i32 %200, i32* %198
%201 = getelementptr inbounds i32, i32* %0, i64 3
%202 = load i32, i32* %201
%203 = load i32, i32* %25
%204 = sext i32 %203 to i64
%205 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %204
%206 = load i32, i32* %205
%207 = add nsw i32 %206, -1
%208 = sext i32 %207 to i64
%209 = getelementptr inbounds i32, i32* %2, i64 %208
store i32 %202, i32* %209
%210 = load i32, i32* %25
%211 = sext i32 %210 to i64
%212 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %211
%213 = load i32, i32* %212
%214 = add nsw i32 %213, -1
store i32 %214, i32* %212
%215 = getelementptr inbounds i32, i32* %0, i64 2
%216 = load i32, i32* %215
%217 = load i32, i32* %19
%218 = sext i32 %217 to i64
%219 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %218
%220 = load i32, i32* %219
%221 = add nsw i32 %220, -1
%222 = sext i32 %221 to i64
%223 = getelementptr inbounds i32, i32* %2, i64 %222
store i32 %216, i32* %223
%224 = load i32, i32* %19
%225 = sext i32 %224 to i64
%226 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %225
%227 = load i32, i32* %226
%228 = add nsw i32 %227, -1
store i32 %228, i32* %226
%229 = getelementptr inbounds i32, i32* %0, i64 1
%230 = load i32, i32* %229
%231 = load i32, i32* %13
%232 = sext i32 %231 to i64
%233 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %232
%234 = load i32, i32* %233
%235 = add nsw i32 %234, -1
%236 = sext i32 %235 to i64
%237 = getelementptr inbounds i32, i32* %2, i64 %236
store i32 %230, i32* %237
%238 = load i32, i32* %13
%239 = sext i32 %238 to i64
%240 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %239
%241 = load i32, i32* %240
%242 = add nsw i32 %241, -1
store i32 %242, i32* %240
%243 = load i32, i32* %0
%244 = load i32, i32* %1
%245 = sext i32 %244 to i64
%246 = getelementptr inbounds [10 x i32], [10 x i32]* %5, i64 0, i64 %245
%247 = load i32, i32* %246
%248 = add nsw i32 %247, -1
%249 = sext i32 %248 to i64
%250 = getelementptr inbounds i32, i32* %2, i64 %249
store i32 %243, i32* %250
ret i32 0
}