#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*/ val;

/* Variables and functions */
int ccnl_ccnb_mkHeader(unsigned char *, int, int);
int ccnl_ccnb_mkBinaryInt(unsigned char *out, unsigned int num, unsigned int tt,
                          unsigned int val, int bytes) {
  int len = ccnl_ccnb_mkHeader(out, num, tt);
  if (!bytes) {
    for (bytes = sizeof(val) - 1; bytes > 0; bytes--)
      if (val >> (8 * bytes))
        break;
    bytes++;
  }
  len += ccnl_ccnb_mkHeader(out + len, bytes, 5);
  while (bytes > 0) {
    bytes--;
    out[len++] = 0x0ff & (val >> (8 * bytes));
  }
  out[len++] = 0;
  return len;
}


x86 assembly (clang, -O0):
<ccnl_ccnb_mkBinaryInt>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    %ecx,-0x14(%rbp)
mov    %r8d,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
mov    -0x10(%rbp),%edx
call   1030 <ccnl_ccnb_mkHeader@plt>
mov    %eax,-0x1c(%rbp)
cmpl   $0x0,-0x18(%rbp)
jne    118b <ccnl_ccnb_mkBinaryInt+0x7b>
movl   $0x3,-0x18(%rbp)
cmpl   $0x0,-0x18(%rbp)
jle    1182 <ccnl_ccnb_mkBinaryInt+0x72>
mov    -0x14(%rbp),%eax
mov    -0x18(%rbp),%ecx
shl    $0x3,%ecx
shr    %cl,%eax
cmp    $0x0,%eax
je     116f <ccnl_ccnb_mkBinaryInt+0x5f>
jmp    1182 <ccnl_ccnb_mkBinaryInt+0x72>
jmp    1174 <ccnl_ccnb_mkBinaryInt+0x64>
mov    -0x18(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x18(%rbp)
jmp    114c <ccnl_ccnb_mkBinaryInt+0x3c>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
movslq -0x1c(%rbp),%rax
add    %rax,%rdi
mov    -0x18(%rbp),%esi
mov    $0x5,%edx
call   1030 <ccnl_ccnb_mkHeader@plt>
add    -0x1c(%rbp),%eax
mov    %eax,-0x1c(%rbp)
cmpl   $0x0,-0x18(%rbp)
jle    11e8 <ccnl_ccnb_mkBinaryInt+0xd8>
mov    -0x18(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x18(%rbp)
mov    -0x14(%rbp),%eax
mov    -0x18(%rbp),%ecx
shl    $0x3,%ecx
shr    %cl,%eax
and    $0xff,%eax
mov    %al,%dl
mov    -0x8(%rbp),%rax
mov    -0x1c(%rbp),%ecx
mov    %ecx,%esi
add    $0x1,%esi
mov    %esi,-0x1c(%rbp)
movslq %ecx,%rcx
mov    %dl,(%rax,%rcx,1)
jmp    11a9 <ccnl_ccnb_mkBinaryInt+0x99>
mov    -0x8(%rbp),%rax
mov    -0x1c(%rbp),%ecx
mov    %ecx,%edx
add    $0x1,%edx
mov    %edx,-0x1c(%rbp)
movslq %ecx,%rcx
movb   $0x0,(%rax,%rcx,1)
mov    -0x1c(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ccnl_ccnb_mkBinaryInt>:
push   %rbp
push   %r15
push   %r14
push   %rbx
sub    $0x28,%rsp
mov    %r8d,%r15d
mov    %ecx,%r14d
mov    %rdi,%rbx
call   1030 <ccnl_ccnb_mkHeader@plt>
test   %r15d,%r15d
jne    115c <ccnl_ccnb_mkBinaryInt+0x4c>
mov    $0x4,%r15d
cmp    $0xffffff,%r14d
ja     115c <ccnl_ccnb_mkBinaryInt+0x4c>
mov    $0x3,%r15d
cmp    $0xffff,%r14d
ja     115c <ccnl_ccnb_mkBinaryInt+0x4c>
cmp    $0x100,%r14d
mov    $0x2,%r15d
sbb    $0x0,%r15d
movslq %eax,%rbp
lea    (%rbx,%rbp,1),%rdi
mov    %r15d,%esi
mov    $0x5,%edx
call   1030 <ccnl_ccnb_mkHeader@plt>
add    %eax,%ebp
test   %r15d,%r15d
jle    1747 <ccnl_ccnb_mkBinaryInt+0x637>
movslq %ebp,%rbp
lea    -0x1(%r15),%eax
cmp    $0xf,%eax
jb     171e <ccnl_ccnb_mkBinaryInt+0x60e>
add    $0x1,%rax
mov    %rax,%r8
and    $0xfffffffffffffff0,%r8
movd   %r15d,%xmm0
pshufd $0x0,%xmm0,%xmm8
movdqa 0xe56(%rip),%xmm15
paddd  %xmm8,%xmm15
movdqa 0xe58(%rip),%xmm9
paddd  %xmm8,%xmm9
movdqa 0xe5a(%rip),%xmm10
paddd  %xmm8,%xmm10
paddd  0xe5c(%rip),%xmm8
movd   %r14d,%xmm0
pshufd $0x0,%xmm0,%xmm12
lea    -0x10(%r8),%rcx
mov    %rcx,%rsi
shr    $0x4,%rsi
add    $0x1,%rsi
test   %rcx,%rcx
je     175e <ccnl_ccnb_mkBinaryInt+0x64e>
mov    %rsi,%rdi
and    $0xfffffffffffffffe,%rdi
lea    (%rbx,%rbp,1),%rcx
add    $0x10,%rcx
xor    %edx,%edx
nopl   0x0(%rax,%rax,1)
movdqa %xmm10,(%rsp)
movdqa %xmm8,0x10(%rsp)
movdqa %xmm15,%xmm4
pslld  $0x3,%xmm4
movdqa %xmm9,%xmm14
pslld  $0x3,%xmm14
movdqa (%rsp),%xmm13
pslld  $0x3,%xmm13
movdqa 0x10(%rsp),%xmm8
pslld  $0x3,%xmm8
movdqa %xmm8,%xmm5
movdqa 0xde8(%rip),%xmm6
paddd  %xmm6,%xmm5
movdqa %xmm13,%xmm7
paddd  %xmm6,%xmm7
movdqa %xmm14,%xmm2
movdqa %xmm4,%xmm0
paddd  %xmm6,%xmm0
pshuflw $0xfe,%xmm0,%xmm1
movdqa %xmm12,%xmm3
psrld  %xmm1,%xmm3
paddd  %xmm6,%xmm2
pshuflw $0x54,%xmm0,%xmm11
movdqa %xmm12,%xmm1
psrld  %xmm11,%xmm1
pshufd $0xee,%xmm0,%xmm0
pshuflw $0xfe,%xmm0,%xmm11
movdqa %xmm12,%xmm10
psrld  %xmm11,%xmm10
punpcklqdq %xmm3,%xmm1
pshuflw $0x54,%xmm0,%xmm0
movdqa %xmm12,%xmm3
psrld  %xmm0,%xmm3
punpckhqdq %xmm10,%xmm3
pshuflw $0xfe,%xmm2,%xmm0
movdqa %xmm12,%xmm10
psrld  %xmm0,%xmm10
shufps $0xcc,%xmm3,%xmm1
pshuflw $0x54,%xmm2,%xmm3
movdqa %xmm12,%xmm0
psrld  %xmm3,%xmm0
pshufd $0xee,%xmm2,%xmm2
pshuflw $0xfe,%xmm2,%xmm11
movdqa %xmm12,%xmm3
psrld  %xmm11,%xmm3
punpcklqdq %xmm10,%xmm0
pshuflw $0x54,%xmm2,%xmm10
movdqa %xmm12,%xmm2
psrld  %xmm10,%xmm2
punpckhqdq %xmm3,%xmm2
pshuflw $0xfe,%xmm7,%xmm10
movdqa %xmm12,%xmm3
psrld  %xmm10,%xmm3
shufps $0xcc,%xmm2,%xmm0
pshuflw $0x54,%xmm7,%xmm10
movdqa %xmm12,%xmm2
psrld  %xmm10,%xmm2
pshufd $0xee,%xmm7,%xmm11
pshuflw $0xfe,%xmm11,%xmm10
movdqa %xmm12,%xmm7
psrld  %xmm10,%xmm7
punpcklqdq %xmm3,%xmm2
pshuflw $0x54,%xmm11,%xmm10
movdqa %xmm12,%xmm3
psrld  %xmm10,%xmm3
punpckhqdq %xmm7,%xmm3
pshuflw $0xfe,%xmm5,%xmm10
movdqa %xmm12,%xmm7
psrld  %xmm10,%xmm7
shufps $0xcc,%xmm3,%xmm2
pshuflw $0x54,%xmm5,%xmm10
movdqa %xmm12,%xmm3
psrld  %xmm10,%xmm3
pshufd $0xee,%xmm5,%xmm11
pshuflw $0xfe,%xmm11,%xmm10
movdqa %xmm12,%xmm5
psrld  %xmm10,%xmm5
punpcklqdq %xmm7,%xmm3
pshuflw $0x54,%xmm11,%xmm7
movdqa %xmm12,%xmm6
psrld  %xmm7,%xmm6
punpckhqdq %xmm5,%xmm6
shufps $0xcc,%xmm6,%xmm3
movaps 0xc92(%rip),%xmm11
andps  %xmm11,%xmm3
andps  %xmm11,%xmm2
packuswb %xmm2,%xmm3
andps  %xmm11,%xmm0
andps  %xmm11,%xmm1
packuswb %xmm1,%xmm0
packuswb %xmm0,%xmm3
movdqu %xmm3,-0x10(%rcx,%rdx,1)
movdqa 0xc78(%rip),%xmm1
paddd  %xmm1,%xmm8
paddd  %xmm1,%xmm13
paddd  %xmm1,%xmm4
pshuflw $0xfe,%xmm4,%xmm0
movdqa %xmm12,%xmm2
psrld  %xmm0,%xmm2
paddd  %xmm1,%xmm14
pshuflw $0x54,%xmm4,%xmm0
movdqa %xmm12,%xmm1
psrld  %xmm0,%xmm1
pshufd $0xee,%xmm4,%xmm0
pshuflw $0xfe,%xmm0,%xmm3
movdqa %xmm12,%xmm4
psrld  %xmm3,%xmm4
punpcklqdq %xmm2,%xmm1
pshuflw $0x54,%xmm0,%xmm0
movdqa %xmm12,%xmm2
psrld  %xmm0,%xmm2
punpckhqdq %xmm4,%xmm2
pshuflw $0xfe,%xmm14,%xmm0
movdqa %xmm12,%xmm3
psrld  %xmm0,%xmm3
shufps $0xcc,%xmm2,%xmm1
pshuflw $0x54,%xmm14,%xmm2
movdqa %xmm12,%xmm0
psrld  %xmm2,%xmm0
pshufd $0xee,%xmm14,%xmm2
pshuflw $0xfe,%xmm2,%xmm4
movdqa %xmm12,%xmm5
psrld  %xmm4,%xmm5
punpcklqdq %xmm3,%xmm0
pshuflw $0x54,%xmm2,%xmm2
movdqa %xmm12,%xmm3
psrld  %xmm2,%xmm3
punpckhqdq %xmm5,%xmm3
pshuflw $0xfe,%xmm13,%xmm2
movdqa %xmm12,%xmm4
psrld  %xmm2,%xmm4
shufps $0xcc,%xmm3,%xmm0
pshuflw $0x54,%xmm13,%xmm3
movdqa %xmm12,%xmm2
psrld  %xmm3,%xmm2
pshufd $0xee,%xmm13,%xmm3
movdqa (%rsp),%xmm10
pshuflw $0xfe,%xmm3,%xmm5
movdqa %xmm12,%xmm6
psrld  %xmm5,%xmm6
punpcklqdq %xmm4,%xmm2
pshuflw $0x54,%xmm3,%xmm3
movdqa %xmm12,%xmm4
psrld  %xmm3,%xmm4
punpckhqdq %xmm6,%xmm4
pshuflw $0xfe,%xmm8,%xmm3
movdqa %xmm12,%xmm5
psrld  %xmm3,%xmm5
shufps $0xcc,%xmm4,%xmm2
pshuflw $0x54,%xmm8,%xmm3
movdqa %xmm12,%xmm4
psrld  %xmm3,%xmm4
pshufd $0xee,%xmm8,%xmm3
movdqa 0x10(%rsp),%xmm8
pshuflw $0xfe,%xmm3,%xmm6
movdqa %xmm12,%xmm7
psrld  %xmm6,%xmm7
punpcklqdq %xmm5,%xmm4
pshuflw $0x54,%xmm3,%xmm3
movdqa %xmm12,%xmm5
psrld  %xmm3,%xmm5
punpckhqdq %xmm7,%xmm5
shufps $0xcc,%xmm5,%xmm4
andps  %xmm11,%xmm4
andps  %xmm11,%xmm2
packuswb %xmm2,%xmm4
andps  %xmm11,%xmm0
andps  %xmm11,%xmm1
packuswb %xmm1,%xmm0
packuswb %xmm0,%xmm4
movdqu %xmm4,(%rcx,%rdx,1)
add    $0x20,%rdx
movdqa 0xb0e(%rip),%xmm0
paddd  %xmm0,%xmm8
paddd  %xmm0,%xmm10
paddd  %xmm0,%xmm9
paddd  %xmm0,%xmm15
add    $0xfffffffffffffffe,%rdi
jne    1210 <ccnl_ccnb_mkBinaryInt+0x100>
test   $0x1,%sil
je     1713 <ccnl_ccnb_mkBinaryInt+0x603>
pslld  $0x3,%xmm15
pslld  $0x3,%xmm9
pslld  $0x3,%xmm10
pslld  $0x3,%xmm8
movdqa 0xa96(%rip),%xmm0
paddd  %xmm0,%xmm8
paddd  %xmm0,%xmm10
paddd  %xmm0,%xmm15
pshuflw $0xfe,%xmm15,%xmm1
movdqa %xmm12,%xmm2
psrld  %xmm1,%xmm2
paddd  %xmm0,%xmm9
pshuflw $0x54,%xmm15,%xmm0
movdqa %xmm12,%xmm1
psrld  %xmm0,%xmm1
pshufd $0xee,%xmm15,%xmm0
pshuflw $0xfe,%xmm0,%xmm3
movdqa %xmm12,%xmm4
psrld  %xmm3,%xmm4
punpcklqdq %xmm2,%xmm1
pshuflw $0x54,%xmm0,%xmm0
movdqa %xmm12,%xmm2
psrld  %xmm0,%xmm2
punpckhqdq %xmm4,%xmm2
pshuflw $0xfe,%xmm9,%xmm0
movdqa %xmm12,%xmm3
psrld  %xmm0,%xmm3
shufps $0xcc,%xmm2,%xmm1
pshuflw $0x54,%xmm9,%xmm2
movdqa %xmm12,%xmm0
psrld  %xmm2,%xmm0
pshufd $0xee,%xmm9,%xmm2
pshuflw $0xfe,%xmm2,%xmm4
movdqa %xmm12,%xmm5
psrld  %xmm4,%xmm5
punpcklqdq %xmm3,%xmm0
pshuflw $0x54,%xmm2,%xmm2
movdqa %xmm12,%xmm3
psrld  %xmm2,%xmm3
punpckhqdq %xmm5,%xmm3
pshuflw $0xfe,%xmm10,%xmm2
movdqa %xmm12,%xmm4
psrld  %xmm2,%xmm4
shufps $0xcc,%xmm3,%xmm0
pshuflw $0x54,%xmm10,%xmm3
movdqa %xmm12,%xmm2
psrld  %xmm3,%xmm2
pshufd $0xee,%xmm10,%xmm3
pshuflw $0xfe,%xmm3,%xmm5
movdqa %xmm12,%xmm6
psrld  %xmm5,%xmm6
punpcklqdq %xmm4,%xmm2
pshuflw $0x54,%xmm3,%xmm3
movdqa %xmm12,%xmm4
psrld  %xmm3,%xmm4
punpckhqdq %xmm6,%xmm4
pshuflw $0xfe,%xmm8,%xmm3
movdqa %xmm12,%xmm5
psrld  %xmm3,%xmm5
shufps $0xcc,%xmm4,%xmm2
pshuflw $0x54,%xmm8,%xmm3
movdqa %xmm12,%xmm4
psrld  %xmm3,%xmm4
pshufd $0xee,%xmm8,%xmm3
pshuflw $0xfe,%xmm3,%xmm6
movdqa %xmm12,%xmm7
psrld  %xmm6,%xmm7
add    %rbp,%rdx
pshuflw $0x54,%xmm3,%xmm3
psrld  %xmm3,%xmm12
punpcklqdq %xmm5,%xmm4
punpckhqdq %xmm7,%xmm12
shufps $0xcc,%xmm12,%xmm4
movaps 0x95a(%rip),%xmm3
andps  %xmm3,%xmm4
andps  %xmm3,%xmm2
packuswb %xmm2,%xmm4
andps  %xmm3,%xmm0
andps  %xmm3,%xmm1
packuswb %xmm1,%xmm0
packuswb %xmm0,%xmm4
movdqu %xmm4,(%rbx,%rdx,1)
add    %r8,%rbp
cmp    %r8,%rax
je     1747 <ccnl_ccnb_mkBinaryInt+0x637>
sub    %r8d,%r15d
mov    %r15d,%eax
add    $0x1,%eax
lea    -0x8(,%r15,8),%ecx
ff
nopl   0x0(%rax)
mov    %r14d,%edx
shr    %cl,%edx
mov    %dl,(%rbx,%rbp,1)
add    $0x1,%rbp
add    $0xffffffff,%eax
add    $0xfffffff8,%ecx
cmp    $0x1,%eax
ja     1730 <ccnl_ccnb_mkBinaryInt+0x620>
movslq %ebp,%rax
add    $0x1,%ebp
movb   $0x0,(%rbx,%rax,1)
mov    %ebp,%eax
add    $0x28,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret
xor    %edx,%edx
test   $0x1,%sil
jne    158a <ccnl_ccnb_mkBinaryInt+0x47a>
jmp    1713 <ccnl_ccnb_mkBinaryInt+0x603>

LLVM IR (-O0):
define i32 @ccnl_ccnb_mkBinaryInt(i8* %0, i32 %1, i32 %2, i32 %3, i32 %4) {
%6 = alloca i8*
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
store i8* %0, i8** %6
store i32 %1, i32* %7
store i32 %2, i32* %8
store i32 %3, i32* %9
store i32 %4, i32* %10
%12 = load i8*, i8** %6
%13 = load i32, i32* %7
%14 = load i32, i32* %8
%15 = call i32 @ccnl_ccnb_mkHeader(i8* %12, i32 %13, i32 %14)
store i32 %15, i32* %11
%16 = load i32, i32* %10
%17 = icmp ne i32 %16, 0
br i1 %17, label %36, label %18
18: ; preds = %5
store i32 3, i32* %10
br label %19
19: ; preds = %30, %18
%20 = load i32, i32* %10
%21 = icmp sgt i32 %20, 0
br i1 %21, label %22, label %33
22: ; preds = %19
%23 = load i32, i32* %9
%24 = load i32, i32* %10
%25 = mul nsw i32 8, %24
%26 = lshr i32 %23, %25
%27 = icmp ne i32 %26, 0
br i1 %27, label %28, label %29
28: ; preds = %22
br label %33
29: ; preds = %22
br label %30
30: ; preds = %29
%31 = load i32, i32* %10
%32 = add nsw i32 %31, -1
store i32 %32, i32* %10
br label %19
33: ; preds = %28, %19
%34 = load i32, i32* %10
%35 = add nsw i32 %34, 1
store i32 %35, i32* %10
br label %36
36: ; preds = %33, %5
%37 = load i8*, i8** %6
%38 = load i32, i32* %11
%39 = sext i32 %38 to i64
%40 = getelementptr inbounds i8, i8* %37, i64 %39
%41 = load i32, i32* %10
%42 = call i32 @ccnl_ccnb_mkHeader(i8* %40, i32 %41, i32 5)
%43 = load i32, i32* %11
%44 = add nsw i32 %43, %42
store i32 %44, i32* %11
br label %45
45: ; preds = %48, %36
%46 = load i32, i32* %10
%47 = icmp sgt i32 %46, 0
br i1 %47, label %48, label %62
48: ; preds = %45
%49 = load i32, i32* %10
%50 = add nsw i32 %49, -1
store i32 %50, i32* %10
%51 = load i32, i32* %9
%52 = load i32, i32* %10
%53 = mul nsw i32 8, %52
%54 = lshr i32 %51, %53
%55 = and i32 255, %54
%56 = trunc i32 %55 to i8
%57 = load i8*, i8** %6
%58 = load i32, i32* %11
%59 = add nsw i32 %58, 1
store i32 %59, i32* %11
%60 = sext i32 %58 to i64
%61 = getelementptr inbounds i8, i8* %57, i64 %60
store i8 %56, i8* %61
br label %45
62: ; preds = %45
%63 = load i8*, i8** %6
%64 = load i32, i32* %11
%65 = add nsw i32 %64, 1
store i32 %65, i32* %11
%66 = sext i32 %64 to i64
%67 = getelementptr inbounds i8, i8* %63, i64 %66
store i8 0, i8* %67
%68 = load i32, i32* %11
ret i32 %68
}

LLVM IR (-O2):
define i32 @ccnl_ccnb_mkBinaryInt(i8* %0, i32 %1, i32 %2, i32 %3, i32 %4) {
%6 = tail call i32 @ccnl_ccnb_mkHeader(i8* %0, i32 %1, i32 %2)
%7 = icmp eq i32 %4, 0
br i1 %7, label %8, label %15
8: ; preds = %5
%9 = icmp ult i32 %3, 16777216
br i1 %9, label %10, label %15
10: ; preds = %8
%11 = icmp ult i32 %3, 65536
br i1 %11, label %12, label %15
12: ; preds = %10
%13 = icmp ult i32 %3, 256
%14 = select i1 %13, i32 1, i32 2
br label %15
15: ; preds = %12, %8, %10, %5
%16 = phi i32 [ %4, %5 ], [ 4, %8 ], [ 3, %10 ], [ %14, %12 ]
%17 = sext i32 %6 to i64
%18 = getelementptr inbounds i8, i8* %0, i64 %17
%19 = tail call i32 @ccnl_ccnb_mkHeader(i8* %18, i32 %16, i32 5)
%20 = add i32 %19, %6
%21 = icmp sgt i32 %16, 0
br i1 %21, label %22, label %98
22: ; preds = %15
%23 = sext i32 %20 to i64
%24 = add i32 %16, -1
%25 = zext i32 %24 to i64
%26 = add nuw nsw i64 %25, 1
%27 = icmp ult i32 %24, 15
br i1 %27, label %82, label %28
28: ; preds = %22
%29 = and i64 %26, 8589934576
%30 = add nsw i64 %29, %23
%31 = trunc i64 %29 to i32
%32 = sub i32 %16, %31
%33 = insertelement <16 x i32> poison, i32 %16, i64 0
%34 = shufflevector <16 x i32> %33, <16 x i32> poison, <16 x i32> zeroinitializer
%35 = add <16 x i32> %34, <i32 0, i32 -1, i32 -2, i32 -3, i32 -4, i32 -5, i32 -6, i32 -7, i32 -8, i32 -9, i32 -10, i32 -11, i32 -12, i32 -13, i32 -14, i32 -15>
%36 = insertelement <16 x i32> poison, i32 %3, i64 0
%37 = shufflevector <16 x i32> %36, <16 x i32> poison, <16 x i32> zeroinitializer
%38 = add nsw i64 %29, -16
%39 = lshr exact i64 %38, 4
%40 = add nuw nsw i64 %39, 1
%41 = and i64 %40, 1
%42 = icmp eq i64 %38, 0
br i1 %42, label %68, label %43
43: ; preds = %28
%44 = and i64 %40, 2305843009213693950
br label %45
45: ; preds = %45, %43
%46 = phi i64 [ 0, %43 ], [ %64, %45 ]
%47 = phi <16 x i32> [ %35, %43 ], [ %65, %45 ]
%48 = phi i64 [ 0, %43 ], [ %66, %45 ]
%49 = add i64 %46, %23
%50 = shl <16 x i32> %47, <i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3>
%51 = add <16 x i32> %50, <i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8>
%52 = lshr <16 x i32> %37, %51
%53 = trunc <16 x i32> %52 to <16 x i8>
%54 = getelementptr inbounds i8, i8* %0, i64 %49
%55 = bitcast i8* %54 to <16 x i8>*
store <16 x i8> %53, <16 x i8>* %55
%56 = or i64 %46, 16
%57 = add i64 %56, %23
%58 = shl <16 x i32> %47, <i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3>
%59 = add <16 x i32> %58, <i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136, i32 -136>
%60 = lshr <16 x i32> %37, %59
%61 = trunc <16 x i32> %60 to <16 x i8>
%62 = getelementptr inbounds i8, i8* %0, i64 %57
%63 = bitcast i8* %62 to <16 x i8>*
store <16 x i8> %61, <16 x i8>* %63
%64 = add nuw i64 %46, 32
%65 = add <16 x i32> %47, <i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32, i32 -32>
%66 = add i64 %48, 2
%67 = icmp eq i64 %66, %44
br i1 %67, label %68, label %45
68: ; preds = %45, %28
%69 = phi i64 [ 0, %28 ], [ %64, %45 ]
%70 = phi <16 x i32> [ %35, %28 ], [ %65, %45 ]
%71 = icmp eq i64 %41, 0
br i1 %71, label %80, label %72
72: ; preds = %68
%73 = add i64 %69, %23
%74 = shl <16 x i32> %70, <i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3, i32 3>
%75 = add <16 x i32> %74, <i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8, i32 -8>
%76 = lshr <16 x i32> %37, %75
%77 = trunc <16 x i32> %76 to <16 x i8>
%78 = getelementptr inbounds i8, i8* %0, i64 %73
%79 = bitcast i8* %78 to <16 x i8>*
store <16 x i8> %77, <16 x i8>* %79
br label %80
80: ; preds = %68, %72
%81 = icmp eq i64 %26, %29
br i1 %81, label %95, label %82
82: ; preds = %22, %80
%83 = phi i64 [ %23, %22 ], [ %30, %80 ]
%84 = phi i32 [ %16, %22 ], [ %32, %80 ]
br label %85
85: ; preds = %82, %85
%86 = phi i64 [ %92, %85 ], [ %83, %82 ]
%87 = phi i32 [ %88, %85 ], [ %84, %82 ]
%88 = add nsw i32 %87, -1
%89 = shl nsw i32 %88, 3
%90 = lshr i32 %3, %89
%91 = trunc i32 %90 to i8
%92 = add nsw i64 %86, 1
%93 = getelementptr inbounds i8, i8* %0, i64 %86
store i8 %91, i8* %93
%94 = icmp ugt i32 %87, 1
br i1 %94, label %85, label %95
95: ; preds = %85, %80
%96 = phi i64 [ %30, %80 ], [ %92, %85 ]
%97 = trunc i64 %96 to i32
br label %98
98: ; preds = %95, %15
%99 = phi i32 [ %20, %15 ], [ %97, %95 ]
%100 = add nsw i32 %99, 1
%101 = sext i32 %99 to i64
%102 = getelementptr inbounds i8, i8* %0, i64 %101
store i8 0, i8* %102
ret i32 %100
}