#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*/ md_kernel(int *, int *, int *, int *, int *, int *, int *,
                             int);
void md(int d_force_x[32], int d_force_y[32], int d_force_z[32],
        int position_x[32], int position_y[32], int position_z[32],
        int NL[32 * 32]) {
  int i, j, jidx;
  int delx, dely, delz, r2inv, r2invTEMP, r2invTEMP2, r2invTEMP3, t1, t2, t3;
loop_i:
  for (i = 0; i < 32; i++)
    md_kernel(d_force_x, d_force_y, d_force_z, position_x, position_y,
              position_z, NL, i);
}


x86 assembly (clang, -O0):
<md>:
push   %rbp
mov    %rsp,%rbp
sub    $0x80,%rsp
mov    0x10(%rbp),%rax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
movl   $0x0,-0x34(%rbp)
cmpl   $0x20,-0x34(%rbp)
jge    1182 <md+0x72>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
mov    -0x20(%rbp),%rcx
mov    -0x28(%rbp),%r8
mov    -0x30(%rbp),%r9
mov    0x10(%rbp),%r10
mov    -0x34(%rbp),%eax
mov    %r10,(%rsp)
mov    %eax,0x8(%rsp)
call   1030 <md_kernel@plt>
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    113e <md+0x2e>
add    $0x80,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<md>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %r9,(%rsp)
mov    %r8,%r15
mov    %rcx,%r12
mov    %rdx,%r13
mov    %rsi,%rbx
mov    %rdi,%rbp
xor    %r14d,%r14d
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    %rbp,%rdi
mov    %rbx,%rsi
mov    %r13,%rdx
mov    %r12,%rcx
mov    %r15,%r8
mov    (%rsp),%r9
push   %r14
push   0x48(%rsp)
call   1030 <md_kernel@plt>
add    $0x10,%rsp
add    $0x1,%r14d
cmp    $0x20,%r14d
jne    1140 <md+0x30>
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define void @md(i32* %0, i32* %1, i32* %2, i32* %3, i32* %4, i32* %5, i32* %6) {
%8 = alloca i32*
%9 = alloca i32*
%10 = alloca i32*
%11 = alloca i32*
%12 = alloca i32*
%13 = alloca i32*
%14 = alloca i32*
%15 = alloca i32
%16 = alloca i32
%17 = alloca i32
%18 = alloca i32
%19 = alloca i32
%20 = alloca i32
%21 = alloca i32
%22 = alloca i32
%23 = alloca i32
%24 = alloca i32
%25 = alloca i32
%26 = alloca i32
%27 = alloca i32
store i32* %0, i32** %8
store i32* %1, i32** %9
store i32* %2, i32** %10
store i32* %3, i32** %11
store i32* %4, i32** %12
store i32* %5, i32** %13
store i32* %6, i32** %14
br label %28
28: ; preds = %7
store i32 0, i32* %15
br label %29
29: ; preds = %42, %28
%30 = load i32, i32* %15
%31 = icmp slt i32 %30, 32
br i1 %31, label %32, label %45
32: ; preds = %29
%33 = load i32*, i32** %8
%34 = load i32*, i32** %9
%35 = load i32*, i32** %10
%36 = load i32*, i32** %11
%37 = load i32*, i32** %12
%38 = load i32*, i32** %13
%39 = load i32*, i32** %14
%40 = load i32, i32* %15
%41 = call i32 @md_kernel(i32* %33, i32* %34, i32* %35, i32* %36, i32* %37, i32* %38, i32* %39, i32 %40)
br label %42
42: ; preds = %32
%43 = load i32, i32* %15
%44 = add nsw i32 %43, 1
store i32 %44, i32* %15
br label %29
45: ; preds = %29
ret void
}

LLVM IR (-O2):
define void @md(i32* %0, i32* %1, i32* %2, i32* %3, i32* %4, i32* %5, i32* %6) {
br label %8
8: ; preds = %7, %8
%9 = phi i32 [ 0, %7 ], [ %11, %8 ]
%10 = tail call i32 @md_kernel(i32* %0, i32* %1, i32* %2, i32* %3, i32* %4, i32* %5, i32* %6, i32 %9)
%11 = add nuw nsw i32 %9, 1
%12 = icmp eq i32 %11, 32
br i1 %12, label %13, label %8
13: ; preds = %8
ret void
}