#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*/ INIT_COMP(void (*)(int, char **));
int /*<<< orphan*/ INIT_COMP_ACTIVE_PORT(void (*)(int, char **),
                                         int /*<<< orphan*/,
                                         int /*<<< orphan*/);
int /*<<< orphan*/ INIT_COMP_PASSIVE_PORT(void (*)(int, char **), int,
                                          int /*<<< orphan*/);
int /*<<< orphan*/ WRITE_DEBUG_INFO_COMP(char *, int);
int /*<<< orphan*/ atoi(char *);
void BrzNullAdapt(int num, char *args[]) {
  INIT_COMP(BrzNullAdapt);
  INIT_COMP_ACTIVE_PORT(BrzNullAdapt, 0, atoi(args[1]));
  INIT_COMP_PASSIVE_PORT(BrzNullAdapt, 1, atoi(args[2]));
  WRITE_DEBUG_INFO_COMP("NullAdapt", 2);
}


x86 assembly (clang, -O0):
<BrzNullAdapt>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    0x2e82(%rip),%rdi
call   1060 <INIT_COMP@plt>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   1070 <atoi@plt>
mov    %eax,%edx
mov    0x2e67(%rip),%rdi
xor    %esi,%esi
call   1040 <INIT_COMP_ACTIVE_PORT@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   1070 <atoi@plt>
mov    %eax,%edx
mov    0x2e4a(%rip),%rdi
mov    $0x1,%esi
call   1030 <INIT_COMP_PASSIVE_PORT@plt>
lea    0xe51(%rip),%rdi
mov    $0x2,%esi
call   1050 <WRITE_DEBUG_INFO_COMP@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<BrzNullAdapt>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%rbx
mov    0x2e8a(%rip),%r14
mov    %r14,%rdi
call   1060 <INIT_COMP@plt>
mov    0x8(%rbx),%rdi
call   1070 <atoi@plt>
mov    %r14,%rdi
xor    %esi,%esi
mov    %eax,%edx
call   1040 <INIT_COMP_ACTIVE_PORT@plt>
mov    0x10(%rbx),%rdi
call   1070 <atoi@plt>
mov    %r14,%rdi
mov    $0x1,%esi
mov    %eax,%edx
call   1030 <INIT_COMP_PASSIVE_PORT@plt>
lea    0xe66(%rip),%rdi
mov    $0x2,%esi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1050 <WRITE_DEBUG_INFO_COMP@plt>

LLVM IR (-O0):
@.str = [10 x i8] c"NullAdapt\00"
define void @BrzNullAdapt(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i8**
store i32 %0, i32* %3
store i8** %1, i8*** %4
%5 = call i32 @INIT_COMP(void (i32, i8**)* @BrzNullAdapt)
%6 = load i8**, i8*** %4
%7 = getelementptr inbounds i8*, i8** %6, i64 1
%8 = load i8*, i8** %7
%9 = call i32 @atoi(i8* %8)
%10 = call i32 @INIT_COMP_ACTIVE_PORT(void (i32, i8**)* @BrzNullAdapt, i32 0, i32 %9)
%11 = load i8**, i8*** %4
%12 = getelementptr inbounds i8*, i8** %11, i64 2
%13 = load i8*, i8** %12
%14 = call i32 @atoi(i8* %13)
%15 = call i32 @INIT_COMP_PASSIVE_PORT(void (i32, i8**)* @BrzNullAdapt, i32 1, i32 %14)
%16 = call i32 @WRITE_DEBUG_INFO_COMP(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i32 2)
ret void
}

LLVM IR (-O2):
@.str = [10 x i8] c"NullAdapt\00"
define void @BrzNullAdapt(i32 %0, i8** nocapture %1) {
%3 = tail call i32 @INIT_COMP(void (i32, i8**)* @BrzNullAdapt)
%4 = getelementptr inbounds i8*, i8** %1, i64 1
%5 = load i8*, i8** %4
%6 = tail call i32 @atoi(i8* %5)
%7 = tail call i32 @INIT_COMP_ACTIVE_PORT(void (i32, i8**)* @BrzNullAdapt, i32 0, i32 %6)
%8 = getelementptr inbounds i8*, i8** %1, i64 2
%9 = load i8*, i8** %8
%10 = tail call i32 @atoi(i8* %9)
%11 = tail call i32 @INIT_COMP_PASSIVE_PORT(void (i32, i8**)* @BrzNullAdapt, i32 1, i32 %10)
%12 = tail call i32 @WRITE_DEBUG_INFO_COMP(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i32 2)
ret void
}