#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 */
typedef struct TYPE_3__ TYPE_1__;

/* Type definitions */
struct TYPE_3__ {
  int /*<<< orphan*/ deskey;
  int /*<<< orphan*/ remotename;
};
typedef TYPE_1__ cryptkeyarg;
typedef int /*<<< orphan*/ bool_t;
typedef int /*<<< orphan*/ XDR;

/* Variables and functions */
int /*<<< orphan*/ FALSE;
int /*<<< orphan*/ TRUE;
int /*<<< orphan*/ xdr_des_block(int /*<<< orphan*/ *, int /*<<< orphan*/ *);
int /*<<< orphan*/ xdr_netnamestr(int /*<<< orphan*/ *, int /*<<< orphan*/ *);
bool_t xdr_cryptkeyarg(register XDR *xdrs, cryptkeyarg *objp) {
  if (!xdr_netnamestr(xdrs, &objp->remotename))
    return (FALSE);
  if (!xdr_des_block(xdrs, &objp->deskey))
    return (FALSE);
  return (TRUE);
}


x86 assembly (clang, -O0):
<xdr_cryptkeyarg>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
add    $0x4,%rsi
call   1040 <xdr_netnamestr@plt>
cmp    $0x0,%eax
jne    115b <xdr_cryptkeyarg+0x3b>
mov    0x2e87(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
jmp    118e <xdr_cryptkeyarg+0x6e>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1030 <xdr_des_block@plt>
cmp    $0x0,%eax
jne    1182 <xdr_cryptkeyarg+0x62>
mov    0x2e60(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
jmp    118e <xdr_cryptkeyarg+0x6e>
mov    0x2e5f(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<xdr_cryptkeyarg>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
add    $0x4,%rsi
call   1040 <xdr_netnamestr@plt>
test   %eax,%eax
je     1146 <xdr_cryptkeyarg+0x26>
mov    %rbx,%rdi
mov    %r14,%rsi
call   1030 <xdr_des_block@plt>
test   %eax,%eax
jne    114f <xdr_cryptkeyarg+0x2f>
mov    0x2e8b(%rip),%rax
jmp    1156 <xdr_cryptkeyarg+0x36>
mov    0x2e92(%rip),%rax
mov    (%rax),%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
%struct.TYPE_3__ = type { i32, i32 }
@FALSE = global i32 0
@TRUE = global i32 0
define i32 @xdr_cryptkeyarg(i32* %0, %struct.TYPE_3__* %1) {
%3 = alloca i32
%4 = alloca i32*
%5 = alloca %struct.TYPE_3__*
store i32* %0, i32** %4
store %struct.TYPE_3__* %1, %struct.TYPE_3__** %5
%6 = load i32*, i32** %4
%7 = load %struct.TYPE_3__*, %struct.TYPE_3__** %5
%8 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %7, i32 0, i32 1
%9 = call i32 @xdr_netnamestr(i32* %6, i32* %8)
%10 = icmp ne i32 %9, 0
br i1 %10, label %13, label %11
11: ; preds = %2
%12 = load i32, i32* @FALSE
store i32 %12, i32* %3
br label %23
13: ; preds = %2
%14 = load i32*, i32** %4
%15 = load %struct.TYPE_3__*, %struct.TYPE_3__** %5
%16 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %15, i32 0, i32 0
%17 = call i32 @xdr_des_block(i32* %14, i32* %16)
%18 = icmp ne i32 %17, 0
br i1 %18, label %21, label %19
19: ; preds = %13
%20 = load i32, i32* @FALSE
store i32 %20, i32* %3
br label %23
21: ; preds = %13
%22 = load i32, i32* @TRUE
store i32 %22, i32* %3
br label %23
23: ; preds = %21, %19, %11
%24 = load i32, i32* %3
ret i32 %24
}

LLVM IR (-O2):
%struct.TYPE_3__ = type { i32, i32 }
@FALSE = global i32 0
@TRUE = global i32 0
define i32 @xdr_cryptkeyarg(i32* %0, %struct.TYPE_3__* %1) {
%3 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %1, i64 0, i32 1
%4 = tail call i32 @xdr_netnamestr(i32* %0, i32* %3)
%5 = icmp eq i32 %4, 0
br i1 %5, label %11, label %6
6: ; preds = %2
%7 = getelementptr inbounds %struct.TYPE_3__, %struct.TYPE_3__* %1, i64 0, i32 0
%8 = tail call i32 @xdr_des_block(i32* %0, i32* %7)
%9 = icmp eq i32 %8, 0
%10 = select i1 %9, i32* @FALSE, i32* @TRUE
br label %11
11: ; preds = %6, %2
%12 = phi i32* [ @FALSE, %2 ], [ %10, %6 ]
%13 = load i32, i32* %12
ret i32 %13
}