#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 */
char fgetc(int /*<<< orphan*/ *);
size_t fpack(int /*<<< orphan*/ *, char *, char, ...);
int /*<<< orphan*/ fputc(int, int /*<<< orphan*/ *);
int /*<<< orphan*/ fputs(char *, int /*<<< orphan*/ *);
int /*<<< orphan*/ fread(char *, int, size_t, int /*<<< orphan*/ *);
size_t funpack(int /*<<< orphan*/ *, char *, char *, ...);
int /*<<< orphan*/ int_ok(char, char);
int /*<<< orphan*/ rewind(int /*<<< orphan*/ *);
int /*<<< orphan*/ size_ok(size_t, int);
int /*<<< orphan*/ str_ok(char *, char *);
int /*<<< orphan*/ test(char *);
int /*<<< orphan*/ title(char *);
int /*<<< orphan*/ *tmpfile();
int main(void) {
  FILE *file = tmpfile();
  size_t len;
  title("fpack()");
  test("c");
  rewind(file);
  len = fpack(file, "c", 0);
  size_ok(len, 1);
  rewind(file);
  int_ok(fgetc(file), 0);
  test("cc");
  rewind(file);
  len = fpack(file, "cc", 1, 2);
  size_ok(len, 2);
  rewind(file);
  int_ok(fgetc(file), 1);
  int_ok(fgetc(file), 2);
  test("c c c");
  rewind(file);
  len = fpack(file, "c c c", 3, 4, 5);
  size_ok(len, 3);
  rewind(file);
  int_ok(fgetc(file), 3);
  int_ok(fgetc(file), 4);
  int_ok(fgetc(file), 5);
  test("c4");
  rewind(file);
  len = fpack(file, "c4", 6, 7, 8, 9);
  size_ok(len, 4);
  rewind(file);
  int_ok(fgetc(file), 6);
  int_ok(fgetc(file), 7);
  int_ok(fgetc(file), 8);
  int_ok(fgetc(file), 9);
  test("c15");
  rewind(file);
  len = fpack(file, "c15", 'H', 'e', 'l', 'l', 'o', ',', ' ', 'w', 'o', 'r',
              'l', 'd', '!', '\n', 0);
  size_ok(len, 15);
  rewind(file);
  char buffer[20];
  fread(buffer, 1, len, file);
  str_ok(buffer, "Hello, world!\n");
  title("funpack()");
  char c1, c2, c3, c4, c5;
  char c6, c7, c8, c9, c10;
  char c11, c12, c13, c14, c15;
  test("c");
  rewind(file);
  fputc(0, file);
  c1 = -1;
  rewind(file);
  len = funpack(file, "c", &c1);
  size_ok(len, 1);
  int_ok(c1, 0);
  test("cc");
  rewind(file);
  fputc(1, file);
  fputc(2, file);
  c1 = -1;
  c2 = -1;
  rewind(file);
  len = funpack(file, "cc", &c1, &c2);
  size_ok(len, 2);
  int_ok(c1, 1);
  int_ok(c2, 2);
  test("c c c");
  rewind(file);
  fputc(3, file);
  fputc(4, file);
  fputc(5, file);
  c1 = -1;
  c2 = -1;
  c3 = -1;
  rewind(file);
  len = funpack(file, "c c c", &c1, &c2, &c3);
  size_ok(len, 3);
  int_ok(c1, 3);
  int_ok(c2, 4);
  int_ok(c3, 5);
  test("c4");
  rewind(file);
  fputc(6, file);
  fputc(7, file);
  fputc(8, file);
  fputc(9, file);
  c1 = -1;
  c2 = -1;
  c3 = -1;
  c4 = -1;
  rewind(file);
  len = funpack(file, "c4", &c1, &c2, &c3, &c4);
  size_ok(len, 4);
  int_ok(c1, 6);
  int_ok(c2, 7);
  int_ok(c3, 8);
  int_ok(c4, 9);
  test("c15");
  rewind(file);
  fputs("Hello, world!\n", file);
  c1 = -1;
  c2 = -1;
  c3 = -1;
  c4 = -1;
  c5 = -1;
  c6 = -1;
  c7 = -1;
  c8 = -1;
  c9 = -1;
  c10 = -1;
  c11 = -1;
  c12 = -1;
  c13 = -1;
  c14 = -1;
  c15 = -1;
  rewind(file);
  len = funpack(file, "c15", &c1, &c2, &c3, &c4, &c5, &c6, &c7, &c8, &c9, &c10,
                &c11, &c12, &c13, &c14, &c15);
  size_ok(len, 15);
  int_ok(c1, 'H');
  int_ok(c2, 'e');
  int_ok(c3, 'l');
  int_ok(c4, 'l');
  int_ok(c5, 'o');
  int_ok(c6, ',');
  int_ok(c7, ' ');
  int_ok(c8, 'w');
  int_ok(c9, 'o');
  int_ok(c10, 'r');
  int_ok(c11, 'l');
  int_ok(c12, 'd');
  int_ok(c13, '!');
  int_ok(c14, '\n');
  int_ok(c15, 0);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0xc8,%rsp
movl   $0x0,-0x2c(%rbp)
mov    $0x0,%al
call   10b0 <tmpfile@plt>
mov    %rax,-0x38(%rbp)
lea    0xe03(%rip),%rdi
call   10a0 <title@plt>
lea    0xe06(%rip),%rdi
call   10f0 <test@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
lea    0xded(%rip),%rsi
xor    %edx,%edx
mov    $0x0,%al
call   10d0 <fpack@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rdi
mov    $0x1,%esi
call   10c0 <size_ok@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
call   1080 <fgetc@plt>
xor    %esi,%esi
movsbl %al,%edi
call   1030 <int_ok@plt>
lea    0xda8(%rip),%rdi
call   10f0 <test@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
lea    0xd8f(%rip),%rsi
mov    $0x1,%edx
mov    $0x2,%ecx
mov    $0x0,%al
call   10d0 <fpack@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rdi
mov    $0x2,%esi
call   10c0 <size_ok@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
call   1080 <fgetc@plt>
mov    $0x1,%esi
movsbl %al,%edi
call   1030 <int_ok@plt>
mov    -0x38(%rbp),%rdi
call   1080 <fgetc@plt>
mov    $0x2,%esi
movsbl %al,%edi
call   1030 <int_ok@plt>
lea    0xd33(%rip),%rdi
call   10f0 <test@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
lea    0xd1a(%rip),%rsi
mov    $0x3,%edx
mov    $0x4,%ecx
mov    $0x5,%r8d
mov    $0x0,%al
call   10d0 <fpack@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rdi
mov    $0x3,%esi
call   10c0 <size_ok@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
call   1080 <fgetc@plt>
mov    $0x3,%esi
movsbl %al,%edi
call   1030 <int_ok@plt>
mov    -0x38(%rbp),%rdi
call   1080 <fgetc@plt>
mov    $0x4,%esi
movsbl %al,%edi
call   1030 <int_ok@plt>
mov    -0x38(%rbp),%rdi
call   1080 <fgetc@plt>
mov    $0x5,%esi
movsbl %al,%edi
call   1030 <int_ok@plt>
lea    0xca5(%rip),%rdi
call   10f0 <test@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
lea    0xc8c(%rip),%rsi
mov    $0x6,%edx
mov    $0x7,%ecx
mov    $0x8,%r8d
mov    $0x9,%r9d
mov    $0x0,%al
call   10d0 <fpack@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rdi
mov    $0x4,%esi
call   10c0 <size_ok@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
call   1080 <fgetc@plt>
mov    $0x6,%esi
movsbl %al,%edi
call   1030 <int_ok@plt>
mov    -0x38(%rbp),%rdi
call   1080 <fgetc@plt>
mov    $0x7,%esi
movsbl %al,%edi
call   1030 <int_ok@plt>
mov    -0x38(%rbp),%rdi
call   1080 <fgetc@plt>
mov    $0x8,%esi
movsbl %al,%edi
call   1030 <int_ok@plt>
mov    -0x38(%rbp),%rdi
call   1080 <fgetc@plt>
mov    $0x9,%esi
movsbl %al,%edi
call   1030 <int_ok@plt>
lea    0xbf8(%rip),%rdi
call   10f0 <test@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
lea    0xbdf(%rip),%rsi
mov    $0x48,%edx
mov    $0x65,%ecx
mov    $0x6c,%r9d
xor    %eax,%eax
mov    %r9d,%r8d
movl   $0x6f,(%rsp)
movl   $0x2c,0x8(%rsp)
movl   $0x20,0x10(%rsp)
movl   $0x77,0x18(%rsp)
movl   $0x6f,0x20(%rsp)
movl   $0x72,0x28(%rsp)
movl   $0x6c,0x30(%rsp)
movl   $0x64,0x38(%rsp)
movl   $0x21,0x40(%rsp)
movl   $0xa,0x48(%rsp)
movl   $0x0,0x50(%rsp)
mov    $0x0,%al
call   10d0 <fpack@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rdi
mov    $0xf,%esi
call   10c0 <size_ok@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
lea    -0x60(%rbp),%rdi
mov    -0x40(%rbp),%rdx
mov    -0x38(%rbp),%rcx
mov    $0x1,%esi
call   1040 <fread@plt>
lea    -0x60(%rbp),%rdi
lea    0xb34(%rip),%rsi
call   1060 <str_ok@plt>
lea    0xb37(%rip),%rdi
call   10a0 <title@plt>
lea    0xb13(%rip),%rdi
call   10f0 <test@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rsi
xor    %edi,%edi
call   1090 <fputc@plt>
movb   $0xff,-0x61(%rbp)
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
lea    0xae2(%rip),%rsi
lea    -0x61(%rbp),%rdx
mov    $0x0,%al
call   10e0 <funpack@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rdi
mov    $0x1,%esi
call   10c0 <size_ok@plt>
xor    %esi,%esi
movsbl -0x61(%rbp),%edi
call   1030 <int_ok@plt>
lea    0xaac(%rip),%rdi
call   10f0 <test@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rsi
mov    $0x1,%edi
call   1090 <fputc@plt>
mov    -0x38(%rbp),%rsi
mov    $0x2,%edi
call   1090 <fputc@plt>
movb   $0xff,-0x61(%rbp)
movb   $0xff,-0x62(%rbp)
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
lea    0xa66(%rip),%rsi
lea    -0x61(%rbp),%rdx
lea    -0x62(%rbp),%rcx
mov    $0x0,%al
call   10e0 <funpack@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rdi
mov    $0x2,%esi
call   10c0 <size_ok@plt>
mov    $0x1,%esi
movsbl -0x61(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x2,%esi
movsbl -0x62(%rbp),%edi
call   1030 <int_ok@plt>
lea    0xa25(%rip),%rdi
call   10f0 <test@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rsi
mov    $0x3,%edi
call   1090 <fputc@plt>
mov    -0x38(%rbp),%rsi
mov    $0x4,%edi
call   1090 <fputc@plt>
mov    -0x38(%rbp),%rsi
mov    $0x5,%edi
call   1090 <fputc@plt>
movb   $0xff,-0x61(%rbp)
movb   $0xff,-0x62(%rbp)
movb   $0xff,-0x63(%rbp)
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
lea    0x9cd(%rip),%rsi
lea    -0x61(%rbp),%rdx
lea    -0x62(%rbp),%rcx
lea    -0x63(%rbp),%r8
mov    $0x0,%al
call   10e0 <funpack@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rdi
mov    $0x3,%esi
call   10c0 <size_ok@plt>
mov    $0x3,%esi
movsbl -0x61(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x4,%esi
movsbl -0x62(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x5,%esi
movsbl -0x63(%rbp),%edi
call   1030 <int_ok@plt>
lea    0x97d(%rip),%rdi
call   10f0 <test@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rsi
mov    $0x6,%edi
call   1090 <fputc@plt>
mov    -0x38(%rbp),%rsi
mov    $0x7,%edi
call   1090 <fputc@plt>
mov    -0x38(%rbp),%rsi
mov    $0x8,%edi
call   1090 <fputc@plt>
mov    -0x38(%rbp),%rsi
mov    $0x9,%edi
call   1090 <fputc@plt>
movb   $0xff,-0x61(%rbp)
movb   $0xff,-0x62(%rbp)
movb   $0xff,-0x63(%rbp)
movb   $0xff,-0x64(%rbp)
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
lea    0x913(%rip),%rsi
lea    -0x61(%rbp),%rdx
lea    -0x62(%rbp),%rcx
lea    -0x63(%rbp),%r8
lea    -0x64(%rbp),%r9
mov    $0x0,%al
call   10e0 <funpack@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rdi
mov    $0x4,%esi
call   10c0 <size_ok@plt>
mov    $0x6,%esi
movsbl -0x61(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x7,%esi
movsbl -0x62(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x8,%esi
movsbl -0x63(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x9,%esi
movsbl -0x64(%rbp),%edi
call   1030 <int_ok@plt>
lea    0x8ae(%rip),%rdi
call   10f0 <test@plt>
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rsi
lea    0x899(%rip),%rdi
call   1070 <fputs@plt>
movb   $0xff,-0x61(%rbp)
movb   $0xff,-0x62(%rbp)
movb   $0xff,-0x63(%rbp)
movb   $0xff,-0x64(%rbp)
movb   $0xff,-0x65(%rbp)
movb   $0xff,-0x66(%rbp)
movb   $0xff,-0x67(%rbp)
movb   $0xff,-0x68(%rbp)
movb   $0xff,-0x69(%rbp)
movb   $0xff,-0x6a(%rbp)
movb   $0xff,-0x6b(%rbp)
movb   $0xff,-0x6c(%rbp)
movb   $0xff,-0x6d(%rbp)
movb   $0xff,-0x6e(%rbp)
movb   $0xff,-0x6f(%rbp)
mov    -0x38(%rbp),%rdi
call   1050 <rewind@plt>
mov    -0x38(%rbp),%rdi
lea    0x840(%rip),%rsi
lea    -0x61(%rbp),%rdx
lea    -0x62(%rbp),%rcx
lea    -0x63(%rbp),%r8
lea    -0x64(%rbp),%r9
lea    -0x65(%rbp),%rax
mov    %rax,-0x90(%rbp)
lea    -0x66(%rbp),%rax
mov    %rax,-0x88(%rbp)
lea    -0x67(%rbp),%rax
mov    %rax,-0x80(%rbp)
lea    -0x68(%rbp),%r13
lea    -0x69(%rbp),%r12
lea    -0x6a(%rbp),%r15
lea    -0x6b(%rbp),%r14
lea    -0x6c(%rbp),%rbx
lea    -0x6d(%rbp),%r11
lea    -0x6e(%rbp),%r10
lea    -0x6f(%rbp),%rax
mov    %rax,-0x78(%rbp)
mov    -0x90(%rbp),%rax
mov    %rax,(%rsp)
mov    -0x88(%rbp),%rax
mov    %rax,0x8(%rsp)
mov    -0x80(%rbp),%rax
mov    %rax,0x10(%rsp)
mov    -0x78(%rbp),%rax
mov    %r13,0x18(%rsp)
mov    %r12,0x20(%rsp)
mov    %r15,0x28(%rsp)
mov    %r14,0x30(%rsp)
mov    %rbx,0x38(%rsp)
mov    %r11,0x40(%rsp)
mov    %r10,0x48(%rsp)
mov    %rax,0x50(%rsp)
mov    $0x0,%al
call   10e0 <funpack@plt>
mov    %rax,-0x40(%rbp)
mov    -0x40(%rbp),%rdi
mov    $0xf,%esi
call   10c0 <size_ok@plt>
mov    $0x48,%esi
movsbl -0x61(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x65,%esi
movsbl -0x62(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x6c,%esi
movsbl -0x63(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x6c,%esi
movsbl -0x64(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x6f,%esi
movsbl -0x65(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x2c,%esi
movsbl -0x66(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x20,%esi
movsbl -0x67(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x77,%esi
movsbl -0x68(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x6f,%esi
movsbl -0x69(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x72,%esi
movsbl -0x6a(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x6c,%esi
movsbl -0x6b(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x64,%esi
movsbl -0x6c(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0x21,%esi
movsbl -0x6d(%rbp),%edi
call   1030 <int_ok@plt>
mov    $0xa,%esi
movsbl -0x6e(%rbp),%edi
call   1030 <int_ok@plt>
xor    %esi,%esi
movsbl -0x6f(%rbp),%edi
call   1030 <int_ok@plt>
xor    %eax,%eax
add    $0xc8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x28,%rsp
xor    %eax,%eax
call   10a0 <tmpfile@plt>
mov    %rax,%rbx
lea    0xe11(%rip),%rdi
call   1090 <title@plt>
lea    0xe14(%rip),%r15
mov    %r15,%rdi
call   10f0 <test@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
xor    %edx,%edx
xor    %eax,%eax
call   10c0 <fpack@plt>
mov    %rax,%rdi
mov    $0x1,%esi
call   10b0 <size_ok@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    %rbx,%rdi
call   1070 <fgetc@plt>
movsbl %al,%edi
xor    %esi,%esi
call   1030 <int_ok@plt>
lea    0xdc0(%rip),%r13
mov    %r13,%rdi
call   10f0 <test@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    %rbx,%rdi
mov    %r13,%rsi
mov    $0x1,%edx
mov    $0x2,%ecx
xor    %eax,%eax
call   10c0 <fpack@plt>
mov    %rax,%rdi
mov    $0x2,%esi
call   10b0 <size_ok@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    %rbx,%rdi
call   1070 <fgetc@plt>
movsbl %al,%edi
mov    $0x1,%esi
call   1030 <int_ok@plt>
mov    %rbx,%rdi
call   1070 <fgetc@plt>
movsbl %al,%edi
mov    $0x2,%esi
call   1030 <int_ok@plt>
lea    0xd56(%rip),%r12
mov    %r12,%rdi
call   10f0 <test@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    %rbx,%rdi
mov    %r12,%rsi
mov    $0x3,%edx
mov    $0x4,%ecx
mov    $0x5,%r8d
xor    %eax,%eax
call   10c0 <fpack@plt>
mov    %rax,%rdi
mov    $0x3,%esi
call   10b0 <size_ok@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    %rbx,%rdi
call   1070 <fgetc@plt>
movsbl %al,%edi
mov    $0x3,%esi
call   1030 <int_ok@plt>
mov    %rbx,%rdi
call   1070 <fgetc@plt>
movsbl %al,%edi
mov    $0x4,%esi
call   1030 <int_ok@plt>
mov    %rbx,%rdi
call   1070 <fgetc@plt>
movsbl %al,%edi
mov    $0x5,%esi
call   1030 <int_ok@plt>
lea    0xcd4(%rip),%rbp
mov    %rbp,%rdi
call   10f0 <test@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    %rbx,%rdi
mov    %rbp,%rsi
mov    $0x6,%edx
mov    $0x7,%ecx
mov    $0x8,%r8d
mov    $0x9,%r9d
xor    %eax,%eax
call   10c0 <fpack@plt>
mov    %rax,%rdi
mov    $0x4,%esi
call   10b0 <size_ok@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    %rbx,%rdi
call   1070 <fgetc@plt>
movsbl %al,%edi
mov    $0x6,%esi
call   1030 <int_ok@plt>
mov    %rbx,%rdi
call   1070 <fgetc@plt>
movsbl %al,%edi
mov    $0x7,%esi
call   1030 <int_ok@plt>
mov    %rbx,%rdi
call   1070 <fgetc@plt>
movsbl %al,%edi
mov    $0x8,%esi
call   1030 <int_ok@plt>
mov    %rbx,%rdi
call   1070 <fgetc@plt>
movsbl %al,%edi
mov    $0x9,%esi
call   1030 <int_ok@plt>
lea    0xc34(%rip),%rbp
mov    %rbp,%rdi
call   10f0 <test@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
sub    $0x8,%rsp
mov    %rbx,%rdi
mov    %rbp,%rsi
mov    $0x48,%edx
mov    $0x65,%ecx
mov    $0x6c,%r8d
mov    $0x6c,%r9d
xor    %eax,%eax
push   $0x0
push   $0xa
push   $0x21
push   $0x64
push   $0x6c
push   $0x72
push   $0x6f
push   $0x77
push   $0x20
push   $0x2c
push   $0x6f
call   10c0 <fpack@plt>
add    $0x60,%rsp
mov    %rax,%rbp
mov    %rax,%rdi
mov    $0xf,%esi
call   10b0 <size_ok@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
lea    0x10(%rsp),%r14
mov    %r14,%rdi
mov    $0x1,%esi
mov    %rbp,%rdx
mov    %rbx,%rcx
call   1040 <fread@plt>
lea    0xbb0(%rip),%rsi
mov    %r14,%rdi
mov    %rsi,%r14
call   1060 <str_ok@plt>
lea    0xbad(%rip),%rdi
call   1090 <title@plt>
mov    %r15,%rdi
call   10f0 <test@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
xor    %edi,%edi
mov    %rbx,%rsi
call   1080 <fputc@plt>
movb   $0xff,0x1(%rsp)
mov    %rbx,%rdi
call   1050 <rewind@plt>
lea    0x1(%rsp),%rbp
mov    %rbx,%rdi
mov    %r15,%rsi
mov    %rbp,%rdx
xor    %eax,%eax
call   10d0 <funpack@plt>
mov    %rax,%rdi
mov    $0x1,%esi
call   10b0 <size_ok@plt>
movsbl 0x1(%rsp),%edi
xor    %esi,%esi
call   1030 <int_ok@plt>
mov    %r13,%rdi
call   10f0 <test@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    $0x1,%edi
mov    %rbx,%rsi
call   1080 <fputc@plt>
mov    $0x2,%edi
mov    %rbx,%rsi
call   1080 <fputc@plt>
movb   $0xff,0x1(%rsp)
movb   $0xff,0x2(%rsp)
mov    %rbx,%rdi
call   1050 <rewind@plt>
lea    0x2(%rsp),%r15
mov    %rbx,%rdi
mov    %r13,%rsi
mov    %rbp,%rdx
mov    %r15,%rcx
xor    %eax,%eax
call   10d0 <funpack@plt>
mov    %rax,%rdi
mov    $0x2,%esi
call   10b0 <size_ok@plt>
movsbl 0x1(%rsp),%edi
mov    $0x1,%esi
call   1030 <int_ok@plt>
movsbl 0x2(%rsp),%edi
mov    $0x2,%esi
call   1030 <int_ok@plt>
mov    %r12,%rdi
call   10f0 <test@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    $0x3,%edi
mov    %rbx,%rsi
call   1080 <fputc@plt>
mov    $0x4,%edi
mov    %rbx,%rsi
call   1080 <fputc@plt>
mov    $0x5,%edi
mov    %rbx,%rsi
call   1080 <fputc@plt>
movb   $0xff,0x1(%rsp)
movb   $0xff,0x2(%rsp)
movb   $0xff,0x3(%rsp)
mov    %rbx,%rdi
call   1050 <rewind@plt>
lea    0x3(%rsp),%r13
mov    %rbx,%rdi
mov    %r12,%rsi
mov    %rbp,%rdx
mov    %rbp,%r12
mov    %r15,%rcx
mov    %r13,%r8
xor    %eax,%eax
call   10d0 <funpack@plt>
mov    %rax,%rdi
mov    $0x3,%esi
call   10b0 <size_ok@plt>
movsbl 0x1(%rsp),%edi
mov    $0x3,%esi
call   1030 <int_ok@plt>
movsbl 0x2(%rsp),%edi
mov    $0x4,%esi
call   1030 <int_ok@plt>
movsbl 0x3(%rsp),%edi
mov    $0x5,%esi
call   1030 <int_ok@plt>
lea    0xa11(%rip),%rbp
mov    %rbp,%rdi
call   10f0 <test@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    $0x6,%edi
mov    %rbx,%rsi
call   1080 <fputc@plt>
mov    $0x7,%edi
mov    %rbx,%rsi
call   1080 <fputc@plt>
mov    $0x8,%edi
mov    %rbx,%rsi
call   1080 <fputc@plt>
mov    $0x9,%edi
mov    %rbx,%rsi
call   1080 <fputc@plt>
movb   $0xff,0x1(%rsp)
movb   $0xff,0x2(%rsp)
movb   $0xff,0x3(%rsp)
movb   $0xff,0x4(%rsp)
mov    %rbx,%rdi
call   1050 <rewind@plt>
lea    0x4(%rsp),%r9
mov    %rbx,%rdi
mov    %rbp,%rsi
mov    %r12,%rdx
mov    %r15,%rcx
mov    %r13,%r8
xor    %eax,%eax
call   10d0 <funpack@plt>
mov    %rax,%rdi
mov    $0x4,%esi
call   10b0 <size_ok@plt>
movsbl 0x1(%rsp),%edi
mov    $0x6,%esi
call   1030 <int_ok@plt>
movsbl 0x2(%rsp),%edi
mov    $0x7,%esi
call   1030 <int_ok@plt>
movsbl 0x3(%rsp),%edi
mov    $0x8,%esi
call   1030 <int_ok@plt>
movsbl 0x4(%rsp),%edi
mov    $0x9,%esi
call   1030 <int_ok@plt>
lea    0x949(%rip),%rdi
call   10f0 <test@plt>
mov    %rbx,%rdi
call   1050 <rewind@plt>
mov    $0xe,%esi
mov    $0x1,%edx
mov    %r14,%rdi
mov    %rbx,%rcx
call   10e0 <fwrite@plt>
movb   $0xff,0x1(%rsp)
movb   $0xff,0x2(%rsp)
movb   $0xff,0x3(%rsp)
movb   $0xff,0x4(%rsp)
movb   $0xff,0xf(%rsp)
movb   $0xff,0xe(%rsp)
movb   $0xff,0xd(%rsp)
movb   $0xff,0xc(%rsp)
movb   $0xff,0xb(%rsp)
movb   $0xff,0xa(%rsp)
movb   $0xff,0x9(%rsp)
movb   $0xff,0x8(%rsp)
movb   $0xff,0x7(%rsp)
movb   $0xff,0x6(%rsp)
movb   $0xff,0x5(%rsp)
mov    %rbx,%rdi
call   1050 <rewind@plt>
sub    $0x8,%rsp
lea    0xd(%rsp),%rbp
lea    0xe(%rsp),%r10
lea    0xf(%rsp),%r11
lea    0x10(%rsp),%r15
lea    0x11(%rsp),%r14
lea    0x12(%rsp),%r13
lea    0x13(%rsp),%r12
mov    %rbx,%rdi
lea    0xb(%rsp),%r8
lea    0xc(%rsp),%r9
lea    0x899(%rip),%rsi
lea    0x9(%rsp),%rdx
lea    0xa(%rsp),%rcx
mov    $0x0,%eax
push   %rbp
push   %r10
push   %r11
push   %r15
push   %r14
push   %r13
push   %r12
lea    0x4c(%rsp),%rbp
push   %rbp
lea    0x55(%rsp),%rbp
push   %rbp
lea    0x5e(%rsp),%rbp
push   %rbp
lea    0x67(%rsp),%rbp
push   %rbp
call   10d0 <funpack@plt>
add    $0x60,%rsp
mov    %rax,%rdi
mov    $0xf,%esi
call   10b0 <size_ok@plt>
movsbl 0x1(%rsp),%edi
mov    $0x48,%esi
call   1030 <int_ok@plt>
movsbl 0x2(%rsp),%edi
mov    $0x65,%esi
call   1030 <int_ok@plt>
movsbl 0x3(%rsp),%edi
mov    $0x6c,%esi
call   1030 <int_ok@plt>
movsbl 0x4(%rsp),%edi
mov    $0x6c,%esi
call   1030 <int_ok@plt>
movsbl 0xf(%rsp),%edi
mov    $0x6f,%esi
call   1030 <int_ok@plt>
movsbl 0xe(%rsp),%edi
mov    $0x2c,%esi
call   1030 <int_ok@plt>
movsbl 0xd(%rsp),%edi
mov    $0x20,%esi
call   1030 <int_ok@plt>
movsbl 0xc(%rsp),%edi
mov    $0x77,%esi
call   1030 <int_ok@plt>
movsbl 0xb(%rsp),%edi
mov    $0x6f,%esi
call   1030 <int_ok@plt>
movsbl 0xa(%rsp),%edi
mov    $0x72,%esi
call   1030 <int_ok@plt>
movsbl 0x9(%rsp),%edi
mov    $0x6c,%esi
call   1030 <int_ok@plt>
movsbl 0x8(%rsp),%edi
mov    $0x64,%esi
call   1030 <int_ok@plt>
movsbl 0x7(%rsp),%edi
mov    $0x21,%esi
call   1030 <int_ok@plt>
movsbl 0x6(%rsp),%edi
mov    $0xa,%esi
call   1030 <int_ok@plt>
movsbl 0x5(%rsp),%edi
xor    %esi,%esi
call   1030 <int_ok@plt>
xor    %eax,%eax
add    $0x28,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [8 x i8] c"fpack()\00"
@.str.1 = [2 x i8] c"c\00"
@.str.2 = [3 x i8] c"cc\00"
@.str.3 = [6 x i8] c"c c c\00"
@.str.4 = [3 x i8] c"c4\00"
@.str.5 = [4 x i8] c"c15\00"
@.str.6 = [15 x i8] c"Hello, world!\0A\00"
@.str.7 = [10 x i8] c"funpack()\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32*
%3 = alloca i64
%4 = alloca [20 x i8]
%5 = alloca i8
%6 = alloca i8
%7 = alloca i8
%8 = alloca i8
%9 = alloca i8
%10 = alloca i8
%11 = alloca i8
%12 = alloca i8
%13 = alloca i8
%14 = alloca i8
%15 = alloca i8
%16 = alloca i8
%17 = alloca i8
%18 = alloca i8
%19 = alloca i8
store i32 0, i32* %1
%20 = call i32* (...) @tmpfile()
store i32* %20, i32** %2
%21 = call i32 @title(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0))
%22 = call i32 @test(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%23 = load i32*, i32** %2
%24 = call i32 @rewind(i32* %23)
%25 = load i32*, i32** %2
%26 = call i64 (i32*, i8*, i8, ...) @fpack(i32* %25, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0), i8 signext 0)
store i64 %26, i64* %3
%27 = load i64, i64* %3
%28 = call i32 @size_ok(i64 %27, i32 1)
%29 = load i32*, i32** %2
%30 = call i32 @rewind(i32* %29)
%31 = load i32*, i32** %2
%32 = call signext i8 @fgetc(i32* %31)
%33 = call i32 @int_ok(i8 signext %32, i8 signext 0)
%34 = call i32 @test(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%35 = load i32*, i32** %2
%36 = call i32 @rewind(i32* %35)
%37 = load i32*, i32** %2
%38 = call i64 (i32*, i8*, i8, ...) @fpack(i32* %37, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i8 signext 1, i32 2)
store i64 %38, i64* %3
%39 = load i64, i64* %3
%40 = call i32 @size_ok(i64 %39, i32 2)
%41 = load i32*, i32** %2
%42 = call i32 @rewind(i32* %41)
%43 = load i32*, i32** %2
%44 = call signext i8 @fgetc(i32* %43)
%45 = call i32 @int_ok(i8 signext %44, i8 signext 1)
%46 = load i32*, i32** %2
%47 = call signext i8 @fgetc(i32* %46)
%48 = call i32 @int_ok(i8 signext %47, i8 signext 2)
%49 = call i32 @test(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0))
%50 = load i32*, i32** %2
%51 = call i32 @rewind(i32* %50)
%52 = load i32*, i32** %2
%53 = call i64 (i32*, i8*, i8, ...) @fpack(i32* %52, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), i8 signext 3, i32 4, i32 5)
store i64 %53, i64* %3
%54 = load i64, i64* %3
%55 = call i32 @size_ok(i64 %54, i32 3)
%56 = load i32*, i32** %2
%57 = call i32 @rewind(i32* %56)
%58 = load i32*, i32** %2
%59 = call signext i8 @fgetc(i32* %58)
%60 = call i32 @int_ok(i8 signext %59, i8 signext 3)
%61 = load i32*, i32** %2
%62 = call signext i8 @fgetc(i32* %61)
%63 = call i32 @int_ok(i8 signext %62, i8 signext 4)
%64 = load i32*, i32** %2
%65 = call signext i8 @fgetc(i32* %64)
%66 = call i32 @int_ok(i8 signext %65, i8 signext 5)
%67 = call i32 @test(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0))
%68 = load i32*, i32** %2
%69 = call i32 @rewind(i32* %68)
%70 = load i32*, i32** %2
%71 = call i64 (i32*, i8*, i8, ...) @fpack(i32* %70, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0), i8 signext 6, i32 7, i32 8, i32 9)
store i64 %71, i64* %3
%72 = load i64, i64* %3
%73 = call i32 @size_ok(i64 %72, i32 4)
%74 = load i32*, i32** %2
%75 = call i32 @rewind(i32* %74)
%76 = load i32*, i32** %2
%77 = call signext i8 @fgetc(i32* %76)
%78 = call i32 @int_ok(i8 signext %77, i8 signext 6)
%79 = load i32*, i32** %2
%80 = call signext i8 @fgetc(i32* %79)
%81 = call i32 @int_ok(i8 signext %80, i8 signext 7)
%82 = load i32*, i32** %2
%83 = call signext i8 @fgetc(i32* %82)
%84 = call i32 @int_ok(i8 signext %83, i8 signext 8)
%85 = load i32*, i32** %2
%86 = call signext i8 @fgetc(i32* %85)
%87 = call i32 @int_ok(i8 signext %86, i8 signext 9)
%88 = call i32 @test(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0))
%89 = load i32*, i32** %2
%90 = call i32 @rewind(i32* %89)
%91 = load i32*, i32** %2
%92 = call i64 (i32*, i8*, i8, ...) @fpack(i32* %91, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0), i8 signext 72, i32 101, i32 108, i32 108, i32 111, i32 44, i32 32, i32 119, i32 111, i32 114, i32 108, i32 100, i32 33, i32 10, i32 0)
store i64 %92, i64* %3
%93 = load i64, i64* %3
%94 = call i32 @size_ok(i64 %93, i32 15)
%95 = load i32*, i32** %2
%96 = call i32 @rewind(i32* %95)
%97 = getelementptr inbounds [20 x i8], [20 x i8]* %4, i64 0, i64 0
%98 = load i64, i64* %3
%99 = load i32*, i32** %2
%100 = call i32 @fread(i8* %97, i32 1, i64 %98, i32* %99)
%101 = getelementptr inbounds [20 x i8], [20 x i8]* %4, i64 0, i64 0
%102 = call i32 @str_ok(i8* %101, i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.6, i64 0, i64 0))
%103 = call i32 @title(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.7, i64 0, i64 0))
%104 = call i32 @test(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%105 = load i32*, i32** %2
%106 = call i32 @rewind(i32* %105)
%107 = load i32*, i32** %2
%108 = call i32 @fputc(i32 0, i32* %107)
store i8 -1, i8* %5
%109 = load i32*, i32** %2
%110 = call i32 @rewind(i32* %109)
%111 = load i32*, i32** %2
%112 = call i64 (i32*, i8*, i8*, ...) @funpack(i32* %111, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0), i8* %5)
store i64 %112, i64* %3
%113 = load i64, i64* %3
%114 = call i32 @size_ok(i64 %113, i32 1)
%115 = load i8, i8* %5
%116 = call i32 @int_ok(i8 signext %115, i8 signext 0)
%117 = call i32 @test(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%118 = load i32*, i32** %2
%119 = call i32 @rewind(i32* %118)
%120 = load i32*, i32** %2
%121 = call i32 @fputc(i32 1, i32* %120)
%122 = load i32*, i32** %2
%123 = call i32 @fputc(i32 2, i32* %122)
store i8 -1, i8* %5
store i8 -1, i8* %6
%124 = load i32*, i32** %2
%125 = call i32 @rewind(i32* %124)
%126 = load i32*, i32** %2
%127 = call i64 (i32*, i8*, i8*, ...) @funpack(i32* %126, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i8* %5, i8* %6)
store i64 %127, i64* %3
%128 = load i64, i64* %3
%129 = call i32 @size_ok(i64 %128, i32 2)
%130 = load i8, i8* %5
%131 = call i32 @int_ok(i8 signext %130, i8 signext 1)
%132 = load i8, i8* %6
%133 = call i32 @int_ok(i8 signext %132, i8 signext 2)
%134 = call i32 @test(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0))
%135 = load i32*, i32** %2
%136 = call i32 @rewind(i32* %135)
%137 = load i32*, i32** %2
%138 = call i32 @fputc(i32 3, i32* %137)
%139 = load i32*, i32** %2
%140 = call i32 @fputc(i32 4, i32* %139)
%141 = load i32*, i32** %2
%142 = call i32 @fputc(i32 5, i32* %141)
store i8 -1, i8* %5
store i8 -1, i8* %6
store i8 -1, i8* %7
%143 = load i32*, i32** %2
%144 = call i32 @rewind(i32* %143)
%145 = load i32*, i32** %2
%146 = call i64 (i32*, i8*, i8*, ...) @funpack(i32* %145, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), i8* %5, i8* %6, i8* %7)
store i64 %146, i64* %3
%147 = load i64, i64* %3
%148 = call i32 @size_ok(i64 %147, i32 3)
%149 = load i8, i8* %5
%150 = call i32 @int_ok(i8 signext %149, i8 signext 3)
%151 = load i8, i8* %6
%152 = call i32 @int_ok(i8 signext %151, i8 signext 4)
%153 = load i8, i8* %7
%154 = call i32 @int_ok(i8 signext %153, i8 signext 5)
%155 = call i32 @test(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0))
%156 = load i32*, i32** %2
%157 = call i32 @rewind(i32* %156)
%158 = load i32*, i32** %2
%159 = call i32 @fputc(i32 6, i32* %158)
%160 = load i32*, i32** %2
%161 = call i32 @fputc(i32 7, i32* %160)
%162 = load i32*, i32** %2
%163 = call i32 @fputc(i32 8, i32* %162)
%164 = load i32*, i32** %2
%165 = call i32 @fputc(i32 9, i32* %164)
store i8 -1, i8* %5
store i8 -1, i8* %6
store i8 -1, i8* %7
store i8 -1, i8* %8
%166 = load i32*, i32** %2
%167 = call i32 @rewind(i32* %166)
%168 = load i32*, i32** %2
%169 = call i64 (i32*, i8*, i8*, ...) @funpack(i32* %168, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0), i8* %5, i8* %6, i8* %7, i8* %8)
store i64 %169, i64* %3
%170 = load i64, i64* %3
%171 = call i32 @size_ok(i64 %170, i32 4)
%172 = load i8, i8* %5
%173 = call i32 @int_ok(i8 signext %172, i8 signext 6)
%174 = load i8, i8* %6
%175 = call i32 @int_ok(i8 signext %174, i8 signext 7)
%176 = load i8, i8* %7
%177 = call i32 @int_ok(i8 signext %176, i8 signext 8)
%178 = load i8, i8* %8
%179 = call i32 @int_ok(i8 signext %178, i8 signext 9)
%180 = call i32 @test(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0))
%181 = load i32*, i32** %2
%182 = call i32 @rewind(i32* %181)
%183 = load i32*, i32** %2
%184 = call i32 @fputs(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.6, i64 0, i64 0), i32* %183)
store i8 -1, i8* %5
store i8 -1, i8* %6
store i8 -1, i8* %7
store i8 -1, i8* %8
store i8 -1, i8* %9
store i8 -1, i8* %10
store i8 -1, i8* %11
store i8 -1, i8* %12
store i8 -1, i8* %13
store i8 -1, i8* %14
store i8 -1, i8* %15
store i8 -1, i8* %16
store i8 -1, i8* %17
store i8 -1, i8* %18
store i8 -1, i8* %19
%185 = load i32*, i32** %2
%186 = call i32 @rewind(i32* %185)
%187 = load i32*, i32** %2
%188 = call i64 (i32*, i8*, i8*, ...) @funpack(i32* %187, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0), i8* %5, i8* %6, i8* %7, i8* %8, i8* %9, i8* %10, i8* %11, i8* %12, i8* %13, i8* %14, i8* %15, i8* %16, i8* %17, i8* %18, i8* %19)
store i64 %188, i64* %3
%189 = load i64, i64* %3
%190 = call i32 @size_ok(i64 %189, i32 15)
%191 = load i8, i8* %5
%192 = call i32 @int_ok(i8 signext %191, i8 signext 72)
%193 = load i8, i8* %6
%194 = call i32 @int_ok(i8 signext %193, i8 signext 101)
%195 = load i8, i8* %7
%196 = call i32 @int_ok(i8 signext %195, i8 signext 108)
%197 = load i8, i8* %8
%198 = call i32 @int_ok(i8 signext %197, i8 signext 108)
%199 = load i8, i8* %9
%200 = call i32 @int_ok(i8 signext %199, i8 signext 111)
%201 = load i8, i8* %10
%202 = call i32 @int_ok(i8 signext %201, i8 signext 44)
%203 = load i8, i8* %11
%204 = call i32 @int_ok(i8 signext %203, i8 signext 32)
%205 = load i8, i8* %12
%206 = call i32 @int_ok(i8 signext %205, i8 signext 119)
%207 = load i8, i8* %13
%208 = call i32 @int_ok(i8 signext %207, i8 signext 111)
%209 = load i8, i8* %14
%210 = call i32 @int_ok(i8 signext %209, i8 signext 114)
%211 = load i8, i8* %15
%212 = call i32 @int_ok(i8 signext %211, i8 signext 108)
%213 = load i8, i8* %16
%214 = call i32 @int_ok(i8 signext %213, i8 signext 100)
%215 = load i8, i8* %17
%216 = call i32 @int_ok(i8 signext %215, i8 signext 33)
%217 = load i8, i8* %18
%218 = call i32 @int_ok(i8 signext %217, i8 signext 10)
%219 = load i8, i8* %19
%220 = call i32 @int_ok(i8 signext %219, i8 signext 0)
ret i32 0
}

LLVM IR (-O2):
@.str = [8 x i8] c"fpack()\00"
@.str.1 = [2 x i8] c"c\00"
@.str.2 = [3 x i8] c"cc\00"
@.str.3 = [6 x i8] c"c c c\00"
@.str.4 = [3 x i8] c"c4\00"
@.str.5 = [4 x i8] c"c15\00"
@.str.6 = [15 x i8] c"Hello, world!\0A\00"
@.str.7 = [10 x i8] c"funpack()\00"
define i32 @main() {
%1 = alloca [20 x i8]
%2 = alloca i8
%3 = alloca i8
%4 = alloca i8
%5 = alloca i8
%6 = alloca i8
%7 = alloca i8
%8 = alloca i8
%9 = alloca i8
%10 = alloca i8
%11 = alloca i8
%12 = alloca i8
%13 = alloca i8
%14 = alloca i8
%15 = alloca i8
%16 = alloca i8
%17 = tail call i32* (...) @tmpfile()
%18 = tail call i32 @title(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0))
%19 = tail call i32 @test(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%20 = tail call i32 @rewind(i32* %17)
%21 = tail call i64 (i32*, i8*, i8, ...) @fpack(i32* %17, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0), i8 signext 0)
%22 = tail call i32 @size_ok(i64 %21, i32 1)
%23 = tail call i32 @rewind(i32* %17)
%24 = tail call signext i8 @fgetc(i32* %17)
%25 = tail call i32 @int_ok(i8 signext %24, i8 signext 0)
%26 = tail call i32 @test(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%27 = tail call i32 @rewind(i32* %17)
%28 = tail call i64 (i32*, i8*, i8, ...) @fpack(i32* %17, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i8 signext 1, i32 2)
%29 = tail call i32 @size_ok(i64 %28, i32 2)
%30 = tail call i32 @rewind(i32* %17)
%31 = tail call signext i8 @fgetc(i32* %17)
%32 = tail call i32 @int_ok(i8 signext %31, i8 signext 1)
%33 = tail call signext i8 @fgetc(i32* %17)
%34 = tail call i32 @int_ok(i8 signext %33, i8 signext 2)
%35 = tail call i32 @test(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0))
%36 = tail call i32 @rewind(i32* %17)
%37 = tail call i64 (i32*, i8*, i8, ...) @fpack(i32* %17, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), i8 signext 3, i32 4, i32 5)
%38 = tail call i32 @size_ok(i64 %37, i32 3)
%39 = tail call i32 @rewind(i32* %17)
%40 = tail call signext i8 @fgetc(i32* %17)
%41 = tail call i32 @int_ok(i8 signext %40, i8 signext 3)
%42 = tail call signext i8 @fgetc(i32* %17)
%43 = tail call i32 @int_ok(i8 signext %42, i8 signext 4)
%44 = tail call signext i8 @fgetc(i32* %17)
%45 = tail call i32 @int_ok(i8 signext %44, i8 signext 5)
%46 = tail call i32 @test(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0))
%47 = tail call i32 @rewind(i32* %17)
%48 = tail call i64 (i32*, i8*, i8, ...) @fpack(i32* %17, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0), i8 signext 6, i32 7, i32 8, i32 9)
%49 = tail call i32 @size_ok(i64 %48, i32 4)
%50 = tail call i32 @rewind(i32* %17)
%51 = tail call signext i8 @fgetc(i32* %17)
%52 = tail call i32 @int_ok(i8 signext %51, i8 signext 6)
%53 = tail call signext i8 @fgetc(i32* %17)
%54 = tail call i32 @int_ok(i8 signext %53, i8 signext 7)
%55 = tail call signext i8 @fgetc(i32* %17)
%56 = tail call i32 @int_ok(i8 signext %55, i8 signext 8)
%57 = tail call signext i8 @fgetc(i32* %17)
%58 = tail call i32 @int_ok(i8 signext %57, i8 signext 9)
%59 = tail call i32 @test(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0))
%60 = tail call i32 @rewind(i32* %17)
%61 = tail call i64 (i32*, i8*, i8, ...) @fpack(i32* %17, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0), i8 signext 72, i32 101, i32 108, i32 108, i32 111, i32 44, i32 32, i32 119, i32 111, i32 114, i32 108, i32 100, i32 33, i32 10, i32 0)
%62 = tail call i32 @size_ok(i64 %61, i32 15)
%63 = tail call i32 @rewind(i32* %17)
%64 = getelementptr inbounds [20 x i8], [20 x i8]* %1, i64 0, i64 0
%65 = call i32 @fread(i8* %64, i32 1, i64 %61, i32* %17)
%66 = call i32 @str_ok(i8* %64, i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.6, i64 0, i64 0))
%67 = call i32 @title(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.7, i64 0, i64 0))
%68 = call i32 @test(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%69 = call i32 @rewind(i32* %17)
%70 = call i32 @fputc(i32 0, i32* %17)
store i8 -1, i8* %2
%71 = call i32 @rewind(i32* %17)
%72 = call i64 (i32*, i8*, i8*, ...) @funpack(i32* %17, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0), i8* %2)
%73 = call i32 @size_ok(i64 %72, i32 1)
%74 = load i8, i8* %2
%75 = call i32 @int_ok(i8 signext %74, i8 signext 0)
%76 = call i32 @test(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%77 = call i32 @rewind(i32* %17)
%78 = call i32 @fputc(i32 1, i32* %17)
%79 = call i32 @fputc(i32 2, i32* %17)
store i8 -1, i8* %2
store i8 -1, i8* %3
%80 = call i32 @rewind(i32* %17)
%81 = call i64 (i32*, i8*, i8*, ...) @funpack(i32* %17, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i8* %2, i8* %3)
%82 = call i32 @size_ok(i64 %81, i32 2)
%83 = load i8, i8* %2
%84 = call i32 @int_ok(i8 signext %83, i8 signext 1)
%85 = load i8, i8* %3
%86 = call i32 @int_ok(i8 signext %85, i8 signext 2)
%87 = call i32 @test(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0))
%88 = call i32 @rewind(i32* %17)
%89 = call i32 @fputc(i32 3, i32* %17)
%90 = call i32 @fputc(i32 4, i32* %17)
%91 = call i32 @fputc(i32 5, i32* %17)
store i8 -1, i8* %2
store i8 -1, i8* %3
store i8 -1, i8* %4
%92 = call i32 @rewind(i32* %17)
%93 = call i64 (i32*, i8*, i8*, ...) @funpack(i32* %17, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), i8* %2, i8* %3, i8* %4)
%94 = call i32 @size_ok(i64 %93, i32 3)
%95 = load i8, i8* %2
%96 = call i32 @int_ok(i8 signext %95, i8 signext 3)
%97 = load i8, i8* %3
%98 = call i32 @int_ok(i8 signext %97, i8 signext 4)
%99 = load i8, i8* %4
%100 = call i32 @int_ok(i8 signext %99, i8 signext 5)
%101 = call i32 @test(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0))
%102 = call i32 @rewind(i32* %17)
%103 = call i32 @fputc(i32 6, i32* %17)
%104 = call i32 @fputc(i32 7, i32* %17)
%105 = call i32 @fputc(i32 8, i32* %17)
%106 = call i32 @fputc(i32 9, i32* %17)
store i8 -1, i8* %2
store i8 -1, i8* %3
store i8 -1, i8* %4
store i8 -1, i8* %5
%107 = call i32 @rewind(i32* %17)
%108 = call i64 (i32*, i8*, i8*, ...) @funpack(i32* %17, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0), i8* %2, i8* %3, i8* %4, i8* %5)
%109 = call i32 @size_ok(i64 %108, i32 4)
%110 = load i8, i8* %2
%111 = call i32 @int_ok(i8 signext %110, i8 signext 6)
%112 = load i8, i8* %3
%113 = call i32 @int_ok(i8 signext %112, i8 signext 7)
%114 = load i8, i8* %4
%115 = call i32 @int_ok(i8 signext %114, i8 signext 8)
%116 = load i8, i8* %5
%117 = call i32 @int_ok(i8 signext %116, i8 signext 9)
%118 = call i32 @test(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0))
%119 = call i32 @rewind(i32* %17)
%120 = call i64 @fwrite(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.6, i64 0, i64 0), i64 14, i64 1, i32* %17)
store i8 -1, i8* %2
store i8 -1, i8* %3
store i8 -1, i8* %4
store i8 -1, i8* %5
store i8 -1, i8* %6
store i8 -1, i8* %7
store i8 -1, i8* %8
store i8 -1, i8* %9
store i8 -1, i8* %10
store i8 -1, i8* %11
store i8 -1, i8* %12
store i8 -1, i8* %13
store i8 -1, i8* %14
store i8 -1, i8* %15
store i8 -1, i8* %16
%121 = call i32 @rewind(i32* %17)
%122 = call i64 (i32*, i8*, i8*, ...) @funpack(i32* %17, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0), i8* %2, i8* %3, i8* %4, i8* %5, i8* %6, i8* %7, i8* %8, i8* %9, i8* %10, i8* %11, i8* %12, i8* %13, i8* %14, i8* %15, i8* %16)
%123 = call i32 @size_ok(i64 %122, i32 15)
%124 = load i8, i8* %2
%125 = call i32 @int_ok(i8 signext %124, i8 signext 72)
%126 = load i8, i8* %3
%127 = call i32 @int_ok(i8 signext %126, i8 signext 101)
%128 = load i8, i8* %4
%129 = call i32 @int_ok(i8 signext %128, i8 signext 108)
%130 = load i8, i8* %5
%131 = call i32 @int_ok(i8 signext %130, i8 signext 108)
%132 = load i8, i8* %6
%133 = call i32 @int_ok(i8 signext %132, i8 signext 111)
%134 = load i8, i8* %7
%135 = call i32 @int_ok(i8 signext %134, i8 signext 44)
%136 = load i8, i8* %8
%137 = call i32 @int_ok(i8 signext %136, i8 signext 32)
%138 = load i8, i8* %9
%139 = call i32 @int_ok(i8 signext %138, i8 signext 119)
%140 = load i8, i8* %10
%141 = call i32 @int_ok(i8 signext %140, i8 signext 111)
%142 = load i8, i8* %11
%143 = call i32 @int_ok(i8 signext %142, i8 signext 114)
%144 = load i8, i8* %12
%145 = call i32 @int_ok(i8 signext %144, i8 signext 108)
%146 = load i8, i8* %13
%147 = call i32 @int_ok(i8 signext %146, i8 signext 100)
%148 = load i8, i8* %14
%149 = call i32 @int_ok(i8 signext %148, i8 signext 33)
%150 = load i8, i8* %15
%151 = call i32 @int_ok(i8 signext %150, i8 signext 10)
%152 = load i8, i8* %16
%153 = call i32 @int_ok(i8 signext %152, i8 signext 0)
ret i32 0
}