void fill_node_phys_prop(int m, double *p00, double *pL0, double *pR0,
                         double *p0L, double *p0R, double *pLL, double *pRL,
                         double *pLR, double *pRR, const double *const p,
                         const int *const M0L, const int *const M0R) {
  *p00 = p[m];
  *pL0 = p[m - 1];
  *pR0 = p[m + 1];
  *p0L = p[M0L[m]];
  *p0R = p[M0R[m]];
  *pLL = p[M0L[m] - 1];
  *pRL = p[M0L[m] + 1];
  *pLR = p[M0R[m] - 1];
  *pRR = p[M0R[m] + 1];
}


x86 assembly (clang, -O0):
<fill_node_phys_prop>:
push   %rbp
mov    %rsp,%rbp
mov    0x40(%rbp),%rax
mov    0x38(%rbp),%rax
mov    0x30(%rbp),%rax
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
mov    0x18(%rbp),%rax
mov    0x10(%rbp),%rax
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
mov    0x30(%rbp),%rax
movslq -0x4(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x10(%rbp),%rax
movsd  %xmm0,(%rax)
mov    0x30(%rbp),%rax
mov    -0x4(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x18(%rbp),%rax
movsd  %xmm0,(%rax)
mov    0x30(%rbp),%rax
mov    -0x4(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x20(%rbp),%rax
movsd  %xmm0,(%rax)
mov    0x30(%rbp),%rax
mov    0x38(%rbp),%rcx
movslq -0x4(%rbp),%rdx
movslq (%rcx,%rdx,4),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x28(%rbp),%rax
movsd  %xmm0,(%rax)
mov    0x30(%rbp),%rax
mov    0x40(%rbp),%rcx
movslq -0x4(%rbp),%rdx
movslq (%rcx,%rdx,4),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x30(%rbp),%rax
movsd  %xmm0,(%rax)
mov    0x30(%rbp),%rax
mov    0x38(%rbp),%rcx
movslq -0x4(%rbp),%rdx
mov    (%rcx,%rdx,4),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x10(%rbp),%rax
movsd  %xmm0,(%rax)
mov    0x30(%rbp),%rax
mov    0x38(%rbp),%rcx
movslq -0x4(%rbp),%rdx
mov    (%rcx,%rdx,4),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x18(%rbp),%rax
movsd  %xmm0,(%rax)
mov    0x30(%rbp),%rax
mov    0x40(%rbp),%rcx
movslq -0x4(%rbp),%rdx
mov    (%rcx,%rdx,4),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x20(%rbp),%rax
movsd  %xmm0,(%rax)
mov    0x30(%rbp),%rax
mov    0x40(%rbp),%rcx
movslq -0x4(%rbp),%rdx
mov    (%rcx,%rdx,4),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x28(%rbp),%rax
movsd  %xmm0,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<fill_node_phys_prop>:
push   %r15
push   %r14
push   %r12
push   %rbx
mov    0x40(%rsp),%r10
mov    0x38(%rsp),%r11
mov    0x30(%rsp),%r14
mov    0x28(%rsp),%r15
mov    0x58(%rsp),%r12
mov    0x50(%rsp),%rbx
mov    0x48(%rsp),%rax
movslq %edi,%rdi
movsd  (%rax,%rdi,8),%xmm0
movsd  %xmm0,(%rsi)
movsd  -0x8(%rax,%rdi,8),%xmm0
movsd  %xmm0,(%rdx)
movsd  0x8(%rax,%rdi,8),%xmm0
movsd  %xmm0,(%rcx)
movslq (%rbx,%rdi,4),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,(%r8)
movslq (%r12,%rdi,4),%rdx
movsd  (%rax,%rdx,8),%xmm0
movsd  %xmm0,(%r9)
movsd  -0x8(%rax,%rcx,8),%xmm0
movsd  %xmm0,(%r15)
movsd  0x8(%rax,%rcx,8),%xmm0
movsd  %xmm0,(%r14)
movsd  -0x8(%rax,%rdx,8),%xmm0
movsd  %xmm0,(%r11)
movsd  0x8(%rax,%rdx,8),%xmm0
movsd  %xmm0,(%r10)
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define void @fill_node_phys_prop(i32 %0, double* %1, double* %2, double* %3, double* %4, double* %5, double* %6, double* %7, double* %8, double* %9, double* %10, i32* %11, i32* %12) {
%14 = alloca i32
%15 = alloca double*
%16 = alloca double*
%17 = alloca double*
%18 = alloca double*
%19 = alloca double*
%20 = alloca double*
%21 = alloca double*
%22 = alloca double*
%23 = alloca double*
%24 = alloca double*
%25 = alloca i32*
%26 = alloca i32*
store i32 %0, i32* %14
store double* %1, double** %15
store double* %2, double** %16
store double* %3, double** %17
store double* %4, double** %18
store double* %5, double** %19
store double* %6, double** %20
store double* %7, double** %21
store double* %8, double** %22
store double* %9, double** %23
store double* %10, double** %24
store i32* %11, i32** %25
store i32* %12, i32** %26
%27 = load double*, double** %24
%28 = load i32, i32* %14
%29 = sext i32 %28 to i64
%30 = getelementptr inbounds double, double* %27, i64 %29
%31 = load double, double* %30
%32 = load double*, double** %15
store double %31, double* %32
%33 = load double*, double** %24
%34 = load i32, i32* %14
%35 = sub nsw i32 %34, 1
%36 = sext i32 %35 to i64
%37 = getelementptr inbounds double, double* %33, i64 %36
%38 = load double, double* %37
%39 = load double*, double** %16
store double %38, double* %39
%40 = load double*, double** %24
%41 = load i32, i32* %14
%42 = add nsw i32 %41, 1
%43 = sext i32 %42 to i64
%44 = getelementptr inbounds double, double* %40, i64 %43
%45 = load double, double* %44
%46 = load double*, double** %17
store double %45, double* %46
%47 = load double*, double** %24
%48 = load i32*, i32** %25
%49 = load i32, i32* %14
%50 = sext i32 %49 to i64
%51 = getelementptr inbounds i32, i32* %48, i64 %50
%52 = load i32, i32* %51
%53 = sext i32 %52 to i64
%54 = getelementptr inbounds double, double* %47, i64 %53
%55 = load double, double* %54
%56 = load double*, double** %18
store double %55, double* %56
%57 = load double*, double** %24
%58 = load i32*, i32** %26
%59 = load i32, i32* %14
%60 = sext i32 %59 to i64
%61 = getelementptr inbounds i32, i32* %58, i64 %60
%62 = load i32, i32* %61
%63 = sext i32 %62 to i64
%64 = getelementptr inbounds double, double* %57, i64 %63
%65 = load double, double* %64
%66 = load double*, double** %19
store double %65, double* %66
%67 = load double*, double** %24
%68 = load i32*, i32** %25
%69 = load i32, i32* %14
%70 = sext i32 %69 to i64
%71 = getelementptr inbounds i32, i32* %68, i64 %70
%72 = load i32, i32* %71
%73 = sub nsw i32 %72, 1
%74 = sext i32 %73 to i64
%75 = getelementptr inbounds double, double* %67, i64 %74
%76 = load double, double* %75
%77 = load double*, double** %20
store double %76, double* %77
%78 = load double*, double** %24
%79 = load i32*, i32** %25
%80 = load i32, i32* %14
%81 = sext i32 %80 to i64
%82 = getelementptr inbounds i32, i32* %79, i64 %81
%83 = load i32, i32* %82
%84 = add nsw i32 %83, 1
%85 = sext i32 %84 to i64
%86 = getelementptr inbounds double, double* %78, i64 %85
%87 = load double, double* %86
%88 = load double*, double** %21
store double %87, double* %88
%89 = load double*, double** %24
%90 = load i32*, i32** %26
%91 = load i32, i32* %14
%92 = sext i32 %91 to i64
%93 = getelementptr inbounds i32, i32* %90, i64 %92
%94 = load i32, i32* %93
%95 = sub nsw i32 %94, 1
%96 = sext i32 %95 to i64
%97 = getelementptr inbounds double, double* %89, i64 %96
%98 = load double, double* %97
%99 = load double*, double** %22
store double %98, double* %99
%100 = load double*, double** %24
%101 = load i32*, i32** %26
%102 = load i32, i32* %14
%103 = sext i32 %102 to i64
%104 = getelementptr inbounds i32, i32* %101, i64 %103
%105 = load i32, i32* %104
%106 = add nsw i32 %105, 1
%107 = sext i32 %106 to i64
%108 = getelementptr inbounds double, double* %100, i64 %107
%109 = load double, double* %108
%110 = load double*, double** %23
store double %109, double* %110
ret void
}

LLVM IR (-O2):
define void @fill_node_phys_prop(i32 %0, double* nocapture writeonly %1, double* nocapture writeonly %2, double* nocapture writeonly %3, double* nocapture writeonly %4, double* nocapture writeonly %5, double* nocapture writeonly %6, double* nocapture writeonly %7, double* nocapture writeonly %8, double* nocapture writeonly %9, double* nocapture %10, i32* nocapture %11, i32* nocapture %12) {
%14 = sext i32 %0 to i64
%15 = getelementptr inbounds double, double* %10, i64 %14
%16 = load double, double* %15
store double %16, double* %1
%17 = add nsw i32 %0, -1
%18 = sext i32 %17 to i64
%19 = getelementptr inbounds double, double* %10, i64 %18
%20 = load double, double* %19
store double %20, double* %2
%21 = add nsw i32 %0, 1
%22 = sext i32 %21 to i64
%23 = getelementptr inbounds double, double* %10, i64 %22
%24 = load double, double* %23
store double %24, double* %3
%25 = getelementptr inbounds i32, i32* %11, i64 %14
%26 = load i32, i32* %25
%27 = sext i32 %26 to i64
%28 = getelementptr inbounds double, double* %10, i64 %27
%29 = load double, double* %28
store double %29, double* %4
%30 = getelementptr inbounds i32, i32* %12, i64 %14
%31 = load i32, i32* %30
%32 = sext i32 %31 to i64
%33 = getelementptr inbounds double, double* %10, i64 %32
%34 = load double, double* %33
store double %34, double* %5
%35 = add nsw i32 %26, -1
%36 = sext i32 %35 to i64
%37 = getelementptr inbounds double, double* %10, i64 %36
%38 = load double, double* %37
store double %38, double* %6
%39 = add nsw i32 %26, 1
%40 = sext i32 %39 to i64
%41 = getelementptr inbounds double, double* %10, i64 %40
%42 = load double, double* %41
store double %42, double* %7
%43 = add nsw i32 %31, -1
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds double, double* %10, i64 %44
%46 = load double, double* %45
store double %46, double* %8
%47 = add nsw i32 %31, 1
%48 = sext i32 %47 to i64
%49 = getelementptr inbounds double, double* %10, i64 %48
%50 = load double, double* %49
store double %50, double* %9
ret void
}