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

/* Variables and functions */
int html_int(char *, int);
int html_string(char *, char *);
int html_img(char *src, char *align, int height, int width, int hspace,
             int vspace, char *alt) {
  return html_string("<IMG SRC=\"%s\"", src) +
         html_string(" ALIGN=\"%s\"", align) +
         html_int(" HEIGHT=\"%d\"", height) + html_int(" WIDTH=\"%d\"", width) +
         html_int(" HSPACE=\"%d\"", hspace) +
         html_int(" VSPACE=\"%d\"", vspace) + html_string(" ALT=\"%s\"", alt) +
         html_string("%s", ">");
}


x86 assembly (clang, -O0):
<html_img>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    0x10(%rbp),%rax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %ecx,-0x18(%rbp)
mov    %r8d,-0x1c(%rbp)
mov    %r9d,-0x20(%rbp)
mov    -0x8(%rbp),%rsi
lea    0xeb3(%rip),%rdi
call   1030 <html_string@plt>
mov    %eax,-0x3c(%rbp)
mov    -0x10(%rbp),%rsi
lea    0xeae(%rip),%rdi
call   1030 <html_string@plt>
mov    %eax,%ecx
mov    -0x3c(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x38(%rbp)
mov    -0x14(%rbp),%esi
lea    0xea1(%rip),%rdi
call   1040 <html_int@plt>
mov    %eax,%ecx
mov    -0x38(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x34(%rbp)
mov    -0x18(%rbp),%esi
lea    0xe95(%rip),%rdi
call   1040 <html_int@plt>
mov    %eax,%ecx
mov    -0x34(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x30(%rbp)
mov    -0x1c(%rbp),%esi
lea    0xe88(%rip),%rdi
call   1040 <html_int@plt>
mov    %eax,%ecx
mov    -0x30(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x2c(%rbp)
mov    -0x20(%rbp),%esi
lea    0xe7c(%rip),%rdi
call   1040 <html_int@plt>
mov    %eax,%ecx
mov    -0x2c(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x28(%rbp)
mov    0x10(%rbp),%rsi
lea    0xe6f(%rip),%rdi
call   1030 <html_string@plt>
mov    %eax,%ecx
mov    -0x28(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x24(%rbp)
lea    0xe63(%rip),%rdi
lea    0xe5f(%rip),%rsi
call   1030 <html_string@plt>
mov    %eax,%ecx
mov    -0x24(%rbp),%eax
add    %ecx,%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<html_img>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %r9d,%r15d
mov    %r8d,%r12d
mov    %ecx,%r13d
mov    %edx,%ebx
mov    %rsi,%rbp
mov    %rdi,%rsi
lea    0xebd(%rip),%rdi
call   1030 <html_string@plt>
mov    %eax,%r14d
lea    0xebc(%rip),%rdi
mov    %rbp,%rsi
call   1030 <html_string@plt>
mov    %eax,%ebp
add    %r14d,%ebp
lea    0xeb4(%rip),%rdi
mov    %ebx,%esi
call   1040 <html_int@plt>
mov    %eax,%ebx
add    %ebp,%ebx
lea    0xeaf(%rip),%rdi
mov    %r13d,%esi
call   1040 <html_int@plt>
mov    %eax,%ebp
add    %ebx,%ebp
lea    0xea8(%rip),%rdi
mov    %r12d,%esi
call   1040 <html_int@plt>
mov    %eax,%ebx
add    %ebp,%ebx
lea    0xea2(%rip),%rdi
mov    %r15d,%esi
call   1040 <html_int@plt>
mov    %eax,%ebp
add    %ebx,%ebp
lea    0xe9c(%rip),%rdi
mov    0x40(%rsp),%rsi
call   1030 <html_string@plt>
mov    %eax,%ebx
add    %ebp,%ebx
lea    0xe91(%rip),%rdi
lea    0xe8d(%rip),%rsi
call   1030 <html_string@plt>
add    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [14 x i8] c"<IMG SRC=\22%s\22\00"
@.str.1 = [12 x i8] c" ALIGN=\22%s\22\00"
@.str.2 = [13 x i8] c" HEIGHT=\22%d\22\00"
@.str.3 = [12 x i8] c" WIDTH=\22%d\22\00"
@.str.4 = [13 x i8] c" HSPACE=\22%d\22\00"
@.str.5 = [13 x i8] c" VSPACE=\22%d\22\00"
@.str.6 = [10 x i8] c" ALT=\22%s\22\00"
@.str.7 = [3 x i8] c"%s\00"
@.str.8 = [2 x i8] c">\00"
define i32 @html_img(i8* %0, i8* %1, i32 %2, i32 %3, i32 %4, i32 %5, i8* %6) {
%8 = alloca i8*
%9 = alloca i8*
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i8*
store i8* %0, i8** %8
store i8* %1, i8** %9
store i32 %2, i32* %10
store i32 %3, i32* %11
store i32 %4, i32* %12
store i32 %5, i32* %13
store i8* %6, i8** %14
%15 = load i8*, i8** %8
%16 = call i32 @html_string(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i8* %15)
%17 = load i8*, i8** %9
%18 = call i32 @html_string(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i8* %17)
%19 = add nsw i32 %16, %18
%20 = load i32, i32* %10
%21 = call i32 @html_int(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i32 %20)
%22 = add nsw i32 %19, %21
%23 = load i32, i32* %11
%24 = call i32 @html_int(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0), i32 %23)
%25 = add nsw i32 %22, %24
%26 = load i32, i32* %12
%27 = call i32 @html_int(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 %26)
%28 = add nsw i32 %25, %27
%29 = load i32, i32* %13
%30 = call i32 @html_int(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.5, i64 0, i64 0), i32 %29)
%31 = add nsw i32 %28, %30
%32 = load i8*, i8** %14
%33 = call i32 @html_string(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.6, i64 0, i64 0), i8* %32)
%34 = add nsw i32 %31, %33
%35 = call i32 @html_string(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
%36 = add nsw i32 %34, %35
ret i32 %36
}

LLVM IR (-O2):
@.str = [14 x i8] c"<IMG SRC=\22%s\22\00"
@.str.1 = [12 x i8] c" ALIGN=\22%s\22\00"
@.str.2 = [13 x i8] c" HEIGHT=\22%d\22\00"
@.str.3 = [12 x i8] c" WIDTH=\22%d\22\00"
@.str.4 = [13 x i8] c" HSPACE=\22%d\22\00"
@.str.5 = [13 x i8] c" VSPACE=\22%d\22\00"
@.str.6 = [10 x i8] c" ALT=\22%s\22\00"
@.str.7 = [3 x i8] c"%s\00"
@.str.8 = [2 x i8] c">\00"
define i32 @html_img(i8* %0, i8* %1, i32 %2, i32 %3, i32 %4, i32 %5, i8* %6) {
%8 = tail call i32 @html_string(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0), i8* %0)
%9 = tail call i32 @html_string(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i8* %1)
%10 = add nsw i32 %9, %8
%11 = tail call i32 @html_int(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i32 %2)
%12 = add nsw i32 %10, %11
%13 = tail call i32 @html_int(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0), i32 %3)
%14 = add nsw i32 %12, %13
%15 = tail call i32 @html_int(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 %4)
%16 = add nsw i32 %14, %15
%17 = tail call i32 @html_int(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.5, i64 0, i64 0), i32 %5)
%18 = add nsw i32 %16, %17
%19 = tail call i32 @html_string(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.6, i64 0, i64 0), i8* %6)
%20 = add nsw i32 %18, %19
%21 = tail call i32 @html_string(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
%22 = add nsw i32 %20, %21
ret i32 %22
}