#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;
struct tm {
  int tm_hour;
  int tm_min;
  int tm_sec;
};
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
int /*<<< orphan*/ fflush(int /*<<< orphan*/);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, ...);
struct tm *localtime(int /*<<< orphan*/ *);
int /*<<< orphan*/ printf(char *, ...);
int rand();
int /*<<< orphan*/ sleep(int);
int /*<<< orphan*/ srand(int /*<<< orphan*/);
int /*<<< orphan*/ stdout;
int /*<<< orphan*/ system(char *);
int /*<<< orphan*/ time(int /*<<< orphan*/ *);
int main(void) {
  FILE *history = NULL;
  history = fopen("/home/pierre/Documents/doc/history.txt", "a");
  system("echo $(date +%D) >> /home/pierre/Documents/doc/history.txt");
  system("gcc -o heure /home/pierre/Documents/doc/heure.c;./heure");
  fprintf(history, " dynamique \n-----------\n");
  fclose(history);
  system("clear");
  FILE *heure = NULL;
  heure = fopen("heure", "w");
  srand(time(NULL));
  int random = 0;
  random = (rand() % (0, 3));
  while (1) {
    time_t secondes;
    struct tm instant;
    time(&secondes);
    instant = *localtime(&secondes);
    int h = 0;
    int m = 0;
    int s = 0;
    int i = 0;
    int s1 = 0;
    int m1 = 0;
    int h1 = 0;
    int j = 0;
    int k = 0;
    int l = 0;
    h = instant.tm_hour;
    m = instant.tm_min;
    s = instant.tm_sec;
    while (j < 10) {
      printf("\n");
      j++;
    }
    while (k < 35) {
      printf(" ");
      k++;
    }
    if (h < 10) {
      printf("%d", h1);
      fprintf(heure, "%d", h1);
    }
    printf("%d:", h);
    fprintf(heure, "%d:", h);
    if (m < 10) {
      printf("%d", m1);
      fprintf(heure, "%d", m1);
    }
    printf("%d:", m);
    fprintf(heure, "%d:", m);
    if (s < 10) {
      printf("%d", s1);
      fprintf(heure, "%d", s1);
    }
    printf("%d\n", s);
    fprintf(heure, "%d\n", s);
    while (l < 10) {
      printf("\n");
      l++;
    }
    while (m < 15) {
      printf(" ");
      m++;
    }
    printf("l'heure va s'actualiser dans quelques secondes");
    while (i < 10) {
      printf(".");
      fflush(stdout);
      sleep(1);
      i++;
    }
    sleep(1);
    system("clear");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
movl   $0x0,-0x4(%rbp)
movq   $0x0,-0x10(%rbp)
lea    0xe48(%rip),%rdi
lea    0xe2b(%rip),%rsi
call   10b0 <fopen@plt>
mov    %rax,-0x10(%rbp)
lea    0xe1d(%rip),%rdi
call   1050 <system@plt>
lea    0xe4c(%rip),%rdi
call   1050 <system@plt>
mov    -0x10(%rbp),%rdi
lea    0xe74(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
mov    -0x10(%rbp),%rdi
call   1040 <fclose@plt>
lea    0xe76(%rip),%rdi
call   1050 <system@plt>
movq   $0x0,-0x18(%rbp)
lea    0xe43(%rip),%rdi
lea    0xe61(%rip),%rsi
call   10b0 <fopen@plt>
mov    %rax,-0x18(%rbp)
xor    %eax,%eax
mov    %eax,%edi
call   1090 <time@plt>
mov    %eax,%edi
call   1070 <srand@plt>
movl   $0x0,-0x1c(%rbp)
mov    $0x0,%al
call   10d0 <rand@plt>
mov    $0x3,%ecx
cltd
idiv   %ecx
mov    %edx,-0x1c(%rbp)
lea    -0x20(%rbp),%rdi
call   1090 <time@plt>
lea    -0x20(%rbp),%rdi
call   1030 <localtime@plt>
mov    (%rax),%rcx
mov    %rcx,-0x30(%rbp)
mov    0x8(%rax),%eax
mov    %eax,-0x28(%rbp)
movl   $0x0,-0x34(%rbp)
movl   $0x0,-0x38(%rbp)
movl   $0x0,-0x3c(%rbp)
movl   $0x0,-0x40(%rbp)
movl   $0x0,-0x44(%rbp)
movl   $0x0,-0x48(%rbp)
movl   $0x0,-0x4c(%rbp)
movl   $0x0,-0x50(%rbp)
movl   $0x0,-0x54(%rbp)
movl   $0x0,-0x58(%rbp)
mov    -0x30(%rbp),%eax
mov    %eax,-0x34(%rbp)
mov    -0x2c(%rbp),%eax
mov    %eax,-0x38(%rbp)
mov    -0x28(%rbp),%eax
mov    %eax,-0x3c(%rbp)
cmpl   $0xa,-0x50(%rbp)
jge    1302 <main+0x152>
lea    0xd9f(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x50(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x50(%rbp)
jmp    12dc <main+0x12c>
jmp    1307 <main+0x157>
cmpl   $0x23,-0x54(%rbp)
jge    132d <main+0x17d>
lea    0xd7e(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x54(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x54(%rbp)
jmp    1307 <main+0x157>
cmpl   $0xa,-0x34(%rbp)
jge    135d <main+0x1ad>
mov    -0x4c(%rbp),%esi
lea    0xd57(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x18(%rbp),%rdi
mov    -0x4c(%rbp),%edx
lea    0xd42(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
mov    -0x34(%rbp),%esi
lea    0xd34(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x18(%rbp),%rdi
mov    -0x34(%rbp),%edx
lea    0xd1f(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
cmpl   $0xa,-0x38(%rbp)
jge    13b3 <main+0x203>
mov    -0x48(%rbp),%esi
lea    0xd01(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x18(%rbp),%rdi
mov    -0x48(%rbp),%edx
lea    0xcec(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
mov    -0x38(%rbp),%esi
lea    0xcde(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x18(%rbp),%rdi
mov    -0x38(%rbp),%edx
lea    0xcc9(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
cmpl   $0xa,-0x3c(%rbp)
jge    1409 <main+0x259>
mov    -0x44(%rbp),%esi
lea    0xcab(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x18(%rbp),%rdi
mov    -0x44(%rbp),%edx
lea    0xc96(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
mov    -0x3c(%rbp),%esi
lea    0xc8c(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x18(%rbp),%rdi
mov    -0x3c(%rbp),%edx
lea    0xc77(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
cmpl   $0xa,-0x58(%rbp)
jge    1455 <main+0x2a5>
lea    0xc4c(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x58(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x58(%rbp)
jmp    142f <main+0x27f>
jmp    145a <main+0x2aa>
cmpl   $0xf,-0x38(%rbp)
jge    1480 <main+0x2d0>
lea    0xc2b(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    145a <main+0x2aa>
lea    0xc1c(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
cmpl   $0xa,-0x40(%rbp)
jge    14cc <main+0x31c>
lea    0xc33(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    0x2b33(%rip),%rax
mov    (%rax),%edi
call   10a0 <fflush@plt>
mov    $0x1,%edi
call   10c0 <sleep@plt>
mov    -0x40(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x40(%rbp)
jmp    148e <main+0x2de>
mov    $0x1,%edi
call   10c0 <sleep@plt>
lea    0xbb1(%rip),%rdi
call   1050 <system@plt>
jmp    1265 <main+0xb5>

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
lea    0xe31(%rip),%rdi
lea    0xe14(%rip),%rsi
call   10c0 <fopen@plt>
mov    %rax,%rbx
lea    0xe07(%rip),%rdi
call   1060 <system@plt>
lea    0xe36(%rip),%rdi
call   1060 <system@plt>
lea    0xe62(%rip),%rdi
mov    $0x18,%esi
mov    $0x1,%edx
mov    %rbx,%rcx
call   10d0 <fwrite@plt>
mov    %rbx,%rdi
call   1050 <fclose@plt>
lea    0xe5a(%rip),%rdi
call   1060 <system@plt>
lea    0xe2f(%rip),%rdi
lea    0xe4d(%rip),%rsi
call   10c0 <fopen@plt>
mov    %rax,%r13
xor    %edi,%edi
call   10a0 <time@plt>
mov    %eax,%edi
call   1080 <srand@plt>
xor    %eax,%eax
call   10f0 <rand@plt>
lea    0xe2e(%rip),%rbx
lea    0xe2b(%rip),%r12
lea    0xe28(%rip),%r15
jmp    13bf <main+0x1ef>
xchg   %ax,%ax
mov    %r15,%rdi
xor    %eax,%eax
call   1070 <printf@plt>
mov    $0x2e,%edi
call   1030 <putchar@plt>
mov    0x2d45(%rip),%rbp
mov    0x0(%rbp),%edi
call   10b0 <fflush@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
mov    $0x2e,%edi
call   1030 <putchar@plt>
mov    0x0(%rbp),%edi
call   10b0 <fflush@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
mov    $0x2e,%edi
call   1030 <putchar@plt>
mov    0x0(%rbp),%edi
call   10b0 <fflush@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
mov    $0x2e,%edi
call   1030 <putchar@plt>
mov    0x0(%rbp),%edi
call   10b0 <fflush@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
mov    $0x2e,%edi
call   1030 <putchar@plt>
mov    0x0(%rbp),%edi
call   10b0 <fflush@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
mov    $0x2e,%edi
call   1030 <putchar@plt>
mov    0x0(%rbp),%edi
call   10b0 <fflush@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
mov    $0x2e,%edi
call   1030 <putchar@plt>
mov    0x0(%rbp),%edi
call   10b0 <fflush@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
mov    $0x2e,%edi
call   1030 <putchar@plt>
mov    0x0(%rbp),%edi
call   10b0 <fflush@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
mov    $0x2e,%edi
call   1030 <putchar@plt>
mov    0x0(%rbp),%edi
call   10b0 <fflush@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
mov    $0x2e,%edi
call   1030 <putchar@plt>
mov    0x0(%rbp),%edi
call   10b0 <fflush@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
mov    $0x1,%edi
call   10e0 <sleep@plt>
lea    0xcd4(%rip),%rdi
call   1060 <system@plt>
lea    0x14(%rsp),%rbp
mov    %rbp,%rdi
call   10a0 <time@plt>
mov    %rbp,%rdi
call   1040 <localtime@plt>
mov    (%rax),%ebp
mov    0x4(%rax),%r14d
mov    0x8(%rax),%eax
mov    %eax,0xc(%rsp)
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
cmp    $0x9,%ebp
jg     15e4 <main+0x414>
mov    %ebp,0x10(%rsp)
mov    %r15,%rbp
mov    %r12,%r15
mov    %r13,%r12
lea    0xada(%rip),%r13
mov    %r13,%rdi
xor    %esi,%esi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %r12,%rdi
mov    %r13,%rsi
mov    %r12,%r13
mov    %r15,%r12
mov    %rbp,%r15
mov    0x10(%rsp),%ebp
xor    %edx,%edx
xor    %eax,%eax
call   1090 <fprintf@plt>
mov    %rbx,%rdi
mov    %ebp,%esi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %r13,%rdi
mov    %rbx,%rsi
mov    %ebp,%edx
xor    %eax,%eax
call   1090 <fprintf@plt>
cmp    $0x9,%r14d
jg     1627 <main+0x457>
lea    0xa8a(%rip),%rbp
mov    %rbp,%rdi
xor    %esi,%esi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %r13,%rdi
mov    %rbp,%rsi
xor    %edx,%edx
xor    %eax,%eax
call   1090 <fprintf@plt>
mov    %rbx,%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %r13,%rdi
mov    %rbx,%rsi
mov    %r14d,%edx
xor    %eax,%eax
call   1090 <fprintf@plt>
cmpl   $0x9,0xc(%rsp)
jg     166d <main+0x49d>
lea    0xa44(%rip),%rbp
mov    %rbp,%rdi
xor    %esi,%esi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %r13,%rdi
mov    %rbp,%rsi
xor    %edx,%edx
xor    %eax,%eax
call   1090 <fprintf@plt>
mov    %r12,%rdi
mov    0xc(%rsp),%ebp
mov    %ebp,%esi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %r13,%rdi
mov    %r12,%rsi
mov    %ebp,%edx
xor    %eax,%eax
call   1090 <fprintf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
cmp    $0xe,%r14d
jg     1280 <main+0xb0>
add    $0xfffffff1,%r14d
xchg   %ax,%ax
mov    $0x20,%edi
call   1030 <putchar@plt>
inc    %r14d
jne    1700 <main+0x530>
jmp    1280 <main+0xb0>

LLVM IR (-O0):
%struct.tm = type { i32, i32, i32 }
@.str = [39 x i8] c"/home/pierre/Documents/doc/history.txt\00"
@.str.1 = [2 x i8] c"a\00"
@.str.2 = [59 x i8] c"echo $(date +%D) >> /home/pierre/Documents/doc/history.txt\00"
@.str.3 = [56 x i8] c"gcc -o heure /home/pierre/Documents/doc/heure.c;./heure\00"
@.str.4 = [25 x i8] c" dynamique \0A-----------\0A\00"
@.str.5 = [6 x i8] c"clear\00"
@.str.6 = [6 x i8] c"heure\00"
@.str.7 = [2 x i8] c"w\00"
@.str.8 = [2 x i8] c"\0A\00"
@.str.9 = [2 x i8] c" \00"
@.str.10 = [3 x i8] c"%d\00"
@.str.11 = [4 x i8] c"%d:\00"
@.str.12 = [4 x i8] c"%d\0A\00"
@.str.13 = [47 x i8] c"l'heure va s'actualiser dans quelques secondes\00"
@.str.14 = [2 x i8] c".\00"
@stdout = global i32 0
define i32 @main() {
%1 = alloca i32
%2 = alloca i32*
%3 = alloca i32*
%4 = alloca i32
%5 = alloca i32
%6 = alloca %struct.tm
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
store i32 0, i32* %1
store i32* null, i32** %2
%17 = call i32* @fopen(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %17, i32** %2
%18 = call i32 @system(i8* getelementptr inbounds ([59 x i8], [59 x i8]* @.str.2, i64 0, i64 0))
%19 = call i32 @system(i8* getelementptr inbounds ([56 x i8], [56 x i8]* @.str.3, i64 0, i64 0))
%20 = load i32*, i32** %2
%21 = call i32 (i32*, i8*, ...) @fprintf(i32* %20, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.4, i64 0, i64 0))
%22 = load i32*, i32** %2
%23 = call i32 @fclose(i32* %22)
%24 = call i32 @system(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.5, i64 0, i64 0))
store i32* null, i32** %3
%25 = call i32* @fopen(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.6, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.7, i64 0, i64 0))
store i32* %25, i32** %3
%26 = call i32 @time(i32* null)
%27 = call i32 @srand(i32 %26)
store i32 0, i32* %4
%28 = call i32 (...) @rand()
%29 = srem i32 %28, 3
store i32 %29, i32* %4
br label %30
30: ; preds = %0, %126
%31 = call i32 @time(i32* %5)
%32 = call %struct.tm* @localtime(i32* %5)
%33 = bitcast %struct.tm* %6 to i8*
%34 = bitcast %struct.tm* %32 to i8*
store i32 0, i32* %7
store i32 0, i32* %8
store i32 0, i32* %9
store i32 0, i32* %10
store i32 0, i32* %11
store i32 0, i32* %12
store i32 0, i32* %13
store i32 0, i32* %14
store i32 0, i32* %15
store i32 0, i32* %16
%35 = getelementptr inbounds %struct.tm, %struct.tm* %6, i32 0, i32 0
%36 = load i32, i32* %35
store i32 %36, i32* %7
%37 = getelementptr inbounds %struct.tm, %struct.tm* %6, i32 0, i32 1
%38 = load i32, i32* %37
store i32 %38, i32* %8
%39 = getelementptr inbounds %struct.tm, %struct.tm* %6, i32 0, i32 2
%40 = load i32, i32* %39
store i32 %40, i32* %9
br label %41
41: ; preds = %44, %30
%42 = load i32, i32* %14
%43 = icmp slt i32 %42, 10
br i1 %43, label %44, label %48
44: ; preds = %41
%45 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
%46 = load i32, i32* %14
%47 = add nsw i32 %46, 1
store i32 %47, i32* %14
br label %41
48: ; preds = %41
br label %49
49: ; preds = %52, %48
%50 = load i32, i32* %15
%51 = icmp slt i32 %50, 35
br i1 %51, label %52, label %56
52: ; preds = %49
%53 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%54 = load i32, i32* %15
%55 = add nsw i32 %54, 1
store i32 %55, i32* %15
br label %49
56: ; preds = %49
%57 = load i32, i32* %7
%58 = icmp slt i32 %57, 10
br i1 %58, label %59, label %65
59: ; preds = %56
%60 = load i32, i32* %13
%61 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 %60)
%62 = load i32*, i32** %3
%63 = load i32, i32* %13
%64 = call i32 (i32*, i8*, ...) @fprintf(i32* %62, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 %63)
br label %65
65: ; preds = %59, %56
%66 = load i32, i32* %7
%67 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0), i32 %66)
%68 = load i32*, i32** %3
%69 = load i32, i32* %7
%70 = call i32 (i32*, i8*, ...) @fprintf(i32* %68, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0), i32 %69)
%71 = load i32, i32* %8
%72 = icmp slt i32 %71, 10
br i1 %72, label %73, label %79
73: ; preds = %65
%74 = load i32, i32* %12
%75 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 %74)
%76 = load i32*, i32** %3
%77 = load i32, i32* %12
%78 = call i32 (i32*, i8*, ...) @fprintf(i32* %76, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 %77)
br label %79
79: ; preds = %73, %65
%80 = load i32, i32* %8
%81 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0), i32 %80)
%82 = load i32*, i32** %3
%83 = load i32, i32* %8
%84 = call i32 (i32*, i8*, ...) @fprintf(i32* %82, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0), i32 %83)
%85 = load i32, i32* %9
%86 = icmp slt i32 %85, 10
br i1 %86, label %87, label %93
87: ; preds = %79
%88 = load i32, i32* %11
%89 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 %88)
%90 = load i32*, i32** %3
%91 = load i32, i32* %11
%92 = call i32 (i32*, i8*, ...) @fprintf(i32* %90, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 %91)
br label %93
93: ; preds = %87, %79
%94 = load i32, i32* %9
%95 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.12, i64 0, i64 0), i32 %94)
%96 = load i32*, i32** %3
%97 = load i32, i32* %9
%98 = call i32 (i32*, i8*, ...) @fprintf(i32* %96, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.12, i64 0, i64 0), i32 %97)
br label %99
99: ; preds = %102, %93
%100 = load i32, i32* %16
%101 = icmp slt i32 %100, 10
br i1 %101, label %102, label %106
102: ; preds = %99
%103 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
%104 = load i32, i32* %16
%105 = add nsw i32 %104, 1
store i32 %105, i32* %16
br label %99
106: ; preds = %99
br label %107
107: ; preds = %110, %106
%108 = load i32, i32* %8
%109 = icmp slt i32 %108, 15
br i1 %109, label %110, label %114
110: ; preds = %107
%111 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0))
%112 = load i32, i32* %8
%113 = add nsw i32 %112, 1
store i32 %113, i32* %8
br label %107
114: ; preds = %107
%115 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str.13, i64 0, i64 0))
br label %116
116: ; preds = %119, %114
%117 = load i32, i32* %10
%118 = icmp slt i32 %117, 10
br i1 %118, label %119, label %126
119: ; preds = %116
%120 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.14, i64 0, i64 0))
%121 = load i32, i32* @stdout
%122 = call i32 @fflush(i32 %121)
%123 = call i32 @sleep(i32 1)
%124 = load i32, i32* %10
%125 = add nsw i32 %124, 1
store i32 %125, i32* %10
br label %116
126: ; preds = %116
%127 = call i32 @sleep(i32 1)
%128 = call i32 @system(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.5, i64 0, i64 0))
br label %30
}

LLVM IR (-O2):
%struct.tm = type { i32, i32, i32 }
@.str = [39 x i8] c"/home/pierre/Documents/doc/history.txt\00"
@.str.1 = [2 x i8] c"a\00"
@.str.2 = [59 x i8] c"echo $(date +%D) >> /home/pierre/Documents/doc/history.txt\00"
@.str.3 = [56 x i8] c"gcc -o heure /home/pierre/Documents/doc/heure.c;./heure\00"
@.str.4 = [25 x i8] c" dynamique \0A-----------\0A\00"
@.str.5 = [6 x i8] c"clear\00"
@.str.6 = [6 x i8] c"heure\00"
@.str.7 = [2 x i8] c"w\00"
@.str.10 = [3 x i8] c"%d\00"
@.str.11 = [4 x i8] c"%d:\00"
@.str.12 = [4 x i8] c"%d\0A\00"
@.str.13 = [47 x i8] c"l'heure va s'actualiser dans quelques secondes\00"
@stdout = global i32 0
define i32 @main() {
%1 = alloca i32
%2 = tail call i32* @fopen(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 @system(i8* getelementptr inbounds ([59 x i8], [59 x i8]* @.str.2, i64 0, i64 0))
%4 = tail call i32 @system(i8* getelementptr inbounds ([56 x i8], [56 x i8]* @.str.3, i64 0, i64 0))
%5 = tail call i64 @fwrite(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.4, i64 0, i64 0), i64 24, i64 1, i32* %2)
%6 = tail call i32 @fclose(i32* %2)
%7 = tail call i32 @system(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.5, i64 0, i64 0))
%8 = tail call i32* @fopen(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.6, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.7, i64 0, i64 0))
%9 = tail call i32 @time(i32* null)
%10 = tail call i32 @srand(i32 %9)
%11 = tail call i32 (...) @rand()
%12 = bitcast i32* %1 to i8*
br label %13
13: ; preds = %104, %0
%14 = call i32 @time(i32* %1)
%15 = call %struct.tm* @localtime(i32* %1)
%16 = getelementptr inbounds %struct.tm, %struct.tm* %15, i64 0, i32 0
%17 = load i32, i32* %16
%18 = getelementptr inbounds %struct.tm, %struct.tm* %15, i64 0, i32 1
%19 = load i32, i32* %18
%20 = getelementptr inbounds %struct.tm, %struct.tm* %15, i64 0, i32 2
%21 = load i32, i32* %20
%22 = call i32 @putchar(i32 10)
%23 = call i32 @putchar(i32 10)
%24 = call i32 @putchar(i32 10)
%25 = call i32 @putchar(i32 10)
%26 = call i32 @putchar(i32 10)
%27 = call i32 @putchar(i32 10)
%28 = call i32 @putchar(i32 10)
%29 = call i32 @putchar(i32 10)
%30 = call i32 @putchar(i32 10)
%31 = call i32 @putchar(i32 10)
%32 = call i32 @putchar(i32 32)
%33 = call i32 @putchar(i32 32)
%34 = call i32 @putchar(i32 32)
%35 = call i32 @putchar(i32 32)
%36 = call i32 @putchar(i32 32)
%37 = call i32 @putchar(i32 32)
%38 = call i32 @putchar(i32 32)
%39 = call i32 @putchar(i32 32)
%40 = call i32 @putchar(i32 32)
%41 = call i32 @putchar(i32 32)
%42 = call i32 @putchar(i32 32)
%43 = call i32 @putchar(i32 32)
%44 = call i32 @putchar(i32 32)
%45 = call i32 @putchar(i32 32)
%46 = call i32 @putchar(i32 32)
%47 = call i32 @putchar(i32 32)
%48 = call i32 @putchar(i32 32)
%49 = call i32 @putchar(i32 32)
%50 = call i32 @putchar(i32 32)
%51 = call i32 @putchar(i32 32)
%52 = call i32 @putchar(i32 32)
%53 = call i32 @putchar(i32 32)
%54 = call i32 @putchar(i32 32)
%55 = call i32 @putchar(i32 32)
%56 = call i32 @putchar(i32 32)
%57 = call i32 @putchar(i32 32)
%58 = call i32 @putchar(i32 32)
%59 = call i32 @putchar(i32 32)
%60 = call i32 @putchar(i32 32)
%61 = call i32 @putchar(i32 32)
%62 = call i32 @putchar(i32 32)
%63 = call i32 @putchar(i32 32)
%64 = call i32 @putchar(i32 32)
%65 = call i32 @putchar(i32 32)
%66 = call i32 @putchar(i32 32)
%67 = icmp slt i32 %17, 10
br i1 %67, label %68, label %71
68: ; preds = %13
%69 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 0)
%70 = call i32 (i32*, i8*, ...) @fprintf(i32* %8, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 0)
br label %71
71: ; preds = %68, %13
%72 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0), i32 %17)
%73 = call i32 (i32*, i8*, ...) @fprintf(i32* %8, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0), i32 %17)
%74 = icmp slt i32 %19, 10
br i1 %74, label %75, label %78
75: ; preds = %71
%76 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 0)
%77 = call i32 (i32*, i8*, ...) @fprintf(i32* %8, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 0)
br label %78
78: ; preds = %75, %71
%79 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0), i32 %19)
%80 = call i32 (i32*, i8*, ...) @fprintf(i32* %8, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.11, i64 0, i64 0), i32 %19)
%81 = icmp slt i32 %21, 10
br i1 %81, label %82, label %85
82: ; preds = %78
%83 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 0)
%84 = call i32 (i32*, i8*, ...) @fprintf(i32* %8, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i32 0)
br label %85
85: ; preds = %82, %78
%86 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.12, i64 0, i64 0), i32 %21)
%87 = call i32 (i32*, i8*, ...) @fprintf(i32* %8, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.12, i64 0, i64 0), i32 %21)
%88 = call i32 @putchar(i32 10)
%89 = call i32 @putchar(i32 10)
%90 = call i32 @putchar(i32 10)
%91 = call i32 @putchar(i32 10)
%92 = call i32 @putchar(i32 10)
%93 = call i32 @putchar(i32 10)
%94 = call i32 @putchar(i32 10)
%95 = call i32 @putchar(i32 10)
%96 = call i32 @putchar(i32 10)
%97 = call i32 @putchar(i32 10)
%98 = icmp slt i32 %19, 15
br i1 %98, label %99, label %104
99: ; preds = %85, %99
%100 = phi i32 [ %102, %99 ], [ %19, %85 ]
%101 = call i32 @putchar(i32 32)
%102 = add i32 %100, 1
%103 = icmp eq i32 %102, 15
br i1 %103, label %104, label %99
104: ; preds = %99, %85
%105 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([47 x i8], [47 x i8]* @.str.13, i64 0, i64 0))
%106 = call i32 @putchar(i32 46)
%107 = load i32, i32* @stdout
%108 = call i32 @fflush(i32 %107)
%109 = call i32 @sleep(i32 1)
%110 = call i32 @putchar(i32 46)
%111 = load i32, i32* @stdout
%112 = call i32 @fflush(i32 %111)
%113 = call i32 @sleep(i32 1)
%114 = call i32 @putchar(i32 46)
%115 = load i32, i32* @stdout
%116 = call i32 @fflush(i32 %115)
%117 = call i32 @sleep(i32 1)
%118 = call i32 @putchar(i32 46)
%119 = load i32, i32* @stdout
%120 = call i32 @fflush(i32 %119)
%121 = call i32 @sleep(i32 1)
%122 = call i32 @putchar(i32 46)
%123 = load i32, i32* @stdout
%124 = call i32 @fflush(i32 %123)
%125 = call i32 @sleep(i32 1)
%126 = call i32 @putchar(i32 46)
%127 = load i32, i32* @stdout
%128 = call i32 @fflush(i32 %127)
%129 = call i32 @sleep(i32 1)
%130 = call i32 @putchar(i32 46)
%131 = load i32, i32* @stdout
%132 = call i32 @fflush(i32 %131)
%133 = call i32 @sleep(i32 1)
%134 = call i32 @putchar(i32 46)
%135 = load i32, i32* @stdout
%136 = call i32 @fflush(i32 %135)
%137 = call i32 @sleep(i32 1)
%138 = call i32 @putchar(i32 46)
%139 = load i32, i32* @stdout
%140 = call i32 @fflush(i32 %139)
%141 = call i32 @sleep(i32 1)
%142 = call i32 @putchar(i32 46)
%143 = load i32, i32* @stdout
%144 = call i32 @fflush(i32 %143)
%145 = call i32 @sleep(i32 1)
%146 = call i32 @sleep(i32 1)
%147 = call i32 @system(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.5, i64 0, i64 0))
br label %13
}