#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 */
char **malloc(int);
int /*<<< orphan*/ printFF(char *, char **, int /*<<< orphan*/);
int /*<<< orphan*/ putchar(char);
void error(char *buffer) {
  char **s = malloc(sizeof(char *));
  s[0] = buffer;
  printFF("%s", s, 0);
  putchar(':');
  putchar(' ');
  char *error = "command not found";
  s[0] = error;
  printFF("%s", s, 0);
  putchar('\n');
}


x86 assembly (clang, -O0):
<error>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x8,%edi
call   1050 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    -0x8(%rbp),%rcx
mov    -0x10(%rbp),%rax
mov    %rcx,(%rax)
mov    -0x10(%rbp),%rsi
lea    0xea0(%rip),%rdi
xor    %edx,%edx
call   1040 <printFF@plt>
mov    $0x3a,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
lea    0xe81(%rip),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rcx
mov    -0x10(%rbp),%rax
mov    %rcx,(%rax)
mov    -0x10(%rbp),%rsi
lea    0xe64(%rip),%rdi
xor    %edx,%edx
call   1040 <printFF@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<error>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%r14
mov    $0x8,%edi
call   1050 <malloc@plt>
mov    %rax,%rbx
mov    %r14,(%rax)
lea    0xeb2(%rip),%r14
mov    %r14,%rdi
mov    %rax,%rsi
xor    %edx,%edx
call   1040 <printFF@plt>
mov    $0x3a,%edi
call   1030 <putchar@plt>
mov    $0x20,%edi
call   1030 <putchar@plt>
lea    0xe8d(%rip),%rax
mov    %rax,(%rbx)
mov    %r14,%rdi
mov    %rbx,%rsi
xor    %edx,%edx
call   1040 <printFF@plt>
mov    $0xa,%edi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <putchar@plt>

LLVM IR (-O0):
@.str = [3 x i8] c"%s\00"
@.str.1 = [18 x i8] c"command not found\00"
define void @error(i8* %0) {
%2 = alloca i8*
%3 = alloca i8**
%4 = alloca i8*
store i8* %0, i8** %2
%5 = call i8** @malloc(i32 8)
store i8** %5, i8*** %3
%6 = load i8*, i8** %2
%7 = load i8**, i8*** %3
%8 = getelementptr inbounds i8*, i8** %7, i64 0
store i8* %6, i8** %8
%9 = load i8**, i8*** %3
%10 = call i32 @printFF(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8** %9, i32 0)
%11 = call i32 @putchar(i8 signext 58)
%12 = call i32 @putchar(i8 signext 32)
store i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.1, i64 0, i64 0), i8** %4
%13 = load i8*, i8** %4
%14 = load i8**, i8*** %3
%15 = getelementptr inbounds i8*, i8** %14, i64 0
store i8* %13, i8** %15
%16 = load i8**, i8*** %3
%17 = call i32 @printFF(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8** %16, i32 0)
%18 = call i32 @putchar(i8 signext 10)
ret void
}

LLVM IR (-O2):
@.str = [3 x i8] c"%s\00"
@.str.1 = [18 x i8] c"command not found\00"
define void @error(i8* %0) {
%2 = tail call i8** @malloc(i32 8)
store i8* %0, i8** %2
%3 = tail call i32 @printFF(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8** %2, i32 0)
%4 = tail call i32 @putchar(i8 signext 58)
%5 = tail call i32 @putchar(i8 signext 32)
store i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.1, i64 0, i64 0), i8** %2
%6 = tail call i32 @printFF(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8** %2, i32 0)
%7 = tail call i32 @putchar(i8 signext 10)
ret void
}