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

/* Variables and functions */
int /*<<< orphan*/ ctime(int /*<<< orphan*/ *);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ strcpy(char *, int /*<<< orphan*/);
int /*<<< orphan*/ time(int /*<<< orphan*/ *);
void print_header(void) {
  char s1[30];
  time_t now;
  printf("%s_%s of %s (%s).\n", "vcddiff", "0.04c-veripool", "07/28/2004",
         "Linux-ELF");
  printf("Copyright (c) 2002-2004 Pragmatic C Software Corp.\n");
  printf("All Rights reserved.  Licensed under the GNU General Public License "
         "(GPL).\n");
  printf("See the 'COPYING' file for details.  NO WARRANTY provided.\n");
  time(&now);
  strcpy(s1, ctime(&now));
  s1[24] = '\0';
  printf("Today is %s.\n\n", s1);
}


x86 assembly (clang, -O0):
<print_header>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
lea    0xeb1(%rip),%rdi
lea    0xebd(%rip),%rsi
lea    0xebe(%rip),%rdx
lea    0xec6(%rip),%rcx
lea    0xeca(%rip),%r8
mov    $0x0,%al
call   1050 <printf@plt>
lea    0xec6(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
lea    0xeec(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
lea    0xf2a(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
lea    -0x24(%rbp),%rdi
call   1060 <time@plt>
lea    -0x20(%rbp),%rax
mov    %rax,-0x30(%rbp)
lea    -0x24(%rbp),%rdi
call   1040 <ctime@plt>
mov    -0x30(%rbp),%rdi
mov    %eax,%esi
call   1030 <strcpy@plt>
movb   $0x0,-0x8(%rbp)
lea    -0x20(%rbp),%rsi
lea    0xf2b(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_header>:
push   %rbx
sub    $0x30,%rsp
lea    0xea4(%rip),%rdi
lea    0xeb0(%rip),%rsi
lea    0xeb1(%rip),%rdx
lea    0xeb9(%rip),%rcx
lea    0xebd(%rip),%r8
xor    %eax,%eax
call   1060 <printf@plt>
lea    0xec8(%rip),%rdi
call   1040 <puts@plt>
lea    0xeef(%rip),%rdi
call   1040 <puts@plt>
lea    0xf2e(%rip),%rdi
call   1040 <puts@plt>
lea    0xc(%rsp),%rbx
mov    %rbx,%rdi
call   1070 <time@plt>
mov    %rbx,%rdi
call   1050 <ctime@plt>
lea    0x10(%rsp),%rbx
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <strcpy@plt>
movb   $0x0,0x28(%rsp)
lea    0xe6c(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1060 <printf@plt>
add    $0x30,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [19 x i8] c"%s_%s of %s (%s).\0A\00"
@.str.1 = [8 x i8] c"vcddiff\00"
@.str.2 = [15 x i8] c"0.04c-veripool\00"
@.str.3 = [11 x i8] c"07/28/2004\00"
@.str.4 = [10 x i8] c"Linux-ELF\00"
@.str.5 = [52 x i8] c"Copyright (c) 2002-2004 Pragmatic C Software Corp.\0A\00"
@.str.6 = [76 x i8] c"All Rights reserved. Licensed under the GNU General Public License (GPL).\0A\00"
@.str.7 = [60 x i8] c"See the 'COPYING' file for details. NO WARRANTY provided.\0A\00"
@.str.8 = [15 x i8] c"Today is %s.\0A\0A\00"
define void @print_header() {
%1 = alloca [30 x i8]
%2 = alloca i32
%3 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.4, i64 0, i64 0))
%4 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([52 x i8], [52 x i8]* @.str.5, i64 0, i64 0))
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([76 x i8], [76 x i8]* @.str.6, i64 0, i64 0))
%6 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @.str.7, i64 0, i64 0))
%7 = call i32 @time(i32* %2)
%8 = getelementptr inbounds [30 x i8], [30 x i8]* %1, i64 0, i64 0
%9 = call i32 @ctime(i32* %2)
%10 = call i32 @strcpy(i8* %8, i32 %9)
%11 = getelementptr inbounds [30 x i8], [30 x i8]* %1, i64 0, i64 24
store i8 0, i8* %11
%12 = getelementptr inbounds [30 x i8], [30 x i8]* %1, i64 0, i64 0
%13 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.8, i64 0, i64 0), i8* %12)
ret void
}

LLVM IR (-O2):
@.str = [19 x i8] c"%s_%s of %s (%s).\0A\00"
@.str.1 = [8 x i8] c"vcddiff\00"
@.str.2 = [15 x i8] c"0.04c-veripool\00"
@.str.3 = [11 x i8] c"07/28/2004\00"
@.str.4 = [10 x i8] c"Linux-ELF\00"
@.str.8 = [15 x i8] c"Today is %s.\0A\0A\00"
@str = [51 x i8] c"Copyright (c) 2002-2004 Pragmatic C Software Corp.\00"
@str.9 = [75 x i8] c"All Rights reserved. Licensed under the GNU General Public License (GPL).\00"
@str.10 = [59 x i8] c"See the 'COPYING' file for details. NO WARRANTY provided.\00"
define void @print_header() {
%1 = alloca [30 x i8]
%2 = alloca i32
%3 = getelementptr inbounds [30 x i8], [30 x i8]* %1, i64 0, i64 0
%4 = bitcast i32* %2 to i8*
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.4, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([51 x i8], [51 x i8]* @str, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([75 x i8], [75 x i8]* @str.9, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([59 x i8], [59 x i8]* @str.10, i64 0, i64 0))
%9 = call i32 @time(i32* %2)
%10 = call i32 @ctime(i32* %2)
%11 = call i32 @strcpy(i8* %3, i32 %10)
%12 = getelementptr inbounds [30 x i8], [30 x i8]* %1, i64 0, i64 24
store i8 0, i8* %12
%13 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str.8, i64 0, i64 0), i8* %3)
ret void
}