#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 */
unsigned int nlm_read_ucore_rxpktrdy();
int /*<<< orphan*/ nlm_ucore_pkt_done(int, int /*<<< orphan*/,
                                      int /*<<< orphan*/, int /*<<< orphan*/,
                                      int /*<<< orphan*/, int /*<<< orphan*/,
                                      int /*<<< orphan*/, int /*<<< orphan*/,
                                      int /*<<< orphan*/, int /*<<< orphan*/,
                                      int /*<<< orphan*/, int /*<<< orphan*/);
int /*<<< orphan*/ nlm_ucore_setup_poepktdistr(int, int /*<<< orphan*/,
                                               int /*<<< orphan*/,
                                               int /*<<< orphan*/,
                                               int /*<<< orphan*/);
int main(void) {
  unsigned int pktrdy;
  int num_cachelines = 1518 / 64;
  while (1) {
    pktrdy = nlm_read_ucore_rxpktrdy();
    nlm_ucore_setup_poepktdistr(4, 0, 0, 0, 0);
    nlm_ucore_pkt_done(num_cachelines, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
  }
  return (0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x17,-0xc(%rbp)
mov    $0x0,%al
call   1050 <nlm_read_ucore_rxpktrdy@plt>
mov    %eax,-0x8(%rbp)
mov    $0x4,%edi
xor    %r8d,%r8d
mov    %r8d,%esi
mov    %r8d,%edx
mov    %r8d,%ecx
call   1040 <nlm_ucore_setup_poepktdistr@plt>
mov    -0xc(%rbp),%edi
xor    %r9d,%r9d
mov    %r9d,%esi
mov    %r9d,%edx
mov    %r9d,%ecx
mov    %r9d,%r8d
movl   $0x0,(%rsp)
movl   $0x0,0x8(%rsp)
movl   $0x0,0x10(%rsp)
movl   $0x0,0x18(%rsp)
movl   $0x0,0x20(%rsp)
movl   $0x0,0x28(%rsp)
call   1030 <nlm_ucore_pkt_done@plt>
jmp    1146 <main+0x16>

x86 assembly (clang, -O2):
<main>:
push   %rax
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
xor    %eax,%eax
call   1050 <nlm_read_ucore_rxpktrdy@plt>
mov    $0x4,%edi
xor    %esi,%esi
xor    %edx,%edx
xor    %ecx,%ecx
xor    %r8d,%r8d
call   1040 <nlm_ucore_setup_poepktdistr@plt>
mov    $0x17,%edi
xor    %esi,%esi
xor    %edx,%edx
xor    %ecx,%ecx
xor    %r8d,%r8d
xor    %r9d,%r9d
push   $0x0
push   $0x0
push   $0x0
push   $0x0
push   $0x0
push   $0x0
call   1030 <nlm_ucore_pkt_done@plt>
add    $0x30,%rsp
jmp    1140 <main+0x10>

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
store i32 23, i32* %3
br label %4
4: ; preds = %0, %4
%5 = call i32 (...) @nlm_read_ucore_rxpktrdy()
store i32 %5, i32* %2
%6 = call i32 @nlm_ucore_setup_poepktdistr(i32 4, i32 0, i32 0, i32 0, i32 0)
%7 = load i32, i32* %3
%8 = call i32 @nlm_ucore_pkt_done(i32 %7, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0)
br label %4
}

LLVM IR (-O2):
define i32 @main() {
br label %1
1: ; preds = %1, %0
%2 = tail call i32 (...) @nlm_read_ucore_rxpktrdy()
%3 = tail call i32 @nlm_ucore_setup_poepktdistr(i32 4, i32 0, i32 0, i32 0, i32 0)
%4 = tail call i32 @nlm_ucore_pkt_done(i32 23, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0)
br label %1
}