#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 */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, ...);
void printLicence(FILE *stream) {
  fprintf(stream, "ram emulator %d.%d \n", 0, 1);
  fprintf(stream, "Copyright (C) 2014 Noel Kuntze <noel@familie-kuntze.de>\n");
  fprintf(
      stream,
      "Licence GLPv3+: GNU GPL version 3 <http://gnu.org/licenses/gpl.html>.");
  fprintf(
      stream,
      "This is free software: You are free to change and redistribute it.\n");
  fprintf(stream, "There is NO WARRANTY, to the extent permitted by law.\n");
}


x86 assembly (clang, -O0):
<printLicence>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
lea    0xed9(%rip),%rsi
xor    %edx,%edx
mov    $0x1,%ecx
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x8(%rbp),%rdi
lea    0xed5(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x8(%rbp),%rdi
lea    0xefc(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x8(%rbp),%rdi
lea    0xf30(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x8(%rbp),%rdi
lea    0xf62(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<printLicence>:
push   %rbx
mov    %rdi,%rbx
lea    0xed5(%rip),%rsi
xor    %edx,%edx
mov    $0x1,%ecx
xor    %eax,%eax
call   1030 <fprintf@plt>
lea    0xed5(%rip),%rdi
mov    $0x38,%esi
mov    $0x1,%edx
mov    %rbx,%rcx
call   1040 <fwrite@plt>
lea    0xef5(%rip),%rdi
mov    $0x45,%esi
mov    $0x1,%edx
mov    %rbx,%rcx
call   1040 <fwrite@plt>
lea    0xf22(%rip),%rdi
mov    $0x43,%esi
mov    $0x1,%edx
mov    %rbx,%rcx
call   1040 <fwrite@plt>
lea    0xf4d(%rip),%rdi
mov    $0x36,%esi
mov    $0x1,%edx
mov    %rbx,%rcx
pop    %rbx
jmp    1040 <fwrite@plt>

LLVM IR (-O0):
@.str = [21 x i8] c"ram emulator %d.%d \0A\00"
@.str.1 = [57 x i8] c"Copyright (C) 2014 Noel Kuntze <noel@familie-kuntze.de>\0A\00"
@.str.2 = [70 x i8] c"Licence GLPv3+: GNU GPL version 3 <http://gnu.org/licenses/gpl.html>.\00"
@.str.3 = [68 x i8] c"This is free software: You are free to change and redistribute it.\0A\00"
@.str.4 = [55 x i8] c"There is NO WARRANTY, to the extent permitted by law.\0A\00"
define void @printLicence(i32* %0) {
%2 = alloca i32*
store i32* %0, i32** %2
%3 = load i32*, i32** %2
%4 = call i32 (i32*, i8*, ...) @fprintf(i32* %3, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), i32 0, i32 1)
%5 = load i32*, i32** %2
%6 = call i32 (i32*, i8*, ...) @fprintf(i32* %5, i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str.1, i64 0, i64 0))
%7 = load i32*, i32** %2
%8 = call i32 (i32*, i8*, ...) @fprintf(i32* %7, i8* getelementptr inbounds ([70 x i8], [70 x i8]* @.str.2, i64 0, i64 0))
%9 = load i32*, i32** %2
%10 = call i32 (i32*, i8*, ...) @fprintf(i32* %9, i8* getelementptr inbounds ([68 x i8], [68 x i8]* @.str.3, i64 0, i64 0))
%11 = load i32*, i32** %2
%12 = call i32 (i32*, i8*, ...) @fprintf(i32* %11, i8* getelementptr inbounds ([55 x i8], [55 x i8]* @.str.4, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [21 x i8] c"ram emulator %d.%d \0A\00"
@.str.1 = [57 x i8] c"Copyright (C) 2014 Noel Kuntze <noel@familie-kuntze.de>\0A\00"
@.str.2 = [70 x i8] c"Licence GLPv3+: GNU GPL version 3 <http://gnu.org/licenses/gpl.html>.\00"
@.str.3 = [68 x i8] c"This is free software: You are free to change and redistribute it.\0A\00"
@.str.4 = [55 x i8] c"There is NO WARRANTY, to the extent permitted by law.\0A\00"
define void @printLicence(i32* nocapture %0) {
%2 = tail call i32 (i32*, i8*, ...) @fprintf(i32* %0, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), i32 0, i32 1)
%3 = tail call i64 @fwrite(i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str.1, i64 0, i64 0), i64 56, i64 1, i32* %0)
%4 = tail call i64 @fwrite(i8* getelementptr inbounds ([70 x i8], [70 x i8]* @.str.2, i64 0, i64 0), i64 69, i64 1, i32* %0)
%5 = tail call i64 @fwrite(i8* getelementptr inbounds ([68 x i8], [68 x i8]* @.str.3, i64 0, i64 0), i64 67, i64 1, i32* %0)
%6 = tail call i64 @fwrite(i8* getelementptr inbounds ([55 x i8], [55 x i8]* @.str.4, i64 0, i64 0), i64 54, i64 1, i32* %0)
ret void
}