#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 /*<<< orphan*/ sprintf(char *, char *, ...);
void vn_build_resp_404_body(char *body, const char *uri) {
  sprintf(body, "<html><head>");
  sprintf(body, "%s<title>404 Not Found</title>", body);
  sprintf(body, "%s</head><body>", body);
  sprintf(body, "%s<h1>Not Found</h1>", body);
  sprintf(body, "%s<p>The requested URL %s was not found on this server.</p>",
          body, uri);
  sprintf(body, "%s<hr>", body);
  sprintf(body, "%s<address>Vino Server</address>", body);
  sprintf(body, "%s</body></html>", body);
}


x86 assembly (clang, -O0):
<vn_build_resp_404_body>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
lea    0xed5(%rip),%rsi
mov    $0x0,%al
call   1030 <sprintf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rdx
lea    0xecc(%rip),%rsi
mov    $0x0,%al
call   1030 <sprintf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rdx
lea    0xed5(%rip),%rsi
mov    $0x0,%al
call   1030 <sprintf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rdx
lea    0xecf(%rip),%rsi
mov    $0x0,%al
call   1030 <sprintf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rdx
mov    -0x10(%rbp),%rcx
lea    0xeca(%rip),%rsi
mov    $0x0,%al
call   1030 <sprintf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rdx
lea    0xef0(%rip),%rsi
mov    $0x0,%al
call   1030 <sprintf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rdx
lea    0xee1(%rip),%rsi
mov    $0x0,%al
call   1030 <sprintf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x8(%rbp),%rdx
lea    0xeec(%rip),%rsi
mov    $0x0,%al
call   1030 <sprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<vn_build_resp_404_body>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
movabs $0x3e646165683c3e,%rax
mov    %rax,0x5(%rdi)
movabs $0x683c3e6c6d74683c,%rax
3e 3c 68
mov    %rax,(%rdi)
lea    0xed1(%rip),%rsi
mov    %rdi,%rdx
xor    %eax,%eax
call   1030 <sprintf@plt>
lea    0xedf(%rip),%rsi
mov    %rbx,%rdi
mov    %rbx,%rdx
xor    %eax,%eax
call   1030 <sprintf@plt>
lea    0xedb(%rip),%rsi
mov    %rbx,%rdi
mov    %rbx,%rdx
xor    %eax,%eax
call   1030 <sprintf@plt>
lea    0xedc(%rip),%rsi
mov    %rbx,%rdi
mov    %rbx,%rdx
mov    %r14,%rcx
xor    %eax,%eax
call   1030 <sprintf@plt>
lea    0xf01(%rip),%rsi
mov    %rbx,%rdi
mov    %rbx,%rdx
xor    %eax,%eax
call   1030 <sprintf@plt>
lea    0xef4(%rip),%rsi
mov    %rbx,%rdi
mov    %rbx,%rdx
xor    %eax,%eax
call   1030 <sprintf@plt>
lea    0xf01(%rip),%rsi
mov    %rbx,%rdi
mov    %rbx,%rdx
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <sprintf@plt>

LLVM IR (-O0):
@.str = [13 x i8] c"<html><head>\00"
@.str.1 = [31 x i8] c"%s<title>404 Not Found</title>\00"
@.str.2 = [16 x i8] c"%s</head><body>\00"
@.str.3 = [21 x i8] c"%s<h1>Not Found</h1>\00"
@.str.4 = [60 x i8] c"%s<p>The requested URL %s was not found on this server.</p>\00"
@.str.5 = [7 x i8] c"%s<hr>\00"
@.str.6 = [33 x i8] c"%s<address>Vino Server</address>\00"
@.str.7 = [17 x i8] c"%s</body></html>\00"
define void @vn_build_resp_404_body(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%5 = load i8*, i8** %3
%6 = call i32 (i8*, i8*, ...) @sprintf(i8* %5, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%7 = load i8*, i8** %3
%8 = load i8*, i8** %3
%9 = call i32 (i8*, i8*, ...) @sprintf(i8* %7, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.1, i64 0, i64 0), i8* %8)
%10 = load i8*, i8** %3
%11 = load i8*, i8** %3
%12 = call i32 (i8*, i8*, ...) @sprintf(i8* %10, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0), i8* %11)
%13 = load i8*, i8** %3
%14 = load i8*, i8** %3
%15 = call i32 (i8*, i8*, ...) @sprintf(i8* %13, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.3, i64 0, i64 0), i8* %14)
%16 = load i8*, i8** %3
%17 = load i8*, i8** %3
%18 = load i8*, i8** %4
%19 = call i32 (i8*, i8*, ...) @sprintf(i8* %16, i8* getelementptr inbounds ([60 x i8], [60 x i8]* @.str.4, i64 0, i64 0), i8* %17, i8* %18)
%20 = load i8*, i8** %3
%21 = load i8*, i8** %3
%22 = call i32 (i8*, i8*, ...) @sprintf(i8* %20, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.5, i64 0, i64 0), i8* %21)
%23 = load i8*, i8** %3
%24 = load i8*, i8** %3
%25 = call i32 (i8*, i8*, ...) @sprintf(i8* %23, i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.6, i64 0, i64 0), i8* %24)
%26 = load i8*, i8** %3
%27 = load i8*, i8** %3
%28 = call i32 (i8*, i8*, ...) @sprintf(i8* %26, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.7, i64 0, i64 0), i8* %27)
ret void
}

LLVM IR (-O2):
@.str = [13 x i8] c"<html><head>\00"
@.str.1 = [31 x i8] c"%s<title>404 Not Found</title>\00"
@.str.2 = [16 x i8] c"%s</head><body>\00"
@.str.3 = [21 x i8] c"%s<h1>Not Found</h1>\00"
@.str.4 = [60 x i8] c"%s<p>The requested URL %s was not found on this server.</p>\00"
@.str.5 = [7 x i8] c"%s<hr>\00"
@.str.6 = [33 x i8] c"%s<address>Vino Server</address>\00"
@.str.7 = [17 x i8] c"%s</body></html>\00"
define void @vn_build_resp_404_body(i8* %0, i8* %1) {
tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* align 1 dereferenceable(13) %0, i8* align 1 dereferenceable(13) getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i64 13, i1 false)
%3 = tail call i32 (i8*, i8*, ...) @sprintf(i8* dereferenceable(1) %0, i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @.str.1, i64 0, i64 0), i8* %0)
%4 = tail call i32 (i8*, i8*, ...) @sprintf(i8* dereferenceable(1) %0, i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0), i8* %0)
%5 = tail call i32 (i8*, i8*, ...) @sprintf(i8* dereferenceable(1) %0, i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str.3, i64 0, i64 0), i8* %0)
%6 = tail call i32 (i8*, i8*, ...) @sprintf(i8* dereferenceable(1) %0, i8* dereferenceable(1) getelementptr inbounds ([60 x i8], [60 x i8]* @.str.4, i64 0, i64 0), i8* %0, i8* %1)
%7 = tail call i32 (i8*, i8*, ...) @sprintf(i8* dereferenceable(1) %0, i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @.str.5, i64 0, i64 0), i8* %0)
%8 = tail call i32 (i8*, i8*, ...) @sprintf(i8* dereferenceable(1) %0, i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @.str.6, i64 0, i64 0), i8* %0)
%9 = tail call i32 (i8*, i8*, ...) @sprintf(i8* dereferenceable(1) %0, i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str.7, i64 0, i64 0), i8* %0)
ret void
}