#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 */
struct t_gui_bar {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ gui_bar_default_items(char *);
scalar_t__ gui_bar_new(char *, char *, char *, char *, char *, char *, char *,
                       char *, char *, char *, char *, char *, char *, char *,
                       int /*<<< orphan*/);
struct t_gui_bar *gui_bar_search(char *);
int /*<<< orphan*/ gui_chat_printf_date_tags(int /*<<< orphan*/ *,
                                             int /*<<< orphan*/,
                                             int /*<<< orphan*/ *, char *,
                                             char *);
void gui_bar_create_default_nicklist() {
  struct t_gui_bar *ptr_bar;
  ptr_bar = gui_bar_search("nicklist");
  if (!ptr_bar) {
    if (gui_bar_new("nicklist", "0", "200", "window", "${nicklist}", "right",
                    "columns_vertical", "vertical", "0", "0", "default", "cyan",
                    "default", "1", gui_bar_default_items("nicklist"))) {
      gui_chat_printf_date_tags(NULL, 0, NULL, ("Bar \"%s\" created"),
                                "nicklist");
    }
  }
}


x86 assembly (clang, -O0):
<gui_bar_create_default_nicklist>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x50,%rsp
lea    0xeaa(%rip),%rdi
call   1050 <gui_bar_search@plt>
mov    %rax,-0x28(%rbp)
cmpq   $0x0,-0x28(%rbp)
jne    1221 <gui_bar_create_default_nicklist+0xe1>
lea    0xe8f(%rip),%rdi
call   1040 <gui_bar_default_items@plt>
lea    0xe83(%rip),%rdi
lea    0xe87(%rip),%r14
lea    0xe7e(%rip),%rdx
lea    0xe7b(%rip),%rcx
lea    0xe7b(%rip),%r8
lea    0xe80(%rip),%r9
lea    0xe7f(%rip),%r12
lea    0xe80(%rip),%r15
lea    0xe82(%rip),%r11
lea    0xe83(%rip),%rbx
lea    0xe81(%rip),%r10
mov    %r14,%rsi
mov    %r12,(%rsp)
mov    %r15,0x8(%rsp)
mov    %r14,0x10(%rsp)
mov    %r14,0x18(%rsp)
mov    %r11,0x20(%rsp)
mov    %rbx,0x28(%rsp)
mov    %r11,0x30(%rsp)
mov    %r10,0x38(%rsp)
mov    %eax,0x40(%rsp)
call   1060 <gui_bar_new@plt>
cmp    $0x0,%rax
je     121c <gui_bar_create_default_nicklist+0xdc>
xor    %eax,%eax
mov    %eax,%edx
xor    %esi,%esi
lea    0xe39(%rip),%rcx
lea    0xdec(%rip),%r8
mov    %rdx,%rdi
call   1030 <gui_chat_printf_date_tags@plt>
jmp    1221 <gui_bar_create_default_nicklist+0xe1>
add    $0x50,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

x86 assembly (clang, -O2):
<gui_bar_create_default_nicklist>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
lea    0xeb1(%rip),%rdi
call   1050 <gui_bar_search@plt>
test   %rax,%rax
je     1165 <gui_bar_create_default_nicklist+0x25>
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret
lea    0xe94(%rip),%rbx
mov    %rbx,%rdi
call   1040 <gui_bar_default_items@plt>
sub    $0x8,%rsp
lea    0xec5(%rip),%r10
lea    0xeb1(%rip),%r11
lea    0xeb2(%rip),%r14
lea    0xe77(%rip),%rsi
lea    0xe93(%rip),%r15
lea    0xe84(%rip),%r12
lea    0xe60(%rip),%rdx
lea    0xe5d(%rip),%rcx
lea    0xe5d(%rip),%r8
lea    0xe62(%rip),%r9
mov    %rbx,%rdi
push   %rax
push   %r10
push   %r11
push   %r14
push   %r11
push   %rsi
push   %rsi
push   %r15
push   %r12
call   1060 <gui_bar_new@plt>
add    $0x50,%rsp
test   %rax,%rax
je     1159 <gui_bar_create_default_nicklist+0x19>
lea    0xe5d(%rip),%rcx
lea    0xe10(%rip),%r8
xor    %edi,%edi
xor    %esi,%esi
xor    %edx,%edx
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
jmp    1030 <gui_chat_printf_date_tags@plt>

LLVM IR (-O0):
%struct.t_gui_bar = type { i32 }
@.str = [9 x i8] c"nicklist\00"
@.str.1 = [2 x i8] c"0\00"
@.str.2 = [4 x i8] c"200\00"
@.str.3 = [7 x i8] c"window\00"
@.str.4 = [12 x i8] c"${nicklist}\00"
@.str.5 = [6 x i8] c"right\00"
@.str.6 = [17 x i8] c"columns_vertical\00"
@.str.7 = [9 x i8] c"vertical\00"
@.str.8 = [8 x i8] c"default\00"
@.str.9 = [5 x i8] c"cyan\00"
@.str.10 = [2 x i8] c"1\00"
@.str.11 = [17 x i8] c"Bar \22%s\22 created\00"
define void @gui_bar_create_default_nicklist() {
%1 = alloca %struct.t_gui_bar*
%2 = call %struct.t_gui_bar* @gui_bar_search(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
store %struct.t_gui_bar* %2, %struct.t_gui_bar** %1
%3 = load %struct.t_gui_bar*, %struct.t_gui_bar** %1
%4 = icmp ne %struct.t_gui_bar* %3, null
br i1 %4, label %12, label %5
5: ; preds = %0
%6 = call i32 @gui_bar_default_items(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
%7 = call i64 @gui_bar_new(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.6, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.10, i64 0, i64 0), i32 %6)
%8 = icmp ne i64 %7, 0
br i1 %8, label %9, label %11
9: ; preds = %5
%10 = call i32 @gui_chat_printf_date_tags(i32* null, i32 0, i32* null, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.11, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
br label %11
11: ; preds = %9, %5
br label %12
12: ; preds = %11, %0
ret void
}

LLVM IR (-O2):
%struct.t_gui_bar = type { i32 }
@.str = [9 x i8] c"nicklist\00"
@.str.1 = [2 x i8] c"0\00"
@.str.2 = [4 x i8] c"200\00"
@.str.3 = [7 x i8] c"window\00"
@.str.4 = [12 x i8] c"${nicklist}\00"
@.str.5 = [6 x i8] c"right\00"
@.str.6 = [17 x i8] c"columns_vertical\00"
@.str.7 = [9 x i8] c"vertical\00"
@.str.8 = [8 x i8] c"default\00"
@.str.9 = [5 x i8] c"cyan\00"
@.str.10 = [2 x i8] c"1\00"
@.str.11 = [17 x i8] c"Bar \22%s\22 created\00"
define void @gui_bar_create_default_nicklist() {
%1 = tail call %struct.t_gui_bar* @gui_bar_search(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
%2 = icmp eq %struct.t_gui_bar* %1, null
br i1 %2, label %3, label %9
3: ; preds = %0
%4 = tail call i32 @gui_bar_default_items(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
%5 = tail call i64 @gui_bar_new(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.6, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.10, i64 0, i64 0), i32 %4)
%6 = icmp eq i64 %5, 0
br i1 %6, label %9, label %7
7: ; preds = %3
%8 = tail call i32 @gui_chat_printf_date_tags(i32* null, i32 0, i32* null, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.11, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0))
br label %9
9: ; preds = %3, %7, %0
ret void
}