#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 uint;

/* Variables and functions */
int /*<<< orphan*/ dodiv2m1(int /*<<< orphan*/, int);
int /*<<< orphan*/ dodiv2p1(int /*<<< orphan*/, int);
int /*<<< orphan*/ fputs(char *, int /*<<< orphan*/);
int /*<<< orphan*/ loada4(int, int, int);
int log2uni(int);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ stderr;
void divideby2(uint type, uint n, uint lsb, uint msb) {
  uint loglsb;
  uint logmsb;
  uint usinga4;
  loglsb = log2uni(lsb);
  logmsb = log2uni(msb);
  printf("; %s [%s]\n\n", "generated by divc 1.02 (Advanced RISC Machines)",
         "27 Jan 94");
  printf("\tAREA |div%d$code|, CODE, READONLY\n\n", n);
  printf("\tEXPORT udiv%d\n\n", n);
  printf("udiv%d\n", n);
  printf("; takes argument in a1\n");
  printf("; returns quotient in a1, remainder in a2\n");
  printf("; cycles could be saved if only divide or remainder is required\n");
  usinga4 = (n >> loglsb) > 255;
  if (usinga4) {
    loada4(type, lsb, msb);
    printf("\tSUB     a2, a1, a4\n");
  } else {
    printf("\tSUB     a2, a1, #%d\n", n);
  }
  switch (type) {
  case 0:
    dodiv2m1(logmsb - loglsb, logmsb);
    printf("\tRSB     a3, a1, a1, asl #%d\n", logmsb - loglsb);
    break;
  case 1:
    dodiv2p1(logmsb - loglsb, logmsb);
    printf("\tADD     a3, a1, a1, asl #%d\n", logmsb - loglsb);
    break;
  default:
    fputs("Internal error", stderr);
  }
  printf("\tSUBS    a2, a2, a3, asl #%d\n", loglsb);
  printf("\tADDPL   a1, a1, #1\n");
  if (usinga4) {
    printf("\tADDMI   a2, a2, a4\n");
  } else {
    printf("\tADDMI   a2, a2, #%d\n", n);
  }
  if (n == 3) {
    printf("\tCMP     a2, #3\n");
    printf("\tADDGE   a1, a1, #1\n");
    printf("\tSUBGE   a2, a2, #3\n");
  }
  printf("\tMOV     pc, lr\n\n");
  printf("\tEND\n");
}


x86 assembly (clang, -O0):
<divideby2>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    -0xc(%rbp),%edi
call   1060 <log2uni@plt>
mov    %eax,-0x14(%rbp)
mov    -0x10(%rbp),%edi
call   1060 <log2uni@plt>
mov    %eax,-0x18(%rbp)
lea    0xe6f(%rip),%rdi
lea    0xe74(%rip),%rsi
lea    0xe9d(%rip),%rdx
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%esi
lea    0xe96(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%esi
lea    0xeaa(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%esi
lea    0xeaa(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xea4(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xeae(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xecb(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%eax
mov    -0x14(%rbp),%ecx
sar    %cl,%eax
cmp    $0xff,%eax
setg   %al
and    $0x1,%al
movzbl %al,%eax
mov    %eax,-0x1c(%rbp)
cmpl   $0x0,-0x1c(%rbp)
je     1246 <divideby2+0xe6>
mov    -0x4(%rbp),%edi
mov    -0xc(%rbp),%esi
mov    -0x10(%rbp),%edx
call   1030 <loada4@plt>
lea    0xece(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1257 <divideby2+0xf7>
mov    -0x8(%rbp),%esi
lea    0xecd(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x4(%rbp),%eax
mov    %eax,-0x20(%rbp)
test   %eax,%eax
je     127b <divideby2+0x11b>
jmp    126a <divideby2+0x10a>
mov    -0x20(%rbp),%eax
sub    $0x1,%eax
je     12a2 <divideby2+0x142>
jmp    12c9 <divideby2+0x169>
mov    -0x18(%rbp),%edi
sub    -0x14(%rbp),%edi
mov    -0x18(%rbp),%esi
call   1080 <dodiv2m1@plt>
mov    -0x18(%rbp),%esi
sub    -0x14(%rbp),%esi
lea    0xe9d(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    12de <divideby2+0x17e>
mov    -0x18(%rbp),%edi
sub    -0x14(%rbp),%edi
mov    -0x18(%rbp),%esi
call   1070 <dodiv2p1@plt>
mov    -0x18(%rbp),%esi
sub    -0x14(%rbp),%esi
lea    0xe94(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    12de <divideby2+0x17e>
mov    0x2d10(%rip),%rax
mov    (%rax),%esi
lea    0xe96(%rip),%rdi
call   1050 <fputs@plt>
mov    -0x14(%rbp),%esi
lea    0xe96(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xea6(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
cmpl   $0x0,-0x1c(%rbp)
je     131a <divideby2+0x1ba>
lea    0xea3(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    132b <divideby2+0x1cb>
mov    -0x8(%rbp),%esi
lea    0xea2(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
cmpl   $0x3,-0x8(%rbp)
jne    135f <divideby2+0x1ff>
lea    0xea0(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xea3(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xeaa(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xeb1(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xeb5(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<divideby2>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %ecx,%r12d
mov    %edx,%r13d
mov    %esi,%r14d
mov    %edi,%ebp
mov    %edx,%edi
call   1070 <log2uni@plt>
mov    %eax,%r15d
mov    %r12d,%edi
call   1070 <log2uni@plt>
mov    %eax,0x4(%rsp)
lea    0xe5d(%rip),%rdi
lea    0xe62(%rip),%rsi
lea    0xe8b(%rip),%rdx
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xe87(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xe9b(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xe9b(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xf27(%rip),%rdi
call   1040 <puts@plt>
lea    0xf32(%rip),%rdi
call   1040 <puts@plt>
lea    0xf50(%rip),%rdi
call   1040 <puts@plt>
mov    %r14d,%ebx
mov    %r15d,%ecx
sar    %cl,%ebx
cmp    $0x100,%ebx
jl     125a <divideby2+0xea>
mov    %ebp,%edi
mov    %r13d,%esi
mov    %r12d,%edx
call   1030 <loada4@plt>
lea    0xfdd(%rip),%rdi
call   1040 <puts@plt>
cmp    $0x1,%ebp
je     1270 <divideby2+0x100>
test   %ebp,%ebp
jne    1292 <divideby2+0x122>
mov    0x4(%rsp),%esi
mov    %esi,%ebp
sub    %r15d,%ebp
mov    %ebp,%edi
call   1090 <dodiv2m1@plt>
lea    0xe42(%rip),%rdi
jmp    1287 <divideby2+0x117>
lea    0xe23(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1050 <printf@plt>
cmp    $0x1,%ebp
jne    123d <divideby2+0xcd>
mov    0x4(%rsp),%esi
mov    %esi,%ebp
sub    %r15d,%ebp
mov    %ebp,%edi
call   1080 <dodiv2p1@plt>
lea    0xe31(%rip),%rdi
mov    %ebp,%esi
xor    %eax,%eax
call   1050 <printf@plt>
jmp    12a7 <divideby2+0x137>
mov    0x2d47(%rip),%rax
mov    (%rax),%esi
lea    0xe34(%rip),%rdi
call   1060 <fputs@plt>
lea    0xe37(%rip),%rdi
mov    %r15d,%esi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xedb(%rip),%rdi
call   1040 <puts@plt>
cmp    $0x100,%ebx
jl     12e0 <divideby2+0x170>
lea    0xf29(%rip),%rdi
call   1040 <puts@plt>
cmp    $0x3,%r14d
je     12f7 <divideby2+0x187>
jmp    131b <divideby2+0x1ab>
lea    0xe1c(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1050 <printf@plt>
cmp    $0x3,%r14d
jne    131b <divideby2+0x1ab>
lea    0xec6(%rip),%rdi
call   1040 <puts@plt>
lea    0xeca(%rip),%rdi
call   1040 <puts@plt>
lea    0xed2(%rip),%rdi
call   1040 <puts@plt>
lea    0xe8c(%rip),%rdi
call   1040 <puts@plt>
lea    0xe91(%rip),%rdi
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1040 <puts@plt>

LLVM IR (-O0):
@.str = [12 x i8] c"; %s [%s]\0A\0A\00"
@.str.1 = [48 x i8] c"generated by divc 1.02 (Advanced RISC Machines)\00"
@.str.2 = [10 x i8] c"27 Jan 94\00"
@.str.3 = [37 x i8] c"\09AREA |div%d$code|, CODE, READONLY\0A\0A\00"
@.str.4 = [17 x i8] c"\09EXPORT udiv%d\0A\0A\00"
@.str.5 = [8 x i8] c"udiv%d\0A\00"
@.str.6 = [24 x i8] c"; takes argument in a1\0A\00"
@.str.7 = [43 x i8] c"; returns quotient in a1, remainder in a2\0A\00"
@.str.8 = [65 x i8] c"; cycles could be saved if only divide or remainder is required\0A\00"
@.str.9 = [21 x i8] c"\09SUB a2, a1, a4\0A\00"
@.str.10 = [22 x i8] c"\09SUB a2, a1, #%d\0A\00"
@.str.11 = [30 x i8] c"\09RSB a3, a1, a1, asl #%d\0A\00"
@.str.12 = [30 x i8] c"\09ADD a3, a1, a1, asl #%d\0A\00"
@.str.13 = [15 x i8] c"Internal error\00"
@stderr = global i32 0
@.str.14 = [30 x i8] c"\09SUBS a2, a2, a3, asl #%d\0A\00"
@.str.15 = [21 x i8] c"\09ADDPL a1, a1,\0A\00"
@.str.16 = [21 x i8] c"\09ADDMI a2, a2, a4\0A\00"
@.str.17 = [22 x i8] c"\09ADDMI a2, a2, #%d\0A\00"
@.str.18 = [17 x i8] c"\09CMP a2,\0A\00"
@.str.19 = [21 x i8] c"\09ADDGE a1, a1,\0A\00"
@.str.20 = [21 x i8] c"\09SUBGE a2, a2,\0A\00"
@.str.21 = [18 x i8] c"\09MOV pc, lr\0A\0A\00"
@.str.22 = [6 x i8] c"\09END\0A\00"
define void @divideby2(i32 %0, i32 %1, i32 %2, i32 %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
store i32 %0, i32* %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i32 %3, i32* %8
%12 = load i32, i32* %7
%13 = call i32 @log2uni(i32 %12)
store i32 %13, i32* %9
%14 = load i32, i32* %8
%15 = call i32 @log2uni(i32 %14)
store i32 %15, i32* %10
%16 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.2, i64 0, i64 0))
%17 = load i32, i32* %6
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.3, i64 0, i64 0), i32 %17)
%19 = load i32, i32* %6
%20 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.4, i64 0, i64 0), i32 %19)
%21 = load i32, i32* %6
%22 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.5, i64 0, i64 0), i32 %21)
%23 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.6, i64 0, i64 0))
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.7, i64 0, i64 0))
%25 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str.8, i64 0, i64 0))
%26 = load i32, i32* %6
%27 = load i32, i32* %9
%28 = ashr i32 %26, %27
%29 = icmp sgt i32 %28, 255
%30 = zext i1 %29 to i32
store i32 %30, i32* %11
%31 = load i32, i32* %11
%32 = icmp ne i32 %31, 0
br i1 %32, label %33, label %39
33: ; preds = %4
%34 = load i32, i32* %5
%35 = load i32, i32* %7
%36 = load i32, i32* %8
%37 = call i32 @loada4(i32 %34, i32 %35, i32 %36)
%38 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.9, i64 0, i64 0))
br label %42
39: ; preds = %4
%40 = load i32, i32* %6
%41 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.10, i64 0, i64 0), i32 %40)
br label %42
42: ; preds = %39, %33
%43 = load i32, i32* %5
switch i32 %43, label %64 [
i32 0, label %44
i32 1, label %54
]
44: ; preds = %42
%45 = load i32, i32* %10
%46 = load i32, i32* %9
%47 = sub nsw i32 %45, %46
%48 = load i32, i32* %10
%49 = call i32 @dodiv2m1(i32 %47, i32 %48)
%50 = load i32, i32* %10
%51 = load i32, i32* %9
%52 = sub nsw i32 %50, %51
%53 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.11, i64 0, i64 0), i32 %52)
br label %67
54: ; preds = %42
%55 = load i32, i32* %10
%56 = load i32, i32* %9
%57 = sub nsw i32 %55, %56
%58 = load i32, i32* %10
%59 = call i32 @dodiv2p1(i32 %57, i32 %58)
%60 = load i32, i32* %10
%61 = load i32, i32* %9
%62 = sub nsw i32 %60, %61
%63 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.12, i64 0, i64 0), i32 %62)
br label %67
64: ; preds = %42
%65 = load i32, i32* @stderr
%66 = call i32 @fputs(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.13, i64 0, i64 0), i32 %65)
br label %67
67: ; preds = %64, %54, %44
%68 = load i32, i32* %9
%69 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.14, i64 0, i64 0), i32 %68)
%70 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.15, i64 0, i64 0))
%71 = load i32, i32* %11
%72 = icmp ne i32 %71, 0
br i1 %72, label %73, label %75
73: ; preds = %67
%74 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.16, i64 0, i64 0))
br label %78
75: ; preds = %67
%76 = load i32, i32* %6
%77 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.17, i64 0, i64 0), i32 %76)
br label %78
78: ; preds = %75, %73
%79 = load i32, i32* %6
%80 = icmp eq i32 %79, 3
br i1 %80, label %81, label %85
81: ; preds = %78
%82 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.18, i64 0, i64 0))
%83 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.19, i64 0, i64 0))
%84 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.20, i64 0, i64 0))
br label %85
85: ; preds = %81, %78
%86 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.21, i64 0, i64 0))
%87 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.22, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [12 x i8] c"; %s [%s]\0A\0A\00"
@.str.1 = [48 x i8] c"generated by divc 1.02 (Advanced RISC Machines)\00"
@.str.2 = [10 x i8] c"27 Jan 94\00"
@.str.3 = [37 x i8] c"\09AREA |div%d$code|, CODE, READONLY\0A\0A\00"
@.str.4 = [17 x i8] c"\09EXPORT udiv%d\0A\0A\00"
@.str.5 = [8 x i8] c"udiv%d\0A\00"
@.str.10 = [22 x i8] c"\09SUB a2, a1, #%d\0A\00"
@.str.11 = [30 x i8] c"\09RSB a3, a1, a1, asl #%d\0A\00"
@.str.12 = [30 x i8] c"\09ADD a3, a1, a1, asl #%d\0A\00"
@.str.13 = [15 x i8] c"Internal error\00"
@stderr = global i32 0
@.str.14 = [30 x i8] c"\09SUBS a2, a2, a3, asl #%d\0A\00"
@.str.17 = [22 x i8] c"\09ADDMI a2, a2, #%d\0A\00"
@str = [23 x i8] c"; takes argument in a1\00"
@str.23 = [42 x i8] c"; returns quotient in a1, remainder in a2\00"
@str.24 = [64 x i8] c"; cycles could be saved if only divide or remainder is required\00"
@str.25 = [20 x i8] c"\09ADDPL a1, a1,\00"
@str.26 = [17 x i8] c"\09MOV pc, lr\0A\00"
@str.27 = [5 x i8] c"\09END\00"
@str.28 = [16 x i8] c"\09CMP a2,\00"
@str.29 = [20 x i8] c"\09ADDGE a1, a1,\00"
@str.30 = [20 x i8] c"\09SUBGE a2, a2,\00"
@str.31 = [20 x i8] c"\09ADDMI a2, a2, a4\00"
@str.32 = [20 x i8] c"\09SUB a2, a1, a4\00"
define void @divideby2(i32 %0, i32 %1, i32 %2, i32 %3) {
%5 = tail call i32 @log2uni(i32 %2)
%6 = tail call i32 @log2uni(i32 %3)
%7 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.2, i64 0, i64 0))
%8 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @.str.3, i64 0, i64 0), i32 %1)
%9 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str.4, i64 0, i64 0), i32 %1)
%10 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @.str.5, i64 0, i64 0), i32 %1)
%11 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @str, i64 0, i64 0))
%12 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([42 x i8], [42 x i8]* @str.23, i64 0, i64 0))
%13 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([64 x i8], [64 x i8]* @str.24, i64 0, i64 0))
%14 = ashr i32 %1, %5
%15 = icmp sgt i32 %14, 255
br i1 %15, label %16, label %19
16: ; preds = %4
%17 = tail call i32 @loada4(i32 %0, i32 %2, i32 %3)
%18 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @str.32, i64 0, i64 0))
br label %21
19: ; preds = %4
%20 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.10, i64 0, i64 0), i32 %1)
br label %21
21: ; preds = %19, %16
switch i32 %0, label %30 [
i32 0, label %22
i32 1, label %26
]
22: ; preds = %21
%23 = sub nsw i32 %6, %5
%24 = tail call i32 @dodiv2m1(i32 %23, i32 %6)
%25 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([30 x i8], [30 x i8]* @.str.11, i64 0, i64 0), i32 %23)
br label %33
26: ; preds = %21
%27 = sub nsw i32 %6, %5
%28 = tail call i32 @dodiv2p1(i32 %27, i32 %6)
%29 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([30 x i8], [30 x i8]* @.str.12, i64 0, i64 0), i32 %27)
br label %33
30: ; preds = %21
%31 = load i32, i32* @stderr
%32 = tail call i32 @fputs(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.13, i64 0, i64 0), i32 %31)
br label %33
33: ; preds = %30, %26, %22
%34 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([30 x i8], [30 x i8]* @.str.14, i64 0, i64 0), i32 %5)
%35 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @str.25, i64 0, i64 0))
br i1 %15, label %36, label %38
36: ; preds = %33
%37 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @str.31, i64 0, i64 0))
br label %40
38: ; preds = %33
%39 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.17, i64 0, i64 0), i32 %1)
br label %40
40: ; preds = %38, %36
%41 = icmp eq i32 %1, 3
br i1 %41, label %42, label %46
42: ; preds = %40
%43 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @str.28, i64 0, i64 0))
%44 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @str.29, i64 0, i64 0))
%45 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @str.30, i64 0, i64 0))
br label %46
46: ; preds = %42, %40
%47 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @str.26, i64 0, i64 0))
%48 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @str.27, i64 0, i64 0))
ret void
}