#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 google_chart_float_chart(FILE *output_file, char *title, int width,
                              int height, int chart_number) {
  if (title && *title) {
    fprintf(output_file, "<h3>%s</h3>\n", title);
  }
  fprintf(
      output_file,
      "<div id=\"chart_div%d\" style=\"width: %dpx; height: %dpx\"></div>\n",
      chart_number, width, height);
}


x86 assembly (clang, -O0):
<google_chart_float_chart>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %ecx,-0x18(%rbp)
mov    %r8d,-0x1c(%rbp)
cmpq   $0x0,-0x10(%rbp)
je     115b <google_chart_float_chart+0x4b>
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x0,%eax
je     115b <google_chart_float_chart+0x4b>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rdx
lea    0xeac(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x1c(%rbp),%edx
mov    -0x14(%rbp),%ecx
mov    -0x18(%rbp),%r8d
lea    0xe9d(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<google_chart_float_chart>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %r8d,%r15d
mov    %ecx,%r14d
mov    %edx,%ebx
mov    %rdi,%rbp
test   %rsi,%rsi
je     1140 <google_chart_float_chart+0x30>
mov    %rsi,%rdx
cmpb   $0x0,(%rsi)
je     1140 <google_chart_float_chart+0x30>
lea    0xeca(%rip),%rsi
mov    %rbp,%rdi
xor    %eax,%eax
call   1030 <fprintf@plt>
lea    0xec6(%rip),%rsi
mov    %rbp,%rdi
mov    %r15d,%edx
mov    %ebx,%ecx
mov    %r14d,%r8d
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@.str = [13 x i8] c"<h3>%s</h3>\0A\00"
@.str.1 = [64 x i8] c"<div id=\22chart_div%d\22 style=\22width: %dpx; height: %dpx\22></div>\0A\00"
define void @google_chart_float_chart(i32* %0, i8* %1, i32 %2, i32 %3, i32 %4) {
%6 = alloca i32*
%7 = alloca i8*
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
store i32* %0, i32** %6
store i8* %1, i8** %7
store i32 %2, i32* %8
store i32 %3, i32* %9
store i32 %4, i32* %10
%11 = load i8*, i8** %7
%12 = icmp ne i8* %11, null
br i1 %12, label %13, label %22
13: ; preds = %5
%14 = load i8*, i8** %7
%15 = load i8, i8* %14
%16 = sext i8 %15 to i32
%17 = icmp ne i32 %16, 0
br i1 %17, label %18, label %22
18: ; preds = %13
%19 = load i32*, i32** %6
%20 = load i8*, i8** %7
%21 = call i32 (i32*, i8*, ...) @fprintf(i32* %19, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* %20)
br label %22
22: ; preds = %18, %13, %5
%23 = load i32*, i32** %6
%24 = load i32, i32* %10
%25 = load i32, i32* %8
%26 = load i32, i32* %9
%27 = call i32 (i32*, i8*, ...) @fprintf(i32* %23, i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str.1, i64 0, i64 0), i32 %24, i32 %25, i32 %26)
ret void
}

LLVM IR (-O2):
@.str = [13 x i8] c"<h3>%s</h3>\0A\00"
@.str.1 = [64 x i8] c"<div id=\22chart_div%d\22 style=\22width: %dpx; height: %dpx\22></div>\0A\00"
define void @google_chart_float_chart(i32* nocapture %0, i8* %1, i32 %2, i32 %3, i32 %4) {
%6 = icmp eq i8* %1, null
br i1 %6, label %12, label %7
7: ; preds = %5
%8 = load i8, i8* %1
%9 = icmp eq i8 %8, 0
br i1 %9, label %12, label %10
10: ; preds = %7
%11 = tail call i32 (i32*, i8*, ...) @fprintf(i32* %0, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* %1)
br label %12
12: ; preds = %10, %7, %5
%13 = tail call i32 (i32*, i8*, ...) @fprintf(i32* %0, i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str.1, i64 0, i64 0), i32 %4, i32 %2, i32 %3)
ret void
}