#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 main() {
  printf("\n");
  printf("Hello, world! 1\n");
  printf("Hello, world! %d\n", 2);
  printf("\n");
  printf("abcdefg\aaaa\n");
  printf("abcdefg\baaa\n");
  printf("abcdefg\raaa\n");
  printf("abcdefg\taaa\n");
  printf("abcde\taaa\n");
  printf("abcdefg\\aaa\n");
  printf("\n");
  printf("%i\n", -1024);
  printf("%o\n", 1024);
  printf("%o\n", -1024);
  printf("%u\n", -1024);
  printf("%e\n", 1024.12);
  printf("%g\n", 1024.12);
  printf("%g\n", 1024000000000.12);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xef9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xedc(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xedf(%rip),%rdi
mov    $0x2,%esi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeca(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xed0(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xecf(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xece(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xecd(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xecc(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xec9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe68(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeba(%rip),%rdi
mov    $0xfffffc00,%esi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xeab(%rip),%rdi
mov    $0x400,%esi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe98(%rip),%rdi
mov    $0xfffffc00,%esi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe89(%rip),%rdi
mov    $0xfffffc00,%esi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe7a(%rip),%rdi
movsd  0xdef(%rip),%xmm0
mov    $0x1,%al
call   1030 <printf@plt>
lea    0xe68(%rip),%rdi
movsd  0xdd9(%rip),%xmm0
mov    $0x1,%al
call   1030 <printf@plt>
lea    0xe52(%rip),%rdi
movsd  0xdbb(%rip),%xmm0
mov    $0x1,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xef4(%rip),%rdi
call   1040 <puts@plt>
lea    0xec2(%rip),%rdi
mov    $0x2,%esi
xor    %eax,%eax
call   1050 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xedb(%rip),%rdi
call   1040 <puts@plt>
lea    0xedb(%rip),%rdi
call   1040 <puts@plt>
lea    0xedb(%rip),%rdi
call   1040 <puts@plt>
lea    0xedb(%rip),%rdi
call   1040 <puts@plt>
lea    0xedb(%rip),%rdi
call   1040 <puts@plt>
lea    0xed9(%rip),%rdi
call   1040 <puts@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xe65(%rip),%rdi
mov    $0xfffffc00,%esi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xe56(%rip),%rbx
mov    %rbx,%rdi
mov    $0x400,%esi
xor    %eax,%eax
call   1050 <printf@plt>
mov    %rbx,%rdi
mov    $0xfffffc00,%esi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xe35(%rip),%rdi
mov    $0xfffffc00,%esi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xe26(%rip),%rdi
movsd  0xdf0(%rip),%xmm0
mov    $0x1,%al
call   1050 <printf@plt>
lea    0xe14(%rip),%rbx
mov    %rbx,%rdi
movsd  0xdd7(%rip),%xmm0
mov    $0x1,%al
call   1050 <printf@plt>
movsd  0xdd0(%rip),%xmm0
mov    %rbx,%rdi
mov    $0x1,%al
call   1050 <printf@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [2 x i8] c"\0A\00"
@.str.1 = [17 x i8] c"Hello, world! 1\0A\00"
@.str.2 = [18 x i8] c"Hello, world! %d\0A\00"
@.str.3 = [13 x i8] c"abcdefg\07aaa\0A\00"
@.str.4 = [13 x i8] c"abcdefg\08aaa\0A\00"
@.str.5 = [13 x i8] c"abcdefg\0Daaa\0A\00"
@.str.6 = [13 x i8] c"abcdefg\09aaa\0A\00"
@.str.7 = [11 x i8] c"abcde\09aaa\0A\00"
@.str.8 = [13 x i8] c"abcdefg\\aaa\0A\00"
@.str.9 = [4 x i8] c"%i\0A\00"
@.str.10 = [4 x i8] c"%o\0A\00"
@.str.11 = [4 x i8] c"%u\0A\00"
@.str.12 = [4 x i8] c"%e\0A\00"
@.str.13 = [4 x i8] c"%g\0A\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%3 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0))
%4 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0), i32 2)
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%6 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0))
%7 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0))
%8 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.5, i64 0, i64 0))
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.6, i64 0, i64 0))
%10 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.7, i64 0, i64 0))
%11 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.8, i64 0, i64 0))
%12 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%13 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.9, i64 0, i64 0), i32 -1024)
%14 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 1024)
%15 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 -1024)
%16 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0), i32 -1024)
%17 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.12, i64 0, i64 0), double 1.024120e+03)
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.13, i64 0, i64 0), double 1.024120e+03)
%19 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.13, i64 0, i64 0), double 0x426DCD65000003D7)
ret i32 0
}

LLVM IR (-O2):
@.str.2 = [18 x i8] c"Hello, world! %d\0A\00"
@.str.9 = [4 x i8] c"%i\0A\00"
@.str.10 = [4 x i8] c"%o\0A\00"
@.str.11 = [4 x i8] c"%u\0A\00"
@.str.12 = [4 x i8] c"%e\0A\00"
@.str.13 = [4 x i8] c"%g\0A\00"
@str = [16 x i8] c"Hello, world! 1\00"
@str.14 = [12 x i8] c"abcdefg\07aaa\00"
@str.15 = [12 x i8] c"abcdefg\08aaa\00"
@str.16 = [12 x i8] c"abcdefg\0Daaa\00"
@str.17 = [12 x i8] c"abcdefg\09aaa\00"
@str.18 = [10 x i8] c"abcde\09aaa\00"
@str.19 = [12 x i8] c"abcdefg\\aaa\00"
define i32 @main() {
%1 = tail call i32 @putchar(i32 10)
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @str, i64 0, i64 0))
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0), i32 2)
%4 = tail call i32 @putchar(i32 10)
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.14, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.15, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.16, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.17, i64 0, i64 0))
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str.18, i64 0, i64 0))
%10 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.19, i64 0, i64 0))
%11 = tail call i32 @putchar(i32 10)
%12 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.9, i64 0, i64 0), i32 -1024)
%13 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 1024)
%14 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 -1024)
%15 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0), i32 -1024)
%16 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.12, i64 0, i64 0), double 1.024120e+03)
%17 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.13, i64 0, i64 0), double 1.024120e+03)
%18 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.13, i64 0, i64 0), double 0x426DCD65000003D7)
ret i32 0
}