#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*/ fputs(char const *, int /*<<< orphan*/ *);
void print_day_header(FILE *f) {
  const char *day_header =
      "ScaleY ScaleX Min dup scale\n"
      "%----------------------------------------\n"
      "% First the gray background area\n"
      "newpath\n"
      "0 slw\n"
      " 0.5  inch  3.5 inch m\n"
      " 0          7.0 inch rl\n"
      " 7.5  inch  0        rl\n"
      " 0         -1   inch rl\n"
      "-3    inch  0        rl\n"
      " 0         -6   inch rl\n"
      "-0.75 inch  0        rl\n"
      " 0          6   inch rl\n"
      "-3    inch  0        rl\n"
      " 0         -6   inch rl\n"
      "closepath 0.85 setgray fill stroke\n"
      "%----------------------------------------\n"
      "% Next highlighting lines round title\n"
      "0 setgray\n"
      "1 slw newpath 0.5 inch 10.5    inch m 7.5 inch 0 rl stroke\n"
      "      newpath 0.5 inch  9.5625 inch m 7.5 inch 0 rl stroke\n"
      "2 slw newpath 0.5 inch  9.5    inch m 7.5 inch 0 rl stroke\n\n"
      "/Times-Roman-ISOLatin1 findfont 14 scalefont setfont\n"
      "0 slw\n"
      "0 1 11 {\n"
      "       /I edef\n"
      "       %----------------------------------------\n"
      "       % The hours\n"
      "       0.5 inch 9.15 inch I 0.5 inch mul sub m\n"
      "       I 10 lt { (0) show } if I nstr cvs show (:00) show\n"
      "       4.25 inch 9.15 inch I 0.5 inch mul sub m\n"
      "       I 12 add nstr cvs show (:00) show\n"
      "       %----------------------------------------\n"
      "       % The horizontal lines between hours\n"
      "       1.25 inch 9 inch I 0.5 inch mul sub m 3 inch 0 rl\n"
      "       5    inch 9 inch I 0.5 inch mul sub m 3 inch 0 rl\n"
      "} for\n"
      "stroke\n";
  fputs(day_header, f);
}


x86 assembly (clang, -O0):
<print_day_header>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
lea    0xedd(%rip),%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x8(%rbp),%rsi
call   1030 <fputs@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_day_header>:
mov    %rdi,%rcx
lea    0xee6(%rip),%rdi
mov    $0x4c8,%esi
mov    $0x1,%edx
jmp    1030 <fwrite@plt>

LLVM IR (-O0):
@.str = [1225 x i8] c"ScaleY ScaleX Min dup scale\0A%----------------------------------------\0A% First the gray background area\0Anewpath\0A0 slw\0A 0.5 inch 3.5 inch m\0A 0 7.0 inch rl\0A 7.5 inch 0 rl\0A 0 -1 inch rl\0A-3 inch 0 rl\0A 0 -6 inch rl\0A-0.75 inch 0 rl\0A 0 6 inch rl\0A-3 inch 0 rl\0A 0 -6 inch rl\0Aclosepath 0.85 setgray fill stroke\0A%----------------------------------------\0A% Next highlighting lines round title\0A0 setgray\0A1 slw newpath 0.5 inch 10.5 inch m 7.5 inch 0 rl stroke\0A newpath 0.5 inch 9.5625 inch m 7.5 inch 0 rl stroke\0A2 slw newpath 0.5 inch 9.5 inch m 7.5 inch 0 rl stroke\0A\0A/Times-Roman-ISOLatin1 findfont 14 scalefont setfont\0A0 slw\0A0 1 11 {\0A /I edef\0A %----------------------------------------\0A % The hours\0A 0.5 inch 9.15 inch I 0.5 inch mul sub m\0A I 10 lt { (0) show } if I nstr cvs show (:00) show\0A 4.25 inch 9.15 inch I 0.5 inch mul sub m\0A I 12 add nstr cvs show (:00) show\0A %----------------------------------------\0A % The horizontal lines between hours\0A 1.25 inch 9 inch I 0.5 inch mul sub m 3 inch 0 rl\0A 5 inch 9 inch I 0.5 inch mul sub m 3 inch 0 rl\0A} for\0Astroke\0A\00"
define void @print_day_header(i32* %0) {
%2 = alloca i32*
%3 = alloca i8*
store i32* %0, i32** %2
store i8* getelementptr inbounds ([1225 x i8], [1225 x i8]* @.str, i64 0, i64 0), i8** %3
%4 = load i8*, i8** %3
%5 = load i32*, i32** %2
%6 = call i32 @fputs(i8* %4, i32* %5)
ret void
}

LLVM IR (-O2):
@.str = [1225 x i8] c"ScaleY ScaleX Min dup scale\0A%----------------------------------------\0A% First the gray background area\0Anewpath\0A0 slw\0A 0.5 inch 3.5 inch m\0A 0 7.0 inch rl\0A 7.5 inch 0 rl\0A 0 -1 inch rl\0A-3 inch 0 rl\0A 0 -6 inch rl\0A-0.75 inch 0 rl\0A 0 6 inch rl\0A-3 inch 0 rl\0A 0 -6 inch rl\0Aclosepath 0.85 setgray fill stroke\0A%----------------------------------------\0A% Next highlighting lines round title\0A0 setgray\0A1 slw newpath 0.5 inch 10.5 inch m 7.5 inch 0 rl stroke\0A newpath 0.5 inch 9.5625 inch m 7.5 inch 0 rl stroke\0A2 slw newpath 0.5 inch 9.5 inch m 7.5 inch 0 rl stroke\0A\0A/Times-Roman-ISOLatin1 findfont 14 scalefont setfont\0A0 slw\0A0 1 11 {\0A /I edef\0A %----------------------------------------\0A % The hours\0A 0.5 inch 9.15 inch I 0.5 inch mul sub m\0A I 10 lt { (0) show } if I nstr cvs show (:00) show\0A 4.25 inch 9.15 inch I 0.5 inch mul sub m\0A I 12 add nstr cvs show (:00) show\0A %----------------------------------------\0A % The horizontal lines between hours\0A 1.25 inch 9 inch I 0.5 inch mul sub m 3 inch 0 rl\0A 5 inch 9 inch I 0.5 inch mul sub m 3 inch 0 rl\0A} for\0Astroke\0A\00"
define void @print_day_header(i32* nocapture %0) {
%2 = tail call i64 @fwrite(i8* getelementptr inbounds ([1225 x i8], [1225 x i8]* @.str, i64 0, i64 0), i64 1224, i64 1, i32* %0)
ret void
}