#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*/ fatal(char *);
int /*<<< orphan*/ sprintf(char *, char *, int, int, int, int, int, int, int,
                           int);
void fatals(char *fmt, int x1, int x2, int x3, int x4, int x5, int x6, int x7,
            int x8) {
  char buffer[200];
  sprintf(buffer, fmt, x1, x2, x3, x4, x5, x6, x7, x8);
  fatal(buffer);
}


x86 assembly (clang, -O0):
<fatals>:
push   %rbp
mov    %rsp,%rbp
push   %rbx
sub    $0x108,%rsp
mov    0x20(%rbp),%eax
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%eax
mov    %rdi,-0x10(%rbp)
mov    %esi,-0x14(%rbp)
mov    %edx,-0x18(%rbp)
mov    %ecx,-0x1c(%rbp)
mov    %r8d,-0x20(%rbp)
mov    %r9d,-0x24(%rbp)
lea    -0xf0(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x14(%rbp),%edx
mov    -0x18(%rbp),%ecx
mov    -0x1c(%rbp),%r8d
mov    -0x20(%rbp),%r9d
mov    -0x24(%rbp),%ebx
mov    0x10(%rbp),%r11d
mov    0x18(%rbp),%r10d
mov    0x20(%rbp),%eax
mov    %ebx,(%rsp)
mov    %r11d,0x8(%rsp)
mov    %r10d,0x10(%rsp)
mov    %eax,0x18(%rsp)
call   1030 <sprintf@plt>
lea    -0xf0(%rbp),%rdi
call   1040 <fatal@plt>
add    $0x108,%rsp
pop    %rbx
pop    %rbp
ret

x86 assembly (clang, -O2):
<fatals>:
push   %r14
push   %rbx
sub    $0xc8,%rsp
mov    %r9d,%eax
mov    %r8d,%r9d
mov    %ecx,%r8d
mov    %edx,%ecx
mov    %esi,%edx
mov    %rdi,%rsi
mov    0xe0(%rsp),%r10d
mov    0xe8(%rsp),%r11d
mov    0xf0(%rsp),%r14d
mov    %rsp,%rbx
mov    %rbx,%rdi
push   %r14
push   %r11
push   %r10
push   %rax
call   1030 <sprintf@plt>
add    $0x20,%rsp
mov    %rbx,%rdi
call   1040 <fatal@plt>
add    $0xc8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define void @fatals(i8* %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, i32 %8) {
%10 = alloca i8*
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
%17 = alloca i32
%18 = alloca i32
%19 = alloca [200 x i8]
store i8* %0, i8** %10
store i32 %1, i32* %11
store i32 %2, i32* %12
store i32 %3, i32* %13
store i32 %4, i32* %14
store i32 %5, i32* %15
store i32 %6, i32* %16
store i32 %7, i32* %17
store i32 %8, i32* %18
%20 = getelementptr inbounds [200 x i8], [200 x i8]* %19, i64 0, i64 0
%21 = load i8*, i8** %10
%22 = load i32, i32* %11
%23 = load i32, i32* %12
%24 = load i32, i32* %13
%25 = load i32, i32* %14
%26 = load i32, i32* %15
%27 = load i32, i32* %16
%28 = load i32, i32* %17
%29 = load i32, i32* %18
%30 = call i32 @sprintf(i8* %20, i8* %21, i32 %22, i32 %23, i32 %24, i32 %25, i32 %26, i32 %27, i32 %28, i32 %29)
%31 = getelementptr inbounds [200 x i8], [200 x i8]* %19, i64 0, i64 0
%32 = call i32 @fatal(i8* %31)
ret void
}

LLVM IR (-O2):
define void @fatals(i8* nocapture %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, i32 %8) {
%10 = alloca [200 x i8]
%11 = getelementptr inbounds [200 x i8], [200 x i8]* %10, i64 0, i64 0
%12 = call i32 @sprintf(i8* %11, i8* dereferenceable(1) %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, i32 %8)
%13 = call i32 @fatal(i8* %11)
ret void
}