#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 */
typedef int /*<<< orphan*/ xdrproc_t;
struct timeval {
  int /*<<< orphan*/ member_1;
  int /*<<< orphan*/ member_0;
};
typedef int /*<<< orphan*/ domainname;
typedef int /*<<< orphan*/ clnt_res;
typedef int /*<<< orphan*/ caddr_t;
typedef int /*<<< orphan*/ bool_t;
typedef int /*<<< orphan*/ CLIENT;

/* Variables and functions */
scalar_t__ RPC_SUCCESS;
int /*<<< orphan*/ YPPROC_DOMAIN_NONACK;
scalar_t__ clnt_call(int /*<<< orphan*/ *, int /*<<< orphan*/,
                     int /*<<< orphan*/, int /*<<< orphan*/, int /*<<< orphan*/,
                     int /*<<< orphan*/, struct timeval);
int /*<<< orphan*/ memset(char *, int /*<<< orphan*/, int);
scalar_t__ xdr_bool;
scalar_t__ xdr_domainname;
bool_t *ypproc_domain_nonack_2_send(domainname *argp, CLIENT *clnt) {
  static bool_t clnt_res;
  struct timeval TIMEOUT = {0, 0};
  memset((char *)&clnt_res, 0, sizeof(clnt_res));
  if (clnt_call(clnt, YPPROC_DOMAIN_NONACK, (xdrproc_t)xdr_domainname,
                (caddr_t)argp, (xdrproc_t)xdr_bool, (caddr_t)&clnt_res,
                TIMEOUT) != RPC_SUCCESS) {
    return (NULL);
  }
  return (&clnt_res);
}


x86 assembly (clang, -O0):
<ypproc_domain_nonack_2_send>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
lea    -0x20(%rbp),%rdi
xor    %esi,%esi
mov    $0x8,%edx
call   1030 <memset@plt>
lea    0x2ef1(%rip),%rdi
xor    %esi,%esi
mov    $0x4,%edx
call   1030 <memset@plt>
mov    -0x18(%rbp),%rdi
mov    0x2e7a(%rip),%rax
mov    (%rax),%esi
mov    0x2e61(%rip),%rax
mov    (%rax),%rax
mov    %eax,%edx
mov    -0x10(%rbp),%rax
mov    %eax,%ecx
mov    0x2e57(%rip),%rax
mov    (%rax),%rax
mov    %eax,%r8d
mov    -0x20(%rbp),%rax
lea    0x2eae(%rip),%r9
mov    %rax,(%rsp)
call   1040 <clnt_call@plt>
mov    0x2e4e(%rip),%rcx
cmp    (%rcx),%rax
je     11b0 <ypproc_domain_nonack_2_send+0x90>
movq   $0x0,-0x8(%rbp)
jmp    11bb <ypproc_domain_nonack_2_send+0x9b>
lea    0x2e81(%rip),%rax
mov    %rax,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<ypproc_domain_nonack_2_send>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
mov    %rsi,%r15
mov    %rdi,%r12
lea    0x2f03(%rip),%r14
xor    %ebx,%ebx
mov    %r14,%rdi
xor    %esi,%esi
mov    $0x4,%edx
call   1030 <memset@plt>
mov    0x2e8b(%rip),%rax
mov    (%rax),%esi
mov    0x2e72(%rip),%rax
mov    (%rax),%edx
mov    0x2e71(%rip),%rax
mov    (%rax),%r8d
movq   $0x0,(%rsp)
mov    %r15,%rdi
mov    %r12d,%ecx
mov    %r14d,%r9d
call   1040 <clnt_call@plt>
mov    0x2e69(%rip),%rcx
cmp    (%rcx),%rax
cmove  %r14,%rbx
mov    %rbx,%rax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
%struct.timeval = type { i32, i32 }
@ypproc_domain_nonack_2_send.clnt_res = internal global i32 0
@YPPROC_DOMAIN_NONACK = global i32 0
@xdr_domainname = global i64 0
@xdr_bool = global i64 0
@RPC_SUCCESS = global i64 0
define i32* @ypproc_domain_nonack_2_send(i32* %0, i32* %1) {
%3 = alloca i32*
%4 = alloca i32*
%5 = alloca i32*
%6 = alloca %struct.timeval
store i32* %0, i32** %4
store i32* %1, i32** %5
%7 = bitcast %struct.timeval* %6 to i8*
%8 = call i32 @memset(i8* bitcast (i32* @ypproc_domain_nonack_2_send.clnt_res to i8*), i32 0, i32 4)
%9 = load i32*, i32** %5
%10 = load i32, i32* @YPPROC_DOMAIN_NONACK
%11 = load i64, i64* @xdr_domainname
%12 = trunc i64 %11 to i32
%13 = load i32*, i32** %4
%14 = ptrtoint i32* %13 to i32
%15 = load i64, i64* @xdr_bool
%16 = trunc i64 %15 to i32
%17 = bitcast %struct.timeval* %6 to i64*
%18 = load i64, i64* %17
%19 = call i64 @clnt_call(i32* %9, i32 %10, i32 %12, i32 %14, i32 %16, i32 ptrtoint (i32* @ypproc_domain_nonack_2_send.clnt_res to i32), i64 %18)
%20 = load i64, i64* @RPC_SUCCESS
%21 = icmp ne i64 %19, %20
br i1 %21, label %22, label %23
22: ; preds = %2
store i32* null, i32** %3
br label %24
23: ; preds = %2
store i32* @ypproc_domain_nonack_2_send.clnt_res, i32** %3
br label %24
24: ; preds = %23, %22
%25 = load i32*, i32** %3
ret i32* %25
}

LLVM IR (-O2):
@ypproc_domain_nonack_2_send.clnt_res = internal global i32 0
@YPPROC_DOMAIN_NONACK = global i32 0
@xdr_domainname = global i64 0
@xdr_bool = global i64 0
@RPC_SUCCESS = global i64 0
define i32* @ypproc_domain_nonack_2_send(i32* %0, i32* %1) {
%3 = tail call i32 @memset(i8* bitcast (i32* @ypproc_domain_nonack_2_send.clnt_res to i8*), i32 0, i32 4)
%4 = load i32, i32* @YPPROC_DOMAIN_NONACK
%5 = load i64, i64* @xdr_domainname
%6 = trunc i64 %5 to i32
%7 = ptrtoint i32* %0 to i64
%8 = trunc i64 %7 to i32
%9 = load i64, i64* @xdr_bool
%10 = trunc i64 %9 to i32
%11 = tail call i64 @clnt_call(i32* %1, i32 %4, i32 %6, i32 %8, i32 %10, i32 ptrtoint (i32* @ypproc_domain_nonack_2_send.clnt_res to i32), i64 0)
%12 = load i64, i64* @RPC_SUCCESS
%13 = icmp eq i64 %11, %12
%14 = select i1 %13, i32* @ypproc_domain_nonack_2_send.clnt_res, i32* null
ret i32* %14
}