#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*/ BlankLine();
int /*<<< orphan*/ EmitIndented(int, char *, ...);
void EmitBringup(int indent, char *name) {
  BlankLine();
  EmitIndented(indent, "cut_start( \"group-%s\", __CUT_TAKEDOWN__%s );", name,
               name);
  EmitIndented(indent, "__CUT_BRINGUP__%s();", name);
  EmitIndented(indent, "cut_check_errors();");
}


x86 assembly (clang, -O0):
<EmitBringup>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x0,%al
call   1030 <BlankLine@plt>
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rdx
mov    -0x10(%rbp),%rcx
lea    0xeb8(%rip),%rsi
mov    $0x0,%al
call   1040 <EmitIndented@plt>
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rdx
lea    0xed0(%rip),%rsi
mov    $0x0,%al
call   1040 <EmitIndented@plt>
mov    -0x4(%rbp),%edi
lea    0xed4(%rip),%rsi
mov    $0x0,%al
call   1040 <EmitIndented@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<EmitBringup>:
push   %rbp
push   %rbx
push   %rax
mov    %rsi,%rbx
mov    %edi,%ebp
xor    %eax,%eax
call   1030 <BlankLine@plt>
lea    0xeca(%rip),%rsi
mov    %ebp,%edi
mov    %rbx,%rdx
mov    %rbx,%rcx
xor    %eax,%eax
call   1040 <EmitIndented@plt>
lea    0xee1(%rip),%rsi
mov    %ebp,%edi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <EmitIndented@plt>
lea    0xee3(%rip),%rsi
mov    %ebp,%edi
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1040 <EmitIndented@plt>

LLVM IR (-O0):
@.str = [45 x i8] c"cut_start( \22group-%s\22, __CUT_TAKEDOWN__%s );\00"
@.str.1 = [21 x i8] c"__CUT_BRINGUP__%s();\00"
@.str.2 = [20 x i8] c"cut_check_errors();\00"
define void @EmitBringup(i32 %0, i8* %1) {
%3 = alloca i32
%4 = alloca i8*
store i32 %0, i32* %3
store i8* %1, i8** %4
%5 = call i32 (...) @BlankLine()
%6 = load i32, i32* %3
%7 = load i8*, i8** %4
%8 = load i8*, i8** %4
%9 = call i32 (i32, i8*, ...) @EmitIndented(i32 %6, i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str, i64 0, i64 0), i8* %7, i8* %8)
%10 = load i32, i32* %3
%11 = load i8*, i8** %4
%12 = call i32 (i32, i8*, ...) @EmitIndented(i32 %10, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.1, i64 0, i64 0), i8* %11)
%13 = load i32, i32* %3
%14 = call i32 (i32, i8*, ...) @EmitIndented(i32 %13, i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [45 x i8] c"cut_start( \22group-%s\22, __CUT_TAKEDOWN__%s );\00"
@.str.1 = [21 x i8] c"__CUT_BRINGUP__%s();\00"
@.str.2 = [20 x i8] c"cut_check_errors();\00"
define void @EmitBringup(i32 %0, i8* %1) {
%3 = tail call i32 (...) @BlankLine()
%4 = tail call i32 (i32, i8*, ...) @EmitIndented(i32 %0, i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str, i64 0, i64 0), i8* %1, i8* %1)
%5 = tail call i32 (i32, i8*, ...) @EmitIndented(i32 %0, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.1, i64 0, i64 0), i8* %1)
%6 = tail call i32 (i32, i8*, ...) @EmitIndented(i32 %0, i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0))
ret void
}